/* PokéSurvivor 3DS — web de descarga. Colores de Pokémon sobre azul noche. */
@font-face { font-family: 'Pixel'; src: url('fuentes/PixelifyPS-700.ttf') format('truetype'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Pixel'; src: url('fuentes/PixelifyPS-400.ttf') format('truetype'); font-weight: 400; font-display: swap; }

:root {
  --noche: #0e1630; --noche2: #16214a; --noche3: #1d2b5e;
  --amarillo: #ffcb05; --amarillo2: #ffde5a; --azul: #3c5aa6; --azul2: #2a75bb;
  --rojo: #e3350d; --rojo2: #ff5a3c; --verde: #5fe08a; --morado: #c47bff;
  --texto: #eaf0ff; --suave: #a9b6d8; --borde: rgba(255, 203, 5, .55);
  --radio: 18px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--noche); color: var(--texto);
  font: 17px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--amarillo); }
code { font-family: ui-monospace, Menlo, monospace; background: rgba(255,255,255,.08); padding: .1em .4em; border-radius: 6px; font-size: .9em; word-break: break-all; }
kbd { font-family: 'Pixel', monospace; font-weight: 700; background: #22305f; border: 2px solid #4a5ea8; border-bottom-width: 4px; border-radius: 8px; padding: 0 .45em; color: #fff; }
h1, h2, h3 { margin: 0; }
h3 { font-family: 'Pixel', system-ui; font-weight: 700; font-size: 1.25rem; letter-spacing: .02em; }

/* ---------- pokéball ---------- */
.pokeball { width: 26px; height: 26px; border-radius: 50%; display: inline-block; position: relative; flex: none;
  background: linear-gradient(var(--rojo) 0 46%, #111 46% 54%, #f5f5f5 54%); border: 3px solid #111; }
.pokeball::after { content: ''; position: absolute; inset: 0; margin: auto; width: 9px; height: 9px; border-radius: 50%; background: #f5f5f5; border: 3px solid #111; }

/* ---------- barra ---------- */
.barra { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 1.2rem; padding: .7rem clamp(1rem, 4vw, 3rem);
  background: rgba(14, 22, 48, .82); backdrop-filter: blur(10px); border-bottom: 2px solid rgba(255, 203, 5, .25); }
.marca { display: flex; align-items: center; gap: .6rem; font-family: 'Pixel'; font-weight: 700; font-size: 1.25rem; color: #fff; text-decoration: none; }
.marca b { color: var(--rojo2); }
.barra nav { display: flex; gap: 1.1rem; margin-left: auto; }
.barra nav a { color: var(--suave); text-decoration: none; font-weight: 600; font-size: .95rem; }
.barra nav a:hover { color: var(--amarillo); }

/* ---------- botones ---------- */
.boton { display: inline-flex; flex-direction: column; align-items: center; justify-content: center; text-decoration: none; color: #fff;
  border-radius: 16px; padding: .85rem 1.6rem; border: 3px solid #111; box-shadow: 0 6px 0 #111, 0 12px 30px rgba(0,0,0,.35);
  transition: transform .12s, box-shadow .12s; cursor: pointer; }
.boton:hover { transform: translateY(-3px); box-shadow: 0 9px 0 #111, 0 18px 36px rgba(0,0,0,.4); }
.boton:active { transform: translateY(4px); box-shadow: 0 2px 0 #111; }
.boton-rojo { background: linear-gradient(var(--rojo2), var(--rojo)); }
.boton-azul { background: linear-gradient(#4f8ee0, var(--azul)); }
.boton-mini { padding: .45rem 1.1rem; font-family: 'Pixel'; font-weight: 700; background: var(--amarillo); color: #1b2350; border-width: 2px; box-shadow: 0 4px 0 #111; flex-direction: row; }
.b-tit { font-family: 'Pixel'; font-weight: 700; font-size: 1.35rem; letter-spacing: .03em; }
.b-sub { font-size: .8rem; opacity: .9; }

/* ---------- portada ---------- */
.portada { position: relative; min-height: 92vh; display: flex; flex-direction: column; align-items: center; justify-content: center; overflow: hidden;
  background:
    radial-gradient(1000px 520px at 50% 35%, rgba(60, 90, 166, .55), transparent 70%),
    radial-gradient(700px 400px at 85% 80%, rgba(196, 123, 255, .25), transparent 70%),
    linear-gradient(#0b1230, #16123a 70%, #10183a); }
.estrellas { position: absolute; inset: 0; background-image:
    radial-gradient(2px 2px at 20% 30%, #fff9, transparent), radial-gradient(2px 2px at 70% 20%, #fff8, transparent),
    radial-gradient(1.5px 1.5px at 40% 70%, #fff7, transparent), radial-gradient(2px 2px at 85% 55%, #fff8, transparent),
    radial-gradient(1.5px 1.5px at 10% 80%, #fff6, transparent), radial-gradient(2px 2px at 55% 45%, #ffde5a99, transparent);
  background-size: 600px 500px; animation: brillo 6s ease-in-out infinite alternate; }
@keyframes brillo { from { opacity: .5; } to { opacity: 1; } }
.portada-contenido { position: relative; z-index: 2; text-align: center; padding: 3rem 1rem 13rem; max-width: 1000px; }
.logo { display: flex; flex-direction: column; align-items: center; gap: .3rem; animation: entra .9s cubic-bezier(.2, 1.4, .4, 1) both; }
.logo img:first-child { width: min(900px, 92vw); filter: drop-shadow(0 12px 24px rgba(0,0,0,.45)); }
.logo-3ds { width: min(230px, 40vw); margin-top: -.4rem; }
@keyframes entra { from { transform: scale(1.4); opacity: 0; } to { transform: none; opacity: 1; } }
.lema { font-size: clamp(1.15rem, 2.6vw, 1.6rem); margin: 1.4rem auto 2rem; max-width: 760px; color: #dfe7ff; }
.lema b { color: var(--amarillo); }
.botones { display: flex; gap: 1.2rem; justify-content: center; flex-wrap: wrap; scroll-margin-top: 90px; }
.version { color: var(--suave); font-size: .95rem; margin: 1.4rem 0 .6rem; }
.version b { color: var(--verde); }
.chips { list-style: none; display: flex; gap: .6rem; justify-content: center; flex-wrap: wrap; padding: 0; margin: 0; }
.chips li { font-family: 'Pixel'; font-size: .95rem; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.18); border-radius: 999px; padding: .2rem .9rem; }

/* desfile de Pokémon por la hierba */
.suelo { position: absolute; left: 0; right: 0; bottom: 0; height: 78px; z-index: 1;
  background: repeating-linear-gradient(90deg, #3f9a4a 0 18px, #48a854 18px 36px); border-top: 6px solid #2f7a3a; image-rendering: pixelated; }
.desfile { position: absolute; left: 0; right: 0; bottom: 78px; height: 0; z-index: 3; pointer-events: none; }   /* (el borde de arriba de la hierba) */
.caminante { position: absolute; bottom: 0; image-rendering: pixelated; background-repeat: no-repeat;
  animation-name: anda, cruza; animation-iteration-count: infinite, infinite; animation-timing-function: steps(1), linear; }
@keyframes cruza { from { transform: translateX(-160px); } to { transform: translateX(calc(100vw + 160px)); } }

/* ---------- secciones ---------- */
.seccion { padding: clamp(3.5rem, 7vw, 6rem) clamp(1rem, 5vw, 4rem); max-width: 1240px; margin: 0 auto; scroll-margin-top: 70px; }
.seccion-oscura { max-width: none; background: linear-gradient(#0a1128, #101a3d); }
.seccion-oscura > * { max-width: 1160px; margin-left: auto; margin-right: auto; }
.centro { text-align: center; display: flex; justify-content: center; }
.titulo-img { height: clamp(56px, 8vw, 92px); width: auto; filter: drop-shadow(0 8px 14px rgba(0,0,0,.4)); }
.sub { color: var(--suave); margin: .6rem auto 2rem; display: block; }

/* tráiler */
.seccion-trailer { display: grid; grid-template-columns: 1.1fr .9fr; gap: 3rem; align-items: center; }
.trailer-texto p { color: #d4ddf7; font-size: 1.1rem; }
.lista-ticks { list-style: none; padding: 0; }
.lista-ticks li { padding-left: 2rem; position: relative; margin: .5rem 0; }
.lista-ticks li::before { content: ''; position: absolute; left: 0; top: .35em; width: 18px; height: 18px; border-radius: 50%;
  background: linear-gradient(var(--rojo) 0 46%, #111 46% 54%, #f5f5f5 54%); border: 2px solid #111; }
.movil { justify-self: center; width: min(360px, 80vw); aspect-ratio: 9 / 16; border-radius: 34px; padding: 12px; background: #0a0f22;
  border: 3px solid #2a3870; box-shadow: 0 0 0 6px #121a3a, 0 30px 60px rgba(0,0,0,.55), 0 0 80px rgba(196,123,255,.25); }
.movil video { width: 100%; height: 100%; object-fit: contain; border-radius: 24px; background: #000; }

/* tarjetas */
.tarjetas { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 1.3rem; margin-top: 2.2rem; }
.tarjeta { background: linear-gradient(var(--noche2), var(--noche3)); border: 2px solid rgba(255,255,255,.08); border-radius: var(--radio); overflow: hidden;
  transition: transform .2s, border-color .2s; }
.tarjeta:hover { transform: translateY(-6px); border-color: var(--borde); }
.tarjeta.destacada { border-color: var(--morado); box-shadow: 0 0 40px rgba(196,123,255,.25); }
.t-icono { aspect-ratio: 5 / 3; overflow: hidden; border-bottom: 3px solid #111; }
.t-icono img { width: 100%; height: 100%; object-fit: cover; image-rendering: pixelated; transition: transform .4s; }
.tarjeta:hover .t-icono img { transform: scale(1.08); }
.tarjeta h3 { padding: 1rem 1.1rem .2rem; color: var(--amarillo); }
.tarjeta p { padding: 0 1.1rem 1.2rem; margin: .3rem 0 0; color: #cdd6f2; font-size: .97rem; }
.nuevo { font-size: .7rem; background: var(--morado); color: #fff; border-radius: 6px; padding: .1rem .4rem; vertical-align: middle; }

/* galería */
.galeria { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 1.4rem; }
.cap { background: #0c1330; border: 3px solid #2a3870; border-radius: 22px; padding: 12px 12px 8px; cursor: zoom-in; transition: transform .2s, border-color .2s; }
.cap:hover { transform: translateY(-5px) rotate(-.4deg); border-color: var(--amarillo); }
.cap img { image-rendering: pixelated; border-radius: 6px; }
.cap figcaption { font-family: 'Pixel'; font-weight: 700; text-align: center; color: var(--amarillo); margin-top: .5rem; }
.visor[hidden] { display: none; }
.visor { position: fixed; inset: 0; z-index: 50; background: rgba(5, 8, 20, .92); display: flex; align-items: center; justify-content: center; padding: 2rem; cursor: zoom-out; }
.visor img { max-height: 92vh; image-rendering: pixelated; border-radius: 10px; box-shadow: 0 30px 80px #000; }
.visor button { position: absolute; top: 1rem; right: 1.4rem; font-size: 2.6rem; background: none; border: 0; color: #fff; cursor: pointer; }

/* novedades */
.linea { margin-top: 2.4rem; display: grid; gap: 1.2rem; }
.hito { display: grid; grid-template-columns: 90px 1fr; gap: 1.2rem; background: var(--noche2); border-radius: var(--radio); padding: 1.4rem; border: 2px solid rgba(255,255,255,.07); }
.hito.actual { border-color: var(--borde); background: linear-gradient(135deg, #1f2c63, #2a1f5c); }
.hito-v { font-family: 'Pixel'; font-weight: 700; font-size: 2rem; color: #1b2350; background: var(--amarillo); border-radius: 16px; display: grid; place-items: center; height: 72px; border: 3px solid #111; }
.hito h3 { color: var(--amarillo); }
.hito ul { margin: .5rem 0 0; padding-left: 1.2rem; color: #d2dbf5; }
.hito li { margin: .25rem 0; }

/* instalar */
.aviso { background: rgba(227, 53, 13, .14); border: 2px solid rgba(255, 90, 60, .55); border-radius: var(--radio); padding: 1rem 1.3rem; margin: 2rem auto 1.6rem; }
.pestanas { display: flex; gap: .8rem; justify-content: center; margin-bottom: 1.4rem; flex-wrap: wrap; }
.pestana { font: 700 1.2rem 'Pixel'; color: var(--texto); background: var(--noche2); border: 3px solid #2a3870; border-radius: 14px; padding: .6rem 1.4rem; cursor: pointer; }
.pestana small { font: 400 .75rem system-ui; color: var(--suave); margin-left: .3rem; }
.pestana.activa { background: var(--amarillo); color: #1b2350; border-color: #111; box-shadow: 0 4px 0 #111; }
.pestana.activa small { color: #3a3f6a; }
.panel-p { display: none; }
.panel-p.activo { display: block; animation: aparece .35s ease; }
@keyframes aparece { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.intro { text-align: center; font-size: 1.1rem; color: #d6def7; }
.dos-col { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; margin-top: 1rem; }
.metodo { background: var(--noche2); border: 2px solid rgba(255,255,255,.08); border-radius: var(--radio); padding: 1.4rem 1.5rem; }
.metodo h3 { display: flex; align-items: center; gap: .6rem; color: var(--amarillo); margin-bottom: .6rem; }
.num { display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--rojo); color: #fff; border: 3px solid #111; font-size: 1rem; }
.metodo ol { padding-left: 1.3rem; margin: 0; }
.metodo li { margin: .45rem 0; }
.qr { margin-top: 1.2rem; display: flex; flex-direction: column; align-items: center; gap: .6rem; }
.qr img { width: 230px; background: #fff; border-radius: 16px; padding: 10px; border: 4px solid var(--amarillo); box-shadow: 0 0 40px rgba(255,203,5,.25); image-rendering: pixelated; }
.qr code { font-size: .8rem; text-align: center; }
.notas { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 1.8rem auto; }
.nota { background: rgba(60, 90, 166, .18); border-left: 5px solid var(--azul2); border-radius: 12px; padding: .9rem 1.1rem; font-size: .95rem; color: #d3dcf6; }
.nota b { color: #fff; }
.pregunta { background: var(--noche2); border-radius: 14px; padding: .8rem 1.2rem; margin: .6rem auto; }
.pregunta summary { cursor: pointer; font-weight: 700; }
.pregunta p { color: #cdd6f2; margin: .5rem 0 .2rem; }

/* apoya */
.apoyo { display: grid; grid-template-columns: 1fr 1fr; gap: 1.4rem; margin-top: 2.2rem; }
.caja { display: flex; align-items: center; gap: 1.2rem; text-decoration: none; color: #fff; border-radius: 22px; padding: 1.5rem 1.6rem; border: 3px solid #111;
  box-shadow: 0 7px 0 #111; transition: transform .15s; }
.caja:hover { transform: translateY(-4px); }
.caja svg { width: 58px; height: 58px; flex: none; }
.caja b { display: block; font-family: 'Pixel'; font-size: 1.45rem; }
.caja span { color: rgba(255,255,255,.85); }
.caja-github { background: linear-gradient(135deg, #2b3137, #161b22); }
.caja-kofi { background: linear-gradient(135deg, #29abe0, #1b7fb5); }
.caja-kofi svg { color: #fff; }

/* pie */
.pie { text-align: center; padding: 2.5rem 1rem 3rem; background: #070c1e; color: var(--suave); font-size: .92rem; border-top: 3px solid rgba(255,203,5,.25); }
.pie p { margin: .35rem auto; max-width: 900px; }
.legal { font-size: .8rem; opacity: .75; }

/* ---------- móvil ---------- */
@media (max-width: 860px) {
  .barra nav { display: none; }
  .barra .boton-mini { margin-left: auto; }
  .seccion-trailer, .dos-col, .apoyo, .notas { grid-template-columns: 1fr; }
  .hito { grid-template-columns: 1fr; }
  .hito-v { width: 90px; height: 56px; font-size: 1.6rem; }
  .portada-contenido { padding-bottom: 11rem; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* capturas a su tamaño de verdad (400 px de ancho = 1 píxel de la consola por píxel): nítidas */
.cap img { width: 100%; height: auto; image-rendering: auto; }   /* (reducidas: suave, el texto se lee mejor que pixelado) */

/* el tráiler a pantalla completa: entero, con bandas, sin recortar */
video:fullscreen, video:-webkit-full-screen { object-fit: contain; background: #000; }

/* Ko-fi, bien visible */
.boton-kofi { background: #29abe0; color: #fff; gap: .4rem; margin-left: .2rem; }
.boton-kofi svg, .boton-kofi-grande svg { width: 22px; height: 22px; }
.banda-kofi { background: linear-gradient(90deg, #1b7fb5, #29abe0 50%, #1b7fb5); border-top: 3px solid #111; border-bottom: 3px solid #111; }
.banda-dentro { max-width: 1160px; margin: 0 auto; padding: 1.3rem clamp(1rem, 4vw, 2rem); display: flex; align-items: center; gap: 1.3rem; }
.taza { flex: none; width: 64px; height: 64px; border-radius: 50%; background: #fff; color: #29abe0; display: grid; place-items: center; border: 3px solid #111; }
.taza svg { width: 38px; height: 38px; }
.banda-texto { flex: 1; }
.banda-texto b { display: block; font-family: 'Pixel'; font-size: 1.3rem; color: #fff; }
.banda-texto span { color: #eaf6ff; }
.boton-kofi-grande { flex-direction: row; gap: .5rem; background: linear-gradient(#ff6b6b, #e5484d); font-family: 'Pixel'; font-weight: 700; font-size: 1.15rem; white-space: nowrap; }
/* popup al descargar */
.popup[hidden] { display: none; }
.popup { position: fixed; inset: 0; z-index: 60; background: rgba(5, 8, 20, .8); display: grid; place-items: center; padding: 1rem; animation: aparece .25s ease; }
.popup-caja { position: relative; max-width: 470px; text-align: center; background: linear-gradient(var(--noche2), var(--noche3)); border: 3px solid var(--amarillo);
  border-radius: 24px; padding: 2rem 1.6rem 1.4rem; box-shadow: 0 30px 80px #000; display: flex; flex-direction: column; align-items: center; gap: .8rem; }
.popup-caja h3 { color: var(--amarillo); font-size: 1.5rem; }
.popup-caja p { margin: 0; color: #d6def7; }
.popup-x { position: absolute; top: .4rem; right: .8rem; background: none; border: 0; color: #fff; font-size: 2rem; cursor: pointer; }
.popup-sigue { color: var(--suave); font-size: .95rem; }
.pokeball.grande { width: 52px; height: 52px; border-width: 4px; animation: bote 1s ease-in-out infinite; }
.pokeball.grande::after { width: 16px; height: 16px; border-width: 4px; }
@keyframes bote { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px) rotate(-10deg); } }
@media (max-width: 860px) {
  .banda-dentro { flex-direction: column; text-align: center; }
  .boton-kofi { font-size: 0; gap: 0; padding: .45rem .6rem; }   /* (en el móvil, sólo la taza) */
  .boton-kofi svg { width: 22px; height: 22px; }
}
/* la fuente pixel junta «fi» en una ligadura rara («fin» salía «An») */
body, h3, .b-tit, .cap figcaption, .pestana, .marca, .boton { font-variant-ligatures: none; font-feature-settings: "liga" 0, "clig" 0; }
@media (max-width: 480px) {
  .barra { gap: .5rem; padding: .6rem .8rem; }
  .marca { font-size: 1rem; gap: .4rem; }
  .barra .boton-mini { padding: .4rem .7rem; font-size: .9rem; }
}
@media (max-width: 860px) { .barra .boton-kofi { font-size: 0; gap: 0; padding: .45rem .6rem; white-space: nowrap; } }
.barra .boton-mini { white-space: nowrap; }
.anotacion { text-align: center; font-size: .85rem; color: var(--suave); opacity: .85; font-style: italic; max-width: 760px; margin: -1.2rem auto 2rem; }
.cap { margin: 0; }

/* popup del QR (Descargar .CIA) */
.popup-ancho { max-width: 620px; }
.qr-pop { display: flex; gap: 1.2rem; align-items: center; text-align: left; }
.qr-pop img { width: 210px; flex: none; background: #fff; border-radius: 14px; padding: 8px; border: 4px solid var(--amarillo); image-rendering: pixelated; }
.qr-pop ol { margin: 0; padding-left: 1.2rem; color: #d6def7; }
.qr-pop li { margin: .35rem 0; }
.boton-archivo { width: 100%; }
.mini-kofi { display: flex; align-items: center; gap: .7rem; text-align: left; background: rgba(41, 171, 224, .15); border: 2px solid rgba(41, 171, 224, .6); border-radius: 14px; padding: .6rem .8rem; font-size: .88rem; color: #d6eaf7; }
.mini-kofi svg { width: 30px; height: 30px; flex: none; color: #29abe0; }
.mini-kofi a { flex: none; background: #29abe0; color: #fff; font-family: 'Pixel'; font-weight: 700; text-decoration: none; padding: .35rem .8rem; border-radius: 10px; border: 2px solid #111; }
@media (max-width: 600px) { .qr-pop { flex-direction: column; } .qr-pop img { width: 190px; } }
.popup-caja { max-height: 92vh; overflow-y: auto; }

/* selector de idioma */
.idiomas { display: flex; border: 2px solid rgba(255,255,255,.18); border-radius: 10px; overflow: hidden; flex: none; }
.idiomas a { font-family: 'Pixel'; font-weight: 700; font-size: .85rem; color: var(--suave); text-decoration: none; padding: .3rem .55rem; }
.idiomas a[aria-current] { background: var(--amarillo); color: #1b2350; }
@media (max-width: 860px) { .barra nav { display: none; } .idiomas { margin-left: auto; } .barra .boton-kofi { margin-left: 0; } }
