@font-face {
  font-family: "Bricolage Grotesque";
  src: url("/fonts/bricolage.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "Geist Mono";
  src: url("/fonts/geist-mono.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --paper: #f4f6f5;
  --panel: #ffffff;
  --tint: #e9eeec;
  --ink: #0e1b18;
  --soft: #55645f;
  --line: #d8dfdc;
  --board: #101c19;
  --board-line: #243631;
  --board-soft: #94a8a1;
  --up: #1fd18b;
  --down: #ff5c4d;
  --amber: #ffb224;
  --radius: 20px;
  --nav-h: 64px;
  /* Curvas de movimiento: salida firme para lo que responde o llega. */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --sans:
    "Bricolage Grotesque", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
h1,
h2,
h3,
p,
dl,
dd,
figure {
  margin: 0;
}
a {
  color: inherit;
}
:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
  border-radius: 6px;
}
a,
button,
summary {
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}
p {
  text-wrap: pretty;
}
.skip {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 20;
  padding: 12px 18px;
  border-radius: 12px;
  background: var(--ink);
  color: #fff;
  font-weight: 650;
  text-decoration: none;
}
.skip:focus-visible {
  top: 12px;
  outline-color: var(--up);
}
main:focus {
  outline: none;
}
.wrap {
  width: min(1200px, 100% - 32px);
  margin-inline: auto;
}

/* Tipografía. Crece con la pantalla sin exagerar (CEO 2026-11-21): ~34 px
   en celular, ~49 en tableta y 72 como máximo en computadora. */
h1 {
  font-size: clamp(2.125rem, 1rem + 4vw, 4.5rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.04em;
}
h2 {
  font-size: clamp(1.5rem, 1rem + 2vw, 2.75rem);
  font-weight: 750;
  line-height: 1.08;
  letter-spacing: -0.035em;
  text-wrap: balance;
}
h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.015em;
}
.lead {
  font-size: clamp(1rem, 0.875rem + 0.4vw, 1.1875rem);
  line-height: 1.5;
  max-width: 34ch;
}

/* Botones */
.btn[hidden],
.closing[hidden],
.plan-cta[hidden] {
  display: none;
}
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 22px;
  border: 1.5px solid transparent;
  border-radius: 12px;
  font: inherit;
  font-size: 1rem;
  font-weight: 650;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease,
    transform 0.16s var(--ease-out);
}
.btn:active:not(:disabled) {
  transform: scale(0.97);
}
.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.btn-primary {
  background: var(--ink);
  color: #fff;
}
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover:not(:disabled) {
    background: #1f3a34;
  }
}
.btn-quiet {
  border-color: var(--ink);
  color: var(--ink);
}
@media (hover: hover) and (pointer: fine) {
  .btn-quiet:hover {
    background: var(--tint);
  }
}
.btn-light {
  background: #fff;
  color: var(--ink);
}
@media (hover: hover) and (pointer: fine) {
  .btn-light:hover:not(:disabled) {
    background: var(--tint);
  }
}
/* Pausa del hero: detiene todo lo que se mueve solo. */
.btn-pause {
  min-height: 40px;
  padding: 0 16px;
  border-color: var(--line);
  color: var(--soft);
  background: transparent;
  font-size: 0.95rem;
}
.btn-pause[aria-pressed="true"] {
  border-color: var(--ink);
  color: var(--ink);
}
@media (hover: hover) and (pointer: fine) {
  .btn-pause:hover {
    border-color: var(--soft);
    color: var(--ink);
  }
}
.btn-pause:focus-visible {
  outline-color: var(--ink);
}
.is-paused .tvu-run {
  animation-play-state: paused;
}
/* Cinta de la TV */
@keyframes ticker {
  to {
    transform: translateX(-50%);
  }
}

/* Navegación: barra estable. Al hacer scroll solo aparece su fondo, sin
   cambiar de tamaño ni de lugar. */
.nav {
  position: sticky;
  top: 0;
  z-index: 10;
}
.nav::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgb(244 246 245 / 0.95);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom: 1px solid var(--line);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.nav.is-scrolled::before {
  opacity: 1;
}
.nav-inner {
  position: relative;
  width: min(1200px, 100% - 32px);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--nav-h);
}
.brand {
  display: inline-block;
  padding: 9px 0;
  font-size: 1.625rem;
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 1;
  text-decoration: none;
}
.brand span {
  color: var(--up);
}
.nav-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 18px;
}
.nav-actions .btn {
  min-height: 42px;
  white-space: nowrap;
}
.cta-short {
  display: none;
}
@media (max-width: 400px) {
  .cta-long {
    display: none;
  }
  .cta-short {
    display: inline;
  }
}
.link-quiet {
  font-weight: 600;
  text-decoration: none;
}
@media (hover: hover) and (pointer: fine) {
  .link-quiet:hover {
    text-decoration: underline;
  }
}

/* Hero */
.hero {
  padding: clamp(28px, 4.5vw, 56px) 0 clamp(56px, 8vw, 104px);
}
.hero-head {
  display: grid;
  grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
  gap: 32px 48px;
  align-items: end;
  margin-bottom: clamp(28px, 3.5vw, 48px);
}
.hero-side {
  display: grid;
  gap: 24px;
  padding-bottom: 8px;
}
.status {
  color: var(--soft);
  font-size: 0.9375rem;
}
.status:empty {
  display: none;
}

/* Descarga: botón de instalar y los pasos del equipo, si hacen falta. */
.install {
  display: grid;
  gap: 14px;
  justify-items: start;
  margin-top: 8px;
}
.install .btn {
  min-height: 52px;
  padding: 0 26px;
  font-size: 1.0625rem;
}
.install-help {
  max-width: 42ch;
  color: var(--soft);
  font-size: 0.9375rem;
}
.install-help:empty {
  display: none;
}

/* Debajo de la TV: qué es y cómo detenerla. */
.hero-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: clamp(20px, 3vw, 32px);
  color: var(--soft);
  font-size: 0.9rem;
}

/* Secciones */
.section {
  padding: clamp(72px, 10vw, 136px) 0;
}
.tinted {
  background: var(--tint);
}
.split {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: center;
}
.split-reverse {
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}
.split-reverse .split-copy {
  order: 2;
}
.split-copy {
  display: grid;
  gap: 20px;
  align-content: start;
}
.split-copy > p {
  color: var(--soft);
  max-width: 52ch;
}
.split-copy.wide {
  max-width: 760px;
  margin-bottom: clamp(36px, 5vw, 64px);
}
/* Una noche en tu bar. En computadora la sección se fija y la noche avanza
   con el scroll; sin fijar, la línea se dibuja una vez al entrar. */
.night {
  background: var(--board);
  color: #fff;
  border-radius: 40px;
  margin: 0 8px;
}
.night-stage {
  padding: clamp(72px, 10vw, 128px) 0;
}
.readout,
.rail {
  display: none;
}
.night-head {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: 20px clamp(32px, 6vw, 88px);
  align-items: end;
  margin-bottom: clamp(32px, 5vw, 56px);
}
.night-head p {
  color: var(--board-soft);
  max-width: 46ch;
}
.night-chart {
  display: grid;
  gap: 12px;
  padding: clamp(16px, 2.6vw, 32px);
  background: #0b1512;
  border: 1px solid var(--board-line);
  border-radius: 28px;
}
.night-chart svg {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
}
.night-chart figcaption {
  color: var(--board-soft);
  font-size: 0.875rem;
}
/* Capas por pasos: cada una aparece cuando la noche llega a ella. */
.n-band,
.n-limit,
.n-limit-label,
.n-crash,
.n-crash-label,
.n-ghost,
.n-ghost-label,
.n-amber {
  opacity: 0;
  transition: opacity 0.5s ease;
}
.is-limited .n-band,
.is-limited .n-limit,
.is-limited .n-limit-label,
.is-limited .n-ghost,
.is-limited .n-ghost-label,
.show-c0 [data-crash="0"],
.show-c1 [data-crash="1"] {
  opacity: 1;
}
.night:not(.is-pinned) svg:not(.is-drawn) .n-ghost,
.night:not(.is-pinned) svg:not(.is-drawn) .n-ghost-label,
.night:not(.is-pinned) svg:not(.is-drawn) .n-amber {
  opacity: 0;
}
.night:not(.is-pinned) .is-drawn .n-ghost,
.night:not(.is-pinned) .is-drawn .n-ghost-label,
.night:not(.is-pinned) .is-drawn .n-amber {
  transition-delay: 1.6s;
}
.n-band {
  fill: var(--up);
  fill-opacity: 0.08;
}
.n-limit {
  stroke: var(--up);
  stroke-width: 1.5;
  stroke-dasharray: 5 6;
  stroke-opacity: 0.7;
}
.n-limit-label {
  fill: var(--up);
  font-family: var(--mono);
}
.n-crash {
  fill: var(--amber);
  fill-opacity: 0.14;
}
.n-crash-label {
  fill: var(--amber);
  font-weight: 700;
}
.n-ghost {
  fill: none;
  stroke: var(--board-soft);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.n-ghost-label {
  fill: var(--board-soft);
  font-weight: 600;
}
.n-amber {
  fill: none;
  stroke: var(--amber);
  stroke-width: 3;
  stroke-linejoin: round;
  stroke-linecap: round;
}
.n-hour {
  fill: var(--board-soft);
  font-family: var(--mono);
}
.n-line {
  fill: none;
  stroke: #fff;
  stroke-width: 3;
  stroke-linejoin: round;
  stroke-linecap: round;
  transition:
    stroke-dashoffset 2.2s var(--ease-out),
    stroke 0.5s ease;
}
.is-limited .n-line {
  stroke: var(--up);
}
.n-guide {
  stroke: #fff;
  stroke-width: 1;
  stroke-dasharray: 2 5;
  opacity: 0;
  transition: opacity 0.2s ease;
}
.n-dot {
  fill: var(--board);
  stroke: #fff;
  stroke-width: 3;
  opacity: 0;
  transition:
    opacity 0.3s ease 1.6s,
    fill 0.2s ease;
}
.is-drawn .n-dot {
  opacity: 1;
}
.n-dot.is-active {
  fill: #fff;
}
.n-guide.is-active {
  opacity: 0.6;
}
.night-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 24px;
  margin: clamp(28px, 4vw, 44px) 0 0;
  padding: 0;
  list-style: none;
}
.night-steps li {
  display: grid;
  gap: 8px;
  align-content: start;
  padding-top: 16px;
  border-top: 2px solid var(--board-line);
  transition: border-color 0.2s ease;
}
.night-steps li.is-active {
  border-top-color: #fff;
}
.night-steps time {
  font-family: var(--mono);
  font-size: 0.9375rem;
  color: var(--board-soft);
}
.night-steps h3 {
  font-size: 1.2rem;
}
.night-steps p {
  color: var(--board-soft);
  font-size: 0.975rem;
  line-height: 1.5;
}
.night :focus-visible {
  outline-color: var(--amber);
}

.n-head {
  fill: #fff;
  stroke: var(--board);
  stroke-width: 3;
  transition: fill 0.2s ease;
}
.is-limited .n-head {
  fill: var(--up);
}
.n-head.is-crash {
  fill: var(--amber);
}

/* Fijada en computadora */
.night.is-pinned .night-track {
  height: 460vh;
}
.night.is-pinned .night-stage {
  position: sticky;
  top: var(--nav-h);
  height: calc(100vh - var(--nav-h));
  padding: 0 0 24px;
  display: grid;
  align-items: center;
}
.night.is-pinned .night-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  grid-template-areas:
    "head chart"
    "rail chart"
    "steps chart";
  grid-template-rows: auto auto auto;
  align-content: center;
  gap: 28px clamp(32px, 6vw, 88px);
}
.night.is-pinned .night-head {
  grid-area: head;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  margin: 0;
}
.night.is-pinned .night-chart {
  grid-area: chart;
  align-self: center;
}
.night.is-pinned .readout {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
}
.readout b {
  font-family: var(--mono);
  font-size: clamp(2.25rem, 4.4vw, 3.5rem);
  font-weight: 600;
  letter-spacing: -0.05em;
  line-height: 1;
  transition: color 0.2s ease;
}
.readout b.is-crash {
  color: var(--amber);
}
.readout span {
  color: var(--board-soft);
  font-family: var(--mono);
  font-weight: 600;
}
.night.is-pinned .night-steps {
  grid-area: steps;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  margin: 0;
  min-height: 11.5em;
}
.night.is-pinned .night-steps li {
  grid-area: 1 / 1;
  padding-top: 0;
  border-top: 0;
  opacity: 0;
  transform: translateY(14px);
  pointer-events: none;
  transition:
    opacity 0.4s,
    transform 0.4s var(--ease-out),
    border-color 0.2s ease;
}
.night.is-pinned .night-steps li.is-active {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.night.is-pinned .night-steps h3 {
  font-size: 1.5rem;
  letter-spacing: -0.02em;
}
.night.is-pinned .night-steps p {
  font-size: 1.0625rem;
  max-width: 40ch;
}
.night.is-pinned .n-dot {
  opacity: 0;
  transition:
    opacity 0.2s ease,
    fill 0.2s ease;
}
.night.is-pinned .n-dot.is-reached {
  opacity: 1;
}
/* Cinco pestañas con nombres de largo distinto: cada una toma su palabra
   en una sola línea más una parte igual del espacio que sobra. */
.night.is-pinned .rail {
  grid-area: rail;
  display: flex;
  gap: clamp(8px, 1.2vw, 14px);
}
.night.is-pinned .rail button {
  flex: 1 1 auto;
  white-space: nowrap;
}
/* Pestañas de los pasos: la palabra arriba de su tramo de línea. El tramo
   del paso activo se llena conforme se baja (--k va de 0 a 1 en el paso).
   Cada sección pone sus colores: --tab-soft, --tab-line y --tab-on. */
.rail button {
  position: relative;
  min-height: 44px;
  padding: 0 0 10px;
  border: 0;
  border-bottom: 2px solid var(--tab-line);
  background: none;
  color: var(--tab-soft);
  font: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: left;
  cursor: pointer;
  transition: color 0.2s ease;
}
.rail button::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: var(--tab-on);
  transform: scaleX(0);
  transform-origin: left;
}
@media (hover: hover) and (pointer: fine) {
  .rail button:hover {
    color: var(--tab-on);
  }
}
.rail button[aria-current="step"] {
  color: var(--tab-on);
}
.rail button[aria-current="step"]::after {
  transform: scaleX(var(--k, 1));
}
.rail button:focus-visible {
  outline: 2px solid var(--tab-on);
  outline-offset: 4px;
}
.night {
  --tab-soft: var(--board-soft);
  --tab-line: var(--board-line);
  --tab-on: #fff;
}
.mesa {
  --tab-soft: var(--soft);
  --tab-line: var(--line);
  --tab-on: var(--ink);
}
@media (max-width: 1199px) {
  .night.is-pinned .night-grid {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
  }
  .night.is-pinned .rail button {
    font-size: 0.9rem;
  }
}
@media (max-height: 780px) {
  .night.is-pinned .night-head p {
    display: none;
  }
}

/* Por qué funciona */
.why-title {
  max-width: 18ch;
  margin-bottom: clamp(32px, 5vw, 56px);
}
.why {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(24px, 4vw, 56px);
}
.why > div {
  display: grid;
  gap: 10px;
  align-content: start;
  padding-top: 20px;
  border-top: 2px solid var(--ink);
}
.why h3 {
  font-size: 1.5rem;
  letter-spacing: -0.025em;
}
.why p {
  color: var(--soft);
}
/* Cómo empiezas: cuatro pasos en orden, numerados porque son una secuencia. */
.start {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(20px, 3vw, 40px);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: start;
}
.start li {
  display: grid;
  gap: 10px;
  align-content: start;
  padding-top: 16px;
  border-top: 2px solid var(--ink);
  counter-increment: start;
}
.start li::before {
  content: counter(start);
  font-family: var(--mono);
  font-size: 0.9375rem;
  color: var(--soft);
}
.start h3 {
  font-size: 1.3rem;
  letter-spacing: -0.02em;
}
.start p {
  color: var(--soft);
}
.proof {
  margin-top: clamp(40px, 6vw, 72px);
  padding: 24px 28px;
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: 0 0 0 1px rgb(14 27 24 / 0.08);
  font-size: 1.125rem;
  max-width: 68ch;
}

/* Tus reglas */
.rules-wrap {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: start;
}
.rules {
  margin: 0;
  border-top: 1px solid var(--line);
}
.rules > div {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: 8px 24px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}
.rules dt {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}
.rules dd {
  margin: 0;
  color: var(--soft);
}

/* Pantalla y comensal: TV e iPhone con réplicas a escala de la UI real.
   Dentro de cada pantalla todo se mide en unidades del propio dispositivo:
   --r es un «rem» de la TV real a 1920 px (1 % de su ancho) y --p es un
   punto del iPhone (402 pt de ancho), así se encogen como una foto nítida. */
.stage {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}
.tv {
  display: grid;
  justify-items: center;
}
.tv-panel {
  width: 100%;
  padding: 0.55%;
  border-radius: 12px;
  background: #0a0a0a;
  box-shadow:
    inset 0 0 0 1px #2a2a2a,
    0 30px 60px -30px rgb(14 27 24 / 0.55);
}
.tv-screen {
  container-type: inline-size;
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 4px;
  background: #000;
}
.tv-stand {
  width: 26%;
  height: 12px;
  margin-top: 18px;
  border-radius: 6px 6px 3px 3px;
  background: linear-gradient(#2a2d2c, #141615);
  position: relative;
}
.tv-stand::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 100%;
  width: 16%;
  height: 18px;
  transform: translateX(-50%);
  background: linear-gradient(90deg, #1b1d1c, #2c2f2e, #1b1d1c);
}

/* TV real (board.css) a 1920 × 1080 */
.tvu {
  --r: 1cqw;
  position: relative;
  --tv-line: #262626;
  --tv-soft: #8f8f8f;
  height: 100%;
  display: flex;
  flex-direction: column;
  color: #fff;
  line-height: 1.25;
}
.tvu-tape {
  flex: none;
  height: calc(var(--r) * 4.4);
  display: flex;
  align-items: center;
  overflow: hidden;
  border-bottom: calc(var(--r) * 0.06) solid var(--tv-line);
  font-family: var(--mono);
  font-size: calc(var(--r) * 1.5);
  text-transform: uppercase;
}
.tvu-run {
  display: flex;
  width: max-content;
  animation: ticker 60s linear infinite;
}
.tvu-item {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: calc(var(--r) * 0.9);
  width: 21ch;
  padding-left: calc(var(--r) * 2.2);
  white-space: nowrap;
}
.tvu-item > span:first-child {
  color: var(--tv-soft);
}
.tvu-board {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  padding: calc(var(--r) * 1.4) calc(var(--r) * 2.6) calc(var(--r) * 1.2);
  transition: box-shadow 0.3s;
}
.tvu-bar {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--r) * 2);
  padding: calc(var(--r) * 1) 0 calc(var(--r) * 1.1);
  font-size: calc(var(--r) * 1.1);
  transition:
    background-color 0.3s,
    padding 0.3s;
}
.tvu-state {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--r) * 0.8);
}
.tvu-state i {
  width: calc(var(--r) * 0.8);
  height: calc(var(--r) * 0.8);
  border-radius: 50%;
  background: var(--up);
}
.tvu-state b {
  color: var(--up);
  font-size: calc(var(--r) * 1.3);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.tvu-next {
  display: inline-flex;
  align-items: baseline;
  gap: calc(var(--r) * 0.8);
  color: var(--tv-soft);
  font-family: var(--mono);
}
.tvu-next strong {
  color: #fff;
  font-size: calc(var(--r) * 1.9);
  letter-spacing: -0.03em;
}
/* Con el mercado abierto no hay letrero ni cuenta regresiva: los precios se
   mueven solos, a destiempo. Solo la caída se anuncia y dice cuánto le queda. */
.tvu:not([data-market="crash"]) .tvu-bar {
  display: none;
}
.tvu-tick {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(var(--r) * 0.22);
  background: var(--tv-line);
}
.tvu-tick i,
.gu-track i {
  display: block;
  height: 100%;
  background: var(--up);
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 1s linear;
}
.tvu-quotes {
  flex: 1;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
  grid-auto-flow: column;
  column-gap: calc(var(--r) * 5);
  background: linear-gradient(var(--tv-line), var(--tv-line)) 50% 0 /
    calc(var(--r) * 0.06) 100% no-repeat;
}
.tvq {
  display: grid;
  grid-template-columns: minmax(0, 1fr) calc(var(--r) * 7.56) auto 5.4em;
  align-items: center;
  gap: calc(var(--r) * 1.44);
  min-height: 0;
  border-bottom: calc(var(--r) * 0.06) solid var(--tv-line);
  font-size: calc(var(--r) * 1.44);
}
.tvq-name {
  display: grid;
  gap: 0.2em;
  min-width: 0;
}
.tvq-name b {
  font-size: calc(var(--r) * 1.8);
  font-weight: 700;
  letter-spacing: 0.02em;
  line-height: 1.1;
  text-transform: uppercase;
}
.tvq-name small {
  color: var(--tv-soft);
  font-size: calc(var(--r) * 1.12);
  white-space: nowrap;
}
.tvq-spark {
  width: 100%;
  height: calc(var(--r) * 2.52);
  overflow: visible;
}
.tvq-spark polyline {
  fill: none;
  stroke: var(--tv-soft);
  stroke-width: 2;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.tvq-spark .is-up {
  stroke: var(--up);
}
.tvq-spark .is-down {
  stroke: var(--down);
}
.tvq-price {
  min-width: 4.4ch;
  font-family: var(--mono);
  font-size: calc(var(--r) * 3.6);
  font-weight: 600;
  letter-spacing: -0.04em;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.tvq-delta,
.tvu-d {
  display: inline-flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.4em;
  font-family: var(--mono);
  font-weight: 500;
  white-space: nowrap;
}
.tvq-delta::before,
.tvu-d::before {
  content: "";
  width: 0.55em;
  height: 0.5em;
  background: currentColor;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}
.tvu .is-up {
  color: var(--up);
}
.tvu .is-down {
  color: var(--down);
}
.tvu .is-flat {
  color: var(--tv-soft);
}
.tvq-price.is-flat {
  color: #fff;
}
.tvu .is-down::before {
  transform: rotate(180deg);
}
.tvu .is-flat::before {
  display: none;
}
.tvu-foot {
  flex: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: calc(var(--r) * 1);
  color: var(--tv-soft);
  font-size: calc(var(--r) * 1.05);
}
.tvu-logo {
  color: #fff;
  font-size: calc(var(--r) * 1.3);
  font-weight: 800;
  letter-spacing: -0.04em;
}
.tvu-logo span {
  color: var(--up);
}
/* Caída: la barra se vuelve ámbar y el tablero se enmarca, como en la TV. */
.tvu[data-market="crash"] .tvu-board {
  box-shadow: inset 0 0 0 calc(var(--r) * 0.2) var(--amber);
}
.tvu[data-market="crash"] .tvu-bar {
  padding: calc(var(--r) * 1.5) calc(var(--r) * 1.8) calc(var(--r) * 1.7);
  background: var(--amber);
  color: #000;
}
.tvu[data-market="crash"] .tvu-state i {
  background: #000;
}
.tvu[data-market="crash"] .tvu-state b {
  color: #000;
  font-size: calc(var(--r) * 3);
  letter-spacing: 0.01em;
}
.tvu[data-market="crash"] .tvu-next,
.tvu[data-market="crash"] .tvu-next strong {
  color: #000;
}
.tvu[data-market="crash"] .tvu-next strong {
  font-size: calc(var(--r) * 3.6);
}
.tvu[data-market="crash"] .tvu-tick {
  background: rgb(0 0 0 / 0.18);
}
.tvu[data-market="crash"] .tvu-tick i {
  background: #000;
}

/* iPhone con isla dinámica (402 × 874 pt) */
.iphone {
  --w: clamp(230px, 23vw, 290px);
  position: relative;
  z-index: 1;
  width: var(--w);
  padding: calc(var(--w) * 0.034);
  border-radius: calc(var(--w) * 0.19);
  background: #050505;
  box-shadow:
    0 0 0 calc(var(--w) * 0.009) #5d5f62,
    0 0 0 calc(var(--w) * 0.014) #2b2c2e,
    0 40px 70px -30px rgb(14 27 24 / 0.6);
}
.iphone-key {
  position: absolute;
  width: calc(var(--w) * 0.012);
  border-radius: 2px;
  background: #3b3d40;
}
.k-action {
  left: calc(var(--w) * -0.024);
  top: 17%;
  height: 4%;
}
.k-up {
  left: calc(var(--w) * -0.024);
  top: 24.5%;
  height: 7.5%;
}
.k-down {
  left: calc(var(--w) * -0.024);
  top: 33.5%;
  height: 7.5%;
}
.k-power {
  right: calc(var(--w) * -0.024);
  top: 26%;
  height: 11%;
}
.iphone-screen {
  container-type: inline-size;
  position: relative;
  aspect-ratio: 402 / 874;
  overflow: hidden;
  border-radius: calc(var(--w) * 0.155);
  background: #fff;
}

/* Pantalla real del cliente (customer.css) */
.gu {
  --p: calc(100cqw / 402);
  --g-line: #e1e7e4;
  --g-soft: #5b6a65;
  --g-mute: #7d8b86;
  --g-up: #06683f;
  --g-down: #b3291b;
  --g-amber: #835300;
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  font-size: calc(var(--p) * 16);
  line-height: 1.4;
}
.ios-bar {
  height: calc(var(--p) * 54);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: calc(var(--p) * 6) calc(var(--p) * 32) 0 calc(var(--p) * 50);
  color: #000;
}
.ios-time {
  font-family: -apple-system, "SF Pro Text", system-ui, sans-serif;
  font-size: calc(var(--p) * 17);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.ios-icons {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--p) * 6);
}
.ios-icons svg {
  fill: currentColor;
  height: calc(var(--p) * 12);
}
.ios-signal {
  width: calc(var(--p) * 18);
}
.ios-wifi {
  width: calc(var(--p) * 16);
}
.ios-battery {
  width: calc(var(--p) * 27);
  height: calc(var(--p) * 13) !important;
}
.ios-island {
  position: absolute;
  top: calc(var(--p) * 11);
  left: 50%;
  width: calc(var(--p) * 125);
  height: calc(var(--p) * 37);
  transform: translateX(-50%);
  border-radius: calc(var(--p) * 20);
  background: #000;
}
.ios-home {
  position: absolute;
  left: 50%;
  bottom: calc(var(--p) * 8);
  width: calc(var(--p) * 140);
  height: calc(var(--p) * 5);
  transform: translateX(-50%);
  border-radius: calc(var(--p) * 3);
  background: #000;
  z-index: 3;
}
.gu-top {
  display: grid;
  padding: calc(var(--p) * 10) calc(var(--p) * 20) calc(var(--p) * 4);
}
.gu-top b {
  font-size: calc(var(--p) * 22);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.15;
}
.gu-top span {
  color: var(--g-soft);
  font-size: calc(var(--p) * 14);
  font-weight: 500;
}
.gu-bar,
.gu-notice {
  display: none;
}
.gu[data-market="crash"] .gu-bar {
  display: block;
  padding: calc(var(--p) * 10) calc(var(--p) * 20) 0;
}
.gu-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: calc(var(--p) * 13);
  color: var(--g-soft);
}
.gu-live {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--p) * 7);
  color: var(--g-amber);
  font-weight: 700;
}
.gu-live::before {
  content: "";
  width: calc(var(--p) * 7);
  height: calc(var(--p) * 7);
  border-radius: 50%;
  background: var(--amber);
}
.gu-track {
  height: calc(var(--p) * 2);
  margin: calc(var(--p) * 10) calc(var(--p) * -20) 0;
  background: var(--g-line);
}
.gu-track i {
  background: var(--amber);
}
.gu[data-market="crash"] .gu-notice {
  display: block;
  margin: calc(var(--p) * 12) calc(var(--p) * 20) 0;
  padding: calc(var(--p) * 12) calc(var(--p) * 14);
  border-radius: calc(var(--p) * 12);
  background: #fff4dc;
  color: var(--g-amber);
  font-size: calc(var(--p) * 15);
  font-weight: 700;
}
.gu-main {
  padding: 0 calc(var(--p) * 20);
}
.gu-spot {
  display: grid;
  padding-top: calc(var(--p) * 22);
}
.gu-spot[hidden] {
  display: none;
}
.gu-kicker {
  color: var(--g-down);
  font-size: calc(var(--p) * 13);
  font-weight: 700;
}
.gu-spot-name {
  margin-top: calc(var(--p) * 4);
  font-size: calc(var(--p) * 20);
  font-weight: 600;
  letter-spacing: -0.02em;
}
.gu-spot-quote {
  display: flex;
  align-items: baseline;
  gap: calc(var(--p) * 10);
  margin-top: calc(var(--p) * 2);
}
.gu-spot-quote b {
  color: var(--g-down);
  font-size: calc(var(--p) * 52);
  font-weight: 700;
  letter-spacing: -0.045em;
  line-height: 1;
}
.gu-spot-quote s {
  color: var(--g-soft);
  font-size: calc(var(--p) * 15);
  text-decoration-color: var(--g-mute);
}
.gu-buy {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: calc(var(--p) * 52);
  margin-top: calc(var(--p) * 18);
  padding: 0 calc(var(--p) * 20);
  border-radius: calc(var(--p) * 14);
  background: var(--ink);
  color: #fff;
  font-weight: 700;
}
.gu-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: calc(var(--p) * 30);
  padding-bottom: calc(var(--p) * 4);
}
.gu-head b {
  font-size: calc(var(--p) * 20);
  letter-spacing: -0.02em;
}
.gu-head span {
  color: var(--g-soft);
  font-size: calc(var(--p) * 13);
}
.gu-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: calc(var(--p) * 14);
  padding: calc(var(--p) * 14) 0;
  border-bottom: 1px solid var(--g-line);
}
.gu-name {
  display: grid;
  gap: calc(var(--p) * 2);
}
.gu-name b {
  font-weight: 600;
  line-height: 1.2;
}
.gu-name small {
  color: var(--g-soft);
  font-size: calc(var(--p) * 13);
}
.gu-quote {
  display: flex;
  align-items: baseline;
  gap: calc(var(--p) * 10);
}
.gu-px {
  font-size: calc(var(--p) * 22);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.gu-chg,
#g-spot-chg {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: calc(var(--p) * 5);
  min-width: 4.6em;
  font-size: calc(var(--p) * 13);
  font-style: normal;
  font-weight: 700;
}
#g-spot-chg {
  min-width: 0;
  font-size: calc(var(--p) * 16);
}
.gu-chg::before,
#g-spot-chg::before {
  content: "";
  width: calc(var(--p) * 8);
  height: calc(var(--p) * 7);
  background: currentColor;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}
.gu .is-up {
  color: var(--g-up);
}
.gu .is-down {
  color: var(--g-down);
}
.gu .is-flat {
  color: var(--g-soft);
}
.gu-px.is-flat {
  color: var(--ink);
}
.gu .is-down::before {
  transform: rotate(180deg);
}
.gu .is-flat::before {
  display: none;
}
.gu-cart {
  position: absolute;
  left: calc(var(--p) * 12);
  right: calc(var(--p) * 12);
  bottom: calc(var(--p) * 106);
  z-index: 2;
  display: flex;
  align-items: center;
  gap: calc(var(--p) * 12);
  padding: calc(var(--p) * 10) calc(var(--p) * 18) calc(var(--p) * 10)
    calc(var(--p) * 10);
  border-radius: calc(var(--p) * 16);
  background: var(--ink);
  color: #fff;
  box-shadow: 0 calc(var(--p) * 16) calc(var(--p) * 32) calc(var(--p) * -16)
    rgb(14 27 24 / 0.5);
}
.gu-count {
  display: grid;
  place-items: center;
  width: calc(var(--p) * 34);
  height: calc(var(--p) * 34);
  border-radius: calc(var(--p) * 10);
  background: rgb(255 255 255 / 0.14);
  font-weight: 700;
}
.gu-cart-text {
  flex: 1;
  font-weight: 700;
}
.gu-cart b {
  font-size: calc(var(--p) * 17);
}
.gu-nav {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  height: calc(var(--p) * 96);
  padding-bottom: calc(var(--p) * 34);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--g-line);
  background: #fff;
}
.gu-nav span {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: calc(var(--p) * 3);
  color: var(--g-soft);
  font-size: calc(var(--p) * 12);
  font-weight: 600;
}
.gu-nav .is-active {
  color: var(--ink);
}
.gu-nav svg {
  width: calc(var(--p) * 23);
  height: calc(var(--p) * 23);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.gu-nav .is-active svg {
  stroke-width: 2.3;
}

/* Un cambio de precio ilumina la fila y tiñe el precio un momento, como en
   la TV real (board.css). */
.tvq.hit-up {
  animation: tv-wash-up 2.6s ease-out;
}
.tvq.hit-down {
  animation: tv-wash-down 2.6s ease-out;
}
.tvq-price.hit-up {
  animation: tv-hit-up 2.6s ease-out;
}
.tvq-price.hit-down {
  animation: tv-hit-down 2.6s ease-out;
}
@keyframes tv-wash-up {
  from {
    background: linear-gradient(90deg, rgb(31 209 139 / 0.22), transparent);
  }
}
@keyframes tv-wash-down {
  from {
    background: linear-gradient(90deg, rgb(255 92 77 / 0.22), transparent);
  }
}
@keyframes tv-hit-up {
  from {
    color: var(--up);
  }
}
@keyframes tv-hit-down {
  from {
    color: var(--down);
  }
}

/* Ranking de la noche en la TV: lugar en mono, nombre en mayúsculas y la
   primera mesa en verde; nunca montos. */
.tvu-leaders {
  display: none;
  flex: 1;
  min-height: 0;
  flex-direction: column;
  justify-content: center;
  width: min(100%, calc(var(--r) * 72));
  margin-inline: auto;
}
.tvu[data-scene="leaders"] .tvu-quotes {
  display: none;
}
.tvu[data-scene="leaders"] .tvu-leaders {
  display: flex;
}
.tvu-lhead {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: calc(var(--r) * 3);
  padding-bottom: calc(var(--r) * 1.4);
  border-bottom: calc(var(--r) * 0.06) solid var(--tv-line);
}
.tvu-lhead b {
  font-size: calc(var(--r) * 3.3);
  letter-spacing: -0.03em;
  line-height: 1;
}
.tvu-lhead span {
  max-width: calc(var(--r) * 24);
  color: var(--tv-soft);
  font-size: calc(var(--r) * 1.2);
  text-align: right;
}
#tv-leaders {
  margin: 0;
  padding: 0;
  list-style: none;
}
#tv-leaders li {
  display: grid;
  grid-template-columns: calc(var(--r) * 7) minmax(0, 1fr);
  align-items: center;
  padding: calc(var(--r) * 1.1) 0;
  border-bottom: calc(var(--r) * 0.06) solid var(--tv-line);
  animation: tv-leader-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(var(--i, 0) * 0.12s + 0.1s);
}
#tv-leaders .pos {
  color: var(--tv-soft);
  font-family: var(--mono);
  font-size: calc(var(--r) * 2.6);
  font-weight: 600;
}
#tv-leaders .who {
  display: grid;
  gap: calc(var(--r) * 0.2);
  min-width: 0;
}
#tv-leaders .who b {
  overflow: hidden;
  font-size: calc(var(--r) * 2.6);
  letter-spacing: 0.02em;
  line-height: 1.05;
  text-overflow: ellipsis;
  text-transform: uppercase;
  white-space: nowrap;
}
#tv-leaders .who small {
  color: var(--tv-soft);
  font-size: calc(var(--r) * 1.2);
}
#tv-leaders .is-lead {
  padding: calc(var(--r) * 1.8) 0;
}
#tv-leaders .is-lead .pos {
  color: var(--up);
  font-size: calc(var(--r) * 4.2);
}
#tv-leaders .is-lead .who b {
  color: var(--up);
  font-size: calc(var(--r) * 4.6);
}
#tv-leaders .up-mark {
  margin-left: calc(var(--r) * 1.2);
  color: var(--up);
  font-family: var(--mono);
  font-size: 0.45em;
  font-style: normal;
  letter-spacing: 0;
  text-transform: none;
  vertical-align: middle;
}
#tv-leaders .climb .who b {
  animation: tv-climb 1.2s cubic-bezier(0.22, 1, 0.36, 1) 0.6s both;
}
@keyframes tv-leader-in {
  from {
    opacity: 0;
    transform: translateY(calc(var(--r) * 1.4));
  }
}
@keyframes tv-climb {
  from {
    color: var(--up);
  }
}

/* Momentos de la bolsa: la caída toma la pantalla con un destello ámbar y
   una gráfica que se desploma; al terminar, una que sube. */
.tvm {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: rgb(0 0 0 / 0.94);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.45s ease-in,
    visibility 0s linear 0.45s;
}
.tvm.on {
  opacity: 1;
  visibility: visible;
  transition: none;
}
.tvm-flash {
  position: absolute;
  inset: 0;
  background: var(--amber);
  opacity: 0;
}
.tvm.crash.on .tvm-flash {
  animation: tv-alarm 1s steps(1, end) 2;
}
.tvm-chart {
  position: absolute;
  inset: 18% 0 8%;
  width: 100%;
  height: 74%;
}
.tvm-chart polyline {
  fill: none;
  stroke: var(--up);
  stroke-width: 5;
  stroke-linejoin: round;
  stroke-linecap: round;
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  opacity: 0.55;
}
.tvm.on .tvm-chart polyline {
  animation: tv-draw 1.6s cubic-bezier(0.5, 0, 0.3, 1) 0.15s forwards;
}
.tvm.crash .tvm-chart polyline {
  stroke: var(--down);
  opacity: 0.8;
}
.tvm-text {
  position: relative;
  display: grid;
  justify-items: center;
  gap: calc(var(--r) * 1);
  padding: 0 calc(var(--r) * 4);
  text-align: center;
}
.tvm.on .tvm-text {
  animation: tv-slam 0.55s cubic-bezier(0.2, 0.9, 0.25, 1.2) both;
}
.tvm-text strong {
  color: #fff;
  font-size: calc(var(--r) * 8.4);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 0.95;
}
.tvm.crash .tvm-text strong {
  color: var(--amber);
}
.tvm-kicker {
  color: var(--down);
  font-size: calc(var(--r) * 5);
  line-height: 1;
}
.tvm-kicker:empty {
  display: none;
}
.tvm.crash.on .tvm-kicker {
  animation: tv-drop 0.9s cubic-bezier(0.5, 0, 0.75, 0) 0.2s 3 both;
}
.tvm-sub {
  color: var(--tv-soft);
  font-family: var(--mono);
  font-size: calc(var(--r) * 1.9);
}
.tvm.crash .tvm-sub {
  color: #fff;
}
.tv-screen.shake .tvu-board {
  animation: tv-shake 0.6s cubic-bezier(0.36, 0.07, 0.19, 0.97);
}
@keyframes tv-alarm {
  0% {
    opacity: 0.55;
  }
  35% {
    opacity: 0;
  }
}
@keyframes tv-draw {
  to {
    stroke-dashoffset: 0;
  }
}
@keyframes tv-slam {
  from {
    opacity: 0;
    transform: scale(1.18);
  }
}
@keyframes tv-drop {
  0% {
    opacity: 0;
    transform: translateY(calc(var(--r) * -1.5));
  }
  30% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translateY(calc(var(--r) * 2));
  }
}
@keyframes tv-shake {
  20%,
  60% {
    transform: translateX(calc(var(--r) * -0.5));
  }
  40%,
  80% {
    transform: translateX(calc(var(--r) * 0.5));
  }
}

/* Lo que muestra la TV, en orden. La raya del momento activo avanza con el
   tiempo que le queda; se puede tocar para verlo ya. */
.tv-moments {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(12px, 2.4vw, 32px);
  margin-top: clamp(24px, 3.6vw, 40px);
}
.tv-moments button {
  position: relative;
  display: grid;
  gap: 4px;
  align-content: start;
  min-height: 44px;
  padding: 16px 0 4px;
  border: 0;
  border-top: 2px solid var(--line);
  background: none;
  color: var(--soft);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: color 0.2s ease;
}
.tv-moments b {
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}
.tv-moments span {
  font-size: 0.95rem;
  line-height: 1.45;
}
.tv-moments-bar {
  position: absolute;
  top: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: left;
}
.tv-moments [aria-pressed="true"] {
  color: var(--ink);
}
.tv-moments [aria-pressed="true"] .tv-moments-bar {
  transform: scaleX(var(--k, 1));
  transition: transform 1s linear;
}
.tv-moments [data-scene="crash"][aria-pressed="true"] .tv-moments-bar {
  background: var(--amber);
}
@media (hover: hover) and (pointer: fine) {
  .tv-moments button:hover {
    color: var(--ink);
  }
}
.tv-moments button:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 4px;
}

/* El celular del cliente. Fijo en pantalla mientras se baja: cada paso
   cambia lo que muestra el iPhone. Sin fijar, se elige con los botones. */
.mesa {
  padding-top: clamp(24px, 4vw, 48px);
}
.mesa-head {
  display: grid;
  gap: 20px;
}
.mesa-head h2,
.mesa-head p {
  max-width: 760px;
}
.mesa-head p {
  color: var(--soft);
  max-width: 56ch;
}
.mesa-stage {
  padding: clamp(36px, 5vw, 64px) 0 clamp(72px, 10vw, 128px);
}
.mesa-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  grid-template-areas:
    "rail phone"
    "steps phone";
  grid-template-rows: auto 1fr;
  gap: 24px clamp(32px, 6vw, 88px);
  align-items: start;
}
.mesa-steps {
  grid-area: steps;
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.mesa-steps li {
  display: grid;
  gap: 8px;
  padding: 18px 0 14px;
  border-top: 2px solid var(--line);
  color: var(--soft);
  transition:
    border-color 0.2s ease,
    color 0.2s ease;
}
.mesa-steps li.is-active {
  border-top-color: var(--ink);
  color: var(--ink);
}
/* La línea de las pestañas ya separa el primer paso. */
.mesa-steps li:first-child {
  border-top: 0;
  padding-top: 0;
}
.mesa-steps h3 {
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}
.mesa-steps p {
  max-width: 44ch;
  color: var(--soft);
}
.mesa .rail {
  grid-area: rail;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(8px, 1.4vw, 16px);
}
.mesa .iphone {
  grid-area: phone;
  justify-self: center;
  --w: clamp(240px, 24vw, 300px);
}

/* Fijo: un paso a la vez junto al iPhone. */
.mesa.is-pinned .mesa-track {
  height: 400vh;
}
.mesa.is-pinned .mesa-stage {
  position: sticky;
  top: var(--nav-h);
  height: calc(100vh - var(--nav-h));
  height: calc(100svh - var(--nav-h));
  display: grid;
  align-items: center;
  padding: 12px 0 20px;
}
.mesa.is-pinned .mesa-grid {
  grid-template-rows: auto auto;
  align-content: center;
  align-items: center;
}
.mesa.is-pinned .mesa-steps {
  align-self: start;
  min-height: 12em;
}
.mesa.is-pinned .mesa-steps li {
  grid-area: 1 / 1;
  align-content: start;
  border-top: 0;
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity 0.4s,
    transform 0.4s var(--ease-out),
    border-color 0.2s ease;
}
.mesa.is-pinned .mesa-steps li.is-active {
  opacity: 1;
  transform: none;
}
.mesa.is-pinned .mesa-steps h3 {
  font-size: clamp(1.4rem, 2.4vw, 1.875rem);
}
.mesa.is-pinned .mesa-steps p {
  font-size: 1.0625rem;
}
.mesa.is-pinned .rail {
  align-self: end;
}
.mesa.is-pinned .iphone {
  --w: min(300px, calc((100svh - var(--nav-h) - 72px) / 2.1));
}

/* Pantallas del iPhone: Mercado, Tu orden (hoja), Cuenta y el top. */
/* Cada vista ocupa lo que queda debajo del nombre del bar; lo que baja
   se recorta ahí, como al hacer scroll en el celular real. */
.gu-view {
  display: none;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}
.gu[data-screen="0"] .gu-market,
.gu[data-screen="1"] .gu-market,
.gu[data-screen="3"] .gu-market,
.gu[data-screen="2"] .gu-account {
  display: block;
  animation: gu-in 0.35s var(--ease-out);
}
@keyframes gu-in {
  from {
    opacity: 0;
  }
}
.gu-main {
  transition: transform 0.7s var(--ease-out);
}
.gu-top-head {
  margin-top: calc(var(--p) * 36);
}
.gu-rank {
  margin: 0;
  padding: 0 0 calc(var(--p) * 200);
  list-style: none;
}
.gu-rank li {
  display: grid;
  grid-template-columns: calc(var(--p) * 36) minmax(0, 1fr) auto;
  align-items: center;
  gap: calc(var(--p) * 12);
  padding: calc(var(--p) * 12) 0;
  border-bottom: 1px solid var(--g-line);
}
.gu-rank li.mine {
  margin: 0 calc(var(--p) * -12);
  padding: calc(var(--p) * 12);
  border-radius: calc(var(--p) * 12);
  border-bottom-color: transparent;
  background: #e3f7ed;
}
.gu-rank .pos {
  color: var(--g-soft);
  font-size: calc(var(--p) * 18);
  font-weight: 700;
  text-align: center;
}
.gu-rank li:first-child .pos {
  color: var(--g-up);
}
.gu-rank .who {
  display: grid;
  gap: calc(var(--p) * 2);
  min-width: 0;
}
.gu-rank .who b {
  font-weight: 600;
  line-height: 1.2;
}
.gu-rank .who small {
  color: var(--g-soft);
  font-size: calc(var(--p) * 13);
}
.gu-rank .tag {
  color: var(--g-up);
  font-size: calc(var(--p) * 13);
  font-weight: 700;
}
.gu[data-screen="2"] .gu-cart,
.gu[data-screen="3"] .gu-cart {
  display: none;
}

/* Tu orden: la hoja sube sobre el Mercado, que se oscurece. */
.gu::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  background: rgb(14 27 24 / 0.38);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.gu[data-screen="1"]::before {
  opacity: 1;
}
.gu-sheet {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 4;
  display: grid;
  padding: calc(var(--p) * 10) calc(var(--p) * 20) calc(var(--p) * 40);
  border-radius: calc(var(--p) * 26) calc(var(--p) * 26) 0 0;
  background: #fff;
  transform: translateY(105%);
  transition: transform 0.55s var(--ease-out);
}
.gu[data-screen="1"] .gu-sheet {
  transform: none;
}
.gu-grip {
  justify-self: center;
  width: calc(var(--p) * 40);
  height: calc(var(--p) * 5);
  margin-bottom: calc(var(--p) * 14);
  border-radius: calc(var(--p) * 3);
  background: var(--g-line);
}
.gu-sheet-title {
  margin-bottom: calc(var(--p) * 8);
  font-size: calc(var(--p) * 22);
  letter-spacing: -0.02em;
}
.gu-line-item,
.gu-total,
.gu-lock-line,
.gu-order-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: calc(var(--p) * 12);
}
.gu-line-item {
  padding: calc(var(--p) * 12) 0;
  border-bottom: 1px solid var(--g-line);
}
.gu-total {
  padding-top: calc(var(--p) * 14);
  font-weight: 700;
}
.gu-total b {
  font-size: calc(var(--p) * 28);
  letter-spacing: -0.03em;
}
.gu-lock {
  margin-top: calc(var(--p) * 12);
  padding: calc(var(--p) * 12) calc(var(--p) * 14);
  border-radius: calc(var(--p) * 12);
  background: #e3f7ed;
  color: var(--g-up);
  font-size: calc(var(--p) * 14);
  font-weight: 700;
}
.gu-lock-track {
  height: calc(var(--p) * 4);
  margin-top: calc(var(--p) * 8);
  border-radius: calc(var(--p) * 2);
  background: rgb(6 104 63 / 0.18);
  overflow: hidden;
}
.gu-lock-track i {
  display: block;
  height: 100%;
  background: var(--g-up);
  transform-origin: left;
  transition: transform 1s linear;
}
.gu-confirm {
  margin-top: calc(var(--p) * 14);
}

/* Cuenta: lo gastado, el nombre de la mesa y cada orden con su estado. */
.gu-account {
  padding: calc(var(--p) * 18) calc(var(--p) * 20) 0;
}
.gu-bill-label {
  display: block;
  color: var(--g-soft);
  font-size: calc(var(--p) * 14);
  font-weight: 600;
}
.gu-bill {
  display: block;
  font-size: calc(var(--p) * 44);
  letter-spacing: -0.045em;
  line-height: 1.1;
}
.gu-bill-note {
  margin: calc(var(--p) * 6) 0 0;
  color: var(--g-soft);
  font-size: calc(var(--p) * 14);
}
.gu-name-box {
  display: grid;
  gap: calc(var(--p) * 2);
  margin-top: calc(var(--p) * 16);
  padding: calc(var(--p) * 14) 0;
  border-top: 1px solid var(--g-line);
  border-bottom: 1px solid var(--g-line);
}
.gu-name-box span {
  color: var(--g-soft);
  font-size: calc(var(--p) * 13);
  font-weight: 600;
}
.gu-name-box b {
  font-size: calc(var(--p) * 20);
  letter-spacing: -0.02em;
}
.gu-name-box small {
  color: var(--g-up);
  font-size: calc(var(--p) * 14);
  font-weight: 700;
}
.gu-orders-head {
  display: block;
  margin: calc(var(--p) * 18) 0 calc(var(--p) * 4);
  font-size: calc(var(--p) * 20);
  letter-spacing: -0.02em;
}
.gu-order {
  display: grid;
  gap: calc(var(--p) * 8);
  margin-top: calc(var(--p) * 10);
  padding: calc(var(--p) * 14);
  border: 1px solid var(--g-line);
  border-radius: calc(var(--p) * 14);
}
.gu-order-top b {
  font-weight: 600;
}
.gu-order-top span {
  font-weight: 700;
}
.gu-steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--p) * 4);
}
.gu-steps i {
  height: calc(var(--p) * 4);
  border-radius: calc(var(--p) * 2);
  background: var(--g-line);
  transition: background-color 0.3s ease;
}
.gu-steps i.on {
  background: var(--ink);
}
.gu-order.is-done .gu-steps i {
  background: var(--g-up);
}
.gu-order small {
  color: var(--g-soft);
  font-size: calc(var(--p) * 13);
  font-weight: 600;
}
.gu-order.is-done small {
  color: var(--g-up);
}

@media (max-width: 760px) {
  .tv-moments span {
    display: none;
  }
  .tv-moments b {
    font-size: 0.95rem;
  }
  .mesa-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "phone"
      "rail"
      "steps";
    grid-template-rows: auto;
  }
  .mesa .iphone {
    --w: min(64vw, 260px);
  }
  .mesa.is-pinned .mesa-grid {
    grid-template-areas:
      "phone"
      "rail"
      "steps";
    gap: 6px;
  }
  .mesa.is-pinned .iphone {
    --w: min(62vw, calc((100svh - var(--nav-h) - 280px) / 2.1));
  }
  .mesa.is-pinned .mesa-steps {
    align-self: start;
    min-height: 0;
    height: 9.6em;
  }
  .mesa.is-pinned .mesa-steps li {
    gap: 4px;
    padding-top: 12px;
  }
  .mesa.is-pinned .mesa-steps h3 {
    font-size: 1.15rem;
  }
  .mesa.is-pinned .mesa-steps p {
    font-size: 0.9375rem;
    line-height: 1.45;
  }
}
@media (prefers-reduced-motion: reduce) {
  .tvq,
  .tvq-price,
  #tv-leaders li,
  #tv-leaders .climb .who b,
  .tvm,
  .tvm *,
  .tv-screen.shake .tvu-board,
  .gu-view,
  .gu-sheet,
  .gu-main,
  .gu::before {
    animation: none !important;
    transition: none !important;
  }
  .tvm-chart polyline {
    stroke-dashoffset: 0;
  }
}

/* Todo en uno */
.caps {
  list-style: none;
  padding: 0;
  margin: 8px 0 0;
  display: grid;
  gap: 16px;
}
.caps li {
  display: flex;
  gap: 12px;
  align-items: baseline;
  line-height: 1.45;
  color: var(--soft);
  max-width: 52ch;
}
.caps b {
  color: var(--ink);
  font-weight: 650;
}
.caps li::before {
  content: "";
  flex: none;
  width: 8px;
  height: 8px;
  margin-top: 0.4em;
  border-radius: 2px;
  background: var(--up);
}
.ticket {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(20px, 3vw, 32px);
  display: grid;
  gap: 18px;
  max-width: 520px;
  justify-self: center;
  width: 100%;
  box-shadow: 0 24px 48px -28px rgb(14 27 24 / 0.3);
}
.ticket-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-bottom: 16px;
  border-bottom: 1px dashed var(--line);
}
.ticket-head b {
  font-size: 1.3rem;
  letter-spacing: -0.02em;
}
.ticket-head span {
  color: var(--soft);
  font-size: 0.9rem;
}
.ticket-lines {
  display: grid;
  gap: 12px;
}
.ticket-line {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.ticket-line > span:last-child {
  font-family: var(--mono);
  font-weight: 500;
}
.ticket-item {
  display: grid;
}
.ticket-item b {
  font-weight: 600;
}
.ticket-item small {
  color: var(--soft);
  font-size: 0.8125rem;
}
.ticket-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding-top: 16px;
  border-top: 1px dashed var(--line);
  font-size: 1.1rem;
}
.ticket-total b {
  font-family: var(--mono);
  font-size: 1.8rem;
  letter-spacing: -0.04em;
}
.ticket-note {
  color: var(--soft);
  font-size: 0.875rem;
}

/* Planes: tres tarjetas cuyas filas (encabezado, precio, botón y lista)
   se alinean entre sí con subgrid, como en las páginas de precios de
   referencia. Las palomitas van en tinta: el verde significa «sube». */
.plans {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 16px;
}
.plan {
  grid-row: span 4;
  display: grid;
  grid-template-rows: subgrid;
  row-gap: 24px;
  align-content: start;
  padding: clamp(24px, 2.6vw, 32px);
  background: var(--panel);
  border-radius: var(--radius);
  box-shadow:
    0 0 0 1px rgb(14 27 24 / 0.08),
    0 1px 2px rgb(14 27 24 / 0.04),
    0 12px 32px -20px rgb(14 27 24 / 0.18);
}
.plan-head {
  display: grid;
  gap: 4px;
}
.plan-head h3 {
  font-size: 1.6rem;
  font-weight: 750;
  letter-spacing: -0.03em;
}
.plan-head p {
  color: var(--soft);
}
.plan-price {
  display: grid;
  gap: 6px;
  align-content: start;
}
.plan-amount {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 8px;
}
.plan-amount b {
  font-size: clamp(2.5rem, 4vw, 3.25rem);
  font-weight: 750;
  letter-spacing: -0.045em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.plan-amount span {
  color: var(--soft);
  font-weight: 550;
}
.plan-amount.is-custom b {
  font-size: clamp(2rem, 3.2vw, 2.5rem);
}
.plan-total {
  color: var(--soft);
  font-size: 0.95rem;
  font-variant-numeric: tabular-nums;
}
.stepper {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  margin-top: 10px;
  border-radius: 12px;
  box-shadow: inset 0 0 0 1px var(--line);
}
.stepper button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    transform 0.16s var(--ease-out);
}
.stepper button:active:not([aria-disabled="true"]) {
  transform: scale(0.94);
}
.stepper button[aria-disabled="true"] {
  color: var(--line);
  cursor: not-allowed;
}
.stepper svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}
.stepper output {
  min-width: 9.5ch;
  text-align: center;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
@media (hover: hover) and (pointer: fine) {
  .stepper button:hover:not([aria-disabled="true"]) {
    background: var(--tint);
  }
}
.plan-cta .btn {
  width: 100%;
}
.plan-features {
  display: grid;
  gap: 14px;
  align-content: start;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}
.plan-lead {
  font-weight: 650;
}
.checks {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.checks li {
  position: relative;
  padding-left: 28px;
  font-size: 0.975rem;
  line-height: 1.45;
}
.checks li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.28em;
  width: 6px;
  height: 11px;
  border: solid var(--ink);
  border-width: 0 1.75px 1.75px 0;
  transform: rotate(45deg);
}
.plans-notes {
  display: grid;
  gap: 6px;
  margin-top: 28px;
  color: var(--soft);
  font-size: 0.9rem;
  max-width: 78ch;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Preguntas */
.faq-wrap {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: start;
}
.faq {
  border-top: 1px solid var(--line);
}
.faq details {
  border-bottom: 1px solid var(--line);
}
.faq summary {
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 22px 0;
  font-size: 1.15rem;
  font-weight: 650;
  letter-spacing: -0.015em;
  cursor: pointer;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: "";
  flex: none;
  width: 14px;
  height: 14px;
  background:
    linear-gradient(var(--ink), var(--ink)) center / 100% 2px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center / 2px 100% no-repeat;
  transition: background-size 0.25s var(--ease-out);
}
.faq details[open] summary::after {
  background-size:
    100% 2px,
    2px 0%;
}
/* La respuesta se despliega con su altura real (Chrome y Edge); en otros
   navegadores se abre al instante. */
.faq {
  interpolate-size: allow-keywords;
}
.faq details::details-content {
  block-size: 0;
  overflow: clip;
  transition:
    block-size 0.3s var(--ease-out),
    content-visibility 0.3s allow-discrete;
}
.faq details[open]::details-content {
  block-size: auto;
}
.faq details p {
  padding: 0 40px 24px 0;
  color: var(--soft);
  max-width: 60ch;
}

/* Cierre y pie */
.closing {
  background: var(--board);
  color: #fff;
  padding: clamp(72px, 10vw, 128px) 0;
}
.closing-inner {
  display: grid;
  gap: 20px;
  justify-items: start;
}
.closing h2 {
  font-size: clamp(2rem, 1rem + 3.5vw, 4rem);
  font-weight: 800;
  letter-spacing: -0.045em;
  line-height: 0.95;
}
.closing p {
  color: var(--board-soft);
  font-size: clamp(1rem, 0.875rem + 0.4vw, 1.1875rem);
}
.closing .btn {
  margin-top: 12px;
}
.closing :focus-visible {
  outline-color: var(--amber);
}
.footer {
  background: var(--board);
  color: var(--board-soft);
  font-size: 0.9rem;
  border-top: 1px solid var(--board-line);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 32px;
  padding: 28px 0;
}
.footer-note {
  flex: 1;
}
.footer a {
  color: #fff;
  margin-left: 20px;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
}
.footer :focus-visible {
  outline-color: var(--amber);
}

/* Adaptación */
@media (max-width: 960px) {
  .hero-head,
  .split,
  .split-reverse,
  .night-head,
  .rules-wrap,
  .faq-wrap {
    grid-template-columns: minmax(0, 1fr);
  }
  .split-reverse .split-copy {
    order: 0;
  }
  .stage {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    padding-bottom: 0;
  }
  .tv {
    width: 100%;
  }
  .tv-stand {
    display: none;
  }
  .plans {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .night-steps {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .why {
    grid-template-columns: minmax(0, 1fr);
  }
  .start {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .plan {
    grid-row: auto;
    grid-template-rows: none;
  }
}
/* Tableta: la tarjeta a todo el ancho pone precio y botón a la izquierda
   y lo que incluye a la derecha, en vez de un botón de 700 px. */
@media (min-width: 640px) and (max-width: 960px) {
  .plan {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
    grid-template-rows: auto auto auto 1fr;
    column-gap: 40px;
  }
  .plan-head,
  .plan-price,
  .plan-cta {
    grid-column: 1;
  }
  .plan-features {
    grid-column: 2;
    grid-row: 1 / span 4;
    padding: 0 0 0 40px;
    border-top: 0;
    border-left: 1px solid var(--line);
  }
}
@media (max-width: 560px) {
  .start {
    grid-template-columns: minmax(0, 1fr);
  }
  .night-steps {
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
  }
  .night-steps li {
    grid-template-columns: 4.5rem minmax(0, 1fr);
    column-gap: 12px;
    padding: 16px 0;
  }
  .night-steps time {
    grid-row: span 2;
    padding-top: 3px;
  }
  .rules > div {
    grid-template-columns: minmax(0, 1fr);
  }
  .proof {
    padding: 20px;
    font-size: 1.0625rem;
  }
  .nav-inner {
    gap: 12px;
  }
  .nav-actions {
    gap: 12px;
  }
  .nav-actions .js-demo {
    padding: 0 14px;
    font-size: 0.9375rem;
  }
  .caps {
    grid-template-columns: minmax(0, 1fr);
  }
  .hero-foot {
    flex-direction: column;
    align-items: flex-start;
  }
  .btn {
    width: 100%;
  }
  .nav-actions .btn,
  .hero-foot .btn {
    width: auto;
  }
}

@media (pointer: coarse) {
  .btn-pause,
  .nav-actions .btn,
  .footer a,
  .link-quiet,
  .brand {
    min-height: 44px;
  }
  .link-quiet {
    display: inline-flex;
    align-items: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .tvu-run {
    animation: none;
  }
  .tvu-tick i,
  .gu-track i,
  .tvu-bar,
  .tvu-board {
    transition: none;
  }
  .btn:active:not(:disabled) {
    transform: none;
  }
  .btn,
  .n-line,
  .n-dot,
  .nav::before,
  .faq details::details-content,
  .faq summary::after {
    transition: none;
  }
}

/* ---------- Celular: una idea por pantalla ----------
   En pantallas angostas la página no apila todo: las listas se vuelven
   capítulos que avanzan con el scroll (landing.js, «Capítulos»), la noche
   se queda fija como en computadora y los planes se deslizan de lado. */
.ch-bar,
.plan-pick {
  display: none;
}

/* La noche fija en pantallas sin espacio para dos columnas. */
@media (max-width: 959px) {
  .night.is-pinned .night-track {
    height: 420svh;
  }
  .night.is-pinned .night-stage {
    height: calc(100svh - var(--nav-h));
    padding: 0;
  }
  .night.is-pinned .night-grid {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "head"
      "chart"
      "rail"
      "steps";
    gap: 16px;
  }
  .night.is-pinned .night-head h2 {
    font-size: clamp(1.5rem, 1rem + 2vw, 2.25rem);
  }
  .night.is-pinned .night-head p,
  .night.is-pinned .night-chart figcaption {
    display: none;
  }
  .night.is-pinned .night-chart {
    gap: 4px;
    padding: 14px 14px 10px;
    border-radius: 20px;
  }
  .night.is-pinned .readout b {
    font-size: 2rem;
  }
  .night.is-pinned .readout span {
    font-size: 0.875rem;
  }
  .night.is-pinned .rail {
    gap: 8px;
  }
  .night.is-pinned .rail button {
    min-height: 40px;
    font-size: 0.8125rem;
  }
  .night.is-pinned .night-steps {
    min-height: 0;
    height: 8.4em;
  }
  .night.is-pinned .night-steps li {
    grid-template-columns: minmax(0, 1fr);
    gap: 6px;
    padding: 0;
  }
  .night.is-pinned .night-steps time {
    display: none;
  }
  .night.is-pinned .night-steps h3 {
    font-size: 1.25rem;
  }
  .night.is-pinned .night-steps p {
    font-size: 0.975rem;
    line-height: 1.45;
  }
}

@media (max-width: 760px) {
  /* Capítulos: el título se queda y cada punto toma la pantalla. */
  .is-chaptered {
    padding: 0;
    height: calc(100svh - var(--nav-h) + var(--n) * 45svh);
  }
  .is-chaptered > .wrap {
    position: sticky;
    top: var(--nav-h);
    min-height: calc(100svh - var(--nav-h));
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    gap: 24px;
    padding-block: 28px;
  }
  .is-chaptered .split-copy {
    gap: 16px;
  }
  .is-chaptered .why-title {
    margin: 0;
  }
  .is-chaptered .ch-bar {
    display: flex;
    gap: 6px;
  }
  .ch-bar i {
    position: relative;
    flex: 1;
    height: 3px;
    border-radius: 2px;
    overflow: hidden;
    background: var(--line);
  }
  .ch-bar i::after {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--ink);
    transform: scaleX(var(--k, 0));
    transform-origin: left;
  }
  .tinted .ch-bar i {
    background: #cfd8d4;
  }
  .is-chaptered [data-chapter-list] {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 0;
    margin: 0;
    border: 0;
  }
  .is-chaptered [data-chapter-list] > * {
    grid-area: 1 / 1;
    padding: 0;
    border: 0;
    opacity: 0;
    transform: translateY(16px);
    pointer-events: none;
    transition:
      opacity 0.35s ease,
      transform 0.45s var(--ease-out);
  }
  .is-chaptered [data-chapter-list] > .is-on {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
  .is-chaptered .why h3,
  .is-chaptered .start h3,
  .is-chaptered .rules dt {
    font-size: 2rem;
    line-height: 1.1;
    letter-spacing: -0.03em;
  }
  .is-chaptered .why p,
  .is-chaptered .start p,
  .is-chaptered .rules dd,
  .is-chaptered .caps li {
    font-size: 1.125rem;
    line-height: 1.5;
  }
  .is-chaptered .why > div,
  .is-chaptered .start li,
  .is-chaptered .rules > div {
    gap: 12px;
  }
  .is-chaptered .rules > div {
    grid-template-columns: minmax(0, 1fr);
  }
  .is-chaptered .caps b {
    display: block;
    margin-bottom: 6px;
    font-size: 1.5rem;
    line-height: 1.15;
    letter-spacing: -0.025em;
  }
  .is-chaptered .caps li::before {
    display: none;
  }
  .is-chaptered .proof {
    margin: 0;
  }
  /* Todo en uno: la cuenta queda como imagen, sin el texto de la sección. */
  #todo-en-uno.is-chaptered .split-copy > p {
    display: none;
  }
  .is-chaptered .ticket {
    gap: 12px;
    padding: 18px 20px;
  }
  .is-chaptered .ticket-note {
    display: none;
  }

  /* La TV de la portada sigue siendo una TV (CEO, 2026-11-21): horizontal,
     con su base. */
  .tv-stand {
    display: block;
    margin-top: 12px;
    height: 8px;
  }
  .tv-stand::before {
    height: 12px;
  }

  /* Planes: uno a la vez, se deslizan de lado o se eligen arriba. */
  .plan-pick {
    --tab-soft: var(--soft);
    --tab-line: var(--line);
    --tab-on: var(--ink);
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
  }
  .plan-pick button {
    flex: 1;
  }
  .plan-pick button[aria-pressed="true"] {
    color: var(--tab-on);
  }
  .plan-pick button[aria-pressed="true"]::after {
    transform: scaleX(1);
    transition: transform 0.3s var(--ease-out);
  }
  .plans {
    display: flex;
    gap: 12px;
    align-items: start;
    margin-inline: -16px;
    padding: 4px 16px 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 16px;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  .plans::-webkit-scrollbar {
    display: none;
  }
  .plan {
    flex: 0 0 88%;
    scroll-snap-align: center;
  }
}

/* Cambio de paso sin texto encimado: el que sale se apaga rápido y el que
   entra aparece después. Vale para la noche, el celular y los capítulos. */
.night.is-pinned .night-steps li,
.mesa.is-pinned .mesa-steps li,
.is-chaptered [data-chapter-list] > * {
  transition:
    opacity 0.12s ease,
    transform 0s linear 0.12s;
}
.night.is-pinned .night-steps li.is-active,
.mesa.is-pinned .mesa-steps li.is-active,
.is-chaptered [data-chapter-list] > .is-on {
  transition:
    opacity 0.35s ease 0.1s,
    transform 0.45s var(--ease-out) 0.1s;
}

/* Escala del celular (CEO 2026-11-21: «hay cosas sobredimensionadas»).
   Proporciones medidas en anthropic.com a 390 px: titular ~25 px, títulos
   20–25 px, texto 14–16 px, margen 32 px. Pistock conserva un titular de
   marca algo mayor, pero nada pasa de 34 px y el texto corrido va a 15 px. */
@media (max-width: 760px) {
  :root {
    --nav-h: 56px;
  }
  body {
    font-size: 0.9375rem;
  }
  .wrap,
  .nav-inner {
    width: calc(100% - 40px);
  }
  h1 {
    font-size: 2.125rem;
    line-height: 1.02;
    letter-spacing: -0.035em;
  }
  h2,
  .night.is-pinned .night-head h2 {
    font-size: 1.5rem;
    line-height: 1.15;
    letter-spacing: -0.025em;
  }
  h3 {
    font-size: 1.0625rem;
  }
  .lead,
  .closing p {
    font-size: 1rem;
  }
  .split-copy > p,
  .night-head p,
  .mesa-head p,
  .proof,
  .faq summary {
    font-size: 0.9375rem;
  }
  .brand {
    font-size: 1.375rem;
  }
  .btn {
    min-height: 44px;
    font-size: 0.9375rem;
  }
  .nav-actions .btn,
  .nav-actions .js-demo {
    min-height: 36px;
    padding: 0 14px;
    font-size: 0.875rem;
  }
  .btn-pause {
    min-height: 36px;
    font-size: 0.875rem;
  }
  .section,
  .closing {
    padding: 56px 0;
  }
  .hero {
    padding: 20px 0 48px;
  }
  .hero-head {
    margin-bottom: 24px;
  }
  .closing h2 {
    font-size: 2rem;
    line-height: 1.05;
  }
  .tv-moments button {
    min-height: 0;
    padding-top: 10px;
  }
  .tv-moments b {
    font-size: 0.8125rem;
  }
  .tv-moments span {
    font-size: 0.8125rem;
  }
  .night.is-pinned .readout b {
    font-size: 1.625rem;
  }
  .night.is-pinned .night-steps h3,
  .mesa.is-pinned .mesa-steps h3,
  .why h3,
  .start h3,
  .is-chaptered .why h3,
  .is-chaptered .start h3,
  .is-chaptered .rules dt {
    font-size: 1.25rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
  }
  .night.is-pinned .night-steps p,
  .mesa.is-pinned .mesa-steps p,
  .is-chaptered .why p,
  .is-chaptered .start p,
  .is-chaptered .rules dd,
  .is-chaptered .caps li {
    font-size: 0.9375rem;
  }
  .is-chaptered .caps b {
    font-size: 1.25rem;
  }
  .plan-head h3 {
    font-size: 1.25rem;
  }
  .plan-amount b {
    font-size: 2rem;
  }
  .plan-amount.is-custom b {
    font-size: 1.625rem;
  }
  .ticket-total b {
    font-size: 1.5rem;
  }
  .plans {
    margin-inline: -20px;
    padding-inline: 20px;
    scroll-padding-inline: 20px;
  }
  /* Con letra más chica, centrado dejaba media pantalla vacía arriba: el
     capítulo empieza en el tercio superior, a la altura de la noche. */
  .is-chaptered > .wrap {
    justify-content: flex-start;
    padding-top: clamp(40px, 11svh, 104px);
  }
}
@media (max-width: 760px) and (pointer: coarse) {
  .nav-actions .btn,
  .btn-pause {
    min-height: 40px;
  }
}

/* En pantallas táctiles, la zona que responde al dedo mide al menos 44 px
   aunque el botón se vea más chico (el encabezado, la pausa y los momentos
   de la noche se ven compactos en celular a propósito). */
@media (pointer: coarse) {
  .nav-actions .btn,
  .btn-pause,
  .night.is-pinned .rail button {
    position: relative;
  }
  .nav-actions .btn::before,
  .btn-pause::before,
  .night.is-pinned .rail button::before {
    content: "";
    position: absolute;
    z-index: 1;
    inset: -4px -2px;
  }
}

/* Planes compactos (CEO 2026-11-21: que quepan en pantalla con todas las
   funciones dentro). Escala más chica y ritmo de 8 px: nombre 20 px,
   precio 40 px, texto 14 px; One lleva sus funciones en dos columnas con
   nombres cortos. Objetivo: tarjeta de ~460 px, entera en una laptop. */
.plan {
  row-gap: 16px;
  padding: 24px;
}
.plan-head h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.plan-head p {
  font-size: 0.875rem;
}
.plan-price {
  gap: 4px;
}
.plan-amount b {
  font-size: 2.5rem;
}
.plan-amount.is-custom b {
  font-size: 2rem;
  line-height: 1.25;
}
.plan-amount span {
  font-size: 0.875rem;
}
.plan-total {
  font-size: 0.8125rem;
}
.stepper {
  margin-top: 8px;
  border-radius: 10px;
}
.stepper button {
  width: 36px;
  height: 36px;
  border-radius: 10px;
}
.stepper output {
  font-size: 0.875rem;
}
.plan-cta .btn {
  min-height: 40px;
  font-size: 0.875rem;
}
.plan-features {
  gap: 12px;
  padding-top: 16px;
}
.plan-lead {
  font-size: 0.875rem;
}
.plan .checks {
  gap: 8px;
}
.plan .checks li {
  padding-left: 22px;
  font-size: 0.875rem;
  line-height: 1.35;
}
.plan .checks li::before {
  left: 3px;
  top: 0.2em;
  width: 5px;
  height: 10px;
}
.plan .checks.is-two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 16px;
}
.plans-notes {
  margin-top: 32px;
  font-size: 0.8125rem;
}
/* En el carrusel del celular, todas a la altura de la más alta: el espacio
   sobrante queda dentro de la tarjeta y no como hueco debajo. */
@media (max-width: 560px) {
  .plans {
    align-items: stretch;
  }
  .plan .checks.is-two {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (pointer: coarse) {
  .stepper button {
    width: 44px;
    height: 44px;
  }
  .plan-cta .btn {
    min-height: 44px;
  }
}

/* Un solo plan (CEO 2026-11-21): todos incluyen todo y solo cambia cuántas
   sucursales. Una tarjeta, sin carrusel ni selector de planes: a la
   izquierda precio, sucursales y botón; a la derecha todo lo que incluye.
   En celular, una columna. */
.plans.is-solo {
  display: block;
  max-width: 960px;
  margin: 0;
  padding: 0;
  overflow: visible;
}
.plan.is-solo {
  grid-row: auto;
  grid-template-rows: none;
  grid-template-columns: minmax(0, 1fr);
  row-gap: 20px;
}
.plan-count {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  font-weight: 550;
}
.plan-count .stepper {
  margin-top: 0;
}
.plan.is-solo .stepper output {
  min-width: 4ch;
}
.plan.is-solo .plan-cta {
  display: grid;
  gap: 12px;
  align-content: start;
}
.plan-rule {
  color: var(--soft);
  font-size: 0.8125rem;
  line-height: 1.45;
}
@media (min-width: 640px) {
  .plan.is-solo {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    grid-template-rows: auto auto 1fr;
    column-gap: 40px;
    padding: 32px;
  }
  .plan.is-solo .plan-head,
  .plan.is-solo .plan-price,
  .plan.is-solo .plan-cta {
    grid-column: 1;
  }
  .plan.is-solo .plan-features {
    grid-column: 2;
    grid-row: 1 / span 3;
    padding: 0 0 0 40px;
    border-top: 0;
    border-left: 1px solid var(--line);
  }
}
