/* EVerso · web del juego.
   Lenguaje visual «cielo de caramelo» (docs/marca/DESIGN_WEB.md) con la paleta y el arte del
   juego: claro, degradados pastel a sangre, letras redondas muy gruesas, botones píldora y
   marcos de 32 px. La profundidad sale de brillos interiores y degradados, no de sombras
   exteriores. Sin dependencias externas. */
/* pesos fijos: la fuente variable no la respetan todos los WebKit */
@font-face { font-family: "Rubik"; src: url("fonts/Rubik-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Rubik"; src: url("fonts/Rubik-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Rubik"; src: url("fonts/Rubik-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Rubik"; src: url("fonts/Rubik-900.woff2") format("woff2"); font-weight: 900; font-display: swap; }

:root {
  /* tinta: el azul noche del juego hace de negro */
  --ink: #141a46;
  --ink-soft: #5d6490;
  --white: #ffffff;
  --cloud: #f2f4fa;
  --mist: #e4e8f6;
  /* acentos del juego */
  --gold: #ffc21a;
  --gold-deep: #f59e0b;
  --green: #1faa55;
  --green-hi: #2fc467;
  --purple: #7b4cf0;
  --purple-hi: #9064ff;
  --blue: #3b8cff;
  --red: #e5484d;
  --sky: #9fe8ff;
  /* degradados (siempre se disuelven en blanco o nube por un borde) */
  --g-sky: radial-gradient(120% 100% at 50% 100%, #a9cbff 0%, #e2e5ff 36%, #f2f4fa 100%);
  --g-mint: radial-gradient(95% 95% at 50% 100%, #a6f5cf 0%, #ebe4f8 36%, #f2f4fa 100%);
  --g-prism: linear-gradient(180deg, #8fe3ff 0%, #fff4e0 9%, #fff0f6 16%, #effbe8 24%, #eeebff 32%, #f6ebff 39%, #ffffff 50%, #e8f1ff 70%, #ffffff 100%);
  --g-ribbon: linear-gradient(120deg, #ffd24a 0%, #ffb21a 45%, #ff8a3d 100%);
  /* formas */
  --r-card: 32px;
  --r-btn: 40px;
  --r-pill: 50px;
  --r-tile: 14px;
  --inset: rgba(255, 255, 255, 0.32) 0 5px 32px 12px inset, rgba(255, 255, 255, 0.44) 0 1px 4px 0 inset;
  --press: inset 0 -5px 0 rgba(0, 0, 0, 0.16);
  --max: 1200px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Rubik", ui-rounded, "SF Pro Rounded", "Segoe UI", system-ui, -apple-system, Roboto, sans-serif;
  font-weight: 400;
  font-size: 17px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: var(--purple); font-weight: 600; }
h1, h2, h3 { font-weight: 850; letter-spacing: -0.028em; line-height: 1.08; margin: 0; }
h2 { font-size: clamp(34px, 5.4vw, 56px); }
h3 { font-size: 22px; letter-spacing: -0.018em; }
p { margin: 0; }
.wrap { width: min(var(--max), 100% - 32px); margin: 0 auto; }
[hidden] { display: none !important; }

/* ---------- barra superior ---------- */
.top {
  position: sticky; top: 0; z-index: 20;
  transition: background 0.25s, box-shadow 0.25s;
}
.top.scrolled { background: rgba(255, 255, 255, 0.78); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 72px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 900; font-size: 24px; letter-spacing: -0.03em; }
.brand .tile { width: 44px; height: 44px; }
.brand .tile img { width: 36px; height: 36px; border-radius: 9px; }
.top nav { display: flex; align-items: center; gap: 4px; }
.top nav a:not(.btn) {
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 16px;
  padding: 9px 14px; border-radius: var(--r-pill);
}
.top nav a:not(.btn):hover, .top nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.7); }
.lang {
  font: inherit; font-weight: 700; font-size: 15px; color: var(--ink);
  background: var(--white); border: 0; border-radius: var(--r-pill);
  padding: 9px 12px; margin-left: 4px; cursor: pointer; box-shadow: var(--inset);
}
.btn-nav {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--white); color: var(--ink); text-decoration: none; font-weight: 800; font-size: 16px;
  padding: 11px 20px; border-radius: 9999px; margin-left: 6px; box-shadow: var(--inset), inset 0 -3px 0 var(--mist);
}

/* ---------- baldosa blanca (marca) ---------- */
.tile {
  display: grid; place-items: center; flex: none;
  width: 46px; height: 46px; border-radius: var(--r-tile); background: var(--white);
}
.tile img { width: 34px; height: 34px; border-radius: 8px; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 9px 9px 9px 26px; border-radius: var(--r-btn);
  color: var(--white); text-decoration: none; font-weight: 700; letter-spacing: -0.01em;
  box-shadow: var(--press); transition: transform 0.15s ease, filter 0.15s ease;
}
.btn:hover { transform: translateY(-2px); filter: brightness(1.05); }
.btn:active { transform: translateY(1px); box-shadow: none; }
.btn .t { display: flex; flex-direction: column; text-align: left; line-height: 1.15; }
.btn .t > span { font-size: 18px; font-weight: 800; }
.btn small { font-size: 13px; font-weight: 500; opacity: 0.92; }
.btn .tile { color: var(--ink); font-size: 20px; }
.btn-play { background: linear-gradient(180deg, var(--green-hi), var(--green)); }
.btn-pc, .btn-android, .btn-dl { background: linear-gradient(180deg, var(--purple-hi), var(--purple)); }
.btn-ghost { background: var(--white); color: var(--ink); box-shadow: var(--inset), inset 0 -4px 0 var(--mist); }
.btn-ghost .tile { background: var(--cloud); }
main.page .btn.is-main { outline: 4px solid rgba(255, 194, 26, 0.55); outline-offset: 3px; }

/* ---------- portada ---------- */
.hero { position: relative; background: var(--g-sky); margin-top: -72px; padding: 120px 0 0; overflow: hidden; }
.hero .wrap { position: relative; z-index: 2; text-align: center; }
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--white); color: var(--ink); font-weight: 700; font-size: 15px;
  padding: 8px 16px 8px 10px; border-radius: var(--r-pill); box-shadow: var(--inset);
}
.badge .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--green-hi); box-shadow: 0 0 0 4px rgba(47, 196, 103, 0.22); }
.logo { font-size: clamp(22px, 3vw, 28px); font-weight: 900; letter-spacing: -0.03em; margin-top: 22px; color: var(--purple); }
.display {
  font-size: clamp(54px, 10.5vw, 104px); font-weight: 900; letter-spacing: -0.035em; line-height: 0.98;
  margin: 6px auto 0; max-width: 11ch;
}
.display .hl { background: var(--g-ribbon); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: clamp(18px, 2.2vw, 21px); font-weight: 500; color: var(--ink-soft); max-width: 640px; margin: 20px auto 0; line-height: 1.45; }
.cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin-top: 32px; }
.cta .btn { min-width: 280px; }
.more { margin-top: 16px; font-size: 15px; color: var(--ink-soft); }
.more a { color: var(--ink); }
.note { font-size: 15px; color: var(--ink-soft); margin-top: 14px; }

/* escenario con el móvil y los personajes flotando */
.stage { position: relative; height: clamp(440px, 62vw, 640px); margin-top: 48px; }
.stage .device { position: absolute; left: 50%; bottom: -60px; width: clamp(230px, 27vw, 330px); transform: translateX(-50%); z-index: 3; }
.float { position: absolute; z-index: 2; animation: bob 6s ease-in-out infinite; will-change: transform; }
.float img { width: 100%; height: auto; }
.f-chico { left: 5%; bottom: 0; width: clamp(150px, 22vw, 300px); }
.f-chica { right: 5%; bottom: 0; width: clamp(140px, 20vw, 280px); animation-delay: -2s; }
.f-coin1 { left: 24%; top: 6%; width: clamp(54px, 7vw, 92px); animation-delay: -1s; }
.f-coin2 { right: 23%; top: 22%; width: clamp(40px, 5vw, 66px); animation-delay: -3s; transform: rotate(-14deg); }
.f-cash { left: 15%; top: 44%; width: clamp(80px, 11vw, 150px); animation-delay: -4s; }
.spark { position: absolute; z-index: 2; width: 34px; height: 34px; color: var(--gold); animation: twinkle 3.2s ease-in-out infinite; }
.spark svg { width: 100%; height: 100%; filter: drop-shadow(0 0 10px rgba(255, 210, 74, 0.9)); }
.s1 { left: 32%; top: 2%; } .s2 { right: 31%; top: 8%; width: 24px; height: 24px; animation-delay: -1.2s; }
.s3 { right: 12%; top: 40%; width: 28px; height: 28px; animation-delay: -2.1s; } .s4 { left: 9%; top: 30%; width: 20px; height: 20px; animation-delay: -0.6s; }

/* aviso flotante (estilo noticia del juego) */
.toast {
  position: absolute; z-index: 4; display: flex; align-items: center; gap: 12px;
  background: var(--white); border-radius: 18px; padding: 10px 16px 10px 10px;
  box-shadow: 0 10px 30px rgba(20, 26, 70, 0.08); text-align: left; max-width: 300px;
  animation: bob 7s ease-in-out infinite;
}
.toast .av { width: 40px; height: 40px; border-radius: 50%; background: var(--cloud); display: grid; place-items: center; overflow: hidden; flex: none; font-size: 20px; }
.toast .av img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.toast b { display: block; font-size: 15px; font-weight: 800; line-height: 1.2; }
.toast small { display: block; font-size: 13px; color: var(--ink-soft); font-weight: 500; }
.toast .up { color: var(--green); font-weight: 800; }
.t-hero { right: 3%; top: 26%; animation-delay: -3s; }

/* ---------- marcos ---------- */
.device {
  border-radius: 40px; background: var(--ink); padding: 9px;
  box-shadow: var(--inset);
}
.device img { border-radius: 32px; aspect-ratio: 9 / 16; width: 100%; height: auto; object-fit: cover; background: #000; }
.window {
  border-radius: var(--r-card); background: var(--mist); box-shadow: var(--inset); overflow: hidden;
}
.window .bar { display: flex; gap: 7px; padding: 14px 18px; background: rgba(255, 255, 255, 0.7); }
.window .bar i { width: 12px; height: 12px; border-radius: 50%; background: #ff6159; }
.window .bar i:nth-child(2) { background: #ffbd2e; } .window .bar i:nth-child(3) { background: #28c941; }
.window .screen { background: radial-gradient(90% 90% at 50% 100%, #3f52ad 0%, #1b2566 50%, #0b1033 100%); display: grid; place-items: center; padding: 22px 0; }
.window .screen img { width: auto; height: min(52vw, 440px); border-radius: 14px; aspect-ratio: 9 / 16; object-fit: cover; }

/* ---------- secciones ---------- */
section { padding: 96px 0; position: relative; }
.center { text-align: center; }
.sub { font-size: clamp(18px, 2vw, 20px); color: var(--ink-soft); font-weight: 500; max-width: 620px; margin: 16px auto 0; }

.show { background: var(--g-mint); overflow: hidden; }
.show-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: 28px; align-items: center; margin-top: 56px; position: relative; }
.show-grid .device { width: min(290px, 80%); justify-self: center; }
.t-show1 { left: -8px; top: 18%; }
.t-show2 { right: 30%; bottom: 8%; animation-delay: -2.5s; }

/* tarjetas de colores con capturas */
.cards { background: var(--cloud); }
.phones { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.pcard {
  border-radius: var(--r-card); padding: 40px 40px 0; overflow: hidden; box-shadow: var(--inset);
  display: flex; flex-direction: column; align-items: center; gap: 22px; min-height: 100%;
}
.pcard .device { width: 78%; margin-bottom: -60px; padding: 7px; border-radius: 34px; }
.pcard .device img { border-radius: 28px; }
.pcard p { font-weight: 800; font-size: 19px; letter-spacing: -0.02em; text-align: center; line-height: 1.2; }
.c-cloud { background: var(--white); }
.c-gold { background: var(--gold); }
.c-green { background: var(--green); color: var(--white); }
.c-blue { background: var(--blue); color: var(--white); }
.c-ink { background: var(--ink); color: var(--white); }
.c-ink .device { background: #2a3276; }
.c-purple { background: var(--purple); color: var(--white); }

/* lo que puedes hacer */
.prism { background: var(--g-prism); }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.card {
  background: var(--white); border-radius: var(--r-card); padding: 28px; box-shadow: var(--inset), 0 0 0 1px rgba(20, 26, 70, 0.04);
}
.card h3 { margin: 18px 0 8px; }
.card p { color: var(--ink-soft); }
.icon { width: 58px; height: 58px; border-radius: 18px; display: grid; place-items: center; font-size: 30px; }
.i-gold { background: #fff1c2; } .i-pink { background: #ffe0ef; } .i-blue { background: #dde9ff; }
.quote { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 56px; }
.quote img { width: 150px; }
.bubble {
  background: var(--white); border-radius: 26px; padding: 18px 24px; font-weight: 800; font-size: clamp(18px, 2.2vw, 22px);
  letter-spacing: -0.02em; position: relative; max-width: 440px; box-shadow: var(--inset), 0 10px 30px rgba(20, 26, 70, 0.06);
}
.bubble::before { content: ""; position: absolute; left: -10px; top: 50%; width: 22px; height: 22px; background: var(--white); transform: translateY(-50%) rotate(45deg); border-radius: 4px; }

/* comunidad */
.join {
  background: var(--g-ribbon); border-radius: var(--r-card); padding: 48px; box-shadow: var(--inset);
  display: grid; grid-template-columns: 1.3fr 1fr; gap: 20px; align-items: end; overflow: hidden; position: relative;
}
.join h2 { font-size: clamp(32px, 4.6vw, 48px); }
.join p { font-size: 18px; font-weight: 500; margin-top: 14px; max-width: 520px; }
.join .btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.join .beta { margin-top: 24px; background: rgba(255, 255, 255, 0.6); border-radius: 20px; padding: 14px 18px; font-size: 16px; font-weight: 500; }
.join .beta b { font-weight: 800; }
.join .art { align-self: end; justify-self: center; width: min(340px, 100%); margin-bottom: -48px; }

.disclaimer {
  background: var(--cloud); border-radius: 20px; padding: 16px 20px; color: var(--ink-soft);
  font-size: 15px; margin-top: 28px;
}

/* ---------- páginas interiores ---------- */
.page-head { background: var(--g-sky); margin-top: -72px; padding: 130px 0 56px; text-align: center; }
.page-head h1 { font-size: clamp(44px, 8vw, 80px); font-weight: 900; letter-spacing: -0.035em; }
.page-head .lead { margin-top: 14px; }
main.page { padding: 40px 0 20px; }
main.page section { padding: 16px 0; }
main.page .card { box-shadow: var(--inset), 0 0 0 1px rgba(20, 26, 70, 0.06); }
main.page .card h2 { font-size: clamp(26px, 3.4vw, 34px); margin-bottom: 12px; }
.steps { counter-reset: s; list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 12px; }
.steps li { counter-increment: s; position: relative; padding-left: 48px; color: var(--ink-soft); }
.steps li::before {
  content: counter(s); position: absolute; left: 0; top: -3px; width: 34px; height: 34px; border-radius: 50%;
  background: var(--gold); color: var(--ink); font-weight: 900; display: grid; place-items: center;
}
.dl-meta { font-size: 14px; color: var(--ink-soft); margin-top: 12px; word-break: break-all; }
pre.dl-meta { background: var(--cloud); border-radius: 16px; padding: 14px 16px; white-space: pre-wrap; }
code { background: var(--cloud); padding: 2px 6px; border-radius: 6px; font-size: 0.92em; }
pre code { background: none; padding: 0; }
.prose { max-width: 780px; }
.prose h2 { font-size: clamp(26px, 3.4vw, 34px); margin: 34px 0 12px; }
.prose p, .prose li { color: var(--ink-soft); }
.prose p + p { margin-top: 12px; }
.prose li { margin: 6px 0; }
.prose strong { color: var(--ink); }
.changelog article { background: var(--white); border-radius: var(--r-card); padding: 26px 30px; margin-bottom: 18px; box-shadow: var(--inset), 0 0 0 1px rgba(20, 26, 70, 0.06); }
.changelog h3 { color: var(--purple); font-size: 24px; margin-bottom: 8px; }
.changelog ul { margin: 0; padding-left: 20px; }

/* ---------- pie ---------- */
footer { background: var(--cloud); margin-top: 80px; padding: 36px 0 44px; color: var(--ink-soft); font-size: 15px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 14px 24px; justify-content: space-between; align-items: center; }
footer a { color: var(--ink); font-weight: 600; text-decoration: none; }
footer a:hover { text-decoration: underline; }
footer .brand { font-size: 20px; }
footer .brand .tile { width: 38px; height: 38px; }
footer .brand .tile img { width: 30px; height: 30px; }

/* ---------- animación ---------- */
@keyframes bob { 0%, 100% { translate: 0 0; } 50% { translate: 0 -14px; } }
@keyframes twinkle { 0%, 100% { transform: scale(1) rotate(0); opacity: 1; } 50% { transform: scale(0.72) rotate(20deg); opacity: 0.65; } }

/* ---------- móvil ---------- */
@media (max-width: 900px) {
  .phones { grid-template-columns: repeat(6, 78%); overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 12px; margin-inline: -16px; padding-inline: 16px; }
  .pcard { scroll-snap-align: center; }
  .grid3 { grid-template-columns: 1fr; }
  .show-grid { grid-template-columns: 1fr; }
  .show-grid .window { order: 2; }
  .t-show1 { left: 0; top: -30px; } .t-show2 { display: none; }
  .join { grid-template-columns: 1fr; padding: 32px 24px; }
  .join .art { width: 240px; }
}
@media (max-width: 720px) {
  body { font-size: 16px; }
  section { padding: 72px 0; }
  .top nav a.hide-sm, .top nav a:not(.btn-nav) { display: none; }
  .btn-nav { padding: 10px 16px; }
  .cta .btn { width: 100%; min-width: 0; }
  .stage { height: 420px; margin-top: 36px; }
  .f-chico { left: -6%; width: 150px; } .f-chica { right: -6%; width: 140px; }
  .f-cash { left: 2%; top: 26%; width: 90px; } .f-coin1 { left: 14%; top: 2%; } .f-coin2 { right: 12%; top: 14%; }
  .t-hero { right: 2%; left: 2%; top: auto; bottom: 16px; margin: 0 auto; max-width: 290px; }
  .quote { flex-direction: column; } .quote img { width: 120px; }
  .bubble::before { left: 50%; top: -10px; transform: translateX(-50%) rotate(45deg); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .float, .spark, .toast { animation: none; }
  .btn { transition: none; }
}
