/* Font ospitati sul sito: nessuna richiesta a terze parti (come da informativa privacy) */
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-sans-400-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-sans-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/dm-sans-500-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/dm-sans-500-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/dm-sans-700-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'DM Sans';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/dm-sans-700-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'DM Serif Display';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-serif-display-400-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'DM Serif Display';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/dm-serif-display-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  /* brand kit delle guide, invariato */
  --verde: #4A7C5C;
  --verde-scuro: #3D6A4C;
  --verde-chiaro: #EEF4F0;
  --beige: #F5F0E8;
  --arancio: #E8784B;
  --arancio-scuro: #C85A1E;
  --testo: #1A1A1A;
  --muted: #8A8A8A;
  --bianco: #FFFFFF;
  --bordo: #E8E2D8;
  --callout: #FFF6F0;
  --esercizio: #E9F1EB;

  --serif: 'DM Serif Display', Georgia, serif;
  --sans: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;

  --colonna: 1120px;
  --stretta: 720px;
  --raggio: 12px;
  --raggio-s: 12px;
  --ritmo: clamp(72px, 9vw, 116px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

body {
  margin: 0;
  background: var(--bianco);
  color: var(--testo);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.66;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

:focus-visible {
  outline: 2px solid var(--arancio);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- impianto ---------- */
.sezione { padding: var(--ritmo) 24px; }
.sezione.beige { background: var(--beige); }
.sezione.verdino { background: var(--verde-chiaro); }
.dentro { max-width: var(--colonna); margin: 0 auto; }
.dentro.stretta { max-width: var(--stretta); }

/* ---------- tipografia ---------- */
h1, h2, h3 {
  margin: 0;
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: -0.005em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.4rem, 5vw, 3.5rem); line-height: 1.12; }
h2 { font-size: clamp(1.95rem, 3.6vw, 2.75rem); line-height: 1.18; }
h3 { font-size: 1.32rem; line-height: 1.3; }
p { margin: 0; }

.occhiello {
  display: inline-block;
  width: fit-content;
  max-width: 100%;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--arancio-scuro);
  background: var(--callout);
  padding: 6px 12px;
  border-radius: 6px;
}
.guida { color: #4A4A4A; font-size: 1.09rem; }
.piccolo { font-size: 0.94rem; color: var(--muted); }

.testa { display: flex; flex-direction: column; gap: 18px; max-width: 700px; }
.testa + * { margin-top: 46px; }

/* ---------- pulsanti ---------- */
.bottone {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 58px;
  padding: 0 30px;
  border-radius: var(--raggio-s);
  border: 1px solid transparent;
  background: var(--arancio);
  color: #fff;
  font-family: var(--sans);
  font-size: 1.04rem;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: background .16s ease, border-color .16s ease;
}
.bottone:hover { background: var(--arancio-scuro); }
.bottone.chiaro {
  background: transparent;
  color: var(--testo);
  border-color: var(--bordo);
}
.bottone.chiaro:hover { border-color: var(--muted); background: transparent; }
.bottoni { display: flex; gap: 12px; flex-wrap: wrap; }
.freccia { width: 15px; height: 15px; flex: none; }

/* ---------- barra in alto ---------- */
.barra {
  position: sticky; top: 0; z-index: 20;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(1.6) blur(9px);
  border-bottom: 1px solid var(--bordo);
}
.barra-dentro {
  max-width: var(--colonna); margin: 0 auto;
  padding: 13px 24px;
  display: flex; align-items: center; gap: 26px;
}
.logo {
  font-family: var(--sans);
  font-weight: 700; font-size: 1.04rem; letter-spacing: -0.01em;
  text-decoration: none; color: var(--testo);
}
.logo span { color: var(--verde); }
.menu { display: flex; gap: 24px; margin-left: auto; align-items: center; }
.menu a { text-decoration: none; color: #4A4A4A; font-size: 0.97rem; }
.menu a:hover { color: var(--testo); }
.barra .bottone { min-height: 44px; padding: 0 18px; font-size: 0.95rem; }

/* ---------- apertura, il primo pezzo: verde salvia ---------- */
.apertura {
  background: var(--verde);
  color: #fff;
  padding: clamp(64px, 9vw, 118px) 24px clamp(60px, 8vw, 104px);
  position: relative;
  overflow: hidden;
}
.apertura .deco {
  position: absolute;
  width: 460px; height: 460px;
  border-radius: 50%;
  background: rgba(255,255,255,.055);
  right: -140px; top: -170px;
  pointer-events: none;
}
.apertura .dentro {
  display: flex; flex-direction: column; gap: 26px; align-items: flex-start;
  position: relative;
}
.apertura h1 { max-width: 31ch; }
.apertura .guida { max-width: 56ch; font-size: 1.17rem; color: rgba(255,255,255,.88); }
.apertura .occhiello { color: #fff; background: rgba(255,255,255,.16); }
.apertura .bottone.chiaro { color: #fff; border-color: rgba(255,255,255,.42); }
.apertura .bottone.chiaro:hover { border-color: #fff; }
.sotto-bottoni { font-size: 0.9rem; color: var(--muted); }
.apertura .sotto-bottoni { color: rgba(255,255,255,.62); }

.apertura .prova {
  color: #fff; font-size: 1rem; font-weight: 500;
  border-left: 3px solid rgba(255,255,255,.5);
  padding-left: 14px;
}

/* ---------- numeri ---------- */
.numeri {
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-bottom: 1px solid var(--bordo);
}
.numeri div { padding: 30px 20px 30px 0; }
.numeri strong {
  display: block;
  font-family: var(--serif); font-weight: 400;
  font-size: 2.1rem; line-height: 1.1; color: var(--verde);
}
.numeri span { font-size: 0.9rem; color: var(--muted); }

/* ---------- griglie di card ---------- */
.griglia { display: grid; gap: 16px; }
.griglia.tre { grid-template-columns: repeat(3, 1fr); }
.griglia.due { grid-template-columns: repeat(2, 1fr); }

.scheda {
  background: var(--bianco);
  border: 1px solid var(--bordo);
  border-radius: var(--raggio);
  padding: 26px 24px 28px;
  display: flex; flex-direction: column; gap: 11px;
}
.scheda .icona { color: var(--verde); margin-bottom: 5px; }
.scheda p { color: #4A4A4A; font-size: 0.99rem; }

/* ---------- passi numerati ---------- */
.passi { display: flex; flex-direction: column; gap: 14px; }
.passo {
  display: grid; grid-template-columns: 58px 1fr;
  gap: 24px; align-items: start;
  background: var(--bianco);
  border: 1px solid var(--bordo);
  border-left: 4px solid var(--arancio);
  border-radius: var(--raggio);
  padding: 30px 30px 32px;
}
.passo .n {
  font-family: var(--sans);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.1em;
  color: var(--arancio-scuro); padding-top: 9px;
}
.passo h3 { font-size: 1.5rem; margin-bottom: 9px; }
.passo p { color: #4A4A4A; max-width: 62ch; }

/* ---------- citazioni ---------- */
.citazioni { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.citazione {
  background: var(--bianco);
  border: 1px solid var(--bordo);
  border-radius: var(--raggio);
  padding: 28px 26px;
  display: flex; flex-direction: column; gap: 16px;
}
.citazione blockquote {
  margin: 0;
  font-family: var(--serif); font-weight: 400;
  font-size: 1.28rem; line-height: 1.45; color: var(--testo);
}
.citazione footer { font-size: 0.89rem; color: var(--muted); }

/* ---------- elenchi si / no ---------- */
.elenco { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.elenco li { display: flex; gap: 12px; align-items: flex-start; color: #4A4A4A; }
.elenco svg { flex: none; margin-top: 5px; }
.elenco.si svg { color: var(--verde); }
.elenco.no svg { color: var(--muted); }

/* ---------- guide ---------- */
.guide { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.guida-card {
  border: 1px solid var(--bordo); border-radius: var(--raggio-s);
  padding: 20px 22px; text-decoration: none;
  display: flex; flex-direction: column; gap: 7px;
  background: var(--bianco);
  transition: border-color .16s ease;
}
.guida-card:hover { border-color: var(--arancio); }
.guida-card .tipo {
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--arancio-scuro);
}
.guida-card strong { font-family: var(--serif); font-weight: 400; font-size: 1.14rem; line-height: 1.3; }

/* ---------- chiusura ---------- */
.chiusura { background: var(--verde); color: #fff; position: relative; overflow: hidden; }
.chiusura .deco {
  position: absolute; width: 420px; height: 420px; border-radius: 50%;
  background: rgba(255,255,255,.055); left: -150px; bottom: -200px; pointer-events: none;
}
.chiusura .dentro { position: relative; }
.chiusura h2 { max-width: 18ch; }
.chiusura .guida { color: rgba(255,255,255,.85); }
.chiusura .sotto-bottoni { color: rgba(255,255,255,.62); }

/* ---------- piede ---------- */
.piede { border-top: 1px solid var(--bordo); padding: 54px 24px 40px; }
.piede-dentro {
  max-width: var(--colonna); margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 36px;
}
.piede h4 {
  margin: 0 0 14px; font-family: var(--sans);
  font-size: 0.74rem; font-weight: 700;
  letter-spacing: 0.13em; text-transform: uppercase; color: var(--muted);
}
.piede ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.piede a { text-decoration: none; color: #4A4A4A; font-size: 0.95rem; }
.piede a:hover { color: var(--testo); }
.piede-basso {
  max-width: var(--colonna); margin: 34px auto 0;
  padding-top: 22px; border-top: 1px solid var(--bordo);
  font-size: 0.86rem; color: var(--muted);
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .griglia.tre, .guide { grid-template-columns: repeat(2, 1fr); }
  .numeri { grid-template-columns: repeat(2, 1fr); }
  .numeri div { padding: 24px 16px 24px 0; }
  .piede-dentro { grid-template-columns: 1fr 1fr; gap: 30px; }
}
@media (max-width: 680px) {
  body { font-size: 16.5px; }
  .menu { display: none; }
  .barra-dentro { gap: 14px; }
  .barra .bottone { margin-left: auto; }
  .apertura .deco, .chiusura .deco { width: 300px; height: 300px; right: -120px; top: -120px; }
  .griglia.tre, .griglia.due, .citazioni, .guide { grid-template-columns: 1fr; }
  .passo { grid-template-columns: 1fr; gap: 8px; padding: 26px 22px 28px; }
  .passo .n { padding-top: 0; }
  .bottoni { flex-direction: column; align-items: stretch; }
  .bottone { width: 100%; }
  .piede-dentro { grid-template-columns: 1fr; gap: 26px; }
}

/* ---------- chi sono ---------- */
.chi-sono {
  display: grid; grid-template-columns: 440px 1fr; gap: 60px; align-items: stretch;
}
.fotostack { position: relative; height: 100%; min-height: 460px; }
.fotodeco {
  position: absolute; width: 250px; height: 250px; border-radius: 50%;
  background: var(--verde); opacity: .12; top: -34px; left: -40px;
}
.foto-principale {
  width: 100%; height: 100%; border-radius: var(--raggio);
  object-fit: cover; object-position: center 30%;
  position: relative;
}
.foto-polaroid {
  position: absolute; width: 46%; right: -26px; bottom: -30px;
  border: 6px solid #fff; border-radius: 10px;
  box-shadow: 0 14px 34px rgba(26,26,26,.18);
  transform: rotate(3.5deg);
}
.chi-sono .testo { display: flex; flex-direction: column; gap: 15px; max-width: 68ch; }
.chi-sono .firma {
  font-family: var(--serif); font-size: 1.15rem; color: var(--verde);
}
@media (max-width: 680px) {
  .chi-sono { grid-template-columns: 1fr; gap: 24px; }
  .chi-sono img { max-width: 220px; }
}

/* ---------- filtri e ricerca delle guide ---------- */
.filtri-guide { display: flex; flex-direction: column; gap: 18px; margin-bottom: 24px; }
.cerca {
  display: flex; align-items: center; gap: 11px;
  background: var(--bianco); border: 1px solid var(--bordo);
  border-radius: var(--raggio); padding: 0 18px; max-width: 560px;
}
.cerca svg { color: var(--muted); flex: none; }
.cerca input {
  flex: 1; min-width: 0; border: 0; outline: none; background: transparent;
  font-family: var(--sans); font-size: 1rem; padding: 16px 0; color: var(--testo);
}
.cerca input::placeholder { color: var(--muted); }
.cerca:focus-within { border-color: var(--arancio); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.fchip {
  display: inline-flex; align-items: center; gap: 7px;
  border: 1px solid var(--bordo); background: var(--bianco); color: #4A4A4A;
  border-radius: 30px; padding: 9px 16px; font-family: var(--sans);
  font-size: 0.95rem; cursor: pointer; transition: border-color .15s, background .15s;
}
.fchip:hover { border-color: var(--muted); }
.fchip .conta { font-size: 0.82rem; color: var(--muted); }
.fchip.attivo { background: var(--verde); border-color: var(--verde); color: #fff; }
.fchip.attivo .conta { color: rgba(255,255,255,.7); }
.esito { color: var(--muted); font-size: 0.95rem; margin-bottom: 14px; }
.guida-card[hidden] { display: none; }
@media (max-width: 680px) {
  .cerca input { font-size: 16px; }
  .fchip { padding: 8px 13px; font-size: 0.9rem; }
}
.nota-citazioni { font-size: 0.85rem; color: var(--muted); }

/* ---------- vetrina piattaforma: le tre schermate a cascata, come nelle guide ---------- */
.vetrina { position: relative; width: 100%; padding-bottom: 77%; margin: 30px 0 14px; }
.vetrina .sh {
  position: absolute; width: 58%; border-radius: 12px; overflow: hidden;
  border: 1px solid var(--bordo); background: var(--bianco);
  box-shadow: 0 16px 38px rgba(26,26,26,.17);
}
.vetrina .sh img { display: block; width: 100%; height: auto; }
/* le percentuali di top sono calcolate sull'altezza del contenitore (77% della larghezza) */
.vetrina .sh1 { left: 0;   top: 0;     transform: rotate(-3deg);   z-index: 1; }
.vetrina .sh2 { left: 21%; top: 27.3%; transform: rotate(1.5deg);  z-index: 2; }
.vetrina .sh3 { left: 42%; top: 54.5%; transform: rotate(-1.5deg); z-index: 3; }
.vetrina-dida { color: var(--muted); font-size: 0.92rem; text-align: center; margin: 0; }
@media (max-width: 760px) {
  /* a cascata sarebbero illeggibili: una sotto l'altra, a tutta larghezza */
  .vetrina { padding-bottom: 0; margin: 22px 0 12px;
             display: flex; flex-direction: column; gap: 12px; }
  .vetrina .sh { position: static; width: 100%; transform: none;
                 box-shadow: 0 8px 20px rgba(26,26,26,.12); }
  .vetrina-dida { text-align: left; font-size: 0.88rem; }
}

/* ---------- mobile: meno aria, meno bordi (revisione con Codex) ---------- */
@media (max-width: 680px) {
  .sezione { padding: 48px 20px; }
  .apertura { padding: 46px 20px 42px; }
  .apertura .dentro { gap: 18px; }
  .testa + * { margin-top: 28px; }
  .griglia, .citazioni { gap: 12px; }
  .scheda { padding: 20px 18px 22px; }
  .citazione { padding: 20px 18px; }
  /* i bordi servono solo dove la card non stacca dal fondo:
     sui fondi colorati la card bianca si vede da sola */
  .beige .scheda, .verdino .scheda, .beige .citazione, .verdino .citazione,
  .beige .guida-card, .verdino .guida-card { border: 0; }
  .passo { border: 0; border-left: 3px solid var(--arancio); border-radius: 0;
           background: transparent; padding: 4px 0 6px 16px; }
  .passi { gap: 22px; }
  .apertura .deco, .chiusura .deco { display: none; }
  .fotostack { min-height: 0; }
  .foto-principale { aspect-ratio: 4 / 3; height: auto; object-position: center 25%; }
  .foto-polaroid { width: 38%; right: 6px; bottom: -18px; }
  .fotodeco { display: none; }
  .numeri div { padding: 16px 12px 16px 0; }
  .numeri strong { font-size: 1.7rem; }
}

/* ---------- entrata morbida delle sezioni ---------- */
@media (prefers-reduced-motion: no-preference) {
  .riva { opacity: 0; transform: translateY(22px); transition: opacity .6s ease, transform .6s ease; }
  .riva.vista { opacity: 1; transform: none; }
  .riva:nth-child(2) { transition-delay: .07s; }
  .riva:nth-child(3) { transition-delay: .14s; }
}
