/* Matside Padova
   Base: la versione pubblicata sulla bozza (home a due sedi, pagine sede scure), ripulita.
   Inter Tight in maiuscolo per titoli, menu ed etichette; Inter per i testi. Scala tipografica unica. */

@font-face { font-family: "Inter Tight"; src: url("../fonts/inter-tight-var.woff2") format("woff2"); font-weight: 600 800; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --black: #0b0b0b;
  --white: #fff;
  --paper: #f4f3f0;
  --line: #e2e1dd;
  --gray: #666666;
  --red: #d6202c;
  --font: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --display: "Inter Tight", "Inter", "Helvetica Neue", Arial, sans-serif;
  --pad: clamp(16px, 4vw, 48px);
  --nav-h: 72px;
  /* scala tipografica */
  --t-label: 12px;
  --t-nav: 13px;
  --t-body: 16px;
  --t-h3: 18px;
  --t-h2: clamp(24px, 2.6vw, 32px);
  --t-h1: clamp(34px, 4.6vw, 56px);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { background: var(--white); color: var(--black); font-family: var(--font); font-size: var(--t-body); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; height: auto; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul { list-style: none; }
address { font-style: normal; }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
[id] { scroll-margin-top: calc(var(--nav-h) + 16px); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* link per saltare al contenuto: invisibile finché non ci si arriva con la tastiera */
.skip { position: fixed; top: 8px; left: 8px; z-index: 200; padding: 10px 16px; background: var(--black); color: var(--white); font-weight: 600; border-radius: var(--r, 6px); transform: translateY(-160%); }
.skip:focus { transform: none; }
.nav-menu { display: contents; }
.nav:has(:focus-visible) { transform: none; }

/* ---------- Tipografia ---------- */
.label { font-size: var(--t-label); line-height: 1.4; font-weight: 600; text-transform: uppercase; letter-spacing: .12em; color: var(--gray); }
h1, h2, h3, .h2 { font-weight: 700; text-transform: uppercase; letter-spacing: .01em; line-height: 1.05; }
h1 { font-size: var(--t-h1); }
h2, .h2 { font-size: var(--t-h2); }
h3 { font-size: var(--t-h3); letter-spacing: .03em; line-height: 1.2; }
.lead { font-size: 18px; line-height: 1.6; max-width: 34em; }
.muted { color: var(--gray); }

.container { width: min(1180px, 100% - 2 * var(--pad)); margin-inline: auto; }
.block { padding: 96px 0; }
.block + .block { padding-top: 0; }
.block-head { margin-bottom: 36px; }
.block-head .label { margin-bottom: 10px; }

/* ---------- Pulsanti ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 22px;
  background: var(--black); color: var(--white); border: 1.5px solid var(--black);
  font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; white-space: nowrap;
  transition: none;
}
.btn.outline { background: transparent; color: var(--black); }
.btn.light { background: var(--white); color: var(--black); border-color: var(--white); }
.btn.ghost { background: transparent; color: var(--white); border-color: rgba(255,255,255,.7); }
/* stesso effetto per tutti i bottoni: rosso pieno con testo bianco */
.btn:hover, .btn:focus-visible, .cal-btn:hover, .cal[open] .cal-btn { background: var(--red); border-color: var(--red); color: var(--white); }
.btns { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- Header ---------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100; height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 0 var(--pad);
  transition: transform .35s cubic-bezier(.2,.7,.2,1), background .3s, box-shadow .3s, color .3s;
}
.nav.hide { transform: translateY(-100%); }
.nav .brand { display: flex; align-items: center; gap: 14px; }
.nav .brand img { height: 40px; width: auto; }
.nav .brand span { font-size: var(--t-label); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.nav ul { display: flex; gap: 32px; }
.nav ul a { position: relative; padding: 6px 0; font-size: var(--t-nav); font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.nav ul a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1.5px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .3s cubic-bezier(.2,.7,.2,1); }
.nav ul a:hover::after, .nav ul a[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }
.nav--light { background: rgba(255,255,255,.95); color: var(--black); box-shadow: 0 1px 0 var(--line); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.nav--overlay { color: var(--white); background: linear-gradient(rgba(0,0,0,.45), transparent); }
.nav--overlay.solid { background: rgba(11,11,11,.95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.nav-toggle { display: none; width: 44px; height: 44px; }
.nav-toggle span { display: block; width: 22px; height: 1.5px; background: currentColor; margin: 6px auto; transition: transform .25s, opacity .25s; }

/* ---------- Home ---------- */
.home-main { padding: calc(var(--nav-h) + 20px) var(--pad) var(--pad); min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column; }
.home-top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 14px; }
.home-top h1 { font-size: var(--t-label); letter-spacing: .12em; font-weight: 600; color: var(--gray); }
.split { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; min-height: 480px; }
.sede-box { position: relative; display: block; overflow: hidden; background: #111; }
.sede-box img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.08) brightness(.9); transition: transform 1.2s cubic-bezier(.2,.7,.2,1), filter .6s; }
.sede-box:hover img { transform: scale(1.03); filter: grayscale(.1); }
.tagbox {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  background: var(--black); color: var(--white); text-align: center; padding: 20px 30px 18px; min-width: 240px;
  transition: background .25s;
}
.sede-box:hover .tagbox { background: var(--red); }
.tagbox .t-city { display: block; font-size: 22px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; line-height: 1.1; }
.tagbox .t-zone { display: block; margin-top: 6px; font-size: var(--t-label); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; opacity: .75; }
.tagbox .t-next { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 12px; padding-top: 12px; border-top: 1px solid rgba(255,255,255,.18); font-size: 11px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; }
.tagbox .t-next:empty::before { content: "\00a0"; } /* riga riservata: il riquadro non cambia altezza quando arriva l'orario */

/* ---------- Sede: apertura ---------- */
.hero { position: relative; min-height: 88vh; min-height: 88svh; color: var(--white); display: flex; align-items: flex-end; background: #111; overflow: hidden; overflow: clip; }
.hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.08) brightness(.42); }
.hero-inner { position: relative; width: 100%; padding: calc(var(--nav-h) + 40px) var(--pad) clamp(40px, 7vh, 80px); }
.hero .label { color: rgba(255,255,255,.7); margin-bottom: 14px; }
.hero h1 em { font-style: normal; color: var(--red); }
.hero .intro { max-width: 34em; margin: 16px 0 22px; color: rgba(255,255,255,.85); }
.next { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 26px; font-size: 14px; color: rgba(255,255,255,.9); }
.next[hidden] { display: none; }
.next strong { font-weight: 600; color: #fff; }

/* ---------- Orari ---------- */
.week { display: grid; grid-template-columns: repeat(5, 1fr); border-top: 1.5px solid var(--black); }
.day { padding: 20px 18px 26px 0; border-right: 1px solid var(--line); }
.day + .day { padding-left: 18px; }
.day:last-child { border-right: 0; }
.day h3 { font-size: 14px; letter-spacing: .08em; }
.day.today h3::after { content: "Oggi"; margin-left: 8px; padding: 2px 6px; background: var(--red); color: #fff; font-size: 10px; letter-spacing: .12em; vertical-align: 2px; }
.day.off p { margin-top: 16px; color: var(--gray); font-size: 13px; }
.slot { margin-top: 16px; }
.slot time { display: block; font-size: 15px; font-weight: 600; }
.slot .tipo { display: block; margin-top: 2px; font-size: var(--t-label); font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--gray); }
.slot .tipo b { color: var(--black); font-weight: 600; }
.noscript-hours { display: grid; grid-template-columns: auto 1fr; gap: 6px 18px; padding: 20px 0; }

/* ---------- Classi ---------- */
.classes { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1.5px solid var(--black); }
.classes.two { grid-template-columns: repeat(2, 1fr); }
.class { padding: 22px 22px 8px 0; }
.class + .class { padding-left: 22px; border-left: 1px solid var(--line); }
.class .label { margin-bottom: 8px; }
.class h3 { font-size: 20px; margin-bottom: 8px; }
.class p { font-size: 15px; line-height: 1.6; color: #333; }

/* ---------- Maestri ---------- */
.team { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 24px; max-width: 980px; }
.coach .ph { aspect-ratio: 4 / 5; overflow: hidden; background: #eee; }
.coach .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.coach:hover .ph img { transform: scale(1.03); }
.coach h3 { margin-top: 14px; }
.coach .label { margin-top: 4px; }
.belt { display: block; position: relative; width: 150px; height: 12px; margin-top: 12px; background: var(--belt, #111); box-shadow: inset 0 0 0 1px rgba(0,0,0,.2); }
.belt i { position: absolute; right: 14px; top: 0; bottom: 0; width: 34px; background: #111; }
.belt-nera i { background: var(--red); }

/* ---------- Foto ---------- */
.photos { padding: 96px 0; background: var(--black); color: var(--white); overflow: hidden; }
.photos .block-head { width: min(1180px, 100% - 2 * var(--pad)); margin: 0 auto 36px; }
.photos .label { color: rgba(255,255,255,.6); }
.car-track { display: flex; align-items: center; gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 6px 50vw; scrollbar-width: none; outline: none; }
.car-track:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.car-track::-webkit-scrollbar { display: none; }
.slide { flex: 0 0 auto; scroll-snap-align: center; height: min(64vh, 600px); margin: 0; cursor: pointer; }
.slide img { height: 100%; width: auto; max-width: 80vw; object-fit: cover; filter: brightness(.55); transform: scale(.92); transition: filter .45s ease, transform .45s ease; }
.slide.active img { filter: none; transform: none; cursor: zoom-in; }
.car-bar { display: flex; justify-content: center; align-items: center; gap: 18px; margin-top: 24px; font-size: var(--t-label); font-weight: 600; letter-spacing: .14em; }
.car-bar button { width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%; color: rgba(255,255,255,.7); transition: color .2s, background .2s; }
.car-bar button:hover { color: var(--black); background: var(--white); }
.car-bar svg { width: 16px; height: 16px; }
.car-count { min-width: 64px; text-align: center; color: rgba(255,255,255,.75); }

.lightbox { position: fixed; inset: 0; z-index: 120; background: rgba(8,8,8,.97); display: none; align-items: center; justify-content: center; }
.lightbox.open { display: flex; }
.lightbox img { max-width: min(92vw, 1400px); max-height: 84vh; object-fit: contain; }
.lightbox .lb-btn { position: absolute; color: #fff; font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; padding: 14px 16px; }
.lb-close { top: 12px; right: 12px; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); font-size: 26px !important; }
.lb-prev { left: 6px; } .lb-next { right: 6px; }
.lb-count { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); color: #aaa; font-size: var(--t-label); letter-spacing: .14em; }

/* ---------- Prima volta ---------- */
.two-col { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(32px, 6vw, 88px); align-items: start; }
.two-col .lead { margin-bottom: 24px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 0; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary h3 { font-size: 14px; letter-spacing: .06em; }
.faq summary::after { content: "+"; font-size: 20px; line-height: 1; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); color: var(--red); }
.faq details.chiude summary::after { transform: none; color: inherit; }
.faq summary::after { transition: transform .3s cubic-bezier(.2,.7,.2,1), color .3s; }
.faq details p { padding: 0 0 20px; max-width: 36em; color: #333; font-size: 15px; }

/* ---------- Dove siamo ---------- */
.where { background: var(--paper); border-top: 1px solid var(--line); padding: 96px 0; }
.where h2 { margin: 10px 0 18px; }
.where address { font-size: 17px; line-height: 1.6; }
.where address small { display: block; font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray); }
.where dl { display: grid; grid-template-columns: 120px 1fr; margin: 24px 0 28px; border-top: 1px solid var(--line); font-size: 15px; }
.where dt, .where dd { padding: 10px 0; border-bottom: 1px solid var(--line); }
.where dt { font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray); padding-top: 12px; }
.map { position: relative; aspect-ratio: 4 / 3; background: #e9e8e4; border: 1px solid var(--line); overflow: hidden; }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map-cover { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 24px; text-align: center;
  background-image: linear-gradient(#e2e1dd 1px, transparent 1px), linear-gradient(90deg, #e2e1dd 1px, transparent 1px); background-size: 32px 32px; }
.map-cover .pin { width: 34px; height: 34px; color: var(--red); }
.map-cover p { font-size: 13px; color: var(--gray); max-width: 30em; }

/* ---------- Pagine interne ---------- */
.page { padding: calc(var(--nav-h) + 56px) 0 80px; }
.page-head { margin-bottom: 40px; }
.page-head .label { margin-bottom: 10px; }
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px 24px; }
.news-card .ph { aspect-ratio: 3 / 2; overflow: hidden; background: #eee; margin-bottom: 14px; }
.news-card .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.news-card:hover .ph img { transform: scale(1.03); }
.news-card h2, .news-card h3 { font-size: var(--t-h3); margin: 8px 0; }
.news-card p { font-size: 15px; color: #444; }
.news-card .more { display: inline-block; margin-top: 10px; font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; border-bottom: 1.5px solid var(--red); }
.article { max-width: 760px; }
.crumbs { display: flex; gap: 8px; margin-bottom: 20px; }
.crumbs a:hover { color: var(--black); }
.article h1 { font-size: clamp(28px, 3.4vw, 40px); margin: 10px 0 16px; }
.article .ph { aspect-ratio: 16 / 9; overflow: hidden; margin: 28px 0 32px; background: #eee; }
.article .ph img { width: 100%; height: 100%; object-fit: cover; }
.credit { margin-top: -24px; margin-bottom: 28px; font-size: 12px; color: var(--gray); }
.prose p { font-size: 17px; line-height: 1.75; margin-bottom: 18px; }
.prose h2 { font-size: 20px; margin: 36px 0 10px; }
.prose h3 { font-size: 15px; margin: 22px 0 6px; }
.prose ul { list-style: disc; padding-left: 20px; margin-bottom: 18px; }
.prose li { margin-bottom: 8px; }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose .gara-cta { margin: 32px 0; }
.prose .gara-cta a { text-decoration: none; }
.sources { font-size: 14px !important; color: var(--gray); border-top: 1px solid var(--line); padding-top: 14px; }
.more-news { margin-top: 80px; }

/* ---------- Footer ---------- */
.footer { background: var(--black); color: #cfcfcf; padding: 72px 0 32px; }
.f-top { display: grid; grid-template-columns: auto 1fr; gap: 32px; align-items: center; padding-bottom: 40px; border-bottom: 1px solid #262626; }
.f-top img { height: 64px; width: auto; }
.f-top p { max-width: 44em; font-size: 15px; color: #a9a9a9; }
.f-cols { display: grid; grid-template-columns: 1.2fr 1.2fr 1fr 1fr; gap: 32px; padding: 40px 0; }
.f-cols h2 { font-size: var(--t-label); letter-spacing: .14em; color: #fff; margin-bottom: 14px; }
.f-cols address, .f-cols li, .f-cols p { font-size: 14px; line-height: 1.7; }
.f-cols .hours { margin-top: 10px; color: #8f8f8f; }
.f-cols a:hover { color: #fff; }
.f-cols .f-link { display: inline-block; margin-top: 12px; font-size: var(--t-label); font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #fff; border-bottom: 1px solid var(--red); }
.f-legal { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; padding-top: 24px; border-top: 1px solid #262626; font-size: 12px; color: #8a8a8a; }
.f-legal nav { display: flex; gap: 20px; flex-wrap: wrap; }
.f-legal a:hover { color: #fff; }
.f-legal nav a { display: inline-flex; align-items: center; min-height: 32px; }

/* ---------- WhatsApp ---------- */
.wa-float { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 6px 20px rgba(0,0,0,.22); transition: transform .2s; }
.wa-float svg { width: 30px; height: 30px; }
.wa-float:hover { transform: scale(1.06); }
.lightbox.open ~ .wa-float { display: none; }

/* ---------- Tempo reale e comparsa ---------- */
.live { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--red); flex-shrink: 0; animation: pulse 1.6s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(214,32,44,.7); } 70% { box-shadow: 0 0 0 9px rgba(214,32,44,0); } 100% { box-shadow: 0 0 0 0 rgba(214,32,44,0); } }
/* testi e blocchi sempre visibili subito, niente dissolvenze mentre scorri (17/11) */
.reveal { opacity: 1; transform: none; }
.reveal.no-anim { transition: none; }
.reveal.in { opacity: 1; transform: none; }
/* chi naviga con la tastiera non deve mai trovarsi su un elemento ancora trasparente */
.reveal:focus-within, .reveal:focus { opacity: 1; transform: none; }

/* Passaggio morbido tra le pagine */

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .nav ul { position: fixed; inset: var(--nav-h) 0 auto 0; flex-direction: column; gap: 0; padding: 8px var(--pad) 24px; display: none; }
  .nav.open ul { display: flex; }
  .nav--light ul { background: #fff; border-top: 1px solid var(--line); }
  .nav--overlay ul { background: rgba(11,11,11,.98); }
  .nav.open.nav--overlay { background: rgba(11,11,11,.98); }
  .nav ul a { display: block; padding: 16px 0; font-size: 18px; border-bottom: 1px solid rgba(128,128,128,.25); }
  .nav ul a::after { display: none; }
  .nav-toggle { display: block; }
  .nav.open .nav-toggle span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  .nav.open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav.open .nav-toggle span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
  .classes { grid-template-columns: 1fr 1fr; }
  .class:nth-child(3) { padding-left: 0; border-left: 0; }
  .class:nth-child(n+3) { border-top: 1px solid var(--line); }
  .two-col { grid-template-columns: 1fr; }
  .f-cols { grid-template-columns: 1fr 1fr; }
  .news-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 700px) {
  :root { --nav-h: 64px; }
  .nav .brand img { height: 34px; }
  .home-main { padding-top: calc(var(--nav-h) + 12px); }
  .home-top .muted { display: none; }
  .split { grid-template-columns: 1fr; min-height: 0; gap: 12px; }
  .sede-box { height: 40svh; min-height: 260px; }
  .tagbox { min-width: 210px; padding: 16px 22px 14px; }
  .block, .photos, .where { padding: 72px 0; }
  .week { grid-template-columns: 1fr; }
  .day, .day + .day { padding: 14px 0; border-right: 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 120px 1fr; gap: 0 12px; }
  .day h3 { grid-row: span 4; }
  .day .slot:first-of-type, .day.off p { margin-top: 0; }
  .day.today h3::after { display: block; width: max-content; margin: 6px 0 0; }
  .classes, .classes.two { grid-template-columns: 1fr; }
  .class, .class + .class { padding: 18px 0; border-left: 0; border-top: 1px solid var(--line); }
  .class:first-child { border-top: 0; }
  .slide { height: 52vh; }
  .slide img { max-width: 86vw; }
  .car-track { gap: 10px; }
  .where dl { grid-template-columns: 100px 1fr; }
  .f-top { grid-template-columns: 1fr; }
  .f-cols { grid-template-columns: 1fr; gap: 28px; }
  .news-grid { grid-template-columns: 1fr; }
  .wa-float { width: 52px; height: 52px; right: 14px; bottom: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  html, .car-track { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .live { animation: none; }
  @view-transition { navigation: none; }
}


/* ===================== Ritocchi: font, apertura, orari a schede, classi, prima volta ===================== */
.label, h1, h2, h3, .h2, .btn, .nav ul a, .nav .brand span, .tagbox, .slot .tipo, .day h3, .car-bar, .lb-btn, .lb-count, .f-cols h2, .where dt, .news-card .more, .faq summary h3 { font-family: var(--display); }
h1, h2, h3, .h2 { letter-spacing: 0; }
.label { letter-spacing: .1em; }
.btn, .nav ul a { letter-spacing: .08em; }

/* logo un poco più grande */
.nav .brand img { height: 48px; }

/* home: niente scritte sopra i riquadri, stesso spazio */
.home-top { min-height: 20px; margin-bottom: 14px; }

/* apertura della sede a tutto schermo */
.hero { min-height: 100vh; min-height: 100svh; }
.hero .intro { margin-bottom: 26px; }

/* prossima lezione in evidenza */
.next-card {
  display: inline-grid; grid-template-columns: auto 1fr; gap: 2px 14px; align-items: center;
  margin-bottom: 28px; padding: 14px 20px 14px 16px;
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.22); border-left: 3px solid var(--red);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); color: #fff;
}
.next-card[hidden] { display: none; }
.next-card .nc-label { grid-column: 1 / -1; font-family: var(--display); font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.65); }
.next-card .nc-when { font-family: var(--display); font-size: 22px; font-weight: 600; line-height: 1.2; }
.next-card .nc-what { font-size: 14px; color: rgba(255,255,255,.85); }
.next-card .nc-in { grid-column: 1 / -1; font-size: 13px; color: rgba(255,255,255,.75); }
.next-card .nc-in strong { color: #fff; font-weight: 600; }
.next-card .live { margin-right: 2px; }

/* sezioni alternate, meno bianco piatto */
.block.tone { background: var(--paper); }
.block + .block.tone, .block.tone + .block, .block.tone + .block[hidden] + .block { padding-top: 96px; }

/* orari: schede per giorno */
.days-tabs { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 20px; }
.days-tabs button {
  min-width: 64px; padding: 12px 16px; background: #fff; border: 1px solid var(--line);
  font-family: var(--display); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  transition: background .2s, color .2s, border-color .2s;
}
.days-tabs button:hover { border-color: var(--black); }
.days-tabs button[aria-selected="true"] { background: var(--black); color: #fff; border-color: var(--black); }
.days-tabs button .dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--red); margin-left: 6px; vertical-align: 2px; }
.day-panel { display: grid; gap: 10px; }
.class-row {
  display: grid; grid-template-columns: 170px 1fr auto; align-items: center; gap: 20px;
  padding: 20px 24px; background: #fff; border: 1px solid var(--line);
  transition: transform .25s, box-shadow .25s;
}
.class-row:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(0,0,0,.06); }
.class-row time { font-family: var(--display); font-size: 22px; font-weight: 600; }
.class-row .cr-name { font-family: var(--display); font-size: 15px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.class-row .cr-note { display: block; margin-top: 2px; font-size: 13px; color: var(--gray); }
.class-row.now { border-color: var(--red); box-shadow: inset 3px 0 0 var(--red); }
.chip { display: inline-flex; align-items: center; height: 28px; padding: 0 12px; font-family: var(--display); font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; border: 1.5px solid var(--black); }
.chip.gi { background: var(--black); color: #fff; }
.chip.nogi { background: #fff; color: var(--black); }
.day-empty { padding: 28px 24px; background: #fff; border: 1px dashed var(--line); color: var(--gray); }
.week-mini { margin-top: 18px; font-size: 13px; color: var(--gray); }

/* classi: card */
.classes { border-top: 0; gap: 16px; }
.class, .class + .class { padding: 26px 24px; border: 1px solid var(--line); border-left: 1px solid var(--line); background: #fff; transition: border-color .25s, transform .25s; }
.class:hover { border-color: var(--black); transform: translateY(-3px); }
.class .num { display: block; font-family: var(--display); font-size: 13px; font-weight: 600; color: var(--red); margin-bottom: 18px; }
.class h3 { font-size: 22px; }
.class .lvl { display: inline-block; margin-top: 14px; }

/* maestri: più ordinati */
.coach { padding-bottom: 6px; }
.coach .ph { position: relative; }
.coach .belt { width: 100%; max-width: 160px; }

/* prima volta: tre passaggi */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 8px 0 40px; counter-reset: s; }
.step { padding: 24px; background: #fff; border: 1px solid var(--line); }
.step::before { counter-increment: s; content: "0" counter(s); display: block; font-family: var(--display); font-size: 13px; font-weight: 600; color: var(--red); margin-bottom: 14px; }
.step h3 { font-size: 16px; margin-bottom: 8px; }
.step p { font-size: 15px; color: #444; }
.step .btn { margin-top: 16px; }
.faq-wrap { display: grid; grid-template-columns: 1fr 2fr; gap: clamp(24px, 5vw, 72px); align-items: start; }

/* dove siamo più compatto */
.where .btns { margin-top: 26px; }

/* footer: link di sede più elegante */
.f-cols .f-link { margin-top: 12px; font-family: var(--font); font-size: 14px; font-weight: 500; letter-spacing: 0; text-transform: none; border: 0; color: #fff; display: inline-flex; gap: 6px; align-items: center; }
.f-cols .f-link span { transition: transform .2s; }
.f-cols .f-link:hover span { transform: translateX(4px); }

@media (max-width: 980px) {
  .steps { grid-template-columns: 1fr; }
  .faq-wrap { grid-template-columns: 1fr; }
}
@media (max-width: 700px) {
  .nav .brand img { height: 40px; }
  .class-row { grid-template-columns: 1fr auto; gap: 6px 12px; padding: 16px; }
  .class-row time { grid-column: 1 / -1; font-size: 20px; }
  .days-tabs button { min-width: 0; flex: 1; padding: 12px 6px; }
  .next-card .nc-when { font-size: 19px; }
  .classes .class { border: 1px solid var(--line) !important; }
}

/* ===================== Apertura a tutto schermo, classi a programmi, prima lezione ===================== */
.hero { min-height: 100vh; min-height: 100svh; align-items: flex-end; }
.hero > img { filter: grayscale(1) contrast(1.1) brightness(.5); }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.35) 0%, rgba(0,0,0,0) 30%, rgba(0,0,0,.55) 100%); pointer-events: none; }
.hero-inner { z-index: 1; }
.hero h1 { font-size: var(--t-h1); line-height: 1.02; max-width: 14em; }
.hero .intro { font-size: 18px; margin: 18px 0 26px; }
.hero .next-card { display: inline-grid; }
.hero .next-card[hidden] { display: none; }
.hero .btns { margin-top: 0; }
.hero-addr { display: flex; align-items: center; gap: 10px; max-width: 640px; margin-top: 36px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.2); font-size: 14px; color: rgba(255,255,255,.85); }
.hero-addr svg { width: 18px; height: 18px; color: var(--red); flex-shrink: 0; }
.hero-addr strong { margin-left: auto; font-family: var(--display); font-size: 12px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: #fff; white-space: nowrap; }
.hero-addr:hover strong { color: var(--red); }

/* classi: legenda Gi e NoGi + un programma per classe */
.legend { display: flex; flex-wrap: wrap; gap: 12px 40px; margin: -8px 0 32px; padding-bottom: 28px; border-bottom: 1px solid var(--line); }
.legend p { display: flex; align-items: center; gap: 12px; font-size: 15px; color: #444; }
.legend .chip { flex-shrink: 0; min-width: 62px; justify-content: center; }
.progs { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px; }
.prog { grid-column: span 2; display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); transition: border-color .25s, transform .25s, box-shadow .25s; }
.progs-5 .prog:nth-child(n+4), .progs-2 .prog, .progs-4 .prog { grid-column: span 3; }
.progs-5 .prog:nth-child(n+4) { flex-direction: row; }
.progs-5 .prog:nth-child(n+4) .prog-img { width: 42%; aspect-ratio: auto; flex-shrink: 0; }
.prog:hover { border-color: var(--black); transform: translateY(-3px); box-shadow: 0 14px 30px rgba(0,0,0,.07); }
.prog-img { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #111; }
.progs-2 .prog-img, .progs-4 .prog-img { aspect-ratio: 16 / 9; }
.prog-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s; }
.prog:hover .prog-img img { transform: scale(1.03); }
.prog { position: relative; cursor: pointer; }
.prog-link { color: inherit; text-decoration: none; }
.prog-link::after { content: ""; position: absolute; inset: 0; z-index: 1; }
.prog-link:focus-visible { outline: none; }
.prog:has(.prog-link:focus-visible) { outline: 2px solid var(--red); outline-offset: 3px; }
/* il bottone è lo stesso di tutto il sito: si colora quando passi sulla scheda, che è tutta cliccabile */
.prog-btn { align-self: flex-start; margin-top: 18px; }
.prog:hover .prog-btn, .prog:has(.prog-link:focus-visible) .prog-btn { background: var(--red); border-color: var(--red); color: var(--white); }
.prog-img, .prog-body { position: relative; }
.prog-badge { position: absolute; left: 14px; top: 14px; padding: 6px 10px; background: #fff; font-family: var(--display); font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.prog-body { display: flex; flex-direction: column; flex: 1; padding: 22px 22px 20px; }
.prog h3 { font-size: 24px; }
.prog-chi { margin: 4px 0 10px; font-family: var(--display); font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.prog-body > p:not(.prog-chi) { font-size: 15px; color: #444; }
.prog-when { margin-top: auto; padding-top: 18px; }
.prog-when li { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.prog-when .pw-day { font-weight: 600; }
.prog-when .pw-time { color: #555; }
.prog-when .chip { margin-left: auto; height: 24px; padding: 0 9px; font-size: 11px; }

/* foto: titolo centrato */
.photos .block-head { text-align: center; }

/* prima lezione: foto a sinistra, testo a destra */
.first { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.first-img { aspect-ratio: 4 / 5; overflow: hidden; }
.first-img img { width: 100%; height: 100%; object-fit: cover; }
.first h2 { margin: 10px 0 16px; }
.first-sub { margin-top: 28px; }
.check { list-style: none; margin: 12px 0 30px; }
.check li { position: relative; padding: 10px 0 10px 30px; border-bottom: 1px solid var(--line); font-size: 15px; }
.check li::before { content: ""; position: absolute; left: 2px; top: 16px; width: 12px; height: 7px; border-left: 2px solid var(--red); border-bottom: 2px solid var(--red); transform: rotate(-45deg); }

/* domande frequenti centrate */
.faq-block { padding-top: 96px !important; }
.faq-center { max-width: 780px; }
.faq-center .block-head { text-align: center; }
.faq-block + .where { border-top: 1px solid var(--line); }

@media (max-width: 980px) {
  .progs { grid-template-columns: 1fr 1fr; }
  .prog, .progs-5 .prog:nth-child(n+4), .progs-2 .prog, .progs-4 .prog { grid-column: span 1; }
  .progs-5 .prog:nth-child(n+4) { flex-direction: column; }
  .progs-5 .prog:nth-child(n+4) .prog-img { width: auto; aspect-ratio: 4 / 3; }
  .first { grid-template-columns: 1fr; }
  .first-img { aspect-ratio: 16 / 10; }
}
@media (max-width: 700px) {
  .progs { grid-template-columns: 1fr; }
  .legend { flex-direction: column; }
  .hero-addr { flex-wrap: wrap; }
  .hero .intro { font-size: 16px; }
}
.credit { margin: -22px 0 28px; font-size: 12px; color: var(--gray); }
.credit a { text-decoration: underline; text-underline-offset: 2px; }
.credit.small { margin: -8px 0 8px; font-size: 11px; }

/* dove siamo: sfondo bianco, indirizzo sopra e mappa in riquadro sotto */
.where { background: var(--white); }
.where-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px 48px; flex-wrap: wrap; margin-bottom: 32px; }
.where-head .btns { margin-top: 0; }
.where .map { display: block; aspect-ratio: 21 / 9; background: #eee; border: 1px solid var(--line); }
.where .map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map-fallback { position: absolute; inset: 0; display: block; }
.map-fallback img { width: 100%; height: 100%; object-fit: cover; }
.map-fallback span { position: absolute; left: 16px; bottom: 16px; right: 16px; max-width: max-content; padding: 10px 14px; background: #fff; font-size: 13px; border: 1px solid var(--line); }
.map-credit { margin-top: 10px; font-size: 12px; color: var(--gray); }
.map-credit a { text-decoration: underline; text-underline-offset: 2px; }
@media (max-width: 700px) {
  .where .map { aspect-ratio: 4 / 3; }
  .where-head .btns { width: 100%; }
}

/* tutto allineato alla stessa colonna del footer (1180px): header, home, apertura. Le foto di sfondo restano a tutta larghezza */
:root { --side: max(var(--pad), calc((100% - 1180px) / 2)); }
.nav { padding-inline: var(--side); }
.home-main { padding-inline: var(--side); }
.hero-inner { padding-inline: var(--side); }
@media (max-width: 980px) { .nav ul { padding-inline: var(--pad); } }

/* credito Audacis nella riga legale */
.f-legal .f-built { padding-left: 20px; border-left: 1px solid #333; }
@media (max-width: 700px) { .f-legal .f-built { padding-left: 0; border-left: 0; } }

/* apertura più asciutta: titolo corto, niente paragrafo; indirizzo e "Indicazioni" sempre sulla stessa riga */
.hero h1 { margin-bottom: 26px; }
.hero-addr span { flex: 1; min-width: 0; }
@media (max-width: 700px) {
  .hero-addr { flex-wrap: nowrap; font-size: 13px; gap: 10px; }
  .hero-addr strong { font-size: 11px; }
  .hero .next-card { margin-bottom: 22px; }
  .hero-inner { padding-bottom: 36px; }
  .hero-addr { padding-right: 76px; } /* il testo non finisce sotto il pulsante WhatsApp */
}

/* ===================== Caricamento senza scatti, menu mobile, tocco, scroll morbido ===================== */
/* prossima lezione: lo spazio è già riservato, il testo compare in dissolvenza */
.next-card .nc-when, .next-card .nc-in, .next-card .nc-what { transition: opacity .3s ease; }
.next-card.is-loading .nc-when, .next-card.is-loading .nc-in { opacity: 0; }

/* scroll morbido: Lenis gestisce lo scorrimento, il CSS non deve sommarsi */

/* home: al tocco sul telefono il riquadro si accende come al passaggio del mouse */
.sede-box.is-tap img, .sede-box:focus-visible img { transform: scale(1.03); filter: grayscale(.1); transition-duration: .35s; }
.sede-box.is-tap .tagbox, .sede-box:focus-visible .tagbox { background: var(--red); }
.sede-box:hover .tagbox *, .sede-box.is-tap .tagbox *, .sede-box:focus-visible .tagbox * { opacity: 1; }

/* menu mobile: si apre in dissolvenza insieme allo sfondo, senza salti */
@media (max-width: 980px) {
  .nav ul {
    display: flex; bottom: 0; height: calc(100dvh - var(--nav-h)); overflow-y: auto;
    opacity: 0; visibility: hidden; transform: translateY(-8px);
    transition: opacity .28s ease, transform .35s cubic-bezier(.2,.7,.2,1), visibility 0s linear .35s;
  }
  .nav.open ul { opacity: 1; visibility: visible; transform: none; transition: opacity .28s ease, transform .35s cubic-bezier(.2,.7,.2,1), visibility 0s; }
  .nav--overlay ul, .nav.open.nav--overlay { background: #0b0b0b; }
  .nav.open { transition: transform .35s cubic-bezier(.2,.7,.2,1); backdrop-filter: none; -webkit-backdrop-filter: none; }
  .nav.open.nav--light { background: #fff; }
  .nav ul li { opacity: 0; transform: translateY(6px); transition: opacity .3s ease, transform .3s ease; }
  .nav.open ul li { opacity: 1; transform: none; }
  .nav.open ul li:nth-child(2) { transition-delay: .04s; }
  .nav.open ul li:nth-child(3) { transition-delay: .08s; }
  html.menu-open, html.menu-open body { overflow: hidden; }
  /* hamburger: tre linee posizionate con precisione, la X ruota dal centro */
  .nav-toggle { position: relative; }
  .nav-toggle span { position: absolute; left: 11px; width: 22px; height: 1.5px; margin: 0; transform-origin: center; transition: transform .35s cubic-bezier(.2,.7,.2,1), opacity .2s ease; }
  .nav-toggle span:nth-child(1) { top: 15px; }
  .nav-toggle span:nth-child(2) { top: 21.25px; }
  .nav-toggle span:nth-child(3) { top: 27.5px; }
  .nav.open .nav-toggle span:nth-child(1) { transform: translateY(6.25px) rotate(45deg); }
  .nav.open .nav-toggle span:nth-child(3) { transform: translateY(-6.25px) rotate(-45deg); }
}
@media (prefers-reduced-motion: reduce) {
  .nav ul, .nav ul li, .nav-toggle span { transition: none !important; }
}
@media (max-width: 980px) { .nav ul a[aria-current="page"] { color: var(--red); } .nav--overlay ul a[aria-current="page"] { color: #fff; box-shadow: inset 3px 0 0 var(--red); padding-left: 12px; } }

/* indirizzo nell'apertura: è lui il link alle indicazioni */
.hero-addr span { text-decoration: underline; text-decoration-color: rgba(255,255,255,.35); text-underline-offset: 4px; transition: text-decoration-color .2s, color .2s; }
.hero-addr:hover span { color: #fff; text-decoration-color: var(--red); }
.class-row .cr-name:empty { display: none; }

/* ===================== Istruttori e La nostra storia ===================== */
a.coach { display: block; }
/* la card intera porta alla presentazione: un solo pulsante sotto, "Tutti gli istruttori" */
.coach h3 { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 5px; text-decoration-thickness: 2px; transition: text-decoration-color .2s; }
.coach:hover h3, .coach:focus-visible h3 { text-decoration-color: var(--red); }
.team-more { margin-top: 40px; }
@media (max-width: 700px) {
  .team { grid-template-columns: 1fr 1fr; gap: 28px 14px; }
  .coach h3 { font-size: 16px; margin-top: 10px; }
  .coach .label { font-size: 10px; letter-spacing: .08em; }
  .coach .belt { max-width: 100%; }
  .team-more { margin-top: 32px; }
  .team-more .btn { width: 100%; }
}
.ph-vuota { display: flex; align-items: center; justify-content: center; background: var(--black) !important; }
.ph-vuota img, .coach .ph.ph-vuota img { width: 46% !important; height: auto !important; object-fit: contain; filter: none !important; opacity: .85; transform: none !important; }

.bios { display: grid; gap: 80px; }
.bio { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; scroll-margin-top: calc(var(--nav-h) + 24px); }
.bio .ph { aspect-ratio: 4 / 5; overflow: hidden; background: #eee; position: sticky; top: calc(var(--nav-h) + 24px); }
.bio .ph img { width: 100%; height: 100%; object-fit: cover; }
.bio h2 { font-size: var(--t-h2); }
.bio-role { margin: 8px 0 14px; color: var(--red); }
.bio .belt { max-width: 180px; }
.bio-sedi { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 18px 0 22px; }
.bio-sedi .label { margin-right: 4px; color: var(--gray); }
.bio-sedi .chip:hover { background: var(--black); color: #fff; }
.bio .prose p { font-size: 16px; }
.bio:target .bio-role { text-decoration: underline; text-underline-offset: 4px; }

.story .lead { margin-top: 14px; }
.story-fig { margin: 36px 0 40px; aspect-ratio: 16 / 9; overflow: hidden; background: #eee; }
.story-fig img { width: 100%; height: 100%; object-fit: cover; }
.story-cta { margin-top: 40px; }
@media (max-width: 760px) {
  .bio { grid-template-columns: 1fr; }
  .bio .ph { position: static; max-width: 340px; }
}

/* ===================== Mobile: più compatto ===================== */
@media (max-width: 700px) {
  /* meno vuoto tra le sezioni */
  .block, .photos, .where { padding: 56px 0; }
  .block + .block.tone, .block.tone + .block, .block.tone + .block[hidden] + .block, .faq-block { padding-top: 56px !important; }
  .block-head { margin-bottom: 26px; }
  /* classi: foto più basse, la card si legge senza scorrere troppo */
  .prog-img, .progs-2 .prog-img, .progs-4 .prog-img, .progs-5 .prog:nth-child(n+4) .prog-img { aspect-ratio: 16 / 9; }
  .prog-body { padding: 18px 18px 16px; }
  /* pagina istruttori: foto piccola accanto al nome, testo sotto a tutta larghezza */
  .bios { gap: 56px; }
  .bio { grid-template-columns: 112px minmax(0, 1fr); gap: 4px 16px; align-items: start; }
  .bio .ph { grid-row: 1 / span 4; max-width: none; width: 112px; position: static; }
  .bio-text { display: contents; }
  .bio h2 { font-size: 22px; align-self: end; }
  .bio-role { margin: 2px 0 6px; font-size: 10px; }
  .bio .belt { max-width: 140px; }
  .bio-sedi { margin: 8px 0 0; }
  .bio-sedi .label { display: none; }
  .bio .prose { grid-column: 1 / -1; margin-top: 18px; }
  .bio .prose p { font-size: 15.5px; line-height: 1.7; }
  /* storia */
  .story-fig { margin: 28px 0 30px; }
  .prose h2 { margin-top: 30px; }
  /* footer più leggero */
  .f-top p { font-size: 14px; }
}

.story-fig--cap { aspect-ratio: auto; overflow: visible; background: none; }
.story-fig--cap img { aspect-ratio: 4 / 3; height: auto; }
.story-fig figcaption { margin-top: 10px; font-size: 13px; color: var(--gray); }

/* ===================== Responsive: rifiniture ===================== */
/* tablet: istruttori 4 per riga invece di 2 card enormi */
@media (min-width: 701px) and (max-width: 980px) {
  .team { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; max-width: none; }
  .coach h3 { font-size: 16px; }
}
/* telefono: niente testo sotto gli 11-12 px */
@media (max-width: 700px) {
  .coach .label { font-size: 11px; }
  .bio-role { font-size: 11px; line-height: 1.4; }
  .prog-when .chip { font-size: 11px; height: 26px; }
}

/* ===================== La nostra storia ===================== */
.story-hero { min-height: 72vh; min-height: 72svh; }
.story-hero > img { object-position: center 35%; }
.story-hero .intro { margin-bottom: 0; }

.story-tappe { padding-bottom: 72px; }
.timeline { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; border-top: 1.5px solid var(--black); }
.timeline li { position: relative; padding-top: 26px; }
.timeline li::before { content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--red); }
.timeline .t-year { display: block; font-family: var(--display); font-size: clamp(30px, 3.4vw, 44px); font-weight: 800; line-height: 1; color: var(--red); }
.timeline h3 { margin: 14px 0 6px; font-size: 17px; }
.timeline p { font-size: 15px; color: #444; }

.story-sec + .story-sec { padding-top: 96px; }
.story-grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(28px, 6vw, 96px); align-items: start; }
.story-grid h2 { position: sticky; top: calc(var(--nav-h) + 24px); font-size: var(--t-h2); }
.story-grid .prose p { font-size: 17px; }
.story-grid .prose p:last-child { margin-bottom: 0; }

.story-photos { display: grid; gap: 16px; margin-top: 56px; }
.story-photos--2 { grid-template-columns: 1fr 1fr; }
.story-photos--3 { grid-template-columns: repeat(3, 1fr); }
.story-photos figure { margin: 0; }
.story-photos img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .5s; }
.story-photos figure:hover img { filter: none; }
.story-photos figcaption { margin-top: 10px; font-size: 13px; color: var(--gray); }

.story-end { background: var(--black); color: #fff; padding: 104px 0; }
.story-end-inner > * { max-width: 760px; }
.story-end .label { color: rgba(255,255,255,.6); margin-bottom: 12px; }
.story-end h2 { font-size: var(--t-h1); margin-bottom: 20px; }
.story-end p:not(.label) { font-size: 18px; color: rgba(255,255,255,.82); margin-bottom: 14px; max-width: 34em; }
.story-end .btns { margin-top: 30px; }

@media (max-width: 980px) {
  .timeline { grid-template-columns: 1fr 1fr; row-gap: 36px; border-top: 0; }
  .timeline li { border-top: 1.5px solid var(--black); }
  .story-grid { grid-template-columns: 1fr; gap: 18px; }
  .story-grid h2 { position: static; }
}
@media (max-width: 700px) {
  .story-hero { min-height: 60svh; }
  .story-tappe { padding-bottom: 48px; }
  .story-sec + .story-sec { padding-top: 56px; }
  .story-grid .prose p { font-size: 16px; }
  .story-photos { margin-top: 36px; gap: 12px; }
  .story-photos--2, .story-photos--3 { grid-template-columns: 1fr 1fr; }
  .story-photos--3 figure:first-child { grid-column: 1 / -1; }
  .story-end { padding: 72px 0; }
  .story-end p:not(.label) { font-size: 16px; }
}

/* ===================== Coerenza tra le pagine ===================== */
/* apertura delle pagine principali (Istruttori, Storia, News): come le sedi, più bassa */
.page-hero { min-height: 62vh; min-height: 62svh; }
.page-hero .intro { margin-bottom: 0; }
.story-hero > img, .page-hero > img { object-position: center 35%; }

/* chiusura scura con invito, uguale su tutte le pagine */
.cta-band { background: var(--black); color: #fff; padding: 104px 0; }
.cta-inner > * { max-width: 760px; }
.cta-band .label { color: rgba(255,255,255,.6); margin-bottom: 12px; }
.cta-band h2 { font-size: var(--t-h1); margin-bottom: 20px; }
.cta-band p:not(.label) { font-size: 18px; color: rgba(255,255,255,.82); margin-bottom: 14px; max-width: 34em; }
.cta-band .btns { margin-top: 30px; }
/* negli articoli la chiusura arriva dopo il contenuto, attaccata al footer */
main.page:has(.cta-band) { padding-bottom: 0; }
main.page > .cta-band { margin-top: 96px; }

/* istruttori: una sezione per persona */
.bio-sec .bio { scroll-margin-top: calc(var(--nav-h) + 24px); }

@media (max-width: 700px) {
  .page-hero { min-height: 52svh; }
  .cta-band { padding: 72px 0; }
  .cta-band p:not(.label) { font-size: 16px; }
  main.page > .cta-band { margin-top: 64px; }
}

/* la chiusura nera e il footer nero restano due blocchi distinti */
main:has(.cta-band) + .footer { border-top: 1px solid #262626; }

/* ===================== Mobile: foto più grandi in Storia e Istruttori ===================== */
@media (max-width: 700px) {
  /* storia: le due foto ieri/oggi una sotto l'altra a tutta larghezza */
  .story-photos--2 { grid-template-columns: 1fr; gap: 22px; }
  .story-photos--3 { grid-template-columns: 1fr 1fr; }
  .story-photos figcaption { font-size: 14px; }
  /* istruttori: foto più grande accanto al nome */
  .bio { grid-template-columns: minmax(0, 44%) minmax(0, 1fr); gap: 4px 18px; }
  .bio .ph { width: 100%; }
  .bio h2 { font-size: 24px; }
}

/* storia: tappe come card con foto, nello stile delle card delle classi */
.tappe { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.tappa { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); transition: border-color .25s, transform .25s, box-shadow .25s; }
.tappa:hover { border-color: var(--black); transform: translateY(-3px); box-shadow: 0 14px 30px rgba(0,0,0,.07); }
.tappa-img { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: #111; }
.tappa-img img { width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.05); transition: filter .5s, transform .8s; }
.tappa:hover .tappa-img img { filter: grayscale(0); transform: scale(1.03); }
.tappa-anno { position: absolute; left: 14px; top: 14px; padding: 6px 12px 5px; background: #fff; font-family: var(--display); font-size: 20px; font-weight: 800; line-height: 1; text-transform: uppercase; }
.tappa-body { padding: 18px 18px 20px; }
.tappa-body h3 { font-size: 17px; margin-bottom: 6px; }
.tappa-body p { font-size: 15px; color: #444; }
@media (max-width: 980px) { .tappe { grid-template-columns: 1fr 1fr; } }
@media (max-width: 700px) {
  .tappe { gap: 12px; }
  .tappa-anno { left: 10px; top: 10px; font-size: 16px; padding: 5px 9px 4px; }
  .tappa-body { padding: 14px 12px 16px; }
  .tappa-body h3 { font-size: 14px; }
  .tappa-body p { font-size: 14px; }
}

/* Storia: album, griglia di foto pulite */
.album { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.album figure { margin: 0; overflow: hidden; }
.album img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; transition: transform .6s; }
.album .alta img { object-position: center 22%; }
.album figure:hover img { transform: scale(1.03); }
@media (max-width: 700px) {
  .album { grid-template-columns: 1fr 1fr; gap: 8px; }
  .album figure:first-child { grid-column: 1 / -1; }
}

/* Foto di famiglia: tutte le foto a colonne, ognuna con le sue proporzioni */
.album-more { margin-top: 28px; text-align: center; }
.foto-tutte { columns: 3; column-gap: 12px; }
.foto-tutte figure { margin: 0 0 12px; break-inside: avoid; overflow: hidden; }
.foto-tutte img { width: 100%; height: auto; display: block; transition: transform .6s; }
.foto-tutte figure:hover img { transform: scale(1.03); }
@media (max-width: 1000px) { .foto-tutte { columns: 2; } }
@media (max-width: 700px) { .foto-tutte { column-gap: 8px; } .foto-tutte figure { margin-bottom: 8px; } }
.photos-more { margin-top: 28px; text-align: center; }

/* Storia: lettura per capitoli con barra fissa che segue (capitolo attuale, avanzamento, elenco a tendina) */
.story-read { position: relative; padding-bottom: clamp(80px, 10vw, 140px); }
.cap-bar { position: sticky; top: 0; z-index: 40; background: rgba(255,255,255,.96); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); transition: top .35s cubic-bezier(.2,.7,.2,1); }
.cap-bar.sotto-nav { top: var(--nav-h); }
.cap-bar-inner { position: relative; }
.cap-btn { display: flex; align-items: center; gap: 16px; width: 100%; padding: 16px 0; background: none; border: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; }
.cap-pos { font-family: var(--display); font-size: 13px; letter-spacing: .08em; color: var(--gray); white-space: nowrap; }
.cap-pos b { color: var(--red); font-weight: 700; }
.cap-tit { flex: 1; min-width: 0; font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cap-btn svg { width: 16px; height: 16px; flex: none; transition: transform .3s; }
.cap-btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.cap-prog { position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%; background: var(--red); transform-origin: left; transform: scaleX(0); }
.cap-menu { list-style: none; position: absolute; left: 0; top: 100%; width: min(460px, 100%); margin-top: 1px; padding: 8px 0; background: #fff; border: 1px solid var(--line); box-shadow: 0 18px 40px rgba(0,0,0,.08); }
.cap-menu a { display: flex; gap: 14px; padding: 11px 20px; font-size: 15px; line-height: 1.4; color: #444; transition: background .2s, color .2s; }
.cap-menu a span { font-family: var(--display); font-size: 12px; color: var(--gray); padding-top: 2px; }
.cap-menu a:hover { background: #f3f2ef; color: var(--black); }
.cap-menu a.on { color: var(--black); font-weight: 600; }
.cap-menu a.on span { color: var(--red); }
.read-body { padding-top: clamp(64px, 8vw, 112px); }
.read-body > .cap { max-width: 760px; }
.cap { scroll-margin-top: calc(var(--nav-h) + 72px); }
.cap + .cap { margin-top: clamp(80px, 10vw, 140px); }
.cap-num { font-family: var(--display); font-size: 14px; font-weight: 700; letter-spacing: .12em; color: var(--red); margin-bottom: 14px; }
.cap h2 { font-size: var(--t-h2); margin-bottom: 28px; }
.cap-testo p { font-size: 18px; line-height: 1.75; color: #2b2b2b; }
.cap-testo p + p { margin-top: 18px; }
.cap-foto { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 48px; }
.cap-foto--3 figure:first-child { grid-column: 1 / -1; }
.cap-foto figure { margin: 0; overflow: hidden; }
.cap-foto img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; display: block; filter: grayscale(1) contrast(1.05); transition: filter .5s; }
.cap-foto--3 figure:first-child img { aspect-ratio: 16 / 9; }
.cap-foto figure:hover img { filter: none; }
@media (max-width: 700px) {
  .cap-btn { padding: 13px 0; gap: 12px; }
  .cap-tit { font-size: 14px; }
  .cap-menu { width: 100%; }
  .cap-testo p { font-size: 16px; }
  .cap-foto { margin-top: 32px; gap: 8px; }
}

/* Memorial: fascia scura con foto, data e countdown, sezione subito dopo gli orari */
.memorial-sec { scroll-margin-top: var(--nav-h); }
.memorial-sec:not([hidden]) + .block { padding-top: 0; }
.memorial { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 48px; align-items: end; padding: clamp(32px, 5vw, 64px); background: var(--black); color: #fff; overflow: hidden; isolation: isolate; }
.memorial img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: grayscale(1) contrast(1.1); opacity: .28; z-index: -1; }
.memorial::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,10,10,.92) 0%, rgba(10,10,10,.55) 70%, rgba(10,10,10,.35) 100%); z-index: -1; }
.memorial .label { color: rgba(255,255,255,.6); margin-bottom: 14px; }
.memorial h3 { font-size: var(--t-h1); line-height: .95; margin-bottom: 18px; }
.mem-txt p:not(.label) { max-width: 52ch; font-size: 17px; color: rgba(255,255,255,.82); }
.mem-badge { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; margin-top: 24px; padding: 0 22px; border: 1.5px solid rgba(255,255,255,.7); font-family: var(--display); font-size: var(--t-label); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; white-space: nowrap; }
.mem-data { display: flex; flex-direction: column; align-items: flex-end; text-align: right; line-height: 1; }
.mem-quando { margin-bottom: 12px; padding: 5px 9px 4px; background: var(--red); font-family: var(--display); font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.mem-d { font-family: var(--display); font-size: clamp(72px, 9vw, 120px); font-weight: 800; letter-spacing: -.02em; }
.mem-m { font-family: var(--display); font-size: 22px; font-weight: 800; text-transform: uppercase; margin-top: 4px; }
.mem-g { margin-top: 10px; font-size: 13px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.6); }
.mem-count { display: flex; gap: 6px; margin-top: 22px; }
.mc { display: flex; flex-direction: column; align-items: center; min-width: 58px; padding: 10px 6px 8px; border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.04); }
.mc b { font-family: var(--display); font-size: 26px; font-weight: 800; line-height: 1; font-variant-numeric: tabular-nums; }
.mc small { margin-top: 6px; font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.mc:last-child b { color: var(--red); }
.mc-live { display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border: 1px solid var(--red); font-family: var(--display); font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
@media (max-width: 700px) {
  .mem-count { width: 100%; margin-top: 14px; }
  .mc { flex: 1; min-width: 0; }
  .mc b { font-size: 22px; }
  .memorial { grid-template-columns: 1fr; gap: 0; padding: 32px 22px 26px; }
  .memorial h3 { font-size: 40px; margin-bottom: 14px; }
  .memorial .label { margin-bottom: 10px; }
  .mem-txt p:not(.label) { font-size: 15px; line-height: 1.6; }
  .mem-badge { margin-top: 18px; }
  .mem-data { display: grid; grid-template-columns: auto 1fr; grid-template-areas: "q q" "d m" "d g" "c c"; align-items: end; column-gap: 12px; margin-top: 26px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.18); text-align: left; }
  .mem-quando { grid-area: q; justify-self: start; margin-bottom: 12px; }
  .mem-d { grid-area: d; font-size: 52px; line-height: .85; }
  .mem-m { grid-area: m; font-size: 18px; margin: 0; }
  .mem-g { grid-area: g; margin: 4px 0 2px; font-size: 12px; }
  .mem-count { grid-area: c; width: 100%; margin-top: 18px; gap: 6px; }
}
/* home: striscia semplice del Memorial sotto i due riquadri */
.home-mem { display: flex; align-items: center; gap: 36px; margin-top: 16px; padding: 28px 32px; background: var(--black); color: #fff; }
.home-mem[hidden] { display: none; }
.hm-txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; margin: 0; font-size: 15px; color: rgba(255,255,255,.72); }
.hm-tit { font-family: var(--display); font-size: 18px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: #fff; transition: color .2s; }
.hm-tit:hover { color: var(--red); }
.hm-gi { white-space: nowrap; font-weight: 600; color: #fff; }
.home-mem .cal { flex: none; }
.home-mem .hm-count { flex: none; display: flex; gap: 0; margin: 0; grid-area: auto; width: auto; }
.home-mem .mc { min-width: 0; padding: 0 18px; border: 0; border-left: 1px solid rgba(255,255,255,.18); background: none; }
.home-mem .mc:first-child { padding-left: 0; border-left: 0; }
.home-mem .mc b { font-size: 34px; font-variant-numeric: tabular-nums; }
.home-mem .mc small { margin-top: 6px; font-size: 11px; }
/* bottone "Segna in calendario" con le due scelte */
.cal { position: relative; }
.cal-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 22px; border: 1.5px solid #fff; background: #fff; color: var(--black); font-family: var(--display); font-size: var(--t-label); font-weight: 600; letter-spacing: .08em; text-transform: uppercase; cursor: pointer; list-style: none; transition: none; white-space: nowrap; }
.cal-btn::-webkit-details-marker { display: none; }
.cal-btn svg { width: 15px; height: 15px; }
.cal-menu { position: absolute; right: 0; bottom: calc(100% + 8px); z-index: 30; display: flex; flex-direction: column; width: 260px; padding: 6px; background: #fff; color: var(--black); box-shadow: 0 18px 40px rgba(0,0,0,.25); }
.cal-menu a { padding: 12px 14px; font-size: 15px; font-weight: 600; transition: background .2s; }
.cal-menu a:hover { background: #f3f2ef; }
.cal-menu small { padding: 8px 14px 8px; font-size: 12px; color: var(--gray); border-top: 1px solid var(--line); }
.mem-azioni { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 24px; }
.mem-azioni .mem-badge { margin-top: 0; }
.mem-azioni .cal-menu { left: 0; right: auto; }
/* riquadri della home: prossima lezione su due righe, "in corso" acceso */
.tagbox .t-next { flex-direction: column; gap: 4px; }
.tn-l { display: inline-flex; align-items: center; gap: 7px; font-size: 11px; letter-spacing: .14em; opacity: .7; }
.tn-v { font-size: 14px; font-weight: 700; letter-spacing: .06em; }
.tagbox.is-live { box-shadow: inset 0 -3px 0 var(--red); }
.tagbox.is-live .tn-l { opacity: 1; color: #fff; }
.sede-box:hover .tagbox.is-live .live { background: #fff; }
@media (max-width: 700px) {
  .home-mem { flex-wrap: wrap; gap: 10px 20px; margin-top: 12px; padding: 16px 18px; }
  .hm-txt { flex-basis: 100%; font-size: 14px; }
  .home-mem .cal { margin-left: auto; }
  .home-mem { padding: 22px 18px; }
  .home-mem .hm-count { width: 100%; justify-content: space-between; order: 2; }
  .home-mem .mc { flex: 1; padding: 0 10px; }
  .home-mem .mc b { font-size: 28px; }
  .home-mem .cal { order: 3; margin-left: 0; }
  .cal-menu { left: 0; right: auto; }
}

/* Prova una lezione: quattro passi e messaggio pronto */
.prova { max-width: 820px; margin-inline: auto; }
.pv-steps { list-style: none; border-top: 1px solid var(--black); }
.pv-step { padding: 28px 0 30px; border-bottom: 1px solid var(--line); scroll-margin-top: calc(var(--nav-h) + 24px); }
.pv-head { display: flex; align-items: baseline; gap: 16px; }
.pv-n { font-family: var(--display); font-size: 14px; font-weight: 800; letter-spacing: .1em; color: var(--red); }
.pv-head h2 { font-size: 22px; }
.pv-scelta { margin-left: auto; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray); white-space: nowrap; }
.pv-step.is-off .pv-head, .pv-step.is-off .pv-n { color: var(--gray); }
.pv-body { margin-top: 20px; }
.pv-opts { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.pv-opt { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; text-align: left; background: #fff; border: 1.5px solid var(--line); font: inherit; color: inherit; cursor: pointer; transition: border-color .2s, background .2s, color .2s; }
.pv-opt b { font-family: var(--display); font-size: 16px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.pv-opt span { font-size: 14px; color: var(--gray); }
.pv-opt:hover { border-color: var(--black); }
.pv-opt.is-on { background: var(--black); border-color: var(--black); color: #fff; }
.pv-opt.is-on span { color: rgba(255,255,255,.7); }
/* lezioni: righe tutte uguali, come gli orari */
.pv-slots { display: flex; flex-direction: column; gap: 8px; }
.pv-slot { display: grid; grid-template-columns: 170px 150px minmax(0, 1fr) 24px; align-items: center; gap: 16px; padding: 16px 20px; }
.pv-slot .ps-g { display: flex; flex-direction: column; gap: 2px; }
.pv-slot .ps-g b { font-family: var(--display); font-size: 16px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.pv-slot .ps-g small { font-size: 13px; color: var(--gray); }
.pv-slot .ps-o { font-family: var(--display); font-size: 18px; color: inherit; font-weight: 700; font-variant-numeric: tabular-nums; }
.pv-slot .ps-c { font-size: 15px; color: #444; }
.pv-slot .ps-go { justify-self: end; color: inherit; font-size: 16px; transition: transform .2s; }
.pv-slot:hover .ps-go { transform: translateX(3px); }
.pv-slot.is-on .ps-g small, .pv-slot.is-on .ps-c { color: rgba(255,255,255,.75); }
.pv-slot.is-on .ps-o, .pv-slot.is-on .ps-go, .pv-slot.is-on .ps-g { color: #fff; }
.pv-vuoto { margin-bottom: 18px; color: #444; }
.pv-fine { margin-top: 32px; padding: clamp(28px, 4vw, 44px); background: var(--black); color: #fff; scroll-margin-top: calc(var(--nav-h) + 24px); }
.pv-fine .label { color: rgba(255,255,255,.6); margin-bottom: 10px; }
.pv-fine h2 { font-size: var(--t-h2); margin-bottom: 12px; }
.pv-fine > p:not(.label):not(.pv-nota) { max-width: 52ch; color: rgba(255,255,255,.82); }
.pv-nome { display: flex; flex-direction: column; gap: 8px; max-width: 360px; margin: 24px 0; font-size: 14px; font-weight: 600; }
.pv-nome small { font-weight: 400; color: rgba(255,255,255,.55); }
.pv-nome input { padding: 12px 14px; border: 1.5px solid rgba(255,255,255,.45); background: transparent; color: #fff; font: inherit; font-weight: 400; font-size: 16px; }
.pv-nome input:focus { outline: none; border-color: #fff; }
.pv-fine .cal-menu { left: 0; right: auto; }
.pv-nota { margin-top: 18px; font-size: 13px; color: rgba(255,255,255,.55); }
@media (max-width: 700px) {
  .pv-head { flex-wrap: wrap; gap: 6px 12px; }
  .pv-head h2 { font-size: 19px; }
  .pv-scelta { margin-left: 0; width: 100%; }
  .pv-opts { grid-template-columns: 1fr; }
  .pv-slot { grid-template-columns: auto minmax(0, 1fr) 20px; grid-template-areas: "g g go" "o c go"; gap: 6px 12px; padding: 14px 16px; }
  .pv-slot .ps-g { grid-area: g; flex-direction: row; align-items: baseline; gap: 8px; white-space: nowrap; }
  .pv-slot .ps-o { grid-area: o; font-size: 15px; white-space: nowrap; }
  .pv-slot .ps-c { grid-area: c; }
  .pv-slot .ps-go { grid-area: go; }
  .pv-fine .btns { flex-direction: column; align-items: stretch; }
  .pv-fine .cal, .pv-fine .cal-btn { width: 100%; }
}

/* apertura delle sedi: "Prossima lezione" larga quanto i due bottoni sotto */
.hero-act { display: inline-grid; max-width: 100%; }
.hero-act .next-card { display: grid; }
.hero-act .btns { display: grid; grid-template-columns: 1fr 1fr; }
@media (max-width: 420px) { .hero-act { display: grid; } .hero-act .btns { grid-template-columns: 1fr; } }
.hero-act .next-card { grid-template-columns: minmax(0, 1fr) auto; gap: 6px 16px; padding: 16px 20px 16px 18px; }
.hero-act .next-card .nc-label { grid-column: 1; grid-row: 1; }
.hero-act .next-card .nc-what { grid-column: 2; grid-row: 1; justify-self: end; padding: 3px 8px 2px; border: 1px solid rgba(255,255,255,.45); font-family: var(--display); font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: #fff; white-space: nowrap; }
.hero-act .next-card .live { grid-column: 2; grid-row: 1; justify-self: end; margin: 0; }
.hero-act .next-card .nc-when { grid-column: 1 / -1; grid-row: 2; }
.hero-act .next-card .nc-in { grid-column: 1 / -1; grid-row: 3; }

/* titoli: a capo bilanciato, niente parola sola sulla seconda riga */
h1, h2, h3, .hero h1 { text-wrap: balance; }

/* News: prossime gare, righe semplici come gli orari */
.gare { list-style: none; border-top: 1px solid var(--black); }
.gara { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; align-items: center; gap: 24px; padding: 22px 0; border-bottom: 1px solid var(--line); }
.gara[hidden] { display: none; }
.g-data { display: flex; flex-direction: column; line-height: 1; padding-top: 2px; }
.g-data b { font-family: var(--display); font-size: 26px; font-weight: 800; white-space: nowrap; }
.g-data span { margin-top: 6px; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray); }
.g-info h3 { font-size: 18px; margin-bottom: 4px; }
.g-info h3 a:hover { color: var(--red); }
.g-info p { font-size: 15px; color: #444; }
.g-info .g-nota { margin-top: 4px; font-size: 13px; color: var(--gray); }
.g-azioni { display: flex; align-items: center; gap: 24px; }
.g-tra { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--red); white-space: nowrap; }
.gare-altre { margin-top: 20px; }
.gare-nota { margin-top: 18px; font-size: 14px; color: var(--gray); }
.paginazione { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 20px; margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--line); }
.paginazione ol { display: flex; gap: 6px; list-style: none; }
.paginazione ol a { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; height: 44px; border: 1.5px solid var(--line); font-family: var(--display); font-weight: 600; }
.paginazione ol a:hover { border-color: var(--black); }
.paginazione ol a[aria-current="page"] { background: var(--black); border-color: var(--black); color: #fff; }
.pag-freccia { display: inline-flex; align-items: center; min-height: 44px; font-family: var(--display); font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; border-bottom: 1.5px solid currentColor; }
.pag-freccia:hover { color: var(--red); }
@media (max-width: 700px) {
  .gara { grid-template-columns: 64px minmax(0, 1fr); align-items: start; gap: 10px 14px; padding: 16px 0; }
  .g-azioni { grid-column: 2; gap: 20px; }
  .g-azioni { flex-wrap: wrap; row-gap: 12px; }
  .g-data b { font-size: 21px; }
  .g-info h3 { font-size: 16px; }
  .g-info p { font-size: 14px; }
}
.gare-sec[hidden] { display: none; }

/* footer: link con area di tocco comoda sul telefono */
.f-cols ul a { display: inline-block; padding: 5px 0; }
/* footer: icone social tonde, stesso hover rosso dei bottoni */
.f-cols .f-social { display: flex; gap: 10px; margin-top: 18px; }
.f-cols .f-social a { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid #3a3a3a; border-radius: 50%; color: #fff; transition: none; }
.f-cols .f-social a:hover, .f-cols .f-social a:focus-visible { background: var(--red); border-color: var(--red); color: #fff; }
.f-cols .f-social svg { width: 20px; height: 20px; }
.footer .muted { color: #a3a3a3; }
/* prova: spazio riservato alla scelta guidata, la pagina non salta mentre carica */
.prova { min-height: 448px; }
@media (max-width: 700px) { .prova { min-height: 533px; } }
.home-top h1 span { font-weight: 500; }
@media (max-width: 700px) { .home-top h1 span { display: none; } }

/* Memorial (pagina sede): riquadro "Prossimo" ordinato al posto della data gigante */
.memorial { align-items: center; }
.memorial .mem-data { display: flex; flex-direction: column; align-items: stretch; text-align: left; min-width: 300px; padding: 26px 28px; border: 1px solid rgba(255,255,255,.28); background: rgba(10,10,10,.55); line-height: 1.2; }
.mem-prox { align-self: flex-start; padding: 3px 8px; background: var(--red); font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: #fff; }
.mem-giorno { margin-top: 10px; font-family: var(--display); font-size: 28px; font-weight: 800; text-transform: uppercase; }
.mem-ora { margin-top: 6px; font-size: 14px; color: rgba(255,255,255,.7); }
.memorial .mem-data .mem-count { margin-top: 20px; width: 100%; justify-content: space-between; }
.memorial .mem-data .mc { flex: 1; min-width: 0; }
@media (max-width: 700px) {
  .memorial .mem-data { order: 0; min-width: 0; width: 100%; padding: 20px; display: flex; grid-template: none; }
  .mem-giorno { font-size: 24px; }
}
.hero-act .next-card[hidden] { display: none; }

/* ---------- Angoli: un solo raggio piccolo per tutto il sito (le fasce a tutta larghezza restano dritte) ---------- */
:root { --r: 6px; }
.btn, .cal-btn, .mem-badge, .chip, .tagbox, .days-tabs button, .pv-opt, .pv-slot, .pv-nome input,
.paginazione ol a, .day-empty, .step, .class-row, .mc, .mem-data, .hero-act .next-card, .hero-act .next-card .nc-what,
.cal-menu, .cap-menu, .cal-menu a, .cap-menu a, .prog-badge, .tappa-anno { border-radius: var(--r); }
.sede-box, .prog, .tappa, .memorial, .home-mem, .pv-fine, .map, .ph,
.album figure, .foto-tutte figure, .story-photos figure, .cap-foto figure { border-radius: var(--r); overflow: hidden; }
.slide img, .lightbox img, .article .ph img { border-radius: var(--r); }

/* telefono: a colori la foto al centro dello schermo (vedi main.js, classe in-vista) */
.sede-box.in-vista img { filter: grayscale(.1); }
.prog.in-vista .prog-img img, .tappa.in-vista .tappa-img img, .coach.in-vista .ph img,
.story-photos figure.in-vista img, .cap-foto figure.in-vista img { filter: none; }
.apribile { cursor: zoom-in; }
.apribile:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* footer su telefono: sedi affiancate, menu su due colonne, link legali in griglia, spazio per il bottone WhatsApp */
@media (max-width: 700px) {
  .footer { padding: 56px 0 104px; }
  .f-top { gap: 20px; padding-bottom: 32px; }
  .f-cols { grid-template-columns: 1fr 1fr; gap: 32px 20px; padding: 32px 0; }
  .f-cols > div:nth-child(n+3) { grid-column: 1 / -1; }
  .f-cols > div:last-child ul { display: grid; grid-template-columns: 1fr 1fr; column-gap: 20px; }
  .f-legal { flex-direction: column; gap: 16px; }
  .f-legal nav { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 20px; }
  .f-legal nav a { padding: 2px 0; }
  .f-legal .f-built { grid-column: 1 / -1; }
  .f-cols h2 .muted { display: block; margin-top: 2px; }
}

/* gare: tipo (Gi/NoGi) come etichetta sopra il nome; su telefono "tra X giorni" e bottone sempre nello stesso ordine */
.g-info .g-tipo { margin-bottom: 4px; font-size: 11px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gray); }
@media (max-width: 700px) {
  .gara { grid-template-columns: 56px minmax(0, 1fr); gap: 0 16px; padding: 22px 0; }
  .g-info { padding-bottom: 14px; }
  .g-azioni { grid-column: 2; display: flex; flex-direction: column; align-items: stretch; gap: 12px; }
  .g-azioni .g-tra:empty { display: none; }
  .g-azioni .btn { width: 100%; justify-content: center; }
}

/* icona tonda di Cookiebot in basso a sinistra: nascosta, le preferenze si cambiano dal link "Preferenze cookie" nel footer */
#CookiebotWidget { display: none !important; }

/* link piccoli più facili da toccare col dito, senza cambiare l'aspetto */
.crumbs { align-items: center; }
.crumbs a { display: inline-block; padding: 12px 0; margin: -12px 0; }
.f-cols .f-link { padding: 11px 0; margin-top: 1px; }

/* Memorial: titolo, sottotitolo, testo; a fianco (su telefono sotto) il prossimo appuntamento con il bottone del calendario */
.memorial .mem-sub { margin: -6px 0 16px; font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.62); }
.mem-obbligo { margin-top: 10px; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.62); }
.mem-data .mem-azioni { margin-top: 22px; }
.mem-data .mem-azioni .cal-menu { left: auto; right: 0; }
@media (max-width: 700px) {
  .memorial .mem-sub { margin: -4px 0 14px; font-size: 12px; }
  .mem-data .mem-azioni { margin-top: 18px; }
  .mem-data .mem-azioni .cal-menu { left: 0; right: auto; }
  .mem-data .mem-azioni .cal, .mem-data .mem-azioni .cal-btn { width: 100%; }
}

/* banner Cookiebot: in basso invece che al centro (il piano gratuito permette solo "Pop up", lo spostiamo noi) */
#CybotCookiebotDialog.CybotCookiebotDialogActive,
#CybotCookiebotDialog[data-template="popup"] {
  top: auto !important;
  bottom: 16px !important;
  left: 50% !important;
  transform: translateX(-50%) !important;
  max-height: calc(100vh - 32px) !important;
}
#CybotCookiebotDialogBodyUnderlay { display: none !important; }
@media (max-width: 600px) {
  #CybotCookiebotDialog.CybotCookiebotDialogActive,
  #CybotCookiebotDialog[data-template="popup"] {
    bottom: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 12px 12px 0 0 !important;
    max-height: 80vh !important;
  }
}

/* Storia: "Torna all'inizio" in fondo */
.totop { display: inline-flex; align-items: center; gap: 14px; margin-top: 56px; padding-top: 28px; border-top: 1px solid rgba(255,255,255,.16); width: 100%; max-width: 760px; color: rgba(255,255,255,.75); font-family: var(--display); font-size: var(--t-label); font-weight: 600; letter-spacing: .14em; text-transform: uppercase; transition: color .2s; }
.totop-ico { display: grid; place-items: center; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.35); border-radius: 50%; transition: background .25s, border-color .25s, transform .3s cubic-bezier(.2,.7,.2,1); }
.totop-ico svg { width: 16px; height: 16px; }
.totop:hover, .totop:focus-visible { color: #fff; }
.totop:hover .totop-ico, .totop:focus-visible .totop-ico { background: var(--red); border-color: var(--red); transform: translateY(-3px); }

/* pagina 404: semplice, a tutto schermo */
.e404 { min-height: 100vh; min-height: 100svh; display: flex; align-items: center; padding: calc(var(--nav-h) + 40px) 0 64px; background: var(--paper); }
.e404 .label { color: var(--gray); margin-bottom: 14px; }
.e404 h1 { font-size: clamp(36px, 6vw, 72px); line-height: 1; }
.e404-txt { margin: 18px 0 32px; max-width: 32em; font-size: 18px; color: #444; }
@media (max-width: 700px) { .e404-txt { font-size: 16px; } }
