:root {
  --noche: #06121a;
  --noche-2: #0b1d29;
  --panel: #102636;
  --linea: rgba(150, 200, 210, .16);
  --cian: #2dd4bf;
  --azul: #0ea5e9;
  --verde: #34d399;
  --ambar: #fbbf24;
  --rojo: #f87171;
  --texto: #e8eefc;
  --suave: #9fb0d4;
  --papel: #f2fbfa;
  --tinta: #0b2330;
  --tinta-suave: #4a6470;
  --display: 'Manrope', system-ui, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, Consolas, monospace;
  --ancho: 1160px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--noche); color: var(--texto);
  font: 400 1.05rem/1.65 var(--display); -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--cian); outline-offset: 3px; border-radius: 4px; }
.wrap { max-width: var(--ancho); margin: 0 auto; padding: 0 24px; }
h1, h2, h3 { font-weight: 800; line-height: 1.1; letter-spacing: -.02em; margin: 0; }
.eyebrow { font: 600 .78rem/1 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--cian); margin-bottom: 14px; display: block; }

/* ---------- Botones ---------- */
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 15px 26px; border-radius: 12px; font-weight: 700; font-size: 1rem; border: 1.5px solid transparent; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s; font-family: inherit; }
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: linear-gradient(135deg, var(--cian), var(--azul)); color: #02222a; box-shadow: 0 10px 30px -10px rgba(45, 212, 191, .6); }
.btn--ghost { border-color: var(--linea); color: var(--texto); background: rgba(255, 255, 255, .03); }
.btn--ghost:hover { border-color: var(--cian); }
.btn--wa { background: #25d366; color: #052e16; }
.btn small { font-weight: 500; opacity: .75; }

/* ---------- Navegación ---------- */
.nav { position: sticky; top: 0; z-index: 50; transition: background .2s, box-shadow .2s; }
.nav.is-scrolled { background: rgba(6, 18, 26, .88); backdrop-filter: blur(12px); box-shadow: 0 1px 0 var(--linea); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.25rem; }
.brand svg { width: 30px; height: 30px; }
.brand small { font-weight: 500; font-size: .8rem; color: var(--suave); }
.nav__links { display: flex; align-items: center; gap: 28px; font-weight: 600; font-size: .95rem; color: var(--suave); }
.nav__links a:hover { color: var(--texto); }
.nav__links .btn { padding: 10px 18px; font-size: .9rem; color: #02222a; }
.nav__burger { display: none; background: none; border: 0; color: var(--texto); padding: 8px; cursor: pointer; }
.nav__burger svg { width: 28px; height: 28px; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 56px 0 96px; margin-top: -72px; padding-top: 150px;
  background: radial-gradient(900px 500px at 85% 10%, rgba(45, 212, 191, .18), transparent 60%), radial-gradient(700px 500px at 0% 0%, rgba(14, 165, 233, .25), transparent 60%), var(--noche); }
.hero::before { content: ""; position: absolute; inset: 0; background-image: linear-gradient(var(--linea) 1px, transparent 1px), linear-gradient(90deg, var(--linea) 1px, transparent 1px); background-size: 56px 56px; mask-image: radial-gradient(ellipse at 70% 30%, #000 0%, transparent 70%); opacity: .5; }
.hero .wrap { position: relative; display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px; border: 1px solid var(--linea); border-radius: 999px; font: 600 .78rem/1 var(--mono); color: var(--suave); background: rgba(255, 255, 255, .03); margin-bottom: 22px; }
.badge i { width: 8px; height: 8px; border-radius: 50%; background: var(--verde); box-shadow: 0 0 0 4px rgba(52, 211, 153, .2); }
.hero h1 { font-size: clamp(2.3rem, 5vw, 3.8rem); }
.hero h1 em { font-style: normal; background: linear-gradient(120deg, var(--cian), #7dd3fc); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 1.18rem; color: var(--suave); margin: 22px 0 32px; max-width: 34em; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; }
.hero__note { margin-top: 18px; font: 500 .8rem/1.5 var(--mono); color: var(--suave); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 44px; border-top: 1px solid var(--linea); padding-top: 24px; }
.stats b { display: block; font-size: 1.6rem; font-weight: 800; color: var(--texto); }
.stats span { font-size: .82rem; color: var(--suave); line-height: 1.3; display: block; }

/* Ventana simulada */
.demo { position: relative; }
.win { background: #07161f; border: 1px solid var(--linea); border-radius: 16px; box-shadow: 0 40px 80px -30px rgba(0, 0, 0, .7), 0 0 0 1px rgba(45, 212, 191, .08); overflow: hidden; }
.win__bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; background: var(--noche-2); border-bottom: 1px solid var(--linea); font: 500 .76rem/1 var(--mono); color: var(--suave); }
.win__bar i { width: 11px; height: 11px; border-radius: 50%; background: #334155; }
.win__bar i:nth-child(1) { background: #f87171; } .win__bar i:nth-child(2) { background: #fbbf24; } .win__bar i:nth-child(3) { background: #34d399; }
.win__bar span { margin-left: auto; color: var(--verde); }
.win__screen { position: relative; aspect-ratio: 16 / 10; background: linear-gradient(160deg, #0f3040, #08202d 70%); }
.win__screen .tile { position: absolute; border-radius: 8px; background: rgba(150, 200, 210, .1); border: 1px solid var(--linea); }
.tile--a { left: 6%; top: 10%; width: 46%; height: 34%; }
.tile--b { left: 56%; top: 10%; width: 36%; height: 22%; }
.tile--c { left: 6%; top: 52%; width: 30%; height: 36%; }
.tile--d { left: 42%; top: 40%; width: 50%; height: 48%; }
.tile i { display: block; height: 6px; margin: 12px; border-radius: 3px; background: rgba(150, 200, 210, .25); }
.tile i:nth-child(2) { width: 70%; } .tile i:nth-child(3) { width: 45%; background: rgba(45, 212, 191, .45); }
.cursor { position: absolute; left: 62%; top: 38%; width: 22px; height: 22px; transition: left 2.4s cubic-bezier(.5, 0, .2, 1), top 2.4s cubic-bezier(.5, 0, .2, 1); filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .5)); }
.chip { position: absolute; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: 12px; background: rgba(13, 23, 48, .92); border: 1px solid var(--linea); backdrop-filter: blur(8px); font-size: .78rem; box-shadow: 0 16px 40px -16px rgba(0, 0, 0, .8); }
.chip b { display: block; font: 700 .85rem/1.2 var(--mono); color: var(--texto); }
.chip span { color: var(--suave); font-size: .72rem; }
.chip svg { width: 22px; height: 22px; flex: none; }
.chip--id { right: -18px; top: 56px; }
.chip--lock { left: -22px; bottom: 42px; }

/* ---------- Secciones ---------- */
section { padding: 96px 0; }
.sec-head { max-width: 42em; margin-bottom: 52px; }
.sec-head h2 { font-size: clamp(1.8rem, 3.6vw, 2.7rem); }
.sec-head p { color: var(--suave); font-size: 1.1rem; margin: 16px 0 0; }
.light { background: var(--papel); color: var(--tinta); }
.light .sec-head p { color: var(--tinta-suave); }
.light .eyebrow { color: var(--azul); }

/* Problema */
.problema { background: var(--noche-2); border-block: 1px solid var(--linea); }
.pgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pcard { padding: 28px; border-radius: 16px; background: var(--panel); border: 1px solid var(--linea); }
.pcard .ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: rgba(248, 113, 113, .12); color: var(--rojo); margin-bottom: 18px; }
.pcard .ico svg { width: 22px; height: 22px; }
.pcard h3 { font-size: 1.15rem; margin-bottom: 8px; }
.pcard p { margin: 0; color: var(--suave); font-size: .98rem; }

/* Cómo funciona */
.pasos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; counter-reset: p; }
.paso { position: relative; padding: 32px 28px; background: #fff; border-radius: 18px; border: 1px solid #cfe8e6; box-shadow: 0 18px 40px -28px rgba(15, 27, 58, .35); }
.paso::before { counter-increment: p; content: "0" counter(p); font: 700 .85rem/1 var(--mono); color: var(--azul); display: block; margin-bottom: 18px; }
.paso h3 { font-size: 1.2rem; margin-bottom: 10px; }
.paso p { margin: 0; color: var(--tinta-suave); font-size: .98rem; }
.paso code { font: 600 .85em var(--mono); background: #d9f3ef; padding: 2px 6px; border-radius: 5px; color: var(--azul); }
.flujo { margin-top: 36px; padding: 28px; border-radius: 18px; background: var(--noche); color: var(--texto); display: grid; grid-template-columns: 1fr auto 1fr; gap: 20px; align-items: center; text-align: center; }
.flujo .nodo { padding: 18px; border: 1px solid var(--linea); border-radius: 14px; background: var(--noche-2); font-weight: 700; }
.flujo .nodo small { display: block; font: 500 .74rem/1.4 var(--mono); color: var(--suave); margin-top: 4px; }
.flujo .via { font: 600 .78rem/1.5 var(--mono); color: var(--cian); }
.flujo .via b { display: block; font-size: 1.4rem; letter-spacing: .2em; }
.flujo .senal { grid-column: 1 / -1; font: 500 .76rem/1.4 var(--mono); color: var(--suave); border-top: 1px dashed var(--linea); padding-top: 14px; }

/* Beneficios */
.bgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.bcard { padding: 30px; border-radius: 18px; background: linear-gradient(180deg, var(--panel), #0c2030); border: 1px solid var(--linea); transition: border-color .2s, transform .2s; }
.bcard:hover { border-color: rgba(45, 212, 191, .5); transform: translateY(-4px); }
.bcard .ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 18px; background: rgba(45, 212, 191, .12); color: var(--cian); }
.bcard .ico svg { width: 24px; height: 24px; }
.bcard h3 { font-size: 1.12rem; margin-bottom: 8px; }
.bcard p { margin: 0; color: var(--suave); font-size: .96rem; }
.bcard--wide { grid-column: span 2; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; }

/* Seguridad */
.seg { background: var(--noche-2); border-block: 1px solid var(--linea); }
.seg .wrap { display: grid; grid-template-columns: .9fr 1.1fr; gap: 56px; align-items: start; }
.seg ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.seg li { display: flex; gap: 14px; padding: 18px 20px; border-radius: 14px; background: var(--panel); border: 1px solid var(--linea); }
.seg li svg { width: 22px; height: 22px; color: var(--verde); flex: none; margin-top: 3px; }
.seg li b { display: block; margin-bottom: 2px; }
.seg li span { color: var(--suave); font-size: .94rem; }

/* Comparativa */
.tabla-wrap { overflow-x: auto; border-radius: 18px; border: 1px solid #cfe8e6; background: #fff; box-shadow: 0 18px 40px -28px rgba(15, 27, 58, .35); }
table { width: 100%; border-collapse: collapse; min-width: 720px; font-size: .96rem; }
th, td { padding: 16px 20px; text-align: left; border-bottom: 1px solid #dcefed; }
thead th { font-weight: 800; background: #e6f6f4; font-size: .9rem; }
thead th.us { background: var(--tinta); color: #fff; }
td.us { background: #effaf8; font-weight: 700; }
td.si { color: #047857; } td.no { color: #b91c1c; } td.med { color: #b45309; }
tbody tr:last-child td { border-bottom: 0; }

/* Servidores */
.srv { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.srv .it { padding: 28px; border-radius: 16px; background: var(--panel); border: 1px solid var(--linea); }
.srv .n { font: 700 .8rem/1 var(--mono); color: var(--ambar); margin-bottom: 14px; display: block; }
.srv h3 { font-size: 1.1rem; margin-bottom: 8px; }
.srv p { margin: 0; color: var(--suave); font-size: .96rem; }

/* Descarga + contacto */
.cta { background: radial-gradient(800px 400px at 50% 0%, rgba(14, 165, 233, .3), transparent 70%), var(--noche-2); border-top: 1px solid var(--linea); }
.cta .wrap { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.dl { display: grid; gap: 14px; margin-top: 28px; }
.dl .btn { justify-content: space-between; width: 100%; }
.reqs { margin: 22px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; font-size: .92rem; color: var(--suave); }
.reqs li::before { content: "✓"; color: var(--verde); font-weight: 800; margin-right: 10px; }
.form { padding: 32px; border-radius: 20px; background: var(--panel); border: 1px solid var(--linea); }
.form h3 { font-size: 1.4rem; margin-bottom: 6px; }
.form > p { margin: 0 0 22px; color: var(--suave); font-size: .96rem; }
.form label { display: block; margin-bottom: 16px; font: 600 .82rem/1 var(--mono); color: var(--suave); }
.form input, .form select { width: 100%; margin-top: 8px; padding: 14px 16px; border-radius: 10px; border: 1px solid var(--linea); background: var(--noche); color: var(--texto); font: 500 1rem var(--display); }
.form input:focus, .form select:focus { outline: 2px solid var(--cian); border-color: transparent; }
.form .btn { width: 100%; justify-content: center; margin-top: 6px; }
.contacto { margin-top: 18px; font-size: .9rem; color: var(--suave); text-align: center; }
.contacto a { color: var(--cian); }

/* Pie */
.pie { padding: 36px 0; border-top: 1px solid var(--linea); font-size: .9rem; color: var(--suave); background: var(--noche); }
.pie .wrap { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: center; }
.por-rsistems { display: inline-flex; align-items: center; gap: 10px; line-height: 1.25; }
.por-rsistems:hover strong { text-decoration: underline; }
.por-rsistems .logo-r { width: 38px; height: 31px; background: url('logo-rsistems.png') top center / 38px auto no-repeat; flex: none; }
.por-rsistems strong { display: block; color: var(--texto); letter-spacing: .02em; }

/* Animación */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .cursor { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero .wrap, .seg .wrap, .cta .wrap { grid-template-columns: 1fr; }
  .pgrid, .pasos, .bgrid, .srv { grid-template-columns: 1fr 1fr; }
  .bcard--wide { grid-column: 1 / -1; }
  .chip--id { right: 8px; } .chip--lock { left: 8px; }
}
@media (max-width: 760px) {
  section { padding: 64px 0; }
  .nav__burger { display: block; }
  .nav__links { position: absolute; left: 0; right: 0; top: 72px; flex-direction: column; align-items: stretch; gap: 0; padding: 8px 24px 20px; background: rgba(6, 18, 26, .97); border-bottom: 1px solid var(--linea); display: none; }
  .nav.is-open .nav__links { display: flex; }
  .nav__links a { padding: 14px 0; border-bottom: 1px solid var(--linea); }
  .nav__links .btn { margin-top: 14px; justify-content: center; }
  .pgrid, .pasos, .bgrid, .srv { grid-template-columns: 1fr; }
  .bcard--wide { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; gap: 20px; }
  .flujo { grid-template-columns: 1fr; }
  .hero { padding-bottom: 64px; }
  .chip { display: none; }
}

.pie__contacto a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.pie__contacto a:hover { color: #fff; }

/* Ventana de sincronización (hero) */
.sync { padding: 18px; display: grid; gap: 10px; }
.sync__row { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-radius: 10px; background: rgba(150, 200, 210, .07); border: 1px solid var(--linea); font: 500 .8rem/1.2 var(--mono); }
.sync__row svg { width: 18px; height: 18px; flex: none; color: var(--cian); }
.sync__row em { margin-left: auto; font-style: normal; font-size: .72rem; color: var(--verde); }
.sync__row--up em { color: var(--ambar); }
.sync__bar { height: 4px; border-radius: 2px; background: rgba(150, 200, 210, .15); overflow: hidden; margin-top: 4px; }
.sync__bar i { display: block; height: 100%; width: 70%; background: linear-gradient(90deg, var(--cian), var(--azul)); animation: subir 3.2s ease-in-out infinite; }
@keyframes subir { 0% { width: 8%; } 70% { width: 96%; } 100% { width: 96%; } }
@media (prefers-reduced-motion: reduce) { .sync__bar i { animation: none; width: 70%; } }
.timeline { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-top: 36px; }
.timeline div { padding: 22px; border-left: 2px solid var(--cian); background: #fff; border-radius: 0 14px 14px 0; margin-right: 10px; box-shadow: 0 14px 30px -24px rgba(11, 35, 48, .4); }
.timeline b { display: block; font: 700 .8rem/1 var(--mono); color: var(--azul); margin-bottom: 10px; }
.timeline span { font-size: .93rem; color: var(--tinta-suave); }
@media (max-width: 980px) { .timeline { grid-template-columns: 1fr 1fr; gap: 12px; } }
@media (max-width: 760px) { .timeline { grid-template-columns: 1fr; } }
.demo .chip--id { top: auto; bottom: -24px; right: -10px; }
.demo .chip--lock { bottom: -24px; left: -14px; }
.sync { padding: 28px 18px 34px; }
@media (max-width: 980px) { .demo .chip--id { right: 8px; } .demo .chip--lock { left: 8px; } .demo { margin: 22px 0; } }
