/* ===== Play Loud! — Design system ===== */

@font-face {
	font-family: "Bebas Neue";
	src: url("../fonts/bebasneue-webfont.woff") format("woff");
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

@font-face {
	font-family: "Francophil Sans";
	src: url("../fonts/francophilsans-webfont.woff") format("woff");
	font-weight: normal;
	font-style: normal;
	font-display: swap;
}

:root {
	--red: #ff1b1b;
	--red-dark: #b31818;
	--black: #121212;
	--ink: #1c1c1c;
	--white: #ffffff;
	--gray-100: #f6f6f6;
	--gray-200: #eaeaea;
	--gray-400: #c7c7c7;
	--gray-600: #6b6b6b;

	--font-display: "Bebas Neue", "Arial Narrow", sans-serif;
	--font-body: "Francophil Sans", -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

	--radius: 10px;
	--shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
	--container: 1180px;
}

* { box-sizing: border-box; }

html { scroll-behavior: auto; }

/* Evita che l'header fisso in alto copra il punto a cui si salta con un link #ancora */
#disponibilita, #tariffe { scroll-margin-top: 90px; }

body {
	margin: 0;
	font-family: var(--font-body);
	color: var(--ink);
	background: var(--white);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
	font-family: var(--font-display);
	letter-spacing: 0.03em;
	text-transform: uppercase;
	margin: 0 0 0.5em;
	line-height: 1.05;
}

h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); }
h3 { font-size: clamp(1.3rem, 3vw, 1.7rem); }
h4 { font-size: 1.1rem; letter-spacing: 0.06em; color: var(--red-dark); }

p { margin: 0 0 1em; }

.container {
	max-width: var(--container);
	margin: 0 auto;
	padding: 0 24px;
}

.btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--font-display);
	letter-spacing: 0.05em;
	text-transform: uppercase;
	font-size: 1.05rem;
	padding: 14px 28px;
	border-radius: 999px;
	border: 2px solid transparent;
	cursor: pointer;
	transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}

.btn-primary {
	background: var(--red);
	color: var(--white);
	box-shadow: 0 8px 20px rgba(255, 27, 27, 0.35);
}
.btn-primary:hover { background: var(--red-dark); transform: translateY(-2px); }

.btn-outline {
	background: transparent;
	color: var(--white);
	border-color: rgba(255, 255, 255, 0.6);
}
.btn-outline:hover { background: rgba(255, 255, 255, 0.12); transform: translateY(-2px); }

.btn-dark {
	background: var(--black);
	color: var(--white);
}
.btn-dark:hover { background: var(--red); transform: translateY(-2px); }

/* ===== Header ===== */

#site-header {
	position: sticky;
	top: 0;
	z-index: 100;
	background: var(--black);
	border-bottom: 3px solid var(--red);
}

.header-inner {
	max-width: var(--container);
	margin: 0 auto;
	padding: 10px 24px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.logo img {
	height: 54px;
	width: auto;
	border-radius: 6px;
}

nav#mainmenu ul {
	list-style: none;
	display: flex;
	gap: 6px;
	margin: 0;
	padding: 0;
}

nav#mainmenu a {
	display: block;
	color: var(--white);
	font-family: var(--font-display);
	letter-spacing: 0.05em;
	font-size: 1.05rem;
	padding: 10px 16px;
	border-radius: 8px;
	transition: background 0.15s ease, color 0.15s ease;
}

nav#mainmenu a:hover,
nav#mainmenu a.active {
	background: var(--red);
	color: var(--white);
}

.header-social {
	display: flex;
	gap: 10px;
}
.header-social img { height: 22px; width: 22px; opacity: 0.85; }
.header-social a:hover img { opacity: 1; }

.menu-toggle {
	display: none;
	flex-direction: column;
	gap: 5px;
	background: none;
	border: none;
	cursor: pointer;
	padding: 8px;
}
.menu-toggle span {
	width: 26px;
	height: 3px;
	background: var(--white);
	border-radius: 2px;
}

/* ===== Hero ===== */

.hero {
	position: relative;
	background: linear-gradient(135deg, var(--black) 0%, #2a0a0a 60%, var(--red-dark) 130%);
	color: var(--white);
	padding: 90px 0 70px;
	overflow: hidden;
}

.hero::after {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(circle at 80% 20%, rgba(255,27,27,0.35), transparent 55%);
	pointer-events: none;
}

.hero-inner {
	position: relative;
	max-width: var(--container);
	margin: 0 auto;
	padding: 0 24px;
}

.hero .eyebrow {
	font-family: var(--font-display);
	color: var(--red);
	letter-spacing: 0.12em;
	font-size: 1rem;
	margin-bottom: 6px;
}

.hero p.lead {
	max-width: 620px;
	font-size: 1.15rem;
	color: rgba(255,255,255,0.85);
}

.hero-actions {
	display: flex;
	gap: 14px;
	flex-wrap: wrap;
	margin-top: 28px;
}

/* ===== Sections ===== */

section { padding: 64px 0; }
section.tight { padding: 40px 0; }
.section-alt { background: var(--gray-100); }
.section-dark { background: var(--black); color: var(--white); }
.section-dark h2, .section-dark h3 { color: var(--white); }

.section-head { max-width: 720px; margin-bottom: 36px; }
.section-head .eyebrow {
	font-family: var(--font-display);
	color: var(--red-dark);
	letter-spacing: 0.1em;
}

/* ===== Cards / grid ===== */

.grid {
	display: grid;
	gap: 24px;
}
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
	background: var(--white);
	border-radius: var(--radius);
	overflow: hidden;
	box-shadow: 0 4px 16px rgba(0,0,0,0.08);
	transition: transform 0.2s ease, box-shadow 0.2s ease;
	display: flex;
	flex-direction: column;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.card img { aspect-ratio: 4/3; object-fit: cover; width: 100%; }

.card-body { padding: 18px 20px 22px; flex: 1; display: flex; flex-direction: column; }
.card-body h3 { margin-bottom: 8px; }
.card-body p { color: var(--gray-600); font-size: 0.95rem; flex: 1; }

.card-tag {
	align-self: flex-start;
	background: var(--red);
	color: var(--white);
	font-family: var(--font-display);
	letter-spacing: 0.05em;
	font-size: 0.85rem;
	padding: 4px 12px;
	border-radius: 999px;
	margin-bottom: 10px;
}

/* ===== Info list (footer style contact) ===== */

.info-list { list-style: none; margin: 0; padding: 0; }
.info-list li {
	display: flex;
	align-items: center;
	gap: 10px;
	margin-bottom: 12px;
}
.info-list img,
.info-list .c-icon { height: 22px; width: 22px; flex-shrink: 0; }
.info-list .label {
	display: block;
	font-size: 0.75rem;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--gray-600);
}
.social-row { display: flex; gap: 12px; align-items: center; }
.social-row img { height: 26px; width: 26px; }
#site-footer .info-list .label { color: rgba(255, 255, 255, 0.5); }

/* ===== Footer ===== */

#site-footer {
	background: var(--black);
	color: rgba(255,255,255,0.85);
	padding: 56px 0 24px;
}

.footer-grid {
	display: grid;
	grid-template-columns: 1.3fr 1fr 1fr;
	gap: 40px;
	margin-bottom: 36px;
}

.footer-grid h4 {
	color: var(--white);
	margin-bottom: 16px;
}

.footer-grid a:hover { color: var(--red); }

.footer-nav { list-style: none; margin: 0; padding: 0; }
.footer-nav li { margin-bottom: 8px; }

.footer-bottom {
	border-top: 1px solid rgba(255,255,255,0.15);
	padding-top: 20px;
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 10px;
	font-size: 0.85rem;
	color: rgba(255,255,255,0.55);
}

/* ===== Room gallery / equipment accordion ===== */

.equip-group { margin-bottom: 28px; }
.equip-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.equip-list li {
	background: var(--gray-100);
	border-radius: 8px;
	padding: 12px 16px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
}
.equip-list li span { flex: 1 1 auto; min-width: 0; }
.equip-list li strong { flex-shrink: 0; white-space: nowrap; }
.equip-note { font-size: 0.85rem; color: var(--gray-600); }

/* Prodotti con foto: si aprono al click, senza bisogno di JavaScript */
.equip-list li.has-photo { padding: 0; overflow: hidden; }
.equip-list li.has-photo details summary {
	list-style: none;
	cursor: pointer;
	padding: 12px 16px;
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
}
.equip-list li.has-photo summary::-webkit-details-marker { display: none; }
.equip-list li.has-photo summary::after {
	content: "+";
	font-family: var(--font-display);
	font-size: 1.2rem;
	color: var(--red-dark);
	margin-left: 8px;
	flex-shrink: 0;
}
.equip-list li.has-photo details[open] summary::after { content: "\2212"; }
.equip-list li.has-photo details[open] summary { border-bottom: 1px solid var(--gray-400); }
.equip-list li.has-photo details .equip-list li { background: var(--white); }
.equip-list li.has-photo details img {
	display: block;
	max-width: 240px;
	width: 100%;
	margin: 0 auto;
	padding: 18px;
}

.gallery {
	display: grid;
	grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
	gap: 10px;
}
.gallery img {
	aspect-ratio: 4/3;
	object-fit: cover;
	border-radius: 8px;
	cursor: zoom-in;
}

.room-switcher {
	display: flex;
	gap: 10px;
	flex-wrap: wrap;
	margin-top: 10px;
}
.room-switcher a {
	padding: 8px 16px;
	border-radius: 999px;
	background: var(--gray-100);
	font-family: var(--font-display);
	letter-spacing: 0.04em;
}
.room-switcher a.active,
.room-switcher a:hover { background: var(--red); color: var(--white); }

/* ===== Availability grid ===== */

.avail-wrap { position: relative; overflow-x: auto; border-radius: var(--radius); box-shadow: 0 2px 10px rgba(0,0,0,0.08); }

.scroll-hint {
	display: none;
	font-size: 0.82rem;
	color: var(--gray-600);
	margin: 8px 0 0;
}

.week-nav {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	margin: 26px 0 12px;
	font-family: var(--font-display);
	letter-spacing: 0.04em;
}
.week-nav button {
	background: var(--black);
	color: var(--white);
	border: none;
	border-radius: 8px;
	padding: 8px 16px;
	cursor: pointer;
	font-family: var(--font-display);
	letter-spacing: 0.04em;
	white-space: nowrap;
	flex-shrink: 0;
}
.week-nav button:hover { background: var(--red); }
.week-nav button:disabled { opacity: 0.35; cursor: default; }
.week-nav .week-label { white-space: nowrap; }

table.avail {
	border-collapse: collapse;
	width: 100%;
	min-width: 900px;
	font-size: 0.82rem;
}
table.avail th, table.avail td {
	border: 1px solid var(--gray-200);
	text-align: center;
	padding: 4px 3px;
}
table.avail thead th {
	background: var(--black);
	color: var(--white);
	font-family: var(--font-display);
	letter-spacing: 0.03em;
}
table.avail .time-col {
	position: sticky;
	left: 0;
	z-index: 1;
	background: var(--gray-100);
	font-weight: 600;
	white-space: nowrap;
}
table.avail thead .time-col {
	background: var(--black);
	color: var(--white);
	z-index: 4;
}
table.avail td.free { background: #eafbea; }
table.avail td.busy { background: var(--red); }
table.avail .room-head { font-size: 0.72rem; font-weight: normal; opacity: 0.85; }

/* Divisorio verticale tra un giorno e il successivo */
table.avail .day-end { border-right: 3px solid var(--black); }

/* Divisorio orizzontale ogni 2 ore e mezza (5 fasce da 30 min) */
table.avail tr.block-start td,
table.avail tr.block-start th { border-top: 2px solid var(--black); }

/* Giornate segnate come chiuse (ferie/festivi): grigio scuro, distinto da "occupato" */
table.avail th.closed { background: #4a4a4a; }
table.avail td.closed { background: #6b6b6b; }

/* Orari già passati: spenti, per non confondersi con la disponibilità reale */
table.avail td.past { background: #d8d8d8 !important; opacity: 0.6; }

/* Fuori dall'orario di apertura (es. sabato sera, domenica mattina): non prenotabile */
table.avail td.off-hours {
	background: repeating-linear-gradient(45deg, #e2e2e2, #e2e2e2 6px, #ececec 6px, #ececec 12px);
	cursor: default;
}

.legend { display: flex; gap: 18px; margin-top: 12px; font-size: 0.85rem; color: var(--gray-600); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 14px; height: 14px; border-radius: 3px; display: inline-block; }
.legend .free i { background: #eafbea; border: 1px solid var(--gray-400); }
.legend .busy i { background: var(--red); }

/* ===== Forms ===== */

.form-grid { display: grid; gap: 16px; max-width: 560px; }
.form-grid label { display: block; font-family: var(--font-display); letter-spacing: 0.04em; margin-bottom: 6px; }
.form-grid input, .form-grid textarea {
	width: 100%;
	padding: 12px 14px;
	border: 1px solid var(--gray-400);
	border-radius: 8px;
	font-family: var(--font-body);
	font-size: 1rem;
}
.form-grid textarea { min-height: 140px; resize: vertical; }
.form-msg { padding: 14px 18px; border-radius: 8px; margin-bottom: 20px; }
.form-msg.ok { background: #e6f7e6; color: #1a6b1a; }
.form-msg.ko { background: #fdeaea; color: var(--red-dark); }

/* ===== Map ===== */

.map-frame { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.map-frame iframe { width: 100%; height: 420px; border: 0; display: block; }

/* ===== Cookie banner ===== */

#cookie-banner {
	position: fixed;
	left: 0; right: 0; bottom: 0;
	background: var(--black);
	color: var(--white);
	padding: 16px 24px;
	display: none;
	z-index: 200;
	font-size: 0.9rem;
}
#cookie-banner .container { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
#cookie-banner a { color: var(--red); text-decoration: underline; }

/* ===== Responsive ===== */

@media (max-width: 900px) {
	.grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
	.footer-grid { grid-template-columns: 1fr; }
}

@media (max-width: 767px) {
	.menu-toggle { display: flex; }
	nav#mainmenu {
		position: absolute;
		top: 100%; left: 0; right: 0;
		background: var(--black);
		display: none;
		flex-direction: column;
		border-top: 1px solid rgba(255,255,255,0.1);
	}
	nav#mainmenu.show { display: flex; }
	nav#mainmenu ul { flex-direction: column; padding: 10px 20px 20px; }
	.grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
	.hero { padding: 60px 0 50px; text-align: center; }
	.hero-actions { justify-content: center; }

	.week-nav { flex-wrap: wrap; justify-content: center; text-align: center; }
	.week-nav .week-label { order: -1; width: 100%; font-size: 0.95rem; margin-bottom: 6px; }
	.scroll-hint { display: block; }
}
