/* Landing pública (18 oct 2026).
   Una sola página, como las de referencia (Holded, Pennylane, Factorial):
   portada con el vídeo, cuatro beneficios con su clip, la demo, tres pasos,
   gestorías, precios, piloto y preguntas. Un solo momento con movimiento al
   cargar (la portada); los clips solo se mueven mientras se ven. */

:root {
  --ink: #070A12;
  --ink-2: #0B1020;
  --ink-3: #10172A;
  --line: #1B2438;
  --line-2: #141C2E;
  --paper: #EEF2F9;
  --mist: #A3AEC0;
  --dim: #8592A6;
  --iris: #8FA4FF;
  --iris-2: #B5C3FF;
  --mint: #4ED7A4;

  --serif: "Instrument Serif", "Times New Roman", serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --max: 1180px;
  --gutter: clamp(20px, 4vw, 40px);

  /* Paleta que usa la demo del chat (landing-demo-chat.css) */
  --sp-bg-alt: var(--ink-2);
  --sp-card: #0F1628;
  --sp-card-hover: #131C31;
  --sp-border: var(--line);
  --sp-border-light: var(--line-2);
  --sp-text: var(--paper);
  --sp-text-sec: var(--mist);
  --sp-text-muted: var(--dim);
  --sp-accent: var(--iris);
  --sp-accent-light: rgba(143, 164, 255, .12);
  --sp-accent-border: rgba(143, 164, 255, .42);
  --sp-accent-glow: rgba(143, 164, 255, .28);
  --sp-success: var(--mint);
  --sp-success-soft: rgba(78, 215, 164, .12);
  --sp-success-border: rgba(78, 215, 164, .38);
  --sp-success-text: #9BEBCB;
  --sp-warning-soft: rgba(240, 180, 90, .12);
  --sp-warning-border: rgba(240, 180, 90, .38);
  --sp-warning-text: #F8D89B;
  --sp-danger: #F2707C;
}

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0; background: var(--ink); color: var(--paper);
  font-family: var(--sans); font-size: 17px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img, video { display: block; max-width: 100%; }
a { color: var(--iris-2); }
a:hover { color: #fff; }
:focus-visible { outline: 2px solid var(--iris); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--paper); color: var(--ink); padding: 8px 14px; border-radius: 8px; }
.skip:focus { left: 12px; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ── Botones ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: 600 15px/1 var(--sans); text-decoration: none; white-space: nowrap;
  padding: 13px 20px; border-radius: 12px; border: 1px solid transparent; cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}
.btn:active { transform: scale(0.97); transition-duration: .1s; }
.btn-primary { background: var(--paper); color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .btn-primary:hover { background: #fff; color: var(--ink); } }
.btn-ghost { background: transparent; color: var(--paper); border-color: var(--line); }
@media (hover: hover) and (pointer: fine) { .btn-ghost:hover { border-color: #33405A; color: #fff; } }
.btn-lg { padding: 16px 24px; font-size: 16px; border-radius: 14px; }

/* ── Navegación ── */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 10, 18, .78); backdrop-filter: saturate(140%) blur(14px); -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid transparent; transition: border-color .2s ease;
}
.nav.is-scrolled { border-bottom-color: var(--line-2); }
.nav-in { height: 68px; display: flex; align-items: center; gap: 28px; }
.nav-brand img { height: 26px; width: auto; }
.nav-links { display: flex; gap: 26px; margin-left: 12px; }
.nav-links a { color: var(--mist); text-decoration: none; font-size: 15px; font-weight: 500; }
.nav-links a:hover { color: var(--paper); }
.nav-ctas { margin-left: auto; display: flex; gap: 10px; align-items: center; }
.nav-ctas .btn { padding: 10px 16px; font-size: 14px; border-radius: 10px; }
@media (max-width: 880px) {
  .nav-links { display: none; }
  .nav-in { gap: 12px; height: 60px; }
  .nav-brand img { height: 22px; }
  .nav-ctas .btn { padding: 9px 12px; font-size: 13.5px; }
}
@media (max-width: 380px) { .nav-ctas .btn-ghost { display: none; } }

/* ── Portada ── */
.hero { position: relative; padding: clamp(36px, 5.5vw, 76px) 0 clamp(56px, 7vw, 96px); isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: -20% -10% auto; height: 120%; pointer-events: none; z-index: -1;
  background:
    radial-gradient(52% 46% at 74% 30%, rgba(143, 164, 255, .14), transparent 70%),
    radial-gradient(40% 40% at 10% 0%, rgba(78, 215, 164, .05), transparent 70%);
}
.hero h1 {
  font-family: var(--serif); font-weight: 400; letter-spacing: -0.018em;
  font-size: clamp(46px, 7vw, 104px); line-height: 0.96; margin: 0 0 clamp(26px, 3vw, 40px); text-wrap: balance;
}
.hero-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 32px 56px; align-items: end; margin-bottom: clamp(40px, 5vw, 64px); }
.hero-sub { font-size: clamp(17px, 1.5vw, 19px); color: var(--mist); max-width: 46ch; margin: 0; }
.hero-act { justify-self: end; }
.hero-ctas { display: flex; gap: 12px; flex-wrap: wrap; }
@media (max-width: 520px) { .hero-ctas .btn { flex: 1 1 100%; } }
.hero-note { margin: 14px 0 0; font-size: 14px; color: var(--dim); }
@media (max-width: 900px) {
  .hero-row { grid-template-columns: 1fr; }
  .hero-act { justify-self: start; }
}

/* Reproductor */
.player {
  position: relative; border-radius: 20px; overflow: hidden; aspect-ratio: 16 / 9; background: #05070D;
  border: 1px solid var(--line);
  box-shadow: 0 50px 120px -40px rgba(0, 0, 0, .8), 0 0 0 1px rgba(255, 255, 255, .03) inset, 0 0 120px -30px rgba(143, 164, 255, .35);
}
.player video { width: 100%; height: 100%; object-fit: cover; }
.player-play {
  position: absolute; left: 20px; bottom: 20px; display: inline-flex; align-items: center; gap: 12px;
  padding: 10px 18px 10px 10px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .14);
  background: rgba(7, 10, 18, .72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  color: var(--paper); font: 600 15px/1 var(--sans); cursor: pointer; transition: background-color .18s ease, border-color .18s ease;
}
@media (hover: hover) and (pointer: fine) { .player-play:hover { background: rgba(7, 10, 18, .9); border-color: rgba(255, 255, 255, .28); } }
.player-play .ico { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--paper); color: var(--ink); }
.player-play small { font-weight: 500; color: var(--mist); font-size: 14px; }
.player.is-full .player-play { display: none; }
.player-cap { margin: 12px 2px 0; font-size: 13px; color: var(--dim); }

/* Entrada de la portada (una vez) */
.js .hero h1, .js .hero-sub, .js .hero-ctas, .js .hero-note, .js .hero-media { opacity: 0; transform: translateY(14px); }
.js.is-ready .hero h1, .js.is-ready .hero-sub, .js.is-ready .hero-ctas, .js.is-ready .hero-note, .js.is-ready .hero-media {
  opacity: 1; transform: none; transition: opacity .7s ease, transform .9s cubic-bezier(.2, .8, .2, 1);
}
.js.is-ready .hero-sub { transition-delay: .08s; }
.js.is-ready .hero-ctas { transition-delay: .16s; }
.js.is-ready .hero-note { transition-delay: .2s; }
.js.is-ready .hero-media { transition-delay: .28s; transition-duration: 1s, 1.2s; }
@media (prefers-reduced-motion: reduce) {
  .js .hero h1, .js .hero-sub, .js .hero-ctas, .js .hero-note, .js .hero-media { opacity: 1; transform: none; }
}

@media (max-width: 960px) {
  .player-play { left: 12px; bottom: 12px; padding: 8px 14px 8px 8px; font-size: 14px; }
  .player-play .ico { width: 30px; height: 30px; }
}

/* Compatibilidad */
.compat { border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.compat-grid { display: flex; justify-content: center; gap: 12px 40px; padding: 18px 0; flex-wrap: wrap; }
.compat p { margin: 0; font-size: 15px; color: var(--mist); }
.compat-row { display: flex; align-items: baseline; gap: 10px; }
.compat-tag {
  flex: none; font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  padding: 3px 9px; border-radius: 999px; border: 1px solid var(--line); transform: translateY(-1px);
}
.compat-tag--now { color: var(--paper); border-color: rgba(255, 255, 255, .28); }
.compat-tag--soon { color: var(--dim); }
.compat strong { color: var(--paper); font-weight: 600; }
@media (max-width: 720px) {
  .compat-grid { flex-direction: column; align-items: flex-start; padding: 16px 0; }
}

/* ── Secciones ── */
.sec { padding: clamp(72px, 10vw, 128px) 0; }
.sec-alt { background: var(--ink-2); border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2); }
.sec-head { max-width: 680px; margin: 0 0 clamp(36px, 5vw, 56px); }
.sec-head.center { margin-left: auto; margin-right: auto; text-align: center; }
h2 {
  font-family: var(--serif); font-weight: 400; letter-spacing: -0.01em;
  font-size: clamp(36px, 4.4vw, 58px); line-height: 1.02; margin: 0 0 16px; text-wrap: balance;
}
.sec-head p { color: var(--mist); font-size: 18px; margin: 0; text-wrap: pretty; }
h3 { font-size: 19px; line-height: 1.3; margin: 0 0 8px; font-weight: 600; }

/* Beneficios: texto y clip, alternos */
.ben { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.ben + .ben { margin-top: clamp(72px, 10vw, 136px); }
.ben:nth-child(even) { grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); }
.ben:nth-child(even) .ben-copy { order: 2; }
.ben-copy h2 { font-size: clamp(34px, 3.8vw, 52px); }
.ben-copy p { color: var(--mist); font-size: 18px; margin: 0 0 22px; max-width: 42ch; }
.facts { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.facts li { padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 16px; color: var(--paper); display: flex; gap: 12px; align-items: baseline; }
.facts li::before { content: ""; flex: none; width: 6px; height: 6px; border-radius: 50%; background: var(--iris); transform: translateY(-2px); }
.clip {
  position: relative; border-radius: 18px; overflow: hidden; aspect-ratio: 2 / 1; background: #05070D;
  border: 1px solid var(--line); box-shadow: 0 40px 90px -45px rgba(0, 0, 0, .85);
}
.clip video { width: 100%; height: 100%; object-fit: cover; }
.clip-note { margin: 10px 2px 0; font-size: 13px; color: var(--dim); }
/* Sin botón de play del navegador sobre los clips (se reproducen solos; ver landing-v5.js). */
.clip video:not([controls])::-webkit-media-controls,
.clip video:not([controls])::-webkit-media-controls-start-playback-button,
.player video:not([controls])::-webkit-media-controls-start-playback-button { display: none !important; -webkit-appearance: none; }
@media (max-width: 960px) {
  .ben, .ben:nth-child(even) { grid-template-columns: 1fr; }
  .ben:nth-child(even) .ben-copy { order: 0; }
}

/* Demo */
.demo-note { max-width: 760px; margin: 18px auto 0; text-align: center; font-size: 14px; color: var(--dim); }
.shot-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.shot-url { margin-left: 10px; font-size: 11.5px; color: var(--dim); padding: 2px 10px; border-radius: 999px; background: var(--ink-2); border: 1px solid var(--line-2); }
@media (max-width: 640px) { .shot-url { display: none; } }

/* Pasos (es una secuencia de verdad) */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.steps li { padding: 28px 28px 0 0; }
.steps li + li { padding-left: 28px; border-left: 1px solid var(--line); }
.step-n { display: block; font-family: var(--serif); font-size: 56px; line-height: 1; color: var(--iris-2); margin-bottom: 18px; }
.steps p { color: var(--mist); margin: 0; font-size: 16px; }
@media (max-width: 860px) {
  .steps { grid-template-columns: 1fr; }
  .steps li, .steps li + li { padding: 24px 0; border-left: 0; border-bottom: 1px solid var(--line); }
}

/* Gestorías */
.gest { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.gest-copy p { color: var(--mist); font-size: 18px; margin: 0 0 22px; }
.gest-copy .btn { margin-top: 24px; }
.gest-plans { display: grid; gap: 12px; }
.gplan { display: grid; grid-template-columns: 1fr auto auto; gap: 16px; align-items: center; padding: 18px 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--ink-3); }
.gplan-n { font-weight: 600; font-size: 17px; }
.gplan-d { display: block; font-size: 14px; color: var(--dim); font-weight: 400; }
.gplan-p { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.gplan-p small { font-size: 14px; color: var(--dim); font-weight: 400; }
.gplan .btn { padding: 10px 14px; font-size: 14px; border-radius: 10px; }
.gest-foot { margin: 14px 2px 0; font-size: 14px; color: var(--dim); }
@media (max-width: 960px) { .gest { grid-template-columns: 1fr; } }
@media (max-width: 560px) {
  .gplan { grid-template-columns: 1fr auto; }
  .gplan .btn { grid-column: 1 / -1; }
}

/* Precios */
.toggle-row { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 0 32px; font-size: 15px; color: var(--mist); }
.toggle-label.active { color: var(--paper); font-weight: 600; }
.switch { position: relative; width: 46px; height: 26px; border-radius: 999px; border: 1px solid var(--line); background: var(--ink-3); cursor: pointer; padding: 0; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: var(--paper); transition: transform .2s ease; }
.switch[aria-checked="true"]::after { transform: translateX(20px); }
.save-pill { font-size: 13px; color: var(--mint); }
.price-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.price-card { position: relative; display: flex; flex-direction: column; padding: 26px 24px; border: 1px solid var(--line); border-radius: 18px; background: var(--ink-3); }
.price-card.featured { border-color: rgba(143, 164, 255, .55); background: linear-gradient(180deg, rgba(143, 164, 255, .09), rgba(143, 164, 255, .02)), var(--ink-3); }
.price-featured-tag { position: absolute; top: -11px; left: 22px; font-size: 12.5px; font-weight: 600; padding: 3px 10px; border-radius: 999px; background: var(--iris); color: var(--ink); }
.price-name { font-size: 18px; font-weight: 600; }
.price-desc { font-size: 14.5px; color: var(--dim); margin: 2px 0 18px; }
.price-amount { display: flex; align-items: baseline; gap: 4px; }
.price-num { font-family: var(--serif); font-size: 48px; line-height: 1; }
.price-period { color: var(--dim); font-size: 15px; }
.price-annual-note { min-height: 20px; font-size: 13px; color: var(--dim); margin: 6px 0 14px; }
.price-features { list-style: none; margin: 0 0 22px; padding: 0; display: grid; gap: 8px; font-size: 15px; color: var(--mist); flex: 1; align-content: start; }
.price-features li { display: flex; gap: 10px; align-items: baseline; }
.price-features svg { flex: none; color: var(--mint); transform: translateY(2px); }
.price-cta { width: 100%; }
@media (max-width: 1020px) { .price-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .price-grid { grid-template-columns: 1fr; } }

.ai-disclosure { margin: 0 auto; max-width: 760px; padding: 28px 0 0; text-align: center; font-size: 14px; color: var(--dim); }

/* Piloto */
.piloto { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(28px, 5vw, 72px); align-items: start; }
.piloto-card { padding: 28px; border: 1px solid var(--line); border-radius: 20px; background: var(--ink-3); }
.piloto-form { display: grid; gap: 16px; }
.piloto-form label { display: block; font-size: 14px; color: var(--mist); margin-bottom: 6px; }
.piloto-form input {
  width: 100%; padding: 13px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--ink);
  color: var(--paper); font: 400 16px/1.3 var(--sans);
}
.piloto-form input:focus { outline: none; border-color: var(--iris); box-shadow: 0 0 0 3px rgba(143, 164, 255, .2); }
.piloto-note { margin: 0; font-size: 13.5px; color: var(--dim); }
.piloto-success { padding: 22px; border-radius: 16px; border: 1px solid var(--sp-success-border); background: var(--sp-success-soft); color: var(--sp-success-text); }
.flash-danger { color: var(--sp-danger); margin: 0 0 12px; }
@media (max-width: 960px) { .piloto { grid-template-columns: 1fr; } }

/* Preguntas */
.faq-list { max-width: 820px; margin: 0 auto; border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 20px; text-align: left;
  padding: 22px 0; background: none; border: 0; color: var(--paper); font: 500 18px/1.4 var(--sans); cursor: pointer;
}
.faq-q svg { flex: none; color: var(--mist); transition: transform .25s ease; }
.faq-item[data-open="true"] .faq-q svg { transform: rotate(45deg); }
.faq-a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .3s ease; }
.faq-item[data-open="true"] .faq-a { grid-template-rows: 1fr; }
.faq-a-inner { overflow: hidden; color: var(--mist); font-size: 16px; }
.faq-item[data-open="true"] .faq-a-inner { padding-bottom: 22px; }

/* Cierre */
.cta-final { padding: clamp(80px, 11vw, 140px) 0; text-align: center; position: relative; overflow: hidden; isolation: isolate; }
.cta-final::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(40% 60% at 50% 100%, rgba(143, 164, 255, .14), transparent 70%); }
.cta-final h2 { font-size: clamp(40px, 5.4vw, 72px); max-width: 16ch; margin: 0 auto 18px; }
.cta-final p { color: var(--mist); max-width: 46ch; margin: 0 auto 32px; font-size: 18px; }

/* Pie */
footer { border-top: 1px solid var(--line-2); padding: 56px 0 40px; font-size: 15px; }
.foot-top { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 40px; }
.foot-brand img { height: 24px; width: auto; margin-bottom: 14px; }
.foot-brand p { color: var(--dim); max-width: 34ch; margin: 0; }
.foot-cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.foot-cols h4 { margin: 0 0 12px; font-size: 14px; font-weight: 600; color: var(--paper); }
.foot-cols a { display: block; color: var(--mist); text-decoration: none; padding: 4px 0; }
.foot-cols a:hover { color: var(--paper); }
.foot-bottom { margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line-2); color: var(--dim); font-size: 14px; }
@media (max-width: 860px) {
  .foot-top { grid-template-columns: 1fr; }
  .foot-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Clips: se descubren de arriba abajo una sola vez, cuando entran en pantalla */
.js .ben .clip video { clip-path: inset(0 0 100% 0); }
.js .ben .ben-copy { opacity: 0; transform: translateY(14px); }
.js .ben.is-in .clip video { clip-path: inset(0 0 0 0); transition: clip-path 1.1s cubic-bezier(.77, 0, .175, 1); }
.js .ben.is-in .ben-copy { opacity: 1; transform: none; transition: opacity .6s ease .25s, transform .8s cubic-bezier(.23, 1, .32, 1) .25s; }
.js .ben.is-in .clip video { animation: clipzoom 1.4s cubic-bezier(.23, 1, .32, 1) both; }
@keyframes clipzoom { from { transform: scale(1.06); } to { transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .js .ben .clip video, .js .ben.is-in .clip video { clip-path: none; transition: none; }
  .js .ben .ben-copy { opacity: 1; transform: none; transition: none; }
  .js .ben.is-in .clip video { animation: none; }
}
.clip-wrap { margin: 0; }
