:root {
  --red: #e30613;
  --red-dark: #b4000a;
  --black: #0d0d0d;
  --ink: #151515;
  --cream: #f4f0e8;
  --paper: #fbfaf7;
  --white: #fff;
  --muted: #77736b;
  --line: rgba(13,13,13,.16);
  --radius: 26px;
  --pad: clamp(20px, 5vw, 72px);
  --header-h: 82px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Manrope", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
  overflow-x: hidden;
}
body.menu-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
::selection { background: var(--red); color: #fff; }

.noise {
  position: fixed;
  inset: 0;
  z-index: 9998;
  pointer-events: none;
  opacity: .025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 3; overflow: hidden; }
.confetti i {
  position: absolute;
  width: 7px;
  height: 18px;
  opacity: 0;
  animation: confettiFall linear forwards;
  border-radius: 2px;
}
@keyframes confettiFall {
  0% { opacity: 0; transform: translate3d(0,-10vh,0) rotate(0deg); }
  10% { opacity: .7; }
  100% { opacity: 0; transform: translate3d(var(--drift),110vh,0) rotate(720deg); }
}

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--header-h);
  padding: 0 var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 100;
  color: #fff;
  transition: background .35s ease, color .35s ease, border .35s ease, height .35s ease;
}
.site-header.scrolled {
  height: 68px;
  color: var(--ink);
  background: rgba(251,250,247,.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(0,0,0,.08);
}
.brand { display: inline-flex; align-items: center; gap: 11px; position: relative; z-index: 102; }
.brand-mark {
  width: 42px; height: 42px;
  border: 2px solid currentColor;
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: "Bebas Neue", sans-serif;
  font-size: 26px;
  line-height: 1;
}
.brand-copy { display: grid; line-height: 1; gap: 4px; }
.brand-copy strong { font-family: "Bebas Neue", sans-serif; font-size: 21px; letter-spacing: .07em; font-weight: 400; }
.brand-copy small { font-size: 8px; letter-spacing: .2em; font-weight: 800; }

.main-nav { display: flex; align-items: center; gap: clamp(20px, 2.5vw, 40px); font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .06em; }
.main-nav a { position: relative; }
.main-nav a::after { content: ""; position: absolute; left: 0; bottom: -7px; width: 100%; height: 2px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .2s ease; }
.main-nav a:hover::after { transform: scaleX(1); }
.menu-toggle { display: none; border: 0; background: transparent; color: inherit; width: 48px; height: 48px; padding: 0; position: relative; z-index: 102; }
.menu-toggle span { position: absolute; width: 24px; height: 2px; background: currentColor; left: 12px; transition: transform .25s ease, top .25s ease; }
.menu-toggle span:first-child { top: 19px; }
.menu-toggle span:last-child { top: 28px; }
.menu-toggle.active span:first-child { top: 24px; transform: rotate(45deg); }
.menu-toggle.active span:last-child { top: 24px; transform: rotate(-45deg); }

.hero { position: relative; min-height: 100svh; color: #fff; display: flex; align-items: flex-end; overflow: hidden; background: #111; }
.hero-photo {
  position: absolute; inset: 0;
  background-image: url("https://carnevalecavaglia.wordpress.com/wp-content/uploads/2025/02/img_5497-1.jpg");
  background-size: cover;
  background-position: center 40%;
  transform: scale(1.04);
  animation: heroZoom 10s ease-out forwards;
}
@keyframes heroZoom { to { transform: scale(1); } }
.hero-shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.2) 0%, rgba(0,0,0,.12) 35%, rgba(0,0,0,.86) 100%), linear-gradient(90deg, rgba(0,0,0,.42), transparent 65%);
}
.hero-content { position: relative; z-index: 2; width: min(1100px, 100%); padding: 0 var(--pad) clamp(88px, 10vh, 130px); }
.eyebrow { margin: 0 0 18px; font-size: 11px; font-weight: 800; letter-spacing: .2em; text-transform: uppercase; }
.eyebrow.dark { color: var(--red); }
.hero h1, .display, .edition-year, footer h2 { font-family: "Bebas Neue", Impact, sans-serif; font-weight: 400; letter-spacing: -.025em; }
.hero h1 { margin: 0; font-size: clamp(78px, 13vw, 180px); line-height: .76; max-width: 1050px; }
.hero h1 span { color: var(--red); }
.hero-lead { margin: 28px 0 0; max-width: 650px; font-size: clamp(16px, 1.5vw, 21px); line-height: 1.55; color: rgba(255,255,255,.84); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.btn { min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 20px; padding: 0 22px; border-radius: 999px; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; transition: transform .2s ease, background .2s ease, color .2s ease; }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: #ff1320; }
.btn-ghost { border: 1px solid rgba(255,255,255,.55); color: #fff; }
.btn-ghost:hover { background: #fff; color: #111; }
.hero-scroll { position: absolute; right: var(--pad); bottom: 38px; z-index: 2; display: flex; align-items: center; gap: 12px; font-size: 9px; font-weight: 800; letter-spacing: .2em; transform: rotate(90deg) translateX(-15px); transform-origin: right bottom; }
.hero-scroll i { display: block; width: 54px; height: 1px; background: rgba(255,255,255,.7); position: relative; overflow: hidden; }
.hero-scroll i::after { content:""; position:absolute; inset:0; background:#fff; transform:translateX(-100%); animation: scrollLine 1.7s ease-in-out infinite; }
@keyframes scrollLine { 50%,100% { transform: translateX(100%); } }

.ticker { background: var(--red); color:#fff; overflow:hidden; border-top:1px solid rgba(255,255,255,.18); border-bottom:1px solid rgba(0,0,0,.12); }
.ticker-track { display:flex; align-items:center; width:max-content; gap:20px; padding:17px 0; animation:ticker 35s linear infinite; }
.ticker span { font-family:"Bebas Neue",sans-serif; font-size:22px; letter-spacing:.04em; white-space:nowrap; }
.ticker b { font-size:11px; font-weight:400; opacity:.8; }
@keyframes ticker { to { transform:translateX(-50%); } }

.section { padding: clamp(90px, 11vw, 160px) var(--pad); }
.section-number { font-family:"Bebas Neue",sans-serif; font-size:16px; letter-spacing:.08em; color:var(--red); border-top:1px solid var(--line); padding-top:12px; width:64px; }
.section-number.inverse { color:#fff; border-color:rgba(255,255,255,.35); }
.intro { display:grid; grid-template-columns:90px minmax(0, 1.2fr) minmax(280px,.8fr); gap:clamp(24px,5vw,84px); align-items:start; }
.display { margin:0; font-size:clamp(64px,8.5vw,130px); line-height:.83; }
.display em { color:var(--red); font-style:normal; }
.intro-text { padding-top:40px; max-width:520px; }
.intro-text p { font-size:16px; line-height:1.78; color:#45413b; margin:0 0 18px; }
.text-link { display:inline-flex; align-items:center; gap:18px; margin-top:12px; font-size:12px; font-weight:800; text-transform:uppercase; letter-spacing:.07em; border-bottom:1px solid var(--ink); padding-bottom:7px; }
.text-link span { transition: transform .2s ease; }
.text-link:hover span { transform:translateX(5px); }

.stats { display:grid; grid-template-columns:repeat(3,1fr); border-top:1px solid var(--line); border-bottom:1px solid var(--line); margin:0 var(--pad); }
.stat { padding:46px clamp(18px,3vw,44px); display:grid; gap:10px; border-right:1px solid var(--line); }
.stat:last-child { border-right:0; }
.stat strong { font-family:"Bebas Neue",sans-serif; color:var(--red); font-size:clamp(60px,7vw,110px); line-height:.85; font-weight:400; }
.stat span { color:var(--muted); font-size:12px; text-transform:uppercase; letter-spacing:.08em; font-weight:800; }

.section-dark { background:var(--black); color:#fff; }
.section-dark .section-number { border-color:rgba(255,255,255,.18); }
.tradition-grid { display:grid; grid-template-columns:minmax(320px,.85fr) minmax(0,1.15fr); gap:clamp(40px,7vw,110px); align-items:center; margin-top:38px; }
.tradition-copy .display em { color:var(--red); }
.tradition-copy > p:not(.eyebrow) { max-width:520px; line-height:1.75; color:rgba(255,255,255,.7); font-size:16px; }
.tradition-photo { min-height:650px; border-radius:var(--radius); background:linear-gradient(180deg,transparent 65%,rgba(0,0,0,.3)), url("https://carnevalecavaglia.wordpress.com/wp-content/uploads/2024/03/img_4188.jpg"); background-size:cover; background-position:center; position:relative; overflow:hidden; }
.tradition-photo::after { content:"60+\A PA IOLI"; white-space:pre; position:absolute; right:-2px; bottom:-12px; font-family:"Bebas Neue",sans-serif; font-size:76px; line-height:.73; text-align:right; color:#fff; opacity:.9; padding:20px; }

.section-head { display:grid; grid-template-columns:1fr minmax(280px,460px); gap:50px; align-items:end; margin-bottom:54px; }
.section-note { margin:0 0 8px; color:var(--muted); line-height:1.7; }
.mosaic { display:grid; grid-template-columns:repeat(12,1fr); gap:16px; }
.moment { position:relative; min-height:520px; overflow:hidden; border-radius:22px; grid-column:span 5; background:#222; color:#fff; isolation:isolate; }
.moment-large { grid-column:span 7; min-height:640px; }
.moment-wide { grid-column:span 7; min-height:480px; }
.moment img { width:100%; height:100%; object-fit:cover; position:absolute; inset:0; transition:transform .6s cubic-bezier(.2,.7,.2,1); }
.moment::after { content:""; position:absolute; inset:0; background:linear-gradient(180deg,transparent 40%,rgba(0,0,0,.9)); z-index:0; }
.moment:hover img { transform:scale(1.035); }
.moment div { position:absolute; z-index:1; left:0; right:0; bottom:0; padding:28px; }
.moment div span { font-size:10px; font-weight:800; letter-spacing:.15em; color:#fff; opacity:.75; }
.moment h3 { font-family:"Bebas Neue",sans-serif; font-size:42px; margin:6px 0 2px; font-weight:400; }
.moment p { margin:0; max-width:480px; color:rgba(255,255,255,.75); line-height:1.55; font-size:13px; }

.section-red { background:var(--red); color:#fff; }
.edition-top { display:flex; align-items:flex-start; justify-content:space-between; }
.edition-grid { display:grid; grid-template-columns:1.1fr .9fr; gap:clamp(40px,8vw,120px); align-items:end; margin-top:30px; }
.edition-year { margin:0; font-size:clamp(170px,27vw,420px); line-height:.7; letter-spacing:-.04em; }
.edition-status { margin:32px 0 0; display:flex; align-items:center; gap:10px; font-size:11px; font-weight:800; letter-spacing:.12em; }
.edition-status span { width:9px; height:9px; background:#fff; border-radius:50%; box-shadow:0 0 0 7px rgba(255,255,255,.16); animation:pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { box-shadow:0 0 0 14px rgba(255,255,255,0); } }
.edition-copy { padding-bottom:18px; }
.edition-copy h3 { font-family:"Bebas Neue",sans-serif; font-size:48px; font-weight:400; margin:0 0 12px; }
.edition-copy p { color:rgba(255,255,255,.82); line-height:1.7; margin:0 0 24px; }
.edition-tags { display:flex; flex-wrap:wrap; gap:8px; }
.edition-tags span { border:1px solid rgba(255,255,255,.5); padding:9px 13px; border-radius:999px; font-size:10px; font-weight:800; text-transform:uppercase; letter-spacing:.07em; }
.past-edition { display:grid; grid-template-columns:auto auto 1fr; gap:24px; align-items:center; border-top:1px solid rgba(255,255,255,.35); margin-top:80px; padding-top:24px; }
.past-edition span { font-size:9px; font-weight:800; letter-spacing:.18em; opacity:.7; }
.past-edition strong { font-family:"Bebas Neue",sans-serif; font-size:27px; letter-spacing:.03em; font-weight:400; }
.past-edition p { margin:0; text-align:right; opacity:.75; font-size:12px; }

.ritual { display:grid; grid-template-columns:90px 1fr; gap:clamp(24px,5vw,84px); }
.ritual-head { grid-column:2; }
.steps { grid-column:2; margin-top:70px; border-top:1px solid var(--line); }
.step { display:grid; grid-template-columns:80px 1fr 1fr; gap:30px; align-items:center; min-height:126px; border-bottom:1px solid var(--line); padding:22px 0; }
.step > span { color:var(--red); font-size:11px; font-weight:800; }
.step h3 { font-family:"Bebas Neue",sans-serif; font-size:34px; margin:0; font-weight:400; }
.step p { margin:0; color:var(--muted); line-height:1.6; font-size:13px; max-width:520px; }

.cta-band { background:var(--black); color:#fff; }
.cta-band a { min-height:230px; padding:40px var(--pad); display:grid; grid-template-columns:1fr auto auto; gap:40px; align-items:center; transition:background .25s ease; }
.cta-band a:hover { background:#171717; }
.cta-band span { font-size:11px; font-weight:800; letter-spacing:.2em; }
.cta-band strong { font-family:"Bebas Neue",sans-serif; font-size:clamp(64px,9vw,130px); font-weight:400; color:var(--red); }
.cta-band i { width:72px; height:72px; border:1px solid rgba(255,255,255,.35); border-radius:50%; display:grid; place-items:center; font-style:normal; font-size:24px; transition:transform .25s ease, background .25s ease; }
.cta-band a:hover i { transform:rotate(45deg); background:var(--red); border-color:var(--red); }

footer { background:#080808; color:#fff; padding:90px var(--pad) 28px; }
.footer-main { display:grid; grid-template-columns:1fr 1fr; gap:70px; padding-bottom:70px; }
.footer-kicker { margin:0 0 8px; font-size:10px; font-weight:800; letter-spacing:.2em; color:rgba(255,255,255,.45); }
footer h2 { margin:0; font-size:clamp(86px,12vw,180px); line-height:.8; color:var(--red); }
.footer-links { display:grid; grid-template-columns:repeat(2,1fr); gap:40px; align-content:end; }
.footer-links div { display:grid; gap:9px; }
.footer-links div:last-child { grid-column:span 2; grid-template-columns:auto auto; justify-content:start; column-gap:24px; }
.footer-links div:last-child span { grid-column:1/-1; }
.footer-links span { font-size:9px; font-weight:800; letter-spacing:.18em; color:rgba(255,255,255,.4); }
.footer-links a { font-size:13px; line-height:1.65; width:max-content; max-width:100%; color:rgba(255,255,255,.83); }
.footer-links a:hover { color:#fff; }
.footer-bottom { border-top:1px solid rgba(255,255,255,.12); padding-top:22px; display:flex; justify-content:space-between; gap:20px; font-size:9px; font-weight:700; letter-spacing:.08em; color:rgba(255,255,255,.4); text-transform:uppercase; }

.reveal { opacity:0; transform:translateY(26px); transition:opacity .75s cubic-bezier(.2,.7,.2,1), transform .75s cubic-bezier(.2,.7,.2,1); }
.reveal.visible { opacity:1; transform:none; }

@media (max-width: 980px) {
  :root { --header-h:72px; }
  .menu-toggle { display:block; }
  .main-nav {
    position:fixed; inset:0; background:var(--red); color:#fff;
    display:flex; flex-direction:column; align-items:flex-start; justify-content:center;
    padding:100px var(--pad) 60px; gap:5px;
    transform:translateY(-100%); transition:transform .45s cubic-bezier(.76,0,.24,1);
  }
  .main-nav.open { transform:none; }
  .main-nav a { font-family:"Bebas Neue",sans-serif; font-size:clamp(44px,11vw,76px); font-weight:400; line-height:1.02; }
  .main-nav a::after { display:none; }
  .site-header.menu-active { color:#fff; background:transparent; border:0; }
  .hero-photo { background-position:center center; }
  .intro { grid-template-columns:60px 1fr; }
  .intro-text { grid-column:2; padding-top:10px; }
  .tradition-grid { grid-template-columns:1fr; }
  .tradition-photo { min-height:520px; }
  .section-head { grid-template-columns:1fr; }
  .section-note { max-width:560px; }
  .moment, .moment-large, .moment-wide { grid-column:span 6; min-height:500px; }
  .edition-grid { grid-template-columns:1fr; }
  .edition-copy { max-width:600px; }
  .past-edition { grid-template-columns:1fr 1fr; }
  .past-edition p { grid-column:1/-1; text-align:left; }
  .footer-main { grid-template-columns:1fr; }
}

@media (max-width: 700px) {
  :root { --pad:20px; --radius:20px; }
  .site-header { padding:0 18px; }
  .brand-copy strong { font-size:18px; }
  .brand-copy small { font-size:7px; }
  .brand-mark { width:38px; height:38px; font-size:23px; }
  .hero { min-height: 96svh; }
  .hero-photo { background-position:52% center; }
  .hero-shade { background:linear-gradient(180deg,rgba(0,0,0,.18),rgba(0,0,0,.2) 38%,rgba(0,0,0,.9) 100%); }
  .hero-content { padding:0 20px 84px; }
  .hero h1 { font-size:clamp(74px,25vw,120px); line-height:.78; }
  .hero-lead { font-size:15px; line-height:1.55; margin-top:20px; }
  .hero-actions { gap:8px; margin-top:24px; }
  .btn { min-height:48px; padding:0 18px; font-size:10px; }
  .btn-ghost { display:none; }
  .hero-scroll { display:none; }
  .ticker-track { padding:13px 0; }
  .ticker span { font-size:19px; }
  .section { padding:82px 20px; }
  .intro { grid-template-columns:1fr; gap:20px; }
  .section-number { width:48px; }
  .intro-copy, .intro-text { grid-column:1; }
  .display { font-size:clamp(58px,19vw,90px); }
  .intro-text { padding-top:10px; }
  .intro-text p { font-size:15px; }
  .stats { margin:0; grid-template-columns:1fr; }
  .stat { border-right:0; border-bottom:1px solid var(--line); padding:30px 20px; grid-template-columns:115px 1fr; align-items:end; }
  .stat:last-child { border-bottom:0; }
  .stat strong { font-size:70px; }
  .stat span { padding-bottom:7px; }
  .tradition-grid { margin-top:28px; }
  .tradition-photo { min-height:440px; }
  .tradition-photo::after { font-size:54px; }
  .mosaic { display:flex; gap:12px; overflow-x:auto; scroll-snap-type:x mandatory; padding-bottom:10px; margin-right:-20px; padding-right:20px; scrollbar-width:none; }
  .mosaic::-webkit-scrollbar { display:none; }
  .moment, .moment-large, .moment-wide { min-width:84vw; min-height:480px; scroll-snap-align:start; }
  .moment div { padding:22px; }
  .moment h3 { font-size:38px; }
  .edition-top { display:block; }
  .edition-top .eyebrow { margin-top:32px; }
  .edition-year { font-size:45vw; }
  .edition-status { margin-top:22px; font-size:9px; }
  .edition-copy h3 { font-size:40px; }
  .past-edition { margin-top:60px; grid-template-columns:1fr; gap:8px; }
  .past-edition p { grid-column:auto; }
  .ritual { grid-template-columns:1fr; gap:20px; }
  .ritual-head, .steps { grid-column:1; }
  .steps { margin-top:35px; }
  .step { grid-template-columns:44px 1fr; gap:12px 16px; padding:24px 0; }
  .step p { grid-column:2; }
  .cta-band a { min-height:180px; padding:32px 20px; grid-template-columns:1fr auto; gap:20px; }
  .cta-band span { grid-column:1/-1; }
  .cta-band strong { font-size:72px; }
  .cta-band i { width:54px; height:54px; }
  footer { padding:72px 20px 24px; }
  .footer-main { gap:50px; padding-bottom:52px; }
  footer h2 { font-size:31vw; }
  .footer-links { grid-template-columns:1fr; gap:28px; }
  .footer-links div:last-child { grid-column:1; }
  .footer-bottom { flex-direction:column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior:auto; }
  *, *::before, *::after { animation-duration:.001ms !important; animation-iteration-count:1 !important; transition-duration:.001ms !important; }
  .reveal { opacity:1; transform:none; }
}
