/* theme/volantino.css: «La Valley su un foglio». A schermo due facciate di carta, una sotto l'altra;
   in stampa solo quelle, una per pagina A4: davanti la mappa con i numeri, dietro l'elenco.
   Il foglio è carta anche col tema scuro: inchiostro scuro su bianco, il rosso solo per gli sconti. */
.volantino-comandi { margin: 0 0 18px; padding: 4px 0 4px 14px; border-left: 4px solid var(--red); font-family: var(--cond); font-size: 18px; line-height: 1.35; }
.volantino-comandi p { margin: 0; }
.volantino-comandi[hidden], .volantino[hidden] { display: none; }
.vl-errore a { text-underline-offset: 3px; }

.volantino { display: grid; grid-template-columns: minmax(0, 1fr); justify-items: center; gap: 32px; margin: 8px 0 0; }
.vl-fronte, .vl-retro {
  --vl-ink: #17163a; --vl-red: #b5341f; --vl-muted: #4a475e; --vl-line: #c9bfa8;
  --ink: var(--vl-ink); --text: var(--vl-ink); --red: var(--vl-red); --muted: var(--vl-muted); --line: var(--vl-line);
  color-scheme: light; box-sizing: border-box; display: flex; flex-direction: column;
  width: 100%; max-width: 794px; aspect-ratio: 210 / 297; padding: 45px;
  background: #fff; color: var(--vl-ink); font-size: 17px; line-height: 1.4; overflow-wrap: break-word;
  box-shadow: 0 1px 2px rgb(0 0 0 / .14), 0 10px 28px rgb(0 0 0 / .12);
}
.vl-fronte p, .vl-retro p { margin: 0; }

/* davanti */
.vl-testata { display: flex; align-items: center; gap: 10px; padding-bottom: 8px; border-bottom: 1px solid var(--vl-ink); font-family: var(--cond); font-size: 20px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.vl-testata img { width: 30px; height: 30px; }
.vl-titolo { margin: 18px 0 0; font-size: 64px; line-height: 1; letter-spacing: -.02em; color: var(--vl-ink); text-wrap: balance; }
.vl-fronte .vl-sotto { margin-top: 10px; font-size: 24px; font-style: italic; }
.vl-sotto [data-vl-quanti] { font-family: var(--cond); font-style: normal; font-weight: 700; }
.vl-mappa { margin: 26px 0 0; padding: 6px 0; border-block: 3px double var(--vl-ink); color: var(--vl-ink); }
.vl-passi { display: grid; grid-template-columns: minmax(0, 1fr) 180px; gap: 0 30px; margin-top: auto; padding-top: 24px; }
.vl-fronte .vl-passi-titolo { grid-column: 1; font-family: var(--cond); font-size: 18px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--vl-red); }
.vl-passi ol { grid-column: 1; margin: 10px 0 0; padding: 0; list-style: none; counter-reset: vl-passo; }
.vl-passi li { position: relative; margin: 0 0 10px; padding-left: 44px; font-size: 21px; line-height: 1.3; counter-increment: vl-passo; }
.vl-passi li::before { content: counter(vl-passo); position: absolute; left: 0; top: -2px; font-family: var(--cond); font-size: 34px; font-weight: 700; line-height: 1; }
.vl-fronte .vl-qr { grid-column: 2; grid-row: 1 / span 2; align-self: end; font-family: var(--cond); font-size: 15px; line-height: 1.25; }
.vl-qr img { display: block; width: 180px; height: 180px; margin-bottom: 8px; background: #fff; }
.vl-qr b { font-size: 19px; }

/* la mappa del centro: solo strade, fiume e nomi, presi da cammina.css; i numeri li mette volantino.js */
.vl-mappa .cm-mappa { display: block; width: 100%; height: auto; }
.vl-mappa .cm-mappa path { fill: none; vector-effect: non-scaling-stroke; }
.vl-mappa .cm-m-leno { stroke: #4a9cc2; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.vl-mappa .cm-m-ferrovia { stroke: currentColor; stroke-width: 1.5; stroke-dasharray: 6 4; opacity: .6; }
.vl-mappa .cm-m-strade { stroke: currentColor; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; opacity: .5; }
.vl-mappa .cm-mappa path.cm-m-rocca, .vl-mappa .cm-mappa path.cm-m-stazione { fill: currentColor; stroke: none; opacity: .5; }
.vl-mappa .cm-m-nome { font-family: var(--cond); font-size: 34px; font-weight: 700; fill: currentColor; paint-order: stroke; stroke: #fff; stroke-width: 6px; stroke-linejoin: round; }
.vl-mappa .cm-m-acqua { fill: #2b7ea6; font-style: italic; }
.vl-mappa .cm-m-vicino, .vl-mappa .cm-m-punto, .vl-mappa .cm-m-tratto, .vl-mappa [data-cm-tu] { display: none; }
.vl-segno circle { fill: #fff; stroke: var(--vl-ink); stroke-width: 4; }
.vl-segno text { font-family: var(--mono); font-size: 25px; font-weight: 700; fill: var(--vl-ink); text-anchor: middle; dominant-baseline: central; }
.vl-guida { stroke: var(--vl-ink); stroke-width: 2.5; stroke-linecap: round; }
.vl-vero { fill: var(--vl-ink); stroke: #fff; stroke-width: 1.5; }

/* dietro */
.vl-titolo-retro { margin: 0; padding-bottom: 6px; border-bottom: 3px double var(--vl-ink); font-size: 44px; line-height: 1; letter-spacing: -.015em; color: var(--vl-ink); }
.vl-retro .vl-legenda { display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 8px 0 4px; font-family: var(--cond); font-size: 15px; }
.vl-legenda span { display: inline-block; font: inherit; color: inherit; }
.vl-elenco { margin: 8px 0 0; padding: 0; list-style: none; columns: 2; column-gap: 30px; column-rule: 1px solid var(--vl-line); }
.vl-elenco:empty { display: none; }
.vl-elenco li { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 0 8px; align-items: start; padding: 6px 0; border-bottom: 1px dotted var(--vl-line); break-inside: avoid; }
.vl-fuori li { grid-template-columns: minmax(0, 1fr); }
.vl-n { box-sizing: border-box; width: 30px; height: 30px; border: 2.5px solid var(--vl-ink); border-radius: 50%; font-family: var(--mono); font-size: 14px; font-weight: 700; line-height: 25px; text-align: center; }
.vl-voce { min-width: 0; line-height: 1.25; }
.vl-nome { font-size: 18px; font-weight: 700; }
.vl-ln, .vl-sc { white-space: nowrap; font-family: var(--mono); font-size: 14px; }
.vl-sc { font-weight: 700; color: var(--vl-red); }
.vl-ind { display: block; margin-top: 1px; font-family: var(--cond); font-size: 15px; color: var(--vl-muted); }
.vl-retro .vl-fuori-titolo { margin: 18px 0 0; font-family: var(--cond); font-size: 16px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.vl-retro .vl-fuori-titolo[hidden] { display: none; }
.vl-retro .vl-piede { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--vl-ink); font-family: var(--cond); font-size: 14px; line-height: 1.35; color: var(--vl-muted); }
.vl-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* telefono: il foglio resta carta, ma si allunga quanto serve per leggerlo */
@media (max-width: 700px) {
  .volantino { gap: 20px; }
  .vl-fronte, .vl-retro { padding: 18px 16px; font-size: 16px; }
  .vl-titolo { margin-top: 12px; font-size: clamp(32px, 10vw, 52px); }
  .vl-fronte .vl-sotto { font-size: 18px; }
  .vl-testata { font-size: 16px; }
  .vl-mappa { margin-top: 14px; }
  .vl-passi { grid-template-columns: minmax(0, 1fr); padding-top: 16px; }
  .vl-passi li { padding-left: 30px; font-size: 17px; }
  .vl-passi li::before { font-size: 24px; }
  .vl-fronte .vl-qr { grid-column: 1; grid-row: auto; display: flex; align-items: center; gap: 12px; margin-top: 8px; }
  .vl-qr img { flex: none; width: 104px; height: 104px; margin: 0; }
  .vl-titolo-retro { font-size: 34px; }
  .vl-elenco { columns: 1; }
  .vl-nome { font-size: 17px; }
}

@media print {
  @page { size: A4; margin: 12mm; }
  html, body { background: #fff !important; }
  body > :not(main), main > :not(.page), .page > :not(.volantino) { display: none !important; }
  main, .page { max-width: none !important; margin: 0 !important; padding: 0 !important; }
  .volantino { display: block; margin: 0; }
  .vl-fronte, .vl-retro {
    --vl-ink: #000; --vl-muted: #333; --vl-line: #999;
    width: 100%; max-width: none; height: 270mm; aspect-ratio: auto; padding: 0; overflow: hidden;
    box-shadow: none; break-inside: avoid; -webkit-print-color-adjust: exact; print-color-adjust: exact;
  }
  .vl-fronte { break-after: page; }
  .vl-elenco li { border-bottom-style: solid; border-bottom-width: .5pt; }
}
