@font-face {
  font-family: "Mythbuster";
  src: url("fonts/Mythbuster.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

:root {
  --black: #120b07;
  --charcoal: #22150e;
  --white: #ffffff;
  --paper: #2a160c;
  --foam: #4a2815;
  --cream: #f5d7b5;
  --cream-soft: #ffead2;
  --aqua: #d9822b;
  --lake: #7b3f19;
  --sun: #ff7a1a;
  --pink: #c94f24;
  --lime: #ffd27a;
  --muted: #716156;
  --line-dark: rgba(18, 11, 7, 0.12);
  --line-light: rgba(255, 255, 255, 0.18);
  --shadow-clean: 0 18px 42px rgba(18, 11, 7, 0.12);
  --shadow-pop: 0 22px 54px rgba(18, 11, 7, 0.18);
  --radius: 22px;
  --title: "Space Grotesk", "Inter", sans-serif;
  --body: "Inter", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(255, 122, 26, 0.24) 0%, transparent 30%),
    linear-gradient(215deg, rgba(255, 210, 122, 0.14) 0%, transparent 34%),
    radial-gradient(ellipse at 50% 0%, rgba(217, 130, 43, 0.18), transparent 42%),
    linear-gradient(180deg, #1a0f09 0%, #2a160c 44%, #4a2815 100%);
  font-family: var(--body);
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(120deg, transparent 0%, rgba(255, 234, 210, 0.05) 42%, transparent 68%),
    linear-gradient(180deg, rgba(255, 234, 210, 0.035), transparent 34%, rgba(18, 11, 7, 0.2));
  pointer-events: none;
}

body.nav-open,
body.lightbox-open {
  overflow: hidden;
}

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

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

button,
input,
textarea {
  font: inherit;
}

::selection {
  color: var(--black);
  background: var(--lime);
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  gap: 16px;
  color: var(--white);
  background: var(--black);
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.loader.hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-ring {
  width: 64px;
  height: 64px;
  border: 3px solid rgba(255, 255, 255, 0.16);
  border-top-color: var(--aqua);
  border-left-color: var(--sun);
  border-radius: 50%;
  box-shadow: 0 0 44px rgba(255, 122, 26, 0.28);
  animation: spin 0.85s linear infinite;
}

.loader span {
  font-family: var(--title);
  font-weight: 800;
}

.cursor-dot,
.cursor-ring {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 1200;
  pointer-events: none;
  border-radius: 50%;
}

.cursor-dot {
  width: 7px;
  height: 7px;
  background: var(--sun);
  transform: translate(-50%, -50%);
}

.cursor-ring {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(217, 130, 43, 0.85);
  transform: translate(-50%, -50%);
  transition: width 0.18s ease, height 0.18s ease, border-color 0.18s ease, background 0.18s ease;
}

.cursor-ring.active {
  width: 54px;
  height: 54px;
  border-color: rgba(255, 122, 26, 0.9);
  background: rgba(255, 122, 26, 0.08);
}

.site-header {
  position: fixed;
  top: 16px;
  left: 50%;
  z-index: 900;
  width: fit-content;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 5px 8px;
  color: var(--white);
  background: rgba(42, 22, 12, 0.78);
  border: 1px solid rgba(217, 130, 43, 0.28);
  border-radius: 999px;
  backdrop-filter: blur(18px);
  box-shadow: 0 14px 42px rgba(18, 11, 7, 0.22);
  transform: translateX(-50%);
  transition: top 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.site-header.scrolled {
  top: 8px;
  background: rgba(42, 22, 12, 0.92);
  border-color: rgba(217, 130, 43, 0.4);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 4px 12px 4px 4px;
  background: transparent;
  border: 0;
  border-radius: 999px;
  font-family: "Mythbuster", var(--title);
  font-weight: normal;
  white-space: nowrap;
  transition: transform 0.2s ease, background 0.2s ease;
}

.logo:hover {
  background: rgba(217, 130, 43, 0.14);
  transform: translateY(-1px);
}

.logo-mark {
  width: 44px;
  height: 44px;
  display: block;
  flex-shrink: 0;
  object-fit: contain;
  border-radius: 50%;
  box-shadow: 0 0 24px rgba(255, 122, 26, 0.28);
  animation: logoPulse 3s ease-in-out infinite;
}

.footer-logo .logo-mark {
  width: 56px;
  height: 56px;
  box-shadow: 0 0 30px rgba(255, 122, 26, 0.32);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  background: rgba(217, 130, 43, 0.1);
  border: 1px solid rgba(217, 130, 43, 0.18);
  border-radius: 999px;
}

.main-nav a {
  position: relative;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  padding: 0 14px;
  color: rgba(255, 234, 210, 0.85);
  border-radius: 999px;
  font-size: 0.94rem;
  font-weight: 800;
  isolation: isolate;
  transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.main-nav a::before {
  display: none;
}

.main-nav a:hover,
.main-nav a.active {
  color: var(--white);
  background: rgba(217, 130, 43, 0.22);
  transform: translateY(-1px);
}

.main-nav a:last-child {
  color: var(--white);
  background: #d9822b;
  box-shadow: 0 6px 16px rgba(217, 130, 43, 0.32);
}

.main-nav a:last-child:hover,
.main-nav a:last-child.active {
  color: var(--white);
  background: #e8782a;
  box-shadow: 0 8px 20px rgba(232, 120, 42, 0.42);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-light);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.1);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: var(--white);
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.open span:nth-child(2) {
  opacity: 0;
}

.nav-toggle.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.hero,
.page-hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  overflow: hidden;
  color: var(--white);
  background: var(--black);
}

.page-hero {
  min-height: 64svh;
}

.hero-media,
.parallax-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 112%;
  object-fit: cover;
  will-change: transform;
  filter: saturate(1.08) contrast(1.02);
}

.hero-overlay,
.band-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(18, 11, 7, 0.08) 0%, rgba(18, 11, 7, 0.28) 42%, rgba(18, 11, 7, 0.9) 100%),
    linear-gradient(90deg, rgba(18, 11, 7, 0.88) 0%, rgba(74, 36, 14, 0.42) 48%, rgba(18, 11, 7, 0.18) 100%);
}

.hero::before,
.page-hero::before {
  content: "";
  position: absolute;
  right: -90px;
  bottom: 70px;
  z-index: 1;
  width: 300px;
  height: 300px;
  border: 18px solid rgba(217, 130, 43, 0.16);
  border-left-color: rgba(255, 122, 26, 0.26);
  border-radius: 50%;
  transform: rotate(-28deg);
  filter: drop-shadow(0 0 24px rgba(255, 122, 26, 0.12));
  animation: floatRing 7s ease-in-out infinite;
}

.animated-water {
  position: absolute;
  inset: auto 0 0;
  height: 34%;
  z-index: 1;
  background:
    linear-gradient(175deg, transparent 0%, rgba(255, 210, 122, 0.08) 42%, transparent 62%),
    linear-gradient(180deg, transparent, rgba(217, 130, 43, 0.2));
  mix-blend-mode: screen;
  animation: waterMove 9s ease-in-out infinite alternate;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 132px 0 86px;
}

.hero-content.compact {
  max-width: 980px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  color: var(--lime);
  font-size: 0.82rem;
  font-weight: 900;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 34px;
  height: 2px;
  background: currentColor;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--title);
  line-height: 0.96;
  letter-spacing: 0;
}

h1 {
  max-width: 920px;
  font-size: 6.4rem;
  text-transform: uppercase;
}

.hero-content h1 {
  font-family: "Mythbuster", var(--title);
  font-weight: normal;
  font-size: 13rem;
  letter-spacing: 0.02em;
}

.page-hero h1 {
  max-width: 820px;
  font-size: 4.6rem;
  text-transform: uppercase;
}

h2 {
  font-size: 3.7rem;
}

h3 {
  font-size: 1.55rem;
}

p {
  line-height: 1.68;
}

.hero-subtitle {
  width: fit-content;
  margin: 20px 0 0;
  padding: 0;
  color: rgba(255, 234, 210, 0.95);
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: 1.24rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 18px rgba(0, 0, 0, 0.45);
}

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

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 999px;
  font-weight: 900;
  cursor: pointer;
  isolation: isolate;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.34), transparent);
  transform: translateX(-115%);
  transition: transform 0.5s ease;
}

.btn:hover::after {
  transform: translateX(115%);
}

.btn:hover {
  transform: translateY(-3px);
}

.btn-primary {
  color: var(--white);
  background: #d9822b;
  box-shadow: 0 12px 26px rgba(217, 130, 43, 0.34);
}

.btn-primary:hover {
  background: #e8782a;
  box-shadow: 0 16px 34px rgba(232, 120, 42, 0.42);
}

.btn-ghost {
  color: var(--white);
  border-color: rgba(217, 130, 43, 0.65);
  background: rgba(74, 40, 21, 0.42);
  backdrop-filter: blur(14px);
}

.btn-ghost:hover {
  border-color: rgba(232, 120, 42, 0.9);
  background: rgba(74, 40, 21, 0.62);
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 24px;
  z-index: 4;
  width: 28px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.56);
  border-radius: 999px;
  transform: translateX(-50%);
}

.scroll-cue span {
  position: absolute;
  left: 50%;
  top: 10px;
  width: 5px;
  height: 5px;
  background: var(--white);
  border-radius: 50%;
  transform: translateX(-50%);
  animation: scrollCue 1.55s ease-in-out infinite;
}

.section {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 108px 0;
  isolation: isolate;
}

.section::before {
  display: none;
}

.section::after {
  content: "";
  position: absolute;
  left: -24px;
  top: 88px;
  z-index: -1;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(255, 122, 26, 0.1), transparent 70%);
  pointer-events: none;
}

.section-heading {
  position: relative;
  max-width: none;
  display: block;
  margin-bottom: 36px;
  padding-bottom: 0;
  border-bottom: 0;
}

.section-heading::after {
  display: none;
}

.section-heading .eyebrow {
  color: var(--lime);
}

.section-heading h2 {
  color: var(--cream-soft);
  max-width: 760px;
}

.card-grid {
  display: grid;
  gap: 20px;
}

.card-grid.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-card,
.event-card,
.menu-card,
.timeline-card,
.contact-panel,
.contact-form {
  border-radius: var(--radius);
  box-shadow: var(--shadow-clean);
}

.feature-card {
  position: relative;
  min-height: 450px;
  overflow: hidden;
  color: var(--white);
  background: var(--black);
  border: 1px solid rgba(255, 234, 210, 0.12);
  transition: transform 0.32s ease, box-shadow 0.32s ease;
}

.feature-card::before {
  display: none;
}

.feature-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 11, 7, 0.06) 10%, rgba(18, 11, 7, 0.9) 100%);
}

.feature-card img {
  width: 100%;
  height: 100%;
  min-height: 450px;
  object-fit: cover;
  transition: transform 0.72s ease, filter 0.3s ease;
}

.feature-card div {
  position: absolute;
  left: 28px;
  right: 28px;
  bottom: 28px;
  z-index: 3;
  padding: 22px;
  background: rgba(18, 11, 7, 0.52);
  border: 1px solid rgba(255, 234, 210, 0.12);
  border-radius: 18px;
  backdrop-filter: blur(12px);
}

.feature-card h3 {
  font-size: 2rem;
  text-transform: uppercase;
}

.feature-card p,
.event-card p,
.timeline-card p {
  color: rgba(255, 255, 255, 0.76);
}

.feature-card:hover,
.event-card:hover,
.menu-card:hover,
.timeline-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-pop);
}

.feature-card:hover img,
.mosaic-item:hover img,
.gallery-tile:hover img {
  transform: scale(1.08);
  filter: saturate(1.18) contrast(1.04);
}

.sunset-band,
.parallax-section {
  position: relative;
  min-height: 70svh;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: var(--white);
  background: var(--black);
}

.band-content {
  position: relative;
  z-index: 2;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  max-width: 780px;
}

.band-content h2 {
  text-transform: uppercase;
}

.band-content p:last-child {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.12rem;
}

.dark-slice {
  width: 100%;
  max-width: none;
  padding-inline: max(16px, calc((100% - 1180px) / 2));
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(255, 122, 26, 0.16), transparent 38%),
    linear-gradient(225deg, rgba(255, 210, 122, 0.08), transparent 42%),
    linear-gradient(180deg, #160d08, #2a160c);
  border-radius: 0;
}

.dark-slice .section-heading h2 {
  color: var(--white);
}

.dark-slice .section-heading .eyebrow {
  color: var(--lime);
}

.event-card {
  min-height: 290px;
  padding: 30px;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(217, 130, 43, 0.22), transparent 36%),
    linear-gradient(155deg, #24160f, #120b07);
  border: 1px solid rgba(255, 234, 210, 0.12);
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.event-card::after {
  display: none;
}

.event-card:hover {
  border-color: rgba(255, 122, 26, 0.6);
}

.event-card span,
.timeline-card span {
  display: inline-flex;
  margin-bottom: 46px;
  padding: 8px 10px;
  color: var(--black);
  background: var(--lime);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 900;
}

.mosaic-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.9fr 1fr;
  grid-auto-rows: 230px;
  gap: 16px;
}

.mosaic-item,
.gallery-tile {
  position: relative;
  overflow: hidden;
  border: 0;
  border-radius: var(--radius);
  background: var(--black);
  cursor: pointer;
  box-shadow: var(--shadow-clean);
}

.mosaic-item::after,
.gallery-tile::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 54%, rgba(18, 11, 7, 0.48));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.mosaic-item:hover::after,
.gallery-tile:hover::after {
  opacity: 1;
}

.mosaic-item.tall {
  grid-row: span 2;
}

.mosaic-item img,
.gallery-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.65s ease, filter 0.3s ease;
}

.site-footer {
  display: grid;
  grid-template-columns: 1.35fr repeat(3, 1fr);
  gap: 28px;
  padding: 58px max(16px, calc((100% - 1180px) / 2));
  color: rgba(255, 255, 255, 0.78);
  background: var(--black);
  border-top: 1px solid rgba(255, 234, 210, 0.14);
}

.site-footer h3 {
  margin: 0 0 14px;
  color: var(--white);
  font-size: 1rem;
}

.site-footer a,
.site-footer p {
  display: block;
  margin: 0 0 8px;
}

.site-footer a:hover {
  color: var(--lime);
}

.footer-logo {
  margin-bottom: 18px;
  color: var(--white);
}

.menu-section {
  display: grid;
  gap: 42px;
}

.menu-category {
  position: relative;
  padding: 0;
  background: transparent;
  border: 0;
  border-left: 0;
  border-radius: var(--radius);
  box-shadow: none;
}

.menu-category h2 {
  margin-bottom: 22px;
  text-transform: uppercase;
}

.menu-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.menu-card {
  min-height: 195px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 24px;
  color: var(--black);
  background: rgba(245, 215, 181, 0.92);
  border: 1px solid rgba(123, 63, 25, 0.16);
  border-bottom: 0;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.menu-card:hover {
  border-color: rgba(123, 63, 25, 0.48);
}

.menu-card h3 {
  text-transform: uppercase;
}

.menu-card p {
  color: var(--muted);
}

.menu-card strong {
  width: fit-content;
  padding: 8px 10px;
  color: var(--black);
  background: rgba(255, 122, 26, 0.18);
  border-radius: 999px;
  font-size: 1rem;
}

.timeline {
  display: grid;
  gap: 18px;
  position: relative;
}

.timeline::before {
  display: none;
}

.timeline-card {
  position: relative;
  display: grid;
  grid-template-columns: 172px 1fr;
  gap: 28px;
  padding: 28px;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(255, 122, 26, 0.18), transparent 34%),
    var(--black);
  border: 1px solid rgba(255, 234, 210, 0.12);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.timeline-card::before {
  display: none;
}

.timeline-card:hover {
  border-color: rgba(255, 122, 26, 0.58);
}

.timeline-card time {
  display: grid;
  place-items: center;
  min-height: 116px;
  color: var(--black);
  background: rgba(255, 234, 210, 0.86);
  border-radius: 18px;
  font-family: var(--title);
  font-weight: 900;
  text-align: center;
}

.timeline-card span {
  margin-bottom: 18px;
}

/* --- Griglia poster eventi --- */
.poster-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 340px));
  justify-content: center;
  gap: 28px;
}

.poster-card {
  position: relative;
  display: block;
  text-decoration: none;
  border-radius: var(--radius);
  overflow: hidden;
  aspect-ratio: 3 / 4;
  box-shadow: var(--shadow-pop);
  border: 1px solid rgba(255, 234, 210, 0.12);
  transition: transform 0.32s ease, box-shadow 0.32s ease, border-color 0.32s ease;
}

.poster-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.72s ease;
}

.poster-card .poster-info {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 48px 20px 20px;
  background: linear-gradient(to top, rgba(18, 11, 7, 0.9) 0%, transparent 100%);
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.poster-card time {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--lime);
}

.poster-card .poster-title {
  font-family: var(--title);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--cream-soft);
  margin: 0;
}

.poster-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 32px 64px rgba(18, 11, 7, 0.32);
  border-color: rgba(255, 122, 26, 0.5);
}

.poster-card:hover img {
  transform: scale(1.06);
}

.eventi-vuoti {
  grid-column: 1 / -1;
  text-align: center;
  color: var(--muted);
  font-size: 1.05rem;
  padding: 60px 0;
}

/* Pagina dedicata evento */
.evento-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: start;
}

.evento-locandina {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-pop);
  border: 1px solid rgba(255, 234, 210, 0.12);
}

.evento-locandina img {
  width: 100%;
  display: block;
}

.evento-dettagli {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 12px;
}

.evento-dettagli .eyebrow {
  color: var(--lime);
}

.evento-dettagli h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  color: var(--cream-soft);
  margin: 0;
}

.evento-dettagli .evento-data {
  font-size: 1rem;
  font-weight: 600;
  color: var(--cream);
  letter-spacing: 0.06em;
}

.evento-dettagli p {
  color: rgba(255, 255, 255, 0.76);
  line-height: 1.7;
  font-size: 1.05rem;
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--lime);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: opacity 0.2s ease;
}

.btn-back:hover {
  opacity: 0.7;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: 300px;
  gap: 18px;
}

.gallery-tile {
  padding: 0;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: grid;
  place-items: center;
  padding: 28px;
  background: rgba(18, 11, 7, 0.92);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.lightbox.open {
  opacity: 1;
  visibility: visible;
}

.lightbox img {
  max-height: 86svh;
  width: min(1100px, 100%);
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.44);
  transform: scale(0.96);
  transition: transform 0.25s ease;
}

.lightbox.open img {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: 22px;
  right: 22px;
  width: 44px;
  height: 44px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid var(--line-light);
  border-radius: var(--radius);
  cursor: pointer;
  font-size: 2rem;
  line-height: 1;
}

.contact-layout {
  display: grid;
  grid-template-columns: 0.92fr 1.08fr;
  gap: 24px;
  align-items: start;
}

.contact-panel,
.contact-form {
  padding: 30px;
  color: var(--black);
  background: var(--cream);
  border: 1px solid rgba(123, 63, 25, 0.16);
  border-top: 0;
}

.contact-panel {
  background: rgba(245, 215, 181, 0.94);
}

.big-link {
  display: inline-flex;
  margin: 24px 0 8px;
  color: var(--lake);
  font-family: var(--title);
  font-size: 2.8rem;
  font-weight: 900;
}

.contact-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.contact-chips span {
  padding: 9px 11px;
  color: var(--black);
  background: var(--lime);
  border-radius: 999px;
  font-weight: 900;
}

.contact-form {
  display: grid;
  gap: 12px;
}

.contact-form label {
  font-weight: 900;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line-dark);
  border-radius: 16px;
  padding: 14px 15px;
  color: var(--black);
  background: #fff0dd;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form input:focus,
.contact-form textarea:focus {
  border-color: var(--lake);
  box-shadow: 0 0 0 4px rgba(255, 122, 26, 0.18);
}

.contact-form textarea {
  resize: vertical;
}

.privacy-check {
  display: grid;
  grid-template-columns: 22px 1fr;
  gap: 10px;
  align-items: start;
  margin: 4px 0 8px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.45;
}

.privacy-check input {
  width: 18px;
  height: 18px;
  margin: 3px 0 0;
  accent-color: var(--lake);
}

.privacy-check span {
  display: block;
}

.form-note {
  min-height: 28px;
  margin: 0;
  color: var(--lake);
  font-weight: 800;
}

.map-section {
  position: relative;
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto 96px;
  overflow: hidden;
  border-radius: var(--radius);
  background: var(--black);
  box-shadow: var(--shadow-clean);
}

.map-section iframe {
  display: block;
  width: 100%;
  height: 430px;
  border: 0;
  background: rgba(18, 11, 7, 0.72);
}

.map-section iframe:not([src]) {
  display: none;
}

.map-consent {
  min-height: 430px;
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 14px;
  padding: 34px;
  color: var(--white);
  background:
    linear-gradient(135deg, rgba(255, 122, 26, 0.22), transparent 38%),
    linear-gradient(180deg, rgba(18, 11, 7, 0.9), rgba(42, 22, 12, 0.96));
}

.map-consent.hidden {
  display: none;
}

.map-consent h2 {
  max-width: 620px;
  color: var(--cream-soft);
}

.map-consent p:not(.eyebrow) {
  max-width: 620px;
  margin: 0;
  color: rgba(255, 255, 255, 0.78);
}

.legal-page {
  display: grid;
  gap: 20px;
}

.legal-block {
  padding: 30px;
  color: var(--black);
  background: rgba(245, 215, 181, 0.94);
  border: 1px solid rgba(123, 63, 25, 0.16);
  border-radius: var(--radius);
  box-shadow: var(--shadow-clean);
}

.legal-block h2 {
  margin-bottom: 18px;
  color: var(--black);
  font-size: 2.4rem;
  text-transform: uppercase;
}

.legal-block p {
  max-width: 880px;
  color: var(--muted);
}

.legal-block a {
  color: var(--lake);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.legal-block h3 {
  margin: 18px 0 8px;
  font-size: 1.05rem;
  color: var(--white);
}

.cookie-table-wrap {
  margin: 18px 0 8px;
  overflow-x: auto;
  border-radius: 12px;
  border: 1px solid rgba(255, 234, 210, 0.1);
}

.cookie-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  color: var(--muted);
  background: rgba(255, 234, 210, 0.04);
}

.cookie-table th,
.cookie-table td {
  padding: 12px 14px;
  text-align: left;
  border-bottom: 1px solid rgba(255, 234, 210, 0.08);
  vertical-align: top;
}

.cookie-table th {
  font-weight: 700;
  color: var(--white);
  background: rgba(255, 234, 210, 0.08);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.cookie-table tr:last-child td {
  border-bottom: 0;
}

.legal-note {
  margin: 8px 2px 0;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.55);
  font-style: italic;
}

.cookie-banner {
  position: fixed;
  left: 50%;
  bottom: 18px;
  z-index: 1300;
  width: min(980px, calc(100% - 28px));
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 22px;
  align-items: end;
  padding: 22px;
  color: var(--white);
  background: rgba(18, 11, 7, 0.94);
  border: 1px solid rgba(255, 234, 210, 0.18);
  border-radius: var(--radius);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.36);
  backdrop-filter: blur(16px);
  transform: translateX(-50%);
}

.cookie-banner h2 {
  max-width: 680px;
  margin-bottom: 10px;
  color: var(--cream-soft);
  font-size: 1.8rem;
  line-height: 1.05;
}

.cookie-banner p:not(.eyebrow) {
  max-width: 700px;
  margin: 0 0 10px;
  color: rgba(255, 255, 255, 0.78);
}

.cookie-banner a {
  color: var(--lime);
  font-weight: 900;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ai-chat {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1250;
  color: var(--white);
}

.ai-chat-toggle {
  width: 68px;
  height: 68px;
  display: grid;
  place-items: center;
  margin-left: auto;
  color: var(--black);
  background: var(--lime);
  border: 1px solid rgba(18, 11, 7, 0.18);
  border-radius: 50%;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
  cursor: pointer;
  font-weight: 900;
}

.ai-chat-panel {
  position: absolute;
  right: 0;
  bottom: 82px;
  width: min(390px, calc(100vw - 28px));
  overflow: hidden;
  background: rgba(18, 11, 7, 0.96);
  border: 1px solid rgba(255, 234, 210, 0.18);
  border-radius: var(--radius);
  box-shadow: 0 26px 76px rgba(0, 0, 0, 0.38);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
}

.ai-chat.open .ai-chat-panel {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.ai-chat-header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  padding: 18px 18px 14px;
  background:
    linear-gradient(135deg, rgba(255, 122, 26, 0.24), transparent 44%),
    rgba(255, 234, 210, 0.06);
  border-bottom: 1px solid rgba(255, 234, 210, 0.12);
}

.ai-chat-header .eyebrow {
  margin-bottom: 8px;
}

.ai-chat-header h2 {
  color: var(--cream-soft);
  font-size: 1.45rem;
}

.ai-chat-header button {
  width: 38px;
  height: 38px;
  color: var(--white);
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid var(--line-light);
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.5rem;
  line-height: 1;
}

.ai-chat-messages {
  height: 300px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
  overflow-y: auto;
}

.chat-message {
  max-width: 86%;
  padding: 11px 12px;
  border-radius: 8px;
  line-height: 1.45;
  font-size: 0.94rem;
}

.chat-message.bot {
  align-self: flex-start;
  color: var(--white);
  background: rgba(255, 255, 255, 0.1);
}

.chat-message.user {
  align-self: flex-end;
  color: var(--black);
  background: var(--cream-soft);
}

.ai-chat-form {
  display: grid;
  gap: 8px;
  padding: 14px;
  background: rgba(255, 234, 210, 0.06);
  border-top: 1px solid rgba(255, 234, 210, 0.12);
}

.ai-chat-form label {
  font-weight: 900;
}

.ai-chat-form div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.ai-chat-form input {
  min-width: 0;
  width: 100%;
  padding: 0 12px;
  color: var(--black);
  background: #fff0dd;
  border: 1px solid rgba(255, 234, 210, 0.18);
  border-radius: 8px;
  outline: none;
}

.ai-chat-form input:focus {
  border-color: var(--lime);
  box-shadow: 0 0 0 4px rgba(255, 210, 122, 0.18);
}

.ai-chat-form p {
  margin: 0;
  color: rgba(255, 255, 255, 0.64);
  font-size: 0.78rem;
  line-height: 1.4;
}

.reveal {
  opacity: 0;
  transition: opacity 0.75s ease, transform 0.75s ease;
}

/* Se GSAP non è ancora partito, i contenuti restano visibili invece di sparire */
html:not(.gsap-ready) .reveal {
  opacity: 1;
  transform: none;
  transition: none;
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

.slide-up {
  transform: translateY(36px);
}

.fade-in {
  transform: translateY(18px);
}

.zoom-in {
  transform: scale(0.94);
}

.delay-1 {
  transition-delay: 0.12s;
}

.delay-2 {
  transition-delay: 0.24s;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes logoPulse {
  0%, 100% {
    transform: rotate(0deg) scale(1);
  }
  50% {
    transform: rotate(-9deg) scale(1.06);
  }
}

@keyframes floatRing {
  0%, 100% {
    transform: translateY(0) rotate(-28deg);
  }
  50% {
    transform: translateY(-18px) rotate(-18deg);
  }
}

@keyframes waterMove {
  from {
    transform: translateY(0);
  }
  to {
    transform: translateY(18px);
  }
}

@keyframes scrollCue {
  0% {
    opacity: 0;
    transform: translate(-50%, 0);
  }
  45% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, 18px);
  }
}

@media (max-width: 980px) {
  .hero-media,
  .parallax-bg {
    height: 100%;
    will-change: auto;
  }

  .cursor-dot,
  .cursor-ring {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .main-nav {
    position: fixed;
    top: 74px;
    left: 10px;
    right: 10px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 8px;
    background: rgba(22, 10, 5, 0.97);
    border: 1px solid rgba(217, 130, 43, 0.35);
    border-radius: 20px;
    backdrop-filter: blur(24px);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 122, 26, 0.06) inset;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px) scale(0.98);
    transform-origin: top center;
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
  }

  .main-nav.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
  }

  .main-nav a {
    min-height: 52px;
    padding: 0 18px;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.01em;
    justify-content: flex-start;
    border-bottom: none;
  }

  .main-nav a:last-of-type {
    margin-bottom: 2px;
  }

  .main-nav a:last-child {
    background: rgba(217, 130, 43, 0.14);
    box-shadow: none;
  }

  .main-nav a:last-child:hover,
  .main-nav a:last-child.active {
    background: rgba(217, 130, 43, 0.25);
    box-shadow: none;
  }

  h1 {
    font-size: 4.4rem;
  }

  .page-hero h1 {
    font-size: 3.4rem;
  }

  h2 {
    font-size: 3rem;
  }

  .card-grid.three,
  .menu-grid,
  .gallery-grid,
  .contact-layout,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .evento-layout {
    grid-template-columns: 1fr;
  }

  .cookie-banner {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .ai-chat {
    right: 14px;
    bottom: 14px;
  }

  .mosaic-grid {
    grid-template-columns: 1fr 1fr;
  }

  .timeline-card {
    grid-template-columns: 1fr;
  }

  .section-heading {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .section-heading::after {
    justify-self: start;
  }

  .timeline::before,
  .timeline-card::before {
    display: none;
  }

  .timeline-card time {
    min-height: 82px;
  }
}

@media (max-width: 620px) {
  .site-header {
    top: 10px;
    width: calc(100% - 20px);
  }

  .logo span:last-child {
    max-width: 170px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .hero,
  .page-hero {
    min-height: 92svh;
  }

  .page-hero {
    min-height: 58svh;
  }

  .hero::before,
  .page-hero::before {
    right: -170px;
    width: 270px;
    height: 270px;
  }

  .hero-content {
    width: calc(100% - 28px);
    padding-bottom: 74px;
  }

  h1 {
    font-size: 3.15rem;
  }

  .hero-content h1 {
    font-size: clamp(3.2rem, 22vw, 8rem);
  }

  .page-hero h1 {
    font-size: 2.55rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .hero-subtitle {
    font-size: 1.04rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .section {
    width: calc(100% - 28px);
    padding: 76px 0;
  }

  .section::before {
    top: 42px;
  }

  .section::after {
    display: none;
  }

  .section-heading {
    margin-bottom: 28px;
    padding-bottom: 20px;
  }

  .feature-card,
  .feature-card img {
    min-height: 365px;
  }

  .mosaic-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
    grid-auto-rows: 260px;
  }

  .mosaic-item.tall {
    grid-row: span 1;
  }

  .contact-panel,
  .contact-form {
    padding: 22px;
  }

  .menu-category {
    padding: 22px;
  }

  .big-link {
    font-size: 2rem;
  }

  .site-footer {
    padding: 42px 16px;
  }

  .map-consent,
  .legal-block,
  .cookie-banner {
    padding: 22px;
  }

  .cookie-banner {
    bottom: 10px;
    max-height: calc(100svh - 20px);
    overflow: auto;
  }

  .cookie-actions {
    display: grid;
    width: 100%;
  }

  .cookie-actions .btn {
    width: 100%;
  }

  .ai-chat {
    left: 10px;
    right: 10px;
    bottom: 10px;
  }

  .ai-chat-toggle {
    width: 62px;
    height: 62px;
  }

  .ai-chat-panel {
    right: 0;
    bottom: 76px;
    width: 100%;
    max-height: calc(100svh - 96px);
  }

  .ai-chat-messages {
    height: min(300px, 42svh);
  }

  .ai-chat-form div {
    grid-template-columns: 1fr;
  }

  .legal-block h2,
  .cookie-banner h2 {
    font-size: 1.65rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
