/* Il Messicano: il giro, in profondità. Token in DESIGN.md */

/* ---------- Toni per tappa ---------- */
[data-tone="pista"]    { --sky-a:#0A0A0C; --sky-b:#2A1114; --glow:#FF5A1F; --ink:#F6F3EF; --soft:#BDB4AC; --accent:#FF6A2B; --on-accent:#120405; }
[data-tone="brand"]    { --sky-a:#150B05; --sky-b:#5A2C10; --glow:#F5A742; --ink:#FFF2E0; --soft:#E4C79E; --accent:#F7B455; --on-accent:#150B05; }
[data-tone="bivio"]    { --sky-a:#1B0D06; --sky-b:#71320D; --glow:#FFB45C; --ink:#FFF2E0; --soft:#E4C79E; --accent:#FF9B45; --on-accent:#1B0D06; }
[data-tone="criminal"] { --sky-a:#BFC4C9; --sky-b:#E8EAEC; --glow:#FFFFFF; --ink:#0D0F12; --soft:#3A4149; --accent:#B0111C; --on-accent:#FFF5F5; }
[data-tone="fuego"]    { --sky-a:#200400; --sky-b:#8E2506; --glow:#FF9E33; --ink:#FFF0E2; --soft:#F3CBA6; --accent:#FFAE55; --on-accent:#200400; }
[data-tone="garage"]   { --sky-a:#B4BCC4; --sky-b:#DFE4E8; --glow:#FFFFFF; --ink:#0E141A; --soft:#3B4650; --accent:#17466B; --on-accent:#EAF2F8; }
[data-tone="box"]      { --sky-a:#071310; --sky-b:#17452F; --glow:#4FE0A2; --ink:#ECFBF3; --soft:#A9D7C2; --accent:#6FE8B6; --on-accent:#071310; }
[data-tone="social"]   { --sky-a:#170D0F; --sky-b:#55202E; --glow:#FF7FA8; --ink:#FFEFF3; --soft:#EFC6D1; --accent:#FF8FB2; --on-accent:#170D0F; }
[data-tone="strada"]   { --sky-a:#060709; --sky-b:#191D23; --glow:#FF5A1F; --ink:#EDEAE6; --soft:#A8A39D; --accent:#FF7A3D; --on-accent:#060709; }

:root {
  --f-display: "Bricolage Grotesque", "Arial Narrow", system-ui, sans-serif;
  --f-body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-flap: "Oswald", "Arial Narrow", Impact, sans-serif;
  --gutter: max(1rem, 4vw);
}

@supports (content-visibility: auto) {
  html:not(.is-3d) .ch { content-visibility: auto; contain-intrinsic-size: 100vh; }
}
/* Future scroll-driven effects stay opt-in: the current JS camera remains authoritative. */
@supports (animation-timeline: scroll()) {
  .is-3d .road { contain: paint; }
}
@supports not (scroll-timeline-name: none) {
  .road { opacity: .95; }
}

*, *::before, *::after { box-sizing: border-box; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
html { color-scheme: dark; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 400 1.0625rem/1.55 var(--f-body);
  background: #0A0A0C;
  color: #F6F3EF;
}
img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
a { color: inherit; }

h1, h2 {
  font-family: var(--f-display);
  font-variation-settings: "wdth" 82;
  font-weight: 760;
  line-height: .95;
  letter-spacing: -.02em;
  margin: 0 0 .35em;
  text-wrap: balance;
}
h1 { font-size: clamp(3rem, 8.4vw, 7.4rem); }
h1 .sub { display: block; font-weight: 420; font-size: .5em; letter-spacing: .01em; color: var(--accent); margin-top: .12em; }
h2 { font-size: clamp(2.3rem, 5.6vw, 4.8rem); }

.skip {
  position: fixed; left: 1rem; top: -4rem; z-index: 100;
  background: #FFFFFF; color: #0A0A0C; padding: .7rem 1rem; font-weight: 600; text-decoration: none;
}
.skip:focus { top: 1rem; }

/* Focus a doppio anello: leggibile sui fondi chiari e su quelli scuri */
:focus-visible {
  outline: 2px solid #FFFFFF;
  outline-offset: 3px;
  box-shadow: 0 0 0 6px #0A0A0C;
  border-radius: 2px;
}
main:focus { outline: none; box-shadow: none; }

.btn {
  display: inline-block;
  padding: .8em 1.25em;
  font: 600 1rem/1 var(--f-body);
  text-decoration: none;
  background: var(--accent);
  color: var(--on-accent);
  border: 2px solid var(--accent);
  border-radius: 4px 999px 999px 999px;
}
.btn-ghost { background: transparent; color: var(--ink); border-color: currentColor; }
.btn:hover { background: var(--ink); border-color: var(--ink); color: var(--sky-a); }

/* ---------- HUD ---------- */
.hud { color: var(--ink); font-size: .95rem; }
.brand { text-decoration: none; font-family: var(--f-display); font-weight: 760; font-variation-settings: "wdth" 82; font-size: 1.15rem; line-height: 1.1; letter-spacing: .01em; text-transform: uppercase; }
.brand-sub { font-weight: 400; color: var(--soft); text-transform: none; letter-spacing: 0; }
.index ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .25rem 1.1rem; }
.index a { text-decoration: none; display: inline-block; padding: .35rem 0; color: var(--soft); }
.index a:hover, .index a[aria-current="step"] { color: var(--ink); }
.index .n { font-family: var(--f-flap); font-weight: 600; font-variant-numeric: tabular-nums; margin-right: .3em; color: var(--accent); }

/* Tabellone a palette: la marcia del giro */
.clock { display: none; margin: 0; align-items: center; gap: .18rem; font: 600 2.1rem/1 var(--f-flap); }
.flap { position: relative; display: inline-block; width: 1.5rem; height: 2.4rem; perspective: 240px; color: #F3EEE2; }
.flap .h, .flap .f {
  position: absolute; left: 0; right: 0; height: 50%; overflow: hidden;
  background: #17191C;
  backface-visibility: hidden;
}
.flap i { display: block; height: 2.4rem; line-height: 2.4rem; text-align: center; font-style: normal; }
.flap .t, .flap .ft { top: 0; border-radius: 3px 3px 0 0; transform-origin: 50% 100%; }
.flap .b, .flap .fb { bottom: 0; border-radius: 0 0 3px 3px; transform-origin: 50% 0; }
.flap .b i, .flap .fb i { transform: translateY(-50%); }
.flap .b, .flap .fb { background: #202327; }
.flap::after { content: ""; position: absolute; left: 0; right: 0; top: calc(50% - .5px); height: 1px; background: #050607; }
.flap .fb { transform: rotateX(90deg); }
.flap.go .ft { animation: flap-top var(--dur, .22s) ease-in var(--delay, 0s) forwards; }
.flap.go .fb { animation: flap-bottom var(--dur, .22s) ease-out calc(var(--delay, 0s) + var(--dur, .22s)) forwards; }
@keyframes flap-top { to { transform: rotateX(-90deg); } }
@keyframes flap-bottom { from { transform: rotateX(90deg); } to { transform: rotateX(0); } }

/* ---------- Versione piatta (senza JS, ?piatto) ---------- */
html:not(.is-3d) .hud {
  position: sticky; top: 0; z-index: 20;
  display: flex; flex-wrap: wrap; align-items: center; gap: .6rem 1.5rem;
  padding: .8rem var(--gutter);
  background: #0A0A0C; color: #F6F3EF;
  --ink:#F6F3EF; --soft:#BDB4AC; --accent:#FF6A2B; --on-accent:#120405;
}
html:not(.is-3d) .index { flex-basis: 100%; }
html:not(.is-3d) .skies, html:not(.is-3d) .spacer, html:not(.is-3d) .vignette,
html:not(.is-3d) .deco, html:not(.is-3d) .hint { display: none; }
html:not(.is-3d) .brand-sub { display: none; }

.ch {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
  gap: 2rem 3rem;
  align-items: center;
  padding: clamp(3.5rem, 9vw, 7rem) var(--gutter);
  color: var(--ink);
  background:
    radial-gradient(60% 70% at 85% 10%, color-mix(in srgb, var(--glow) 32%, transparent), transparent 70%),
    linear-gradient(170deg, var(--sky-a), var(--sky-b));
  scroll-margin-top: 7rem;
}
.copy { max-width: 36rem; }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); margin: 0 0 1rem; }
.ora { margin: 0 0 .6rem; font: 600 1.3rem/1 var(--f-flap); color: var(--accent); text-transform: uppercase; letter-spacing: .08em; }
.motto { font-family: var(--f-display); font-size: clamp(1.3rem, 2.4vw, 1.9rem); margin: 0 0 1rem; color: var(--soft); }
.motto em { color: var(--ink); font-style: italic; }
.items { list-style: none; padding: 0; margin: 1.2rem 0 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.items li { padding: .35em .8em; border: 1.5px solid color-mix(in srgb, var(--ink) 45%, transparent); border-radius: 4px 999px 999px 999px; }
.photo img { width: 100%; object-fit: cover; }
.photo.tall img { aspect-ratio: 3 / 4; }
.photo.wide img { aspect-ratio: 3 / 2; }
.photo.small img, .photo.square img { aspect-ratio: 1; }
/* Espositori da negozio: fondo scuro e filetto arancione */
.frame { padding: clamp(.6rem, 1.4vw, 1.1rem); background: #14161A; border: 2px solid #FF6A2B; }
.frame img { aspect-ratio: 1; outline: 1px solid color-mix(in srgb, #FF6A2B 55%, transparent); outline-offset: -8px; }
.photo img { box-shadow: 0 1.4rem 3rem rgba(0, 0, 0, .34); }

.hours { margin: 1.2rem 0; display: grid; gap: .6rem; }
.hours div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .2rem 1.5rem; border-bottom: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); padding-bottom: .5rem; }
.hours dt { color: var(--soft); }
.hours dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; }
.hours dd a { color: var(--accent); }
.note { margin: 0 0 1.2rem; color: var(--soft); max-width: 34rem; }
.trust-strip { display: flex; flex-wrap: wrap; gap: .45rem; margin: 0 0 1.2rem; }
.trust-strip span { padding: .35rem .6rem; border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent); border-radius: 999px; color: var(--soft); font-size: .78rem; }
address { font-style: normal; margin: 0 0 1.4rem; }
address a { color: var(--accent); font-weight: 600; }
.actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 0 0 1.4rem; }
.fine { font-size: .85rem; color: var(--soft); margin: 0; }
.fine a { color: var(--soft); }

/* ---------- Versione in profondità ---------- */
.is-3d body { overflow-x: hidden; }
.is-3d .spacer { width: 1px; }
.is-3d .stage { position: fixed; inset: 0; overflow: hidden; }
.road { display: none; }
.is-3d .road { display: block; position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.is-3d .road-surface {
  position: absolute; left: 50%; top: 48%; width: 38vw; height: 150vh;
  transform: translate(-50%, -50%) perspective(700px) rotateX(61deg);
  transform-origin: 50% 50%;
  background:
    linear-gradient(90deg, transparent 0 8%, rgba(255,255,255,.08) 8% 9%, transparent 9% 91%, rgba(255,255,255,.08) 91% 92%, transparent 92%),
    linear-gradient(90deg, #202328, #111419 12% 88%, #202328);
  border-inline: 2px solid rgba(255,106,43,.36);
  box-shadow: 0 -2rem 6rem rgba(255,90,31,.12), 0 0 0 100vmax rgba(5,6,8,.08);
}
.is-3d .road > i {
  position: absolute; left: 50%; top: 43%; width: 4px; height: 8vh;
  background: #F6E8C8; box-shadow: 0 0 10px rgba(255,220,150,.42);
  transform: translateX(-50%) perspective(500px) rotateX(58deg);
  transform-origin: 50% 0; opacity: .78;
}
.is-3d .road > i:nth-child(2) { top: 54%; height: 10vh; }
.is-3d .road > i:nth-child(3) { top: 67%; height: 13vh; }
.is-3d .road > i:nth-child(4) { top: 83%; height: 17vh; }
.is-3d .road > i:nth-child(5) { top: 101%; height: 20vh; }
.is-3d .skies { position: absolute; inset: 0; }
.is-3d .sky {
  position: absolute; inset: 0; opacity: 0;
  background:
    radial-gradient(55% 60% at 78% 18%, color-mix(in srgb, var(--glow) 42%, transparent), transparent 70%),
    radial-gradient(90% 70% at 20% 100%, color-mix(in srgb, var(--sky-b) 90%, transparent), transparent 75%),
    linear-gradient(180deg, var(--sky-a), var(--sky-a) 35%, var(--sky-b));
}
.is-3d .sky:first-child { opacity: 1; }
/* il mondo non intercetta i clic: li ricevono solo i piani vicini (.is-live) */
.is-3d .world { position: absolute; inset: 0; pointer-events: none; }
.is-3d .ch { display: contents; }
.is-3d .ora { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.is-3d .plane {
  position: absolute; left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  pointer-events: none;
  will-change: transform, opacity;
  backface-visibility: hidden;
}
.is-3d .plane * { pointer-events: none; }
.is-3d .plane.is-live, .is-3d .plane.is-live * { pointer-events: auto; }
.is-3d .photo.near-camera { filter: drop-shadow(0 1.2rem 1.8rem rgba(0,0,0,.38)); }
.is-3d .photo.near-camera img { outline: 2px solid color-mix(in srgb, var(--accent) 58%, transparent); outline-offset: -2px; }
.is-3d .copy { width: min(34rem, 86vw); text-shadow: 0 1px 18px color-mix(in srgb, var(--sky-a) 80%, transparent); }
.is-3d .copy.center { text-align: center; }
.is-3d .copy.center .lead { margin-inline: auto; max-width: 30rem; }
.is-3d .copy.center .items { justify-content: center; }
.is-3d .photo.tall { width: min(30vw, 26rem); }
.is-3d .photo.wide { width: min(44vw, 44rem); }
.is-3d .photo.small { width: min(17vw, 15rem); }
.is-3d .photo.square { width: min(32vw, 30rem); }
.is-3d .frame { width: min(27vw, 28rem); }
.is-3d .visit { width: min(36rem, 88vw); }
.is-3d .visit h2 { font-size: clamp(2rem, 4.2vw, 3.6rem); }

.hint { display: flex; align-items: center; gap: .8rem; color: var(--soft); font-size: .95rem; margin: 1.6rem 0 0; }
.hint-line { flex: none; width: 3rem; height: 2px; background: var(--accent); transform-origin: 0 50%; animation: hint 2.4s ease-in-out infinite; }
@keyframes hint { 0%, 100% { transform: scaleX(.25); } 50% { transform: scaleX(1); } }
.hint-touch { display: none; }
@media (hover: none) and (pointer: coarse) {
  .hint-wheel { display: none; }
  .hint-touch { display: inline; }
}

/* Fiamme a filo: passano ai lati come i cartelloni a bordo pista */
.fiamma { color: color-mix(in srgb, var(--accent) 32%, transparent); width: min(24vw, 20rem); }
.fiamma.piccola { width: min(13vw, 11rem); }
.fiamma svg { display: block; width: 100%; height: auto; aspect-ratio: 200 / 260; }

/* Sombrero a filo: la firma del Messicano, appena accennata */
.sombrero { color: color-mix(in srgb, var(--accent) 26%, transparent); width: min(26vw, 22rem); }
.sombrero svg { display: block; width: 100%; height: auto; aspect-ratio: 260 / 150; }

/* Fari: aloni di luce come i fanali nel buio */
.fari { width: 90vw; height: 70vh; }
.fari i { position: absolute; border-radius: 50%; width: 12vmin; height: 12vmin; background: radial-gradient(circle, color-mix(in srgb, var(--glow) 70%, transparent), transparent 68%); }
.fari i:nth-child(1) { left: 4%; top: 10%; }
.fari i:nth-child(2) { left: 22%; top: 62%; width: 20vmin; height: 20vmin; }
.fari i:nth-child(3) { left: 48%; top: 4%; width: 8vmin; height: 8vmin; }
.fari i:nth-child(4) { left: 70%; top: 48%; width: 24vmin; height: 24vmin; }
.fari i:nth-child(5) { left: 88%; top: 14%; }
.fari i:nth-child(6) { left: 58%; top: 80%; width: 9vmin; height: 9vmin; }
.fari.freddi i:nth-child(odd) { background: radial-gradient(circle, color-mix(in srgb, #CFEBFF 55%, transparent), transparent 68%); }

.is-3d .vignette {
  position: fixed; inset: 0; pointer-events: none; z-index: 5;
  background: radial-gradient(120% 90% at 50% 50%, transparent 55%, rgba(2, 3, 5, .58));
}

.is-3d .hud { position: fixed; inset: 0; z-index: 10; pointer-events: none; transition: color .6s; }
.is-3d .hud > * { pointer-events: auto; }
.is-3d .brand { position: absolute; left: var(--gutter); top: 1.2rem; }
.is-3d .brand-sub { display: block; font-size: .8rem; letter-spacing: .04em; }
.is-3d .clock { display: flex; position: absolute; left: 50%; top: 1rem; transform: translateX(-50%); }
.is-3d .index { position: absolute; left: var(--gutter); right: var(--gutter); bottom: 1rem; }
.is-3d .index a[aria-current="step"] { box-shadow: inset 0 -2px 0 var(--accent); }

/* HUD leggibile anche quando una foto chiara o scura gli passa dietro */
.is-3d .brand, .is-3d .index a {
  text-shadow: 0 1px 14px color-mix(in srgb, var(--sky-a) 90%, transparent), 0 0 3px color-mix(in srgb, var(--sky-a) 70%, transparent);
}

/* ---------- Contatti rapidi: Instagram accanto allo shop ---------- */
.rapidi { display: flex; align-items: center; gap: .5rem; }
.is-3d .rapidi { position: absolute; right: var(--gutter); top: 1.1rem; }
html:not(.is-3d) .rapidi { margin-left: auto; }
.btn-tondo {
  display: inline-grid; place-items: center; width: 2.75rem; height: 2.75rem; flex: none;
  border: 2px solid currentColor; border-radius: 50%; color: var(--ink); text-decoration: none;
  transition: background-color .25s ease, color .25s ease, border-color .25s ease;
}
.btn-tondo svg { width: 1.25rem; height: 1.25rem; }
.btn-tondo:hover, .btn-tondo:focus-visible { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.cart-trigger { white-space: nowrap; }
.cart-trigger .cart-count { display: inline-grid; place-items: center; min-width: 1.35em; height: 1.35em; margin-left: .25em; padding: 0 .2em; border-radius: 50%; background: color-mix(in srgb, var(--on-accent) 18%, transparent); font: 600 .85em var(--f-flap); }
.btn-ig, .btn-tiktok, .btn-yt { display: inline-flex; align-items: center; gap: .5em; }
.btn-ig svg, .btn-tiktok svg, .btn-yt svg { width: 1.1em; height: 1.1em; }
.shop-tools { display: flex; gap: .45rem; position: absolute; right: var(--gutter); top: 4.7rem; pointer-events: auto; }
.shop-search input, .shop-tools select { min-height: 2.35rem; border: 1px solid color-mix(in srgb, var(--ink) 55%, transparent); border-radius: 999px; background: color-mix(in srgb, var(--sky-a) 70%, transparent); color: var(--ink); padding: .45rem .8rem; font: .85rem var(--f-body); }
.shop-search input { width: 10rem; }
.shop-tools select { max-width: 9rem; }
html:not(.is-3d) .shop-tools { position: static; flex-basis: 100%; order: 3; }
html:not(.is-3d) .index { order: 4; }

/* ---------- Barra di avanzamento ---------- */
.avanzamento { display: none; }
.is-3d .hud > .avanzamento {
  display: block; position: absolute; left: 0; right: 0; bottom: 0; height: 2px;
  background: color-mix(in srgb, var(--ink) 14%, transparent); pointer-events: none;
}
.avanzamento i { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }
.reduced-toggle { position: fixed; z-index: 12; left: var(--gutter); top: 4.7rem; padding: .45em .8em; font-size: .75rem; }
html:not(.is-3d) .reduced-toggle { display: none; }
.is-3d .reduced-toggle { color: var(--ink); border-color: color-mix(in srgb, var(--ink) 65%, transparent); }
.minimap { display: none; }
.is-3d .minimap {
  display: block; position: fixed; z-index: 11; right: var(--gutter); top: 8rem;
  width: min(13rem, 24vw); color: var(--ink); text-shadow: 0 1px 10px var(--sky-a);
}
.minimap-tappa { display: flex; gap: .55rem; align-items: baseline; margin: 0 0 .45rem; font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; }
.minimap-num { color: var(--accent); font: 600 .9rem var(--f-flap); }
.minimap-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.minimap-track { height: 3px; margin-bottom: .35rem; background: color-mix(in srgb, var(--ink) 22%, transparent); }
.minimap-track i { display: block; height: 100%; background: var(--accent); transform: scaleX(0); transform-origin: 0 50%; }
.minimap-links ol { display: grid; gap: .12rem; margin: 0; padding: 0; list-style: none; }
.minimap-links a { display: flex; gap: .5rem; padding: .18rem 0; color: var(--soft); font-size: .72rem; text-decoration: none; }
.minimap-links a span { width: 1.35rem; color: var(--accent); font-family: var(--f-flap); }
.minimap-links a b { font-weight: 400; }
.minimap-links a[aria-current="step"] { color: var(--ink); font-weight: 600; }
.chapter-controls { display: flex; gap: .35rem; margin-top: .7rem; }
.chapter-controls .btn { padding: .42em .62em; font-size: .72rem; }
.chapter-controls button:disabled { opacity: .35; cursor: not-allowed; }

/* ---------- Foto in primo piano ---------- */
.zoom { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; color: inherit; }
.luce { border: 0; padding: 0; background: transparent; color: #F6F3EF; max-width: min(92vw, 70rem); max-height: 92dvh; overflow: visible; }
.luce::backdrop { background: rgba(5, 5, 7, .88); backdrop-filter: blur(6px); }
/* colonna: il bottone Chiudi sta nel flusso, così non finisce mai fuori dallo schermo */
.luce[open] { display: flex; flex-direction: column; align-items: center; animation: luce-in .35s cubic-bezier(.2, .8, .2, 1); }
.luce img { display: block; max-width: 100%; max-height: 62dvh; width: auto; margin: 0 auto; box-shadow: 0 2rem 5rem rgba(0, 0, 0, .55); }
.luce-testo { margin: .9rem 0 .2rem; text-align: center; font-weight: 600; }
.luce-prezzo { margin: 0 0 .9rem; text-align: center; color: #BDB4AC; font-variant-numeric: tabular-nums; }
.luce-prezzo s { color: #8D857E; margin-right: .5em; }
.luce-azioni { text-align: center; margin: 0; }
.luce-chiudi { align-self: flex-end; margin: 0 0 .7rem; --ink: #F6F3EF; --sky-a: #0A0A0C; padding: .6em 1em; }
@keyframes luce-in { from { opacity: 0; transform: scale(.94); } }
html:has(.luce[open]) { overflow: hidden; }

/* ---------- Cartellini: nome e prezzo, come in negozio ---------- */
.cartellino { margin: .6rem 0 0; font-size: .85rem; line-height: 1.3; color: var(--soft); }
.cartellino b { display: block; font-weight: 600; color: var(--ink); }
.cartellino .eur { font-family: var(--f-flap); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.cartellino s { opacity: .7; margin-right: .35em; }
.is-3d .photo { position: absolute; }
.is-3d .cartellino {
  position: absolute; left: 1.2rem; top: calc(100% + 1.4rem); margin: 0;
  min-width: 9rem; max-width: 15rem; padding: .45rem .75rem .5rem 1.25rem;
  background: #F2EFE8; color: #55504A; border-radius: 12px 3px 3px 3px;
  box-shadow: 0 .6rem 1.4rem rgba(0, 0, 0, .32);
  opacity: 0; transform: translateY(-.6rem) rotate(-3deg); transform-origin: 1.25rem 0;
  transition: opacity .45s ease, transform .7s cubic-bezier(.2, .8, .2, 1);
}
.is-3d .cartellino.destra { left: auto; right: 1.2rem; transform: translateY(-.6rem) rotate(3deg); }
.is-3d .cartellino b { color: #14161A; }
.is-3d .cartellino .eur { color: #B0111C; font-size: .95em; }
.product-details { display: block; margin-top: .4rem; padding: 0; border: 0; background: none; color: #5C5550; text-decoration: underline; font: .72rem var(--f-body); cursor: pointer; }
.catalogo-nascosto { display: none !important; }
.add-cart { margin-top: .55rem; padding: .45em .75em; border: 1px solid currentColor; border-radius: 999px; background: transparent; color: inherit; font: 600 .78rem/1 var(--f-body); cursor: pointer; }
.add-cart:hover, .add-cart:focus-visible { background: #B0111C; border-color: #B0111C; color: #FFF5F5; }
.variant-select { display: block; width: 100%; margin-top: .5rem; padding: .35em .45em; border: 1px solid currentColor; border-radius: 3px; background: #FFF8EE; color: #14161A; font: .75rem var(--f-body); }
.is-3d .cartellino::before { content: ""; position: absolute; left: 1.25rem; bottom: calc(100% - .55rem); width: 1px; height: 1.95rem; background: #FF6A2B; }
.is-3d .cartellino::after { content: ""; position: absolute; left: calc(1.25rem - 3px); top: .3rem; width: 7px; height: 7px; border-radius: 50%; background: #CFC8BE; box-shadow: inset 0 1px 2px rgba(0, 0, 0, .35); }
.is-3d .plane.is-live .cartellino { opacity: 1; transform: rotate(-3deg); }
.is-3d .plane.is-live .cartellino.destra { transform: rotate(3deg); }
/* Cartellini che dondolano quando compaiono */
@keyframes dondola { 0% { rotate: 9deg; } 30% { rotate: -5deg; } 55% { rotate: 3deg; } 78% { rotate: -1deg; } 100% { rotate: 0deg; } }
@media (min-width: 761px) and (min-aspect-ratio: 4/5) {
  .is-3d .plane.is-live .cartellino { animation: dondola 1.8s cubic-bezier(.3, .7, .4, 1) both; }
}
.calmo .cartellino { animation: none !important; }
/* Cartellini: non sugli espositori inclinati (si schiaccerebbero) */
.is-3d .frame .cartellino { display: block; }
/* Nella versione piatta restano dentro l'espositore, che è sempre scuro: colori propri */
.frame .cartellino { color: #BDB4AC; }
.frame .cartellino b { color: #F6F3EF; }
.frame .cartellino .eur { color: #FF8A4D; }

/* ---------- Bivio: due direzioni nello stesso viaggio ---------- */
.bivio-corsia { display: grid; gap: .35rem; width: min(20rem, 38vw); padding: 1rem 1.2rem; border: 2px solid color-mix(in srgb, var(--ink) 55%, transparent); border-radius: 8px 26px 8px 26px; text-decoration: none; text-shadow: none; transition: transform .35s ease, background-color .35s ease, border-color .35s ease, box-shadow .35s ease; }
.is-3d .bivio-corsia { width: min(20rem, 38vw); }
.bivio-corsia:hover, .bivio-corsia:focus-visible { transform: translate(-50%, -50%) scale(1.06) !important; background: color-mix(in srgb, var(--accent) 24%, transparent); border-color: var(--accent); box-shadow: 0 1rem 2.5rem rgba(0,0,0,.3); }
.bivio-corsia strong { font: 700 clamp(1.25rem, 2.2vw, 1.8rem)/1 var(--f-display); }
.bivio-corsia > span:last-child { color: var(--soft); font-size: .9rem; }
.bivio-freccia { position: absolute; top: -.9rem; font-size: 2.3rem; color: var(--accent); line-height: 1; }
.bivio-corsia-sinistra .bivio-freccia { left: .8rem; }
.bivio-corsia-destra .bivio-freccia { right: .8rem; }
.bivio-num { color: var(--accent); font: 600 .85rem/1 var(--f-flap); }
.bivio-corsia-destra { border-radius: 26px 8px 26px 8px; }
.bivio-line { width: 1px; height: 18vh; background: linear-gradient(var(--accent), transparent); transform-origin: 50% 0; opacity: .6; }
.bivio-line-left { rotate: 28deg; }
.bivio-line-right { rotate: -28deg; }
.bivio-corsia-sinistra { background: linear-gradient(125deg, color-mix(in srgb, #B0111C 24%, transparent), transparent 70%); }
.bivio-corsia-destra { background: linear-gradient(225deg, color-mix(in srgb, #17466B 28%, transparent), transparent 70%); }

/* ---------- Carrello laterale ---------- */
.carrello-backdrop { position: fixed; inset: 0; z-index: 29; background: rgba(4, 5, 7, .65); opacity: 0; pointer-events: none; transition: opacity .3s ease; }
.carrello { position: fixed; z-index: 30; inset: 0 0 0 auto; width: min(27rem, 100vw); padding: 1.5rem; display: flex; flex-direction: column; background: #111419; color: #F6F3EF; box-shadow: -1.5rem 0 4rem rgba(0, 0, 0, .32); transform: translateX(105%); transition: transform .4s cubic-bezier(.2, .8, .2, 1); }
.carrello[aria-hidden="false"] { transform: translateX(0); }
.carrello[aria-hidden="false"] + .carrello-backdrop { opacity: 1; pointer-events: auto; }
.carrello-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; padding-bottom: 1rem; border-bottom: 1px solid rgba(246, 243, 239, .18); }
.carrello-head h2 { font-size: 2.4rem; margin: 0; }
.carrello-head .ora { margin: 0 0 .3rem; font-size: .9rem; }
.carrello-head .cart-count { color: var(--accent); font: .6em var(--f-flap); vertical-align: middle; }
.carrello-chiudi { --ink: #F6F3EF; --accent: #FF6A2B; font-size: .8rem; padding: .65em .8em; }
.carrello-body { flex: 1; overflow-y: auto; padding: 1rem 0; }
.carrello-item { display: grid; grid-template-columns: 4.4rem 1fr; gap: .8rem; padding: .8rem 0; border-bottom: 1px solid rgba(246, 243, 239, .14); }
.carrello-item img { width: 4.4rem; height: 5rem; object-fit: cover; border-radius: 3px; }
.carrello-item strong, .carrello-item span { display: block; }
.carrello-item strong { font-size: .95rem; line-height: 1.2; }
.carrello-item span { margin-top: .25rem; color: #BDB4AC; font-size: .82rem; }
.carrello-qty { display: flex; align-items: center; gap: .6rem; margin-top: .7rem; }
.carrello-qty button { border: 0; background: transparent; color: #F6F3EF; cursor: pointer; font: 600 1rem var(--f-body); }
.carrello-qty button[data-cart-action="remove"] { margin-left: auto; color: #BDB4AC; font-size: .72rem; text-decoration: underline; }
.carrello-vuoto { margin-top: 3rem; text-align: center; color: #F6F3EF; }
.carrello-vuoto span, .carrello-nota { color: #BDB4AC; font-size: .85rem; }
.carrello-foot { padding-top: 1rem; border-top: 1px solid rgba(246, 243, 239, .18); }
.carrello-totale { display: flex; justify-content: space-between; margin: 0 0 1rem; font-size: 1.1rem; }
.carrello-totale strong { font: 600 1.4rem var(--f-flap); color: #FF8A4D; }
.carrello-checkout { width: 100%; }
.carrello-checkout:disabled { cursor: not-allowed; opacity: .4; }
.carrello-nota { margin: .7rem 0 0; line-height: 1.35; }
.coupon-label { display: block; margin: .4rem 0 .8rem; color: #BDB4AC; font-size: .8rem; }
.coupon-label > span { display: flex; margin-top: .3rem; }
.coupon-input { min-width: 0; flex: 1; padding: .55rem .65rem; border: 1px solid #4F565F; background: #0C0E11; color: #F6F3EF; font: .85rem var(--f-body); }
.coupon-apply { border: 1px solid #FF6A2B; background: #FF6A2B; color: #120405; padding: .55rem .7rem; font-weight: 600; cursor: pointer; }
.coupon-status, .spedizione-status { min-height: 1.2em; margin: .25rem 0; color: #FF9D6A; font-size: .78rem; }
.spedizione-status { color: #83E3B5; }
.prodotto-dialog { width: min(54rem, 92vw); padding: clamp(1rem, 3vw, 2rem); border: 1px solid #FF6A2B; background: #111419; color: #F6F3EF; }
.prodotto-dialog::backdrop { background: rgba(4, 5, 7, .8); backdrop-filter: blur(8px); }
.prodotto-chiudi { float: right; --ink: #F6F3EF; }
.prodotto-grid { display: grid; grid-template-columns: minmax(12rem, .8fr) 1fr; gap: clamp(1rem, 4vw, 3rem); align-items: center; }
.prodotto-img { width: 100%; max-height: 65vh; object-fit: cover; }
.prodotto-prezzo { color: #FF9D6A; font: 600 1.5rem var(--f-flap); }
.prodotto-desc { color: #BDB4AC; }
.prodotto-trust { margin: 1rem 0; color: #83E3B5; font-size: .85rem; }
body.carrello-aperto .shop-tools { pointer-events: none; }
body.carrello-aperto { overflow: hidden; }

/* Il riquadro del testo non ruba i tocchi alle foto: cliccabili solo i suoi link */
.is-3d .plane.copy.is-live, .is-3d .plane.copy.is-live * { pointer-events: none; }
.is-3d .plane.copy.is-live a, .is-3d .plane.copy.is-live button { pointer-events: auto; }
.is-3d .plane.bivio-corsia.is-live { pointer-events: auto; }

/* ---------- Luce del cursore sulle foto ---------- */
@property --mx { syntax: "<number>"; inherits: true; initial-value: .3; }
@property --my { syntax: "<number>"; inherits: true; initial-value: .25; }
.is-3d .zoom { position: relative; }
.is-3d .zoom::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(45% 45% at calc(var(--mx) * 100%) calc(var(--my) * 100%), rgba(255, 255, 255, .3), transparent 70%);
  mix-blend-mode: overlay;
}

/* ---------- Polvere nel passaggio tra due tappe ---------- */
html:not(.is-3d) .velo, html:not(.is-3d) .ingresso, html:not(.is-3d) .chiusura { display: none; }
.is-3d .velo {
  position: fixed; inset: 0; z-index: 6; pointer-events: none; opacity: 0; visibility: hidden;
  -webkit-backdrop-filter: blur(14px) saturate(.9); backdrop-filter: blur(14px) saturate(.9);
  background: radial-gradient(120% 100% at 50% 50%, rgba(226, 198, 168, .1), rgba(226, 198, 168, .22));
}
/* telefono e touch: niente sfocatura in tempo reale (è la cosa più pesante), solo polvere */
@media (hover: none), (pointer: coarse) {
  .is-3d .velo { -webkit-backdrop-filter: none; backdrop-filter: none; background: radial-gradient(120% 100% at 50% 50%, rgba(214, 194, 172, .4), rgba(214, 194, 172, .6)); }
}

/* ---------- Insegna sulla saracinesca ---------- */
.is-3d .ingresso {
  position: fixed; inset: 0; z-index: 8; pointer-events: none;
  display: grid; place-content: center; justify-items: center; gap: .6rem; text-align: center;
  background:
    repeating-linear-gradient(180deg, rgba(255, 255, 255, .035) 0 3px, transparent 3px 9px),
    linear-gradient(115deg, transparent 18%, rgba(255, 255, 255, .07) 24%, transparent 31%),
    radial-gradient(120% 90% at 50% 42%, rgba(26, 10, 6, .82), rgba(5, 5, 7, .96));
  backdrop-filter: blur(14px);
  transform-origin: 50% 45%;
}
.insegna {
  margin: 0;
  font-family: "Anton", "Arial Narrow", Impact, sans-serif; font-weight: 400;
  font-size: clamp(2.7rem, 12vw, 10rem); line-height: .92; letter-spacing: .01em; text-transform: uppercase;
  background: linear-gradient(180deg, #FFE0C2 0%, #FF8A2B 38%, #C7300A 64%, #FFB870 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 2px 0 rgba(60, 16, 4, .6)) drop-shadow(0 14px 30px rgba(0, 0, 0, .5));
}
.insegna-sub { margin: 0; color: #E9D2B8; letter-spacing: .3em; text-transform: uppercase; font-size: clamp(.65rem, 1.6vw, .85rem); }
.insegna-hint { margin: 1.6rem 0 0; color: rgba(246, 243, 239, .75); font-size: .95rem; }

/* ---------- Chiusura: l'insegna torna per un attimo ---------- */
.is-3d .chiusura {
  position: fixed; inset: 0; z-index: 8; pointer-events: none;
  display: grid; place-content: center; justify-items: center; gap: .5rem; text-align: center;
  background: radial-gradient(90% 80% at 50% 50%, rgba(6, 7, 9, .95), rgba(6, 7, 9, .84));
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; visibility: hidden;
  transition: opacity .8s ease, visibility 0s linear .8s;
}
.is-3d .chiusura.on { opacity: 1; visibility: visible; transition: opacity .6s ease; }
.is-3d .chiusura .insegna { font-size: clamp(2.2rem, 10vw, 7rem); transform: scale(1.06); transition: transform 2.6s cubic-bezier(.2, .8, .2, 1); }
.is-3d .chiusura.on .insegna { transform: scale(1); }

/* ---------- Asfalto sui fondi scuri ---------- */
.is-3d .sky:is([data-tone="pista"], [data-tone="brand"], [data-tone="fuego"], [data-tone="box"], [data-tone="social"], [data-tone="strada"])::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(120deg, transparent 30%, rgba(255, 255, 255, .035) 48%, transparent 66%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .5 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: auto, 220px 220px;
  opacity: .05;
}

/* ---------- Scintille sul cromo ---------- */
.stella {
  position: absolute; width: 52px; height: 52px; margin: -26px 0 0 -26px; z-index: 2; pointer-events: none;
  background:
    radial-gradient(circle, #FFF 0 7%, rgba(255, 240, 225, .55) 16%, transparent 34%),
    linear-gradient(90deg, transparent 47%, rgba(255, 255, 255, .95) 50%, transparent 53%),
    linear-gradient(0deg, transparent 47%, rgba(255, 255, 255, .95) 50%, transparent 53%);
  -webkit-mask: radial-gradient(circle, #000 18%, transparent 68%); mask: radial-gradient(circle, #000 18%, transparent 68%);
  filter: drop-shadow(0 0 5px rgba(255, 220, 180, 1));
  mix-blend-mode: screen;
  animation: stella 1.2s ease-in-out forwards;
}
@keyframes stella {
  0% { transform: scale(0) rotate(0deg); opacity: 0; }
  40% { transform: scale(1) rotate(40deg); opacity: 1; }
  100% { transform: scale(0) rotate(90deg); opacity: 0; }
}

/* ---------- Fiamme che guizzano ---------- */
@keyframes guizza { 0%, 100% { transform: scaleY(1) skewX(0deg); } 25% { transform: scaleY(1.07) skewX(3deg); } 60% { transform: scaleY(.95) skewX(-2deg); } }
@keyframes arde { 0%, 100% { opacity: .5; } 50% { opacity: 1; } }
.is-3d .fiamma svg { transform-origin: 50% 100%; animation: guizza 3.4s ease-in-out infinite, arde 4.6s ease-in-out infinite; }
.is-3d .fiamma.piccola svg { animation-duration: 2.3s, 3.1s; }
.calmo .fiamma svg { animation: none; }
@keyframes ondeggia { 0%, 100% { transform: rotate(-2.5deg); } 50% { transform: rotate(2.5deg); } }
.is-3d .sombrero svg { animation: ondeggia 9s ease-in-out infinite; }
.calmo .sombrero svg { animation: none; }
.calmo .road > i { opacity: .48; }

/* ---------- Instagram ---------- */
.is-3d .feed { width: min(36vw, 32rem); }
.feed-griglia { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(.4rem, 1vw, .75rem); }
.feed-griglia a {
  position: relative; display: block; overflow: hidden; aspect-ratio: 1;
  border-radius: 3px; background: #17090C; box-shadow: 0 1rem 2.4rem rgba(0, 0, 0, .34);
}
.feed-griglia img { width: 100%; height: 100%; object-fit: cover; box-shadow: none; transition: transform .8s cubic-bezier(.2, .8, .2, 1); }
.feed-velo {
  position: absolute; inset: 0; display: grid; place-items: center; color: #FFEFF3;
  background: linear-gradient(160deg, rgba(23, 13, 15, .05), rgba(23, 13, 15, .62));
  opacity: 0; transition: opacity .4s ease;
}
.feed-velo svg { width: 2rem; height: 2rem; transform: scale(.8); transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
.feed-griglia a:is(:hover, :focus-visible) img { transform: scale(1.06); }
.feed-griglia a:is(:hover, :focus-visible) .feed-velo { opacity: 1; }
.feed-griglia a:is(:hover, :focus-visible) .feed-velo svg { transform: scale(1); }
@media (hover: none) {
  .feed-velo { opacity: 1; place-items: end; padding: .45rem; background: linear-gradient(180deg, transparent 55%, rgba(23, 13, 15, .55)); }
  .feed-velo svg { width: 1.1rem; height: 1.1rem; transform: none; }
}

/* ---------- Tachimetro della spedizione ---------- */
/* --giro: quanto ha spinto l'ago. Il JS lo muove con lo scroll; nella versione piatta resta a fondo scala. */
.tachimetro { --giro: 1; background: #0C0E11; border: 2px solid #FF6A2B; padding: clamp(.45rem, 1vw, .8rem); box-shadow: 0 1.4rem 3rem rgba(0, 0, 0, .4); }
.is-3d .tachimetro { width: min(36vw, 32rem); }
.tachi-svg { display: block; width: 100%; height: auto; aspect-ratio: 1; background: #08090B; }
.t-quadrante { fill: none; stroke: #1E242B; stroke-width: 54; }
.t-zona { fill: none; stroke: #FF6A2B; stroke-width: 54; opacity: .16; }
.t-zona-gratis { fill: none; stroke: #4FE0A2; stroke-width: 54; opacity: .34; }
.t-tacca { stroke: #6C737C; stroke-width: 4; stroke-linecap: round; }
.t-tacca-grande { stroke: #E4E7EA; stroke-width: 7; stroke-linecap: round; }
.t-num { fill: #D6DCE2; font: 600 52px var(--f-flap); text-anchor: middle; }
.t-titolo { fill: #FF8A4D; font: 600 48px var(--f-flap); text-anchor: middle; letter-spacing: 3px; }
.t-nota { fill: #A6ADB5; font: 400 38px var(--f-body); text-anchor: middle; }
.t-ago { transform: rotate(calc(-125deg + var(--giro, 0) * 250deg)); transform-box: view-box; transform-origin: 500px 520px; transition: transform .45s cubic-bezier(.2, .8, .2, 1); }
.t-ago path { fill: #FF3B1F; }
.t-perno { fill: #E4E7EA; }
.t-perno-interno { fill: #0C0E11; }
.calmo .t-ago { transition: none; }

/* ---------- Fine corsa ---------- */
html.is-3d, html.is-3d body { overscroll-behavior: none; }
html.is-3d body { background: var(--sky-b); transition: background-color .6s ease; }

/* ---------- Riduci movimento: profondità sì, effetti di contorno no ---------- */
.calmo .ingresso, .calmo .velo, .calmo .chiusura { display: none; }
.calmo .hint-line { animation: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    transition-delay: 0s !important;
    scroll-behavior: auto !important;
  }
}

/* ---------- Versione animata / semplice: ognuna offre l'altra ---------- */
.semplice { margin: .8rem 0 0; font-size: .85rem; }
.semplice a { color: var(--soft); }
html:not(.is-3d) .semplice { display: none; }
.animata { display: none; }
html:not(.is-3d) .animata { display: block; margin: .8rem 0 0; font-size: .85rem; }
.animata a { color: var(--soft); }

/* ---------- Schermi larghi ma non molto ---------- */
@media (min-width: 761px) and (min-aspect-ratio: 4/5) {
  .is-3d .copy { width: min(34rem, 40vw); }
  .is-3d .visit { width: min(36rem, 44vw); }
}

/* ---------- Telefono e tablet in verticale ---------- */
@media (max-width: 760px), (max-aspect-ratio: 4/5) {
  body { font-size: 1rem; }
  .is-3d .brand { font-size: .95rem; top: .9rem; }
  .is-3d .clock { top: auto; bottom: 3.6rem; left: var(--gutter); transform: none; font-size: 1.6rem; }
  .is-3d .flap { width: 1.15rem; height: 1.8rem; }
  .is-3d .flap i { height: 1.8rem; line-height: 1.8rem; }
  .is-3d .rapidi { top: .8rem; gap: .4rem; }
  .is-3d .btn-tondo { width: 2.6rem; height: 2.6rem; }
  .is-3d .rapidi .btn { padding: .7em 1em; font-size: .95rem; }
  .shop-tools { left: var(--gutter); right: var(--gutter); top: 4.2rem; }
  .shop-search { flex: 1; }
  .shop-search input { width: 100%; }
  .shop-tools select { max-width: 45%; }
  .is-3d .reduced-toggle { top: auto; bottom: 3.7rem; }
  .is-3d .index { bottom: .4rem; overflow-x: auto; scrollbar-width: none; }
  .is-3d .index ol { flex-wrap: nowrap; white-space: nowrap; padding-bottom: .2rem; }
  .is-3d .minimap { top: 7.8rem; right: var(--gutter); width: 9.5rem; }
  .is-3d .minimap-links { display: none; }
  .is-3d .chapter-controls .btn span { display: none; }
  .reduced-toggle { top: 7.9rem; left: var(--gutter); }
  .is-3d .road-surface { width: 72vw; opacity: .72; transform: translate(-50%, -50%) perspective(500px) rotateX(65deg); }
  .is-3d .road > i { height: 6vh; }
  .is-3d .fari, .is-3d .sombrero { display: none; }
  .is-3d .photo.tall { width: 56vw; }
  .is-3d .photo.wide { width: 80vw; }
  .is-3d .photo.small { width: 32vw; }
  .is-3d .photo.square { width: 62vw; }
  .is-3d .frame { width: 44vw; }
  .is-3d .feed { width: 62vw; }
  .is-3d .tachimetro { width: 58vw; }
  .prodotto-grid { grid-template-columns: 1fr; }
  .prodotto-img { max-height: 38vh; }
  .is-3d .bivio-corsia { width: min(14rem, 42vw); padding: .7rem .75rem; }
  .is-3d .bivio-corsia strong { font-size: 1.1rem; }
  .is-3d .bivio-corsia > span:last-child { font-size: .75rem; }
  .is-3d .fiamma { width: 34vw; }
  .is-3d .fiamma.piccola { width: 20vw; }
  .is-3d .sombrero { width: 40vw; }
  .is-3d h1 { font-size: clamp(2.6rem, 13vw, 4rem); }
  .is-3d h2 { font-size: clamp(2rem, 9.5vw, 3rem); }
  .is-3d .visit h2 { font-size: clamp(1.7rem, 8vw, 2.4rem); }
  .is-3d .lead { font-size: 1.02rem; }
  html:not(.is-3d) .index { overflow-x: auto; }
  html:not(.is-3d) .index ol { flex-wrap: nowrap; white-space: nowrap; }
  html:not(.is-3d) .ch { scroll-margin-top: 6rem; }
  /* niente sfocatura a tutto schermo sull'ingresso (pesante), basta un vetro più scuro */
  .is-3d .ingresso {
    backdrop-filter: none;
    background:
      repeating-linear-gradient(180deg, rgba(255, 255, 255, .03) 0 3px, transparent 3px 9px),
      radial-gradient(120% 90% at 50% 42%, rgba(26, 10, 6, .93), rgba(5, 5, 7, .98));
  }
  /* cartellino compatto dentro la foto (--s è la scala della foto: il cartellino la compensa) */
  .is-3d .cartellino, .is-3d .cartellino.destra {
    left: .4rem; right: auto; top: auto; bottom: .4rem; min-width: 0;
    max-width: calc(100% * var(--s, 1) - .8rem);
    padding: .28rem .55rem .32rem .85rem; font-size: .74rem; border-radius: 8px 2px 2px 2px;
    transform: none; transform-origin: 0 100%; scale: calc(1 / var(--s, 1));
  }
  .is-3d .plane.is-live .cartellino, .is-3d .plane.is-live .cartellino.destra { transform: none; }
  .is-3d .cartellino::before, .is-3d .photo.small .cartellino { display: none; }
  .is-3d .cartellino::after { left: .3rem; top: .42rem; width: 5px; height: 5px; }
  /* dove una foto piccola copre il fondo di quella grande, il cartellino va in alto */
  .is-3d .cartellino.destra { top: .4rem; bottom: auto; transform-origin: 0 0; }
  .is-3d .tachimetro .cartellino { display: none; }
}

/* ---------- Telefoni con schermo basso (iPhone SE e simili) ---------- */
@media (max-width: 760px) and (max-height: 700px) {
  .is-3d .photo.tall { width: 38vw; }
  .is-3d .photo.square { width: 42vw; }
  .is-3d .photo.small { width: 24vw; }
  .is-3d .frame { width: 30vw; }
  .is-3d .feed { width: 42vw; }
  .is-3d .tachimetro { width: 40vw; }
  .is-3d h1 { font-size: clamp(2.1rem, 10.5vw, 2.8rem); }
  .is-3d h2 { font-size: clamp(1.6rem, 7.6vw, 2.2rem); }
  .is-3d .visit h2 { font-size: clamp(1.5rem, 7vw, 2rem); }
  .is-3d .lead, .is-3d .note { font-size: .92rem; margin-bottom: .6rem; }
  .is-3d .motto { font-size: 1.15rem; margin-bottom: .6rem; }
  .is-3d .items { margin-top: .7rem; gap: .35rem; }
  .is-3d .items li { font-size: .82rem; }
  .is-3d .hours { margin: .7rem 0; gap: .35rem; }
  .is-3d .actions { margin-bottom: .7rem; }
  .is-3d .hint { margin-top: .8rem; }
  /* il tabellone in basso finirebbe sui link: su schermi così bassi basta l'indice */
  .is-3d .clock { display: none; }
}

/* ---------- Touch: niente fusioni di colore e filtri sui livelli che si muovono ---------- */
@media (hover: none), (pointer: coarse) {
  .is-3d .zoom::after { display: none; }
  .stella { filter: none; mix-blend-mode: normal; }
  .is-3d .chiusura { -webkit-backdrop-filter: none; backdrop-filter: none; }
}
