/* Natale dell'Imperatore: original branding, with the clear editorial rhythm of the reference. */
@font-face{font-family:ChristmasSans;src:url('assets/fonts/montserrat-300.ttf') format('truetype');font-weight:300;font-display:swap}
@font-face{font-family:ChristmasSans;src:url('assets/fonts/montserrat-400.ttf') format('truetype');font-weight:400;font-display:swap}
@font-face{font-family:ChristmasSans;src:url('assets/fonts/montserrat-500.ttf') format('truetype');font-weight:500;font-display:swap}
@font-face{font-family:ChristmasSans;src:url('assets/fonts/montserrat-600.ttf') format('truetype');font-weight:600;font-display:swap}
@font-face{font-family:ChristmasSans;src:url('assets/fonts/montserrat-700.ttf') format('truetype');font-weight:700;font-display:swap}
:root {
  --title-family: ChristmasSans, Montserrat, Arial, sans-serif;
  --section-title-size: clamp(30px, 3.1vw, 46px);
  --card-title-size: clamp(21px, 2vw, 27px);
  --poster-red: #84171d;
  --poster-cream: #fff;
  --poster-copy: #fff;
  --poster-gold: #e3cfa7;
  --poster-line: #ffffff4d;
  --header-cream: #f9f5ec;
  --site-header-height: 104px;
  --page-gutter: max(32px, calc((100vw - 1244px) / 2));
}
body { font-family: ChristmasSans, Montserrat, Arial, sans-serif; background: #fff; color: var(--poster-red); line-height: 1.65; }
body::before { display: none; }
body .header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 7px;
  position: sticky;
  top: 0;
  height: 104px;
  min-height: 0;
  padding: 0 28px;
  background: var(--header-cream);
  border: 0;
  border-bottom: 1px solid var(--poster-gold);
  box-shadow: none;
  z-index: 80;
}
body[data-page="villaggio"] .header {
  position: fixed;
  inset: 0 0 auto;
  visibility: hidden;
  transform: translateY(-100%);
  transition: transform .22s ease;
}
body[data-page="villaggio"] .header.header-visible { visibility: visible; transform: translateY(0); }
body .header .header-logo {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  width: max-content;
  max-width: 100%;
  padding: 0 6px;
  overflow: visible;
  border-radius: 0;
  background: transparent;
}
body .header .header-logo img { width: auto; height: 78px; max-height: none; object-fit: contain; object-position: left center; }
body .header button.header-action,
body .header .header-action.nav-advent {
  grid-row: 1;
  width: auto;
  min-width: 44px;
  height: 44px;
  min-height: 44px;
  padding: 0 12px;
  gap: 5px;
  border: 1px solid var(--poster-red);
  border-radius: 999px;
  color: var(--poster-red);
  background: transparent;
  text-transform: uppercase;
}
body .header button.menu-toggle { grid-column: 3; justify-self: end; width: 44px; padding: 0; border-color: transparent; }
body .header .header-action.nav-advent { grid-column: 2; justify-self: end; height: 38px; min-height: 38px; }
body .header .nav-advent .header-action-label { font-family: ChristmasSans, Arial, sans-serif; font-size: 11px; font-weight: 700; letter-spacing: .3px; }
body .header button.menu-toggle .menu-toggle-icon { width: 20px; }
body .header button.menu-toggle .menu-toggle-icon i { width: 20px; height: 2px; background: var(--poster-red); }
body .header .header-action:hover,
body .header .header-action[aria-expanded="true"] { background: var(--poster-gold); color: var(--poster-red); }
body .header nav {
  position: absolute;
  grid-column: auto;
  left: auto;
  right: 28px;
  top: 100%;
  display: none;
  width: 430px;
  max-width: calc(100vw - 56px);
  max-height: calc(100svh - var(--site-header-height) - 12px);
  padding: 26px 32px;
  background: #fff;
  color: var(--poster-red);
  border: 1px solid var(--poster-gold);
  border-radius: 0;
  box-shadow: 0 16px 35px #361b1824;
  font-family: ChristmasSans, Arial, sans-serif;
  font-style: normal;
  font-size: 16px;
  line-height: 1.4;
  gap: 0;
}
body .header nav.open { display: flex; }
body .header nav > a {
  min-height: 48px;
  padding: 12px 0;
  border-bottom: 1px solid var(--poster-gold);
  color: var(--poster-red);
  text-transform: uppercase;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .3px;
}
body .header nav > a:hover,
body .header nav > a[aria-current] { color: var(--poster-red); text-decoration: underline; text-underline-offset: 7px; }
body :is(a, button, summary):focus-visible { outline: 3px solid var(--poster-red); outline-offset: 4px; }
body .home-surface :is(a, button):focus-visible { outline-color: var(--header-cream); }

.home-surface {
  background: var(--poster-red) url('assets/mobile/trama-natale-2026.webp') center / cover no-repeat;
  color: #fff;
  scroll-margin-top: var(--site-header-height);
}
body[data-page="villaggio"] .home-surface .home-stage {
  gap: clamp(18px, 2.6vh, 26px);
  max-width: none;
  min-height: 100svh;
  padding: 14px 24px 32px;
  color: #fff;
}
body[data-page="villaggio"] .home-surface .home-poster {
  position: relative;
  container-type: inline-size;
  width: min(100%, 1200px, calc(80svh - 24px));
  background: none;
}
body[data-page="villaggio"] .home-surface .home-poster > a { border-radius: 0; }
body[data-page="villaggio"] .home-surface .home-poster > a:hover { transform: none; filter: none; }
body[data-page="villaggio"] .home-surface .home-poster img { filter: drop-shadow(0 15px 35px #40120c33); }
/* Fit the live countdown into the existing cream panel of the official poster. */
body[data-page="villaggio"] .home-surface .home-countdown {
  position: absolute;
  inset: 74.5% 1.8% 14.3% 45.25%;
  z-index: 1;
  display: grid;
  place-items: center;
  width: auto;
  max-width: none;
  background: #f8ebd8;
  color: var(--poster-red);
  pointer-events: none;
}
body[data-page="villaggio"] .home-surface .home-countdown::before { display: none; }
body[data-page="villaggio"] .home-surface .countdown-clock { max-width: none; }
body[data-page="villaggio"] .home-surface .countdown-clock > div { align-items: center; min-height: 0; padding: 0 2px; }
body[data-page="villaggio"] .home-surface .countdown-clock > div + div { border-color: #84171d42; }
body[data-page="villaggio"] .home-surface .countdown-clock strong {
  font-family: ChristmasSans, Arial, sans-serif;
  font-size: clamp(19px, 4vw, 42px);
  font-size: clamp(19px, 7.3cqw, 88px);
  font-weight: 650;
  color: inherit;
  letter-spacing: -.035em;
}
body[data-page="villaggio"] .home-surface .countdown-clock span {
  margin-top: 3px;
  margin-top: .55cqw;
  font-size: clamp(7px, 1.3vw, 12px);
  font-size: clamp(7px, 2.23cqw, 24px);
  font-weight: 650;
  letter-spacing: .04em;
  color: inherit;
  text-transform: uppercase;
}
body[data-page="villaggio"] .home-surface .countdown-phase {
  margin: 0;
  padding: 0 3%;
  font-size: clamp(11px, 2.5vw, 24px);
  font-size: clamp(11px, 3.8cqw, 40px);
  line-height: 1.2;
  color: inherit;
}
body[data-page="villaggio"] .home-surface .entry-record-toggle {
  display: block;
  position: relative;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--poster-red);
  cursor: pointer;
}
body[data-page="villaggio"] .home-surface .entry-record-toggle:disabled { opacity: .6; cursor: wait; }
body[data-page="villaggio"] .home-surface .entry-record-toggle .record {
  --home-record-size: clamp(96px, 10vw, 114px);
  width: var(--home-record-size);
  height: var(--home-record-size);
  animation: vinyl-turn 18s linear infinite paused;
}
body[data-page="villaggio"] .home-surface .record-label { width: 50%; height: 50%; }
body[data-page="villaggio"].soundtrack-playing .home-surface .entry-record-toggle .record { animation-play-state: running; }
body[data-page="villaggio"] .home-surface .entry-record-control {
  position: absolute;
  right: -2px;
  bottom: -2px;
  display: grid;
  place-items: center;
  width: 33px;
  height: 33px;
  border: 1px solid var(--poster-red);
  border-radius: 50%;
  background: var(--header-cream);
  color: var(--poster-red);
  font-family: Arial, sans-serif;
  font-size: 14px;
  font-weight: 700;
  line-height: 1;
}
@media (min-width: 1600px) {
  body .header { padding-inline: max(28px, calc((100vw - 1440px) / 2)); }
}
@media (max-width: 800px) {
  :root { --page-gutter: 24px; --site-header-height: 88px; }
  body .header { height: 88px; padding-inline: 20px; }
  body .header .header-logo { padding-inline: 5px; }
  body .header .header-logo img { height: 66px; }
  body .header nav { right: 20px; max-width: calc(100vw - 40px); }
}
@media (max-width: 650px) and (orientation: portrait) {
  body[data-page="villaggio"] .home-surface .home-stage {
    padding: max(8px, env(safe-area-inset-top)) max(6px, env(safe-area-inset-right)) 28px max(6px, env(safe-area-inset-left));
  }
  body[data-page="villaggio"] .home-surface .home-poster { width: 100%; }
  body[data-page="villaggio"] .home-poster > a:focus-visible { outline-offset: -4px; }
}
@media (max-width: 420px) {
  body .header { padding-inline: 12px; }
  body .header nav { right: 12px; left: 12px; width: auto; max-width: none; padding: 20px 24px; }
}
@media (max-width: 360px) {
  body .header { padding-inline: 8px; gap: 5px; }
  body .header .header-logo img { height: 60px; }
}
@media (prefers-reduced-motion: reduce) {
  body[data-page="villaggio"] .header { transition: none; }
  body[data-page="villaggio"] .home-surface .entry-record-toggle .record { animation: none; }
}
