/* Penumbra — landing. Editorial nocturno: tinta de noche, luz de luna, titulares en serif. */
@property --pos { syntax: '<percentage>'; inherits: true; initial-value: 46%; }

:root {
  --ink: #0b0920;
  --ink-2: #110e2b;
  --night: #17133a;
  --night-2: #1f1a4a;
  --line: rgba(183, 173, 255, 0.14);
  --line-2: rgba(183, 173, 255, 0.26);
  --moon: #b7adff;
  --moon-2: #d9d3ff;
  --paper: #f3f1ff;
  --muted: #a7a1cf;
  --dim: #8781b5;
  --accent: #7b6cf6;
  --lamp: #f4e9c8;
  --ok: #34d399;
  --radius: 22px;
  --serif: "Instrument Serif", "New York", Georgia, serif;
  --sans: "DM Sans", system-ui, -apple-system, sans-serif;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font: 400 17px/1.6 var(--sans);
  font-optical-sizing: auto;
  overflow-x: hidden;
}
/* Cielo: estrellas muy tenues y grano, sobre la tinta. */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  background:
    radial-gradient(1px 1px at 12% 18%, rgba(243,241,255,.55) 50%, transparent 51%),
    radial-gradient(1px 1px at 72% 9%, rgba(243,241,255,.4) 50%, transparent 51%),
    radial-gradient(1.4px 1.4px at 86% 34%, rgba(243,241,255,.5) 50%, transparent 51%),
    radial-gradient(1px 1px at 28% 62%, rgba(243,241,255,.3) 50%, transparent 51%),
    radial-gradient(1px 1px at 55% 80%, rgba(243,241,255,.35) 50%, transparent 51%),
    radial-gradient(1.2px 1.2px at 92% 76%, rgba(243,241,255,.3) 50%, transparent 51%),
    radial-gradient(1px 1px at 6% 88%, rgba(243,241,255,.3) 50%, transparent 51%),
    radial-gradient(1200px 700px at 85% -10%, rgba(123,108,246,.16), transparent 60%),
    radial-gradient(900px 600px at -10% 110%, rgba(244,233,200,.05), transparent 60%),
    var(--ink);
}
body::after {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none; opacity: .07; mix-blend-mode: overlay;
  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='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

a { color: var(--moon-2); text-decoration-color: var(--line-2); text-underline-offset: 3px; }
a:hover { color: var(--paper); text-decoration-color: var(--moon); }
img { display: block; max-width: 100%; height: auto; }
:focus-visible { outline: 2px solid var(--moon); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(1160px, 100% - 40px); margin-inline: auto; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Cabecera ---------- */
.top { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  background: rgba(11, 9, 32, .62); border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--paper); text-decoration: none; font-weight: 600; letter-spacing: -.01em; }
.brand img { width: 30px; height: 30px; border-radius: 8px; }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: 15px; }
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover { color: var(--paper); }
.lang { font-size: 14px; color: var(--dim); text-decoration: none; border: 1px solid var(--line); padding: 6px 12px; border-radius: 999px; }
.lang:hover { color: var(--paper); border-color: var(--line-2); }
@media (max-width: 720px) { .nav { display: none; } .lang { margin-left: auto; } }

/* ---------- Hero ---------- */
.hero { padding: 72px 0 40px; }
.hero .wrap { display: grid; grid-template-columns: 1.1fr .9fr; gap: 56px; align-items: center; }
@media (max-width: 920px) { .hero .wrap { grid-template-columns: 1fr; gap: 40px; } .hero { padding-top: 40px; } }
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-size: 12.5px; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; color: var(--moon); }
.eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--moon); opacity: .6; }
h1, h2, h3 { font-weight: 400; margin: 0; }
h1 { font-family: var(--serif); font-size: clamp(48px, 7.4vw, 96px); line-height: .98; letter-spacing: -.02em; margin: 18px 0 22px; }
h1 em, h2 em { font-style: italic; color: var(--moon-2); }
.lede { font-size: clamp(18px, 1.6vw, 21px); color: var(--muted); max-width: 34ch; margin: 0 0 30px; }
.lede strong { color: var(--paper); font-weight: 500; }
.ctas { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.btn { display: inline-flex; align-items: center; gap: 10px; height: 54px; padding: 0 24px; border-radius: 999px;
  font-weight: 600; font-size: 16px; text-decoration: none; transition: transform .2s, background .2s, border-color .2s; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--paper); color: var(--night); }
.btn-primary:hover { color: var(--night); background: #fff; }
.btn-primary small { display: block; font-size: 11px; font-weight: 500; opacity: .65; line-height: 1; margin-top: 2px; }
.btn-primary span { display: flex; flex-direction: column; line-height: 1.15; }
.btn-ghost { color: var(--paper); border: 1px solid var(--line-2); }
.btn-ghost:hover { border-color: var(--moon); color: var(--paper); }
.trio { margin-top: 30px; display: flex; gap: 18px; font-family: var(--serif); font-size: 26px; color: var(--moon-2); font-style: italic; }
.trio span:not(:last-child)::after { content: "·"; margin-left: 18px; color: var(--dim); font-style: normal; }

/* ---------- Teléfono con antes/después ---------- */
.phone { position: relative; width: min(340px, 100%); margin-inline: auto; aspect-ratio: 1260 / 2736;
  border-radius: 52px; padding: 11px; background: linear-gradient(160deg, #2a2550, #0e0c24 40%, #1b1740);
  box-shadow: 0 0 0 1px rgba(183,173,255,.18), 0 40px 90px rgba(0,0,0,.6), 0 0 120px rgba(123,108,246,.18); }
.phone .screen { position: relative; width: 100%; height: 100%; border-radius: 42px; overflow: hidden; background: #000; }
.phone img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.phone.small { width: min(280px, 100%); border-radius: 44px; padding: 9px; }
.phone.small .screen { border-radius: 36px; }

.compare { --pos: 46%; }
.compare .dark { clip-path: inset(0 0 0 var(--pos)); }
.compare .terminator { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 2px; margin-left: -1px;
  background: linear-gradient(var(--lamp), var(--moon)); box-shadow: 0 0 18px rgba(183,173,255,.8); pointer-events: none; }
.compare .knob { position: absolute; top: 50%; left: var(--pos); width: 46px; height: 46px; margin: -23px 0 0 -23px;
  border-radius: 999px; background: var(--paper); color: var(--night); display: grid; place-items: center;
  box-shadow: 0 6px 20px rgba(0,0,0,.45); pointer-events: none; }
.compare .tag { position: absolute; top: 15%; padding: 5px 11px; border-radius: 999px; font-size: 12px; font-weight: 600; pointer-events: none; }
.compare .tag.before { left: 12px; background: rgba(17,17,17,.75); color: #fff; }
.compare .tag.after { right: 12px; background: var(--accent); color: #fff; }
.compare input[type=range] { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.compare.peek { animation: peek 2.6s cubic-bezier(.65,0,.35,1) .8s 1 both; }
@keyframes peek { 0% { --pos: 46%; } 35% { --pos: 78%; } 70% { --pos: 22%; } 100% { --pos: 46%; } }
.hint { text-align: center; color: var(--dim); font-size: 13px; margin-top: 16px; }

/* ---------- Secciones ---------- */
section { padding: 110px 0; position: relative; }
.kicker { font-size: 12.5px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--moon); margin-bottom: 18px; }
h2 { font-family: var(--serif); font-size: clamp(38px, 5vw, 64px); line-height: 1.02; letter-spacing: -.015em; margin-bottom: 22px; }
.section-lede { color: var(--muted); font-size: 19px; max-width: 52ch; margin: 0; }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.split.flip > :first-child { order: 2; }
@media (max-width: 880px) { .split { grid-template-columns: 1fr; gap: 44px; } .split.flip > :first-child { order: 0; } section { padding: 80px 0; } }

.points { list-style: none; padding: 0; margin: 30px 0 0; display: grid; gap: 18px; }
.points li { display: grid; grid-template-columns: 34px 1fr; gap: 14px; align-items: start; }
.points li svg { width: 34px; height: 34px; padding: 8px; border-radius: 11px; background: var(--night); border: 1px solid var(--line); color: var(--moon); }
.points b { display: block; font-weight: 600; color: var(--paper); margin-bottom: 2px; }
.points span { color: var(--muted); font-size: 16px; }

/* Franja con la frase grande */
.quote { padding: 90px 0; border-block: 1px solid var(--line); background: linear-gradient(180deg, transparent, rgba(23,19,58,.5), transparent); }
.quote p { font-family: var(--serif); font-size: clamp(30px, 4.2vw, 54px); line-height: 1.12; text-align: center; margin: 0 auto; max-width: 22ch; }
.quote p em { color: var(--lamp); }

/* Rejilla de detalles */
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 48px; }
@media (max-width: 900px) { .grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .grid { grid-template-columns: 1fr; } }
.card { padding: 26px; border-radius: var(--radius); background: linear-gradient(180deg, rgba(31,26,74,.55), rgba(17,14,43,.55));
  border: 1px solid var(--line); transition: border-color .25s, transform .25s; }
.card:hover { border-color: var(--line-2); transform: translateY(-2px); }
.card h3 { font-family: var(--sans); font-size: 18px; font-weight: 600; margin: 14px 0 6px; }
.card p { margin: 0; color: var(--muted); font-size: 15.5px; }
.card svg { width: 26px; height: 26px; color: var(--moon); }

/* Preguntas */
.faq { max-width: 820px; }
.faq details { border-top: 1px solid var(--line); padding: 4px 0; }
.faq details:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 22px 40px 22px 0; position: relative; font-size: 19px; font-weight: 500; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 6px; top: 16px; font-size: 28px; font-weight: 300; color: var(--moon); transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 22px; color: var(--muted); max-width: 68ch; }

/* Cierre */
.closing { text-align: center; padding: 130px 0 120px; }
.closing .moon { width: 120px; height: 120px; margin: 0 auto 30px; border-radius: 999px;
  box-shadow: inset -26px 10px 0 0 var(--moon), 0 0 80px rgba(183,173,255,.25); transform: rotate(-20deg); }
.closing h2 { margin-inline: auto; max-width: 16ch; }
.closing .ctas { justify-content: center; margin-top: 30px; }

/* Pie */
footer { border-top: 1px solid var(--line); padding: 44px 0 60px; color: var(--dim); font-size: 14px; }
footer .wrap { display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: start; }
footer nav { display: flex; gap: 20px; flex-wrap: wrap; }
footer nav a { color: var(--muted); text-decoration: none; }
footer nav a:hover { color: var(--paper); }
footer .credits { grid-column: 1 / -1; font-size: 12.5px; line-height: 1.6; }
@media (max-width: 640px) { footer .wrap { grid-template-columns: 1fr; } }

/* Páginas de texto (privacidad, soporte) */
.doc { padding: 70px 0 100px; }
.doc .wrap { max-width: 760px; }
.doc h1 { font-size: clamp(44px, 6vw, 72px); margin-bottom: 10px; }
.doc .updated { color: var(--dim); font-size: 14px; margin-bottom: 40px; }
.doc h2 { font-size: 32px; margin: 46px 0 12px; }
.doc p, .doc li { color: var(--muted); }
.doc li { margin-bottom: 8px; }
.doc strong { color: var(--paper); font-weight: 600; }
.callout { padding: 22px 24px; border-radius: 18px; background: var(--night); border: 1px solid var(--line-2); color: var(--paper); margin: 26px 0; }
.callout b { color: var(--ok); }

/* Aparición al desplazar (si el navegador lo soporta) */
@supports (animation-timeline: view()) {
  .reveal { animation: reveal linear both; animation-timeline: view(); animation-range: entry 0% cover 28%; }
  @keyframes reveal { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
}
.load > * { animation: rise .9s cubic-bezier(.2,.7,.2,1) both; }
.load > *:nth-child(2) { animation-delay: .08s; } .load > *:nth-child(3) { animation-delay: .16s; }
.load > *:nth-child(4) { animation-delay: .24s; } .load > *:nth-child(5) { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
