/* arkeniq.com — un solo archivo, sin dependencias. Tokens primero; claro por defecto, oscuro por sistema o por elección. */
:root {
  color-scheme: light;
  /* paleta sacada del logo oficial: azul marino #020c2b → #16306d, degradado #3b82f6 → #06b6d4 */
  --paper: #f7f8fa;
  --paper-2: #eef1f6;
  --card: #ffffff;
  --ink: #0b1226;
  --ink-2: #343c4e;
  --muted: #586173;
  --line: #e1e5ec;
  --line-2: #cdd3de;
  --accent: #1d4ed8;          /* texto de acento: 6,3:1 sobre --paper */
  --accent-strong: #3b82f6;   /* superficies, nunca texto pequeño */
  --accent-soft: #e8effd;
  --brand-grad: linear-gradient(90deg, #3b82f6, #06b6d4);
  --text-grad: linear-gradient(90deg, #1d4ed8, #0e7490);   /* ≥5:1 en todo el recorrido */
  --ok: #166534;
  --field: #7b8496;           /* borde de campos: 3,5:1 (WCAG 1.4.11) */
  --danger: #b42318;
  --btn-bg: #0f2557;
  --btn-fg: #ffffff;
  --btn-bg-hover: #16306d;
  --glow: rgba(59, 130, 246, .14);
  --grid: rgba(11, 18, 38, .03);
  --shadow: 0 1px 2px rgba(11,18,38,.05), 0 8px 24px -12px rgba(11,18,38,.14);
  --shadow-lg: 0 2px 4px rgba(11,18,38,.04), 0 24px 60px -24px rgba(11,18,38,.22);
  --radius: 14px;
  --radius-lg: 22px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: ui-sans-serif, system-ui, -apple-system, "Segoe UI Variable Display", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", "Segoe UI Mono", Menlo, Consolas, monospace;
  --wrap: 1180px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #060a14;
  --paper-2: #0a101d;
  --card: #0e1526;
  --ink: #eef2f8;
  --ink-2: #c3cad8;
  --muted: #909aae;
  --line: #1a2236;
  --line-2: #283350;
  --accent: #60a5fa;
  --accent-strong: #3b82f6;
  --accent-soft: #0e1a33;
  --text-grad: linear-gradient(90deg, #60a5fa, #22d3ee);
  --ok: #4ade80;
  --field: #5f6c88;
  --danger: #ff8a7a;
  --btn-bg: #eef2f8;
  --btn-fg: #060a14;
  --btn-bg-hover: #ffffff;
  --glow: rgba(59, 130, 246, .22);
  --grid: rgba(255, 255, 255, .025);
  --shadow: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px -12px rgba(0,0,0,.6);
  --shadow-lg: 0 2px 4px rgba(0,0,0,.3), 0 24px 60px -24px rgba(0,0,0,.7);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 17px/1.6 var(--font); font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration-color: color-mix(in srgb, currentColor 35%, transparent); text-underline-offset: .2em; }
a:hover { text-decoration-color: currentColor; }
p { margin: 0 0 1em; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; letter-spacing: -.025em; line-height: 1.08; font-weight: 680; text-wrap: balance; }
::selection { background: var(--accent-strong); color: #fff; }

:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--btn-bg); color: var(--btn-fg); padding: 10px 16px; border-radius: 10px; font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
.eyebrow { font: 500 12.5px/1.35 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--accent); display: flex; align-items: flex-start; gap: 10px; margin: 0 0 18px; }
.eyebrow::before { content: ""; flex: none; width: 16px; height: 4px; margin-top: .45em; border-radius: 2px; background: var(--brand-grad); }
.lead { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; color: var(--ink-2); max-width: 62ch; }
.muted { color: var(--muted); }

/* ---------- botones ---------- */
.btn { --h: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: var(--h); padding: 0 22px; border-radius: 999px; font: 600 16px/1 var(--font); text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: background-color .15s, color .15s, border-color .15s, transform .15s; white-space: nowrap; }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--btn-bg); color: var(--btn-fg); }
.btn-primary:hover { background: var(--btn-bg-hover); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--ink); }
.btn-sm { --h: 40px; padding: 0 16px; font-size: 15px; }
@media (prefers-reduced-motion: no-preference) { .btn:active { transform: translateY(1px); } .btn-arrow:hover svg { transform: translateX(3px); } .btn-arrow svg { transition: transform .2s; } }

/* ---------- cabecera ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: color-mix(in srgb, var(--paper) 82%, transparent); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.site-header.scrolled { border-bottom-color: var(--line); }
.bar { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 700 19px/1 var(--font-display); letter-spacing: -.03em; }
.brand svg { width: 25px; height: 30px; }
.brand .logo-d { display: none; }
:root[data-theme="dark"] .brand .logo-l { display: none; }
:root[data-theme="dark"] .brand .logo-d { display: block; }
.nav { display: flex; gap: 4px; margin-left: 12px; }
.nav a { padding: 8px 12px; border-radius: 999px; text-decoration: none; color: var(--ink-2); font-size: 15px; font-weight: 500; }
.nav a:hover { color: var(--ink); background: var(--paper-2); }
.bar-end { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.icon-btn { width: 40px; height: 40px; display: inline-grid; place-items: center; border-radius: 999px; border: 1px solid var(--line-2); background: transparent; color: var(--ink); cursor: pointer; }
.icon-btn:hover { border-color: var(--ink); }
.icon-btn svg { width: 18px; height: 18px; }
.theme-toggle .moon { display: none; }
:root[data-theme="dark"] .theme-toggle .sun { display: none; }
:root[data-theme="dark"] .theme-toggle .moon { display: block; }
.menu-btn { display: none; }
.mobile-nav { display: none; }
@media (max-width: 920px) {
  .nav, .bar-end .btn { display: none; }
  .menu-btn { display: inline-grid; }
  .mobile-nav { border-top: 1px solid var(--line); padding: 12px 0 20px; }
  .mobile-nav:not([hidden]) { display: block; }
  .mobile-nav a { display: block; padding: 13px 4px; font-size: 18px; text-decoration: none; border-bottom: 1px solid var(--line); }
  .mobile-nav .btn { margin-top: 16px; width: 100%; border-bottom: 0; }
}

/* ---------- hero ---------- */
.hero { position: relative; overflow: hidden; padding: clamp(40px, 7vw, 96px) 0 clamp(40px, 5vw, 72px); isolation: isolate; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px); background-size: 56px 56px; mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 30%, #000 30%, transparent 75%); }
.hero::after { content: ""; position: absolute; z-index: -1; width: 900px; height: 600px; right: -260px; top: -180px; background: radial-gradient(closest-side, var(--glow), transparent); filter: blur(10px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero h1 { font-size: clamp(40px, 6vw, 76px); letter-spacing: -.035em; line-height: 1.02; margin-bottom: 26px; }
.hero h1 em { font-style: normal; color: var(--accent); background: var(--text-grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
@media (forced-colors: active) { .hero h1 em { background: none; -webkit-text-fill-color: CanvasText; } }
.hero .lead { margin-bottom: 34px; max-width: 54ch; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.proof-line { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--muted); font-size: 14.5px; padding: 0; list-style: none; }
.proof-line li { display: inline-flex; align-items: center; gap: 8px; }
.proof-line svg { width: 16px; height: 16px; color: var(--ink-2); }
@media (max-width: 920px) { .hero-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 420px) { .msg { grid-template-columns: 30px minmax(0, 1fr); } .msg .avatar { width: 30px; height: 30px; } .msg > span:last-child { grid-column: 2; justify-self: start; } .demo { padding: 16px; } }

/* tarjeta-demostración del hero */
.demo { margin: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: 22px; position: relative; }
.demo-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.demo-title { font: 600 14px/1.2 var(--font); display: flex; align-items: center; gap: 10px; }
.dot-live { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--brand-grad); box-shadow: 0 0 0 4px var(--accent-soft); }
.tag { font: 500 11.5px/1 var(--mono); letter-spacing: .04em; text-transform: uppercase; color: var(--muted); border: 1px solid var(--line-2); padding: 6px 8px; border-radius: 999px; white-space: nowrap; }
.chat { display: grid; gap: 10px; margin: 0 0 18px; padding: 0; list-style: none; }
.msg { display: grid; grid-template-columns: 34px 1fr auto; gap: 12px; align-items: center; padding: 11px 12px; border-radius: 12px; background: var(--paper-2); }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; font: 700 13px/1 var(--font); color: var(--ink-2); background: var(--line); }
.msg p { margin: 0; font-size: 14.5px; line-height: 1.35; }
.msg small { display: block; color: var(--muted); font-size: 12.5px; }
.badge-late { font: 500 11.5px/1 var(--mono); color: var(--danger); background: color-mix(in srgb, var(--danger) 10%, transparent); padding: 6px 8px; border-radius: 999px; white-space: nowrap; }
.badge-ok { font: 500 11.5px/1 var(--mono); color: var(--ok); background: color-mix(in srgb, var(--ok) 12%, transparent); padding: 6px 8px; border-radius: 999px; white-space: nowrap; }
.formula { border-top: 1px dashed var(--line-2); padding-top: 16px; display: grid; gap: 6px; }
.formula code { font: 500 14px/1.5 var(--mono); color: var(--ink-2); overflow-wrap: anywhere; }
.formula strong { font: 700 clamp(26px, 3vw, 34px)/1.1 var(--font-display); letter-spacing: -.03em; }
.formula strong span { color: var(--accent); }
.demo-note { margin: 12px 0 0; font-size: 12.5px; color: var(--muted); }

/* ---------- secciones ---------- */
.section { padding: clamp(64px, 8vw, 104px) 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-alt { background: var(--paper-2); }
.section-head { max-width: 760px; margin-bottom: clamp(36px, 5vw, 56px); }
.section-head h2 { font-size: clamp(32px, 4.4vw, 54px); margin-bottom: 18px; letter-spacing: -.04em; }
.section-head p:not(.eyebrow) { color: var(--ink-2); font-size: clamp(17px, 1.4vw, 19px); max-width: 62ch; margin: 0; }

/* capacidades */
.caps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden; }
.cap { background: var(--card); padding: 28px 24px 26px; display: flex; flex-direction: column; gap: 12px; }
.cap-icon { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--paper-2); color: var(--ink); border: 1px solid var(--line); }
.cap-icon svg { width: 22px; height: 22px; }
.cap h3 { font-size: 20px; letter-spacing: -.02em; margin-top: 6px; }
.cap p { margin: 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.cap dl { margin: auto 0 0; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px; }
.cap dt { font: 500 11.5px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.cap dd { margin: 0; color: var(--ink-2); line-height: 1.5; }
@media (max-width: 1040px) { .caps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .caps { grid-template-columns: minmax(0, 1fr); } }

/* principios */
.principles { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 28px; margin-top: clamp(36px, 5vw, 56px); padding: 0; list-style: none; }
.principles li { padding-top: 18px; border-top: 2px solid var(--ink); }
.principles h3 { font-size: 17px; letter-spacing: -.01em; line-height: 1.3; margin-bottom: 8px; }
.principles p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
@media (max-width: 1040px) { .principles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .principles { grid-template-columns: minmax(0, 1fr); } }

/* pasos */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; counter-reset: step; padding: 0; list-style: none; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 30px 28px; display: flex; flex-direction: column; gap: 14px; position: relative; box-shadow: var(--shadow); }
.step-n { font: 500 12.5px/1 var(--mono); letter-spacing: .06em; color: var(--accent); }
.step h3 { font-size: 24px; letter-spacing: -.03em; }
.step > p { margin: 0; color: var(--ink-2); font-size: 16px; }
.step ul { margin: 4px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; font-size: 15px; color: var(--ink-2); }
.step li { display: grid; grid-template-columns: 18px 1fr; gap: 10px; line-height: 1.45; }
.step li svg { width: 18px; height: 18px; color: var(--ink-2); margin-top: 2px; }
.step-meta { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 14px; color: var(--muted); }
.step-meta b { color: var(--ink); font-weight: 600; }
.step.featured { border-color: var(--ink); }
.step.featured::before { content: "Empieza aquí"; position: absolute; top: -12px; left: 24px; background: var(--btn-bg); color: var(--btn-fg); font: 500 11.5px/1 var(--mono); letter-spacing: .05em; text-transform: uppercase; padding: 6px 10px; border-radius: 999px; }
@media (max-width: 960px) { .steps { grid-template-columns: minmax(0, 1fr); } }

/* mini diagnóstico */
.diag { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.diag-copy h2 { font-size: clamp(32px, 4.4vw, 54px); letter-spacing: -.04em; margin-bottom: 18px; }
.diag-copy > p:not(.eyebrow) { color: var(--ink-2); font-size: 18px; }
.diag-facts { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 14px; }
.diag-facts li { display: grid; grid-template-columns: 22px 1fr; gap: 12px; color: var(--ink-2); font-size: 15.5px; line-height: 1.5; }
.diag-facts svg { width: 20px; height: 20px; color: var(--ink-2); margin-top: 2px; }
.panel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); padding: clamp(22px, 3vw, 34px); }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 16px; }
.field { display: grid; gap: 7px; align-content: start; }
.field.full { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: 15px; line-height: 1.35; }
@media (min-width: 561px) { .field:not(.full) { grid-template-rows: minmax(2.7em, auto); } .field:not(.full) label { align-self: end; } }
.field .hint { font-size: 13.5px; color: var(--muted); line-height: 1.4; }
.input { width: 100%; height: 52px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--field); background: var(--paper); color: var(--ink); font: 500 18px/1 var(--font); font-variant-numeric: tabular-nums; transition: border-color .15s, box-shadow .15s; }
.input::placeholder { color: var(--muted); opacity: 1; }
.input:hover { border-color: var(--ink-2); }
.input:focus { outline: 2px solid transparent; border-color: var(--accent); box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 22%, transparent); }
.input[aria-invalid="true"] { border-color: var(--danger); }
.prefix { position: relative; }
.prefix > span { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 600; pointer-events: none; }
.prefix .input { padding-left: 30px; }
.error { color: var(--danger); font-size: 14px; font-weight: 500; min-height: 0; }
.error:empty { display: none; }
.form-foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; margin-top: 6px; }
.form-foot .btn { flex: none; }
.form-foot p { margin: 0; font-size: 13.5px; color: var(--muted); flex: 1 1 220px; }
.result { margin-top: 26px; padding-top: 26px; border-top: 1px solid var(--line); }
.result[hidden] { display: none; }
.result-big { font: 700 clamp(28px, 3.4vw, 40px)/1.1 var(--font-display); letter-spacing: -.035em; margin: 0 0 12px; }
.result-big span { color: var(--accent); }
.result .math { display: block; font: 500 15px/1.5 var(--mono); background: var(--paper-2); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; margin: 14px 0; overflow-x: auto; color: var(--ink-2); }
.result .money { font-size: 18px; font-weight: 600; margin: 0 0 10px; }
.result .note { font-size: 14px; color: var(--muted); margin: 0 0 20px; }
.result .next { background: var(--accent-soft); border-radius: 14px; padding: 18px 18px; display: grid; gap: 14px; }
.result .next p { margin: 0; font-size: 15.5px; }
@media (max-width: 960px) { .diag { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 560px) { .form-grid { grid-template-columns: minmax(0, 1fr); } }

/* productos y canal */
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.feature { border-radius: var(--radius-lg); padding: clamp(28px, 4vw, 44px); display: flex; flex-direction: column; gap: 16px; min-height: 100%; border: 1px solid var(--line); background: var(--card); position: relative; overflow: hidden; }
.feature h3 { font-size: clamp(26px, 2.6vw, 34px); letter-spacing: -.035em; }
.feature p { margin: 0; color: var(--ink-2); }
.feature .kicker { font: 500 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.feature .actions { margin-top: auto; padding-top: 10px; display: flex; flex-wrap: wrap; gap: 10px; }
.feature.dark { background: linear-gradient(160deg, #16306d, #020c2b 70%); color: #eef2f8; border-color: #0f2557; }
:root[data-theme="dark"] .feature.dark { background: linear-gradient(160deg, #13296a, #070d1c 62%); border-color: color-mix(in srgb, var(--accent) 35%, var(--line-2)); }
.feature.dark p { color: #c3cad8; }
.feature.dark .kicker { color: #a9b4cc; }
.feature.dark .btn-primary { background: #eef2f8; color: #060a14; }
.feature.dark .btn-primary:hover { background: #fff; }
.feature.dark .btn-ghost { color: #eef2f8; border-color: #5d6f9e; }
.feature.dark .btn-ghost:hover { border-color: #eef2f8; }
.feature.dark::after { content: ""; position: absolute; width: 420px; height: 420px; right: -160px; bottom: -200px; background: radial-gradient(closest-side, rgba(6,182,212,.24), transparent); filter: blur(40px); pointer-events: none; }
.series { list-style: none; padding: 0; margin: 4px 0 0; display: grid; gap: 10px; }
.series li { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: baseline; padding: 12px 0; border-top: 1px solid var(--line); }
.series b { font-weight: 650; white-space: nowrap; }
.series span { color: var(--ink-2); font-size: 15px; }
.nets { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); font-size: 14px; font-weight: 500; text-decoration: none; color: var(--ink); }
a.chip:hover { border-color: var(--ink); }
.feature.dark .chip { border-color: #5d6f9e; color: #eef2f8; }
@media (max-width: 900px) { .duo { grid-template-columns: minmax(0, 1fr); } }

/* preguntas */
.faq { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 72px); }
.faq h2 { font-size: clamp(32px, 4vw, 48px); letter-spacing: -.04em; }
.qa { border-top: 1px solid var(--line); }
.qa details { border-bottom: 1px solid var(--line); }
.qa summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; font-weight: 600; font-size: 18px; position: relative; line-height: 1.4; }
.qa summary::-webkit-details-marker { display: none; }
.qa summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 12px; height: 12px; margin-top: -8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s; }
.qa details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.qa details > div { padding: 0 0 22px; color: var(--ink-2); max-width: 64ch; }
.qa details > div p:last-child { margin: 0; }
@media (max-width: 900px) { .faq { grid-template-columns: minmax(0, 1fr); } }

/* contacto */
.contact { text-align: center; }
.contact h2 { font-size: clamp(36px, 5.6vw, 68px); letter-spacing: -.045em; max-width: 16ch; margin: 0 auto 22px; }
.contact .lead { margin: 0 auto 34px; }
.contact .cta-row { justify-content: center; }
.contact-lines { list-style: none; padding: 0; margin: 30px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px 32px; font: 600 clamp(17px, 1.8vw, 20px)/1.2 var(--font); }
.contact-lines li { display: inline-flex; gap: 10px; align-items: center; }
.contact-lines svg { width: 20px; height: 20px; color: var(--accent); }

/* pie */
.site-footer { border-top: 1px solid var(--line); padding: 48px 0 40px; font-size: 14.5px; color: var(--muted); }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; }
.foot-grid h2 { font: 500 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--ink); margin: 6px 0 14px; }
.foot-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.foot-grid a { text-decoration: none; }
.foot-grid a:hover { color: var(--ink); text-decoration: underline; }
.foot-legal { margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
@media (max-width: 800px) { .foot-grid { grid-template-columns: 1fr 1fr; } }

/* páginas de texto (privacidad, 404) */
.doc { padding: clamp(48px, 7vw, 88px) 0 clamp(64px, 8vw, 104px); }
.doc-grid { display: grid; grid-template-columns: 240px minmax(0, 720px); gap: clamp(32px, 6vw, 88px); }
.doc h1 { font-size: clamp(36px, 5vw, 58px); letter-spacing: -.045em; margin-bottom: 14px; }
.doc .meta { color: var(--muted); font-size: 15px; margin-bottom: 36px; }
.doc h2 { font-size: 22px; letter-spacing: -.02em; margin: 48px 0 12px; line-height: 1.25; scroll-margin-top: 96px; }
.doc .prose { font-size: 17px; line-height: 1.7; color: var(--ink-2); }
.doc .prose strong { color: var(--ink); }
.doc .prose a { color: var(--accent); }
.doc .prose ul { padding-left: 1.2rem; margin: 0 0 1em; }
.doc .prose li { margin: 0 0 .5em; }
.doc .summary { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin: 0 0 8px; }
.doc .summary p { margin: 0; }
.toc { position: sticky; top: 100px; align-self: start; font-size: 14.5px; }
.toc h2 { font: 500 12px/1 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 14px; }
.toc ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; border-left: 1px solid var(--line); }
.toc a { display: block; padding: 6px 0 6px 14px; margin-left: -1px; border-left: 2px solid transparent; text-decoration: none; color: var(--muted); }
.toc a:hover { color: var(--ink); border-left-color: var(--ink); }
.back { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--muted); font-size: 15px; margin-bottom: 28px; }
.back:hover { color: var(--ink); }
.back svg { width: 16px; height: 16px; }
@media (max-width: 900px) { .doc-grid { grid-template-columns: minmax(0, 1fr); } .toc { position: static; } }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.foot-tag { margin-top: 14px; max-width: 34ch; }
.noscript { margin-top: 18px; }
.foot-legal.flat { margin-top: 0; padding-top: 0; border-top: 0; }
.wrap.narrow { max-width: 640px; }
.lead.spaced { margin-bottom: 32px; }

/* aparición suave al hacer scroll (solo si el usuario no pidió menos movimiento y hay JS) */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal.pre { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.2,1); }
  .js .reveal.pre.in { opacity: 1; transform: none; }
}
@media print { .site-header, .theme-toggle, .menu-btn, .skip { display: none !important; } body { background: #fff; color: #000; } .reveal { opacity: 1 !important; transform: none !important; } }

/* ---------- ronda 2 ---------- */
.nowrap { white-space: nowrap; }
.diag-lead { margin-bottom: 0; }
@media (max-width: 560px) { .hero .cta-row .btn { width: 100%; } }

/* micro-interacciones */
.cap, .step, .feature { transition: border-color .2s, transform .2s, box-shadow .2s; }
.cap:hover { background: color-mix(in srgb, var(--card) 92%, var(--paper-2)); }
@media (prefers-reduced-motion: no-preference) { .step:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); } }

/* pasos tras el resultado */
.next-steps { margin: 0; padding: 0; list-style: none; counter-reset: n; display: grid; gap: 10px; }
.next-steps li { counter-increment: n; display: grid; grid-template-columns: 26px 1fr; gap: 10px; font-size: 15px; line-height: 1.45; color: var(--ink-2); }
.next-steps li::before { content: counter(n); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--card); border: 1px solid var(--line-2); font: 600 12.5px/1 var(--font); color: var(--ink); }
.result .next [hidden] { display: none; }

/* agenda ilustrada de CUPO */
.agenda { list-style: none; padding: 0; margin: 6px 0 0; display: grid; gap: 8px; }
.agenda li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; border-radius: 12px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); font-size: 14.5px; }
.agenda .t { font: 500 13px/1 var(--mono); color: #a9b4cc; }
.agenda .w { color: #eef2f8; min-width: 0; }
.agenda .s { font: 500 11.5px/1.2 var(--mono); color: #c3cad8; text-align: right; }
.agenda .rec { border-color: rgba(34,211,238,.45); background: rgba(6,182,212,.12); }
.agenda .rec .s { color: #67e8f9; }
.illu { font-size: 12.5px; color: #a9b4cc !important; margin: 0 !important; }
@media (max-width: 480px) { .agenda li { grid-template-columns: 46px minmax(0, 1fr); } .agenda .s { grid-column: 2; text-align: left; } }

/* privacidad */
.doc .prose :is(h1, h2) { color: var(--ink); }
@media (max-width: 900px) { .toc { order: 2; } }

/* sin JavaScript: navegación visible y sin formulario mudo */
:root:not(.js) .menu-btn, :root:not(.js) .theme-toggle, :root:not(.js) #minidiag { display: none; }
@media (max-width: 920px) { :root:not(.js) .mobile-nav[hidden] { display: block; } }

/* la demo del hero cobra vida (solo si no se pidió menos movimiento) */
@media (prefers-reduced-motion: no-preference) {
  .js .demo .msg { animation: msg-in .55s cubic-bezier(.2,.7,.2,1) both; }
  .js .demo .msg:nth-child(2) { animation-delay: .14s; }
  .js .demo .msg:nth-child(3) { animation-delay: .28s; }
  .js .demo .msg .badge-late, .js .demo .msg .badge-ok { animation: pop .35s cubic-bezier(.2,.9,.3,1.3) both; }
  .js .demo .msg:nth-child(1) > span:last-child { animation-delay: .9s; }
  .js .demo .msg:nth-child(2) > span:last-child { animation-delay: 1.05s; }
  .js .demo .msg:nth-child(3) > span:last-child { animation-delay: 1.2s; }
  .js .demo .formula { animation: msg-in .55s cubic-bezier(.2,.7,.2,1) .5s both; }
  @keyframes msg-in { from { opacity: 0; transform: translateY(8px); } }
  @keyframes pop { from { opacity: 0; transform: scale(.8); } }
}

.hero + .section { padding-top: clamp(32px, 4vw, 56px); }
.hero { padding-bottom: clamp(24px, 3vw, 40px); }

/* ---------- ronda 3 ---------- */
main:focus { outline: none; }
.section-head h2 { font-size: clamp(30px, 3.6vw, 44px); }
.site-footer .brand { color: var(--ink); }
.agenda .s { font-size: 12.5px; }
.tldr { background: var(--accent-soft); border-radius: 12px; padding: 12px 16px; font-size: 15.5px; color: var(--ink); }
@media (max-width: 560px) { .series li { grid-template-columns: 1fr; gap: 4px; } }
@media (max-width: 920px) { .demo .msg:nth-child(3) { display: none; } }

/* cierre en banda oscura, como la tarjeta de CUPO */
.contact { background: linear-gradient(160deg, #0f2557, #020c2b 70%); color: #eef2f8; position: relative; overflow: hidden; isolation: isolate; border-top: 0 !important; }
:root[data-theme="dark"] .contact { background: linear-gradient(160deg, #0f2150, #04091a 70%); border-top: 1px solid var(--line) !important; }
.contact::after { content: ""; position: absolute; z-index: -1; width: 900px; height: 600px; left: 50%; bottom: -380px; transform: translateX(-50%); background: radial-gradient(closest-side, rgba(59,130,246,.38), transparent); filter: blur(40px); pointer-events: none; }
.contact .eyebrow { justify-content: center; color: #67e8f9; }
.contact h2 { color: #eef2f8; }
.contact .lead { color: #c3cad8; }
.contact .btn-primary { background: #eef2f8; color: #060a14; }
.contact .btn-primary:hover { background: #fff; }
.contact .btn-ghost { color: #eef2f8; border-color: #5d6f9e; }
.contact .btn-ghost:hover { border-color: #eef2f8; }
.contact .contact-lines svg { color: #67e8f9; }
.contact :focus-visible { outline-color: #67e8f9; }

/* barra de WhatsApp en móvil (atajo visual; fuera del orden de tabulación) */
.wa-bar { display: none; }
@media (max-width: 720px) {
  .js .wa-bar { position: fixed; z-index: 40; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom, 0px)); display: flex; align-items: center; justify-content: center; gap: 10px; height: 52px; border-radius: 999px; background: var(--btn-bg); color: var(--btn-fg); font: 600 16px/1 var(--font); text-decoration: none; box-shadow: var(--shadow-lg); transform: translateY(160%); visibility: hidden; transition: transform .3s cubic-bezier(.2,.7,.2,1), visibility 0s linear .3s; }
  .js .wa-bar svg { width: 18px; height: 18px; }
  .js .wa-bar.show { transform: none; visibility: visible; transition: transform .3s cubic-bezier(.2,.7,.2,1), visibility 0s; }
  .js body { padding-bottom: 76px; }
  html { scroll-padding-bottom: 84px; }
}
@media print { .wa-bar { display: none !important; } }

/* ---------- ronda 4: logo oficial y móvil ---------- */
.foot-grid h2 { line-height: 1.35; }
@media (max-width: 560px) {
  .foot-grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
  .foot-grid > div:first-child { grid-column: 1 / -1; }
  .contact .cta-row .btn { width: 100%; }
}
.btn-primary { box-shadow: 0 1px 0 rgba(255,255,255,.08) inset; }
.feature.dark :focus-visible { outline-color: #67e8f9; }
::selection { background: #1d4ed8; color: #fff; }
@media (max-width: 560px) { .foot-grid nav:last-child { grid-column: 1 / -1; } }
.foot-app { margin-top: 40px; padding: 20px 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); max-width: 860px; }
.foot-app h2 { font: 600 15px/1.3 var(--font); letter-spacing: 0; color: var(--ink); margin: 0 0 6px; }
.foot-app p { margin: 0; font-size: 14.5px; line-height: 1.55; }
.foot-app a { color: var(--accent); }
mark.pendiente { background: #fde68a; color: #422006; padding: 0 .3em; border-radius: 4px; font-weight: 600; }
