/* ============================================================
   Argumentum — web pública (landing + legales)
   Dark-first, paleta de marca (#4f46e5 · #0c94b5 · #12152b)
   Tema compartido con el panel: localStorage "argumentum-tema"
   ============================================================ */

/* ---------- fuentes self-hosted (sin terceros: RGPD/LSSI) ---------- */
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/pjs-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/pjs-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/pjs-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Plus Jakarta Sans"; src: url("../fonts/pjs-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }

/* ---------- tokens (dark por defecto) ---------- */
:root {
  --bg: #0a0d1e;
  --bg-2: #0e1126;
  --surface: rgba(21, 25, 48, 0.66);
  --surface-solid: #151930;
  --surface-2: rgba(255, 255, 255, 0.04);
  --border: rgba(148, 156, 210, 0.16);
  --border-strong: rgba(148, 156, 210, 0.3);
  --text: #ecedfa;
  --text-soft: #c6cbe6;
  --muted: #9aa2c5;
  --faint: #6b7398;
  --accent: #6d71f9;
  --accent-2: #9a63f8;
  --accent-3: #22d3ee;
  --grad: linear-gradient(92deg, #818cf8 0%, #a78bfa 45%, #22d3ee 100%);
  --grad-btn: linear-gradient(135deg, #5b5ff3 0%, #7c5cf6 55%, #9333ea 100%);
  --ok: #34d399;
  --warn: #fbbf24;
  --danger: #f87171;
  --glow: 0 0 0 1px rgba(129, 140, 248, 0.22), 0 18px 60px -18px rgba(99, 102, 241, 0.55);
  --shadow: 0 24px 70px -28px rgba(2, 4, 18, 0.9);
  --radius: 18px;
  --radius-sm: 12px;
  --nav-h: 72px;
  --font-head: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: dark;
}

[data-theme="claro"] {
  --bg: #f5f6fc;
  --bg-2: #eef0fa;
  --surface: rgba(255, 255, 255, 0.86);
  --surface-solid: #ffffff;
  --surface-2: rgba(18, 21, 43, 0.035);
  --border: rgba(18, 21, 43, 0.1);
  --border-strong: rgba(18, 21, 43, 0.2);
  --text: #14172c;
  --text-soft: #33384f;
  --muted: #5b6280;
  --faint: #8f96b4;
  --accent: #4f46e5;
  --accent-2: #7c3aed;
  --accent-3: #0c94b5;
  --glow: 0 0 0 1px rgba(79, 70, 229, 0.16), 0 18px 50px -20px rgba(79, 70, 229, 0.35);
  --shadow: 0 24px 60px -30px rgba(18, 21, 43, 0.25);
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; } /* el banner/modal no deben asomar aunque su clase fije display */
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 16px); }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background 0.25s ease, color 0.25s ease;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, h4 { font-family: var(--font-head); letter-spacing: -0.025em; line-height: 1.12; margin: 0; }
p { margin: 0; }
button { font-family: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 28px; }
.narrow { max-width: 860px; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 0 22px; height: 46px; border-radius: 12px;
  font-family: var(--font-head); font-weight: 600; font-size: 15px;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease, border-color 0.16s ease;
  white-space: nowrap;
}
.btn svg { width: 17px; height: 17px; flex: none; }
.btn.primary {
  color: #fff; background: var(--grad-btn);
  box-shadow: 0 10px 26px -10px rgba(110, 84, 240, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.18);
}
.btn.primary:hover { transform: translateY(-2px); box-shadow: 0 16px 34px -12px rgba(110, 84, 240, 0.85), inset 0 1px 0 rgba(255, 255, 255, 0.18); }
.btn.ghost {
  color: var(--text); background: var(--surface-2);
  border-color: var(--border-strong);
  backdrop-filter: blur(6px);
}
[data-theme="claro"] .btn.ghost { background: #fff; }
.btn.ghost:hover { border-color: var(--accent); transform: translateY(-2px); }
.btn.lg { height: 54px; padding: 0 30px; font-size: 16px; border-radius: 14px; }
.btn.sm { height: 40px; padding: 0 16px; font-size: 14px; border-radius: 10px; }
.icon-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 10px; cursor: pointer;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text-soft);
  transition: color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}
.icon-btn:hover { color: var(--text); border-color: var(--accent); transform: translateY(-1px); }
.icon-btn svg { width: 18px; height: 18px; }
/* en oscuro se ofrece el sol (paso a claro) y viceversa: solo se ve un icono */
html:not([data-theme="claro"]) .icon-moon { display: none; }
[data-theme="claro"] .icon-sun { display: none; }

/* ---------- cabecera ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 90;
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  border-bottom: 1px solid transparent;
}
.nav.scrolled, .nav.solid {
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  border-bottom-color: var(--border);
}
.nav.scrolled { box-shadow: 0 12px 40px -22px rgba(2, 4, 18, 0.8); }
.nav-in {
  max-width: 1180px; margin: 0 auto; padding: 0 28px; height: var(--nav-h);
  display: flex; align-items: center; gap: 26px;
}
.brand { display: inline-flex; align-items: center; text-decoration: none; flex: none; }
.brand img { height: 32px; width: auto; }
[data-theme="claro"] .brand img[data-dark] { display: none; }
html:not([data-theme="claro"]) .brand img[data-light] { display: none; }
.nav-links { display: flex; align-items: center; gap: 4px; margin: 0 auto; }
.nav-links a {
  text-decoration: none; color: var(--muted); font-size: 14.5px; font-weight: 500;
  padding: 9px 13px; border-radius: 9px; transition: color 0.15s ease, background 0.15s ease;
}
.nav-links a:hover { color: var(--text); background: var(--surface-2); }
.nav-actions { display: flex; align-items: center; gap: 10px; flex: none; }
.menu-btn { display: none; }
.mobile-menu {
  display: none; flex-direction: column; gap: 2px; padding: 10px 20px 18px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
}
.mobile-menu a { text-decoration: none; color: var(--text-soft); font-weight: 500; padding: 12px 12px; border-radius: 10px; }
.mobile-menu a:hover { background: var(--surface-2); }
.mobile-menu .btn { margin-top: 10px; }
.mobile-menu.open { display: flex; }

/* ---------- hero ---------- */
.hero { position: relative; padding: calc(var(--nav-h) + 74px) 0 30px; overflow: clip; }
.hero-bg { position: absolute; inset: 0; pointer-events: none; z-index: -1; }
.hero-bg::before {
  content: ""; position: absolute; inset: -20% -10% auto;
  height: 80%;
  background:
    radial-gradient(52% 55% at 24% 22%, rgba(99, 102, 241, 0.3), transparent 68%),
    radial-gradient(42% 48% at 82% 12%, rgba(34, 211, 238, 0.14), transparent 66%),
    radial-gradient(40% 42% at 60% 60%, rgba(154, 99, 248, 0.14), transparent 70%);
  filter: blur(6px);
}
[data-theme="claro"] .hero-bg::before { opacity: 0.55; }
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(148, 156, 210, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(148, 156, 210, 0.07) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(72% 60% at 50% 18%, #000 30%, transparent 100%);
  mask-image: radial-gradient(72% 60% at 50% 18%, #000 30%, transparent 100%);
}
.hero-grid { display: grid; grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr); gap: 54px; align-items: center; }
.pill {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 15px; border-radius: 999px;
  background: var(--surface-2); border: 1px solid var(--border-strong);
  font-size: 13px; font-weight: 600; color: var(--text-soft);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.16); }
.hero h1 {
  font-size: clamp(38px, 4.6vw, 58px); font-weight: 700;
  margin: 22px 0 18px;
}
.grad {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.lead { font-size: 18.5px; color: var(--muted); max-width: 34em; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; }
.hero-chips { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; padding: 0; margin: 28px 0 0; }
.hero-chips li { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 500; color: var(--muted); }
.hero-chips svg { width: 15px; height: 15px; color: var(--ok); flex: none; }

/* ---------- mockup del producto en el hero ---------- */
.hero-visual { position: relative; }
.mock {
  position: relative;
  background: color-mix(in srgb, var(--surface-solid) 88%, transparent);
  border: 1px solid var(--border-strong);
  border-radius: 20px;
  box-shadow: var(--shadow), var(--glow);
  overflow: hidden;
  font-family: var(--font-body);
  animation: mock-in 0.9s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
@keyframes mock-in { from { opacity: 0; transform: translateY(26px) scale(0.97); } to { opacity: 1; transform: none; } }
.mock-bar {
  display: flex; align-items: center; gap: 7px; padding: 12px 16px;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.02);
}
[data-theme="claro"] .mock-bar { background: rgba(18, 21, 43, 0.03); }
.mock-bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--border-strong); }
.mock-bar i:nth-child(1) { background: #f87171aa; }
.mock-bar i:nth-child(2) { background: #fbbf24aa; }
.mock-bar i:nth-child(3) { background: #34d399aa; }
.mock-bar span { margin-left: 10px; font-size: 12px; color: var(--faint); font-weight: 500; }
.mock-body { display: grid; grid-template-columns: 58px 1fr; }
.mock-side {
  border-right: 1px solid var(--border); padding: 14px 0;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  background: rgba(18, 21, 43, 0.35);
}
[data-theme="claro"] .mock-side { background: rgba(18, 21, 43, 0.045); }
.ms-logo {
  width: 26px; height: 26px; border-radius: 8px; margin-bottom: 6px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  box-shadow: 0 4px 14px -4px rgba(124, 92, 246, 0.8);
}
.ms-item { width: 26px; height: 26px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--border); }
.ms-item.on { background: var(--grad-btn); border-color: transparent; box-shadow: 0 4px 12px -4px rgba(124, 92, 246, 0.9); }
.mock-main { padding: 16px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.mock-kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.mk {
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: 12px; padding: 10px 12px; min-width: 0;
}
.mk small { display: block; font-size: 10.5px; font-weight: 600; letter-spacing: 0.02em; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mk b { display: block; font-family: var(--font-head); font-size: 19px; font-weight: 700; letter-spacing: -0.02em; margin: 3px 0 1px; }
.mk em { font-style: normal; font-size: 10.5px; font-weight: 700; }
.mk em.up { color: var(--ok); }
.mock-panels { display: grid; grid-template-columns: 1.5fr 1fr; gap: 10px; }
.mp { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; min-width: 0; }
.mp small { display: block; font-size: 10.5px; font-weight: 600; color: var(--faint); margin-bottom: 9px; }
.funnel { display: flex; flex-direction: column; gap: 6px; }
.fl {
  --w: 100%;
  position: relative; height: 24px; border-radius: 7px;
  background: var(--surface-2); border: 1px solid var(--border);
  overflow: hidden;
}
.fl::before {
  content: ""; position: absolute; inset: 0;
  width: var(--w);
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.85), rgba(34, 211, 238, 0.55));
  border-radius: inherit;
  transform-origin: left;
  animation: bar-grow 1.1s 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
[data-theme="claro"] .fl::before { background: linear-gradient(90deg, rgba(79, 70, 229, 0.8), rgba(12, 148, 181, 0.55)); }
@keyframes bar-grow { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.fl span, .fl b {
  position: absolute; inset: 0; display: flex; align-items: center;
  font-size: 11px; font-weight: 600;
}
.fl span { padding-left: 10px; color: #fff; text-shadow: 0 1px 3px rgba(10, 12, 30, 0.7); }
[data-theme="claro"] .fl span { color: #fff; }
.fl b { justify-content: flex-end; padding-right: 10px; color: var(--text-soft); }
.ring {
  --p: 76;
  width: 74px; height: 74px; border-radius: 50%;
  margin: 2px auto 8px;
  display: grid; place-items: center;
  background: conic-gradient(#6d71f9 calc(var(--p) * 1%), rgba(148, 156, 210, 0.18) 0);
}
[data-theme="claro"] .ring { background: conic-gradient(#4f46e5 calc(var(--p) * 1%), rgba(18, 21, 43, 0.1) 0); }
.ring::before { content: ""; position: absolute; width: 56px; height: 56px; border-radius: 50%; background: var(--surface-solid); }
.ring b { position: relative; font-family: var(--font-head); font-size: 19px; }
.ring-wrap { text-align: center; }
.tag { display: inline-flex; align-items: center; gap: 5px; font-size: 10.5px; font-weight: 700; padding: 3px 9px; border-radius: 999px; }
.tag.ok { color: var(--ok); background: rgba(52, 211, 153, 0.12); }
.spark { grid-column: 1 / -1; }
.spark svg { width: 100%; height: 64px; display: block; }
.spark .area { fill: url(#sparkFill); stroke: none; opacity: 0.5; }
.spark .line { fill: none; stroke: #818cf8; stroke-width: 2.4; stroke-linecap: round; }
[data-theme="claro"] .spark .line { stroke: #4f46e5; }
.g-row { display: flex; align-items: center; gap: 9px; padding: 6px 0; border-top: 1px solid var(--border); font-size: 11.5px; font-weight: 500; color: var(--text-soft); }
.g-row:first-of-type { border-top: 0; padding-top: 0; }
.g-row .g-dot { width: 8px; height: 8px; border-radius: 3px; background: var(--grad); flex: none; }
.g-row .g-val { margin-left: auto; color: var(--faint); font-weight: 600; }
.g-toggle { margin-left: auto; width: 26px; height: 15px; border-radius: 999px; background: var(--grad-btn); position: relative; flex: none; }
.g-toggle::after { content: ""; position: absolute; top: 2px; right: 2px; width: 11px; height: 11px; border-radius: 50%; background: #fff; }

/* chips flotantes sobre el mockup */
.chip {
  position: absolute; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-radius: 12px;
  background: color-mix(in srgb, var(--surface-solid) 86%, transparent);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow);
  font-size: 12.5px; font-weight: 600; color: var(--text-soft);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  animation: chip-float 6s ease-in-out infinite;
}
.chip .ico { display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 8px; background: var(--grad-btn); color: #fff; flex: none; }
.chip .ico svg { width: 13px; height: 13px; }
.chip small { display: block; font-size: 10.5px; color: var(--faint); font-weight: 500; }
.chip.c1 { top: -18px; right: 8%; }
.chip.c2 { bottom: 10%; left: -26px; animation-delay: -2s; }
.chip.c3 { bottom: 20%; right: -20px; animation-delay: -4s; }
@keyframes chip-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ---------- banda de stats ---------- */
.stats-band {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px;
  margin-top: 64px;
}
.stat {
  text-align: center; padding: 22px 14px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.stat b { display: block; font-family: var(--font-head); font-size: 30px; font-weight: 700; letter-spacing: -0.03em; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat span { font-size: 13px; color: var(--muted); font-weight: 500; }

/* ---------- secciones ---------- */
section { position: relative; }
.sec { padding: 108px 0 0; }
.sec-head { max-width: 640px; margin-bottom: 52px; }
.sec-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-head); font-size: 12.5px; font-weight: 700;
  letter-spacing: 0.14em; text-transform: uppercase;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  margin-bottom: 14px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--grad); }
.sec-head.center .eyebrow::after { content: ""; width: 22px; height: 2px; border-radius: 2px; background: var(--grad); }
.sec-head h2 { font-size: clamp(28px, 3.2vw, 40px); font-weight: 700; }
.sec-head p { color: var(--muted); font-size: 17px; margin-top: 14px; }

/* aparición al hacer scroll */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.2, 0.7, 0.2, 1); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .chip, .fl::before, .org-q i, .mock { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- bento de funcionalidades ---------- */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.b-card {
  grid-column: span 2;
  position: relative; overflow: hidden;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 24px;
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}
.b-card:hover { transform: translateY(-4px); border-color: var(--border-strong); box-shadow: var(--shadow); }
.b-card.wide { grid-column: span 3; }
.b-card.full { grid-column: span 6; }
.b-ico {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px; border-radius: 13px; margin-bottom: 18px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.22), rgba(34, 211, 238, 0.14));
  border: 1px solid rgba(129, 140, 248, 0.3);
  color: var(--accent);
}
[data-theme="claro"] .b-ico { color: #4f46e5; }
.b-ico svg { width: 22px; height: 22px; }
.b-card h3 { font-size: 19px; font-weight: 700; margin-bottom: 9px; }
.b-card p { color: var(--muted); font-size: 14.5px; }
.b-card .b-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 16px; }
.b-tags span { font-size: 12px; font-weight: 600; color: var(--text-soft); background: var(--surface-2); border: 1px solid var(--border); padding: 4px 10px; border-radius: 999px; }
/* gran tarjeta de analítica con visual propio */
.b-card.analytics { display: grid; grid-template-columns: 1fr 0.9fr; gap: 26px; align-items: center; }
.b-visual { position: relative; min-height: 210px; }
.mini-sankey { position: absolute; inset: 0; }
.mini-sankey svg { width: 100%; height: 100%; }
.ms-box { fill: rgba(129, 140, 248, 0.16); stroke: rgba(129, 140, 248, 0.55); rx: 7; }
.ms-box.b { fill: rgba(34, 211, 238, 0.13); stroke: rgba(34, 211, 238, 0.5); }
.ms-flow { fill: none; stroke-linecap: round; opacity: 0.8; }
/* gran tarjeta de plataforma multi-cliente con visual propio */
.b-card.plataforma { display: grid; grid-template-columns: 1fr 0.9fr; gap: 26px; align-items: center; }
.orgs { display: grid; gap: 10px; align-content: center; min-height: 210px; }
.org { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 13px 15px; }
.org-h { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.org-h b { font-family: var(--font-head); font-size: 14px; }
.org-h span { color: var(--faint); font-size: 11.5px; font-weight: 600; }
.org-h .org-susp { color: var(--warn); }
.org-q { margin-top: 9px; height: 7px; border-radius: 999px; background: rgba(148, 156, 210, 0.14); overflow: hidden; }
[data-theme="claro"] .org-q { background: rgba(18, 21, 43, 0.08); }
.org-q i {
  display: block; height: 100%; width: var(--u, 40%);
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.85), rgba(34, 211, 238, 0.55));
  border-radius: inherit;
  transform-origin: left;
  animation: bar-grow 1.1s 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
[data-theme="claro"] .org-q i { background: linear-gradient(90deg, rgba(79, 70, 229, 0.8), rgba(12, 148, 181, 0.55)); }

/* ---------- cómo funciona ---------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: paso; }
.step {
  position: relative; padding: 30px 26px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.step .num {
  display: inline-grid; place-items: center;
  width: 40px; height: 40px; border-radius: 12px; margin-bottom: 18px;
  background: var(--grad-btn); color: #fff;
  font-family: var(--font-head); font-weight: 700; font-size: 17px;
  box-shadow: 0 8px 22px -8px rgba(110, 84, 240, 0.8);
}
.step h3 { font-size: 18px; margin-bottom: 9px; }
.step p { color: var(--muted); font-size: 14.5px; }
.codebox {
  margin-top: 18px;
  background: #0b0e20; border: 1px solid var(--border-strong); border-radius: 14px;
  overflow: hidden;
}
[data-theme="claro"] .codebox { background: #12152b; }
.codebox .cb-bar { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-bottom: 1px solid rgba(148, 156, 210, 0.14); }
.codebox .cb-bar i { width: 9px; height: 9px; border-radius: 50%; background: rgba(148, 156, 210, 0.35); }
.codebox .cb-bar span { margin-left: 6px; font-size: 11.5px; color: #8f96b4; font-weight: 500; }
.codebox pre {
  margin: 0; padding: 16px 18px; overflow-x: auto;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 13px; line-height: 1.7; color: #d6daf3;
}
.codebox .t-tag { color: #7dd3fc; }
.codebox .t-attr { color: #c4b5fd; }
.codebox .t-str { color: #86efac; }
.codebox .t-com { color: #6b7398; }
.copy-btn {
  margin-left: auto; display: inline-flex; align-items: center; gap: 6px;
  background: rgba(255, 255, 255, 0.06); color: #c6cbe6; border: 1px solid rgba(148, 156, 210, 0.25);
  border-radius: 8px; font-size: 11.5px; font-weight: 600; padding: 4px 10px; cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.copy-btn:hover { background: rgba(255, 255, 255, 0.12); color: #fff; }
.copy-btn svg { width: 12px; height: 12px; }

/* ---------- seguridad ---------- */
.sec-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 54px; align-items: center; }
.sec-list { display: grid; gap: 12px; }
.sec-item {
  display: flex; gap: 15px; padding: 18px 20px;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.sec-item .b-ico { width: 38px; height: 38px; border-radius: 11px; margin: 0; flex: none; }
.sec-item .b-ico svg { width: 18px; height: 18px; }
.sec-item b { display: block; font-family: var(--font-head); font-size: 15px; margin-bottom: 3px; }
.sec-item p { color: var(--muted); font-size: 13.5px; }

/* ---------- comparativa ---------- */
.vs { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: stretch; }
.vs-card {
  padding: 30px 28px; border-radius: 22px;
  background: var(--surface); border: 1px solid var(--border);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.vs-card.us {
  position: relative;
  border: 1px solid transparent;
  background:
    linear-gradient(var(--surface-solid), var(--surface-solid)) padding-box,
    var(--grad) border-box;
  box-shadow: var(--glow);
}
.vs-card .vs-tag {
  display: inline-flex; font-size: 11.5px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 5px 11px; border-radius: 999px; margin-bottom: 14px;
}
.vs-card.us .vs-tag { color: #fff; background: var(--grad-btn); }
.vs-card.them .vs-tag { color: var(--muted); background: var(--surface-2); border: 1px solid var(--border); }
.vs-card h3 { font-size: 22px; margin-bottom: 20px; }
.vs-row { display: flex; gap: 12px; align-items: flex-start; padding: 13px 0; border-top: 1px solid var(--border); font-size: 14.5px; }
.vs-row .mark { width: 22px; height: 22px; border-radius: 50%; display: inline-grid; place-items: center; flex: none; margin-top: 1px; }
.vs-row .mark svg { width: 12px; height: 12px; }
.vs-row .mark.yes { background: rgba(52, 211, 153, 0.14); color: var(--ok); }
.vs-row .mark.no { background: rgba(248, 113, 113, 0.13); color: var(--danger); }
.vs-row div b { display: block; font-weight: 600; }
.vs-row div span { color: var(--muted); font-size: 13.5px; }

/* ---------- FAQ ---------- */
.faq { max-width: 780px; margin: 0 auto; display: grid; gap: 12px; }
.faq details {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  overflow: hidden;
  transition: border-color 0.2s ease;
}
.faq details[open] { border-color: var(--border-strong); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; align-items: center; gap: 14px;
  padding: 19px 22px; font-family: var(--font-head); font-weight: 600; font-size: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .plus { margin-left: auto; flex: none; width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); border: 1px solid var(--border); color: var(--muted); transition: transform 0.25s ease; }
.faq summary .plus svg { width: 13px; height: 13px; }
.faq details[open] .plus { transform: rotate(45deg); color: var(--accent); border-color: var(--accent); }
.faq .faq-a { padding: 0 22px 20px; color: var(--muted); font-size: 14.5px; max-width: 62em; }
.faq .faq-a a { color: var(--accent); font-weight: 600; }

/* ---------- CTA final ---------- */
.cta-final {
  position: relative; overflow: hidden;
  margin-top: 108px; padding: 74px 40px; text-align: center;
  border-radius: 28px;
  border: 1px solid transparent;
  background:
    linear-gradient(color-mix(in srgb, var(--surface-solid) 92%, transparent), color-mix(in srgb, var(--surface-solid) 92%, transparent)) padding-box,
    var(--grad) border-box;
}
.cta-final::before {
  content: ""; position: absolute; inset: -40% -20%; z-index: -1;
  background: radial-gradient(46% 60% at 50% 100%, rgba(99, 102, 241, 0.3), transparent 70%);
}
.cta-final h2 { font-size: clamp(28px, 3.4vw, 42px); font-weight: 700; max-width: 18em; margin: 0 auto 16px; }
.cta-final p { color: var(--muted); font-size: 17px; max-width: 40em; margin: 0 auto 32px; }
.cta-final .hero-cta { justify-content: center; margin: 0; }

/* ---------- footer ---------- */
footer { margin-top: 110px; border-top: 1px solid var(--border); background: color-mix(in srgb, var(--bg-2) 70%, transparent); }
.foot-in { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; padding: 60px 0 44px; }
.foot-brand p { color: var(--muted); font-size: 14px; max-width: 26em; margin-top: 16px; }
.foot-brand .brand img { height: 30px; }
.foot-social { display: flex; gap: 10px; margin-top: 20px; }
.foot-social a { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--border); color: var(--muted); transition: color 0.15s ease, border-color 0.15s ease, transform 0.15s ease; }
.foot-social a:hover { color: var(--text); border-color: var(--accent); transform: translateY(-2px); }
.foot-social svg { width: 17px; height: 17px; }
.foot-col b { display: block; font-family: var(--font-head); font-size: 13.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); margin-bottom: 16px; }
.foot-col a { display: block; text-decoration: none; color: var(--muted); font-size: 14.5px; padding: 5px 0; transition: color 0.15s ease; }
.foot-col a:hover { color: var(--text); }
.foot-col button { background: none; border: 0; padding: 5px 0; color: var(--muted); font-size: 14.5px; cursor: pointer; display: block; transition: color 0.15s ease; }
.foot-col button:hover { color: var(--text); }
.foot-base { display: flex; flex-wrap: wrap; gap: 10px 24px; align-items: center; padding: 22px 0 30px; border-top: 1px solid var(--border); color: var(--faint); font-size: 13px; }
.foot-base .spacer { flex: 1; }
.foot-base a { color: var(--faint); text-decoration: none; }
.foot-base a:hover { color: var(--text); }

/* ---------- banner + modal de cookies ---------- */
.ck-banner {
  position: fixed; z-index: 120; left: 20px; right: 20px; bottom: 20px;
  max-width: 660px; margin: 0 auto;
  background: color-mix(in srgb, var(--surface-solid) 94%, transparent);
  border: 1px solid var(--border-strong); border-radius: 18px;
  box-shadow: var(--shadow), 0 0 0 1px rgba(129, 140, 248, 0.1);
  -webkit-backdrop-filter: blur(16px); backdrop-filter: blur(16px);
  animation: ck-in 0.5s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
@keyframes ck-in { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: none; } }
.ck-in { display: flex; gap: 20px; padding: 20px 22px; align-items: center; }
.ck-txt b { font-family: var(--font-head); font-size: 15.5px; }
.ck-txt p { color: var(--muted); font-size: 13px; margin-top: 5px; }
.ck-txt a { color: var(--accent); font-weight: 600; }
.ck-actions { display: flex; flex-direction: column; gap: 8px; flex: none; }
.ck-actions .btn { height: 38px; font-size: 13.5px; padding: 0 16px; }
.modal {
  position: fixed; inset: 0; z-index: 130;
  display: grid; place-items: center; padding: 20px;
  background: rgba(5, 7, 18, 0.66);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  animation: ck-fade 0.25s ease both;
}
@keyframes ck-fade { from { opacity: 0; } to { opacity: 1; } }
.modal-card {
  width: 100%; max-width: 540px; max-height: calc(100vh - 40px); overflow: auto;
  background: var(--surface-solid); border: 1px solid var(--border-strong); border-radius: 20px;
  box-shadow: var(--shadow); padding: 28px;
  animation: ck-in 0.35s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}
.modal-card h3 { font-size: 20px; margin-bottom: 8px; }
.modal-card .modal-sub { color: var(--muted); font-size: 14px; }
.ck-cat { display: flex; gap: 14px; align-items: flex-start; padding: 16px 0; border-top: 1px solid var(--border); margin-top: 16px; }
.ck-cat:first-of-type { border-top: 0; }
.ck-cat b { display: block; font-family: var(--font-head); font-size: 15px; }
.ck-cat p { color: var(--muted); font-size: 13px; margin-top: 3px; }
.switch { margin-left: auto; flex: none; position: relative; width: 44px; height: 25px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border-strong); cursor: pointer; transition: background 0.18s ease, border-color 0.18s ease; }
.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 19px; height: 19px; border-radius: 50%; background: var(--muted); transition: transform 0.18s ease, background 0.18s ease; }
.switch[aria-checked="true"] { background: var(--grad-btn); border-color: transparent; }
.switch[aria-checked="true"]::after { transform: translateX(19px); background: #fff; }
.switch.locked { opacity: 0.55; cursor: not-allowed; }
.modal-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.modal-actions .btn { flex: 1; min-width: 150px; height: 44px; }
.modal-link { display: block; text-align: center; margin-top: 16px; color: var(--accent); font-size: 13.5px; font-weight: 600; text-decoration: none; }
.modal-link:hover { text-decoration: underline; }

/* ---------- páginas legales ---------- */
.legal-main { padding: calc(var(--nav-h) + 56px) 0 40px; }
.crumb { font-size: 13.5px; color: var(--faint); margin-bottom: 18px; }
.crumb a { color: var(--muted); text-decoration: none; }
.crumb a:hover { color: var(--text); }
.legal-main h1 { font-size: clamp(30px, 3.6vw, 42px); font-weight: 700; }
.legal-updated { display: inline-flex; align-items: center; gap: 8px; margin-top: 16px; font-size: 13px; font-weight: 600; color: var(--muted); background: var(--surface-2); border: 1px solid var(--border); padding: 6px 13px; border-radius: 999px; }
.prose { margin-top: 44px; }
.prose h2 { font-size: 22px; margin: 42px 0 14px; padding-top: 10px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 16.5px; margin: 28px 0 10px; }
.prose p, .prose li { color: var(--text-soft); font-size: 15px; line-height: 1.75; }
.prose p { margin: 0 0 14px; }
.prose ul, .prose ol { margin: 0 0 16px; padding-left: 22px; display: grid; gap: 7px; }
.prose a { color: var(--accent); font-weight: 600; }
.prose strong { color: var(--text); }
.prose .ph { color: var(--warn); font-weight: 600; }
.prose table { width: 100%; border-collapse: collapse; margin: 18px 0 26px; font-size: 13.5px; }
.prose th { text-align: left; font-family: var(--font-head); font-size: 12.5px; text-transform: uppercase; letter-spacing: 0.05em; color: var(--faint); padding: 10px 14px; border-bottom: 1px solid var(--border-strong); }
.prose td { padding: 11px 14px; border-bottom: 1px solid var(--border); color: var(--text-soft); vertical-align: top; }
.prose td code, .prose p code { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 2px 6px; color: var(--accent-3); }
.prose .note {
  display: flex; gap: 13px; padding: 16px 18px; margin: 20px 0;
  background: rgba(34, 211, 238, 0.07); border: 1px solid rgba(34, 211, 238, 0.25); border-radius: var(--radius-sm);
  font-size: 14px; color: var(--text-soft);
}
.prose .note svg { width: 19px; height: 19px; flex: none; margin-top: 2px; color: var(--accent-3); }
.legal-cta {
  margin-top: 52px; padding: 22px 26px; border-radius: var(--radius);
  border: 1px solid var(--border); background: var(--surface);
  display: flex; flex-wrap: wrap; gap: 14px; align-items: center;
}
.legal-cta p { font-size: 14px; color: var(--muted); }
.legal-cta .btn { margin-left: auto; }

/* ---------- responsive ---------- */
@media (max-width: 1060px) {
  .hero-grid { grid-template-columns: 1fr; gap: 70px; }
  .hero { padding-top: calc(var(--nav-h) + 52px); }
  .lead { max-width: 44em; }
  .hero-visual { max-width: 660px; }
  .chip.c2 { left: 0; }
  .chip.c3 { right: 0; }
  .sec-grid { grid-template-columns: 1fr; gap: 36px; }
  .foot-in { grid-template-columns: 1fr 1fr; }
  .b-card, .b-card.wide { grid-column: span 3; }
  .b-card.full { grid-column: span 6; }
  .b-card.analytics, .b-card.plataforma { grid-column: span 6; grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .wrap { padding: 0 20px; }
  .nav-links { display: none; }
  .menu-btn { display: inline-flex; }
  .nav-actions .ghost { display: none; }
  .hero h1 { font-size: clamp(32px, 9vw, 40px); }
  .hero-cta .btn { width: 100%; }
  .stats-band { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; }
  .vs { grid-template-columns: 1fr; }
  .b-card, .b-card.wide, .b-card.analytics, .b-card.plataforma { grid-column: span 6; }
  .b-card.analytics, .b-card.plataforma { grid-template-columns: 1fr; }
  .orgs { min-height: 0; }
  .b-visual { min-height: 170px; }
  .mock-kpis { grid-template-columns: 1fr 1fr; }
  .mock-panels { grid-template-columns: 1fr; }
  .chip { display: none; }
  .foot-in { grid-template-columns: 1fr; gap: 30px; padding: 44px 0 34px; }
  .ck-in { flex-direction: column; align-items: stretch; }
  .ck-actions { flex-direction: row; flex-wrap: wrap; }
  .ck-actions .btn { flex: 1; }
  .sec { padding-top: 84px; }
  .cta-final { padding: 54px 22px; }
  .modal-actions .btn { min-width: 100%; }
}
