/* ═══════════════════════════════════════════════════════════════════════
   ZENIT WEB — core.css
   Token, reset, tipografia e componenti condivisi fra mobile e desktop.
   I file desktop.css e mobile.css aggiungono solo il layout.
   ═══════════════════════════════════════════════════════════════════════ */

/* ─────────────────────────────────────────────────────────────── font */
@font-face {
  font-family: 'Satoshi';
  src: url('../fonts/satoshi-400.woff2') format('woff2');
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('../fonts/satoshi-500.woff2') format('woff2');
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('../fonts/satoshi-700.woff2') format('woff2');
  font-weight: 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Satoshi';
  src: url('../fonts/satoshi-900.woff2') format('woff2');
  font-weight: 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-latin.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
  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: 'Inter';
  src: url('../fonts/inter-latin-ext.woff2') format('woff2');
  font-weight: 100 900; font-style: normal; font-display: swap;
  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;
}

/* ───────────────────────────────────────────────────────────── token */
:root {
  /* superfici */
  --bg:        #FBFBF9;
  --surface:   #FFFFFF;
  --muted:     #F5F5F2;
  --line:      #E8E8E3;
  --line-soft: #F0F0EC;

  /* testo
     I due grigi tenui sono tarati sul contrasto, non a occhio: su fondo
     #FBFBF9 danno 5,7:1 e 4,7:1, entrambi sopra la soglia WCAG AA di 4,5:1.
     Il grigio più chiaro che avevamo prima (#8A8A90) si fermava a 3,3:1 ed
     era illeggibile per chi ha una vista anche solo un po' ridotta. */
  --ink:       #0B0B0C;
  --ink-2:     #3A3A40;
  --ink-3:     #64646B;
  --ink-4:     #71717B;

  /* accento */
  --accent:      #1B4DFF;
  --accent-dark: #143BC7;
  --accent-tint: #EEF2FF;

  /* stato */
  --danger:    #C42B1C;
  --success:   #0E7C4A;

  /* tipografia */
  --font-display: 'Satoshi', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

  /* forme */
  --r-sm:  8px;
  --r-md:  14px;
  --r-lg:  20px;
  --r-xl:  28px;
  --r-pill: 100px;

  /* movimento */
  --ease:  cubic-bezier(.22, 1, .36, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --dur:   .55s;

  /* ombre — quasi impercettibili, coerenti con lo stile editoriale */
  --shadow-sm: 0 1px 2px rgba(11,11,12,.04);
  --shadow-md: 0 4px 24px -8px rgba(11,11,12,.10);
  --shadow-lg: 0 24px 60px -20px rgba(11,11,12,.16);
}

/* ───────────────────────────────────────────────────────────── reset */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  font-feature-settings: 'kern' 1, 'liga' 1, 'cv11' 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -.03em;
  line-height: 1.08;
  margin: 0;
  text-wrap: balance;
}

p { margin: 0; text-wrap: pretty; }

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

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

button, input, textarea, select {
  font: inherit;
  color: inherit;
  margin: 0;
}

ul, ol { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--accent); color: #fff; }

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

/* Testo solo per i lettori di schermo: invisibile ma presente */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* Salta al contenuto: obbligatorio per la navigazione da tastiera */
.skip {
  position: absolute;
  left: -9999px;
  top: 12px;
  z-index: 999;
  background: var(--ink);
  color: #fff;
  padding: 12px 20px;
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 600;
}
.skip:focus { left: 12px; }

/* honeypot: invisibile all'utente, presente per i bot */
.hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px; height: 1px;
  overflow: hidden;
}

/* ───────────────────────────────────────────────────── tipografia utile */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.eyebrow::before {
  content: '';
  width: 20px; height: 1px;
  background: var(--accent);
}

.lede {
  font-size: 1.15em;
  line-height: 1.6;
  color: var(--ink-2);
}

.accent { color: var(--accent); }
.muted  { color: var(--ink-3); }

/* la marcatura <em> negli h1 diventa il tocco di colore, non il corsivo */
h1 em, h2 em, h3 em {
  font-style: normal;
  color: var(--accent);
}

/* ─────────────────────────────────────────────────────────── pulsanti */
.btn {
  --btn-bg: var(--ink);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 26px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -.01em;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), background .25s ease;
  -webkit-tap-highlight-color: transparent;
}
.btn .ico { transition: transform .35s var(--ease); flex-shrink: 0; }
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn:hover .ico { transform: translateX(4px); }
.btn:active { transform: translateY(0); }

.btn--accent { --btn-bg: var(--accent); }
.btn--accent:hover { background: var(--accent-dark); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  border-color: var(--line);
}
.btn--ghost:hover { background: var(--surface); border-color: var(--ink); }

.btn--block { width: 100%; }

/* collegamento testuale con sottolineatura che si estende */
.link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: var(--accent);
  position: relative;
  padding-bottom: 2px;
}
.link::after {
  content: '';
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .4s var(--ease);
}
.link:hover::after { transform: scaleX(1); transform-origin: left; }
.link .ico { transition: transform .35s var(--ease); }
.link:hover .ico { transform: translate(3px, -3px); }

/* ────────────────────────────────────────────────────────── superfici */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  transition: border-color .35s var(--ease), transform .45s var(--ease), box-shadow .45s var(--ease);
}
.card:hover { border-color: #D8D8D2; transform: translateY(-3px); box-shadow: var(--shadow-md); }

.hair { height: 1px; background: var(--line); border: 0; margin: 0; }

/* ───────────────────────────────────────────────────────────── marchio */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -.04em;
  color: var(--ink);
}
.brand__mark { flex-shrink: 0; }
.brand__mark path, .brand__mark polyline { transition: none; }
.brand b { font-weight: 700; }
.brand span { color: var(--accent); font-weight: 700; }

/* ────────────────────────────────────────────────────────── modulo */
.field { display: flex; flex-direction: column; gap: 7px; }

.field label {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  letter-spacing: -.005em;
}
.field label .req { color: var(--accent); }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 16px; /* sotto i 16px iOS ingrandisce la pagina all'attivazione */
  line-height: 1.5;
  color: var(--ink);
  transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;
  appearance: none;
}
.field textarea { resize: vertical; min-height: 132px; }

.field select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236B6B70' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 44px;
  cursor: pointer;
}

.field input::placeholder,
.field textarea::placeholder { color: var(--ink-4); }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(27, 77, 255, .12);
}

.field--error input,
.field--error select,
.field--error textarea { border-color: var(--danger); }

.field__err {
  font-size: 13px;
  color: var(--danger);
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* ─────────────────────────────────────────── selettore su misura ──────
   Il <select> nativo si può vestire solo da chiuso: la tendina aperta la
   disegna il sistema operativo e nessun CSS la raggiunge. Questo componente
   la ridisegna per intero. Il <select> vero resta nel DOM — nascosto ma
   presente — così il modulo si invia normalmente e senza JS funziona tutto
   come prima. */
.sel { position: relative; }

/* il select originale sparisce alla vista ma non dal modulo */
.sel__native {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.sel__btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
  transition: border-color .25s ease, box-shadow .25s ease;
  -webkit-tap-highlight-color: transparent;
}
.sel__btn:hover { border-color: #D2D2CC; }
.sel__btn[aria-expanded="true"] {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(27, 77, 255, .12);
}
.sel__btn .ico {
  flex-shrink: 0;
  color: var(--ink-3);
  transition: transform .35s var(--ease);
}
.sel__btn[aria-expanded="true"] .ico { transform: rotate(180deg); }

/* finché non si sceglie nulla il testo resta da segnaposto */
.sel__btn.is-empty .sel__label { color: var(--ink-4); }
.sel__label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.field--error .sel__btn { border-color: var(--danger); }

/* ── pannello delle voci ── */
.sel__panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
.sel__panel:focus { outline: none; }

.sel__group {
  padding: 14px 16px 6px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.sel__group + .sel__opt { margin-top: 0; }

.sel__opt {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 16px;
  font-size: 15px;
  color: var(--ink-2);
  cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.sel__opt:hover,
.sel__opt.is-active {            /* is-active = voce raggiunta da tastiera */
  background: var(--muted);
  color: var(--ink);
}
.sel__opt[aria-selected="true"] {
  background: var(--accent-tint);
  color: var(--accent);
  font-weight: 600;
}
.sel__opt .ico { flex-shrink: 0; opacity: 0; transition: opacity .18s ease; }
.sel__opt[aria-selected="true"] .ico { opacity: 1; }

/* consenso privacy */
.check {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  cursor: pointer;
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--ink-3);
}
.check input {
  width: 19px; height: 19px;
  flex-shrink: 0;
  margin-top: 2px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--surface);
  cursor: pointer;
  transition: background .2s ease, border-color .2s ease;
  position: relative;
}
.check input:checked {
  background: var(--accent);
  border-color: var(--accent);
}
.check input:checked::after {
  content: '';
  position: absolute;
  left: 6px; top: 2px;
  width: 5px; height: 10px;
  border: solid #fff;
  border-width: 0 2px 2px 0;
  transform: rotate(43deg);
}
.check a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }

/* avviso globale del modulo */
.alert {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 15px 18px;
  border-radius: var(--r-md);
  font-size: 14.5px;
  line-height: 1.55;
}
.alert--error {
  background: #FDF2F1;
  color: #8E2318;
  border: 1px solid #F5D6D2;
}
.alert .ico { flex-shrink: 0; margin-top: 2px; }

/* ─────────────────────────────────────────── loghi in scorrimento */
.marquee {
  overflow: hidden;
  position: relative;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent);
}
.marquee__track {
  display: flex;
  width: max-content;
  animation: marquee 42s linear infinite;
}
.marquee:hover .marquee__track { animation-play-state: paused; }
.marquee__item {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  opacity: .62;
  filter: grayscale(1);
  transition: opacity .4s ease, filter .4s ease;
}
.marquee__item:hover { opacity: 1; filter: grayscale(0); }

@keyframes marquee {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-50%, 0, 0); }
}

/* ───────────────────────────────────────────────────────── fisarmonica */
.acc__item { border-bottom: 1px solid var(--line); }
.acc__item:first-child { border-top: 1px solid var(--line); }

.acc__head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 0;
  background: none;
  border: 0;
  text-align: left;
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -.02em;
  color: var(--ink);
  transition: color .25s ease;
}
.acc__head:hover { color: var(--accent); }

.acc__sign {
  flex-shrink: 0;
  width: 32px; height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  transition: transform .45s var(--ease), background .3s ease, border-color .3s ease, color .3s ease;
}
.acc__head[aria-expanded="true"] .acc__sign {
  transform: rotate(45deg);
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.acc__body {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows .45s var(--ease);
}
.acc__body > div { overflow: hidden; }
.acc__item.is-open .acc__body { grid-template-rows: 1fr; }
.acc__body p {
  color: var(--ink-2);
  padding-bottom: 26px;
  max-width: 68ch;
}

/* ──────────────────────────────────────────────────────── rivelazione */
/* Niente will-change qui, per due motivi.
   1) Su un antenato crea un blocco contenitore: qualunque elemento
      position:fixed discendente — il pannello del selettore, per dire —
      smetterebbe di ancorarsi al viewport e resterebbe appeso dentro
      la scheda, tagliato a metà.
   2) Su 51 elementi resterebbe in memoria per sempre, mentre serve solo
      per gli 0,8 secondi dell'animazione.
   Opacità e transform sono comunque composte dalla GPU anche senza. */
[data-reveal] {
  opacity: 0;
  transform: translate3d(0, 22px, 0);
  transition:
    opacity .8s var(--ease-out) var(--reveal-delay, 0s),
    transform .8s var(--ease-out) var(--reveal-delay, 0s);
}
[data-reveal].is-in {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}
/* Senza JS il contenuto deve restare visibile: mai nascondere per sempre. */
.no-js [data-reveal] { opacity: 1; transform: none; }

/* Variante "bare": il contenitore riceve is-in ma non si nasconde mai.
   Innesca disegni interni (la linea del processo) senza sommare una
   seconda dissolvenza a quella dei figli. */
[data-reveal="bare"] { opacity: 1; transform: none; transition: none; }

/* Senza JS il configuratore sarebbe una fila di pulsanti morti: sparisce,
   e restano le schede dei piani che dicono già tutto. */
.no-js .quiz { display: none; }

/* Stessa sorte per il check-up: senza JS il modulo non può far niente,
   e il modulo contatti qui sotto fa lo stesso lavoro con una persona vera. */
.no-js #checkup { display: none; }

/* ──────────────────────────────────────────────────────────── mappa */
.map {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--muted);
  isolation: isolate;
}

.map__canvas {
  position: relative;
  width: 100%;
  /* Altezza esplicita: il contenitore non ha contenuto in flusso che la generi,
     e senza questa il renderer disegnerebbe su un'area di zero pixel. */
  height: 260px;
  overflow: hidden;
  touch-action: none;      /* il trascinamento lo gestiamo noi */
  cursor: grab;
  background:
    repeating-linear-gradient(45deg, #EFEFEB 0 12px, #F4F4F0 12px 24px);
}
.map.is-live .map__canvas { background: #E9E5DC; }  /* tinta delle tessere OSM */
.map.is-dragging .map__canvas { cursor: grabbing; }

.map__layer { position: absolute; inset: 0; }

.map__tile {
  position: absolute;
  top: 0; left: 0;
  width: 256px;
  height: 256px;
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.map__pin {
  position: absolute;
  top: 0; left: 0;
  z-index: 3;
  pointer-events: none;
  filter: drop-shadow(0 3px 6px rgba(11,11,12,.28));
}

/* schermata di consenso: nessuna tessera parte prima del clic */
.map__gate {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: grid;
  place-items: center;
  padding: 24px;
  text-align: center;
  background: var(--muted);
  transition: opacity .4s var(--ease), visibility .4s;
}
.map__gate.is-gone { opacity: 0; visibility: hidden; }
.map__gate-in { display: flex; flex-direction: column; align-items: center; gap: 5px; max-width: 320px; }
.map__gate-in .ico { color: var(--accent); margin-bottom: 4px; }
.map__gate-in b { font-family: var(--font-display); font-size: 16px; letter-spacing: -.02em; }
.map__gate-in small { font-size: 13px; color: var(--ink-3); }
.map__gate-in .btn { margin-top: 12px; padding: 11px 22px; font-size: 14px; background: var(--surface); }
.map__gate-note { font-size: 10.5px; line-height: 1.5; color: var(--ink-4); margin-top: 8px; }

/* comandi di scala */
/* display:flex vincerebbe sull'attributo hidden dello UA stylesheet:
   senza questa riga i pulsanti si vedono anche a mappa non ancora caricata. */
.map__zoom[hidden] { display: none; }

.map__zoom {
  position: absolute;
  top: 10px; right: 10px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  gap: 1px;
  border-radius: 9px;
  overflow: hidden;
  box-shadow: 0 1px 4px rgba(11,11,12,.18);
}
.map__zbtn {
  width: 32px; height: 32px;
  display: grid;
  place-items: center;
  background: rgba(255,255,255,.95);
  border: 0;
  color: var(--ink-2);
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.map__zbtn:hover { background: #fff; color: var(--accent); }

/* Attribuzione OpenStreetMap: obbligatoria per licenza ODbL,
   ridotta al minimo indispensabile e ancorata in basso a destra. */
.map__credit {
  position: absolute;
  right: 6px;
  bottom: 6px;
  z-index: 5;
  padding: 2px 7px;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-radius: 5px;
  font-size: 9.5px;
  line-height: 1.5;
  letter-spacing: 0;
}
.map__credit a { color: var(--ink-3); text-decoration: none; }
.map__credit a:hover { text-decoration: underline; }

.map__open {
  position: absolute;
  left: 10px; bottom: 8px;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  box-shadow: 0 1px 4px rgba(11,11,12,.12);
  transition: color .25s ease;
}
.map__open:hover { color: var(--accent); }

/* ───────────────────────────────────────────────────── piè di pagina */
.foot { border-top: 1px solid var(--line); }
.foot a { color: var(--ink-3); transition: color .25s ease; }
.foot a:hover { color: var(--ink); }
.foot__legal {
  font-size: 12.5px;
  color: var(--ink-4);
  line-height: 1.75;
}

/* ═══════════════════════════════════════════════════════════════════════
   MOVIMENTO
   Tutto quello che segue è governato dal blocco prefers-reduced-motion
   in fondo al file: chi ha chiesto meno animazioni non ne vede nessuna.
   ═══════════════════════════════════════════════════════════════════════ */

/* ── titolo che sale parola per parola ─────────────────────────────────
   Ogni parola sta in una finestrella con overflow nascosto e scivola su
   da sotto. È l'animazione più costosa in termini di attenzione, quindi
   sta solo sul titolo principale e su nessun'altra cosa. */
.rise { display: block; }
.rise > span {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
  padding-bottom: .08em;   /* spazio per i discendenti: senza, la g si taglia */
  margin-bottom: -.08em;
}
.rise > span > b {
  display: inline-block;
  font-weight: inherit;
  animation: riseUp .95s var(--ease-out) both;
  animation-delay: var(--d, 0s);
}
@keyframes riseUp {
  from { transform: translateY(105%); }
  to   { transform: translateY(0); }
}
/* Ritardi a scalare: le parole entrano una dopo l'altra.
   In CSS e non inline, così la CSP resta pulita. */
.rise > span:nth-child(1) > b { --d: .06s; }
.rise > span:nth-child(2) > b { --d: .15s; }
.rise > span:nth-child(3) > b { --d: .24s; }
.rise > span:nth-child(4) > b { --d: .33s; }
.rise > span:nth-child(5) > b { --d: .42s; }

.no-js .rise > span > b { animation: none; }

/* ── barra di avanzamento della lettura ───────────────────────────────── */
.progress {
  position: fixed;
  top: 0; left: 0;
  z-index: 300;
  height: 2px;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left;
  background: linear-gradient(90deg, var(--accent), #7C5BFF);
  pointer-events: none;
  will-change: transform;
}

/* ── lampo che attraversa i pulsanti al passaggio ─────────────────────── */
.btn::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 38%, rgba(255,255,255,.28) 50%, transparent 62%);
  transform: translateX(-120%);
  transition: transform .75s var(--ease);
  pointer-events: none;
}
.btn:hover::before { transform: translateX(120%); }
.btn > * { position: relative; z-index: 1; }

/* ── la lineetta dell'occhiello si allunga quando entra in vista ──────── */
.eyebrow::before {
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .7s var(--ease-out) .15s;
}
.eyebrow.is-in::before,
.is-in .eyebrow::before,
.no-js .eyebrow::before { transform: scaleX(1); }

/* ── fascia scura: lo stesso contrasto del richiamo finale ─────────────
   Spezza il ritmo della pagina e fa risaltare i numeri, che altrimenti
   su fondo chiaro passavano inosservati. */
.band {
  position: relative;
  background: var(--ink);
  border-radius: var(--r-xl);
  overflow: hidden;
  isolation: isolate;
}
.band::before {
  content: '';
  position: absolute;
  top: -60%; left: 50%;
  width: 780px; height: 780px;
  margin-left: -390px;
  background: radial-gradient(circle, rgba(27,77,255,.34), transparent 64%);
  pointer-events: none;
  z-index: 0;
  animation: breathe 9s ease-in-out infinite alternate;
}
/* reticolo appena percettibile, come nell'hero ma in negativo */
.band::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.045) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000, transparent 76%);
          mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000, transparent 76%);
  pointer-events: none;
  z-index: 0;
}
.band > * { position: relative; z-index: 1; }

@keyframes breathe {
  from { transform: scale(1)    translateY(0);     opacity: .85; }
  to   { transform: scale(1.14) translateY(26px);  opacity: 1; }
}

/* ── faretto che segue il puntatore sulle schede ───────────────────────
   Le coordinate arrivano dal JS come variabili CSS. Senza JS non succede
   nulla e la scheda resta esattamente com'era. */
/* Niente overflow:hidden qui: taglierebbe il badge "Il più scelto",
   che sporge sopra il bordo della scheda. Il bagliore lo contengo con
   il raggio ereditato dalla scheda stessa. */
.spot { position: relative; }
.spot::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(
    340px circle at var(--mx, 50%) var(--my, 50%),
    rgba(27, 77, 255, .09),
    transparent 62%
  );
  opacity: 0;
  transition: opacity .45s var(--ease);
  pointer-events: none;
  z-index: 0;
}
.spot:hover::before { opacity: 1; }
.spot > * { position: relative; z-index: 1; }

/* ── l'attributo hidden vince sempre ───────────────────────────────────
   Un display esplicito (flex, grid…) batterebbe l'attributo hidden dello
   UA stylesheet: senza questa riga un pannello "nascosto" resterebbe lì. */
[hidden] { display: none !important; }

/* ── puntino di presenza: pulsa accanto alla promessa di risposta ────── */
.livedot {
  position: relative;
  display: inline-block;
  width: 8px; height: 8px;
  margin-right: 7px;
  vertical-align: 1px;
  border-radius: 50%;
  background: var(--success);
}
.livedot::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 50%;
  background: var(--success);
  animation: livedot 2.4s ease-out infinite;
}
@keyframes livedot {
  from { transform: scale(.6);  opacity: .55; }
  70%  { transform: scale(2.4); opacity: 0; }
  to   { transform: scale(2.4); opacity: 0; }
}

/* ─────────────────────────────────────── configuratore dei piani ──────
   Due domande, nessun dato raccolto: tutto succede nel browser.
   Il markup sta in partials/quiz.php, la logica in wizard.js. */
.quiz {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-xl);
  padding: 34px 36px 36px;
  margin-bottom: 44px;
  position: relative;
  overflow: hidden;
}
/* filo d'accento in alto: segnala che questo blocco è "vivo" */
.quiz::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 2px;
  background: linear-gradient(90deg, var(--accent), #7C5BFF);
}

.quiz__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; }
.quiz__head h3 { font-size: 22px; letter-spacing: -.025em; }
.quiz__head p { margin-top: 6px; font-size: 14.5px; color: var(--ink-3); max-width: 52ch; }
.quiz__badge {
  flex-shrink: 0;
  padding: 6px 13px;
  background: var(--accent-tint);
  color: var(--accent);
  border-radius: var(--r-pill);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .02em;
  white-space: nowrap;
}

.quiz__q { margin-top: 26px; }
.quiz__label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 13px;
}

.quiz__chips { display: flex; flex-wrap: wrap; gap: 9px; }
.quiz__chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-pill);
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color .22s ease, background .22s ease, color .22s ease, transform .3s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.quiz__chip .ico { color: var(--ink-4); transition: color .22s ease; }
.quiz__chip:hover { border-color: var(--ink); transform: translateY(-1px); }
.quiz__chip[aria-pressed="true"] {
  background: var(--accent-tint);
  border-color: var(--accent);
  color: var(--accent);
  font-weight: 600;
}
.quiz__chip[aria-pressed="true"] .ico { color: var(--accent); }

.quiz__paynote {
  margin-top: 12px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-3);
  max-width: 62ch;
}

/* passi 3 e 4 fianco a fianco dove lo spazio c'è */
.quiz__pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 28px;
  align-items: start;
}

/* ── la riga che apre il popup: tutto il configuratore in 90 pixel ── */
.quizlaunch {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 20px 24px;
  margin-bottom: 40px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  position: relative;
  overflow: hidden;
}
.quizlaunch::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 2px;
  background: linear-gradient(90deg, var(--accent), #7C5BFF);
}
.quizlaunch b {
  display: block;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -.02em;
}
.quizlaunch span {
  display: block;
  margin-top: 3px;
  font-size: 13.5px;
  color: var(--ink-3);
}
.quizlaunch .btn { flex-shrink: 0; padding: 12px 22px; font-size: 14.5px; }
.no-js .quizlaunch { display: none; }

/* ── il popup del preventivo veloce ─────────────────────────────────── */
dialog.quizmodal {
  width: min(760px, calc(100vw - 32px));
  max-height: min(88vh, 880px);
  margin: auto;
  padding: 0;
  border: 0;
  border-radius: var(--r-xl);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}
/* nei browser senza <dialog> resterebbe visibile in fondo alla pagina */
dialog.quizmodal:not([open]) { display: none; }

/* Col popup aperto la pagina dietro resta ferma: senza questo blocco la
   rotella e il dito scorrevano lo sfondo. La classe la mette wizard.js;
   è la stessa che usa il menù a tutto schermo del telefono. */
body.is-locked { overflow: hidden; }

.quizmodal::backdrop {
  background: rgba(11, 11, 12, .45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.quizmodal[open] { animation: modalin .35s var(--ease-out); }
@keyframes modalin {
  from { opacity: 0; transform: translateY(14px) scale(.98); }
  to   { opacity: 1; transform: none; }
}

.quizmodal__close {
  position: sticky;
  top: 12px;
  z-index: 6;
  display: grid;
  place-items: center;
  width: 36px; height: 36px;
  margin: 12px 12px -48px auto;
  background: var(--muted);
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--ink-2);
  cursor: pointer;
  transition: background .2s ease, color .2s ease, transform .3s var(--ease);
}
.quizmodal__close:hover { background: var(--ink); color: #fff; transform: rotate(90deg); }

/* dentro il popup la carta perde cornice e si stringe */
.quizmodal .quiz {
  border: 0;
  border-radius: 0;
  margin: 0;
  padding: 26px 30px 30px;
}
.quizmodal .quiz__head h3 { font-size: 21px; }
.quizmodal .quiz__head p { font-size: 13.5px; }
.quizmodal .quiz__q { margin-top: 20px; }
.quizmodal .quiz__chip { padding: 8px 13px; font-size: 13px; }
.quizmodal .quiz__label { margin-bottom: 10px; }
.quizmodal .quiz__result { margin-top: 22px; }
.quizmodal .quiz__verdict { padding: 18px 22px; }

/* domanda 2, risultato e passo finale compaiono scivolando, senza scatti */
.quiz__q--late, .quiz__result, .quiz__go {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .5s var(--ease-out), transform .5s var(--ease-out);
}
.quiz__q--late.is-shown, .quiz__result.is-shown, .quiz__go.is-shown { opacity: 1; transform: none; }

.quiz__result { margin-top: 28px; }
.quiz__verdict {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px 28px;
  padding: 22px 26px;
  background: var(--accent-tint);
  border: 1px solid #DBE3FF;
  border-radius: var(--r-lg);
}
.quiz__verdict-in { max-width: 56ch; }
.quiz__reco {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 6px;
}
.quiz__verdict h4 {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -.03em;
  margin: 0 0 5px;
}
.quiz__verdict h4 small {
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 500;
  color: var(--ink-2);
  letter-spacing: 0;
  margin-left: 4px;
}
.quiz__why { font-size: 14.5px; color: var(--ink-2); line-height: 1.6; }
.quiz__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.quiz__actions .btn { padding: 12px 22px; font-size: 14.5px; }
.quiz__redo {
  border: 0;
  background: none;
  padding: 4px 2px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-3);
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color .22s ease;
}
.quiz__redo:hover { color: var(--ink); }

/* ── il passo finale del preventivo: nome ed email, dentro il popup ── */
.quiz__go {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.quiz__golabel {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 13px;
}
.quiz__gogrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.quiz__gophone { grid-column: 1 / -1; }
.quiz__go .field label small { font-weight: 400; color: var(--ink-4); }
.quiz__go .check { margin-top: 14px; }
.quiz__go .btn { margin-top: 14px; }
.quiz__gofoot {
  margin-top: 10px;
  font-size: 12px;
  color: var(--ink-4);
  text-align: center;
}

/* scheda del piano consigliato dal configuratore */
.plan--reco { border-color: var(--accent) !important; box-shadow: 0 0 0 3px rgba(27, 77, 255, .14), var(--shadow-lg); }
/* Un'etichetta alla volta: il consiglio personale batte la statistica,
   e sul telefono i due badge si pesterebbero i piedi. */
.plan--reco .plan__badge { display: none; }
.plan__reco {
  position: absolute;
  top: -12px; right: 24px;
  padding: 6px 14px;
  background: var(--ink);
  color: #fff;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
}

/* ═══════════════════════════════════════════════════════════════════════
   v1.4 — componenti condivisi: riga che si riscrive, prima/dopo,
   area amministratore di prova, check-up, scontrino, sitino a fasi
   ═══════════════════════════════════════════════════════════════════════ */

/* ── la riga dell'hero che si riscrive da sola ───────────────────────── */
.typeline {
  margin-top: 20px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 23px;
  letter-spacing: -.02em;
  color: var(--ink-3);
}
.typeline__w { color: var(--accent); }
.typeline__caret {
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-left: 3px;
  vertical-align: -.12em;
  background: var(--accent);
  animation: caret 1.1s steps(1) infinite;
}
@keyframes caret { 50% { opacity: 0; } }

/* ── prima/dopo: il cursore che divide i due mondi ───────────────────── */
.cmp { max-width: 980px; margin: 0 auto; }

.cmp__stage {
  --split: 50%;
  position: relative;
  height: 470px;
  border-radius: var(--r-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
  background: var(--surface);
  /* pan-y, non none: lo scorrimento verticale della pagina resta al browser,
     a noi arrivano solo i gesti orizzontali. Un riquadro a tutta larghezza
     con touch-action:none ingoierebbe lo scroll del telefono. */
  touch-action: pan-y;
  cursor: ew-resize;
  isolation: isolate;
}

.cmp__pane { position: absolute; inset: 0; }
.cmp__pane--new { clip-path: inset(0 0 0 var(--split)); }

.cmp__bar {
  position: absolute;
  top: 0; bottom: 0;
  left: var(--split);
  width: 2px;
  margin-left: -1px;
  background: var(--ink);
  z-index: 3;
  pointer-events: none;
}

.cmp__handle {
  position: absolute;
  top: 50%;
  left: var(--split);
  transform: translate(-50%, -50%);
  z-index: 4;
  width: 46px; height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  border-radius: 50%;
  background: var(--ink);
  color: #fff;
  border: 2px solid #fff;
  box-shadow: var(--shadow-md);
  cursor: ew-resize;
  touch-action: none;   /* chi afferra la maniglia ha il controllo pieno */
}
.cmp__handle .ico { flex-shrink: 0; margin: 0 -2px; }
.cmp__cw { transform: scaleX(-1); }

/* finché nessuno lo tocca, il comando respira per farsi notare */
.cmp:not(.is-touched) .cmp__handle { animation: nudge 2.4s ease-in-out infinite; }
@keyframes nudge {
  0%, 100% { box-shadow: var(--shadow-md), 0 0 0 0 rgba(27, 77, 255, .35); }
  50%      { box-shadow: var(--shadow-md), 0 0 0 12px rgba(27, 77, 255, 0); }
}

.cmp__tag {
  position: absolute;
  top: 14px;
  z-index: 3;
  padding: 5px 13px;
  border-radius: var(--r-pill);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  pointer-events: none;
}
.cmp__tag--old { left: 14px;  background: rgba(11, 11, 12, .72); color: #fff; }
.cmp__tag--new { right: 14px; background: var(--accent); color: #fff; }

/* il "prima": volutamente d'epoca, coi suoi font di sistema */
.old {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: #F7F5EA;
  font-family: 'Times New Roman', Georgia, serif;
  color: #1A2C56;
  overflow: hidden;
}
.old__head {
  background: linear-gradient(#3A63B8, #24427E);
  color: #fff;
  text-align: center;
  padding: 16px 10px 11px;
}
.old__title {
  display: block;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: .04em;
  text-shadow: 1px 1px 0 rgba(0, 0, 0, .7);
}
.old__sub { font-style: italic; font-size: 12.5px; color: #FFE27A; }
.old__nav {
  display: flex;
  justify-content: center;
  gap: 3px;
  background: #D9D2B8;
  padding: 6px;
  font-size: 11.5px;
  font-weight: 700;
}
.old__nav span {
  padding: 3px 11px;
  background: #EFE9D2;
  border: 1px outset #FFFFFF;
  color: #24427E;
  text-decoration: underline;
}
.old__body { display: flex; gap: 14px; padding: 16px; flex: 1; min-height: 0; }
.old__img {
  width: 40%;
  background: repeating-conic-gradient(#C9C2A8 0 25%, #BDB493 0 50%) 0 0 / 22px 22px;
  border: 2px inset #999;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-style: italic;
  color: #6B6448;
  text-align: center;
  padding: 8px;
}
.old__text { flex: 1; font-size: 13.5px; line-height: 1.5; }
.old__pdf {
  display: inline-block;
  margin-top: 10px;
  color: #0000CC;
  font-weight: 700;
  text-decoration: underline;
}
.old__hours { margin-top: 10px; color: #802020; font-weight: 700; }
.old__foot {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 12px;
  background: #24427E;
  color: #CFD8EE;
  font-size: 10px;
  padding: 6px 10px;
}

/* il "dopo": la nostra mano, gli stessi token del sito vero */
.new {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  padding: 16px 22px 18px;
}
.new__nav {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 11px;
  border-bottom: 1px solid var(--line-soft);
  font-family: var(--font-display);
}
.new__logo { width: 14px; height: 14px; border-radius: 5px; background: var(--accent); }
.new__nav b { font-size: 13px; letter-spacing: -.02em; }
.new__links { margin-left: auto; display: flex; gap: 7px; }
.new__links i { width: 22px; height: 5px; border-radius: 3px; background: var(--line); }
.new__pill {
  background: var(--ink);
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  padding: 4px 11px;
  border-radius: var(--r-pill);
}
/* L'hero del "dopo" è centrato apposta: il sipario del confronto può
   fermarsi ovunque, e da qualsiasi metà si deve vedere qualcosa di bello. */
.new__hero {
  padding: 18px 0 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.new__eyebrow {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.new__h {
  margin-top: 8px;
  font-family: var(--font-display);
  font-size: 29px;
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1.03;
}
.new__h em { font-style: normal; color: var(--accent); }
.new__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  width: fit-content;
  margin-top: 13px;
  background: var(--accent);
  color: #fff;
  padding: 8px 15px;
  border-radius: var(--r-pill);
  font-size: 11.5px;
  font-weight: 600;
}
.new__open {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 11px;
  font-size: 11px;
  color: var(--ink-3);
}
.new__open i { width: 7px; height: 7px; border-radius: 50%; background: var(--success); }
.new__cards {
  margin-top: auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}
.new__card { height: 58px; border-radius: 10px; }
.new__card--a { background: linear-gradient(135deg, #DCE6FF, #C4D3FF); }
.new__card--b { background: linear-gradient(135deg, #EBE7DC, #DCD5C2); }
.new__card--c { background: linear-gradient(135deg, #DDEDE2, #C4DECB); }

/* ── area amministratore di prova: fascia scura, comandi veri ────────── */
.demoband, .checkband { padding: 54px 52px; }

.demo__eyebrow, .check__eyebrow {
  display: block;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #9DB4FF;
  margin-bottom: 14px;
}
.demo h2, .chk h2 {
  color: #fff;
  font-size: clamp(25px, 2.4vw, 33px);
  letter-spacing: -.03em;
}
.demo__intro p, .check__intro p {
  margin-top: 12px;
  color: rgba(255, 255, 255, .62);
  font-size: 15px;
  line-height: 1.65;
  max-width: 54ch;
}

.demo__panel {
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: var(--r-lg);
  padding: 16px 18px 10px;
}
.demo__phead {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.demo__pdot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #34C77B;
  box-shadow: 0 0 8px rgba(52, 199, 123, .7);
  flex-shrink: 0;
}
.demo__saved {
  margin-left: auto;
  font-size: 11px;
  font-weight: 500;
  color: #8BE6B4;
  opacity: 0;
  transition: opacity .3s ease;
  text-align: right;
}
.demo__saved.is-on { opacity: 1; }

.demo__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 0;
}
.demo__row + .demo__row,
.demo__phead + .demo__row { border-top: 0; }
.demo__row { border-bottom: 1px solid rgba(255, 255, 255, .08); }
.demo__row:last-child { border-bottom: 0; }
.demo__row b { display: block; color: #fff; font-size: 13.5px; font-weight: 600; letter-spacing: -.01em; }
.demo__row small { display: block; color: rgba(255, 255, 255, .48); font-size: 11.5px; line-height: 1.45; }
.demo__row--switch { cursor: pointer; }

/* interruttore: il checkbox vero resta sopra, invisibile ma cliccabile */
.demo__switch { position: relative; flex-shrink: 0; }
.demo__switch input {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
  z-index: 2;
}
.demo__switch i {
  display: block;
  width: 46px; height: 26px;
  border-radius: var(--r-pill);
  background: rgba(255, 255, 255, .18);
  transition: background .25s ease;
}
.demo__switch i::after {
  content: '';
  position: absolute;
  top: 3px; left: 3px;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: #fff;
  transition: transform .25s var(--ease);
}
.demo__switch input:checked + i { background: var(--danger); }
.demo__switch input:checked + i::after { transform: translateX(20px); }
.demo__switch input:focus-visible + i { outline: 2px solid #fff; outline-offset: 2px; }

.demo__step { display: inline-flex; align-items: center; gap: 5px; flex-shrink: 0; }
.demo__step button {
  width: 30px; height: 30px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(255, 255, 255, .08);
  color: #fff;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  transition: background .2s ease;
}
.demo__step button:hover { background: rgba(255, 255, 255, .18); }
.demo__step output {
  min-width: 52px;
  text-align: center;
  color: #fff;
  font-size: 13.5px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* il sitino accanto al pannello */
.demo__site {
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: var(--r-lg);
  overflow: hidden;
  align-self: start;
}
.demo__url {
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--muted);
  color: var(--ink-3);
  font-size: 10.5px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--line-soft);
}
.demo__url .ico { color: var(--success); }
.demo__page { padding: 14px 16px 16px; }
.demo__nav {
  display: flex;
  align-items: center;
  gap: 7px;
  font-family: var(--font-display);
  font-size: 12.5px;
  padding-bottom: 10px;
}
.demo__logo { width: 12px; height: 12px; border-radius: 4px; background: var(--accent); }
.demo__status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 11.5px;
  font-weight: 600;
  transition: background .3s ease, color .3s ease;
}
.demo__status i { width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.demo__status--open   { background: #E5F4EC; color: var(--success); }
.demo__status--closed { background: #FDF2F1; color: var(--danger); }
.demo__dish {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.demo__dish b { font-size: 12px; letter-spacing: -.01em; }
.demo__dish small { display: block; font-size: 10.5px; color: var(--ink-4); }
.demo__price {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 900;
  letter-spacing: -.03em;
  font-variant-numeric: tabular-nums;
}
.demo__cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 12px;
  background: var(--accent);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  transition: opacity .3s ease, filter .3s ease;
}
.demo__cta.is-off { opacity: .35; filter: grayscale(1); text-decoration: line-through; }

/* ── check-up del sito ───────────────────────────────────────────────── */
.check__form { display: flex; gap: 10px; margin-top: 24px; max-width: 560px; }
.check__form input {
  flex: 1;
  min-width: 0;
  padding: 13px 16px;
  border-radius: var(--r-md);
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .22);
  color: #fff;
  font-size: 16px;
}
.check__form input::placeholder { color: rgba(255, 255, 255, .4); }
.check__form input:focus {
  outline: none;
  border-color: #7FA0FF;
  box-shadow: 0 0 0 3px rgba(127, 160, 255, .25);
}
.check__form .btn { flex-shrink: 0; }

.check__err { margin-top: 12px; color: #FFB4A8; font-size: 14px; }

.check__out {
  margin-top: 26px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .5s var(--ease-out), transform .5s var(--ease-out);
}
.check__out.is-shown { opacity: 1; transform: none; }

.check__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}
.check__head b { color: #fff; font-size: 15px; letter-spacing: -.01em; overflow-wrap: anywhere; }
.check__score {
  flex-shrink: 0;
  padding: 5px 13px;
  border-radius: var(--r-pill);
  font-size: 12.5px;
  font-weight: 700;
}
.check__score--ok   { background: rgba(20, 150, 90, .28);  color: #8BE6B4; }
.check__score--warn { background: rgba(190, 150, 30, .28); color: #F4D77E; }
.check__score--fail { background: rgba(196, 43, 28, .28);  color: #FFB4A8; }

.check__list { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.check__row {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  padding: 13px 15px;
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--r-md);
  animation: checkrow .5s var(--ease-out) both;
  animation-delay: var(--cd, 0s);
}
@keyframes checkrow {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: none; }
}
.check__row i {
  width: 10px; height: 10px;
  border-radius: 50%;
  margin-top: 5px;
  flex-shrink: 0;
}
.check__row--ok i   { background: #34C77B; box-shadow: 0 0 10px rgba(52, 199, 123, .55); }
.check__row--warn i { background: #F4C542; box-shadow: 0 0 10px rgba(244, 197, 66, .5); }
.check__row--fail i { background: #FF6B5A; box-shadow: 0 0 10px rgba(255, 107, 90, .5); }
.check__row b { display: block; color: #fff; font-size: 13.5px; letter-spacing: -.01em; }
.check__row small { display: block; margin-top: 2px; color: rgba(255, 255, 255, .55); font-size: 12px; line-height: 1.5; }

.check__cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px 18px;
  margin-top: 18px;
}
.check__cta p { color: rgba(255, 255, 255, .65); font-size: 13.5px; max-width: 52ch; }
.check__cta .btn { --btn-bg: #fff; --btn-fg: var(--ink); flex-shrink: 0; }
.check__cta .btn:hover { --btn-bg: var(--accent); --btn-fg: #fff; }

/* ── lo scontrino del configuratore ──────────────────────────────────── */
.quiz__bill {
  margin-top: 14px;
  padding: 12px 14px;
  max-width: 400px;
  background: var(--surface);
  border: 1px dashed #B9C8FF;
  border-radius: var(--r-md);
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.quiz__bill li {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  font-size: 13.5px;
  color: var(--ink-2);
}
.quiz__bill b { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.quiz__bill-total { padding-top: 7px; border-top: 1px solid var(--line); color: var(--ink); font-weight: 600; }
.quiz__bill-total b { font-weight: 800; color: var(--accent); }
.quiz__bill-note, .quiz__bill-note b { font-size: 12px; font-weight: 500; color: var(--ink-4); }

/* ── il sitino che si costruisce (bmock), guidato da data-phase ──────── */
.bmock {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.bmock__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 13px;
  background: var(--muted);
  border-bottom: 1px solid var(--line-soft);
}
.bmock__dot { width: 8px; height: 8px; border-radius: 50%; background: #E2E2DC; }
.bmock__url {
  margin-left: 9px;
  flex: 1;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 11px;
  background: var(--surface);
  border: 1px solid var(--line-soft);
  border-radius: 7px;
  font-size: 11px;
  color: var(--ink-3);
}
.bmock__lock { color: var(--ink-4); transition: color .5s ease; }

.bmock__page { padding: 20px 22px 22px; transition: opacity .5s ease, filter .5s ease; }
.bmock__nav {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line-soft);
}
.bmock__logo { width: 14px; height: 14px; border-radius: 5px; background: var(--line); transition: background .5s ease; }
.bmock__name {
  font-family: var(--font-display);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: -.02em;
  color: transparent;
  background: var(--line-soft);
  border-radius: 4px;
  transition: color .5s ease, background .5s ease;
}
.bmock__links { margin-left: auto; display: flex; gap: 7px; }
.bmock__links i { width: 22px; height: 5px; border-radius: 3px; background: var(--line-soft); }
.bmock__pill { width: 46px; height: 15px; border-radius: var(--r-pill); background: var(--line-soft); transition: background .5s ease; }

.bmock__h {
  margin-top: 15px;
  width: fit-content;
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1.06;
  color: transparent;
  background: var(--line-soft);
  border-radius: 6px;
  transition: color .5s ease, background .5s ease;
}
.bmock__h em { font-style: normal; color: inherit; transition: color .5s ease; }
.bmock__lines { display: flex; flex-direction: column; gap: 5px; margin-top: 10px; }
.bmock__lines i { display: block; height: 5px; border-radius: 3px; background: var(--line-soft); }
.bmock__lines i:nth-child(1) { width: 74%; }
.bmock__lines i:nth-child(2) { width: 56%; }
.bmock__cta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 14px;
  padding: 7px 13px;
  border-radius: var(--r-pill);
  font-size: 10.5px;
  font-weight: 600;
  background: var(--line-soft);
  color: transparent;
  transition: color .5s ease, background .5s ease;
}
.bmock__cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.bmock__card { border: 1px solid var(--line-soft); border-radius: 9px; overflow: hidden; }
.bmock__card span { display: block; height: 38px; background: var(--line-soft); transition: background .5s ease; }
.bmock__card i { display: block; height: 4px; border-radius: 2px; background: var(--line-soft); margin: 8px 9px; }

/* fase 0: solo appunti e sagome sbiadite */
[data-phase="0"] .bmock__page { opacity: .45; filter: grayscale(1); }

/* dai colori (fase 2 in su) */
[data-phase="2"] .bmock__logo, [data-phase="3"] .bmock__logo { background: var(--accent); }
[data-phase="2"] .bmock__pill, [data-phase="3"] .bmock__pill { background: var(--ink); }
[data-phase="2"] .bmock__name, [data-phase="3"] .bmock__name { color: var(--ink); background: transparent; }
[data-phase="2"] .bmock__h,    [data-phase="3"] .bmock__h    { color: var(--ink); background: transparent; }
[data-phase="2"] .bmock__h em, [data-phase="3"] .bmock__h em { color: var(--accent); }
[data-phase="2"] .bmock__cta,  [data-phase="3"] .bmock__cta  { color: #fff; background: var(--accent); }
[data-phase="2"] .bmock__card--a span, [data-phase="3"] .bmock__card--a span { background: linear-gradient(135deg, #DCE6FF, #C4D3FF); }
[data-phase="2"] .bmock__card--b span, [data-phase="3"] .bmock__card--b span { background: linear-gradient(135deg, #EBE7DC, #DCD5C2); }
[data-phase="2"] .bmock__card--c span, [data-phase="3"] .bmock__card--c span { background: linear-gradient(135deg, #DDEDE2, #C4DECB); }
[data-phase="3"] .bmock__lock { color: var(--success); }

/* sovrapposizioni: ogni fase accende la sua */
.bmock__note, .bmock__palette, .bmock__codechip, .bmock__done {
  position: absolute;
  z-index: 3;
  opacity: 0;
  transform: translateY(8px) scale(.96);
  transition: opacity .45s var(--ease-out), transform .45s var(--ease-out);
  pointer-events: none;
}
.bmock__note {
  background: #FFF7D6;
  border: 1px solid #EFE0A6;
  color: #6B5D20;
  font-size: 11px;
  line-height: 1.4;
  padding: 7px 11px;
  border-radius: 8px;
  box-shadow: var(--shadow-md);
  rotate: -2deg;
  max-width: 55%;
}
.bmock__note--a { top: 22%; left: 5%; }
.bmock__note--b { top: 46%; right: 6%; rotate: 2deg; }
.bmock__palette {
  bottom: 16%;
  left: 6%;
  display: flex;
  align-items: center;
  gap: 6px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 8px 12px;
  border-radius: 10px;
  box-shadow: var(--shadow-md);
}
.bmock__palette i { width: 14px; height: 14px; border-radius: 50%; }
.bmock__palette i:nth-child(1) { background: var(--accent); }
.bmock__palette i:nth-child(2) { background: var(--ink); }
.bmock__palette i:nth-child(3) { background: #E8E4D8; border: 1px solid var(--line); }
.bmock__palette b {
  margin-left: 3px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--ink-4);
}
.bmock__codechip {
  bottom: 22%;
  right: 6%;
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--ink);
  color: #7FA0FF;
  padding: 9px 12px;
  border-radius: 10px;
  box-shadow: var(--shadow-md);
}
.bmock__codechip b { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-size: 11px; font-weight: 700; }
.bmock__codechip i { width: 24px; height: 4px; border-radius: 2px; background: rgba(255, 255, 255, .28); }
.bmock__done {
  top: 44px;
  right: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--success);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 7px 12px;
  border-radius: var(--r-pill);
  box-shadow: var(--shadow-md);
}

[data-phase="0"] .bmock__note     { opacity: 1; transform: none; }
[data-phase="1"] .bmock__palette  { opacity: 1; transform: none; }
[data-phase="2"] .bmock__codechip { opacity: 1; transform: none; }
[data-phase="3"] .bmock__done     { opacity: 1; transform: none; }

/* variante mini: dentro i passaggi della versione mobile */
.bmock--mini { box-shadow: var(--shadow-sm); margin-bottom: 16px; }
.bmock--mini .bmock__page { padding: 13px 14px 14px; }
.bmock--mini .bmock__h { font-size: 15px; margin-top: 10px; }
.bmock--mini .bmock__cta { margin-top: 10px; padding: 5px 10px; font-size: 9.5px; }
.bmock--mini .bmock__cards { margin-top: 11px; gap: 7px; }
.bmock--mini .bmock__card span { height: 22px; }
.bmock--mini .bmock__card i { margin: 5px 6px; height: 3px; }
.bmock--mini .bmock__note { font-size: 9.5px; padding: 5px 8px; }
.bmock--mini .bmock__note--b { display: none; }
.bmock--mini .bmock__palette { padding: 6px 9px; }
.bmock--mini .bmock__palette i { width: 11px; height: 11px; }
.bmock--mini .bmock__codechip { padding: 6px 9px; }
.bmock--mini .bmock__done { top: 40px; font-size: 10px; padding: 5px 10px; }

/* ── temi di settore: ogni mestiere il suo colore ────────────────────── */
[data-look] { --lookA: var(--accent); --lookB: var(--accent-tint); }
[data-look="utensils"]  { --lookA: #C2410C; --lookB: #FFEDD5; }
[data-look="bed"]       { --lookA: #0E7490; --lookB: #CFFAFE; }
[data-look="coffee"]    { --lookA: #92400E; --lookB: #FBE8CC; }
[data-look="scissors"]  { --lookA: #BE185D; --lookB: #FCE7F3; }
[data-look="activity"]  { --lookA: #15803D; --lookB: #DCFCE7; }
[data-look="briefcase"] { --lookA: #1E3A8A; --lookB: #DBEAFE; }
[data-look="heart"]     { --lookA: #0F766E; --lookB: #CCFBF1; }
[data-look="tool"]      { --lookA: #A16207; --lookB: #FEF3C7; }
[data-look="car"]       { --lookA: #374151; --lookB: #E5E7EB; }

/* ── transizioni fra pagina e pagina ───────────────────────────────────
   Dove il browser le supporta, il passaggio home ↔ settore diventa una
   dissolvenza morbida invece di un lampo bianco. Dove no, non cambia nulla. */
@view-transition { navigation: auto; }
::view-transition-old(root),
::view-transition-new(root) { animation-duration: .24s; }

/* ─────────────────────────────────────────────── movimento ridotto */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    /* Anche i ritardi a zero: senza, le coreografie sfalsate (mockup,
       chip) resterebbero invisibili e "popperebbero" una alla volta. */
    animation-delay: 0s !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
  [data-reveal] { opacity: 1 !important; transform: none !important; }
  .marquee__track { animation: none; }

  /* Le nuove animazioni vanno spente in modo esplicito: con la sola
     durata a .01ms resterebbero ferme sul fotogramma finale, che per il
     bagliore della fascia scura significa "ingrandito e spostato". */
  .rise > span > b { animation: none; transform: none; }
  .band::before    { animation: none; transform: none; opacity: .9; }
  .progress        { display: none; }
  .btn::before     { display: none; }
  .eyebrow::before { transform: scaleX(1) !important; }
  .spot::before    { display: none; }

  /* niente pulsazione: resta il puntino fermo, che è l'informazione */
  .livedot::before { animation: none; opacity: 0; }

  /* mockup e chip dell'hero: fermi e visibili, senza coreografia */
  .mock__in, .chip { animation: none; opacity: 1; transform: none; translate: none; }

  /* cursore del prima/dopo fermo, lampeggio della riga che si riscrive spento */
  .cmp:not(.is-touched) .cmp__handle { animation: none; }
  .typeline__caret { animation: none; }

  /* le righe del check-up appaiono e basta */
  .check__row { animation: none; opacity: 1; transform: none; }

  /* il configuratore appare e basta, senza scivolare */
  .quiz__q--late, .quiz__result, .quiz__go { transition: none; }
  .quizmodal[open] { animation: none; }

  /* cambio pagina secco, senza dissolvenza */
  @view-transition { navigation: none; }
}

/* ───────────────────────────────────────────────────────── stampa */
@media print {
  .nav, .foot, .btn, .marquee { display: none !important; }
  body { background: #fff; font-size: 12pt; }
  a[href^="http"]::after { content: ' (' attr(href) ')'; font-size: 9pt; color: #666; }
}
