/* Despeguía · quiz del organizador. Móvil: columna de 480px máx. Escritorio (≥900px): panel lateral + columna de 620px.
   Navegación con :target y temas con :has(). El JS (js/quiz.js, js/organizador.js) solo calcula y avanza. */

@keyframes stageIn { from { translate: 80px 0; rotate: 2deg; opacity: 0; } }
@keyframes cardIn { from { translate: 10px 14px; rotate: 3deg; scale: .94; opacity: 0; } }
@keyframes slotIn { from { scale: .6; opacity: 0; } }
@keyframes react {
  0% { scale: .3; rotate: 12deg; opacity: 0; }
  20%, 80% { scale: 1; rotate: -4deg; opacity: 1; }
  100% { scale: 1; rotate: -4deg; opacity: 0; }
}
@keyframes fall { from { translate: 0 -40px; rotate: var(--r0); } to { translate: 0 calc(100dvh + 80px); rotate: var(--r1); } }

/* ─── Temas (soltera por defecto; el paso 1 siempre usa el base). El invitado lo fija con la clase .t-<tema> ─── */
.quiz {
  --bg: #F4EEE6; --surf: #FFFFFF; --text: #120F0E; --muted: #5A524C; --line: #DCCFC0;
  --hl-bg: #FF4A12; --hl-text: #120F0E; --on: #120F0E; --on-text: #FFD3B8;
  --cta-bg: #120F0E; --cta-text: #FFD3B8; --ticket-bg: #FF4A12; --ticket-text: #120F0E;
  --range: #FFD3B8; --range-text: #120F0E;
  --side-bg: #120F0E; --side-fg: #FFD3B8; --side-dot: #FF4A12;
  position: relative; max-width: 480px; min-height: 100dvh; margin-inline: auto;
  background: var(--bg); color: var(--text); transition: background .4s, color .4s;
}
.quiz:has(input[name="tema"]:checked):has(.screen:target:not(#paso-1)), .quiz.t-soltera { --side-bg: #FF4A12; --side-fg: #120F0E; --side-dot: #FFFFFF; }
.quiz:has(#t-divorcio:checked):has(.screen:target:not(#paso-1)), .quiz.t-divorcio {
  --side-bg: #FFD3B8; --side-fg: #141110; --side-dot: #FF4A12;
  --bg: #141110; --surf: #1F1B19; --text: #F4EEE6; --muted: #B8ADA3; --line: #3A332F;
  --hl-bg: #FFD3B8; --hl-text: #141110; --on: #FFD3B8; --on-text: #141110;
  --cta-bg: #FF4A12; --cta-text: #141110; --ticket-bg: #FFD3B8; --ticket-text: #141110;
  --range: #4A3A30; --range-text: #F4EEE6;
}
.quiz:has(#t-cumple:checked):has(.screen:target:not(#paso-1)), .quiz.t-cumple {
  --side-bg: #120F0E; --side-fg: #FFD3B8; --side-dot: #FF4A12;
  --bg: #FFD3B8; --surf: #FFF6EF; --text: #120F0E; --muted: #6B4A3A; --line: #EDB28F;
  --hl-bg: #120F0E; --hl-text: #FFD3B8; --on: #120F0E; --on-text: #FFD3B8;
  --cta-bg: #FF4A12; --cta-text: #120F0E; --ticket-bg: #120F0E; --ticket-text: #FFD3B8;
  --range: #FFC49E;
}

/* Textos que cambian según el tema */
[data-tema] { display: none; }
.quiz:not(:has(#t-divorcio:checked, #t-cumple:checked)):not(.t-divorcio, .t-cumple) [data-tema="soltera"],
.quiz:has(#t-divorcio:checked) [data-tema="divorcio"], .quiz.t-divorcio [data-tema="divorcio"],
.quiz:has(#t-cumple:checked) [data-tema="cumple"], .quiz.t-cumple [data-tema="cumple"] { display: revert; }

/* ─── Pantallas: solo se ve la del #hash (o el paso 1 si no hay) ─── */
/* Sin scroll: cada pantalla ocupa el alto visible y solo el cuerpo hace scroll como último recurso */
.screen { display: none; height: 100dvh; flex-direction: column; }
.screen:target, .quiz:not(:has(.screen:target)) #paso-1 { display: flex; }
.screen:target .stage, .quiz:not(:has(.screen:target)) #paso-1 .stage { animation: stageIn .42s cubic-bezier(.2, 1.35, .4, 1) backwards; }

/* Cabecera */
.q-head { position: relative; z-index: 2; display: flex; flex-direction: column; gap: 12px; padding: 14px 20px 10px; }
.q-bar { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.q-step { flex: 1; min-width: 0; text-align: center; font-family: var(--f-mono); font-size: 12px; font-weight: 700; letter-spacing: .02em; white-space: nowrap; }
.icon-btn { width: 44px; height: 44px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border: 2px solid var(--text); color: var(--text); }
.icon-btn svg { width: 20px; height: 20px; }
.icon-btn:hover { background: var(--text); color: var(--bg); }
.segs { list-style: none; margin: 0; padding: 0; display: flex; gap: 3px; }
.segs li { flex: 1; height: 6px; border: 2px solid var(--text); box-sizing: content-box; }
[data-n="1"] .segs li:nth-child(-n+1), [data-n="2"] .segs li:nth-child(-n+2), [data-n="3"] .segs li:nth-child(-n+3),
[data-n="4"] .segs li:nth-child(-n+4), [data-n="5"] .segs li:nth-child(-n+5), [data-n="6"] .segs li:nth-child(-n+6),
[data-n="7"] .segs li { background: var(--accent); }

/* Decoración del tema (pasos 2-7) */
.deco { position: absolute; top: 108px; right: 0; width: 160px; height: 120px; pointer-events: none; }
.quiz:has(#paso-1:target) .deco, .quiz:not(:has(.screen:target)) .deco { display: none; }
.deco i { position: absolute; font-style: normal; }
.star { color: var(--accent); line-height: 1; }
.star--a { right: 16px; top: -4px; font-size: 44px; }
.star--b { right: 64px; top: 36px; font-size: 22px; }
.libre { right: 8px; top: 2px; border: 3px solid var(--sign); color: var(--sign); padding: 0 8px; font-family: var(--f-display); font-size: 26px; font-weight: 900; rotate: 12deg; opacity: .9; }
.deco .bit--a { right: 20px; top: 4px; width: 14px; height: 14px; background: var(--accent); rotate: 25deg; }
.deco .bit--b { right: 60px; top: 30px; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); }
.deco .bit--c { right: 12px; top: 52px; width: 18px; height: 6px; background: var(--ink); rotate: -35deg; }
.deco .bit--d { right: 100px; top: 8px; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); }

/* Cuerpo */
.q-main { flex: 1; min-height: 0; padding: 6px 20px 16px; overflow-x: clip; overflow-y: auto; } /* las cartas que salen volando no crean scroll lateral */
.q-main h1 { font-size: 44px; line-height: .95; max-width: 330px; margin-bottom: 14px; }
.q-main h1:has(+ .q-sub) { margin-bottom: 0; }
.screen--q h1 { font-size: 36px; }
.hl { background: var(--hl-bg); color: var(--hl-text); padding: 0 6px; -webkit-box-decoration-break: clone; box-decoration-break: clone; }
.q-sub { margin: 8px 0 14px; max-width: 330px; font-size: 15px; line-height: 1.45; font-weight: 500; color: var(--muted); }
.lbl { font-family: var(--f-mono); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.hint { margin-top: 6px; font-size: 14px; line-height: 1.45; font-weight: 600; color: var(--muted); }
.ta-r { text-align: right; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.stack--sm, .bote.stack { gap: 12px; }
.stack--lg { gap: 16px; }
.grid-2, .grid-3, .grid-4 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.group { border: 0; padding: 0; margin: 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
.group > legend { padding: 0; margin-bottom: 8px; }
fieldset.grid-2, fieldset.grid-3 { border: 0; padding: 0; margin: 0; min-width: 0; }
.card { background: var(--surf); border: 2px solid var(--text); padding: 12px 14px; }
.field {
  width: 100%; height: 56px; padding: 0 14px; background: var(--surf); color: var(--text);
  border: 2px solid var(--text); border-radius: 0; font-size: 19px; font-weight: 700;
}
.field::placeholder { color: var(--muted); opacity: .8; }
.field:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* Inputs nativos ocultos: la etiqueta es el control visible */
.theme input, .tile input, .row input, .runway input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* Pegatina de reacción: al marcar una opción (la que tiene el foco) o la que lanza el JS (.react) */
[data-react]:has(input:checked:focus)::after, .day[data-react]:focus::after { content: attr(data-react); }
[data-react]:has(input:checked:focus)::after, .day[data-react]:focus::after, .react.is-on {
  position: fixed; z-index: 6; bottom: 112px;
  right: max(16px, calc((100vw - 480px) / 2 + 16px)); max-width: 250px; padding: 10px 14px;
  background: var(--hl-bg); color: var(--hl-text); border: 2px solid var(--text); box-shadow: 4px 4px 0 var(--text);
  font: 900 22px/1 var(--f-display); text-transform: uppercase; pointer-events: none; transform-origin: bottom right;
  animation: react 1.6s cubic-bezier(.2, 1.6, .4, 1) both;
}

.react:not(.is-on) { display: none; }

/* Pie con CTA fijo */
.q-foot { position: relative; z-index: 3; display: flex; flex-direction: column; gap: 10px; padding: 10px 20px 16px; background: var(--bg); border-top: 2px solid var(--text); }
.cta {
  width: 100%; border: 0; min-height: 58px; padding: 8px 16px; display: flex; align-items: center; justify-content: center; gap: 12px;
  background: var(--cta-bg); color: var(--cta-text); text-align: center;
  font-family: var(--f-display); font-size: 28px; font-weight: 900; line-height: 1; text-transform: uppercase;
  transition: translate .15s, box-shadow .15s, opacity .3s;
}
.cta svg { width: 24px; height: 24px; }
.cta:hover { translate: -2px -2px; box-shadow: 4px 4px 0 var(--text); }
.cta--ok { background: #178A45; color: #fff; } /* verde del diseño (#1FA855) oscurecido para AA */
.cta--gate { opacity: .45; }
.gate-on, .quiz:has(input[name="tema"]:checked) .gate-off { display: none; }
.quiz:has(input[name="tema"]:checked) .gate-on { display: inline; }
.quiz:has(input[name="tema"]:checked) .cta--gate { opacity: 1; }
.q-secondary { padding: 4px; text-align: center; font-family: var(--f-mono); font-size: 13px; font-weight: 700; text-transform: uppercase; text-decoration: underline; text-underline-offset: 4px; }

/* ─── Paso 1 · motivo ─── */
.themes { border: 0; padding: 0; margin: 0; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.theme { position: relative; display: block; cursor: pointer; }
.theme__card {
  position: relative; overflow: hidden; min-height: 128px; padding: 14px 16px 16px;
  display: flex; flex-direction: column; gap: 6px; border: 3px solid var(--ink);
  transition: rotate .35s cubic-bezier(.2, 1.4, .4, 1), scale .35s cubic-bezier(.2, 1.4, .4, 1), opacity .3s, box-shadow .3s;
}
.theme--soltera .theme__card { background: var(--accent); color: var(--ink); rotate: -1.2deg; }
.theme--divorcio .theme__card { background: var(--board); color: var(--paper); rotate: .8deg; }
.theme--cumple .theme__card { background: var(--sign); color: var(--ink); rotate: -.6deg; }
.theme input:checked + .theme__card { rotate: 0deg; scale: 1.03; box-shadow: 6px 6px 0 var(--ink); }
.themes:has(:checked) input:not(:checked) + .theme__card { opacity: .5; }
.theme:hover input:not(:checked) + .theme__card { opacity: .85; }
.theme input:focus-visible + .theme__card { outline: 3px solid var(--ink); outline-offset: 4px; }
.theme__card > * { position: relative; }
.theme__kicker { font-family: var(--f-mono); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.k-on, input:checked + .theme__card .k-off { display: none; }
input:checked + .theme__card .k-on { display: inline; }
.theme__title { max-width: 230px; font-family: var(--f-display); font-size: 33px; font-weight: 900; line-height: .92; text-transform: uppercase; }
.theme__tag { max-width: 220px; font-size: 13px; font-weight: 600; line-height: 1.35; }
.theme__card > svg, .theme__card > i { position: absolute; font-style: normal; }
.theme__ring { width: 130px; height: 130px; right: -18px; bottom: -22px; rotate: -18deg; opacity: .9; }
.theme__spark { color: var(--ink); line-height: 1; }
.theme__spark--a { right: 96px; top: 16px; font-size: 26px; }
.theme__spark--b { right: 70px; top: 46px; font-size: 14px; }
.theme__libre { right: 14px; bottom: 18px; border: 3px solid var(--sign); color: var(--sign); padding: 2px 10px; font-family: var(--f-display); font-size: 30px; font-weight: 900; line-height: 1; rotate: -10deg; }
.theme__void { width: 70px; height: 70px; right: 22px; top: 12px; rotate: 12deg; }
.theme__cake { width: 96px; height: 96px; right: 8px; bottom: -8px; rotate: 8deg; }
.theme .bit--a { right: 30px; top: 18px; width: 12px; height: 12px; background: var(--accent); rotate: 20deg; }
.theme .bit--b { right: 70px; top: 40px; width: 9px; height: 9px; border-radius: 50%; background: var(--ink); }
.theme .bit--c { right: 16px; top: 64px; width: 16px; height: 6px; background: var(--ink); rotate: -30deg; }
.theme .bit--d { right: 110px; top: 20px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

/* ─── Opciones tipo baldosa ─── */
.tile { position: relative; display: block; cursor: pointer; }
.tile > span {
  display: flex; align-items: center; min-height: 52px; padding: 10px 12px; height: 100%;
  border: 2px solid var(--text); background: var(--surf); color: var(--text);
  font-size: 15px; font-weight: 800; line-height: 1.2;
  transition: background .2s, color .2s, rotate .2s cubic-bezier(.2, 1.4, .4, 1), scale .2s cubic-bezier(.2, 1.4, .4, 1), box-shadow .2s;
}
.tile:hover > span { box-shadow: 3px 3px 0 var(--line); }
.tile input:checked + span { background: var(--on); color: var(--on-text); rotate: -1deg; scale: 1.02; }
.tile input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 3px; }
.tile--big > span { height: 56px; min-height: 56px; padding: 0; justify-content: center; font-family: var(--f-display); font-size: 24px; font-weight: 900; text-transform: uppercase; }
.tile--choice > span { flex-direction: column; align-items: flex-start; justify-content: center; gap: 4px; }
.tile--choice b { font-family: var(--f-display); font-size: 22px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.tile--choice small { font-size: 12px; font-weight: 600; opacity: .85; }
.tile--city > span { font-family: var(--f-display); font-size: 26px; font-weight: 900; text-transform: uppercase; }
.tile--month > span { justify-content: center; font-family: var(--f-display); font-size: 24px; font-weight: 900; text-transform: uppercase; }

/* ─── Paso 2 · cartas de «La estrella» ─── */
.q-count { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.dots { display: flex; gap: 6px; }
.dots a { width: 12px; height: 12px; border: 2px solid var(--text); transition: width .3s cubic-bezier(.2, 1.4, .4, 1), background .2s; }
.dots a:has(~ [aria-current]) { background: var(--text); }
.dots a[aria-current] { width: 22px; background: var(--accent); }
.deck { position: relative; padding: 0 10px 14px 0; margin-bottom: 14px; }
.deck::before, .deck::after { content: ""; position: absolute; border: 3px solid var(--text); transition: all .3s; }
.deck::before { inset: 7px 5px 7px 5px; background: var(--hl-bg); rotate: 2.5deg; }
.deck::after { inset: 14px 0 0 10px; background: var(--surf); rotate: -2deg; }
.deck[data-left="1"]::after, .deck[data-left="0"]::after, .deck[data-left="0"]::before { display: none; }
.qcard {
  position: relative; z-index: 1; margin: 0; min-width: 0; padding: 18px 16px 16px;
  background: var(--surf); border: 3px solid var(--text); box-shadow: 6px 6px 0 var(--text);
  transform-origin: 50% 100%; animation: cardIn .45s cubic-bezier(.2, 1.4, .4, 1) .12s backwards;
}
.qcard__kicker { font-family: var(--f-mono); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--accent); }
.qcard__title { margin-top: 6px; font-size: 36px; line-height: .95; }
.qcard__body { display: flex; flex-direction: column; gap: 12px; margin-top: 14px; }
.qcard__opts { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.ans > span { min-height: 46px; padding-block: 8px; gap: 12px; font-size: 16px; }
.ans input:checked + span { box-shadow: 4px 4px 0 var(--accent); }
.meter { --fill: currentColor; display: flex; gap: 3px; align-items: flex-end; flex-shrink: 0; }
.meter > i { width: 6px; border: 1.5px solid currentColor; }
.meter > i:nth-child(1) { height: 8px; }
.meter > i:nth-child(2) { height: 11px; }
.meter > i:nth-child(3) { height: 14px; }
.meter > i:nth-child(4) { height: 17px; }
.meter > i:nth-child(5) { height: 20px; }
.ans input:checked + span .meter { --fill: var(--accent); }
[data-lvl="1"] .meter > i:nth-child(-n+1), [data-lvl="2"] .meter > i:nth-child(-n+2), [data-lvl="3"] .meter > i:nth-child(-n+3),
[data-lvl="4"] .meter > i:nth-child(-n+4), [data-lvl="5"] .meter > i { background: var(--fill); }
.portrait { padding: 14px 16px; background: var(--hl-bg); color: var(--hl-text); rotate: -1deg; }
.portrait span { font-family: var(--f-mono); font-size: 11px; font-weight: 700; }
.portrait p { margin-top: 4px; font-family: var(--f-display); font-size: 26px; font-weight: 900; line-height: .95; text-transform: uppercase; }

/* ─── Paso 3 · grupo, ciudad y fecha ─── */
.count__row { display: flex; align-items: center; gap: 10px; }
.count__num { flex: 1; display: flex; flex-direction: column; gap: 2px; cursor: text; }
.count__num > span:last-child { display: flex; align-items: baseline; gap: 8px; }
.count__num input {
  field-sizing: content; min-width: 1ch; padding: 0; border: 0; background: none; color: inherit;
  font-family: var(--f-display); font-size: 56px; font-weight: 900; line-height: .85; -moz-appearance: textfield; appearance: textfield;
}
@supports not (field-sizing: content) { .count__num input { width: 2.2ch; } }
.count__num input::-webkit-inner-spin-button, .count__num input::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.count__num input:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.count__num b { font-family: var(--f-mono); font-size: 12px; font-weight: 700; text-transform: uppercase; }
.sq-btn { width: 56px; height: 56px; padding: 0; display: flex; align-items: center; justify-content: center; border: 2px solid var(--text); background: transparent; color: var(--text); }
.sq-btn svg { width: 22px; height: 22px; fill: none; stroke-linecap: square; }
.sq-btn--on { background: var(--accent); color: var(--ink); }
.sq-btn:active { scale: .92; }

.quick { min-height: 48px; border: 2px solid var(--text); background: var(--surf); color: var(--text); font-family: var(--f-display); font-size: 24px; font-weight: 900; transition: background .2s, rotate .2s; }
.quick[aria-pressed="true"] { background: var(--on); color: var(--on-text); rotate: -1deg; }
.quick:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }

/* Bloques que se despliegan según la opción elegida */
.reveal {
  display: grid; grid-template-rows: 0fr; margin-top: -18px; opacity: 0; visibility: hidden;
  translate: 0 -16px; rotate: -1deg;
  transition: grid-template-rows .5s cubic-bezier(.2, 1, .3, 1), margin-top .5s cubic-bezier(.2, 1, .3, 1), opacity .3s,
              translate .45s cubic-bezier(.2, 1.4, .4, 1), rotate .45s cubic-bezier(.2, 1.4, .4, 1), visibility .5s;
}
.reveal > * { min-height: 0; overflow: hidden; padding: 2px 6px 8px 2px; margin: -2px -6px -8px -2px; }
.quiz:has(#ciudad-si:checked) .reveal--ciudad-si, .quiz:has(#ciudad-rec:checked) .reveal--ciudad-rec,
.quiz:has(#fecha-si:checked) .reveal--fecha-si, .quiz:has(#fecha-no:checked) .reveal--fecha-no {
  grid-template-rows: 1fr; margin-top: 0; opacity: 1; visibility: visible; translate: none; rotate: none;
}

/* Calendario */
.cal { margin: 0; min-width: 0; }
.cal__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.cal__month { font-family: var(--f-display); font-size: 24px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.cal__nav { width: 36px; height: 36px; padding: 0; display: flex; align-items: center; justify-content: center; border: 2px solid var(--text); background: transparent; color: var(--text); }
.cal__nav svg { width: 18px; height: 18px; }
.cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 3px; }
.cal__wd { margin-bottom: 4px; text-align: center; font-family: var(--f-mono); font-size: 12px; font-weight: 700; color: var(--muted); }
.cal__wd .wk { color: var(--accent); }
.day {
  height: 34px; padding: 0; border: 2px solid transparent; background: none; color: var(--text);
  font-family: var(--f-mono); font-size: 15px; transition: background .15s;
}
.day:hover:not(:disabled) { border-color: var(--line); }
.day:disabled { opacity: .3; cursor: default; }
.day--wk { font-weight: 700; text-decoration: underline var(--accent); text-underline-offset: 4px; }
.day--in { background: var(--range); color: var(--range-text); text-decoration: none; }
.day--edge { background: var(--accent); color: var(--ink); border-color: var(--text); font-weight: 700; text-decoration: none; }
.day:focus-visible { outline: 3px solid var(--accent); outline-offset: 1px; }
.cal__nav:disabled { opacity: .3; }
.hl-box { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; background: var(--hl-bg); color: var(--hl-text); }
.hl-box .mono { font-size: 11px; font-weight: 700; }
.hl-box strong { font-family: var(--f-display); font-size: 24px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.hl-box > span:last-child { font-size: 13px; font-weight: 700; }
.hl-box--note { display: block; font-size: 14px; line-height: 1.4; }
.hl-box--note b { font-weight: 800; }

/* ─── Paso 4 · sí o sí / ni de coña ─── */
.rules { border: 0; padding: 0; margin: 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; counter-reset: n; }
.rules input:checked { counter-increment: n; }
.rules__head { order: -1; display: flex; justify-content: space-between; align-items: baseline; }
.rules__title { font-family: var(--f-display); font-size: 28px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.rules__n::before { content: counter(n); }
.rules__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
.row { position: relative; display: block; cursor: pointer; }
.row > span {
  display: grid; grid-template-columns: 22px 1fr; align-content: space-between; gap: 4px 8px; height: 100%; min-height: 58px; padding: 8px 10px;
  border: 2px solid var(--text); background: var(--surf); color: var(--text); font-size: 13px; font-weight: 800; line-height: 1.2;
  transition: background .2s, color .2s, rotate .2s cubic-bezier(.2, 1.4, .4, 1), scale .2s cubic-bezier(.2, 1.4, .4, 1);
}
.row small { grid-column: 2; font-family: var(--f-mono); font-size: 9px; font-weight: 700; text-transform: uppercase; opacity: .75; }
.row__box { width: 20px; height: 20px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; border: 2px solid currentColor; font-style: normal; font-size: 14px; font-weight: 900; }
.row input:checked + span { rotate: -1deg; scale: 1.02; }
.rules--yes input:checked + span { background: var(--on); color: var(--on-text); }
.rules--yes input:checked + span .row__box::before { content: "✓"; }
.rules--no input:checked + span { background: var(--danger); color: #fff; }
.rules--no input:checked + span .row__box::before { content: "✕"; }
.row input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 3px; }

/* ─── Paso 5 · el bote ─── */
.bote { --p: .5; }
.bote:has(#b1:checked) { --p: 0; }
.bote:has(#b2:checked) { --p: .25; }
.bote:has(#b4:checked) { --p: .75; }
.bote:has(#b5:checked) { --p: 1; }
.bote:has(#b1:checked) [data-t]:not([data-t~="1"]), .bote:has(#b2:checked) [data-t]:not([data-t~="2"]),
.bote:has(#b3:checked) [data-t]:not([data-t~="3"]), .bote:has(#b4:checked) [data-t]:not([data-t~="4"]),
.bote:has(#b5:checked) [data-t]:not([data-t~="5"]) { display: none; }
.bote__head { display: flex; justify-content: space-between; align-items: flex-end; }
.bote__tier { font-family: var(--f-display); font-size: 30px; font-weight: 900; line-height: 1; text-transform: uppercase; color: var(--accent); }
.bote__price { font-family: var(--f-display); font-size: 60px; font-weight: 900; line-height: .85; }
.runway { border: 0; padding: 0; margin: 0; min-width: 0; display: grid; grid-template-rows: 56px auto; row-gap: 10px; }
.runway__track { grid-area: 1 / 1; position: relative; }
.runway__track::before, .runway__fill { content: ""; position: absolute; left: 0; top: 50%; height: 24px; translate: 0 -50%; border: 2px solid var(--text); }
.runway__track::before { right: 0; background: var(--surf); }
.runway__fill { background: var(--accent); width: calc(var(--p) * (100% - 56px) + 28px); transition: width .3s cubic-bezier(.2, .9, .3, 1.2); }
.runway__thumb {
  position: absolute; top: 2px; width: 56px; height: 56px; border: 2px solid var(--text); color: var(--cta-text);
  background: linear-gradient(currentColor, currentColor) calc(50% - 4px) 50% / 3px 20px no-repeat,
              linear-gradient(currentColor, currentColor) calc(50% + 4px) 50% / 3px 20px no-repeat, var(--cta-bg);
  left: calc(var(--p) * (100% - 56px)); rotate: calc(-6deg + var(--p) * 12deg);
  transition: left .3s cubic-bezier(.2, .9, .3, 1.2), rotate .3s;
}
.runway__stops { grid-area: 1 / 1 / 3 / 2; display: grid; grid-template-columns: repeat(5, 1fr); }
.runway__stops label { display: flex; align-items: flex-end; justify-content: center; cursor: pointer; font-family: var(--f-mono); font-size: 11px; font-weight: 700; text-transform: uppercase; color: var(--muted); }
.runway__stops label:first-child { justify-content: flex-start; }
.runway__stops label:last-child { justify-content: flex-end; }
.runway__stops label:hover, .runway__stops input:checked + span { color: var(--text); }
.runway__stops input:checked + span { text-decoration: underline 3px var(--accent); text-underline-offset: 5px; }
.runway__stops input:focus-visible + span { outline: 2px solid var(--text); outline-offset: 4px; }
.tier { padding: 14px; }
.tier__title { font-family: var(--f-display); font-size: 28px; font-weight: 900; line-height: .95; text-transform: uppercase; }
.tier__copy { margin-top: 6px; font-size: 14px; line-height: 1.45; font-weight: 500; color: var(--muted); }
.slots { list-style: none; margin: 10px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.slot {
  min-height: 52px; padding: 8px 10px; display: flex; flex-direction: column; justify-content: space-between;
  background: var(--sign); color: var(--ink); border: 2px solid var(--ink); font-family: var(--f-mono); font-size: 10px; font-weight: 700;
  rotate: -2deg; animation: slotIn .45s cubic-bezier(.2, 1.5, .4, 1) both;
}
.slot:nth-child(even) { rotate: 1.5deg; }
.slot:nth-child(3n) { rotate: -1deg; }
.slot b { font-family: var(--f-display); font-size: 19px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.slot--premium { background: var(--ink); color: var(--sign); }
.slot--extra { background: var(--accent); }
.slot--free { background: none; color: var(--muted); border: 2px dashed var(--line); rotate: none; scale: .92; opacity: .75; }

/* ─── Paso 6 · contacto ─── */
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; font-weight: 600; line-height: 1.4; color: var(--muted); cursor: pointer; }
.consent input { width: 22px; height: 22px; margin: 0; flex-shrink: 0; accent-color: var(--accent); }
.summary p { margin-top: 6px; font-size: 14px; font-weight: 700; line-height: 1.35; }

/* ─── Paso 7 · ¡listo! ─── */
.pass { padding: 14px 16px; background: var(--ticket-bg); color: var(--ticket-text); rotate: -1.5deg; box-shadow: 0 20px 40px -18px rgba(0 0 0 / .5); }
.pass__head { display: flex; justify-content: space-between; align-items: center; padding-bottom: 12px; border-bottom: 2px solid currentColor; }
.pass .logo { color: inherit; font-size: 24px; }
.pass__head .mono { font-size: 10px; font-weight: 700; }
.pass__data { margin: 0; padding-top: 12px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.pass__data dt { margin-bottom: 2px; font-family: var(--f-mono); font-size: 10px; opacity: .7; }
.pass__data dd { margin: 0; font-family: var(--f-display); font-size: 24px; font-weight: 900; line-height: 1; text-transform: uppercase; }
.pass__data .span-2 { grid-column: span 2; }
.pass__data .span-2 dd { font-size: 24px; }
.linkbox { display: flex; align-items: center; gap: 12px; height: 56px; padding: 0 16px; background: var(--surf); border: 2px solid var(--text); font-family: var(--f-mono); font-size: 13px; font-weight: 700; }
.linkbox input { flex: 1; min-width: 0; padding: 0; border: 0; background: none; font: inherit; color: inherit; text-overflow: ellipsis; }
.linkbox button { display: flex; padding: 0; border: 0; background: none; color: inherit; }
.linkbox svg { width: 20px; height: 20px; }
.confetti { position: fixed; inset: 0; z-index: 5; max-width: 480px; margin-inline: auto; overflow: hidden; pointer-events: none; }
.confetti i {
  position: absolute; top: 0; left: var(--x); width: var(--w); height: var(--h); background: var(--c);
  translate: 0 -40px; animation: fall var(--t) cubic-bezier(.3, .1, .6, 1) var(--d) both;
}

/* ─── Pantallas bajas (p. ej. 375×667): compactar antes de dejar que haga scroll ─── */
@media (max-height: 740px) {
  .q-head { gap: 8px; padding-block: 10px 6px; }
  .q-main h1 { font-size: 34px; margin-bottom: 10px; }
  .screen--q h1 { font-size: 30px; }
  .q-sub { display: none; }
  .q-main h1:has(+ .q-sub) { margin-bottom: 10px; }
  .q-foot { padding-block: 8px 12px; }
  .cta { min-height: 50px; font-size: 24px; }
  .q-secondary { padding: 0; }
  .themes { gap: 10px; }
  .theme__card { min-height: 0; padding-block: 10px 12px; }
  .theme__tag { display: none; }
  .theme__ring, .theme__cake { width: 80px; height: 80px; }
  .q-count { margin-bottom: 8px; }
  .qcard { padding: 12px 12px 10px; }
  .qcard__title { font-size: 28px; }
  .qcard__opts, .qcard__body { gap: 4px; margin-top: 8px; }
  .ans > span { min-height: 36px; padding-block: 4px; }
  .deck { margin-bottom: 8px; }
  .portrait { padding: 8px 12px; }
  .portrait p { font-size: 20px; }
  .tile > span, .row > span { min-height: 44px; padding-block: 6px; }
  .day { height: 30px; }
  .rules__title { font-size: 24px; }
  .bote__price { font-size: 48px; }
  .tier__copy { display: none; }
  .slot { min-height: 44px; }
  .field { height: 48px; }
  .pass__data { gap: 8px; }
  .deck { padding-bottom: 8px; }
  .stack--lg, .bote.stack { gap: 8px; }
  .rules__list { gap: 4px; }
  .row > span { min-height: 40px; padding-block: 5px; }
  .row small { display: none; }
  .runway { grid-template-rows: 48px auto; row-gap: 6px; }
  .hl-box--note { padding: 8px 12px; font-size: 13px; }
}

/* ─── Escritorio: panel lateral de 560px + contenido en columna de 620px ─── */
.side { display: none; }
@media (min-width: 900px) {
  .quiz { max-width: none; padding-left: 560px; }
  .q-head, .q-main, .q-foot { padding-inline: max(20px, calc(50% - 310px)); }
  .q-main h1:not(.inv-hero), .q-main h1:not(.inv-hero) + .q-sub {
    position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
  }
  [data-react]:has(input:checked:focus)::after, .day[data-react]:focus::after, .react.is-on { right: 16px; }
  .confetti { left: 560px; max-width: none; }

  .side {
    position: fixed; inset: 0 auto 0 0; z-index: 4; width: 560px; overflow: hidden; padding: 40px 48px;
    display: flex; flex-direction: column; justify-content: space-between; gap: 32px;
    background: var(--side-bg); color: var(--side-fg); border-right: 3px solid var(--ink); transition: background .4s, color .4s;
  }
  .side > * { position: relative; }
  .side__top { display: flex; justify-content: space-between; align-items: center; }
  .side .logo { color: inherit; font-size: 34px; }
  .side .logo span { color: var(--side-dot); }
  .side__tag { padding: 5px 8px; border: 2px solid currentColor; font-family: var(--f-mono); font-size: 11px; font-weight: 700; }
  .side__kicker { font-family: var(--f-mono); font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
  .side__big { margin-top: 6px; font-family: var(--f-display); font-size: 132px; font-weight: 900; line-height: .8; }
  .side__title { max-width: 420px; margin-top: 14px; font-family: var(--f-display); font-size: 44px; font-weight: 900; line-height: .95; text-transform: uppercase; }
  .side__quote { max-width: 400px; margin-top: 14px; font-size: 17px; font-weight: 600; line-height: 1.45; opacity: .85; }
  .side__steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
  .side__steps li {
    display: flex; align-items: center; gap: 14px; padding: 8px 12px; border: 2px solid transparent;
    font-size: 16px; font-weight: 800; opacity: .55; transition: all .3s;
  }
  .side__steps span { font-family: var(--f-mono); font-size: 12px; font-weight: 700; }
  .side__steps li::after { margin-left: auto; font-family: var(--f-mono); font-size: 12px; font-weight: 700; }
  .side__steps .is-done { opacity: 1; }
  .side__steps .is-done::after { content: "✓"; }
  .side__steps [aria-current] { opacity: 1; border-color: currentColor; background: rgba(255 255 255 / .14); }
  .side__steps [aria-current]::after { content: "←"; }

  /* Decoración: «?» sin tema; estrellas, sello o confeti con tema */
  .side__deco { position: absolute; inset: 0; pointer-events: none; }
  .side__deco i { position: absolute; font-style: normal; line-height: 1; }
  .side__themed { display: none; }
  .quiz:has(input[name="tema"]:checked):has(.screen:target:not(#paso-1)) .side__themed { display: contents; }
  .quiz:has(input[name="tema"]:checked):has(.screen:target:not(#paso-1)) .side__plain { display: none; }
  .side__q { right: -30px; top: 120px; font-family: var(--f-display); font-size: 520px; font-weight: 900; color: var(--accent); opacity: .9; }
  .side__star--a { right: 30px; top: 110px; font-size: 180px; color: var(--ink); }
  .side__star--b { right: 190px; top: 260px; font-size: 70px; color: #fff; }
  .side__libre { right: 26px; top: 120px; padding: 0 18px; border: 6px solid var(--accent); color: var(--accent); font-family: var(--f-display); font-size: 96px; font-weight: 900; rotate: 12deg; }
  .side__bit--a { right: 60px; top: 130px; width: 60px; height: 60px; background: var(--accent); rotate: 25deg; }
  .side__bit--b { right: 190px; top: 220px; width: 34px; height: 34px; border-radius: 50%; background: var(--sign); }
  .side__bit--c { right: 40px; top: 290px; width: 90px; height: 22px; background: var(--sign); rotate: -35deg; }
  .side__bit--d { right: 250px; top: 120px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); }
}
