/* ============================================================
   CABINA — landing "tablero de instrumentos"
   Paleta heredada de la extensión + tipografía propia:
   Bricolage Grotesque (display) · Instrument Sans (texto) ·
   IBM Plex Mono (números / lecturas de instrumento)
   ============================================================ */

* { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg-0: #0b0e16;
  --bg-1: #111420;
  --bg-2: #1b1f2b;
  --surface: #1f2533;
  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.13);
  --txt: #eceef5;
  --txt-dim: #9aa1b5;
  --txt-mute: #8a91a8;
  --good: #2ee6a6;
  --warn: #ffc24b;
  --bad: #ff6b6b;
  --brand: #5ea0ff;
  --brand-deep: #2f63c9;
  --ml-yellow: #ffe600;
  --radius: 16px;
  --font-display: "Bricolage Grotesque", sans-serif;
  --font-body: "Instrument Sans", sans-serif;
  --font-mono: "IBM Plex Mono", monospace;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg-0);
  color: var(--txt);
  font-family: var(--font-body);
  font-size: 16.5px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* Atmósfera: glows + grano sutil sobre todo el documento */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(900px 600px at 85% -5%, rgba(94, 160, 255, 0.13), transparent 60%),
    radial-gradient(700px 500px at -10% 35%, rgba(46, 230, 166, 0.07), transparent 60%),
    radial-gradient(800px 600px at 60% 110%, rgba(94, 160, 255, 0.08), transparent 60%);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.5;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.035 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

main, header.topbar, footer { position: relative; z-index: 2; }

::selection { background: rgba(94, 160, 255, 0.35); }

a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 24px; }

/* ---------- Topbar ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(11, 14, 22, 0.75);
  border-bottom: 1px solid var(--line);
}
.topbar .wrap {
  display: flex;
  align-items: center;
  gap: 28px;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 17px;
  letter-spacing: 0.18em;
  color: var(--txt);
}
.brand:hover { text-decoration: none; }
.topnav { display: flex; gap: 22px; margin-left: auto; }
.topnav a {
  color: var(--txt-dim);
  font-size: 14.5px;
  font-weight: 500;
}
.topnav a:hover { color: var(--txt); text-decoration: none; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  cursor: pointer;
  border-radius: 12px;
  padding: 13px 22px;
  font-family: var(--font-body);
  font-size: 15.5px;
  font-weight: 650;
  color: #fff;
  background: linear-gradient(180deg, #4a8af5, var(--brand-deep));
  box-shadow: 0 10px 24px -8px rgba(61, 123, 230, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.18);
  transition: transform 0.13s ease, filter 0.15s ease;
}
.btn:hover { filter: brightness(1.08); text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(1px); }
.btn-sm { padding: 9px 16px; font-size: 14px; border-radius: 10px; }
.btn-ghost {
  background: var(--surface);
  color: var(--txt-dim);
  box-shadow: none;
  border: 1px solid var(--line-2);
}
.btn-ghost:hover { color: var(--txt); background: #262c3b; }
.btn-xl { padding: 16px 30px; font-size: 17px; border-radius: 14px; }

/* ---------- Hero ---------- */
.hero { padding: 84px 0 40px; }
.hero .wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 56px;
  align-items: center;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand);
  background: rgba(94, 160, 255, 0.1);
  border: 1px solid rgba(94, 160, 255, 0.25);
  border-radius: 999px;
  padding: 7px 14px;
  margin-bottom: 22px;
}
h1 {
  font-family: var(--font-display);
  font-size: clamp(38px, 5vw, 58px);
  font-weight: 800;
  line-height: 1.06;
  letter-spacing: -0.015em;
  margin-bottom: 20px;
}
h1 em {
  font-style: normal;
  color: var(--good);
  position: relative;
  white-space: nowrap;
}
h1 em::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 4px;
  height: 10px;
  background: rgba(46, 230, 166, 0.18);
  z-index: -1;
  border-radius: 3px;
}
.hero-sub {
  font-size: 18px;
  color: var(--txt-dim);
  max-width: 520px;
  margin-bottom: 30px;
}
.hero-sub strong { color: var(--txt); font-weight: 600; }
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 26px; }
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--txt-mute);
}
.trust span { display: inline-flex; align-items: center; gap: 6px; }
.trust b { color: var(--good); font-weight: 400; }

/* Panel demo (réplica del panel real, inclinado) */
.cockpit {
  position: relative;
  perspective: 1200px;
}
.panel {
  position: relative;
  transform: rotateY(-7deg) rotateX(2deg);
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
  border: 1px solid var(--line-2);
  border-radius: 18px;
  box-shadow:
    0 40px 80px -30px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(94, 160, 255, 0.06),
    0 0 90px -20px rgba(94, 160, 255, 0.25);
  padding: 18px;
  max-width: 400px;
  margin-left: auto;
  font-size: 14px;
}
.panel-head {
  display: flex;
  align-items: center;
  gap: 9px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.18em;
  font-size: 13px;
}
.panel-head .chip-live {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.05em;
  color: var(--txt-mute);
  display: flex;
  align-items: center;
  gap: 6px;
}
.dot-live {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--good);
  box-shadow: 0 0 8px rgba(46, 230, 166, 0.8);
  animation: pulse 2.2s infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.35; } }

.panel-hero {
  background: rgba(46, 230, 166, 0.07);
  border: 1px solid rgba(46, 230, 166, 0.25);
  border-radius: 13px;
  padding: 14px 16px;
  margin-bottom: 13px;
}
.panel-hero .lbl {
  font-family: var(--font-mono);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--good);
}
.panel-hero .amount-row { display: flex; align-items: baseline; gap: 12px; margin-top: 3px; }
.panel-hero .amount {
  font-family: var(--font-mono);
  font-size: 31px;
  font-weight: 600;
  color: var(--good);
  font-variant-numeric: tabular-nums;
}
.panel-hero .pct {
  font-family: var(--font-mono);
  font-size: 15px;
  color: var(--txt-dim);
}
.panel-rows { display: flex; flex-direction: column; gap: 7px; margin-bottom: 13px; }
.prow {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--txt-dim);
}
.prow .v { font-family: var(--font-mono); font-variant-numeric: tabular-nums; color: var(--txt); }
.prow .v.neg { color: var(--bad); }
.prow.total {
  border-top: 1px solid var(--line-2);
  padding-top: 8px;
  color: var(--txt);
  font-weight: 600;
}
.panel-health { display: flex; gap: 8px; }
.hchip {
  flex: 1;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 11.5px;
  border-radius: 10px;
  padding: 8px 6px;
  border: 1px solid var(--line-2);
  background: rgba(0, 0, 0, 0.22);
  color: var(--txt-dim);
}
.hchip b { color: var(--good); font-weight: 600; font-size: 14px; display: block; }

/* Toast flotante sobre el panel */
.float-toast {
  position: absolute;
  left: -28px;
  bottom: 38px;
  background: var(--surface);
  border: 1px solid rgba(255, 194, 75, 0.4);
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 12.5px;
  color: var(--txt);
  box-shadow: 0 18px 40px -14px rgba(0, 0, 0, 0.8);
  animation: floaty 5s ease-in-out infinite;
  max-width: 250px;
}
.float-toast .mono { font-family: var(--font-mono); color: var(--warn); }
@keyframes floaty { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* Pista de aterrizaje: divisor con luces */
.runway {
  height: 1px;
  margin: 70px auto 0;
  max-width: 1120px;
  background-image: linear-gradient(90deg, var(--brand) 0 14px, transparent 14px 28px);
  background-size: 28px 1px;
  opacity: 0.35;
  position: relative;
}

/* ---------- Secciones ---------- */
section { padding: 88px 0; }
.sec-eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 14px;
}
h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin-bottom: 16px;
  max-width: 640px;
}
.sec-sub { color: var(--txt-dim); max-width: 600px; margin-bottom: 44px; }

/* Cascada del precio (problema) */
.waterfall {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px;
  align-items: end;
  margin-top: 16px;
}
.wf {
  border-radius: 10px 10px 4px 4px;
  position: relative;
  min-height: 30px;
  transform-origin: bottom;
}
.wf .wf-cap {
  position: absolute;
  top: -52px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--font-mono);
  font-size: clamp(10px, 1.2vw, 12.5px);
  color: var(--txt-dim);
  line-height: 1.35;
}
.wf .wf-cap b { color: var(--txt); display: block; font-weight: 600; }
.wf-precio { background: linear-gradient(180deg, #3a414f, #262c3b); height: 230px; }
.wf-fee { background: linear-gradient(180deg, #b65151, #7e3434); height: 36px; }
.wf-envio { background: linear-gradient(180deg, #b65151, #7e3434); height: 26px; }
.wf-ret { background: linear-gradient(180deg, #b65151, #7e3434); height: 30px; }
.wf-costo { background: linear-gradient(180deg, #a98439, #6f5520); height: 95px; }
.wf-gan { background: linear-gradient(180deg, var(--good), #169c6e); height: 70px; box-shadow: 0 0 40px -8px rgba(46, 230, 166, 0.5); }
.waterfall-note {
  margin-top: 26px;
  font-size: 14px;
  color: var(--txt-mute);
  font-family: var(--font-mono);
}

/* Features */
.grid3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}
.card {
  background: linear-gradient(180deg, rgba(31, 37, 51, 0.85), rgba(17, 20, 32, 0.85));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 24px;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(94, 160, 255, 0.35);
  box-shadow: 0 24px 50px -24px rgba(94, 160, 255, 0.25);
}
.card .ico {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  font-size: 21px;
  border-radius: 12px;
  background: rgba(94, 160, 255, 0.12);
  border: 1px solid rgba(94, 160, 255, 0.2);
  margin-bottom: 16px;
}
.card h3 {
  font-family: var(--font-display);
  font-size: 18.5px;
  font-weight: 700;
  margin-bottom: 8px;
}
.card p { font-size: 14.5px; color: var(--txt-dim); }
.card p b { color: var(--txt); font-weight: 600; }

/* Calculadora */
.calc-box {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border: 1px solid var(--line-2);
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(180deg, var(--bg-2), var(--bg-1));
  box-shadow: 0 40px 90px -40px rgba(0, 0, 0, 0.8);
}
.calc-in { padding: 34px 32px; border-right: 1px solid var(--line); }
.calc-field { margin-bottom: 18px; }
.calc-field label {
  display: block;
  font-size: 13px;
  color: var(--txt-mute);
  margin-bottom: 7px;
  font-weight: 500;
}
.calc-field input {
  width: 100%;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--line-2);
  border-radius: 11px;
  padding: 13px 14px;
  color: var(--txt);
  font-family: var(--font-mono);
  font-size: 17px;
  outline: none;
  transition: border-color 0.15s;
}
.calc-field input:focus { border-color: var(--brand); }
.calc-assume {
  font-size: 12px;
  color: var(--txt-mute);
  line-height: 1.55;
  margin-top: 6px;
}
.calc-out {
  padding: 34px 32px;
  background:
    radial-gradient(400px 260px at 70% 0%, rgba(46, 230, 166, 0.08), transparent 70%);
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.calc-out .lbl {
  font-family: var(--font-mono);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--txt-mute);
}
.calc-net {
  font-family: var(--font-mono);
  font-size: clamp(34px, 4vw, 46px);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  margin: 4px 0 2px;
  color: var(--good);
  transition: color 0.2s;
}
.calc-net.is-bad { color: var(--bad); }
.calc-net.is-warn { color: var(--warn); }
.calc-pct { font-family: var(--font-mono); color: var(--txt-dim); margin-bottom: 18px; }
.calc-rows { display: flex; flex-direction: column; gap: 6px; }
.calc-rows .prow { font-size: 13.5px; }
.calc-cta { margin-top: 22px; font-size: 13.5px; color: var(--txt-dim); }

/* Seguridad */
.sec-dark {
  background: linear-gradient(180deg, rgba(17, 20, 32, 0.65), transparent);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.grid4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.sec-note {
  margin-top: 28px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--txt-mute);
}

/* Pricing */
.plans {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 420px));
  gap: 22px;
  justify-content: center;
}
.plan {
  border: 1px solid var(--line-2);
  border-radius: 20px;
  padding: 34px 30px;
  background: linear-gradient(180deg, rgba(31, 37, 51, 0.9), rgba(17, 20, 32, 0.9));
  position: relative;
}
.plan.pro {
  border-color: rgba(94, 160, 255, 0.5);
  box-shadow: 0 0 80px -24px rgba(94, 160, 255, 0.4);
}
.plan-badge {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(180deg, #4a8af5, var(--brand-deep));
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 5px 14px;
  border-radius: 999px;
  white-space: nowrap;
}
.plan h3 { font-family: var(--font-display); font-size: 21px; font-weight: 800; }
.plan .for { font-size: 13.5px; color: var(--txt-mute); margin-bottom: 18px; }
.price { font-family: var(--font-mono); font-size: 42px; font-weight: 600; line-height: 1; }
.price small { font-size: 15px; color: var(--txt-mute); font-weight: 400; }
.price-alt { font-size: 13px; color: var(--txt-mute); margin: 8px 0 22px; font-family: var(--font-mono); }
.plan ul { list-style: none; display: flex; flex-direction: column; gap: 11px; margin-bottom: 28px; }
.plan li { font-size: 14.5px; color: var(--txt-dim); display: flex; gap: 10px; }
.plan li b { color: var(--txt); font-weight: 600; }
.plan li::before { content: "✓"; color: var(--good); font-weight: 700; }
.plan li.no::before { content: "✕"; color: var(--txt-mute); }
.plan .btn { width: 100%; }
.plans-note {
  text-align: center;
  margin-top: 24px;
  font-size: 13.5px;
  color: var(--txt-mute);
}

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; }
.faq details {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(31, 37, 51, 0.55);
  margin-bottom: 12px;
  overflow: hidden;
}
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 22px;
  font-weight: 600;
  font-size: 15.5px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  font-family: var(--font-mono);
  color: var(--brand);
  font-size: 19px;
  transition: transform 0.2s;
  flex: none;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .faq-body { padding: 0 22px 20px; color: var(--txt-dim); font-size: 14.5px; }

/* CTA final */
.final { text-align: center; padding-bottom: 110px; }
.final h2 { margin: 0 auto 14px; }
.final .sec-sub { margin: 0 auto 34px; }

/* Footer */
footer {
  border-top: 1px solid var(--line);
  padding: 44px 0 54px;
  background: rgba(11, 14, 22, 0.9);
}
.foot-top {
  display: flex;
  align-items: center;
  gap: 26px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.foot-links { display: flex; gap: 22px; margin-left: auto; flex-wrap: wrap; }
.foot-links a { color: var(--txt-dim); font-size: 14px; }
.foot-links a:hover { color: var(--txt); }
.foot-legal {
  font-size: 12.5px;
  color: var(--txt-mute);
  max-width: 720px;
  line-height: 1.6;
}

/* Páginas legales */
.doc { max-width: 760px; margin: 0 auto; padding: 70px 24px 100px; }
.doc h1 { font-size: clamp(30px, 4vw, 42px); margin-bottom: 8px; }
.doc .doc-date { font-family: var(--font-mono); font-size: 13px; color: var(--txt-mute); margin-bottom: 40px; }
.doc h2 { font-size: 22px; margin: 38px 0 12px; max-width: none; }
.doc p, .doc li { color: var(--txt-dim); font-size: 15.5px; margin-bottom: 12px; }
.doc ul { padding-left: 22px; margin-bottom: 14px; }
.doc strong { color: var(--txt); }
.doc .back { font-family: var(--font-mono); font-size: 13px; display: inline-block; margin-bottom: 30px; }

/* Reveal on scroll */
.rv { opacity: 0; transform: translateY(22px); transition: opacity 0.6s ease, transform 0.6s ease; }
.rv.in { opacity: 1; transform: none; }
.rv-d1 { transition-delay: 0.08s; }
.rv-d2 { transition-delay: 0.16s; }
.rv-d3 { transition-delay: 0.24s; }

/* Toast "muy pronto" */
#toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: var(--surface);
  border: 1px solid rgba(94, 160, 255, 0.4);
  color: var(--txt);
  padding: 13px 22px;
  border-radius: 13px;
  font-size: 14.5px;
  box-shadow: 0 20px 50px -16px rgba(0, 0, 0, 0.9);
  transition: transform 0.3s ease;
  z-index: 100;
}
#toast.show { transform: translateX(-50%) translateY(0); }

/* ---------- Responsive ---------- */
@media (max-width: 920px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 50px; }
  .panel { margin: 0 auto; transform: none; }
  .float-toast { left: 8px; }
  .grid3 { grid-template-columns: 1fr; }
  .grid4 { grid-template-columns: repeat(2, 1fr); }
  .calc-box { grid-template-columns: 1fr; }
  .calc-in { border-right: none; border-bottom: 1px solid var(--line); }
  .plans { grid-template-columns: 1fr; }
  .topnav { display: none; }
  section { padding: 64px 0; }
  .waterfall { gap: 6px; }
}
@media (max-width: 520px) {
  .grid4 { grid-template-columns: 1fr; }
  .wf .wf-cap { font-size: 9px; top: -46px; }
}
