/* ════════════════════════════════════════════════════════════════
   alxn_dev_ai — landing. Identidad de marca premium sobre negro.
   Sin framework. Una sola hoja. Scroll-driven por JS mínimo (rAF).
   ════════════════════════════════════════════════════════════════ */

@font-face {
  font-family: "InterTight";
  src: url("/fonts/intertight-var.woff2") format("woff2");
  font-weight: 300 900;
  font-display: swap;
}
@font-face {
  font-family: "JBMono";
  src: url("/fonts/jbmono-var.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
}

:root {
  /* paleta v2: violeta eléctrico + menta sobre negro azulado (colores del personaje) */
  --bg: #050609;
  --bg2: #0a0b12;
  --ink: #eef0f8;
  --ink-dim: #8e93a9;
  --gold: #8b5cf6;
  --gold-hi: #b9a0ff;
  --green: #2ee6a8;
  --violet: #6d28d9;
  --orange: #ff5e8a;
  --line: rgba(139, 92, 246, 0.22);
  --serif: "InterTight", system-ui, sans-serif;
  --sans: "InterTight", system-ui, sans-serif;
  --mono: "JBMono", ui-monospace, "SF Mono", Menlo, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 410;
  line-height: 1.6;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
b { font-weight: 640; }

::selection { background: var(--gold); color: var(--bg); }

/* ── atmósfera ── */
.grain {
  position: fixed; inset: 0; z-index: 60; pointer-events: none;
  opacity: 0.16; 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='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.35 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}
@keyframes grain {
  0% { transform: translate(0, 0); }
  25% { transform: translate(-2%, 3%); }
  50% { transform: translate(3%, -2%); }
  75% { transform: translate(-3%, -3%); }
  100% { transform: translate(2%, 2%); }
}

.progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 70;
  background: rgba(210, 164, 74, 0.12);
}
.progress span {
  display: block; height: 100%; width: 100%;
  background: linear-gradient(90deg, var(--gold), var(--green));
  transform: scaleX(0); transform-origin: left;
}

/* ── cursor (solo pointer fino) ── */
.cursor { display: none; }
@media (hover: hover) and (pointer: fine) {
  .cursor { display: block; position: fixed; inset: 0; z-index: 80; pointer-events: none; }
  .cursor i { position: absolute; border-radius: 50%; will-change: transform; }
  #dot { width: 6px; height: 6px; background: var(--gold-hi); margin: -3px; }
  #halo {
    width: 38px; height: 38px; margin: -19px;
    border: 1px solid rgba(210, 164, 74, 0.5);
    transition: width 0.25s, height 0.25s, margin 0.25s, border-color 0.25s;
  }
  body.cur-link #halo {
    width: 64px; height: 64px; margin: -32px;
    border-color: var(--green);
  }
}

/* ── tipografía base ── */
.eyebrow {
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--gold);
}
.mono { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.14em; color: var(--ink-dim); }
.h2 {
  font-family: var(--serif); font-weight: 680;
  font-size: clamp(2.2rem, 5.5vw, 4.2rem);
  line-height: 1.02; margin: 0.5rem 0 1.2rem;
  letter-spacing: -0.02em; text-wrap: balance;
}

/* ── reveals ── */
[data-r] {
  opacity: 0; transform: translateY(26px);
  transition: opacity 0.5s cubic-bezier(0.2, 0.6, 0.2, 1) var(--d, 0s),
              transform 0.5s cubic-bezier(0.2, 0.6, 0.2, 1) var(--d, 0s);
}
[data-r].in { opacity: 1; transform: none; }

/* ── nav ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0.9rem clamp(1rem, 4vw, 3rem);
  background: linear-gradient(rgba(5, 6, 9, 0.88), transparent);
}
.nav-brand { display: flex; align-items: center; gap: 0.6rem; }
.nav-brand img { width: 34px; height: auto; filter: drop-shadow(0 0 6px rgba(122, 77, 255, 0.5)); }
.nav-brand span { font-family: var(--mono); font-size: 0.95rem; letter-spacing: 0.06em; }
.nav-brand b { color: var(--gold); }
.nav-links { display: flex; align-items: center; gap: 1.6rem; font-size: 0.86rem; }
.nav-links a { color: var(--ink-dim); transition: color 0.2s; }
.nav-links a:hover { color: var(--gold-hi); }
.nav-cta {
  color: var(--bg) !important; background: var(--gold);
  padding: 0.45rem 1rem; border-radius: 2rem; font-weight: 640;
}
.nav-cta:hover { background: var(--gold-hi); }
@media (max-width: 720px) { .nav-links a:not(.nav-cta) { display: none; } }

/* ── hero ── */
.hero {
  position: relative; min-height: 100svh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  padding: clamp(5rem, 12vh, 8rem) clamp(1.2rem, 5vw, 4rem) clamp(4.5rem, 10vh, 6rem);
  overflow: clip;
}
#fx { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; }
/* piso en perspectiva — el escenario */
.hero-grid {
  z-index: 1;
  position: absolute; left: -20%; right: -20%; bottom: -2%; height: 48%;
  pointer-events: none;
  background:
    linear-gradient(rgba(210, 164, 74, 0.16) 1px, transparent 1px),
    linear-gradient(90deg, rgba(210, 164, 74, 0.16) 1px, transparent 1px);
  background-size: 56px 56px;
  transform: perspective(420px) rotateX(62deg);
  transform-origin: 50% 0;
  mask-image: radial-gradient(65% 90% at 50% 0%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(65% 90% at 50% 0%, #000 30%, transparent 78%);
}
/* celdas del piso que se encienden (reposicionadas por JS) */
.hero-grid .cell {
  position: absolute; width: 55px; height: 55px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.5), rgba(46, 230, 168, 0.25));
  opacity: 0;
  animation: cell 2.8s ease-in-out infinite;
}
.hero-grid .cell:nth-child(2) { animation-delay: 0.5s; }
.hero-grid .cell:nth-child(3) { animation-delay: 0.9s; }
.hero-grid .cell:nth-child(4) { animation-delay: 1.4s; }
.hero-grid .cell:nth-child(5) { animation-delay: 1.8s; }
.hero-grid .cell:nth-child(6) { animation-delay: 2.2s; }
.hero-grid .cell:nth-child(7) { animation-delay: 2.5s; }
@keyframes cell { 0%, 100% { opacity: 0; } 45% { opacity: 0.85; } }
/* meteoros: ráfagas de luz diagonales */
.meteors { position: absolute; inset: 0; pointer-events: none; overflow: clip; }
.meteors i {
  position: absolute; top: -8%;
  width: 1px; height: 110px;
  background: linear-gradient(180deg, transparent, var(--gold-hi) 55%, transparent);
  opacity: 0;
  transform: rotate(38deg);
  animation: meteor 7s linear infinite;
}
.meteors i:nth-child(1) { left: 16%; animation-delay: 0s; }
.meteors i:nth-child(2) { left: 38%; animation-delay: 2.4s; height: 80px; }
.meteors i:nth-child(3) { left: 64%; animation-delay: 4.1s; }
.meteors i:nth-child(4) { left: 84%; animation-delay: 5.6s; height: 70px; }
@keyframes meteor {
  0%, 12% { opacity: 0; transform: rotate(38deg) translateY(0); }
  14% { opacity: 0.9; }
  26% { opacity: 0; transform: rotate(38deg) translateY(64vh); }
  100% { opacity: 0; transform: rotate(38deg) translateY(64vh); }
}
.hero-lockup {
  position: relative; z-index: 2;
  display: flex; flex-direction: column; align-items: center;
  text-align: center;
}
.badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.08em;
  color: var(--ink-dim);
  border: 1px solid var(--line); border-radius: 2rem;
  padding: 0.45rem 1rem;
  background: rgba(20, 17, 13, 0.6);
  transition: border-color 0.2s, color 0.2s;
}
.badge:hover { border-color: var(--gold); color: var(--gold-hi); }
.badge-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 8px var(--green);
  animation: blink 2.2s ease-in-out infinite;
}
.hero-mark {
  font-family: var(--serif); font-weight: 800;
  font-size: clamp(2.7rem, 8.5vw, 6rem);
  letter-spacing: -0.04em; line-height: 1.04;
  margin-top: 1.6rem;
  text-wrap: balance;
}
/* stagger: cada palabra sube desde su clip */
.hw-clip { display: inline-block; overflow: clip; vertical-align: bottom; }
.hw {
  display: inline-block;
  transform: translateY(115%) rotate(3deg);
  transition: transform 0.9s cubic-bezier(0.16, 1, 0.3, 1) calc(var(--i, 0) * 80ms);
}
.hero-mark.go .hw { transform: none; }
.hero-mark em { font-style: normal; color: var(--gold); }
.hero-mark em .hw {
  background: linear-gradient(120deg, var(--gold-hi), var(--gold) 60%, #b8862e);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-line {
  margin-top: 1.2rem; color: var(--ink-dim);
  font-size: clamp(0.98rem, 2.2vw, 1.15rem);
  max-width: 36rem;
}
.hero-actions { display: flex; gap: 0.9rem; margin-top: 2.2rem; flex-wrap: wrap; justify-content: center; }
/* personaje sobre el escenario */
.stage { position: relative; z-index: 2; margin: 2.4rem 0 0; will-change: transform; transform-style: preserve-3d; }
.stage .hero-char { position: relative; z-index: 1; }
.stage-glow {
  position: absolute; left: 50%; bottom: -6px;
  width: 130%; height: 44px;
  transform: translateX(-50%);
  background: radial-gradient(50% 100% at 50% 50%, rgba(210, 164, 74, 0.55), rgba(122, 77, 255, 0.18) 60%, transparent 75%);
  filter: blur(10px);
}

.btn {
  font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.08em;
  padding: 0.8rem 1.5rem; border-radius: 2rem;
  border: 1px solid var(--line);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.3, 1.4), background 0.2s, border-color 0.2s;
  will-change: transform;
}
.btn-gold { background: var(--gold); color: var(--bg); border-color: var(--gold); font-weight: 700; }
.btn-gold:hover { background: var(--gold-hi); }
.btn-ghost:hover { border-color: var(--gold); }

.hero-art { margin: 0; }
.hero-char {
  width: clamp(150px, 22vh, 230px);
  filter: drop-shadow(0 24px 50px rgba(0, 0, 0, 0.6));
}

.hero-orbs { position: absolute; inset: 0; pointer-events: none; }
.orb {
  position: absolute; border-radius: 50%; filter: blur(2px);
  will-change: transform;
}
.orb-a { width: 14px; height: 14px; top: 22%; left: 12%; background: var(--gold-hi); box-shadow: 0 0 30px 8px rgba(240, 200, 122, 0.45); }
.orb-b { width: 10px; height: 10px; top: 14%; right: 18%; background: #6db5ff; box-shadow: 0 0 26px 7px rgba(109, 181, 255, 0.4); }
.orb-c { width: 12px; height: 12px; bottom: 20%; right: 8%; background: var(--violet); box-shadow: 0 0 30px 8px rgba(122, 77, 255, 0.45); }

.scroll-cue {
  position: absolute; bottom: 1.4rem; left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
}
.scroll-cue span {
  width: 1px; height: 42px; background: var(--gold);
  animation: cue 1.8s ease-in-out infinite; transform-origin: top;
}
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(0); transform-origin: bottom; } }

@media (max-width: 860px) {
  .hero { padding-top: 5.5rem; }
}

/* ── capítulos manifiesto (revelado palabra por palabra) ── */
.chapter { height: 175vh; position: relative; }
.chapter-sticky {
  position: sticky; top: 0; height: 100svh; overflow: clip;
  display: flex; flex-direction: column; justify-content: center;
  max-width: 950px; margin: 0 auto;
  padding: 0 clamp(1.2rem, 5vw, 3rem);
}
.chapter-n {
  color: var(--green); font-size: 0.85rem; margin-bottom: 1.6rem;
}
.chapter-text {
  font-family: var(--serif); font-weight: 780;
  font-size: clamp(2.4rem, 6.2vw, 4.8rem);
  line-height: 1.06; letter-spacing: -0.03em;
  text-wrap: balance;
}
.chapter-text { will-change: transform; transform-origin: 50% 50%; }
.chapter-text .w { opacity: 0.14; }
.chapter-text em { font-style: normal; color: var(--gold); margin-left: 0.28em; }

/* ── ticker ── */
.ticker {
  border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  overflow: clip; background: var(--bg2);
  padding: 1.1rem 0; white-space: nowrap;
}
.ticker-track { display: inline-flex; will-change: transform; }
@media (prefers-reduced-motion: no-preference) {
  .no-js .ticker-track { animation: tick 40s linear infinite; }
}
.ticker-track span {
  font-family: var(--mono); font-weight: 400;
  font-size: 0.72rem; letter-spacing: 0.3em;
  color: var(--ink-dim);
}
@keyframes tick { to { transform: translateX(-50%); } }

/* ── forja (scrollytelling) ── */
.forge { height: 420vh; position: relative; }
.forge-sticky {
  position: sticky; top: 0; height: 100svh; overflow: clip;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1.1fr);
  gap: clamp(1.5rem, 4vw, 4rem); align-items: center;
  padding: 0 clamp(1.2rem, 5vw, 4.5rem);

}
.forge-head { align-self: center; }
.forge-note { color: var(--ink-dim); font-size: 0.92rem; }
@media (max-width: 900px) { .forge-note { display: none; } }

/* ── iPhone 17 Pro Max ── */
.phone {
  position: relative; width: clamp(230px, 25vw, 310px); aspect-ratio: 9 / 19.5;
  perspective: 1400px;
}
.phone-core {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d; will-change: transform;
}
.phone-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  border-radius: clamp(34px, 4vw, 46px); overflow: hidden;
  /* filo de aluminio naranja + bisel negro uniforme, como el frontal real */
  border: 2.5px solid #d8601a;
  box-shadow:
    inset 0 0 0 5px #020305,
    0 30px 70px rgba(0, 0, 0, 0.7),
    0 0 60px rgba(247, 104, 31, 0.12);
}
.phone-screen { background: #05060b; transform: translateZ(9px); }
/* canto de titanio: capas apiladas en Z forman la pared lateral real */
.rim {
  position: absolute; inset: 0;
  border-radius: clamp(34px, 4vw, 46px);
  border: 3px solid #e0651f;
  transform: translateZ(var(--z));
  pointer-events: none;
}
.rim:nth-child(odd) { border-color: #c4540f; }
/* botones físicos: acción + vol arriba/abajo (izq), encendido (der) — alturas reales */
.pbtn {
  position: absolute; width: 3.5px; border-radius: 2px;
  background: linear-gradient(90deg, #ff9143, #c4540f);
  transform: translateZ(0);
}
.pb-act { left: -3.5px; top: 17.5%; height: 4.2%; }
.pb-vup { left: -3.5px; top: 24.5%; height: 6.4%; }
.pb-vdn { left: -3.5px; top: 32.5%; height: 6.4%; }
.pb-pwr { right: -3.5px; top: 26.5%; height: 11.5%; }
/* isla dinámica */
.island {
  position: absolute; top: 1.65%; left: 50%; transform: translateX(-50%);
  z-index: 2;
  display: flex; align-items: center; justify-content: center; gap: 5px;
  width: 92px; height: 24px; border-radius: 14px;
  background: #000;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.05);
  animation: island 7s ease-in-out infinite;
}
.island::after {
  content: ""; position: absolute; right: 7px; top: 50%;
  width: 9px; height: 9px; border-radius: 50%;
  transform: translateY(-50%);
  background: radial-gradient(circle at 35% 35%, #2a3550 18%, #0a0d18 55%);
}
.island .mono { font-size: 0.5rem; letter-spacing: 0.18em; color: #d8dae6; }
.island-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #ff4545; box-shadow: 0 0 7px #ff4545;
  animation: blink 1.4s steps(2) infinite;
}
@keyframes island {
  0%, 78%, 100% { width: 92px; }
  84%, 94% { width: 132px; }
}
/* trasera: render real del iPhone 17 Pro naranja */
.phone-back {
  transform: rotateY(180deg) translateZ(9px);
  background: #c44f12;
}
.back-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
}
.back-char {
  position: absolute; left: 50%; top: 56%;
  transform: translate(-50%, -50%);
  width: 30%; height: auto;
  filter: drop-shadow(0 6px 14px rgba(60, 20, 0, 0.5));
}
.back-tag {
  position: absolute; left: 0; right: 0; bottom: 6.5%;
  text-align: center; font-size: 0.52rem; color: #5a2807;
}
/* ── iOS: barra de estado + indicador de inicio ── */
.statusbar {
  position: absolute; top: 1.65%; height: 24px; left: 0; right: 0; z-index: 2;
  display: flex; justify-content: space-between; align-items: center;
  padding: 0 7.5%;
  font-family: var(--mono); font-size: 0.62rem; font-weight: 600;
  color: #f4f5fa; letter-spacing: 0.02em;
  pointer-events: none;
}
.sb-right { display: flex; align-items: center; gap: 5px; }
.sb-bars { font-size: 0.45rem; letter-spacing: -1px; }
.sb-5g { font-size: 0.5rem; }
.sb-bat {
  width: 19px; height: 9px; border-radius: 3px;
  border: 1px solid rgba(244, 245, 250, 0.5);
  position: relative;
}
.sb-bat::before {
  content: ""; position: absolute; inset: 1px;
  width: 68%; border-radius: 1.5px; background: #f4f5fa;
}
.sb-bat::after {
  content: ""; position: absolute; right: -3px; top: 2.5px;
  width: 1.5px; height: 4px; border-radius: 1px;
  background: rgba(244, 245, 250, 0.5);
}
.home-ind {
  position: absolute; bottom: 7px; left: 50%; transform: translateX(-50%);
  width: 36%; height: 4px; border-radius: 2px;
  background: rgba(244, 245, 250, 0.85);
  z-index: 2;
}
/* terminal: el pipeline corriendo en vivo */
.term {
  position: absolute; inset: 0;
  padding: 2.4rem 0.85rem 1rem;
  font-family: var(--mono); font-size: 0.6rem; line-height: 1.9;
  color: var(--ink-dim); text-align: left;
  display: flex; flex-direction: column;
}
.term-line { opacity: 0; transform: translateY(6px); transition: opacity 0.25s, transform 0.25s; white-space: pre; }
.term-line.on { opacity: 1; transform: none; }
.term-line i { font-style: normal; color: var(--green); }
.term-line b { font-weight: 500; color: var(--orange); }
.term-line.gold { color: var(--gold-hi); }
.term-logo {
  margin: auto auto 0.4rem; opacity: 0; transform: scale(0.7);
  transition: opacity 0.6s, transform 0.6s cubic-bezier(0.2, 0.9, 0.3, 1.3);
}
.term-logo.on { opacity: 1; transform: none; }
.term-logo img { width: clamp(80px, 9vw, 120px); height: auto; }
.term-caret {
  position: absolute; left: 1.1rem; bottom: 1.5rem;
  width: 8px; height: 14px; background: var(--green);
  animation: blink 1.1s steps(2) infinite;
}

.forge-steps { list-style: none; position: relative; min-height: 16rem; }
.step {
  position: absolute; inset: 0; max-width: 26rem;
  opacity: 0; transform: translateY(18px);
  transition: opacity 0.4s, transform 0.4s;
  pointer-events: none;
}
.step.on { opacity: 1; transform: none; }
.step-n {
  color: var(--green); font-size: 0.85rem;
  display: inline-block; margin-bottom: 0.6rem;
}
.step h3 {
  font-family: var(--serif); font-size: clamp(2rem, 3.8vw, 3.1rem);
  font-weight: 760; letter-spacing: -0.02em; margin-bottom: 0.7rem;
}
.step p { font-size: 1.02rem; }
.step p { color: var(--ink-dim); }

@media (max-width: 900px) {
  .term { font-size: 0.5rem; padding: 2.2rem 0.7rem 1rem; }
  .forge { height: 340vh; }
  .forge-sticky {
    grid-template-columns: 1fr;
    /* la fila de pasos nunca colapsa: el sticky tiene overflow:clip y cortaba el texto */
    grid-template-rows: auto auto minmax(10.5rem, 1fr);
    justify-items: center; text-align: center;
    padding: 4.5rem 0 max(1.2rem, env(safe-area-inset-bottom)) 0;
    gap: 1rem;
  }
  .forge-head .h2 { font-size: clamp(1.8rem, 7vw, 2.6rem); }
  .phone { width: min(272px, 64vw); margin-block: 0.4rem; }
  .forge-steps { width: 100%; min-height: 10.5rem; }
  .step { left: 0; right: 0; margin: 0 auto; inset-block: 0 auto; padding: 0 1.2rem; }
  .step h3 { font-size: 1.45rem; margin-bottom: 0.45rem; }
  .step p { font-size: 0.9rem; line-height: 1.45; }
  .step-n { margin-bottom: 0.3rem; }
}
/* pantallas cortas (SE / landscape): todo más compacto para que nada se recorte */
@media (max-width: 900px) and (max-height: 720px) {
  .forge-sticky { padding-top: 4.4rem; gap: 0.55rem; }
  .forge-head .h2 { font-size: 1.55rem; }
  .phone { width: min(196px, 50vw); }
  .step h3 { font-size: 1.25rem; }
  .step p { font-size: 0.84rem; }
}

/* ── quién soy ── */
.who {
  display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(2.5rem, 6vw, 6rem); align-items: center;
  padding: clamp(5rem, 14vh, 9rem) clamp(1.2rem, 5vw, 4.5rem);
  max-width: 1200px; margin: 0 auto;
  border-top: 1px solid var(--line);
}
.who-card { justify-self: center; text-align: center; perspective: 1400px; }
.idcard {
  width: min(340px, 84vw); aspect-ratio: 0.66;
  cursor: pointer; outline: none;
  transform-style: preserve-3d;
  will-change: transform;
}
.idcard-inner {
  position: relative; width: 100%; height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.3, 0.8, 0.3, 1);
}
.idcard.flipped .idcard-inner { transform: rotateY(180deg); }
.idcard-face {
  position: absolute; inset: 0; backface-visibility: hidden;
  border-radius: 20px; overflow: hidden;
  border: 1px solid var(--line);
  background:
    linear-gradient(160deg, rgba(210, 164, 74, 0.07), transparent 40%),
    var(--bg2);
  box-shadow: 0 40px 80px rgba(0, 0, 0, 0.65);
  display: flex; flex-direction: column;
  padding: 1.3rem 1.4rem;
  text-align: left;
}
.idcard-top {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 1rem;
}
.idcard-top .mono { color: var(--gold); font-size: 0.62rem; }
.idcard-chip {
  width: 30px; height: 22px; border-radius: 5px;
  background: linear-gradient(135deg, var(--gold-hi), var(--gold) 55%, #8a6320);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35);
}
.idcard-photo {
  width: 104px; height: 104px; object-fit: cover;
  border-radius: 14px; border: 1px solid var(--line);
  filter: saturate(0.9);
  margin-bottom: 1rem;
}
.idcard-name {
  font-family: var(--serif); font-weight: 720;
  font-size: 1.55rem; letter-spacing: -0.02em; line-height: 1.05;
}
.idcard-role { margin-top: 0.35rem; color: var(--green); font-size: 0.6rem; }
.idcard-rows { margin-top: 1.1rem; display: grid; gap: 0.55rem; }
.idcard-rows div { display: flex; gap: 0.8rem; }
.idcard-rows dt { color: var(--ink-dim); font-size: 0.6rem; width: 3.4rem; flex-shrink: 0; }
.idcard-rows dd { color: var(--ink); font-size: 0.64rem; }
.idcard-bar {
  margin-top: auto; height: 30px;
  background: repeating-linear-gradient(90deg,
    var(--ink) 0 2px, transparent 2px 5px, var(--ink) 5px 6px, transparent 6px 11px,
    var(--ink) 11px 14px, transparent 14px 17px);
  opacity: 0.55;
}
.idcard-glare {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(300px 300px at var(--gx, 50%) var(--gy, 30%), rgba(240, 200, 122, 0.16), transparent 60%);
  opacity: 0; transition: opacity 0.3s;
}
.idcard:hover .idcard-glare { opacity: 1; }
.idcard-back {
  transform: rotateY(180deg);
  align-items: center; justify-content: center; gap: 1rem;
  background:
    radial-gradient(60% 50% at 50% 35%, rgba(122, 77, 255, 0.18), transparent 70%),
    var(--bg2);
}
.idcard-back img { width: 58%; height: auto; }
.idcard-back .mono { font-size: 0.6rem; }
.flip-hint { margin-top: 1.1rem; }
.who-copy p:not(.eyebrow) { color: var(--ink-dim); max-width: 32rem; margin-bottom: 1rem; }
.who-copy b { color: var(--ink); }
@media (max-width: 860px) { .who { grid-template-columns: 1fr; } }

/* ── cierre: sígueme ── */
.join {
  position: relative;
  max-width: 1100px; margin: 0 auto;
  padding: clamp(5rem, 14vh, 9rem) clamp(1.2rem, 5vw, 4.5rem);
  border-top: 1px solid var(--line);
  text-align: center;
  overflow: clip;
}
.join-glow {
  position: absolute; left: 50%; top: -10%;
  width: 80vw; height: 60%;
  transform: translateX(-50%);
  background: radial-gradient(50% 60% at 50% 30%, rgba(139, 92, 246, 0.16), transparent 70%);
  pointer-events: none;
}
.join-big {
  font-family: var(--serif); font-weight: 800;
  font-size: clamp(2.6rem, 7.5vw, 5.6rem);
  letter-spacing: -0.035em; line-height: 1.0;
  margin: 0.6rem 0 3rem;
  text-wrap: balance;
  position: relative;
}
.join-big em { font-style: normal; color: var(--gold-hi); }
.stats {
  display: flex; justify-content: center; align-items: stretch;
  gap: clamp(1.2rem, 4vw, 3rem); flex-wrap: wrap;
  margin-bottom: 3.5rem; position: relative;
}
.stat-sep { width: 1px; background: var(--line); }
.stat-n {
  font-family: var(--serif); font-weight: 800;
  font-size: clamp(2.6rem, 6vw, 4.2rem);
  line-height: 1;
  background: linear-gradient(180deg, var(--ink), var(--gold-hi));
  -webkit-background-clip: text; background-clip: text; color: transparent;
  font-variant-numeric: tabular-nums;
}
.stats dd { margin-top: 0.5rem; font-size: 0.56rem; }
/* índice editorial: filas full-width con fill de color por plataforma */
.join-index {
  border-top: 1px solid var(--line);
  text-align: left; position: relative;
}
.join-row {
  position: relative;
  display: flex; align-items: center; gap: clamp(1rem, 3vw, 2.4rem);
  padding: clamp(1.3rem, 3vw, 2rem) clamp(0.6rem, 2vw, 1.6rem);
  border-bottom: 1px solid var(--line);
  overflow: clip;
  isolation: isolate;
}
.join-row::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--c);
  transform: scaleY(0); transform-origin: bottom;
  transition: transform 0.38s cubic-bezier(0.7, 0, 0.2, 1);
}
.join-row:hover::before { transform: scaleY(1); }
.join-row strong {
  font-family: var(--serif); font-weight: 780;
  font-size: clamp(2rem, 6vw, 4rem); letter-spacing: -0.03em; line-height: 1;
  transition: color 0.3s, transform 0.3s;
}
.join-h { margin-left: auto; transition: color 0.3s; }
.join-n { transition: color 0.3s; }
.join-arrow {
  color: var(--gold); font-size: clamp(1.6rem, 3.5vw, 2.4rem);
  transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.3, 1.4), color 0.3s;
}
.join-row:hover strong { color: #07080f; transform: translateX(10px); }
.join-row:hover .join-h, .join-row:hover .join-n { color: rgba(7, 8, 15, 0.7); }
.join-row:hover .join-arrow { color: #07080f; transform: translate(6px, -6px) rotate(8deg); }
@media (max-width: 640px) { .join-h { display: none; } }
.join-cmd { margin-top: 2.6rem; color: var(--green); }
.join-cmd .blink { margin-left: 0.4rem; }

/* ── cohete: el personaje llega con propulsión ── */
.rocket {
  position: absolute; right: clamp(0.5rem, 6vw, 6rem); top: 16%;
  z-index: 3; will-change: transform;
}
.rocket-body { position: relative; transform: rotate(-12deg); }
.rocket-body img {
  width: clamp(78px, 9vw, 130px); height: auto;
  filter: drop-shadow(0 14px 26px rgba(0, 0, 0, 0.55));
}
/* modo armadura: tinte metálico rojizo hasta que se quita el casco */
.rk-char.suited {
  filter: sepia(0.5) saturate(2.1) hue-rotate(-28deg) contrast(1.15) brightness(0.9)
          drop-shadow(0 14px 26px rgba(0, 0, 0, 0.55));
}
.armor {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.5));
}
.armor #helmet, .armor #hmplate { will-change: transform, opacity; }
.reactor {
  position: absolute; top: 49%; left: 49%;
  width: 14px; height: 14px; border-radius: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, #ffffff 18%, #9be8ff 45%, rgba(60, 180, 255, 0.25) 70%, transparent);
  box-shadow: 0 0 16px 5px rgba(120, 210, 255, 0.65);
  animation: reactor 1.3s ease-in-out infinite;
}
@keyframes reactor { 50% { box-shadow: 0 0 26px 9px rgba(120, 210, 255, 0.9); } }
.jetfx {
  position: absolute; left: 50%; bottom: -245px;
  transform: translateX(-50%);
  pointer-events: none;
}
.bubble {
  position: absolute; right: 70%; top: -14%;
  width: max-content; max-width: 200px;
  font-family: var(--sans); font-size: 0.86rem; text-align: left;
  color: var(--ink);
  background: var(--bg2);
  border: 1px solid var(--gold);
  border-radius: 16px 16px 4px 16px;
  padding: 0.8rem 1rem;
  cursor: pointer;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.5), 0 0 30px rgba(139, 92, 246, 0.18);
  transform-origin: 100% 100%;
}
.bubble b { display: block; color: var(--gold-hi); margin-top: 0.25rem; font-weight: 700; }
.bubble:hover { border-color: var(--gold-hi); }
@media (max-width: 860px) {
  /* el cohete no puede pisar el headline: arriba-derecha, más chico */
  .rocket { top: 1.5%; right: 0.5%; transform: scale(0.72); transform-origin: top right; }
  .rocket-body img { width: 72px; }
  .bubble { right: 55%; top: -24%; font-size: 0.72rem; }
}

/* ── modal de satisfacción ── */
.fb-overlay[hidden] { display: none; }
.fb-overlay {
  position: fixed; inset: 0; z-index: 90;
  display: flex; align-items: center; justify-content: center;
  background: rgba(5, 6, 12, 0.72);
  backdrop-filter: blur(6px);
  padding: 1rem;
}
.fb-modal {
  position: relative;
  width: min(440px, 94vw);
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(139, 92, 246, 0.14), transparent 60%),
    var(--bg2);
  border: 1px solid var(--line); border-radius: 24px;
  padding: 2rem 1.8rem 1.8rem;
  box-shadow: 0 50px 110px rgba(0, 0, 0, 0.7);
  will-change: transform;
}
.fb-x {
  position: absolute; top: 0.9rem; right: 0.9rem;
  width: 34px; height: 34px; border-radius: 50%;
  background: none; border: 1px solid var(--line);
  color: var(--ink-dim); font-size: 0.85rem; cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.fb-x:hover { border-color: var(--gold); color: var(--ink); }
.fb-title {
  font-family: var(--serif); font-weight: 780;
  font-size: clamp(1.7rem, 5vw, 2.3rem);
  letter-spacing: -0.025em; line-height: 1.02;
  margin: 0.5rem 0 1.2rem;
}
.fb-stars { display: flex; gap: 0.3rem; margin-bottom: 1.1rem; }
.fb-stars button {
  background: none; border: none; cursor: pointer;
  font-size: 1.9rem; line-height: 1;
  color: rgba(139, 92, 246, 0.25);
  transition: color 0.15s, transform 0.15s;
}
.fb-stars button:hover { transform: scale(1.2) rotate(8deg); }
.fb-stars button.on { color: var(--gold-hi); text-shadow: 0 0 18px rgba(185, 160, 255, 0.5); }
.fb-kinds { display: flex; gap: 0.45rem; flex-wrap: wrap; margin-bottom: 1rem; }
.fb-kinds button {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.04em;
  padding: 0.5rem 0.8rem; border-radius: 2rem; cursor: pointer;
  background: none; border: 1px solid var(--line); color: var(--ink-dim);
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}
.fb-kinds button.on { border-color: var(--gold); color: var(--gold-hi); background: rgba(139, 92, 246, 0.10); }
#fbtext {
  width: 100%; resize: vertical; min-height: 96px;
  background: rgba(5, 6, 12, 0.6);
  border: 1px solid var(--line); border-radius: 14px;
  color: var(--ink); font-family: var(--sans); font-size: 0.92rem;
  padding: 0.9rem 1rem; margin-bottom: 1.2rem;
  outline: none; transition: border-color 0.2s;
}
#fbtext:focus { border-color: var(--gold); }
.fb-send { width: 100%; text-align: center; }
.fb-thanks { text-align: center; padding: 1rem 0 0.4rem; }
.fb-thanks img { margin: 0 auto 1rem; width: 78px; height: auto; filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.5)); }
.fb-thanks p { color: var(--ink-dim); margin: 0.6rem 0 1.4rem; }

/* ── footer ── */
.footer {
  border-top: 1px solid var(--line);
  padding: clamp(3rem, 8vh, 5rem) clamp(1.2rem, 5vw, 4.5rem) 2rem;
  background:
    radial-gradient(70% 90% at 50% 120%, rgba(122, 77, 255, 0.12), transparent 70%),
    var(--bg2);
  overflow: clip;
}
.footer { position: relative; }
.footer-big .fl {
  display: inline-block; will-change: transform;
  background: linear-gradient(180deg, var(--ink) 30%, rgba(238, 240, 248, 0.1) 130%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.footer-big {
  position: relative; z-index: 1;
  font-family: var(--serif); font-weight: 800; letter-spacing: -0.02em;
  font-size: clamp(3rem, 12vw, 11rem);
  line-height: 0.95; text-align: center;
  color: var(--ink);
  user-select: none; margin-bottom: 2.5rem;
}
.footer-row {
  display: flex; justify-content: space-between; align-items: flex-end;
  gap: 2rem; flex-wrap: wrap; margin-bottom: 2.5rem;
}
.footer-links { display: flex; gap: 1.8rem; font-family: var(--mono); font-size: 0.8rem; }
.footer-links a { color: var(--ink-dim); transition: color 0.2s; }
.footer-links a:hover { color: var(--green); }
.footer-fine { text-align: center; opacity: 0.5; }

/* ── reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
  html { scroll-behavior: auto; }
  [data-r] { opacity: 1; transform: none; }
  .grain { animation: none; }
  .chapter { height: auto; }
  .chapter-sticky { position: static; height: auto; padding-top: 5rem; padding-bottom: 5rem; }
  .chapter-text .w { opacity: 1; }
}

/* ── misión Falcon 9 ── */
.lm-sub { color: var(--ink-dim); margin-bottom: 1.4rem; }
.lm-actions { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.lm-actions .btn { flex: 1; text-align: center; }
#falconfx { position: fixed; inset: 0; z-index: 96; pointer-events: none; }
#falconfx[hidden] { display: none; }
.falcon { position: absolute; left: auto; right: 10vw; bottom: 0; width: 82px; margin-left: 0; will-change: transform; }
@media (max-width: 640px) { .falcon { width: 54px; right: 6vw; } }
.f9-svg { width: 100%; height: auto; filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.55)); }
.f9-flame {
  position: absolute; left: 50%; top: 97%;
  width: 24px; height: 100px;
  transform: translateX(-50%);
  transform-origin: 50% 0;
  border-radius: 45% 45% 50% 50% / 18% 18% 82% 82%;
  background: linear-gradient(180deg, #fff 0%, #ffe9a8 18%, #ffb054 42%, rgba(255, 110, 60, 0.55) 70%, transparent);
  filter: blur(1.6px);
  opacity: 0;
  animation: f9f 0.09s linear infinite alternate;
}
/* plumas de los SRB: combustible sólido = fuego blanco-dorado, más largo */
.f9-flame::before, .f9-flame::after {
  content: ""; position: absolute; top: -4px;
  width: 17px; height: 132px;
  border-radius: 45% 45% 50% 50% / 14% 14% 86% 86%;
  background: linear-gradient(180deg, #fff 0%, #fff3cc 26%, #ffd070 52%, rgba(255, 150, 70, 0.5) 75%, transparent);
}
.f9-flame::before { left: -27px; }
.f9-flame::after { right: -27px; }
@keyframes f9f {
  from { transform: translateX(-50%) scaleY(0.82) scaleX(0.9); }
  to { transform: translateX(-50%) scaleY(1.12) scaleX(1.06); }
}
.burro {
  position: fixed; bottom: 5%; left: -130px; z-index: 96;
  font-size: 84px; pointer-events: none;
  transform: scaleX(-1); /* mirando hacia donde camina */
}
.caca { position: fixed; z-index: 95; font-size: 34px; pointer-events: none; }

/* calor y bruma del lanzamiento */
.heatglow {
  position: fixed; left: 50%; bottom: -8%;
  width: 130vw; height: 55vh;
  transform: translateX(-50%);
  background: radial-gradient(50% 80% at 50% 100%, rgba(255, 150, 60, 0.5), rgba(255, 90, 40, 0.18) 45%, transparent 75%);
  mix-blend-mode: screen;
  opacity: 0; pointer-events: none; z-index: 94;
}
.haze {
  position: fixed; left: 50%; bottom: 0;
  width: 300px; height: 320px;
  transform: translateX(-50%);
  backdrop-filter: blur(2.5px);
  -webkit-backdrop-filter: blur(2.5px);
  mask-image: radial-gradient(55% 60% at 50% 78%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(55% 60% at 50% 78%, #000 30%, transparent 75%);
  opacity: 0; pointer-events: none; z-index: 95;
  animation: haze 0.16s linear infinite alternate;
}
@keyframes haze {
  from { transform: translateX(-50%) scale(1, 1) skewX(0.4deg); }
  to { transform: translateX(-51%) scale(1.04, 0.97) skewX(-0.5deg); }
}

/* ── transformación: easter egg al tocar al personaje ── */
.stage { cursor: pointer; }
#aurafx { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; pointer-events: none; }
.ssj-label {
  z-index: 4;
  opacity: 0;
  position: absolute; bottom: 9vh; left: 50%; transform: translateX(-50%);
  z-index: 2; font-size: 0.9rem; color: var(--gold-hi);
  letter-spacing: 0.3em;
}
.ssj-flash {
  position: absolute; inset: 0; z-index: 6;
  background: #fff;
  opacity: 0; pointer-events: none;
}

/* aura del anime (imagen, fondo negro desaparece con screen) */
.aura-img {
  position: absolute; left: 50%; bottom: -6%;
  width: 215%; max-width: none; height: auto;
  margin-left: -107.5%;
  transform-origin: 50% 96%;
  transform: scale(0);
  pointer-events: none;
  will-change: transform, opacity;
  opacity: 0;
}
.aura-b { filter: blur(3px) brightness(1.1); }
.stage .hero-char { position: relative; z-index: 1; }

@keyframes aurabreathe {
  from { filter: brightness(1); }
  to { filter: brightness(1.18) saturate(1.1); }
}
.aura-b { animation-delay: 0.2s; }

/* ── modo ligero móvil: fuera decorativos animados que comen GPU ── */
@media (max-width: 900px), (pointer: coarse) {
  .meteors, .hero-grid { display: none; }
  #fx { display: none; }
}

/* botón Mundial → polla */
.nav-mundial {
  color: #ffd60a !important; font-weight: 700;
  padding: 0.45rem 0.9rem; border-radius: 2rem;
  border: 1.5px solid rgba(255, 214, 10, 0.55);
  transition: background 0.2s, transform 0.15s;
}
.nav-mundial:hover { background: rgba(255, 214, 10, 0.14); transform: translateY(-1px); }
.btn-mundial {
  background: linear-gradient(95deg, #ffd60a, #e8b500); color: #0a0a0e !important;
  font-weight: 760; box-shadow: 0 10px 30px rgba(255, 214, 10, 0.3);
  animation: mundialpulse 2.6s ease-in-out infinite;
}
@keyframes mundialpulse { 50% { box-shadow: 0 10px 44px rgba(255, 214, 10, 0.55); } }
@media (max-width: 720px) { .nav-links .nav-mundial { display: inline-block !important; } }
