/* Esquina (modo expresivo). Diales ENERGY 3 / RHYTHM 3 / MOTION 3.
   Decisiones (una línea por recurso):
   - Verde botella de fondo: el color del plano impreso de barrio y de los toldos de las tiendas; claramente verde, no casi negro.
   - Amarillo señal como acento: es el local del cliente en el plano, la gente que llega a él, la última semana del caso y el CTA. Nada más.
   - Una familia (Archivo) con eje de ancho: expandida y pesada en titulares (letrero de local), normal para leer.
   - El objeto vivo es el plano del barrio (barrio.js): negocios = cuadrados, personas que piden la ruta = puntos. Son datos, no adornos; la leyenda lo dice.
   - El círculo del plano es el radio real de la pauta (2 km), con su etiqueta. La única otra forma redonda es la muestra de "persona" en la leyenda, que explica los puntos del plano.
   - El reporte del lunes es UI del entregable con datos del caso; sus sparklines son 13 semanas de cada métrica y las etiquetas nombran filas reales.
   - La hoja del reporte es papel claro sobre el verde: es lo que el cliente recibe impreso o en PDF. Hairlines solo en sus tablas y el FAQ. */
:root {
  --bg: #123a2f; --surface: #0f3228; --raise: #18473a;
  --ink: #f2eedf; --ink-2: #cfd5c8; --ink-3: #9fb0a5;
  --line: rgba(242, 238, 223, .14); --line-2: rgba(242, 238, 223, .3);
  --street: rgba(242, 238, 223, .16); --avenue: rgba(242, 238, 223, .1);
  --accent: #ffcf3a; --accent-ink: #13261f;
  --paper: #f6f3ea; --paper-ink: #13261f; --paper-2: #4a5a52; --paper-line: rgba(19, 38, 31, .14);
  --sans: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --container: 1280px; --gutter: clamp(16px, 4vw, 40px);
  --t-hero: clamp(40px, 5vw, 72px); --t-h2: clamp(32px, 3.8vw, 56px); --t-h3: clamp(22px, 2vw, 30px);
  --t-lead: clamp(18px, 1.3vw, 20px); --t-body: 17px; --t-small: 14px;
  --r-s: 6px; --r-m: 16px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { background: var(--bg); color: var(--ink); overflow-x: clip; scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { font: 400 var(--t-body)/1.6 var(--sans); background: var(--bg); }
::selection { background: var(--accent); color: var(--accent-ink); }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
.wrap { max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -48px; background: var(--accent); color: var(--accent-ink); padding: 10px 14px; z-index: 50; }
.skip:focus { top: 12px; }

h1, h2, h3 { font-stretch: 125%; font-weight: 800; text-wrap: balance; }
h1 { font-size: var(--t-hero); line-height: .98; letter-spacing: -.03em; }
h2 { font-size: var(--t-h2); line-height: 1; letter-spacing: -.025em; }
h3 { font-size: var(--t-h3); line-height: 1.08; letter-spacing: -.015em; }
p { color: var(--ink-2); text-wrap: pretty; }
.lead { font-size: var(--t-lead); line-height: 1.55; max-width: 31em; }
h1 + .lead, h2 + .lead { margin-top: 22px; }
.kicker { font-size: var(--t-small); font-weight: 600; color: var(--ink-3); margin-bottom: 18px; }
.link { font-weight: 600; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 5px; }
.link:hover { text-decoration-color: var(--accent); }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border-radius: var(--r-s); font-weight: 700; white-space: nowrap; border: 0; cursor: pointer; transition: transform .15s var(--ease), background .2s, color .2s; }
.btn:active { transform: scale(.98); }
.btn--accent { background: var(--accent); color: var(--accent-ink); }
.btn--accent:hover { background: #ffd95e; }
.btn--ghost { border: 1px solid var(--line-2); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--line { border: 1.5px solid var(--ink); color: var(--ink); background: none; }
.btn--line:hover { background: var(--ink); color: var(--bg); }
.btn--lg { min-height: 54px; padding: 0 26px; }
.btn[aria-disabled="true"] { opacity: .45; pointer-events: none; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid transparent; transition: background .3s, border-color .3s; }
.nav.is-scrolled { background: rgba(18, 58, 47, .9); backdrop-filter: blur(12px); border-color: var(--line); }
.nav__in { display: flex; align-items: center; gap: 32px; height: 68px; }
.brand { font-size: 26px; font-weight: 800; font-stretch: 125%; letter-spacing: -.03em; margin-right: auto; }
.nav__links { display: flex; gap: 28px; font-size: var(--t-small); font-weight: 600; color: var(--ink-2); }
.nav__links a:hover { color: var(--ink); }
.nav__toggle { display: none; min-height: 44px; padding: 0 16px; border: 1px solid var(--line-2); border-radius: var(--r-s); background: none; cursor: pointer; }

/* Objeto vivo: el plano */
.map { position: relative; margin: 0; }
.map canvas { display: block; width: 100%; height: 100%; }
.pause { min-height: 44px; padding: 0 14px; background: none; border: 1px solid var(--line-2); border-radius: var(--r-s); cursor: pointer; color: var(--ink-2); font-size: var(--t-small); margin-left: auto; }
.pause:hover { border-color: var(--ink); }

/* 1 · Hero: plano a sangre con marco */
.hero { position: relative; height: clamp(660px, calc(100dvh - 68px), 960px); padding: 0 12px 12px; display: flex; flex-direction: column; }
.map--hero { position: absolute; inset: 0 12px 12px; border-radius: var(--r-m); overflow: hidden; background: var(--surface); }
.hero__in { position: relative; flex: 1; display: flex; flex-direction: column; justify-content: center; width: 100%; pointer-events: none; }
.hero__panel { max-width: 760px; background: var(--bg); padding: clamp(24px, 3vw, 40px); border-radius: var(--r-m); pointer-events: auto; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; margin: 32px 0 36px; }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line-2); }
.facts > div { padding: 14px 12px 0 0; }
.facts dt { font-size: var(--t-small); color: var(--ink-3); }
.facts dd { font-weight: 700; color: var(--ink); }
.map__legend { position: absolute; right: var(--gutter); bottom: 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; font-size: var(--t-small); color: var(--ink-2); pointer-events: auto; background: var(--bg); padding: 6px 6px 6px 16px; border-radius: var(--r-s); width: fit-content; max-width: calc(100% - var(--gutter) * 2); }
.sw { display: inline-block; width: 10px; height: 10px; margin-right: -10px; vertical-align: middle; }
.sw--you { background: var(--accent); }
.sw--rival { background: var(--ink); width: 8px; height: 8px; }
.sw--walk { background: var(--ink); width: 6px; height: 6px; border-radius: 50%; }

/* 2 · Método */
.process { position: relative; background: var(--surface); }
.process__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(24px, 4vw, 72px); min-height: min(100vh, 1000px); align-items: center; }
.rail { display: flex; align-items: center; gap: 14px; margin-bottom: 36px; font-size: var(--t-small); font-weight: 700; color: var(--ink-3); }
.rail__bar { position: relative; width: 140px; height: 2px; background: var(--line-2); }
.rail__bar i { position: absolute; inset: 0; background: var(--accent); transform-origin: left; transform: scaleX(var(--p, 0)); }
.steps { list-style: none; padding: 0; position: relative; min-height: 260px; }
.step h3 { font-size: var(--t-h2); line-height: 1; letter-spacing: -.025em; margin-bottom: 18px; }
.step p { font-size: var(--t-lead); max-width: 26em; }
.map--process { height: min(80vh, 780px); border-radius: var(--r-m); overflow: hidden; background: var(--bg); }
.js-pin .step { position: absolute; inset: 0 0 auto 0; opacity: 0; transform: translateY(16px); transition: opacity .5s var(--ease), transform .5s var(--ease); }
.js-pin .step.is-on { opacity: 1; transform: none; }

/* 3 · Reporte */
.report { padding: clamp(96px, 12vw, 180px) 0; overflow: clip; }
.report__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 80px); align-items: center; }
.sheet { margin: 0; background: var(--paper); color: var(--paper-ink); border-radius: 4px; padding: clamp(24px, 3vw, 44px); max-width: 640px; }
.sheet p { color: var(--paper-2); }
.sheet__head { margin-bottom: 24px; }
.sheet__title { font-size: var(--t-h3); font-weight: 800; font-stretch: 125%; letter-spacing: -.02em; color: var(--paper-ink) !important; }
.sheet__table { width: 100%; border-collapse: collapse; font-size: 15px; }
.sheet__table th, .sheet__table td { text-align: left; padding: 12px 8px; border-bottom: 1px solid var(--paper-line); vertical-align: middle; }
.sheet__table thead th { font-size: 13px; font-weight: 600; color: var(--paper-2); border-bottom: 1.5px solid var(--paper-ink); }
.sheet__table tbody th { font-weight: 600; position: relative; }
.sheet__table td:nth-child(2) { color: var(--paper-2); }
.sheet__table td:nth-child(3) { font-size: 22px; font-weight: 800; font-stretch: 125%; }
.sheet__table td:last-child { width: 26%; }
.spark { display: block; width: 100%; height: 32px; overflow: visible; }
.spark polyline { fill: none; stroke: var(--paper-ink); stroke-width: 1.6; vector-effect: non-scaling-stroke; }
.spark rect { fill: var(--paper-ink); }
.is-key .spark polyline { stroke-width: 2.4; }
.sheet__foot { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 24px; }
.sheet__foot > div { padding: 14px 16px; background: #ebe6d6; border-radius: 4px; position: relative; }
.sheet__foot .is-key { background: var(--accent); }
.sheet__foot .is-key p { color: var(--paper-ink); }
.sheet__foot p { font-size: var(--t-small); }
.sheet__foot .big { font-size: 30px; font-weight: 800; font-stretch: 125%; color: var(--paper-ink); margin-top: 2px; }
.tag { position: absolute; left: calc(100% + 40px); top: 50%; transform: translateY(-50%); width: max-content; max-width: 150px; font-size: 13px; font-weight: 600; line-height: 1.3; padding: 7px 10px; background: var(--bg); color: var(--ink); border-radius: var(--r-s); }
.tag::before { content: ""; position: absolute; right: 100%; top: 50%; border-top: 1.5px solid var(--accent); }
.sheet__table td { position: relative; }
.sheet__table .tag { left: calc(100% + 60px); max-width: 160px; }
.sheet__table .tag::before { width: 52px; }
.tag--up { left: calc(100% + 56px); top: 50%; }
.tag--up::before { width: 56px; }

/* 4 · Planes */
.plans { padding: clamp(96px, 12vw, 180px) 0; background: var(--surface); }
.plans h2 { margin-bottom: 56px; }
.plans__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(16px, 2vw, 28px); }
.plan { padding: clamp(28px, 3.5vw, 48px); border: 1px solid var(--line-2); border-radius: var(--r-m); display: flex; flex-direction: column; }
.plan--rec { background: var(--raise); border-color: var(--raise); }
.plan__price { font-size: clamp(36px, 4vw, 56px); font-weight: 800; font-stretch: 125%; letter-spacing: -.03em; color: var(--ink); margin: 14px 0 8px; line-height: 1; }
.plan__price span { font-size: var(--t-body); font-weight: 400; font-stretch: 100%; letter-spacing: 0; color: var(--ink-3); }
.plan__for { margin-bottom: 24px; }
.plan ul { list-style: none; padding: 0; border-top: 1px solid var(--line); margin-bottom: 24px; }
.plan li { padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.plan__note { font-size: var(--t-small); margin: -8px 0 24px; }
.plan .btn { margin-top: auto; align-self: flex-start; }
.note { max-width: 70ch; margin-top: 24px; font-size: var(--t-small); color: var(--ink-3); }

/* 5 · Diagnóstico */
.book { padding: clamp(96px, 10vw, 160px) 0; }
.book__grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.form .lead { margin-bottom: 36px; }
fieldset { border: 0; padding: 0; margin: 0 0 26px; }
legend { font-size: var(--t-small); font-weight: 600; color: var(--ink-3); margin-bottom: 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-2); background: none; cursor: pointer; font-weight: 500; }
.chip:hover { border-color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.field-row { display: grid; gap: 8px; font-size: var(--t-small); font-weight: 600; color: var(--ink-3); margin-bottom: 20px; }
.field-row input { min-height: 50px; padding: 0 14px; border-radius: var(--r-s); border: 1px solid var(--line-2); background: var(--raise); font-size: var(--t-body); font-weight: 400; color: var(--ink); caret-color: var(--accent); }
.field-row input::placeholder { color: var(--ink-3); opacity: 1; }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.err { color: var(--accent); min-height: 1.6em; font-size: var(--t-small); font-weight: 600; }
.ticket { position: sticky; top: 96px; padding: 28px; border-radius: var(--r-m); background: var(--paper); color: var(--paper-ink); }
.ticket__h { font-size: var(--t-small); font-weight: 600; color: var(--paper-2); margin-bottom: 14px; }
.ticket__msg { font: 400 var(--t-body)/1.6 var(--sans); white-space: pre-wrap; color: var(--paper-ink); margin-bottom: 24px; min-height: 8em; }
.ticket .btn { width: 100%; white-space: normal; text-align: center; }
.ticket .btn--accent { background: var(--paper-ink); color: var(--accent); }
.ticket .btn--accent:hover { background: #1f3a30; }

/* FAQ y pie */
.faq { padding: clamp(96px, 10vw, 160px) 0; background: var(--surface); }
.faq__grid { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 80px); }
details { border-top: 1px solid var(--line); padding: 18px 0; }
details:last-of-type { border-bottom: 1px solid var(--line); }
summary { cursor: pointer; font-size: var(--t-lead); font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 16px; min-height: 44px; align-items: center; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--accent); font-weight: 700; }
details[open] summary::after { content: "−"; }
details p { margin-top: 8px; max-width: 40em; }
.foot { padding: 72px 0 40px; border-top: 1px solid var(--line); }
.foot__in { display: grid; gap: 28px; }
.foot__mark { font-size: clamp(72px, 15vw, 220px); font-weight: 800; font-stretch: 125%; letter-spacing: -.05em; line-height: .85; color: var(--ink) !important; }
.foot__cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; font-size: var(--t-small); }

@media (max-width: 1180px) {
  .tag { display: none; }
}
@media (max-width: 960px) {
  .process__grid, .book__grid, .report__grid, .faq__grid, .plans__grid { grid-template-columns: minmax(0, 1fr); }
  /* en una columna: titular y CTA, después el plano, después los datos */
  .hero { height: auto; padding: 16px 0 24px; }
  .hero__in, .hero__panel { display: contents; }
  .hero__panel > * { margin-left: var(--gutter); margin-right: var(--gutter); }
  .kicker { order: 1; } .hero h1 { order: 2; } .hero .lead { order: 3; } .actions { order: 4; }
  .map--hero { position: relative; inset: auto; height: 420px; margin: 0 12px; order: 5; }
  .facts { order: 6; margin-top: 16px; }
  .map__legend { order: 7; position: static; margin: 8px var(--gutter) 0; padding-left: 0; max-width: none; }
  .process__grid { min-height: auto; padding: 96px var(--gutter); gap: 0; }
  .map--process { height: min(46vh, 420px); position: sticky; top: 68px; order: -1; z-index: 1; border: 8px solid var(--surface); }
  .steps { min-height: 0; }
  .step { padding: 60px 0 220px; }
  .step:last-child { padding-bottom: 80px; }
  .ticket { position: static; }
  .foot__cols { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .nav__links { display: none; position: absolute; top: 68px; left: 0; right: 0; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px var(--gutter) 16px; }
  .nav__links.is-open { display: flex; }
  .nav__links a { min-height: 48px; display: flex; align-items: center; }
  .nav__toggle { display: inline-flex; align-items: center; }
  .nav__cta { display: none; }
  .map--hero { height: 340px; margin: 0 8px; }
  .actions { margin-top: 24px; margin-bottom: 20px; }
  .facts { grid-template-columns: minmax(0, 1fr); }
  .facts > div { display: flex; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 12px 0; }
  .two, .sheet__foot { grid-template-columns: minmax(0, 1fr); }
  .sheet__table { font-size: 14px; }
  .sheet__table td:last-child { width: 22%; }
  .sheet__table td:nth-child(3) { font-size: 18px; }
}
