/* Grafica comune a tutto il sito e all'Area soci: colori, caratteri, griglia, pulsanti, intestazione,
   menu, piè di pagina e home. Le pagine interne aggiungono sito.css; l'Area soci aggiunge
   area-soci/grafica/formazione.css (che legge i nomi "storici" in fondo a :root: --navy, --red, --condensed…).

   Il sistema (tasteskill): un solo blu Leo per i testi, il rosso Leo solo per l'azione principale
   ("Diventa un Leo"), i caratteri delle linee guida Leo Club Italia (Helvetica; Helvetica Neue Condensed per i titoli dell'Area soci), una griglia a 12 colonne larga al massimo 1280px,
   una scala di spazi (--s-1 … --s-10) e un solo stile per pulsanti, schede e link. */
:root {
  /* Colori */
  --bg: #ffffff;
  --surface: #f5f4f1;
  --ink: #183551;
  --muted: #56606c;
  --action: #e30513;
  --action-hover: #b01e2e;
  --action-ink: #ffffff;
  --line: color-mix(in oklab, var(--ink) 14%, transparent);
  --line-strong: color-mix(in oklab, var(--ink) 26%, transparent);
  --tonal: color-mix(in oklab, var(--ink) 7%, var(--bg));
  --tonal-hover: color-mix(in oklab, var(--ink) 13%, var(--bg));

  /* Caratteri */
  --font-display: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-text: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --display-weight: 400;
  --display-tracking: -0.02em;
  --t-h1: clamp(38px, 2.4vw + 28px, 64px);
  --t-h2: clamp(30px, 1.75vw + 23px, 48px);
  --t-h3: clamp(22px, .55vw + 20px, 28px);
  --t-lead: clamp(18px, .2vw + 17px, 20px);
  --t-card: clamp(18px, .2vw + 17px, 20px);
  --t-body: 16px;
  --t-small: 14px;
  --t-label: 13px;

  /* Spazi: 4, 8, 12, 16, 24, 32, 48, 64, 96, 128 */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px; --s-10: 128px;

  /* Ritmo della pagina: intestazione, margini delle sezioni e margine laterale */
  --nav: 72px;
  --padt: 120px;
  --padb: 72px;
  --gut: 80px;
  --hgap: 48px;
  --hpadb: 64px;
  --maxw: 1280px;

  /* Angoli e pulsanti */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-btn: 8px;
  --btn-h: 44px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --dur: 200ms;

  /* Nomi storici, usati dall'Area soci e da qualche pagina */
  --paper: var(--surface);
  --white: #fff;
  --gray: var(--muted);
  --navy: #183551;
  --red: #e30513;
  --red-ink: #e30513;
  --green: #007a35;
  --font: var(--font-text);
  --condensed: "Helvetica Neue Condensed", "HelveticaNeue-CondensedBold", "Arial Narrow", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --gutter: 24px; /* lo spazio tra le colonne della griglia (12px sul telefono) */
  --service-ambiente: #25795e;
  --service-disastri: #440099;
  --service-cancro: #f6c100;
  --service-diabete: #2c9fda;
  --service-fame: #f28b32;
  --service-giovani: #44a3a5;
  --service-umanitarie: #f9423a;
  --service-mentale: #9a84b2;
  --service-vista: #5a2a65
}

@media (max-width: 1023px) {
  :root { --gut: 48px; --padt: 104px; --padb: 64px }
}

@media (max-width: 639px) {
  :root {
    --nav: 56px; --padt: 96px; --padb: 48px; --gut: 24px; --hgap: 40px; --hpadb: 24px; --gutter: 12px
  }
}

/* ---------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box }

html {
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: var(--nav)
}

html, body { margin: 0 }

body {
  background: var(--bg);
  color: var(--ink);
  font: 400 var(--t-body)/1.6 var(--font-text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility
}

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

/* I pulsanti e i campi usano il carattere della pagina, non quello del browser */
button, input, select, textarea { font: inherit; color: inherit }

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

p, h1, h2, h3, h4 { margin-top: 0 }

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: var(--display-weight);
  color: var(--ink);
  text-wrap: balance
}

h1 { font-size: var(--t-h1); line-height: 1.04; letter-spacing: var(--display-tracking); margin-bottom: var(--s-5) }
h2 { font-size: var(--t-h2); line-height: 1.08; letter-spacing: -0.025em; margin-bottom: var(--s-4) }
h3 { font-size: var(--t-card); line-height: 1.3; letter-spacing: -0.01em; margin-bottom: var(--s-2) }

strong, b { font-weight: 500 }

.muted { color: var(--muted) }

::selection { background: color-mix(in oklab, var(--action) 22%, transparent) }

/* Chi naviga con la tastiera (Tab) vede sempre dove si trova. */
:focus-visible { outline: 2px solid var(--action); outline-offset: 3px; border-radius: 2px }

.wrap {
  width: min(100% - 2 * var(--gut), var(--maxw));
  margin-inline: auto
}

.grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--s-5)
}

@media (max-width: 639px) { .grid { column-gap: var(--s-3) } }

.skip-link {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap
}

.skip-link:focus {
  width: auto;
  height: auto;
  clip-path: none;
  padding: var(--s-2) var(--s-4);
  background: var(--bg);
  border-radius: var(--r-sm);
  z-index: 30
}

/* ---------------------------------------------------------------- link e pulsanti */
.link,
.prose a:not([class]) {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  text-decoration-color: var(--line-strong);
  transition: text-decoration-color var(--dur) var(--ease)
}

.link:hover,
.prose a:not([class]):hover { text-decoration-color: currentColor }

.btn,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s-2);
  min-height: var(--btn-h);
  padding: 0 var(--s-5);
  border: 0;
  border-radius: var(--r-btn);
  font: 500 16px/1.2 var(--font-text);
  text-align: center;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color var(--dur) var(--ease), transform var(--dur) var(--ease)
}

.btn:active,
.button:active { transform: translateY(1px) scale(.98) }

.btn--primary {
  background: var(--action);
  color: var(--action-ink)
}

.btn--primary:hover {
  background: var(--action-hover);
  transform: translateY(-1px)
}

/* Il secondo pulsante (e i vecchi .button delle pagine interne): tinta leggera, senza bordo */
.btn--secondary,
.button {
  background: var(--tonal);
  color: var(--ink)
}

.btn--secondary:hover,
.button:hover {
  background: var(--tonal-hover);
  transform: translateY(-1px)
}

/* I .button button-primary delle pagine interne (album, siti esterni): come il pulsante principale */
.button.button-primary {
  background: var(--action);
  color: var(--action-ink)
}

.button.button-primary:hover { background: var(--action-hover) }

.button span { transition: transform var(--dur) var(--ease) }
.button:hover span { transform: translate(2px, -2px) }

.btn--xl {
  width: min(100%, 640px);
  min-height: 72px;
  font: var(--display-weight) 28px/1 var(--font-display);
  letter-spacing: -0.02em;
  border-radius: var(--r-md)
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3)
}

/* ---------------------------------------------------------------- intestazione */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  height: var(--nav);
  z-index: 10;
  background: var(--surface);
  border-bottom: 1px solid var(--line)
}

.nav__bar {
  height: 100%;
  display: flex;
  align-items: center;
  gap: var(--s-6)
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--s-3);
  flex: none
}

.brand-signature {
  width: auto;
  height: 48px
}

.main-nav {
  display: flex;
  align-items: center;
  gap: var(--s-1);
  height: 100%;
  margin-right: auto
}

.nav__item {
  display: flex;
  align-items: center;
  height: 100%
}

.nav__link {
  position: relative;
  display: inline-flex;
  align-items: center;
  height: 100%;
  padding: 0 var(--s-3);
  font: 500 15px/1 var(--font-text);
  color: var(--ink);
  white-space: nowrap
}

.has-menu .nav__link { padding-right: var(--s-1) }

.nav__link::after {
  content: "";
  position: absolute;
  left: var(--s-3);
  right: var(--s-3);
  bottom: 0;
  height: 2px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur) var(--ease)
}

.has-menu .nav__link::after { right: var(--s-1) }

.nav__link:hover::after,
.nav__link[aria-current="page"]::after { transform: scaleX(1) }

.nav__chev {
  width: 24px;
  height: 32px;
  margin-right: var(--s-2);
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  cursor: pointer;
  display: grid;
  place-items: center
}

.nav__chev::before {
  content: "";
  width: 7px;
  height: 7px;
  border: solid currentColor;
  border-width: 0 1.5px 1.5px 0;
  transform: translateY(-2px) rotate(45deg);
  transition: transform var(--dur) var(--ease)
}

.has-menu:hover .nav__chev::before,
.has-menu.is-open .nav__chev::before { transform: translateY(1px) rotate(225deg) }

.nav__menu {
  position: absolute;
  left: 0;
  right: 0;
  top: var(--nav);
  padding: var(--s-6) 0 var(--s-7);
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  visibility: hidden;
  opacity: 0;
  transition: opacity 120ms var(--ease), visibility 0s linear 120ms
}

.has-menu:hover > .nav__menu,
.has-menu:focus-within > .nav__menu,
.has-menu.is-open > .nav__menu {
  visibility: visible;
  opacity: 1;
  transition: opacity 120ms var(--ease) 150ms, visibility 0s linear 150ms
}

.has-menu.is-open > .nav__menu { transition-delay: 0s }

.nav__menu-grid {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--s-5)
}

.menu-col {
  grid-column: span 3;
  display: flex;
  flex-direction: column;
  gap: var(--s-1)
}

.menu-col__head {
  margin: 0 0 var(--s-2);
  font: 500 var(--t-label)/1.4 var(--font-text);
  color: var(--muted);
  text-transform: uppercase;
}

.menu-col a {
  padding: var(--s-2) 0;
  font: 500 16px/1.3 var(--font-text);
  color: var(--ink);
  transition: color var(--dur) var(--ease)
}

.menu-col a:hover { color: var(--action) }

.menu-col small {
  display: block;
  margin-top: 2px;
  font: 400 var(--t-small)/1.4 var(--font-text);
  color: var(--muted)
}

.menu-card {
  grid-column: 10 / span 3;
  display: flex;
  flex-direction: column;
  gap: var(--s-1);
  transition: transform var(--dur) var(--ease)
}

.menu-card:hover { transform: translateY(-2px) }

.menu-card__img {
  display: block;
  aspect-ratio: 3 / 2;
  margin-bottom: var(--s-3);
  overflow: hidden;
  border-radius: var(--r-md);
  background: var(--surface)
}

.menu-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 400ms var(--ease)
}

.menu-card:hover .menu-card__img img { transform: scale(1.03) }

.menu-card__label {
  font: 500 var(--t-label)/1.4 var(--font-text);
  color: var(--muted)
}

.menu-card strong {
  font: 500 16px/1.3 var(--font-text)
}

.nav__item--sheet { display: none }

.header-cta { flex: none }

.menu-toggle {
  display: none;
  flex: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--r-btn);
  background: var(--tonal);
  cursor: pointer;
  position: relative;
  transition: background-color var(--dur) var(--ease)
}

.menu-toggle:hover { background: var(--tonal-hover) }

.menu-toggle span {
  position: absolute;
  left: 13px;
  right: 13px;
  height: 1.5px;
  background: var(--ink);
  transition: transform var(--dur) var(--ease), top var(--dur) var(--ease)
}

.menu-toggle span:first-child { top: 18px }
.menu-toggle span:last-child { top: 25px }
.menu-toggle[aria-expanded="true"] span:first-child { top: 21.5px; transform: rotate(45deg) }
.menu-toggle[aria-expanded="true"] span:last-child { top: 21.5px; transform: rotate(-45deg) }

main { display: block; padding-top: var(--nav) }

/* Sotto i 1100px il menu diventa un foglio a schermo intero; il pulsante principale resta nella barra. */
@media (max-width: 1099px) {
  .menu-toggle { display: block }
  .header-cta { margin-left: auto }
  .nav__bar { gap: var(--s-3) }

  .main-nav {
    position: fixed;
    inset: var(--nav) 0 0;
    height: auto;
    margin: 0;
    padding: var(--s-3) var(--gut) calc(var(--s-7) + env(safe-area-inset-bottom));
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    overflow-y: auto;
    background: var(--bg)
  }

  .main-nav.open { display: flex }

  .nav__item {
    height: auto;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--line)
  }

  .nav__item--sheet { display: flex }

  .nav__link {
    flex: 1;
    height: 56px;
    padding: 0;
    font-size: 18px
  }

  .nav__link::after { display: none }
  .nav__link[aria-current="page"] { color: var(--action) }

  .nav__chev {
    width: 44px;
    height: 44px;
    margin: 0;
    border-radius: var(--r-btn);
    background: var(--tonal)
  }

  .has-menu:hover .nav__chev::before { transform: translateY(-2px) rotate(45deg) }
  .has-menu.is-open .nav__chev::before { transform: translateY(1px) rotate(225deg) }

  .nav__menu,
  .has-menu:hover > .nav__menu,
  .has-menu:focus-within > .nav__menu {
    position: static;
    flex-basis: 100%;
    display: none;
    padding: 0 0 var(--s-4);
    border: 0;
    background: none;
    visibility: visible;
    opacity: 1;
    transition: none
  }

  .has-menu.is-open > .nav__menu { display: block }

  .nav__menu .wrap { width: auto }
  .nav__menu-grid { display: flex; flex-direction: column; gap: var(--s-4) }
  .menu-col a { padding: var(--s-2) 0; font-size: 16px }
  .menu-card { display: none }

  html.sheet-open, html.sheet-open body { overflow: hidden }
}

@media (max-width: 639px) {
  .brand-signature { height: 36px }
  .header-cta { padding: 0 var(--s-4) }
}

@media (max-width: 359px) {
  .header-cta { display: none }
  .menu-toggle { margin-left: auto }
}

/* ---------------------------------------------------------------- sezioni */
.section {
  padding: var(--padt) 0 var(--padb)
}

.ground-surface { background: var(--surface) }

.section-head { margin-bottom: var(--s-7) }

.section-head p,
.section-intro {
  margin-bottom: 0;
  font-size: var(--t-lead);
  line-height: 1.55;
  color: var(--muted)
}

@media (max-width: 639px) {
  .section-head { margin-bottom: var(--s-6) }
}

/* ---------------------------------------------------------------- home: una sezione per schermo */
.screen { min-height: calc(var(--h, 1) * 100svh) }

/* La home: il primo schermo è tutto dell'hero, che parte sotto l'intestazione fissa. */
main:has(> .hero) { padding-top: 0 }

.hero {
  min-height: 100svh;
  padding: calc(var(--nav) + var(--hgap)) 0 var(--hpadb)
}

.hero__grid { align-items: start }

.hero__text { grid-column: 1 / span 5; padding-top: var(--s-2) }

.hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2);
  margin-bottom: var(--s-5);
  font: 500 var(--t-small)/1.4 var(--font-text);
  color: var(--muted)
}

.hero__kicker .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--action)
}

.hero__lead {
  margin-bottom: var(--s-6);
  font-size: var(--t-lead);
  line-height: 1.55;
  color: var(--muted)
}

.hero__lead a { color: var(--ink) }

.hero__facts {
  display: grid;
  grid-template-columns: repeat(3, auto);
  justify-content: start;
  gap: var(--s-6);
  margin: var(--s-7) 0 0;
  padding-top: var(--s-5);
  border-top: 1px solid var(--line)
}

.hero__facts div { display: flex; flex-direction: column; gap: var(--s-1) }
.hero__facts dt { font: 500 var(--t-label)/1.3 var(--font-text); color: var(--muted) }
.hero__facts dd { margin: 0; font: var(--display-weight) 28px/1.1 var(--font-display); letter-spacing: -0.02em }

.hero__media {
  grid-column: 7 / span 6;
  height: min(calc(100svh - var(--nav) - var(--hgap) - var(--hpadb)), 680px);
  min-height: 420px;
  margin: 0;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--surface)
}

.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 40%
}

/* Righe con un link (percorsi, Club, risorse) */
.rows {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line)
}

.rows > li { border-bottom: 1px solid var(--line) }

.rows__item {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: var(--s-4);
  min-height: 64px;
  padding: var(--s-3) 0
}

.rows__name {
  display: block;
  font: 500 17px/1.35 var(--font-text);
  color: var(--ink)
}

.rows__name small {
  display: block;
  margin-top: 2px;
  font: 400 var(--t-small)/1.4 var(--font-text);
  color: var(--muted)
}

.rows__go {
  font: 500 var(--t-small)/1 var(--font-text);
  color: var(--ink);
  white-space: nowrap
}

.rows__go::after {
  content: "→";
  display: inline-block;
  margin-left: 6px;
  transition: transform var(--dur) var(--ease)
}

a.rows__item:hover .rows__go::after,
.rows__item a.rows__go:hover::after { transform: translateX(3px) }

a.rows__item:hover .rows__name { color: var(--action) }

.split { align-items: start }
.split__text { grid-column: 1 / span 6 }
.split__media { grid-column: 7 / span 6; margin: 0 }

.frame {
  margin: 0;
  overflow: hidden;
  border-radius: var(--r-lg);
  background: var(--surface)
}

.frame img {
  width: 100%;
  height: 100%;
  object-fit: cover
}

.frame--43 { aspect-ratio: 4 / 3 }
.frame--32 { aspect-ratio: 3 / 2 }
.frame--169 { aspect-ratio: 16 / 9 }

.split__text .link,
.section-link { display: inline-block; margin-top: var(--s-6); font-weight: 500 }

/* Percorsi Alpha e Omega: due schede con la foto */
.tiles { row-gap: var(--s-5) }

.tile {
  grid-column: span 6;
  display: flex;
  flex-direction: column;
  transition: transform var(--dur) var(--ease)
}

.tile:hover { transform: translateY(-2px) }

.tile .frame { margin-bottom: var(--s-5) }
.tile .frame img { transition: transform 400ms var(--ease) }
.tile:hover .frame img { transform: scale(1.03) }

.tile__top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--s-4)
}

.tile__age {
  font: var(--display-weight) var(--t-h3)/1 var(--font-display);
  letter-spacing: -0.02em;
  color: var(--muted);
  white-space: nowrap
}

.tile h3 { font-size: var(--t-h3); margin: 0 }
.tile p { margin: var(--s-2) 0 0; color: var(--muted) }

/* Il Distretto e la mappa */
.map-frame {
  margin: 0;
  padding: var(--s-6);
  border-radius: var(--r-lg);
  background: var(--bg)
}

.map-frame img { width: 100%; max-height: 560px; object-fit: contain }

/* Aree di service: icone ufficiali nei loro colori */
.service-grid { row-gap: var(--s-5) }

.service-card {
  grid-column: span 4;
  display: grid;
  grid-template-columns: 72px 1fr;
  align-items: center;
  gap: var(--s-4);
  min-height: 112px;
  padding: var(--s-4) var(--s-5) var(--s-4) var(--s-4);
  border-radius: var(--r-lg);
  background: var(--bg);
  transition: transform var(--dur) var(--ease)
}

.service-card:hover { transform: translateY(-2px) }

.service-card img { width: 72px; height: 76px; object-fit: contain }
.service-card h3 { margin: 0 0 2px; font-size: 18px; font-weight: 500; letter-spacing: 0 }
.service-card p { margin: 0; font-size: var(--t-small); line-height: 1.45; color: var(--muted) }

/* Calendario */
.calendar {
  overflow: hidden;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: var(--bg)
}

.calendar iframe {
  display: block;
  width: 100%;
  height: clamp(420px, 100svh - 380px, 560px);
  border: 0
}

/* Il Club: righe più basse, così l'elenco dei nove sta in uno schermo */
.club-rows .rows__item { min-height: 52px; padding: var(--s-2) 0 }
.club-rows .rows__name small { display: inline; margin: 0 0 0 var(--s-2) }

/* ---------------------------------------------------------------- chiusura e piè di pagina */
.closing {
  padding: var(--s-9) 0 var(--s-6);
  background: var(--surface)
}

/* Riga di chiusura: la frase a sinistra, "Diventa un Leo" a destra, sulla stessa linea di base */
.closing__cta {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-5) var(--s-7);
  padding-bottom: var(--s-8);
  border-bottom: 1px solid var(--line)
}

.closing__cta h2 { margin-bottom: var(--s-2) }
.closing__note { margin: 0; font-size: var(--t-lead); color: var(--muted) }

.btn--lg {
  min-height: 56px;
  padding: 0 var(--s-7);
  font-size: 18px
}

.footer__dir {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  column-gap: var(--s-5);
  row-gap: var(--s-7);
  padding-top: var(--s-8)
}

.footer__company {
  grid-column: 1 / span 4;
  align-self: start;
  justify-self: start;
  transition: opacity var(--dur) var(--ease)
}

.footer__company:hover { opacity: .8 }
.footer__logo { width: auto; height: 80px }

.footer__col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--s-3);
  font-size: 16px;
  line-height: 1.5
}

/* Logo a sinistra; Naviga, Sede e Contatti nelle colonne 5-12 della griglia */
.footer__col--nav { grid-column: 5 / span 2 }
.footer__col--sede { grid-column: 5 / span 3 }
.footer__col--contatti { grid-column: 9 / span 4 }

.footer__head {
  margin: 0 0 var(--s-1);
  font: 700 12px/1.3 var(--font-text);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted)
}

.footer__col address {
  font-style: normal;
  color: var(--ink)
}

.footer__col a {
  color: var(--ink);
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat;
  transition: background-size var(--dur) var(--ease), color var(--dur) var(--ease);
  overflow-wrap: anywhere
}

.footer__col a:hover { background-size: 100% 1px }

/* Email e Instagram con la loro icona */
.footer__contact {
  display: inline-flex;
  align-items: center;
  gap: var(--s-2)
}

.footer__contact svg {
  flex: none;
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linejoin: round
}

.footer__contact svg .dot { fill: currentColor; stroke: none }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap
}

.footer__legal {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s-3) var(--s-6);
  padding-top: var(--s-5);
  border-top: 1px solid var(--line);
  font-size: var(--t-small);
  color: var(--muted)
}

.footer__top {
  color: var(--muted);
  transition: color var(--dur) var(--ease)
}

.footer__top span {
  display: inline-block;
  transition: transform var(--dur) var(--ease)
}

.footer__top:hover { color: var(--ink) }
.footer__top:hover span { transform: translateY(-2px) }

@media (max-width: 1023px) {
  .footer__company { grid-column: 1 / -1 }
  .footer__col--nav,
  .footer__col--sede { grid-column: span 6 }
  .footer__col--contatti { grid-column: 1 / -1 }
}

@media (max-width: 639px) {
  .closing { padding-top: var(--s-8) }
  .closing__cta { padding-bottom: var(--s-7) }
  .closing__cta .btn { flex: 1 1 100% }
  .footer__dir { row-gap: var(--s-6); padding-top: var(--s-7) }
  .footer__logo { height: 64px }
  .footer__legal { flex-direction: column }
}

/* ---------------------------------------------------------------- larghezze */
@media (max-width: 1279px) {
  .service-card { grid-template-columns: 56px 1fr; gap: var(--s-3); padding-right: var(--s-4) }
  .service-card img { width: 56px; height: 60px }
}

@media (max-width: 1023px) {
  .service-card { grid-column: span 6 }
  .split .frame--43 { aspect-ratio: 16 / 9 }
  .split__media { margin-top: var(--s-6) }
  .tile .frame { aspect-ratio: 4 / 5 }
  #club .split__media { display: none }
  .hero__text,
  .split__text,
  .split__media { grid-column: 1 / -1 }

  .hero__media { grid-column: 1 / -1; height: auto; min-height: 0; aspect-ratio: 16 / 10; margin-top: var(--s-6) }
  .hero__facts { margin-top: var(--s-6) }
  .split__media { margin-top: var(--s-7) }
  .split { row-gap: 0 }

}

@media (max-width: 639px) {
  .grid > * { grid-column: 1 / -1 }
  .hero { min-height: 0 }
  .hero__text { padding-top: 0 }
  .hero__media { aspect-ratio: 4 / 3 }
  .hero__facts { gap: var(--s-5) }
  .hero__facts dd { font-size: 24px }
  .btn-row .btn { flex: 1 1 100% }
  .tile { grid-column: 1 / -1 }
  .service-card { grid-column: 1 / -1; min-height: 96px }
  .calendar iframe { height: 480px }
  .screen { min-height: calc(var(--hm, 1) * 100svh) }
  #percorsi, #service, #club { --hm: 2 }
  .tile .frame { aspect-ratio: 16 / 9 }
  #club .split__media { display: block }
  .split__media { margin-top: var(--s-5) }
  .rows__item { min-height: 60px }
  .club-rows .rows__name small { display: block; margin: 2px 0 0 }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    transition-duration: 0s !important;
    transition-delay: 0s !important;
    animation: none !important
  }
}

/* Tablet alto (es. 820x1180): la foto del Club torna, più bassa, e l'elenco resta in uno schermo */
@media (min-width: 640px) and (max-width: 1023px) and (min-height: 1100px) {
  #club .split__media { display: block; aspect-ratio: 2 / 1 }
}

/* Spazio tra la frase introduttiva e l’elenco (Club, risorse) */
.section-intro + .rows { margin-top: var(--s-6) }
@media (max-width: 639px) {
  .section-intro + .rows { margin-top: var(--s-4) }
  .split__media { margin-top: var(--s-4) }
}
