/* ============================================================
   GEISIS — Sistemas de Gestión y Contabilidad
   Dirección: "Circuito impreso" — design-system/geisis/MASTER.md
   Sin build. Sin dependencias. Un archivo.
   ============================================================ */

/* ---------- Fuentes autoalojadas (variables, subset latin) ---------- */
@font-face {
  font-family: 'Space Grotesk';
  src: url('../fonts/space-grotesk-var.woff2') format('woff2-variations');
  font-weight: 300 700;
  font-display: swap;
}
@font-face {
  font-family: 'Inter';
  src: url('../fonts/inter-var.woff2') format('woff2-variations');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'JetBrains Mono';
  src: url('../fonts/jetbrains-mono-var.woff2') format('woff2-variations');
  font-weight: 100 800;
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --brand-blue: #0564FF;
  --brand-navy: #0C1B30;

  --blue-100: #E4EEFF;
  --blue-200: #C2D9FF;
  --blue-300: #7FB2FF;
  --blue-500: #0564FF;
  --blue-700: #0344B3;

  --ink-950: #0C1B30;
  --ink-800: #1B2C46;
  --ink-700: #2C3E5C;
  --ink-500: #475569;
  --ink-400: #94A3B8;
  --ink-200: #DDE5F0;
  --ink-100: #EDF2F9;
  --ink-050: #F5F8FD;
  --white:   #FFFFFF;

  --wa-green: #25D366;
  --wa-green-dark: #1EBE5A;

  --ok:   #16A34A;      /* solo puntos/superficies, no texto chico */
  --warn: #D97706;      /* solo puntos/superficies, no texto chico */
  --ok-text:   #15803D; /* 4.5:1 sobre blanco */
  --warn-text: #B45309; /* 4.5:1 sobre blanco */

  --bg:            var(--ink-050);
  --bg-elevated:   var(--white);
  --bg-inverse:    var(--brand-navy);
  --text:          var(--ink-950);
  --text-muted:    var(--ink-500);
  --text-inverse:  var(--white);
  --text-inverse-muted: var(--ink-400);
  --border:        var(--ink-200);
  --border-inverse: rgba(255,255,255,.12);
  --accent:        var(--brand-blue);
  --accent-on-dark: var(--blue-300);

  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body:    'Inter', system-ui, -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', ui-monospace, 'SF Mono', monospace;

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-pill: 999px;

  --container: 1160px;
  --container-narrow: 720px;

  --shadow-sm: 0 1px 2px rgba(12,27,48,.06), 0 1px 3px rgba(12,27,48,.08);
  --shadow-md: 0 4px 12px rgba(12,27,48,.08), 0 2px 4px rgba(12,27,48,.04);
  --shadow-lg: 0 24px 48px -12px rgba(12,27,48,.18);
  --shadow-glow: 0 0 64px rgba(5,100,255,.28);

  --ease-out: cubic-bezier(.2,.7,.3,1);

  --section-y: clamp(64px, 10vw, 112px);
}

/* ---------- Reset y base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

html { overflow-x: clip; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-x: clip;
}

img, svg { display: block; max-width: 100%; }

h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }

a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }

/* Superficies del navegador — también son diseño */
::selection { background: var(--brand-blue); color: var(--white); }
html { scrollbar-color: var(--ink-400) var(--ink-100); }
body::-webkit-scrollbar { width: 10px; }
body::-webkit-scrollbar-track { background: var(--ink-100); }
body::-webkit-scrollbar-thumb { background: var(--ink-400); border-radius: 5px; }

:focus-visible {
  outline: 3px solid var(--brand-blue);
  outline-offset: 3px;
  border-radius: 2px;
}

.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(20px, 4vw, 32px);
}

/* Accesibilidad: saltar al contenido */
.skip-link {
  position: absolute;
  top: -48px; left: 16px;
  z-index: 100;
  padding: 10px 18px;
  background: var(--brand-navy);
  color: var(--white);
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
  transition: top .2s var(--ease-out);
}
.skip-link:focus { top: 0; }

/* ---------- Revelado al scroll (solo si hay JS) ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .42s var(--ease-out), transform .42s var(--ease-out);
  transition-delay: calc(var(--i, 0) * 60ms);
}
.js .reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ============================================================
   Botones
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 26px;
  border-radius: var(--radius-pill);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform .18s var(--ease-out), box-shadow .18s var(--ease-out),
              background-color .18s var(--ease-out), border-color .18s var(--ease-out);
}
.btn svg { flex: 0 0 auto; }

/* El verde significa una sola cosa: abrir WhatsApp. Texto navy, nunca blanco. */
.btn-wa {
  background: var(--wa-green);
  color: var(--brand-navy);
}
.btn-wa:hover { background: var(--wa-green-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-wa:active { transform: translateY(0); }

.btn-lg { min-height: 56px; padding: 16px 34px; font-size: 17px; }

/* ============================================================
   Marquesina superior
   ============================================================ */
/* Banda entre el hero y el cuerpo — se va con el scroll */
.topbar {
  overflow: hidden;
  background: #0C2449; /* navy + tinte azul, sólido */
  border-top: 1px solid var(--border-inverse);
  border-bottom: 1px solid var(--border-inverse);
}
.topbar-track {
  display: flex;
  width: max-content;
  animation: tb-marquee 48s linear infinite;
}
.topbar:hover .topbar-track { animation-play-state: paused; }
.topbar-list {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 16px 0;
  list-style: none;
}
.topbar-list li {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: 26px;
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.85);
  white-space: nowrap;
}
.topbar-list .tb-hi { color: var(--accent-on-dark); font-weight: 700; }
.tb-dot {
  width: 5px; height: 5px;
  border: 1.5px solid var(--brand-blue);
  border-radius: 50%;
  flex: 0 0 auto;
}
@keyframes tb-marquee {
  to { transform: translateX(-50%); }
}
@media (prefers-reduced-motion: reduce) {
  .topbar-track { animation: none; }
}

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--brand-navy);
  transition: background-color .25s var(--ease-out), box-shadow .25s var(--ease-out),
              border-color .25s var(--ease-out);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  background: rgba(12,27,48,.9);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--border-inverse);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 68px;
}
.logo-link { display: inline-flex; align-items: center; }
.logo-link img { height: 34px; width: auto; }
@media (min-width: 1024px) {
  .logo-link img { height: 42px; }
}

.site-nav { display: flex; align-items: center; gap: 6px; }
.site-nav a.nav-item {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-inverse-muted);
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  transition: color .18s var(--ease-out);
}
.site-nav a.nav-item:hover { color: var(--white); }

.btn-wa-sm {
  min-height: 40px;
  padding: 8px 18px;
  font-size: 14.5px;
  margin-left: 10px;
}

/* Hamburguesa + menú lateral (solo móvil) */
.nav-toggle {
  display: none;
  width: 44px; height: 44px;
  place-items: center;
  background: transparent;
  border: 0;
  color: var(--white);
  cursor: pointer;
  border-radius: var(--radius-sm);
}
@media (max-width: 767px) {
  .site-nav a.nav-item, .site-nav .btn-wa-sm { display: none; }
  .nav-toggle { display: grid; }
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  z-index: 65;
  background: rgba(12,27,48,.6);
  opacity: 0;
  transition: opacity .25s var(--ease-out);
}
.drawer-backdrop.open { opacity: 1; }

.drawer {
  position: fixed;
  inset: 0 0 0 auto;
  z-index: 70;
  width: min(300px, 84vw);
  background: var(--brand-navy);
  border-left: 1px solid var(--border-inverse);
  padding: 20px 24px calc(24px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform .3s var(--ease-out);
  overflow-y: auto;
}
.drawer.open { transform: translateX(0); }
@media (prefers-reduced-motion: reduce) {
  .drawer, .drawer-backdrop { transition: none; }
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border-inverse);
}
.drawer-head img { height: 26px; width: auto; }
.drawer-close {
  width: 44px; height: 44px;
  display: grid;
  place-items: center;
  background: transparent;
  border: 0;
  color: var(--text-inverse-muted);
  cursor: pointer;
  border-radius: var(--radius-sm);
}
.drawer-close:hover { color: var(--white); }

.drawer-list {
  margin: 10px 0 0;
  flex: 1;
}
.drawer-list a {
  display: block;
  padding: 16px 4px;
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -.01em;
  color: var(--white);
  text-decoration: none;
  border-bottom: 1px solid var(--border-inverse);
}
.drawer-list a:hover { color: var(--accent-on-dark); }

.drawer-wa { margin-top: 24px; width: 100%; }

/* ============================================================
   Hero — navy, glow, trazas de circuito
   ============================================================ */
.hero {
  position: relative;
  background: var(--bg-inverse);
  color: var(--text-inverse);
  padding-top: clamp(44px, 3vw + 32px, 72px);
  overflow: hidden;
  isolation: isolate;
}

/* Glow radial detrás del mockup */
.hero-glow {
  position: absolute;
  z-index: -1;
  top: 8%;
  right: -12%;
  width: 62vw; height: 62vw;
  max-width: 880px; max-height: 880px;
  background: radial-gradient(circle, rgba(5,100,255,.32) 0%, rgba(5,100,255,.10) 42%, transparent 70%);
  pointer-events: none;
}
/* Segundo glow tenue arriba a la izquierda: profundidad, no simetría */
.hero-glow-b {
  position: absolute;
  z-index: -1;
  top: -18%;
  left: -14%;
  width: 44vw; height: 44vw;
  max-width: 560px; max-height: 560px;
  background: radial-gradient(circle, rgba(5,100,255,.14) 0%, transparent 65%);
  pointer-events: none;
}

/* Trazas de circuito de fondo */
.hero-circuit {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.hero-circuit svg { width: 100%; height: 100%; }
.trace {
  fill: none;
  stroke: var(--brand-blue);
  stroke-width: 1.5;
}
.trace-dim { opacity: .22; }
.trace-mid { opacity: .45; }
.trace-node {
  fill: var(--brand-navy);
  stroke: var(--brand-blue);
  stroke-width: 2;
}
.trace-pulse {
  stroke-dasharray: 8 160;
  stroke-linecap: round;
  animation: trace-flow 8s linear infinite;
}
@keyframes trace-flow {
  from { stroke-dashoffset: 0; }
  to   { stroke-dashoffset: -336; }
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 5fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.15rem, 4.6vw + .6rem, 3.4rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -.03em;
}
@media (min-width: 768px) {
  .hero h1 { text-wrap: balance; line-height: 1.05; }
}
/* Móvil: título compacto en 2 líneas, con "No al revés." continuado */
@media (max-width: 767px) {
  .hero h1 { font-size: clamp(1.5rem, 5.2vw + .35rem, 2.3rem); }
}
.hero h1 .h1-accent {
  color: var(--accent-on-dark);
  white-space: nowrap;
}
.h1-accent { display: inline-block; }

.hero-lede {
  margin-top: 24px;
  max-width: 54ch;
  font-size: clamp(1.06rem, .4vw + 1rem, 1.19rem);
  line-height: 1.6;
  color: var(--text-inverse-muted);
}
@media (max-width: 767px) {
  .hero-lede { font-size: 14px; line-height: 1.55; margin-top: 14px; }
}
@media (min-width: 768px) {
  .hero-lede { font-size: 16.5px; margin-top: 18px; }
}
.hero-lede strong { color: var(--white); font-weight: 600; }

/* Valoración de Google en el hero */
.hero-rating { margin-top: 22px; }
.hr-row {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}
.hr-stars {
  display: inline-flex;
  gap: 2px;
  line-height: 0;
}
.hr-score {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 15px;
  font-weight: 700;
  color: var(--white);
}
.hr-total { font-size: 13.5px; color: var(--text-inverse-muted); }
.hr-row:hover .hr-total { color: var(--accent-on-dark); }

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}
@media (max-width: 767px) {
  .hero-ctas { margin-top: 22px; }
  /* Botón más contenido en pantallas chicas, sin bajar de 48px táctiles */
  .hero-ctas .btn-lg {
    min-height: 50px;
    padding: 13px 26px;
    font-size: 15.5px;
  }
  .hero-ctas .btn-lg svg { width: 18px; height: 18px; }
}

/* ---------- Foto del hero + tarjetas flotantes ---------- */
.mock-wrap { position: relative; }

.hero-photo { position: relative; }
.hero-photo img {
  width: 100%;
  height: auto;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  object-position: 50% 30%;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255,255,255,.14);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
}
/* Tarjetas de cristal navy sobre la foto — datos del sistema, sin mostrar pantalla */
.hero-card {
  position: absolute;
  background: rgba(12,27,48,.74);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,.16);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  color: var(--white);
}
.hero-card-ventas {
  bottom: 30px;
  right: -18px;
  padding: 13px 20px;
  display: grid;
  gap: 2px;
}
.hc-label { font-size: 11.5px; font-weight: 600; color: var(--text-inverse-muted); }
.hc-value {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -.01em;
  /* Ancho fijo: el contador cambia de dígitos sin mover la tarjeta */
  display: inline-block;
  min-width: 14ch;
}
.hc-delta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  color: var(--accent-on-dark);
}
.hero-card-cae {
  top: 26px;
  left: -14px;
  padding: 11px 18px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 13.5px;
  font-weight: 600;
}
.hero-card-cae svg { color: var(--accent-on-dark); flex: 0 0 auto; }

/* Entrada coreografiada: primero la foto, después cada tarjeta.
   Sin JS o con motion reducido queda todo visible desde el arranque. */
@media (prefers-reduced-motion: no-preference) {
  .js .hero-photo img {
    animation: foto-entra .95s cubic-bezier(.16, 1, .3, 1) .1s both;
  }
  .js .hero-card { opacity: 0; will-change: transform, opacity; }
  .js .hero-card-cae {
    animation: hc-entra-izq .75s cubic-bezier(.16, 1, .3, 1) .62s forwards;
  }
  .js .hero-card-ventas {
    animation: hc-entra-der .75s cubic-bezier(.16, 1, .3, 1) .92s forwards;
  }
}
@keyframes foto-entra {
  from { opacity: 0; transform: translate3d(0, 20px, 0) scale(.97); }
  to   { opacity: 1; transform: none; }
}
@keyframes hc-entra-izq {
  from { opacity: 0; transform: translate3d(-14px, 10px, 0) scale(.93); }
  to   { opacity: 1; transform: none; }
}
@keyframes hc-entra-der {
  from { opacity: 0; transform: translate3d(14px, 12px, 0) scale(.93); }
  to   { opacity: 1; transform: none; }
}

@media (max-width: 560px) {
  .hero-card-ventas { right: -6px; bottom: 16px; padding: 11px 16px; }
  .hc-value { font-size: 16px; }
  .hero-card-cae { left: -6px; top: 16px; padding: 9px 14px; font-size: 12.5px; }
}

.mock {
  position: relative;
  background: var(--white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  overflow: hidden;
  font-size: 13px;
  color: var(--ink-950);
  border: 1px solid rgba(255,255,255,.14);
}

.mock-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  background: var(--ink-100);
  border-bottom: 1px solid var(--ink-200);
}
.mock-dots { display: flex; gap: 6px; }
.mock-dots span {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--ink-200);
}
.mock-title {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: var(--ink-500);
}
.mock-badge {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: var(--radius-pill);
  background: var(--blue-100);
  color: var(--blue-700);
  font-size: 11px;
  font-weight: 600;
}
.mock-badge .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-blue); }

.mock-body { padding: 18px; display: grid; gap: 16px; }

.mock-kpi-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}
.mock-kpi-label { font-size: 12px; font-weight: 600; color: var(--ink-500); }
.mock-kpi {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: clamp(20px, 2.2vw, 26px);
  font-weight: 700;
  letter-spacing: -.01em;
}
.mock-kpi-delta {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ok-text);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.mock-kpi-delta svg { flex: 0 0 auto; }

.mock-table { display: grid; gap: 0; border: 1px solid var(--ink-200); border-radius: var(--radius-sm); overflow: hidden; }
.mock-row {
  display: grid;
  grid-template-columns: minmax(72px, auto) minmax(0, 1fr) auto auto;
  gap: 12px;
  align-items: center;
  padding: 9px 12px;
  background: var(--white);
  border-top: 1px solid var(--ink-100);
}
.mock-row:first-child { border-top: 0; }
.mock-row .c-num { font-family: var(--font-mono); font-size: 11px; color: var(--ink-500); font-variant-numeric: tabular-nums; }
.mock-row .c-name { font-weight: 500; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mock-row .c-amount { font-family: var(--font-mono); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; }
.mock-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  font-size: 10.5px;
  font-weight: 600;
  white-space: nowrap;
}
.mock-chip.ok  { background: #E8F7EE; color: #116434; }
.mock-chip.ok .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--ok); }

.mock-cols {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 16px;
}
.mock-panel {
  background: var(--ink-050);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-sm);
  padding: 12px;
}
.mock-panel-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--ink-500);
  margin-bottom: 10px;
}
.mock-stock-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
  font-size: 12px;
}
.mock-stock-row .dot { width: 7px; height: 7px; border-radius: 50%; flex: 0 0 auto; }
.mock-stock-row .dot.warn { background: var(--warn); }
.mock-stock-row .qty { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--ink-500); font-variant-numeric: tabular-nums; }

.mock-chart {
  display: flex;
  align-items: flex-end;
  gap: 7px;
  height: 74px;
  padding-top: 4px;
}
.mock-chart .bar {
  flex: 1;
  border-radius: 3px 3px 0 0;
  background: var(--blue-200);
  min-height: 8px;
}
.mock-chart .bar.hi { background: linear-gradient(180deg, var(--brand-blue), var(--blue-700)); }

.mock-caption {
  margin-top: 12px;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .06em;
  color: var(--text-inverse-muted);
}

/* Traza que entra desde el borde del viewport y ancla un nodo en el mockup */
.mock-trace-in {
  position: absolute;
  top: 24%;
  left: calc(100% - 7px);
  width: 220px;
  height: 72px;
  pointer-events: none;
  z-index: 1;
}
.mock-trace-in svg { width: 100%; height: 100%; overflow: visible; }
@media (max-width: 1023px) {
  .mock-trace-in { display: none; }
}

/* ---------- Franja de confianza (dentro del hero) ---------- */
/* Cristal sobre navy — MASTER §5: glass solo sobre fondo oscuro */
.trust {
  margin-top: clamp(44px, 5.5vw, 64px);
  padding-block: 0 clamp(48px, 6vw, 72px);
}
.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.trust-item {
  flex: 1 1 240px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 15px;
  color: var(--text-inverse-muted);
  background: rgba(255,255,255,.06);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid var(--border-inverse);
  border-radius: var(--radius-md);
  padding: 15px 20px;
}
.trust-item strong { color: var(--white); font-weight: 600; }
.trust-item svg { color: var(--accent-on-dark); flex: 0 0 auto; }

@media (max-width: 1023px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-glow { top: auto; bottom: -10%; right: -30%; width: 90vw; height: 90vw; }
  .mock-wrap { max-width: 640px; }
}
@media (max-width: 560px) {
  .mock-cols { grid-template-columns: minmax(0, 1fr); }
  .mock-row { grid-template-columns: minmax(64px, auto) minmax(0, 1fr) auto; }
  .mock-row .c-amount { display: none; }
  .trust-row { flex-direction: column; gap: 10px; }
  .trust-item { flex-basis: auto; }
}

/* ============================================================
   Secciones claras
   ============================================================ */
.section { padding-block: var(--section-y); scroll-margin-top: 84px; }
.section-alt { background: var(--bg-elevated); }

.section-head { max-width: var(--container-narrow); }
.section-head h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 2.4vw + .8rem, 2.65rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.02em;
  text-wrap: balance;
}
.section-head .lede {
  margin-top: 16px;
  font-size: clamp(1rem, .3vw + .95rem, 1.13rem);
  color: var(--text-muted);
  max-width: 58ch;
}

/* Divisor-traza entre hero y primera sección */
.circuit-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--blue-200) 20%, var(--blue-200) 80%, transparent);
  position: relative;
  max-width: var(--container);
  margin-inline: auto;
}

/* ---------- Bento de funciones ---------- */
.bento {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 20px;
  margin-top: clamp(36px, 5vw, 56px);
}
.bento-card {
  grid-column: span 4;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: clamp(22px, 2.6vw, 30px);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: border-color .22s var(--ease-out), transform .22s var(--ease-out), box-shadow .22s var(--ease-out);
}
.bento-card:hover {
  border-color: var(--blue-200);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.bento-card.span-7 { grid-column: span 7; }
.bento-card.span-5 { grid-column: span 5; }

.bento-icon {
  width: 42px; height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-md);
  background: var(--blue-100);
  color: var(--blue-700);
}
.bento-card h3 {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, .5vw + 1rem, 1.36rem);
  font-weight: 600;
  letter-spacing: -.01em;
}
.bento-card > p { color: var(--text-muted); font-size: 15px; }

.bento-demo {
  margin-top: auto;
  background: var(--ink-050);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  padding: 14px;
  font-size: 12.5px;
}

/* micro-demo: factura */
.demo-fact-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px solid var(--ink-100);
}
.demo-fact-row:first-child { border-top: 0; padding-top: 0; }
.demo-fact-row:last-child { padding-bottom: 0; }
.demo-fact-row .t { font-family: var(--font-mono); font-size: 11px; color: var(--ink-500); font-variant-numeric: tabular-nums; }
.demo-fact-row .n { font-weight: 500; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.demo-fact-row .m { font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums; }

/* micro-demo: cadena ventas→cobro */
.demo-chain {
  font-size: 11px;
  letter-spacing: .04em;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.demo-chain svg { color: var(--brand-blue); flex: 0 0 auto; }

/* micro-demo: saldos */
.demo-saldo {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 0;
  border-top: 1px solid var(--ink-100);
  font-size: 12.5px;
}
.demo-saldo:first-child { border-top: 0; padding-top: 0; }
.demo-saldo:last-child { padding-bottom: 0; }
.demo-saldo .who { font-weight: 500; }
.demo-saldo .val { font-family: var(--font-mono); font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.demo-saldo .val.deb { color: var(--warn-text); }

/* micro-demo: chart */
.demo-chart {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 64px;
}
.demo-chart .bar { flex: 1; border-radius: 3px 3px 0 0; background: var(--blue-200); }
.demo-chart .bar.hi { background: linear-gradient(180deg, var(--brand-blue), var(--blue-700)); }
.demo-chart-caption {
  margin-top: 8px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: .06em;
  color: var(--ink-500);
  display: flex;
  justify-content: space-between;
}

/* CTA sutil hacia WhatsApp dentro de secciones — jerarquía menor al botón verde */
.cta-inline-row { margin-top: 34px; text-align: center; }
.fit-copy .cta-inline-row { text-align: left; margin-top: 28px; }
.cta-inline {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 15.5px;
  color: var(--text);
  text-decoration: none;
  border-bottom: 2px solid var(--blue-200);
  padding-bottom: 3px;
  transition: color .18s var(--ease-out), border-color .18s var(--ease-out);
}
.cta-inline svg { color: var(--wa-green-dark); flex: 0 0 auto; }
.cta-inline:hover { color: var(--blue-700); border-bottom-color: var(--brand-blue); }

@media (max-width: 1023px) {
  .bento-card, .bento-card.span-7, .bento-card.span-5 { grid-column: span 6; }
}
@media (max-width: 719px) {
  .bento { gap: 14px; }
  .bento-card, .bento-card.span-7, .bento-card.span-5 { grid-column: span 12; }
}

/* ============================================================
   A medida — split
   ============================================================ */
.fit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 88px);
  align-items: center;
}
.fit-copy h2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 2.4vw + .8rem, 2.65rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.02em;
  text-wrap: balance;
}
.fit-copy > p {
  margin-top: 16px;
  color: var(--text-muted);
  font-size: clamp(1rem, .3vw + .95rem, 1.13rem);
  max-width: 52ch;
}
.fit-copy > p strong { color: var(--text); }

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 26px;
}
.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}
.chip svg { color: var(--brand-blue); }

/* Escritorio + nube */
.duo {
  position: relative;
  display: grid;
  gap: 16px;
}
.duo-card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.duo-card .bento-icon { flex: 0 0 auto; }
.duo-card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
}
.duo-card p { color: var(--text-muted); font-size: 14.5px; margin-top: 6px; }

/* conector-traza vertical entre las dos tarjetas */
.duo-connector {
  position: relative;
  height: 34px;
  margin-block: -8px;
  z-index: 1;
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.duo-connector svg { height: 100%; overflow: visible; }

@media (max-width: 1023px) {
  .fit-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   Pasos
   ============================================================ */
.steps {
  --steps-gap: clamp(20px, 3vw, 32px);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--steps-gap);
  margin-top: clamp(36px, 5vw, 56px);
}
.step { position: relative; }
/* traza que une cada nodo con el siguiente */
.step:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 20px;
  left: 21px;
  width: calc(100% + var(--steps-gap));
  height: 2px;
  background: var(--blue-200);
}
.step-node {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--bg);
  border: 2px solid var(--brand-blue);
  display: grid;
  place-items: center;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--blue-700);
  position: relative;
  z-index: 1;
}
.step h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  margin-top: 18px;
  letter-spacing: -.01em;
}
.step p { margin-top: 10px; color: var(--text-muted); font-size: 15px; max-width: 34ch; }
.step p strong { color: var(--text); }

.steps-cta {
  margin-top: clamp(36px, 5vw, 52px);
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}
.steps-cta .note { font-size: 14px; color: var(--text-muted); }

@media (max-width: 767px) {
  .steps { --steps-gap: 36px; grid-template-columns: minmax(0, 1fr); }
  .step { padding-left: 62px; min-height: 42px; }
  .step-node { position: absolute; left: 0; top: 0; }
  .step h3 { margin-top: 0; padding-top: 7px; }
  .step:not(:last-child)::after {
    top: 21px;
    left: 20px;
    width: 2px;
    height: calc(100% + var(--steps-gap));
  }
}

/* ============================================================
   Reseñas de Google
   ============================================================ */
.resenas-grid {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.resenas-badge h2 {
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 2vw + .8rem, 2.3rem);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.02em;
  text-wrap: balance;
}
.gbadge {
  margin-top: 22px;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  transition: border-color .22s var(--ease-out), transform .22s var(--ease-out), box-shadow .22s var(--ease-out);
}
.gbadge:hover { border-color: var(--blue-200); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.gbadge-score {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
}
.gbadge-total { font-size: 13.5px; color: var(--text-muted); }
.gbadge-note { margin-top: 14px; font-size: 13.5px; color: var(--text-muted); max-width: 34ch; }

.resenas-list { display: grid; gap: 16px; }
.resena {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 26px;
  box-shadow: var(--shadow-sm);
}
.resena-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}
.resena-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--blue-100);
  color: var(--blue-700);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  flex: 0 0 auto;
  overflow: hidden;
}
.resena-avatar.con-foto { background: var(--ink-100); }
.resena-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.resena-quien { min-width: 0; }
.resena-nombre { font-weight: 600; font-size: 15px; }
.resena-fecha { font-size: 12.5px; color: var(--text-muted); }
.resena .hr-stars { margin-left: auto; }
.resena-texto { color: var(--ink-700); font-size: 15px; line-height: 1.6; }
.resena-texto.sin-texto { color: var(--text-muted); font-style: italic; }
.resena-vacia { border-style: dashed; box-shadow: none; background: transparent; }
.resena-vacia .resena-texto { font-size: 16px; }
.resena-vacia-nota { margin-top: 8px; font-size: 14px; color: var(--text-muted); }
.resena-vacia-nota a { color: var(--blue-700); }

@media (max-width: 1023px) {
  .resenas-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ============================================================
   FAQ
   ============================================================ */
.faq-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(28px, 4vw, 44px) 72px; }
@media (min-width: 1024px) {
  .faq-grid { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); align-items: start; }
  .faq-grid .faq-list { margin-top: 0; }
}
.faq-list {
  max-width: var(--container-narrow);
  border-top: 1px solid var(--border);
}
.faq-item { border-bottom: 1px solid var(--border); }
.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 4px;
  cursor: pointer;
  list-style: none;
  font-family: var(--font-display);
  font-size: clamp(1.05rem, .4vw + .95rem, 1.2rem);
  font-weight: 600;
  letter-spacing: -.01em;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary:hover { color: var(--blue-700); }
.faq-marker {
  flex: 0 0 auto;
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: grid;
  place-items: center;
  color: var(--ink-500);
  transition: transform .25s var(--ease-out), border-color .25s var(--ease-out), color .25s var(--ease-out);
}
.faq-item[open] .faq-marker {
  transform: rotate(45deg);
  border-color: var(--brand-blue);
  color: var(--brand-blue);
}
.faq-body {
  padding: 0 4px 24px;
  color: var(--text-muted);
  max-width: 62ch;
}
.faq-body strong { color: var(--text); }

/* ============================================================
   Cierre — navy
   ============================================================ */
.closing {
  background: var(--bg-inverse);
  color: var(--text-inverse);
  position: relative;
  overflow: hidden;
  isolation: isolate;
}
.closing-glow {
  position: absolute;
  z-index: -1;
  bottom: -40%;
  left: 50%;
  transform: translateX(-50%);
  width: 80vw; height: 60vw;
  max-width: 1000px; max-height: 700px;
  background: radial-gradient(ellipse, rgba(5,100,255,.26) 0%, transparent 65%);
  pointer-events: none;
}
.closing-circuit {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}
.closing-inner {
  padding-block: var(--section-y);
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.closing h2 {
  font-family: var(--font-display);
  font-size: clamp(2rem, 3.4vw + .8rem, 3.35rem);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -.025em;
  max-width: 22ch;
  text-wrap: balance;
}
.closing .lede {
  margin-top: 18px;
  font-size: clamp(1.02rem, .3vw + 1rem, 1.16rem);
  color: var(--text-inverse-muted);
  max-width: 52ch;
}
.closing-ctas {
  margin-top: 36px;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: center;
}
.closing-place {
  margin-top: 30px;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--text-inverse-muted);
  font-size: 15px;
}
.closing-place a {
  color: var(--accent-on-dark);
  text-decoration: none;
  transition: color .18s var(--ease-out);
}
.closing-place a:hover { color: var(--white); }
.closing-place svg { color: var(--accent-on-dark); flex: 0 0 auto; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  background: var(--bg-inverse);
  color: var(--text-inverse-muted);
  border-top: 1px solid var(--border-inverse);
  padding-block: 40px;
  font-size: 14px;
}
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  align-items: center;
  justify-content: space-between;
}
.footer-brand { display: flex; flex-direction: column; gap: 10px; }
.footer-brand img { height: 28px; width: auto; }
.footer-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--text-inverse-muted);
}
.footer-meta { display: flex; flex-direction: column; gap: 6px; }
.footer-meta a {
  color: var(--text-inverse-muted);
  text-decoration: none;
  transition: color .18s var(--ease-out);
}
.footer-meta a:hover { color: var(--accent-on-dark); }
.footer-meta a[href*="wa.me"] { color: var(--accent-on-dark); }
.footer-meta a[href*="wa.me"]:hover { color: var(--white); }
.footer-legal { width: 100%; padding-top: 22px; border-top: 1px solid var(--border-inverse); font-size: 13px; }

/* ============================================================
   Botón flotante de WhatsApp (móvil / tablet)
   ============================================================ */
.wa-float {
  position: fixed;
  right: 16px;
  bottom: max(16px, env(safe-area-inset-bottom));
  z-index: 60;
  width: 56px; height: 56px;
  border-radius: 50%;
  background: var(--wa-green);
  color: var(--brand-navy);
  display: none;
  place-items: center;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  transform: scale(.9);
  transition: opacity .25s var(--ease-out), transform .25s var(--ease-out), background-color .18s var(--ease-out);
  pointer-events: none;
}
.wa-float.visible { opacity: 1; transform: scale(1); pointer-events: auto; }
.wa-float:hover { background: var(--wa-green-dark); }
@media (max-width: 1023px) {
  .wa-float { display: grid; }
}
