/* RetestLab, pagina d'attesa. Sistema visivo «Replay», scelto dall'utente il 22/10/2026
   (lavoro/design_pagina/STATO.md): colori del tema Laguna dell'app (Trading/RetestLab/app/statico/
   aspetto.js), Inter come nei video, il grafico del replay come unica cosa forte.
   GLI STESSI GETTONI, CON GLI STESSI NOMI, STANNO IN regali/sorgenti/stampa.css PER I PDF:
   se se ne cambia uno qui, si cambia anche là.
   Niente stili in linea (la CSP li vieta, anche dentro gli SVG): i disegni hanno solo classi. */

/* Inter 4.001 servito dalla pagina, solo coi caratteri latini (licenza OFL in font/OFL-Inter.txt;
   i file si rifanno dai TTF di macchina/font/, vedi pagina/LEGGIMI.md). */
@font-face { font-family: "Inter"; font-weight: 400; font-display: swap; src: url("font/Inter-Regular.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 600; font-display: swap; src: url("font/Inter-SemiBold.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-weight: 800; font-display: swap; src: url("font/Inter-ExtraBold.woff2") format("woff2"); }

:root {
  /* colori: Laguna (scuro) */
  --fondo: #0c1112; --fondo-grafico: #0e1315; --pannello: #141b1d; --alzato: #1b2427; --campo: #0a0e0f;
  --bordo: #1f292c; --bordo-vivo: #2f3c40; --bordo-controllo: #6b7c78;
  --testo: #e3ebe9; --tenue: #93a39f; --segnaposto: #7f8f8b; --spento: #61716d;
  --accento: #2dd4bf; --accento-acceso: #4ee0cd; --accento-testo: #04211d;
  --candela-giu: #ebebeb; --corallo: #ef6a5f;
  /* caratteri */
  --carattere: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --peso-testo: 400; --peso-forte: 600; --peso-marchio: 800;
  --corpo: 16px; --corpo-grande: 17px; --corpo-piccolo: 15px; --corpo-nota: 13.5px;
  /* spaziature e raggi */
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px; --s7: 48px; --s8: 64px;
  --raggio: 12px; --raggio-grande: 18px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--fondo); }
body { margin: 0; background: var(--fondo); color: var(--testo); font: var(--peso-testo) var(--corpo)/1.55 var(--carattere); }
::selection { background: #2dd4bf4d; color: var(--testo); }

/* ---------- comune a tutte le pagine ---------- */
.pagina { max-width: 1160px; margin: 0 auto; padding: 18px var(--s4) 40px; }
.testata { padding: 2px 0 22px; }
.marchio { font-weight: var(--peso-marchio); font-size: 19px; letter-spacing: -0.01em; }
.marchio span { color: var(--accento); }
.muto { color: inherit; text-decoration: none; }

h1 {
  font-weight: var(--peso-forte); font-size: clamp(31px, 3.6vw + 18px, 56px); line-height: 1.07;
  letter-spacing: -0.028em; margin: 0 0 14px; text-wrap: balance;
}
.sotto { color: var(--tenue); font-size: var(--corpo-grande); line-height: 1.55; margin: 0 0 22px; max-width: 36em; text-wrap: pretty; }
.piccolo { font-size: var(--corpo-nota); line-height: 1.5; color: var(--tenue); }
strong { font-weight: var(--peso-forte); }
a { color: var(--accento); text-underline-offset: 2px; }
a:focus-visible { outline: 2px solid var(--accento); outline-offset: 2px; border-radius: 2px; }
footer { margin-top: 30px; padding-top: 18px; border-top: 1px solid var(--bordo); color: var(--tenue); font-size: var(--corpo-nota); line-height: 1.6; }

/* la scheda: il modulo, e nelle pagine brevi il messaggio */
.carta { background: var(--pannello); border: 1px solid var(--bordo-vivo); border-radius: var(--raggio-grande); padding: 20px var(--s4) 18px; }

/* ---------- index ---------- */
.variante { display: none; }
.mostra-a .v-a, .mostra-b .v-b { display: block; }
.figura { margin: 0; }
.grafico { display: block; width: 100%; height: auto; border: 1px solid var(--bordo); border-radius: 14px; }

.iscrizione .carta { margin: 26px 0 0; }
h2 { font-weight: var(--peso-forte); font-size: 21px; letter-spacing: -0.012em; line-height: 1.2; margin: 0 0 var(--s4); }
label { display: block; }
.campo { display: block; font-weight: var(--peso-forte); font-size: var(--corpo-piccolo); margin: 0 0 var(--s2); }
input[type=email] {
  display: block; width: 100%; min-height: 52px; padding: var(--s3) 14px; font: var(--peso-testo) 17px/1.3 var(--carattere);
  color: var(--testo); background: var(--campo); border: 1.5px solid var(--bordo-controllo); border-radius: var(--raggio);
}
input[type=email]::placeholder { color: var(--segnaposto); opacity: 1; }
input[type=email]:focus { outline: 2px solid var(--accento); outline-offset: 2px; border-color: var(--accento); }
.cosa-arriva { font-size: var(--corpo-piccolo); line-height: 1.55; color: var(--tenue); margin: var(--s3) 0 22px; }
.cosa-arriva strong { color: var(--testo); }

.regali { border: 0; padding: 0; margin: 0 0 var(--s2); min-width: 0; }
.regali legend { padding: 0; margin: 0 0 10px; }
.scelta { display: flex; gap: var(--s3); align-items: flex-start; min-height: 44px; font-size: var(--corpo-piccolo); line-height: 1.45; margin: 0 0 var(--s2); cursor: pointer; }
.nota { color: var(--tenue); }
/* le due guide: righe con un filetto e la copertina in piccolo, non schede dentro la scheda */
.guida { align-items: center; min-height: 66px; padding: 10px 0; margin: 0; border-top: 1px solid var(--bordo-vivo); }
.guida:last-of-type { border-bottom: 1px solid var(--bordo-vivo); margin-bottom: 18px; }
.guida em { font-style: normal; font-weight: var(--peso-forte); }
.guida span { flex: 1; }
.guida:has(input:focus-visible) { outline: 2px solid var(--accento); outline-offset: 2px; border-radius: 4px; }
.copertina { flex: none; width: 32px; height: auto; order: -1; }
.guida input[type=checkbox] { order: 1; }

/* caselle disegnate: 22 px, bordo a 3,6:1 o più, spunta del colore del pulsante */
.scelta input[type=checkbox] {
  -webkit-appearance: none; appearance: none; flex: none; margin: 0; width: 22px; height: 22px;
  display: grid; place-content: center; background: var(--campo);
  border: 2px solid var(--bordo-controllo); border-radius: 6px; cursor: pointer;
}
.scelta input[type=checkbox]::before {
  content: ""; width: 12px; height: 12px; background: var(--accento-testo); transform: scale(0);
  clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}
.scelta input[type=checkbox]:checked { background: var(--accento); border-color: var(--accento); }
.scelta input[type=checkbox]:checked::before { transform: scale(1); }
.scelta input[type=checkbox]:focus-visible { outline: 2px solid var(--accento); outline-offset: 2px; }
@media (prefers-reduced-motion: no-preference) {
  .scelta input[type=checkbox]::before { transition: transform .12s ease-out; }
}
@media (forced-colors: active) {
  .scelta input[type=checkbox] { border-color: CanvasText; }
  .scelta input[type=checkbox]::before { background: CanvasText; }
}

button {
  display: block; width: 100%; min-height: 54px; margin: 18px 0 0; padding: 0 var(--s4);
  font: var(--peso-forte) 17px/1.2 var(--carattere); color: var(--accento-testo); background: var(--accento);
  border: 0; border-radius: var(--raggio); cursor: pointer; -webkit-tap-highlight-color: transparent;
}
button:hover { background: var(--accento-acceso); }
button:focus-visible { outline: 2px solid var(--testo); outline-offset: 3px; }
button:disabled { opacity: .6; cursor: default; }
.carta .piccolo { margin: var(--s3) 0 0; }
.trappola { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* i quattro punti: una candelina verde acqua al posto della freccia */
.punti { list-style: none; padding: 0; margin: 34px 0 0; }
.punti li { position: relative; padding: 14px 0 14px 26px; border-top: 1px solid var(--bordo); }
.punti li:last-child { border-bottom: 1px solid var(--bordo); }
.punti li::before { content: ""; position: absolute; left: 3px; top: 20px; width: 7px; height: 12px; border-radius: 1.5px; background: var(--accento); }
.punti li::after { content: ""; position: absolute; left: 6px; top: 16px; width: 1.5px; height: 20px; background: var(--accento); }
.avviso { margin: 26px 0 0; }

/* ---------- grazie e confermato: una cosa sola da fare ---------- */
.breve { max-width: 640px; }
.breve .testata { padding-bottom: var(--s6); }
.esito { padding: var(--s5) 20px 22px; }
.esito h1, .breve > h1 { font-size: clamp(31px, 2.4vw + 22px, 44px); }
.esito .sotto { margin-bottom: var(--s4); }
.esito .piccolo { margin: 0; }
.busta { display: block; width: 72px; height: auto; margin: 0 0 18px; }
.pdf { list-style: none; padding: 0; margin: 0 0 22px; }
.pdf li + li { margin-top: 10px; }
.pdf a {
  display: flex; align-items: center; gap: 14px; min-height: 76px; padding: var(--s3) 14px;
  color: var(--testo); text-decoration: none; font-size: var(--corpo-grande); line-height: 1.35;
  background: var(--pannello); border: 1px solid var(--bordo-vivo); border-radius: 14px;
}
.pdf a span { flex: 1; }
.pdf a:hover { border-color: var(--accento); }
.pdf a:focus-visible { outline: 2px solid var(--accento); outline-offset: 2px; border-radius: 14px; }
.pdf .copertina { width: 40px; order: 0; }
.scarica { flex: none; width: 24px; height: 24px; }

/* ---------- privacy: testo lungo da leggere ---------- */
.testo-lungo { max-width: 760px; }
.testo-lungo h1.medio { font-size: clamp(31px, 2.4vw + 22px, 44px); margin-bottom: var(--s2); }
.testo-lungo > .piccolo:first-of-type { margin: 0 0 var(--s6); }
.testo-lungo h2 { font-size: 20px; margin: 40px 0 var(--s3); }
.testo-lungo p, .testo-lungo li { font-size: var(--corpo-grande); line-height: 1.65; color: #d0d8d6; max-width: 40em; }
.testo-lungo p { margin: 0 0 var(--s4); }
.testo-lungo strong { color: var(--testo); }
.testo-lungo ul { padding-left: 22px; margin: 0 0 var(--s4); }
.testo-lungo li { margin: 0 0 10px; padding-left: 2px; }
.testo-lungo li::marker { color: var(--accento); }
.testo-lungo table { width: 100%; border-collapse: collapse; margin: var(--s2) 0 var(--s5); font-size: var(--corpo-piccolo); line-height: 1.5; }
.testo-lungo th, .testo-lungo td { text-align: left; vertical-align: top; padding: 14px 16px 14px 0; border-bottom: 1px solid var(--bordo-vivo); }
.testo-lungo th { font-size: 12.5px; font-weight: var(--peso-forte); letter-spacing: .06em; text-transform: uppercase; padding-top: 0; }
.testo-lungo th:first-child, .testo-lungo td:first-child { color: var(--testo); width: 56%; }
.testo-lungo th + th, .testo-lungo td + td { color: var(--tenue); padding-right: 0; }

/* ---------- i disegni (strumenti/grafici.py): solo classi, i colori stanno qui ---------- */
.g-fondo { fill: var(--fondo-grafico); }
.g-griglia { stroke: #162022; stroke-width: 1; fill: none; }
.g-futuro { fill: var(--campo); }
.g-su { fill: var(--accento); }
.g-giu { fill: var(--candela-giu); }
.g-stoppino-su { stroke: var(--accento); stroke-width: 1.4; fill: none; }
.g-stoppino-giu { stroke: var(--candela-giu); stroke-width: 1.4; fill: none; }
.g-cursore { stroke: var(--accento); stroke-width: 1.3; stroke-dasharray: 3 4; fill: none; }
.g-livello { stroke: var(--accento); stroke-opacity: .4; stroke-dasharray: 2 4; fill: none; }
.g-prezzo { fill: var(--accento); }
.g-asse { stroke: #26332f; stroke-width: 1.2; fill: none; }
.g-segno { fill: var(--alzato); }
.g-testa { fill: #3a4a47; }
.g-censura { fill: var(--testo); }
.g-occhio { fill: none; stroke: var(--tenue); stroke-width: 1.6; stroke-linecap: round; }
.g-play-fondo { fill: var(--accento); }
.g-play { fill: var(--accento-testo); }
.g-passo { fill: var(--tenue); stroke: var(--tenue); stroke-width: 2; }
.g-traccia { stroke: #243034; stroke-width: 4; stroke-linecap: round; fill: none; }
.g-corsa { stroke: var(--accento); stroke-width: 4; stroke-linecap: round; fill: none; }
.g-manopola { fill: var(--testo); }
.g-base { stroke: #3a4a47; stroke-width: 1.2; stroke-dasharray: 2 4; fill: none; }
.g-obiettivo { stroke: var(--accento); stroke-width: 2; stroke-dasharray: 7 6; fill: none; }
.g-bandiera { fill: var(--accento); }
.g-pavimento { stroke: var(--corallo); stroke-width: 2.6; fill: none; stroke-linejoin: round; }
.g-conto { stroke: var(--candela-giu); stroke-width: 2.2; fill: none; stroke-linejoin: round; stroke-linecap: round; }
.g-uscita { fill: var(--corallo); }
.g-uscita-alone { fill: none; stroke: var(--corallo); stroke-width: 2; stroke-opacity: .5; }
.c-fondo { fill: var(--fondo-grafico); stroke: var(--bordo-controllo); stroke-width: 1; }
.c-punto { fill: var(--accento); }
.c-titolo { stroke: var(--testo); stroke-width: 3.2; stroke-linecap: round; fill: none; }
.c-casella { fill: none; stroke: var(--tenue); stroke-width: 1.2; }
.c-piena { fill: var(--accento); stroke: var(--accento); }
.c-riga { stroke: var(--spento); stroke-width: 2; stroke-linecap: round; fill: none; }
.c-linea { fill: none; stroke: var(--candela-giu); stroke-width: 1.8; stroke-linejoin: round; }
.c-rete { stroke: var(--corallo); stroke-width: 2.2; fill: none; }
.b-corpo { fill: var(--alzato); stroke: var(--bordo-controllo); stroke-width: 2; }
.b-lembo { fill: none; stroke: var(--testo); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.b-punto { fill: var(--accento); }
.s-freccia { fill: none; stroke: var(--accento); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- telefono: la tabella dell'informativa diventa un elenco ---------- */
@media (max-width: 599px) {
  .testo-lungo table, .testo-lungo tbody, .testo-lungo tr, .testo-lungo th, .testo-lungo td { display: block; width: auto; }
  .testo-lungo th:first-child, .testo-lungo td:first-child { width: auto; }
  .testo-lungo tr:first-child { display: flex; flex-wrap: wrap; gap: var(--s1) var(--s5); padding-bottom: var(--s2); border-bottom: 1px solid var(--bordo-vivo); }
  .testo-lungo tr:first-child th { padding: 0; border: 0; }
  .testo-lungo tr + tr { padding: 14px 0; border-bottom: 1px solid var(--bordo-vivo); }
  .testo-lungo td { padding: 0; border: 0; }
  .testo-lungo td + td { margin-top: var(--s2); }
}

/* ---------- dal tablet in su: la promessa a sinistra, il modulo a destra e sempre in vista ---------- */
@media (min-width: 960px) {
  .pagina { padding: 26px 40px 48px; }
  .iscrizione {
    display: grid; grid-template-columns: minmax(0, 1fr) 400px; column-gap: 72px; align-items: start;
    grid-template-areas: "testata testata" "apertura modulo" "punti modulo" "avviso modulo" "piede piede";
  }
  .iscrizione .testata { grid-area: testata; padding-bottom: 52px; }
  .iscrizione .apertura { grid-area: apertura; }
  .iscrizione .carta { grid-area: modulo; position: sticky; top: 24px; margin: 0; padding: var(--s5) var(--s5) 20px; }
  .iscrizione .punti { grid-area: punti; margin-top: 40px; }
  .iscrizione .avviso { grid-area: avviso; }
  .iscrizione footer { grid-area: piede; margin-top: var(--s7); }
  .iscrizione .sotto { font-size: 19px; margin-bottom: 30px; }
  .breve .testata, .testo-lungo .testata { padding-bottom: var(--s7); }
  .esito { padding: var(--s6) var(--s6) 28px; }
}
