/* Alpha ISP — landing
   Layout: la página sigue un caso real a través del sistema (mensaje → ticket → OS → cierre → métrica);
   una banda oscura "NOC" abre y cierra, el medio es papel claro con capturas reales.
   Marca: todos los colores salen de estos tokens. Cambiar acá cambia el sitio. */
:root {
  --paper: #F3F5F8;
  --surface: #FFFFFF;
  --ink: #0D1726;
  --muted: #536074;
  --line: #DCE2EA;
  --blue: #2B59F0;
  --blue-ink: #FFFFFF;
  --teal: #0F8C79;
  --band: #0D1726;
  --band-2: #142238;
  --band-fg: #E9EEF5;
  --band-muted: #9AA8BC;
  --band-line: #24344D;
  --signal: #19C3A9;
  --shadow: 0 1px 2px rgb(13 23 38 / .06), 0 12px 32px -12px rgb(13 23 38 / .22);
  --phone-bezel: #111821;

  --f-display: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --step--1: .8125rem;
  --step-0: 1rem;
  --step-1: 1.1875rem;
  --step-2: clamp(1.4rem, 1.1rem + 1vw, 1.75rem);
  --step-3: clamp(1.9rem, 1.4rem + 2vw, 2.75rem);
  --step-4: clamp(2.3rem, 1.5rem + 3.4vw, 4rem);

  --wrap: 1180px;
  --radius: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0A111C; --surface: #111B2A; --ink: #E6ECF4; --muted: #9AA8BC; --line: #22314A;
    --blue: #6F8DFF; --blue-ink: #0A111C; --teal: #34D1B8;
    --band: #060B13; --band-2: #0E1828; --band-fg: #E9EEF5; --band-muted: #93A1B5; --band-line: #1D2B42;
    --signal: #34D1B8; --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 16px 40px -16px rgb(0 0 0 / .7);
    --phone-bezel: #000;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #0A111C; --surface: #111B2A; --ink: #E6ECF4; --muted: #9AA8BC; --line: #22314A;
  --blue: #6F8DFF; --blue-ink: #0A111C; --teal: #34D1B8;
  --band: #060B13; --band-2: #0E1828; --band-fg: #E9EEF5; --band-muted: #93A1B5; --band-line: #1D2B42;
  --signal: #34D1B8; --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 16px 40px -16px rgb(0 0 0 / .7);
  --phone-bezel: #000;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 var(--step-0)/1.6 var(--f-body);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body::before {
  content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px);
  z-index: 60; background: var(--band);
}
img, video { max-width: 100%; display: block; }
a { color: var(--blue); }
:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--f-display); font-stretch: 112%; line-height: 1.08; letter-spacing: -.015em; text-wrap: balance; margin: 0; }
h2 { font-size: var(--step-3); font-weight: 700; }
h3 { font-size: var(--step-1); font-weight: 650; letter-spacing: -.005em; }
p { margin: 0; text-wrap: pretty; }
.mono { font-family: var(--f-mono); }

.wrap {
  max-width: calc(var(--wrap) + 2 * 24px); margin-inline: auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 700px) { .wrap { padding-left: max(24px, env(safe-area-inset-left, 0px)); padding-right: max(24px, env(safe-area-inset-right, 0px)); } }

.eyebrow {
  font: 500 var(--step--1)/1.3 var(--f-mono); letter-spacing: .06em; text-transform: uppercase;
  color: var(--teal); display: inline-flex; align-items: center; gap: .5em;
}
.eyebrow::before { content: ""; width: .55em; height: .55em; border-radius: 50%; background: currentColor; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 46px; padding: 0 1.25rem; border-radius: 10px; border: 1px solid transparent;
  font: 600 var(--step-0)/1 var(--f-body); text-decoration: none; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease, border-color .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--blue); color: var(--blue-ink); }
.btn-ghost { color: var(--band-fg); border-color: var(--band-line); background: transparent; }
.btn-ghost:hover { border-color: var(--band-muted); }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 50;
  background: color-mix(in srgb, var(--band) 92%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--band-line); color: var(--band-fg);
}
.site-header .wrap { display: flex; align-items: center; gap: 1.5rem; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--band-fg); text-decoration: none; }
.brand img { width: 34px; height: 34px; }
.brand-word { font: 750 1.3rem/1 var(--f-display); font-stretch: 118%; letter-spacing: -.02em; }
.brand-word small { font: 500 .7rem/1 var(--f-mono); letter-spacing: .08em; color: var(--signal); margin-left: .35em; vertical-align: .25em; }
.nav { display: flex; gap: 1.4rem; margin-left: auto; }
.nav a { color: var(--band-muted); text-decoration: none; font-size: .95rem; }
.nav a:hover { color: var(--band-fg); }
.site-header .btn { min-height: 40px; padding: 0 1rem; font-size: .92rem; }
@media (max-width: 900px) { .nav { display: none; } .site-header .btn { margin-left: auto; } }

/* ---------- hero ---------- */
.hero { background: var(--band); color: var(--band-fg); position: relative; overflow: hidden; }
.hero::before {
  /* brillo suave detrás de la captura */
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background: radial-gradient(circle at 78% 18%, color-mix(in srgb, var(--blue) 28%, transparent), transparent 42%);
}
.hero .wrap { position: relative; display: grid; gap: 3rem; padding-block: 4.5rem 0; }
@media (min-width: 1000px) { .hero .wrap { grid-template-columns: 1fr 1.15fr; align-items: end; padding-block: 5.5rem 0; } }
.hero-copy { display: grid; gap: 1.4rem; align-content: start; padding-bottom: 3rem; min-width: 0; }
.hero h1 { font-size: var(--step-4); font-weight: 750; font-stretch: 116%; }
.hero h1 em { font-style: normal; color: var(--signal); }
.hero-lede { color: var(--band-muted); font-size: var(--step-1); max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; }
.hero .eyebrow { color: var(--signal); }
.hero-visual { position: relative; min-width: 0; padding-bottom: 2.5rem; }
.hero-visual .browser { transform: translateY(0); }
.hero-visual .phone { position: absolute; right: -6px; bottom: 0; width: clamp(150px, 30%, 250px); }
@media (max-width: 999px) { .hero-visual { padding-right: 18%; } .hero-visual .phone { right: 0; width: 34%; } }

/* ---------- frames ---------- */
.browser {
  border-radius: 12px 12px 0 0; overflow: hidden; background: var(--surface);
  border: 1px solid var(--band-line); border-bottom: 0; box-shadow: 0 30px 60px -20px rgb(0 0 0 / .55);
}
.browser.closed { border-radius: 12px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); border-color: var(--line); }
.browser-bar {
  display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: var(--band-2);
  border-bottom: 1px solid var(--band-line);
}
.browser-bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--band-line); }
.browser-bar span {
  margin-left: 10px; font: 400 .72rem/1 var(--f-mono); color: var(--band-muted);
  background: var(--band); padding: 5px 10px; border-radius: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.browser img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: top left; }

.phone {
  position: relative; border-radius: 30px; padding: 7px; background: var(--phone-bezel);
  box-shadow: 0 24px 48px -18px rgb(0 0 0 / .55), inset 0 0 0 1px rgb(255 255 255 / .08);
  max-width: 100%;
}
.phone > img, .phone > video {
  width: 100%; height: auto; border-radius: 24px; aspect-ratio: var(--ar, 1044 / 2214);
  object-fit: cover; object-position: top; background: #fff;
}

.zoomable { cursor: zoom-in; }

/* ---------- facts strip ---------- */
.facts { background: var(--band); color: var(--band-fg); border-top: 1px solid var(--band-line); }
.facts ul { list-style: none; margin-block: 0; margin-inline: auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0; padding-block: 0; }
.facts li { padding: 1.2rem 1rem 1.3rem 0; border-right: 1px solid var(--band-line); display: grid; gap: .2rem; }
.facts li:last-child { border-right: 0; }
.facts li + li { padding-left: 1.25rem; }
.facts b { font: 600 .98rem/1.3 var(--f-body); }
.facts span { color: var(--band-muted); font-size: .88rem; }
@media (max-width: 640px) { .facts li, .facts li + li { border-right: 0; border-bottom: 1px solid var(--band-line); padding-right: 0; padding-left: 0; } .facts li:last-child { border-bottom: 0; } }

/* ---------- sections ---------- */
section { padding-block: clamp(4rem, 3rem + 4vw, 7rem); }
.section-head { display: grid; gap: 1rem; max-width: 46rem; margin-bottom: clamp(2rem, 1.5rem + 2vw, 3.5rem); }
.section-head p { color: var(--muted); font-size: var(--step-1); }

/* trace: el recorrido de un reclamo */
.trace { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; counter-reset: t; }
@media (min-width: 900px) { .trace { grid-template-columns: repeat(5, 1fr); } }
.trace li {
  position: relative; padding: 1.5rem 1.25rem 1.5rem 0; display: grid; gap: .6rem; align-content: start;
  border-top: 2px solid var(--line); min-width: 0;
}
.trace li::before {
  content: ""; position: absolute; top: -7px; left: 0; width: 12px; height: 12px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--teal);
}
.trace li:last-child::before { background: var(--teal); }
.trace .tag {
  font: 500 .74rem/1.2 var(--f-mono); color: var(--muted); background: var(--surface);
  border: 1px solid var(--line); border-radius: 6px; padding: .3rem .5rem; justify-self: start;
  max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.trace p { color: var(--muted); font-size: .95rem; }
@media (max-width: 899px) {
  .trace li { border-top: 0; border-left: 2px solid var(--line); padding: 0 0 1.75rem 1.5rem; }
  .trace li::before { top: 2px; left: -7px; }
}

/* feature blocks */
.feature { display: grid; gap: clamp(2rem, 1rem + 3vw, 4rem); align-items: center; }
.feature + .feature { margin-top: clamp(4.5rem, 3rem + 5vw, 8rem); }
@media (min-width: 960px) {
  .feature { grid-template-columns: 5fr 7fr; }
  .feature.flip { grid-template-columns: 7fr 5fr; }
  .feature.flip .feature-copy { order: 2; }
}
.feature-copy { display: grid; gap: 1.1rem; align-content: start; min-width: 0; }
.feature-copy > p { color: var(--muted); font-size: 1.05rem; }
.feature-media { min-width: 0; }
.checks { list-style: none; margin: .4rem 0 0; padding: 0; display: grid; gap: .6rem; }
.checks li { position: relative; padding-left: 1.6rem; font-size: .97rem; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .45em; width: .85rem; height: .5rem;
  border-left: 2px solid var(--teal); border-bottom: 2px solid var(--teal); transform: rotate(-45deg) translateY(-2px);
}
.note { font-size: .88rem; color: var(--muted); border-left: 2px solid var(--line); padding-left: .9rem; }

/* fila de teléfonos con leyenda */
.phones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(.75rem, 2vw, 1.5rem); align-items: start; }
.phones.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.phones figure { margin: 0; display: grid; gap: .7rem; min-width: 0; }
.phones figcaption { font-size: .85rem; color: var(--muted); text-align: center; }
.phones figure:nth-child(2) { margin-top: 2.2rem; }
.phones.four figure:nth-child(4) { margin-top: 2.2rem; }
@media (max-width: 640px) {
  .phones, .phones.four {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: .75rem;
    margin-inline: -16px; padding-inline: 16px; scrollbar-width: thin;
  }
  .phones figure { flex: 0 0 62%; scroll-snap-align: center; margin-top: 0 !important; }
}

/* ahorro con la Oficina Virtual */
.savings {
  margin-top: clamp(4.5rem, 3rem + 5vw, 8rem);
  background: var(--band); color: var(--band-fg); border-radius: 20px;
  padding: clamp(1.5rem, 1rem + 3vw, 3.5rem);
  display: grid; gap: clamp(2rem, 1rem + 3vw, 3.5rem); align-items: start;
}
@media (min-width: 980px) { .savings { grid-template-columns: 1fr 1fr; } }
.savings + .feature { margin-top: clamp(4.5rem, 3rem + 5vw, 8rem); }
.savings-copy { display: grid; gap: 1.1rem; min-width: 0; }
.savings-copy .eyebrow { color: var(--signal); }
.savings-copy h2 { font-size: clamp(1.7rem, 1.3rem + 1.6vw, 2.4rem); }
.savings-copy > p { color: var(--band-muted); font-size: 1.05rem; }
.savings-points { margin: .5rem 0 0; display: grid; gap: 1rem; }
.savings-points div { border-left: 2px solid var(--signal); padding-left: 1rem; }
.savings-points dt { font-weight: 600; }
.savings-points dd { margin: .15rem 0 0; color: var(--band-muted); font-size: .95rem; }
.calc {
  background: var(--band-2); border: 1px solid var(--band-line); border-radius: var(--radius);
  padding: clamp(1.1rem, .9rem + 1vw, 1.75rem); display: grid; gap: 1rem; min-width: 0;
}
.calc h3 { font-size: 1.25rem; }
.calc-note { color: var(--band-muted); font-size: .82rem; }
.calc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .85rem 1rem; }
@media (max-width: 480px) { .calc-grid { grid-template-columns: 1fr; } .calc-out div { flex-direction: column; align-items: flex-start; gap: .25rem; } }
.calc .field input { font-variant-numeric: tabular-nums; min-height: 42px; }
.calc-out { display: grid; gap: .6rem; border-top: 1px solid var(--band-line); padding-top: 1rem; }
.calc-out div { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.calc-out span { color: var(--band-muted); font-size: .92rem; }
.calc-out b { font: 600 1.05rem/1.2 var(--f-mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.calc-total { margin-top: .3rem; padding: .9rem 1rem; border-radius: 10px; background: color-mix(in srgb, var(--signal) 14%, transparent); }
.calc-total span { color: var(--band-fg); font-weight: 600; }
.calc-total b { font: 750 clamp(1.4rem, 1.1rem + 1vw, 1.9rem)/1 var(--f-display); font-stretch: 112%; color: var(--signal); }

/* composición técnico: video + pantalla */
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1rem, 3vw, 2rem); align-items: end; max-width: 620px; margin-inline: auto; }
.duo figure { margin: 0; display: grid; gap: .7rem; min-width: 0; }
.duo figcaption { font-size: .85rem; color: var(--muted); text-align: center; }
.duo figure:first-child { margin-bottom: 2.5rem; }

/* morosos: tablero + panel de visitas */
.stack { position: relative; padding-block: 1.5rem 2.5rem; }
.stack .browser { width: 84%; }
.stack .floating {
  position: absolute; right: 0; bottom: 0; width: min(34%, 240px);
  border-radius: 12px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--surface);
}
.stack .floating img { width: 100%; height: auto; }
@media (max-width: 640px) { .stack { padding-block: 0; } .stack .browser { width: 100%; } .stack .floating { position: relative; width: 62%; margin: -2.5rem 0 0 auto; } }

.kv { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-top: .5rem; }
.kv div { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: .8rem .9rem; display: grid; gap: .15rem; }
.kv b { font: 600 .95rem/1.25 var(--f-body); }
.kv span { font-size: .84rem; color: var(--muted); }

/* panel: más módulos */
.also { border-top: 1px solid var(--line); margin-top: clamp(4rem, 3rem + 4vw, 7rem); padding-top: 2rem; display: grid; gap: 1rem; }
.also ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .5rem; }
.also li { font-size: .92rem; border: 1px solid var(--line); background: var(--surface); border-radius: 999px; padding: .4rem .85rem; }

/* implementación */
.alt { background: var(--surface); border-block: 1px solid var(--line); }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.5rem; counter-reset: s; }
@media (min-width: 860px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 2.5rem; } }
.steps li { counter-increment: s; display: grid; gap: .6rem; align-content: start; }
.steps li::before {
  content: counter(s, decimal-leading-zero); font: 500 .8rem/1 var(--f-mono); color: var(--teal);
  border: 1px solid var(--teal); border-radius: 6px; padding: .35rem .5rem; justify-self: start;
}
.steps p { color: var(--muted); }

/* faq */
.faq { display: grid; gap: 0; border-top: 1px solid var(--line); max-width: 52rem; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: 1.15rem 2.5rem 1.15rem 0; position: relative;
  font: 600 1.06rem/1.4 var(--f-body);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: .4rem; top: 1.45rem; width: .6rem; height: .6rem;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform .2s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); top: 1.7rem; }
.faq details p { padding: 0 0 1.25rem; color: var(--muted); max-width: 44rem; }

/* contacto */
.contact { background: var(--band); color: var(--band-fg); }
.contact .wrap { display: grid; gap: 3rem; }
@media (min-width: 960px) { .contact .wrap { grid-template-columns: 5fr 7fr; } }
.contact-copy { display: grid; gap: 1.1rem; align-content: start; }
.contact-copy p { color: var(--band-muted); font-size: var(--step-1); }
.contact .eyebrow { color: var(--signal); }
.contact-direct { margin-top: .5rem; display: grid; gap: .5rem; font-size: .95rem; color: var(--band-muted); }
.contact-direct a { color: var(--band-fg); }
form.lead {
  background: var(--band-2); border: 1px solid var(--band-line); border-radius: var(--radius);
  padding: clamp(1.25rem, 1rem + 1.5vw, 2rem); display: grid; gap: 1rem; grid-template-columns: 1fr 1fr; min-width: 0;
}
.field { display: grid; gap: .4rem; min-width: 0; }
.field.full { grid-column: 1 / -1; }
@media (max-width: 560px) { form.lead { grid-template-columns: 1fr; } }
.field label { font-size: .85rem; color: var(--band-muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 46px; border-radius: 9px; border: 1px solid var(--band-line);
  background: var(--band); color: var(--band-fg); font: 400 1rem/1.4 var(--f-body); padding: .65rem .8rem;
  color-scheme: dark;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--signal); outline-offset: 0; border-color: transparent; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
.form-foot small { color: var(--band-muted); font-size: .8rem; flex: 1 1 220px; }
.form-status { grid-column: 1 / -1; font-size: .95rem; border-radius: 9px; padding: .8rem 1rem; }
.form-status.ok { background: color-mix(in srgb, var(--signal) 16%, transparent); color: var(--band-fg); border: 1px solid var(--signal); }
.form-status.err { background: color-mix(in srgb, #F0614B 16%, transparent); color: var(--band-fg); border: 1px solid #F0614B; }

/* footer */
.site-footer { background: var(--band); color: var(--band-muted); border-top: 1px solid var(--band-line); font-size: .88rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; padding-block: 2rem calc(2rem + env(safe-area-inset-bottom, 0px)); }
.site-footer .brand-word { font-size: 1.05rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 1.25rem; margin-left: auto; }
.site-footer a { color: var(--band-muted); text-decoration: none; }
.site-footer a:hover { color: var(--band-fg); }

/* lightbox */
dialog.lightbox {
  border: 0; padding: 0; background: transparent; max-width: min(96vw, 1600px); max-height: 94vh; overflow: visible;
}
dialog.lightbox::backdrop { background: rgb(5 10 18 / .86); }
dialog.lightbox img { max-height: 88vh; width: auto; max-width: 100%; border-radius: 10px; margin-inline: auto; }
dialog.lightbox p { color: #E9EEF5; text-align: center; font-size: .9rem; margin-top: .75rem; }
dialog.lightbox button {
  position: absolute; top: -14px; right: -14px; width: 40px; height: 40px; border-radius: 50%; border: 0;
  background: #fff; color: #0D1726; font-size: 1.3rem; cursor: pointer; line-height: 1;
}

@media (prefers-reduced-motion: reduce) { .btn, .faq summary::after { transition: none; } .btn:hover { transform: none; } }
