/* ============================================================
   styles.css — El Recreo FM v8.0
   Sin duplicados · dvh correcto · Mobile-first · Neon premium
   ============================================================ */

/* ── Variables ────────────────────────────────────────────── */
:root {
  --magenta:     #FF00FF;
  --magenta-d:   #CC00CC;
  --cyan:        #00E5FF;
  --cyan-d:      #00AACC;
  --lime:        #CCFF00;
  --lime-d:      #88CC00;
  --orange:      #FFA500;
  --green:       #00FF88;
  --green-d:     #00CC66;
  --red:         #FF4444;
  --bg:          #050A2E;
  --bg2:         #0A1240;
  --card:        rgba(10, 18, 64, 0.90);
  --dim:         rgba(255, 255, 255, 0.65);
  --fd:          'Orbitron', monospace;
  --fb:          'Exo 2', sans-serif;
  --tr:          0.22s ease;
  --st:          env(safe-area-inset-top,    0px);
  --sb:          env(safe-area-inset-bottom, 0px);
  --home-gap:    1.4dvh;  /* separación prudente entre el juego y la barra inferior */
}

/* ── Reset ────────────────────────────────────────────────── */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  appearance: none;
  -webkit-appearance: none;
}
:where(button, a, [role="button"], [tabindex]):focus-visible {
  outline: 2px solid #fff;
  outline-offset: 3px;
  box-shadow: 0 0 0 5px rgba(0,229,255,.35), 0 0 18px rgba(204,255,0,.45);
}
html, body {
  width: 100%;
  height: 100%;
  overflow: hidden;
  background: var(--bg);
  color: #fff;
  font-family: var(--fb);
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

/* ══════════════════════════════════════════════════════════
   SPLASH
══════════════════════════════════════════════════════════ */
#splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--bg);
  background-image:
    radial-gradient(ellipse at 50% 0%,   rgba(123,0,255,.38) 0%, transparent 65%),
    radial-gradient(ellipse at 50% 100%, rgba(0,229,255,.22)  0%, transparent 65%);
  transition: opacity .7s ease, visibility .7s ease;
}
#splash.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.sp-logo {
  width: min(160px, 42vw);
  height: min(160px, 42vw);
  border-radius: 50%;
  object-fit: cover;
  animation: spPulse 1.4s ease-in-out infinite;
  filter: drop-shadow(0 0 22px var(--magenta)) drop-shadow(0 0 44px var(--cyan));
}
@keyframes spPulse {
  0%, 100% { transform: scale(1); }
  50%       { transform: scale(1.07); }
}
.sp-title {
  margin-top: 14px;
  font-family: var(--fd);
  font-size: clamp(14px, 5vw, 20px);
  font-weight: 900;
  color: var(--lime);
  text-shadow: 0 0 18px var(--lime);
  letter-spacing: 2px;
}
.sp-sub {
  font-family: var(--fd);
  font-size: clamp(8px, 2.8vw, 11px);
  color: var(--cyan);
  letter-spacing: 3px;
  margin-top: 4px;
  text-shadow: 0 0 8px var(--cyan);
}
.sp-bar {
  width: min(200px, 60vw);
  height: 4px;
  background: rgba(255,255,255,.1);
  border-radius: 2px;
  margin-top: 22px;
  overflow: hidden;
}
.sp-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--magenta), var(--cyan));
  border-radius: 2px;
  transition: width .1s linear;
}

/* ══════════════════════════════════════════════════════════
   TUTORIAL FLOTANTE
   position:fixed → flota encima de todo sin ocupar espacio
══════════════════════════════════════════════════════════ */
#tutorial {
  position: fixed;
  inset: 0;
  z-index: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(5,10,46,.72);
  transition: opacity .5s ease;
}
#tutorial.hide  { opacity: 0; pointer-events: none; }
#tutorial.gone  { display: none; }

.tut-box {
  background: rgba(5,10,46,.97);
  border: 2px solid var(--lime);
  border-radius: 14px;
  padding: 18px 22px;
  max-width: 85vw;
  box-shadow: 0 0 24px rgba(204,255,0,.3);
}
.tut-title {
  font-family: var(--fd);
  font-size: clamp(11px, 3.5vw, 15px);
  font-weight: 900;
  color: var(--lime);
  text-shadow: 0 0 10px var(--lime);
  text-align: center;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.tut-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 5px 0;
  font-size: clamp(10px, 3vw, 13px);
  color: #fff;
  line-height: 1.4;
}
.tut-row span:first-child { font-size: 18px; flex-shrink: 0; }
.tut-hint {
  text-align: center;
  font-family: var(--fd);
  font-size: clamp(8px, 2.5vw, 10px);
  color: var(--cyan);
  letter-spacing: 1px;
  margin-top: 14px;
  animation: blink 1.2s ease-in-out infinite;
}
@keyframes blink { 0%,100%{opacity:1;} 50%{opacity:.35;} }
.tut-prog {
  width: 100%;
  height: 3px;
  background: rgba(204,255,0,.15);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 10px;
}
.tut-prog-fill {
  height: 100%;
  width: 0%;
  background: var(--lime);
  border-radius: 2px;
  transition: width 4s linear;
}

/* ══════════════════════════════════════════════════════════
   APP WRAPPER
   100dvh = descuenta la barra del browser en Android Chrome
══════════════════════════════════════════════════════════ */
#app {
  position: fixed;
  top: 0; left: 0; right: 0;
  /* Anclado justo encima de la barra inferior, con una separación
     prudente. Las secciones (logo/frase/radio/juego) reparten este
     alto con flex. */
  bottom: calc(var(--nav-h) + var(--safe-bottom) + var(--home-gap));
  display: flex;
  flex-direction: column;
  background: var(--bg);
  overflow: hidden;
  padding-top:    var(--st);
  padding-bottom: 0;
  /* Bloques apilados a ras; los % de cada sección son del alto disponible */
  row-gap: 0;
}
#app > section { min-height: 0; }

/* Entrada orquestada del home: una sola animación en cascada
   (logo → radio → juego → banner) al ocultarse el splash.
   prefers-reduced-motion la anula vía la regla global. */
#app.home-enter > section { animation: homeIn .55s cubic-bezier(.2,.7,.3,1) both; }
#app.home-enter > #s-logo  { animation-delay: .05s; }
#app.home-enter > #s-frase { animation-delay: .10s; }
#app.home-enter > #s-radio { animation-delay: .15s; }
#app.home-enter > #s-snake { animation-delay: .25s; }
@keyframes homeIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ══════════════════════════════════════════════════════════
   PÁGINAS INTERIORES
══════════════════════════════════════════════════════════ */
.page {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 100;
  transform: translateX(100%);
  transition: transform .32s cubic-bezier(.4,0,.2,1);
  padding-top:    var(--st);
  padding-bottom: var(--sb);
}
.page.active { transform: translateX(0); z-index: 1000; }

/* Partículas fijas en páginas interiores */
.page-particles {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: .82;
}
/* Íconos flotantes en páginas interiores */
.page-float-icons {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.pfi {
  position: absolute;
  animation: pfiAnim 3.5s ease-in-out infinite;
  opacity: 0;
  font-size: clamp(12px, 3.5vw, 20px);
  user-select: none;
}
.pfi:nth-child(1)  { top:8%;  left:5%;   color:var(--magenta); animation-delay:0s;   font-size:clamp(14px,4vw,22px); }
.pfi:nth-child(2)  { top:12%; right:6%;  color:var(--cyan);    animation-delay:.5s; }
.pfi:nth-child(3)  { top:22%; left:2%;   color:var(--lime);    animation-delay:1s; }
.pfi:nth-child(4)  { top:30%; right:3%;  color:var(--magenta); animation-delay:1.5s; }
.pfi:nth-child(5)  { top:45%; left:4%;   color:var(--green);   animation-delay:2s; }
.pfi:nth-child(6)  { top:55%; right:5%;  color:var(--cyan);    animation-delay:2.5s; }
.pfi:nth-child(7)  { top:65%; left:3%;   color:var(--lime);    animation-delay:.8s; }
.pfi:nth-child(8)  { top:72%; right:4%;  color:var(--magenta); animation-delay:1.3s; }
.pfi:nth-child(9)  { top:82%; left:6%;   color:var(--green);   animation-delay:1.8s; }
.pfi:nth-child(10) { top:88%; right:7%;  color:var(--cyan);    animation-delay:.3s; }
.pfi:nth-child(11) { top:38%; left:2%;   color:var(--lime);    animation-delay:2.2s; font-size:clamp(10px,3vw,16px); }
.pfi:nth-child(12) { top:50%; right:2%;  color:var(--magenta); animation-delay:.7s;  font-size:clamp(10px,3vw,16px); }
@keyframes pfiAnim {
  0%   { transform:translateY(0)    rotate(0deg);  opacity:0; }
  15%  { opacity:.85; }
  50%  { transform:translateY(-8px) rotate(8deg);  opacity:.9; }
  85%  { opacity:.85; }
  100% { transform:translateY(0)    rotate(0deg);  opacity:0; }
}
/* Contenido de páginas por encima de partículas */
.ph, .pc, .pf { position: relative; z-index: 1; }

/* ══════════════════════════════════════════════════════════
   S1 — LOGO
══════════════════════════════════════════════════════════ */
#s-logo {
  flex: 17 1 0;                         /* logo más grande (bloque más alto) */
  min-height: 0;
  padding: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;                  /* logo centrado horizontalmente */
  justify-content: center;              /* y centrado vertical en su bloque */
  overflow: hidden;
}
/* Fila héroe: logo (izquierda, centrado vertical) + mascota (derecha) */
.hero-row {
  position: relative;
  z-index: 3;
  width: 100%;
  height: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(6px, 2.5vw, 18px);
  /* Logo pegado totalmente a la izquierda; padding derecho para la mascota */
  padding: 0 clamp(8px, 3vw, 16px) 0 0;
}
.logo-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  z-index: 0;
}
#particles-cv {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  width: 100%;
  height: 100%;
  opacity: .82;
}
.float-icons {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}
.fi {
  position: absolute;
  animation: fiAnim 3s ease-in-out infinite;
  opacity: .78;
  font-size: clamp(11px, 3.2vw, 17px);
}
.fi:nth-child(1)  { top:8%;  left:46%;  color:var(--magenta); animation-delay:0s;   font-size:clamp(13px,4vw,19px); }
.fi:nth-child(2)  { top:18%; left:5%;   color:var(--cyan);    animation-delay:.4s; }
.fi:nth-child(3)  { top:18%; right:5%;  color:var(--lime);    animation-delay:.8s; }
.fi:nth-child(4)  { top:44%; left:1%;   color:var(--magenta); animation-delay:1.2s; }
.fi:nth-child(5)  { top:44%; right:1%;  color:var(--green);   animation-delay:1.6s; }
.fi:nth-child(6)  { top:64%; left:6%;   color:var(--lime);    animation-delay:2s; }
.fi:nth-child(7)  { top:64%; right:6%;  color:var(--cyan);    animation-delay:2.4s; }
.fi:nth-child(8)  { top:77%; left:27%;  color:var(--magenta); animation-delay:2.8s; }
.fi:nth-child(9)  { top:77%; right:27%; color:var(--lime);    animation-delay:.2s; }
.fi:nth-child(10) { top:29%; left:29%;  color:var(--green);   animation-delay:1s; }
@keyframes fiAnim {
  0%,100% { transform:translateY(0)   rotate(0deg); opacity:.78; }
  50%     { transform:translateY(-6px) rotate(7deg); opacity:1;   }
}
/* Logo centrado, sin container de tamaño: la IMAGEN define su tamaño */
.logo-center {
  position: relative;
  z-index: 3;
  width: 100%;
  display: flex;
  justify-content: center;
}
/* Logo del home: rectangular, sin recorte circular, TAMAÑO FIJO.
   Único parámetro de tamaño = width (Daniel lo ajusta desde ajustes). */
#app-logo {
  width: 57vw;         /* agrandado: llena el alto de su bloque (ahora más alto) */
  max-width: 320px;
  aspect-ratio: 560 / 321;   /* fuerza la proporción real del logo */
  height: auto;
  max-height: 100%;          /* tope = alto del bloque → no se corta ni empuja */
  border-radius: 0;
  object-fit: contain;
  display: block;
}
.logo-img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  filter: drop-shadow(0 0 14px rgba(255,0,255,.5)) drop-shadow(0 0 28px rgba(0,229,255,.4));
}

/* Frase rotativa bajo el logo (config Daniel: 4% del alto) */
#s-frase {
  flex: 4 1 0;                          /* proporción Daniel: 4 */
  min-height: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 6px;                       /* margen lateral mínimo → caben más letras */
  overflow: hidden;
}
.frase-rot {
  font-family: var(--ft, "Exo 2"), system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(10.5px, 3.1vw, 13px);
  color: #cfe9ff;
  text-align: center;
  text-shadow: 0 0 10px rgba(0,229,255,.4);
  white-space: nowrap;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity .32s ease;
}
.frase-rot.frase-out { opacity: 0; }

/* Chip "ON AIR" — aparece sobre el logo solo cuando hay señal */
.onair-chip {
  position: absolute;
  top: -4px;
  left: 50%;
  transform: translateX(-50%) scale(.85);
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: var(--fd);
  font-size: clamp(7px, 2vw, 9px);
  font-weight: 900;
  letter-spacing: 2px;
  color: var(--red);
  background: rgba(5,10,46,.92);
  border: 1px solid rgba(255,68,68,.55);
  border-radius: 20px;
  padding: 3px 10px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .4s ease, transform .4s ease;
}
body.radio-live .onair-chip {
  opacity: 1;
  transform: translateX(-50%) scale(1);
}
.onair-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--red);
  box-shadow: 0 0 6px var(--red);
  animation: blink 1.1s ease-in-out infinite;
}

/* Franja de mascota — frase rotativa al pie del header */
.mascota-strip {
  position: relative;
  z-index: 3;
  align-self: center;                   /* frase centrada (el logo sigue a la izquierda) */
  margin-top: clamp(5px, 1.2dvh, 12px); /* separación prudente del logo y el cerebro */
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 92%;
  white-space: nowrap;
  pointer-events: none;
}
.mascota-emoji {
  font-size: clamp(12px, 3.4vw, 16px);
  filter: drop-shadow(0 0 6px rgba(0,229,255,.6));
}
.mascota-frase {
  font-family: var(--fb);
  font-size: clamp(10px, 2.9vw, 13px); /* +10% respecto a clamp(9px,2.6vw,12px) */
  font-weight: 600;
  color: rgba(255,255,255,.78);
  text-shadow: 0 0 8px rgba(0,229,255,.45), 0 1px 3px rgba(0,0,0,.8);
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity .32s ease;
}
.mascota-frase.frase-out { opacity: 0; }

/* ══════════════════════════════════════════════════════════
   CEREBRO INTERACTIVO (lado derecho del header)
   Cada toque AÑADE un elemento: ojo, ojo, nariz, boca, audífonos,
   mensaje, corazón, mensaje final, y vuelve a empezar (ver main.js).
══════════════════════════════════════════════════════════ */
.mascota-zone {
  flex: 1 1 0;
  min-width: 0;
  align-self: stretch;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}
.mascota-fig {
  --brain: clamp(62px, 20vw, 96px);
  position: relative;
  width: var(--brain);
  height: var(--brain);
  flex-shrink: 0;
}
.m-emoji {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--brain);
  line-height: 1;
  filter: drop-shadow(0 0 10px rgba(0,229,255,.5)) drop-shadow(0 0 20px rgba(255,0,255,.3));
}
/* Carita que se va dibujando sobre el cerebro */
.m-cara {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
  pointer-events: none;
}
.m-cara .feat {
  opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
  transition: opacity .25s ease;
}
.m-cara .feat.on {
  opacity: 1;
  animation: featPop .35s ease;
}
@keyframes featPop {
  0%   { transform: scale(.3); }
  60%  { transform: scale(1.18); }
  100% { transform: scale(1); }
}
/* Corazón latiendo */
.m-corazon {
  position: absolute;
  top: -6px; right: -6px;
  font-size: calc(var(--brain) * .42);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}
.m-corazon.on { opacity: 1; animation: latido .8s ease-in-out infinite; }
@keyframes latido {
  0%,100% { transform: scale(1); }
  20%     { transform: scale(1.3); }
  40%     { transform: scale(1.05); }
}
/* Rebote al tocar (feedback) */
.mascota-fig.pop { animation: brainPop .26s ease; }
@keyframes brainPop {
  0% { transform: scale(1); } 40% { transform: scale(1.12); } 100% { transform: scale(1); }
}

/* "¡Tócame!" — pista para que sepan que reacciona */
.mascota-hint {
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  max-width: 100%;
  font-family: var(--fb);
  font-size: clamp(8px, 2vw, 10px);
  font-weight: 700;
  color: var(--cyan);
  background: rgba(5,10,46,.9);
  border: 1px solid rgba(0,229,255,.5);
  border-radius: 20px;
  padding: 2px 7px;
  white-space: nowrap;
  pointer-events: none;
  animation: mHintPulse 1.2s ease-in-out infinite;
}
.mascota-hint.oculto { display: none; }
@keyframes mHintPulse {
  0%,100% { transform: translateX(-50%) scale(1);    opacity: .85; }
  50%     { transform: translateX(-50%) scale(1.08); opacity: 1; }
}
/* Burbuja de mensaje (arriba del cerebro; el texto se ajusta) */
.m-burbuja {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  width: max-content;
  max-width: min(210px, 54vw);
  font-family: var(--fb);
  font-size: clamp(10px, 2.7vw, 12px);
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  color: #fff;
  background: rgba(157,77,255,.95);
  border-radius: 12px;
  padding: 6px 10px;
  box-shadow: 0 4px 14px rgba(0,0,0,.4);
  opacity: 0;
  transform: translateY(6px) scale(.95);
  pointer-events: none;
  transition: opacity .22s ease, transform .22s ease;
}
.m-burbuja.ver { opacity: 1; transform: translateY(0) scale(1); }

@media (prefers-reduced-motion: reduce) {
  .mascota-fig, .mascota-hint, .m-cara .feat, .m-corazon { animation: none !important; }
}

/* ══════════════════════════════════════════════════════════
   S3 — SNAKE / JUEGO (debajo de la radio)
══════════════════════════════════════════════════════════ */
#s-snake {
  /* proporción Daniel: 58 (juego) */
  flex: 58 1 0;
  height: auto;
  padding: 0 4px;
  display: flex;
  flex-direction: column;
  position: relative;
  min-height: 0;
}
.snake-box {
  position: relative;
  flex: 1;
  min-height: 0;
  border: 1px solid rgba(0,229,255,.28);
  border-bottom: none;
  border-radius: 10px 10px 0 0;
  overflow: visible;
  background: rgba(5,10,46,.55);
}
#snake-cv {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 0;
  touch-action: none;
  cursor: pointer;
  background: transparent;
}

/* D-pad */
.dpad-zone {
  --dpad-size: clamp(21px, 7.35vw, 28.5px);
  --dpad-mid: calc(var(--dpad-size) * .72);
  --score-bar-height: clamp(42px, 7dvh, 54px);
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translate(-50%, calc(var(--score-bar-height) + (var(--dpad-size) * 1.5)));
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
}
body[data-game="memory"] .dpad-zone,
body[data-game="breakout"] .dpad-zone {
  display: none;
}
.dpad-row { display: flex; align-items: center; gap: 0; }

.da {
  width:  var(--dpad-size);
  height: var(--dpad-size);
  background: rgba(5,10,46,.93);
  border: 1.5px solid var(--cyan);
  color: var(--cyan);
  font-size: clamp(9.5px, 2.65vw, 13.7px);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 6px rgba(0,229,255,.55);
  touch-action: manipulation;
  transition: background var(--tr), transform var(--tr);
  position: relative;
}
/* Área táctil ampliada sin agrandar visualmente */
.da::after {
  content: '';
  position: absolute;
  inset: -10px;
  z-index: 1;
}
.da-up    { border-radius: 5px 5px 0 0; }
.da-left  { border-radius: 5px 0 0 5px; }
.da-right { border-radius: 0 5px 5px 0; }
.da-down  { border-radius: 0 0 5px 5px; }
.da-mid {
  width:  var(--dpad-mid);
  height: var(--dpad-size);
  background: rgba(5,10,46,.93);
  border-top:    1.5px solid var(--cyan);
  border-bottom: 1.5px solid var(--cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.da-mid::after { content:''; position:absolute; inset:-10px; z-index:1; }
.da-dot {
  width: 6.3px; height: 6.3px;
  border-radius: 50%;
  background: rgba(0,229,255,.3);
  border: 1px solid var(--cyan);
}
.da:active { background: rgba(0,229,255,.28); transform: scale(.88); box-shadow: 0 0 12px var(--cyan); }

/* Barra de puntuación */
.score-bar {
  height: clamp(42px, 7dvh, 54px);
  border: 1px solid rgba(0,229,255,.28);
  border-top: 1px solid rgba(0,229,255,.18);
  border-radius: 0 0 10px 10px;
  background: rgba(5,10,46,.88);
  display: grid;
  grid-template-columns: minmax(0, 1fr) max-content;
  grid-template-rows: 1fr 1fr;
  column-gap: 10px;
  padding: 4px 14px 5px;
  flex-shrink: 0;
}
.score-meta {
  grid-column: 1;
  grid-row: 2;
  align-self: center;
  min-width: 0;
}
/* Marquesina: nombre del juego activo, discreto sobre el nivel */
.score-game {
  grid-column: 1;
  grid-row: 1;
  align-self: center;
  min-width: 0;
  font-family: var(--fd);
  font-size: clamp(8px, 2.3vw, 10px);
  font-weight: 700;
  letter-spacing: 2px;
  color: rgba(0,229,255,.65);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.score-value {
  grid-column: 2;
  grid-row: 1 / span 2;
  display: grid;
  grid-template-rows: 1fr 1fr;
  justify-items: end;
  align-items: center;
  min-width: 0;
}
.score-level {
  font-family: var(--fd);
  font-size: clamp(11px, 3.2vw, 15px);
  font-weight: 900;
  color: var(--cyan);
  text-shadow: 0 0 8px var(--cyan);
  letter-spacing: 1.5px;
  white-space: nowrap;
}
.score-num {
  font-family: var(--fd);
  font-size: clamp(14px, 4.5vw, 20px);
  font-weight: 900;
  color: var(--lime);
  text-shadow: 0 0 10px var(--lime);
  letter-spacing: 3px;
  line-height: 1;
}
.score-best {
  font-family: var(--fd);
  font-size: clamp(7px, 2vw, 9px);
  color: var(--orange);
  display: block;
  text-align: right;
  white-space: nowrap;
  line-height: 1;
}

/* ══════════════════════════════════════════════════════════
   S2b — RADIO (encima del juego, para que siempre se vea)
   Tarjeta tipo "player": play grande a la izquierda; a la
   derecha el nombre de la emisora + estado y el visualizador.
══════════════════════════════════════════════════════════ */
#s-radio {
  flex: 13 1 0;            /* más presencia que antes (era 8) */
  min-height: 72px;        /* en pantallas bajas cede el juego, no el player */
  display: flex;
  align-items: center;
  gap: 12px;
  margin: .5dvh 6px 1.2dvh;  /* alineado con el marco del juego */
  padding: 8px 12px;
  border-radius: 18px;
  /* Cristal oscuro con tinte cian→lima, como el resto de la app */
  background: linear-gradient(120deg,
              rgba(0,229,255,.10), rgba(5,10,46,.78) 42%,
              rgba(5,10,46,.78) 68%, rgba(204,255,0,.08));
  border: 1px solid rgba(0,229,255,.35);
  box-shadow: 0 0 16px rgba(0,229,255,.14),
              inset 0 0 22px rgba(0,229,255,.05);
}
#radio-play-btn {
  position: relative;        /* ancla de las ondas ::before/::after */
  width:  clamp(50px, 13.5vw, 62px);
  height: clamp(50px, 13.5vw, 62px);
  border-radius: 50%;
  border: 2.5px solid var(--lime);
  /* Brillo interior arriba-izquierda: le da volumen al botón */
  background: radial-gradient(circle at 35% 30%,
              rgba(204,255,0,.24), rgba(5,10,46,.95) 72%);
  color: var(--lime);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  box-shadow: 0 0 12px rgba(204,255,0,.5), 0 0 26px rgba(204,255,0,.18);
  touch-action: manipulation;
  transition: transform var(--tr);
}
#radio-play-btn:active { transform: scale(.9); }
#radio-play-btn svg {
  pointer-events: none;
  width:  clamp(20px, 5.5vw, 26px);
  height: clamp(20px, 5.5vw, 26px);
}

/* Ondas de radio: dos anillos que emanan del play para que se note.
   Solo transform/opacity (GPU); van en pseudo-elementos para no
   pelear con el transform del :active del botón. */
#radio-play-btn::before,
#radio-play-btn::after {
  content: '';
  position: absolute;
  inset: -2.5px;             /* nace justo sobre el borde del botón */
  border-radius: 50%;
  border: 2px solid var(--lime);
  opacity: 0;
  pointer-events: none;
  animation: radioOnda 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;
}
#radio-play-btn::after { animation-delay: 1.2s; }
/* Escala contenida (1.35): la onda no cruza el borde de la tarjeta */
@keyframes radioOnda {
  0%   { transform: scale(1);   opacity: .7; }
  70%  { transform: scale(1.35); opacity: 0; }
  100% { transform: scale(1.35); opacity: 0; }
}
/* Ya está sonando: misión cumplida, las ondas se apagan */
#radio-play-btn.is-playing::before,
#radio-play-btn.is-playing::after { animation: none; }
/* Reduced motion: sin ondas; el glow estático sigue destacando */
@media (prefers-reduced-motion: reduce) {
  #radio-play-btn::before,
  #radio-play-btn::after { animation: none; }
}

/* Columna derecha: fila superior (nombre + estado) y visualizador */
.radio-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
}
.radio-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.radio-title {
  font-family: var(--fd);
  font-size: clamp(11px, 3.2vw, 14px);
  font-weight: 900;
  letter-spacing: 1.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  background: linear-gradient(90deg, var(--cyan), var(--lime));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 8px rgba(0,229,255,.35));
}
.radio-freq {
  font-size: clamp(9px, 2.6vw, 11px);
  letter-spacing: 1px;
}
.radio-badge {
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(5,10,46,.8);
  border: 1px solid rgba(204,255,0,.45);
  border-radius: 30px;
  padding: 3px 10px;
  flex-shrink: 0;
}
#live-indicator {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  transition: background var(--tr), box-shadow var(--tr);
}
#live-indicator.status-live {
  background: var(--red);
  box-shadow: 0 0 7px var(--red);
  animation: livePulse 1s ease-in-out infinite;
}
#live-indicator.status-offline    { background: #555; }
#live-indicator.status-connecting {
  background: var(--orange);
  box-shadow: 0 0 7px var(--orange);
  animation: livePulse .5s ease-in-out infinite;
}
@keyframes livePulse { 0%,100%{opacity:1;transform:scale(1);} 50%{opacity:.4;transform:scale(.7);} }

#live-text {
  font-family: var(--fd);
  font-size: clamp(8px, 2.4dvh, 10px);
  font-weight: 700;
  color: #aab2c6;          /* gris claro: contraste ≥4.5:1 sobre el panel oscuro (a11y) */
  letter-spacing: 1px;
  white-space: nowrap;
  transition: color .3s;
}
.radio-viz {
  display: flex;
  align-items: center;
  background: rgba(0,0,0,.28);
  border: 1px solid rgba(0,229,255,.3);
  border-radius: 10px;
  padding: 4px 8px;
  height: clamp(30px, 6.5dvh, 42px);
  box-shadow: inset 0 0 12px rgba(0,229,255,.08);
  overflow: hidden;
}
#radio-viz-cv { width: 100%; height: 100%; display: block; }

/* ══════════════════════════════════════════════════════════
   S4 — 4 BOTONES PRINCIPALES
══════════════════════════════════════════════════════════ */
#s-btns {
  flex: 0 0 auto;
  height: clamp(70px, 12dvh, 100px);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 3px 6px;
  padding-bottom: max(4px, var(--sb));
  margin-bottom: max(8px, var(--sb));
  gap: 5px;
}
.mb {
  flex: 1;
  height: 100%;
  max-width: 24%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  color: inherit;
  border-radius: 10px;
  background: rgba(5,10,46,.42);
  border: 2px solid;
  overflow: hidden;
  animation: mbFloat 3s ease-in-out infinite;
  touch-action: manipulation;
  transition: transform .12s ease;
}
.mb:nth-child(1) { border-color:var(--magenta); box-shadow:0 0 8px rgba(255,0,255,.28);  animation-delay:0s;    }
.mb:nth-child(2) { border-color:var(--orange);  box-shadow:0 0 8px rgba(255,165,0,.28);  animation-delay:.25s;  }
.mb:nth-child(3) { border-color:var(--cyan);    box-shadow:0 0 8px rgba(0,229,255,.28);  animation-delay:.5s;   }
.mb:nth-child(4) { border-color:var(--green);   box-shadow:0 0 8px rgba(0,255,136,.28);  animation-delay:.75s;  }
.mb:active { animation:none; transform:scale(.93); }
@keyframes mbFloat { 0%,100%{transform:translateY(0);} 50%{transform:translateY(-3px);} }

.btn-i {
  width: auto;
  height: 75%;
  max-height: 70px;
  object-fit: contain;
  background: transparent;
  pointer-events: none;
  flex-shrink: 0;
}
.mb-lbl {
  font-family: var(--fd);
  font-size: clamp(6px, 1.8dvh, 9px);
  font-weight: 700;
  letter-spacing: .8px;
  pointer-events: none;
  text-align: center;
}
.mb:nth-child(1) .mb-lbl { color:var(--magenta); text-shadow:0 0 5px var(--magenta); }
.mb:nth-child(2) .mb-lbl { color:var(--orange);  text-shadow:0 0 5px var(--orange);  }
.mb:nth-child(3) .mb-lbl { color:var(--cyan);    text-shadow:0 0 5px var(--cyan);    }
.mb:nth-child(4) .mb-lbl { color:var(--green);   text-shadow:0 0 5px var(--green);   }

/* ══════════════════════════════════════════════════════════
   PÁGINAS — ENCABEZADO COMÚN
══════════════════════════════════════════════════════════ */
.ph {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 14px 5px;
  background: var(--bg);
  position: relative;
}
.pls {
  position: relative;
  width:  min(110px, 32vw);
  height: min(110px, 32vw);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-bottom: 5px;
}
/* Aros neón giratorios alrededor del logo: RETIRADOS a pedido de
   Daniel (noticias, concurso, reportajes y redes). */
.pr-out, .pr-in { display: none; }
.pls .logo-img {
  width: 82%; height: 82%;
  object-fit: contain;   /* logo nuevo: fondo transparente, sin recorte circular */
  position: relative;
  z-index: 3;
  filter: drop-shadow(0 0 6px rgba(0,229,255,.4));
}
@keyframes rotateCW  { to { transform: rotate(360deg);  } }
@keyframes rotateCCW { to { transform: rotate(-360deg); } }

.back-btn {
  position: absolute;
  left: 10px; top: 8px;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(0,229,255,.1);
  border: 1.5px solid var(--cyan);
  color: var(--cyan);
  font-size: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 6px var(--cyan);
  z-index: 10;
  touch-action: manipulation;
  transition: background var(--tr);
}
.back-btn:active { background: rgba(0,229,255,.22); }
.pt {
  font-family: var(--fd);
  font-size: clamp(12px, 3.8dvh, 17px);
  font-weight: 900;
  color: var(--cyan);
  text-shadow: 0 0 11px var(--cyan);
  letter-spacing: 2px;
  text-align: center;
  margin-bottom: 2px;
}

/* ══════════════════════════════════════════════════════════
   PÁGINA NOTICIAS — CARRUSEL
══════════════════════════════════════════════════════════ */
#pn .pc {
  flex: 1;
  padding: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.carousel-wrap {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.carousel-track {
  display: flex;
  height: 100%;
  transition: transform .35s cubic-bezier(.4,0,.2,1);
  will-change: transform;
}
.carousel-slide {
  flex: 0 0 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 10px;
  position: relative;
}
.carousel-slide img {
  width: 100%; height: 100%;
  object-fit: contain;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(0,229,255,.2);
}
.carousel-slide.loading {
  background: var(--card);
  border-radius: 10px;
  margin: 8px 10px;
}
.carousel-spinner {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 32px; height: 32px;
  border: 3px solid rgba(0,229,255,.2);
  border-top-color: var(--cyan);
  border-radius: 50%;
  animation: spin .8s linear infinite;
}
.carousel-controls {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 8px 0 6px;
}
.carousel-btn {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(5,10,46,.85);
  border: 1.5px solid var(--cyan);
  color: var(--cyan);
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 0 6px var(--cyan);
  touch-action: manipulation;
  transition: background var(--tr);
}
.carousel-btn:active    { background: rgba(0,229,255,.2); }
.carousel-btn:disabled  { opacity: .3; pointer-events: none; }
.carousel-dots { display: flex; gap: 7px; align-items: center; }
.carousel-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.22);
  border: 1px solid rgba(0,229,255,.4);
  cursor: pointer;
  transition: background .2s, transform .2s;
}
.carousel-dot.active {
  background: var(--cyan);
  box-shadow: 0 0 6px var(--cyan);
  transform: scale(1.3);
}
.carousel-hint {
  position: absolute;
  bottom: 16px; left: 50%;
  transform: translateX(-50%);
  font-family: var(--fd);
  font-size: clamp(9px, 2.5dvh, 11px);
  color: var(--cyan);
  letter-spacing: 2px;
  white-space: nowrap;
  pointer-events: none;
  animation: hintAnim 2s ease-in-out 1s 3 forwards;
}
@keyframes hintAnim {
  0%   { opacity:0; transform:translateX(-50%) translateX(0); }
  30%  { opacity:1; }
  70%  { opacity:1; transform:translateX(-50%) translateX(8px); }
  100% { opacity:0; transform:translateX(-50%) translateX(0); }
}

.empty-state {
  width: min(310px, 86vw);
  margin: auto;
  padding: 18px 16px;
  border: 1.5px solid rgba(0,229,255,.45);
  border-radius: 10px;
  background: rgba(5,10,46,.74);
  text-align: center;
  box-shadow: 0 0 18px rgba(0,229,255,.18);
}
.empty-state-panel {
  margin-top: 24px;
}
.empty-state-title {
  font-family: var(--fd);
  font-size: clamp(10px, 3dvh, 13px);
  font-weight: 900;
  color: var(--lime);
  text-shadow: 0 0 8px rgba(204,255,0,.55);
  letter-spacing: 1px;
}
.empty-state-text {
  margin-top: 8px;
  font-size: clamp(11px, 3vw, 14px);
  line-height: 1.45;
  color: rgba(255,255,255,.72);
}
.grid-full {
  grid-column: 1 / -1;
}

/* ══════════════════════════════════════════════════════════
   PÁGINA CONCURSO
══════════════════════════════════════════════════════════ */
.cc-titulo {
  font-family: var(--fd);
  font-size: clamp(22px, 8dvh, 36px);
  font-weight: 900;
  color: #fff;
  text-align: center;
  letter-spacing: 3px;
  text-shadow: 0 0 20px rgba(255,255,255,.3);
  margin-bottom: 2px;
}
.cc-fecha {
  font-family: var(--fd);
  font-size: clamp(10px, 3dvh, 14px);
  color: var(--lime);
  text-align: center;
  letter-spacing: 1px;
  text-shadow: 0 0 8px var(--lime);
  margin-bottom: 4px;
}
.cc-fecha span { color: #fff; }

#pc .pc {
  flex: 1;
  padding: 6px 8px 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Temas a estudiar */
.temas-box {
  background: rgba(255,255,255,.96);
  border-radius: 14px;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}
.temas-titulo {
  font-family: var(--fd);
  font-size: clamp(10px, 3dvh, 14px);
  font-weight: 900;
  color: #1a1a2e;
  text-align: center;
  letter-spacing: 2px;
}
.temas-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
}
.temas-empty {
  grid-column: 1 / -1;
  padding: 10px;
  border-radius: 10px;
  background: #f0f4ff;
  border: 2px solid #dde4f5;
  color: #1a1a2e;
  font-family: var(--fd);
  font-size: clamp(9px, 2.6dvh, 12px);
  font-weight: 700;
  text-align: center;
}
.tema-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  background: #f0f4ff;
  border: 2px solid #dde4f5;
  border-radius: 10px;
  padding: 7px 3px 5px;
  cursor: pointer;
  color: inherit;
  touch-action: manipulation;
  text-decoration: none;
  position: relative;
  transition: transform .15s ease;
}
.tema-btn:active { transform: scale(.94); }
.tema-btn.is-disabled,
.instrucciones-btn.is-disabled {
  opacity: .72;
}
.tema-check {
  position: absolute; top: 3px; left: 3px;
  width: 14px; height: 14px;
  background: #4A90E2;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.tema-check::after { content:'✓'; color:#fff; font-size:8px; font-weight:900; }
.tema-icon   { font-size: clamp(16px, 5dvh, 24px); line-height: 1; }
.tema-nombre {
  font-family: var(--fd);
  font-size: clamp(5px, 1.6dvh, 7px);
  font-weight: 700;
  color: #1a1a2e;
  text-align: center;
  letter-spacing: .4px;
  line-height: 1.2;
}
.instrucciones-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: #f0f4ff;
  border: 2px solid #dde4f5;
  border-radius: 10px;
  padding: 9px 12px;
  cursor: pointer;
  color: inherit;
  touch-action: manipulation;
  text-decoration: none;
  transition: transform .15s ease;
}
.instrucciones-btn:active { transform: scale(.97); }
.instrucciones-btn span {
  font-family: var(--fd);
  font-size: clamp(9px, 2.8dvh, 12px);
  font-weight: 700;
  color: #1a1a2e;
  letter-spacing: .8px;
}

/* Carrusel horizontal de meses */
.concurso-meses-wrap {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}
.concurso-meses-track {
  display: flex;
  flex: 1;
  transition: transform .35s cubic-bezier(.4,0,.2,1);
  will-change: transform;
  min-height: 0;
}
.concurso-mes-slide {
  flex: 0 0 100%;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 3px 2px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.mes-label {
  font-family: var(--fd);
  font-size: clamp(10px, 3dvh, 14px);
  font-weight: 900;
  color: var(--lime);
  text-shadow: 0 0 10px var(--lime);
  text-align: center;
  letter-spacing: 2px;
}
.mes-pendiente {
  font-family: var(--fd);
  font-size: clamp(9px, 2.5dvh, 11px);
  color: var(--dim);
  text-align: center;
  padding: 18px;
}
.mes-ganador { display: flex; justify-content: center; margin-top: 5px; }

.concurso-meses-dots {
  display: flex;
  justify-content: center;
  gap: 10px;
  padding: 5px 0 2px;
  flex-shrink: 0;
}
.cm-dot {
  font-family: var(--fd);
  font-size: clamp(8px, 2.2dvh, 10px);
  font-weight: 700;
  padding: 3px 12px;
  border-radius: 18px;
  border: 1.5px solid rgba(204,255,0,.3);
  background: rgba(5,10,46,.45);
  color: rgba(204,255,0,.4);
  cursor: pointer;
  touch-action: manipulation;
  transition: color .2s ease, border-color .2s ease,
              background .2s ease, box-shadow .2s ease;
}
.cm-dot.active {
  border-color: var(--lime);
  color: var(--lime);
  box-shadow: 0 0 8px rgba(204,255,0,.4);
  background: rgba(204,255,0,.08);
}

/* Semanas */
.semana-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 3px 0;
  min-width: 0;
}
.semana-participantes { display: flex; gap: 2px; align-items: flex-end; flex: 1; min-width: 0; justify-content: space-around; }
.participante         { display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 0; flex: 0 1 auto; }
.participante-avatar  {
  width:  clamp(26px, 7.5dvh, 34px);
  height: clamp(26px, 7.5dvh, 34px);
  border-radius: 50%;
  border: 2px solid var(--cyan);
  background: rgba(5,10,60,.8);
  display: flex; align-items: center; justify-content: center;
}
.participante-avatar.fem  { border-color: var(--magenta); }
.participante-avatar svg  { width: 65%; height: 65%; }
.participante-nombre { font-family:var(--fd); font-size:clamp(7px,1.9dvh,9px); color:#fff; text-align:center; width:clamp(42px,10dvh,58px); max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-weight:700; }
.semana-info  { display:flex; flex-direction:column; align-items:center; gap:2px; flex-shrink:0; }
.semana-lbl   { font-family:var(--fd); font-size:clamp(7px,2dvh,9px); font-weight:900; color:var(--lime); text-shadow:0 0 6px var(--lime); text-align:center; line-height:1.1; }
.semana-arrow { text-align:center; color:var(--lime); text-shadow:0 0 6px var(--lime); font-size:13px; }
.eliminado-box   { display:flex; flex-direction:column; align-items:center; gap:2px; flex-shrink:0; }
.eliminado-x     { width:clamp(22px,6.5dvh,28px); height:clamp(22px,6.5dvh,28px); background:rgba(255,50,50,.15); border:2px solid #ff3333; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:clamp(12px,3.5dvh,16px); color:#ff3333; font-weight:900; box-shadow:0 0 7px rgba(255,50,50,.4); }
.eliminado-nombre { font-family:var(--fd); font-size:clamp(7px,1.9dvh,9px); color:#fff; text-align:center; width:clamp(50px,11dvh,68px); max-width:100%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-weight:900; text-shadow:0 0 7px rgba(255,255,255,.55); }
.eliminado-tag    { font-family:var(--fd); font-size:clamp(5px,1.2dvh,6px); color:#ff4444; letter-spacing:.4px; }
.semana-row.compact { gap: 3px; }
.semana-row.compact .semana-participantes { gap: 1px; }
.semana-row.compact .participante-avatar {
  width: clamp(22px, 6dvh, 28px);
  height: clamp(22px, 6dvh, 28px);
}
.semana-row.compact .participante-nombre {
  width: clamp(30px, 7.4dvh, 40px);
  font-size: clamp(6px, 1.55dvh, 8px);
}
.semana-row.compact .eliminado-nombre {
  width: clamp(42px, 9.5dvh, 58px);
  font-size: clamp(6px, 1.65dvh, 8px);
}

/* Ganador card */
.ganador-card         { display:flex; flex-direction:column; align-items:center; gap:3px; background:rgba(255,255,255,.06); border:1.5px solid rgba(204,255,0,.3); border-radius:10px; padding:7px 10px; }
.ganador-card-titulo  { font-family:var(--fd); font-size:clamp(7px,2dvh,9px); color:var(--lime); letter-spacing:1px; }
.ganador-card-avatar  { width:clamp(34px,9dvh,46px); height:clamp(34px,9dvh,46px); border-radius:50%; border:2px solid var(--cyan); background:rgba(5,10,60,.8); display:flex; align-items:center; justify-content:center; }
.ganador-card-avatar.fem { border-color:var(--magenta); }
.ganador-card-avatar svg { width:65%; height:65%; }
.ganador-card-nombre  { font-family:var(--fd); font-size:clamp(9px,2.5dvh,12px); font-weight:900; color:#fff; text-shadow:0 0 8px var(--lime); }

/* Gran Final */
.gran-final-box    { background:rgba(5,10,46,.8); border:2px solid var(--lime); border-radius:10px; padding:8px 12px; text-align:center; box-shadow:0 0 16px rgba(204,255,0,.2); flex-shrink:0; }
.gran-final-titulo { font-family:var(--fd); font-size:clamp(12px,3.5dvh,17px); font-weight:900; color:var(--lime); text-shadow:0 0 12px var(--lime); letter-spacing:2px; }
.gran-final-sub    { font-family:var(--fd); font-size:clamp(8px,2dvh,10px); color:#fff; margin-top:3px; line-height:1.4; }
.gran-final-sub strong { color:var(--lime); }

/* ══════════════════════════════════════════════════════════
   PÁGINA REPORTAJES — sin scroll, tarjetas compactas
══════════════════════════════════════════════════════════ */
#pr-page .pc {
  flex: 1;
  padding: 4px 8px 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow: hidden;
}
#pr-page .pc { flex:1; min-height:0; display:flex; flex-direction:column; padding:0 14px max(18px,var(--sb)); overflow-y:auto; }
.rg-titulo-wrap {
  border: 2.5px solid var(--neon-lima);
  border-radius: 12px;
  padding: 9px 14px;
  text-align: center;
  box-shadow: 0 0 16px rgba(168,255,0,.35), inset 0 0 10px rgba(168,255,0,.07);
  flex-shrink: 0;
  margin-bottom: 6px;
}
.rg-titulo {
  font-family: var(--fd);
  font-size: clamp(13px, 4dvh, 19px);
  font-weight: 900;
  color: var(--neon-lima);
  text-shadow: 0 0 14px var(--neon-lima);
  letter-spacing: 3px;
}
/* Lema "Escucha · Responde · Participa" */
.rg-lema {
  text-align: center;
  font-family: var(--fb, 'Exo 2', sans-serif);
  font-size: clamp(11px, 1.7dvh, 13px);
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(255,255,255,.7);
  margin: 0 0 12px;
  flex-shrink: 0;
}
/* Lista de reportajes — una columna, scrollable, borde neón alterno */
.rg-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 6px;
}
.rg-card {
  --c: var(--neon-cian);
  background: rgba(8,12,40,.72);
  border: 2px solid var(--c);
  border-radius: 14px;
  padding: 13px 14px;
  display: flex;
  align-items: center;
  gap: 13px;
  box-shadow: 0 0 14px -2px var(--c), inset 0 0 12px rgba(0,0,0,.35);
  touch-action: manipulation;
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}
/* Color neón que alterna por tarjeta */
.rg-card:nth-child(4n+1) { --c: var(--neon-cian); }
.rg-card:nth-child(4n+2) { --c: var(--neon-magenta); }
.rg-card:nth-child(4n+3) { --c: var(--neon-lima); }
.rg-card:nth-child(4n+4) { --c: var(--neon-amarillo); }
.rg-card:active { transform: scale(.98); box-shadow: 0 0 22px -1px var(--c), inset 0 0 12px rgba(0,0,0,.35); }
.rg-play {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 2px solid var(--c);
  background: color-mix(in srgb, var(--c) 14%, transparent);
  color: var(--c);
  display: flex; align-items: center; justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
  box-shadow: 0 0 10px -1px var(--c);
  touch-action: manipulation;
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
  position: relative;
}
.rg-play:active  { transform: scale(.9); }
.rg-play.playing { animation: rgPulse .9s ease-in-out infinite; }
@keyframes rgPulse { 0%,100%{ box-shadow:0 0 10px -1px var(--c);} 50%{ box-shadow:0 0 22px 1px var(--c);} }
.rg-info       { flex:1; min-width:0; }
.rg-pregunta   { font-family:var(--fb,'Exo 2',sans-serif); font-size:clamp(13px,1.95dvh,15px); font-weight:700; color:#fff; line-height:1.32; }
.rg-colegio    { font-family:var(--fb,'Exo 2',sans-serif); font-size:clamp(11px,1.6dvh,12px); font-weight:600; color:var(--c); letter-spacing:.3px; margin-top:4px; }
/* Navegadores viejos sin color-mix: respaldo translúcido del play */
@supports not (background: color-mix(in srgb, red, blue)) {
  .rg-play { background: rgba(255,255,255,.08); }
  .rp-btn  { background: rgba(255,255,255,.08); }
}

/* ── PANTALLA DIVIDIDA: niños (izq) | programas (der) ────────
   Dos columnas en la misma página; cada una con su color
   (lima / violeta) para que se note qué es qué de un vistazo. */
.rg-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  align-items: start;
}
.rg-col { min-width: 0; }

/* Encabezados más compactos: caben en media pantalla */
.rg-split .rg-titulo-wrap {
  padding: 7px 8px;
  min-height: 58px;          /* ambos recuadros a la misma altura */
  display: flex;
  align-items: center;
  justify-content: center;
}
.rg-split .rg-titulo {
  font-size: clamp(11px, 2.7vw, 14px);
  letter-spacing: 1.5px;
  line-height: 1.3;
}
.rg-split .rg-lema {
  font-size: clamp(8.5px, 2.1vw, 11px);
  letter-spacing: 1px;
  margin: 0 0 10px;
}
/* Tarjetas de niños en columna estrecha: apiladas y centradas */
.rg-split .rg-card {
  flex-direction: column;
  text-align: center;
  gap: 8px;
  padding: 12px 8px;
}
.rg-split .rg-play { width: 40px; height: 40px; font-size: 14px; }
.rg-split .rg-info { width: 100%; }
.rg-split .rg-pregunta { font-size: clamp(11.5px, 2.8vw, 14px); }
.rg-split .rg-colegio  { font-size: clamp(10px, 2.4vw, 12px); }

/* ── Columna derecha: PROGRAMAS GRABADOS ─────────────────────
   Violeta uniforme (el color de Reportajes en la barra). */
.rp-titulo-wrap {
  border: 2.5px solid var(--neon-violeta);
  border-radius: 12px;
  padding: 7px 8px;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  box-shadow: 0 0 16px rgba(157,77,255,.35), inset 0 0 10px rgba(157,77,255,.07);
  flex-shrink: 0;
  margin-bottom: 6px;
}
.rp-titulo {
  font-family: var(--fd);
  font-size: clamp(11px, 2.7vw, 14px);
  font-weight: 900;
  color: var(--neon-violeta);
  text-shadow: 0 0 14px var(--neon-violeta);
  letter-spacing: 1.5px;
  line-height: 1.3;
}
.rp-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 6px;
}
.rp-card {
  background: rgba(20,10,44,.72);
  border: 2px solid rgba(157,77,255,.6);
  border-radius: 14px;
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  box-shadow: 0 0 14px -4px var(--neon-violeta), inset 0 0 12px rgba(0,0,0,.35);
  transition: transform .15s ease, box-shadow .15s ease;
}
.rp-card:active { transform: scale(.98); }
.rp-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--neon-violeta);
  background: color-mix(in srgb, var(--neon-violeta) 14%, transparent);
  color: var(--neon-violeta);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
  box-shadow: 0 0 10px -1px var(--neon-violeta);
  touch-action: manipulation;
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
}
.rp-btn:active  { transform: scale(.9); }
.rp-btn.playing { --c: var(--neon-violeta); animation: rgPulse .9s ease-in-out infinite; }
/* Fila de controles: −10s | ▶ | +10s */
.rp-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.rp-seek {
  min-width: 40px;
  height: 28px;
  padding: 0 8px;
  border-radius: 14px;
  border: 1.5px solid rgba(157,77,255,.7);
  background: color-mix(in srgb, var(--neon-violeta) 10%, transparent);
  color: var(--neon-violeta);
  font-family: var(--fb,'Exo 2',sans-serif);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .3px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  touch-action: manipulation;
  cursor: pointer;
  transition: background .15s ease, transform .15s ease;
}
.rp-seek:active { transform: scale(.9); background: color-mix(in srgb, var(--neon-violeta) 25%, transparent); }
.rp-seek:disabled { opacity: .4; pointer-events: none; }
.rp-info   { width: 100%; min-width: 0; }
.rp-nombre {
  font-family: var(--fb,'Exo 2',sans-serif);
  font-size: clamp(11.5px, 2.8vw, 14px);
  font-weight: 700;
  color: #fff;
  line-height: 1.32;
}
.rp-fecha {
  font-family: var(--fb,'Exo 2',sans-serif);
  font-size: clamp(10px, 2.4vw, 12px);
  font-weight: 600;
  color: var(--neon-violeta);
  letter-spacing: .3px;
  margin-top: 4px;
}
/* Reproductor a la espera: se ve el player, atenuado y punteado */
.rp-card.rp-espera {
  border-style: dashed;
  opacity: .6;
  box-shadow: none;
}
.rp-espera .rp-nombre {
  color: rgba(255,255,255,.65);
  font-style: italic;
  font-weight: 600;
}

/* ══════════════════════════════════════════════════════════
   PÁGINA REDES SOCIALES — zigzag sin recuadros
══════════════════════════════════════════════════════════ */
#prs { background:var(--bg); position:fixed; inset:0; min-height:100dvh; }
#prs-bg { position:absolute; inset:0; background-image:url('../assets/fondo.webp'); background-size:cover; background-position:center top; opacity:.3; pointer-events:none; z-index:0; }
#prs .ph  { background:transparent; }
#prs .pc  { flex:1; min-height:0; display:flex; flex-direction:column; padding:0 0 max(22px,var(--sb)); overflow-y:auto; overflow-x:visible; position:relative; z-index:2; }

.rs-titulo {
  font-family: var(--fd);
  font-size: clamp(20px, 7dvh, 30px);
  font-weight: 900;
  color: #fff;
  text-align: center;
  letter-spacing: 4px;
  text-shadow: 0 0 24px rgba(255,255,255,.35);
  padding: 10px 0 6px;
  position: relative; z-index: 3;
  text-transform: lowercase;
}
.rs-zigzag {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 6px 16px 10px;
  gap: 0;
  z-index: 3;
}
.rs-row { display:flex; align-items:center; margin-bottom:clamp(12px,3.5dvh,22px); }
.rs-row.left  { justify-content: flex-start; }
.rs-row.right { justify-content: flex-end;   }

.rs-btn-img {
  width: clamp(120px, 38vw, 165px);
  display: block;
  text-decoration: none;
  border-radius: 14px;
  overflow: hidden;
  animation: rsFloat 3.2s ease-in-out infinite;
  touch-action: manipulation;
  transition: transform .15s ease, filter .15s ease;
  filter: drop-shadow(0 6px 18px rgba(0,0,0,.55));
  position: relative; z-index: 3;
}
.rs-btn-img:nth-child(1) { animation-delay:0s;   }
.rs-btn-img:nth-child(2) { animation-delay:.7s;  }
.rs-btn-img:nth-child(3) { animation-delay:1.4s; }
.rs-btn-img:nth-child(4) { animation-delay:2.1s; }
@keyframes rsFloat { 0%,100%{transform:translateY(0);} 50%{transform:translateY(-7px);} }
.rs-btn-img:active { transform:scale(.93); filter:brightness(1.18) drop-shadow(0 6px 18px rgba(0,0,0,.55)); }
.rs-btn-img img { width:100%; height:auto; display:block; border-radius:14px; }

/* Placeholders si la imagen no existe */
.rs-ph { width:clamp(120px,38vw,165px); padding:16px 10px; border-radius:14px; text-align:center; font-family:var(--fd); font-size:clamp(9px,2.8vw,12px); font-weight:700; cursor:pointer; text-decoration:none; display:flex; align-items:center; justify-content:center; animation:rsFloat 3.2s ease-in-out infinite; }
.rs-ph.ig  { background:rgba(180,0,180,.18); border:1.5px solid var(--magenta); color:var(--magenta); }
.rs-ph.tt  { background:rgba(0,180,220,.18); border:1.5px solid var(--cyan);    color:var(--cyan);    }
.rs-ph.wa  { background:rgba(0,200,100,.18); border:1.5px solid var(--green);   color:var(--green);   }
.rs-ph.cwa { background:rgba(0,200,100,.18); border:1.5px solid var(--green);   color:var(--green);   }

/* ══════════════════════════════════════════════════════════
   TOAST
══════════════════════════════════════════════════════════ */
#toast {
  position: fixed;
  bottom: 65px; left: 50%;
  transform: translateX(-50%) translateY(14px);
  background: rgba(0,229,255,.11);
  border: 1px solid var(--cyan);
  color: var(--cyan);
  padding: 6px 13px;
  border-radius: 18px;
  font-size: 10px;
  font-family: var(--fd);
  opacity: 0;
  transition: opacity .3s, transform .3s;
  z-index: 9998;
  pointer-events: none;
  white-space: nowrap;
}
#toast.show { opacity:1; transform:translateX(-50%) translateY(0); }

/* ══════════════════════════════════════════════════════════
   UTILIDADES
══════════════════════════════════════════════════════════ */
::-webkit-scrollbar       { width: 2px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--cyan); border-radius: 2px; }

.spinner {
  width: 22px; height: 22px;
  border: 2px solid rgba(0,229,255,.18);
  border-top-color: var(--cyan);
  border-radius: 50%;
  animation: spin .8s linear infinite;
  margin: 14px auto;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ══════════════════════════════════════════════════════════
   HOVER — feedback visual en escritorio (a11y guidelines).
   Solo con puntero real para no dejar hover "pegado" en táctil.
══════════════════════════════════════════════════════════ */
@media (hover: hover) and (pointer: fine) {
  #radio-play-btn:hover {
    transform: scale(1.06);
    box-shadow: 0 0 18px var(--lime), 0 0 34px rgba(204,255,0,.32);
  }
  .back-btn:hover,
  .carousel-btn:hover:not(:disabled),
  .rg-play:hover:not(:disabled),
  .rp-btn:hover:not(:disabled) {
    filter: brightness(1.25);
    transform: scale(1.05);
  }
  .carousel-dot:hover { filter: brightness(1.4); }
  .cm-dot:hover {
    border-color: rgba(204,255,0,.7);
    color: rgba(204,255,0,.85);
  }
  .rs2-card:hover {
    filter: brightness(1.12);
    transform: translateY(-2px);
  }
  .da:hover { background: rgba(0,229,255,.16); }
}

/* ══════════════════════════════════════════════════════════
   RESPONSIVE — Tablet y pantallas grandes
══════════════════════════════════════════════════════════ */
@media (min-width: 480px) {
  .dpad-zone { --dpad-size: 31.5px; }
  .da { font-size: 12.6px; }
}
@media (min-width: 768px) {
  /* En tablet la tarjeta no crece sin límite: el flex sobrante
     lo absorbe el juego */
  #s-radio { max-height: 118px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: .001ms !important;
  }
}

/* Contrapartida del CSS crítico inline del index: la app estaba
   oculta hasta que esta hoja (la última en cargar) se aplica. */
#app, .page, #tutorial, #toast { visibility: visible; }

/* ══════════════════════════════════════════════════════════
   NOTICIAS — visor de imágenes a PANTALLA COMPLETA
   Cada noticia es una "página": imagen completa (contain) sobre
   un fondo difuminado de sí misma. Se pasa con un volteo 3D.
══════════════════════════════════════════════════════════ */
/* Fondo branded de la app (igual que en Redes): mantiene la
   identidad detrás de la tarjeta del visor. */
#pn-bg {
  position: absolute; inset: 0; z-index: 0;
  background-image: url('../assets/fondo.webp');
  background-size: cover; background-position: center top;
  opacity: .22; pointer-events: none;
}
#pn .ph, #pn .pc { position: relative; z-index: 2; }
/* Header SIN fondo y logo PEGADO arriba (se ven los elementos flotantes detrás) */
#pn .ph { background: transparent; padding-top: 0; padding-bottom: 2px; }
/* Logo grande y PEGADO arriba (solo en Noticias): el logo llena su
   contenedor (antes ocupaba 68% → dejaba 30px vacíos arriba). */
#pn .pls { width: min(120px, 33vw); height: min(120px, 33vw); margin-bottom: 0; }
#pn .pls .logo-img {
  width: 100%; height: 100%;
  object-fit: contain;
  border-radius: 0;
}
#pn .pt { margin-top: 0; margin-bottom: 0; }   /* "NOTICIAS" pegado bajo el logo */

/* Mismo logo que en Noticias para Concurso, Reportajes y Redes:
   el logo llena su contenedor (sin el espacio vacío del 68%) y al
   mismo tamaño que Noticias. */
#pc .pls, #pr-page .pls, #prs .pls {
  width: min(120px, 33vw); height: min(120px, 33vw);
}
#pc .pls .logo-img, #pr-page .pls .logo-img, #prs .pls .logo-img {
  width: 100%; height: 100%;
  object-fit: contain;
  border-radius: 0;
}

/* Mismo FONDO branded que Noticias en Concurso y Reportajes:
   fondo.webp detrás + header SIN color sólido → desaparece el "corte"
   del header y se ven los elementos flotantes. (Redes ya lo tenía.) */
#pc-bg, #pr-bg {
  position: absolute; inset: 0; z-index: 0;
  background-image: url('../assets/fondo.webp');
  background-size: cover; background-position: center top;
  opacity: .22; pointer-events: none;
}
#pc .ph, #pr-page .ph { background: transparent; }
#pc .ph, #pc .pc, #pr-page .ph, #pr-page .pc { position: relative; z-index: 2; }

/* REDES sin scroll (a pedido de Daniel): el contenido se reparte para
   caber en la pantalla; el zigzag se distribuye en el espacio disponible. */
#prs .pc { overflow: hidden; }
/* Panel de VIDRIO LÍQUIDO (iOS 26) que envuelve los botones y la línea:
   difumina el fondo branded, con reflejo de luz arriba y profundidad. */
#prs .rs-zigzag {
  justify-content: space-between;
  padding: 10px 16px 14px;
  margin: 4px 12px 8px;
  border-radius: 28px;
  background: rgba(255,255,255,.10);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  backdrop-filter: blur(18px) saturate(180%);
  border: 1px solid rgba(255,255,255,.26);
  box-shadow:
    inset 0 1.5px 0 rgba(255,255,255,.40),
    inset 0 -1px 0 rgba(255,255,255,.06),
    0 22px 50px rgba(0,0,0,.45);
}
/* Reflejo de luz superior del vidrio */
#prs .rs-zigzag::after {
  content:''; position:absolute; left:0; right:0; top:0; height:42%;
  border-radius: 28px 28px 0 0;
  background: linear-gradient(180deg, rgba(255,255,255,.30), rgba(255,255,255,0));
  pointer-events:none; z-index:1;
}
#prs .rs-titulo { padding: 6px 0 2px; }
#prs .rs-row { margin-bottom: clamp(4px, 1.2dvh, 12px); }
#prs .rs-btn-img { width: clamp(104px, 32vw, 140px); }

/* ══════════════════════════════════════════════════════════
   REDES — circuito de neón vivo (mejora visual)
   Cada botón late con un halo de su color; el título fluye en
   neón; un brillo ambiental respira detrás. (Botones intactos.)
══════════════════════════════════════════════════════════ */
/* Botones: solo flotar suave (el vidrio es el protagonista, sin halos ruidosos) */
#prs #rs-tt  { animation: rsFloat 3.2s ease-in-out infinite .7s; }
#prs #rs-wa  { animation: rsFloat 3.2s ease-in-out infinite 1.4s; }
#prs #rs-cwa { animation: rsFloat 3.2s ease-in-out infinite 2.1s; }

/* Título con barrido de color neón */
#prs .rs-titulo {
  background: linear-gradient(90deg,#FF2BD6,#00E5FF,#00FF88,#FF2BD6);
  background-size: 300% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  filter: drop-shadow(0 0 10px rgba(0,229,255,.45));
  letter-spacing: 5px;
  animation: rsTitleSheen 7s linear infinite;
}
@keyframes rsTitleSheen { to { background-position: 300% 50%; } }

/* Campo de color vivo detrás del vidrio (lo que el vidrio refracta) */
#prs::before {
  content: ''; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(46% 34% at 20% 22%, rgba(255,43,214,.42), transparent 70%),
    radial-gradient(46% 34% at 82% 48%, rgba(0,229,255,.38), transparent 70%),
    radial-gradient(52% 36% at 52% 88%, rgba(0,255,136,.34), transparent 72%);
  animation: rsAmbient 9s ease-in-out infinite alternate;
}
@keyframes rsAmbient { from{ opacity:.6; transform:scale(1); } to{ opacity:1; transform:scale(1.12); } }

/* Zona de contenido: la tarjeta sube hasta justo debajo de "NOTICIAS"
   y baja hasta la barra inferior → cuadro lo más grande posible. */
#pn .pc {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column; align-items: center;
  gap: 8px;
  padding: 4px 14px 10px;
  overflow: hidden;
}

/* Tarjeta-marco neón que envuelve la imagen (estilo cinema dark) */
#pn .carousel-wrap {
  position: relative;
  flex: 1; min-height: 0;
  width: 100%; max-width: 540px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-deep);
  border: 1.5px solid rgba(0,229,255,.45);
  box-shadow:
    0 0 26px -6px var(--neon-cian),
    0 16px 44px rgba(0,0,0,.5),
    inset 0 0 50px rgba(0,0,0,.45);
}
#pn #carousel-track {
  position: absolute; inset: 0;
  display: block;
  perspective: 1700px;
  transform: none;
}

/* Cada "página" apilada que llena la tarjeta */
.np-slide {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  transform-origin: left center;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  will-change: transform;
  background: var(--bg-deep);
  overflow: hidden;
}
.np-blur {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  filter: blur(24px) brightness(.55);
  transform: scale(1.2);
}
.np-img {
  position: relative; z-index: 2;
  max-width: 100%; max-height: 100%;
  object-fit: contain;
}
/* Sombra que aparece durante el volteo (da el efecto 3D) */
.np-shadow {
  position: absolute; inset: 0; z-index: 3; pointer-events: none;
  opacity: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0) 55%, rgba(0,0,0,.6) 100%);
  transition: opacity .5s ease;
}
.np-slide.turning .np-shadow { opacity: 1; }
.np-spin { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); z-index: 4; }
.np-slide:not(.loading) .np-spin { display: none; }

/* Puntitos + flechas debajo de la tarjeta */
#pn .carousel-controls {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: center; gap: 16px;
  padding: 0; background: transparent; flex-shrink: 0;
}
#pn .carousel-btn {
  background: rgba(0,229,255,.12);
  border: 1.5px solid rgba(0,229,255,.55);
  box-shadow: 0 0 10px -2px var(--neon-cian);
}
#pn .carousel-hint { bottom: 14px; z-index: 5; }

/* ══════════════════════════════════════════════════════════
   REDES SOCIALES — rediseño (rs2-*)
   ══════════════════════════════════════════════════════════ */
#prs { background: #05060A; }

.rs2-header {
  position: relative;
  z-index: 3;
  height: 14%;                 /* dentro del rango 12-15% */
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--safe-top, 0);
}
.rs2-logo { height: 64%; width: auto; object-fit: contain; filter: drop-shadow(0 0 10px rgba(0,229,255,.35)); }
.rs2-back {
  position: absolute;
  left: 14px; top: 50%;
  transform: translateY(-50%);
  width: 44px; height: 44px;
  display: grid; place-items: center;
  font-size: 26px; line-height: 1; color: #00e5ff;
  border: 2px solid #00e5ff; border-radius: 50%;
  background: rgba(0,229,255,.08);
  box-shadow: 0 0 12px rgba(0,229,255,.55), inset 0 0 8px rgba(0,229,255,.25);
}

.rs2-stage {
  position: relative;
  z-index: 2;
  width: 100%;
  height: calc(100% - 14%);
  max-width: calc((100dvh - 14%) * 0.5625);  /* 9:16 */
  margin: 0 auto;
  container-type: size;        /* habilita unidades cqmin/cqi */
  padding-bottom: calc(var(--nav-h, 64px) + var(--safe-bottom, 0));
}

.rs2-titulo {
  position: absolute;
  top: 1.4cqh; left: 0; right: 0;
  text-align: center;
  z-index: 4;
  font-family: var(--font-display, 'Orbitron', sans-serif);
  line-height: .9;
  transform: rotate(-2deg);
}
.rs2-t1 { display: block; font-size: 8.4cqi; font-weight: 900; color: #a8ff00;
  text-shadow: 0 0 8px #a8ff00, 0 0 20px rgba(168,255,0,.6); letter-spacing: .5px; }
.rs2-t2 { display: block; font-size: 4cqi; font-weight: 700; color: #fff; margin: .15cqh 0; }
.rs2-t3 { display: block; font-size: 8.4cqi; font-weight: 900; color: #fff;
  text-shadow: 0 0 8px rgba(255,255,255,.5), 0 0 18px rgba(0,229,255,.4); }
.rs2-chip {
  display: inline-block; margin-top: 1cqh;
  font-family: var(--font-sans); font-size: 2.6cqi; font-weight: 600; color: #cfe9ff;
  padding: .8cqh 2.4cqi; border-radius: 999px;
  background: rgba(8,10,22,.55); border: 1px solid rgba(0,229,255,.5);
  box-shadow: 0 0 10px rgba(0,229,255,.3); backdrop-filter: blur(4px);
  transform: rotate(2deg);
}

.rs2-centro {
  position: absolute;
  left: 50%; top: 54%;
  transform: translate(-50%, -50%);
  width: 54cqi; aspect-ratio: 1;
  z-index: 3;
  display: grid; place-items: center;
}
.rs2-personajes { width: 100%; height: 100%; object-fit: contain; position: relative; z-index: 2;
  filter: drop-shadow(0 0 14px rgba(255,43,214,.4)); }
.rs2-anillo {
  position: absolute; inset: -4%; border-radius: 50%; z-index: 1;
  background: conic-gradient(#ff2bd6,#00e5ff,#a8ff00,#ffe600,#ff2bd6);
  filter: blur(7px); opacity: .55;
  -webkit-mask: radial-gradient(circle, transparent 60%, #000 62%, #000 70%, transparent 72%);
          mask: radial-gradient(circle, transparent 60%, #000 62%, #000 70%, transparent 72%);
}
.rs2-ondas {
  position: absolute; inset: 10%; border-radius: 50%; z-index: 0;
  background: repeating-radial-gradient(circle, rgba(0,229,255,.18) 0 2px, transparent 2px 9px);
  opacity: .5;
}

/* Tarjetas de redes sociales (Task 5) */
.rs2-card {
  position: absolute;
  width: 29cqi; padding: 1.5cqh 2.2cqi;
  display: flex; flex-direction: column; gap: .5cqh;
  border-radius: 14px;
  background: rgba(10,12,26,.62);
  backdrop-filter: blur(8px);
  border: 1.5px solid var(--rs-c);
  box-shadow: 0 0 14px var(--rs-c), inset 0 0 10px rgba(255,255,255,.04);
  color: #fff; z-index: 5;
}
.rs2-card.ig  { --rs-c: #ff2bd6; }
.rs2-card.tt  { --rs-c: #00e5ff; }
.rs2-card.wa  { --rs-c: #00ff88; }
.rs2-card.cwa { --rs-c: #ffe600; }
.rs2-card[data-pos="tl"] { top: 25cqh; left: 1.5cqi; }
.rs2-card[data-pos="tr"] { top: 25cqh; right: 1.5cqi; }
.rs2-card[data-pos="bl"] { bottom: 13cqh; left: 1.5cqi; }
.rs2-card[data-pos="br"] { bottom: 13cqh; right: 1.5cqi; }
.rs2-card-ico { width: 7cqi; height: 7cqi; color: var(--rs-c);
  filter: drop-shadow(0 0 6px var(--rs-c)); }
.rs2-card-ico svg { width: 100%; height: 100%; }
.rs2-card-tit  { font-family: var(--font-display); font-weight: 800; font-size: 3.4cqi;
  color: var(--rs-c); text-shadow: 0 0 7px var(--rs-c); line-height: 1.05; }
.rs2-card-desc { font-family: var(--font-sans); font-size: 2.4cqi; color: #d7e2f0; line-height: 1.12; }
.rs2-card-deco { font-size: 2.8cqi; letter-spacing: .5cqi; opacity: .9; line-height: 1; }
.rs2-card-btn  { align-self: flex-start; margin-top: .3cqh;
  font-family: var(--font-display); font-weight: 700; font-size: 2.3cqi;
  color: var(--rs-c); padding: .7cqh 1.7cqi; border: 1px solid var(--rs-c);
  border-radius: 999px; box-shadow: 0 0 8px var(--rs-c); }
.rs2-card:active { transform: scale(.97); }

.rs2-svg {
  position: absolute; inset: 0; width: 100%; height: 100%;
  z-index: 1; pointer-events: none;
  filter: drop-shadow(0 0 3px currentColor);
}

/* Animación de entrada + respiración del anillo + reduced-motion (Task 7) */
@keyframes rs2In { from { opacity: 0; transform: var(--rs2-from); } to { opacity: 1; } }
#prs.active .rs2-card,
#prs.active .rs2-centro { animation: rs2In .5s var(--ease, ease-out) both; }
#prs.active .rs2-card[data-pos="tl"] { --rs2-from: translateY(-14px) scale(.9); animation-delay:.05s; }
#prs.active .rs2-card[data-pos="tr"] { --rs2-from: translateY(-14px) scale(.9); animation-delay:.12s; }
#prs.active .rs2-card[data-pos="bl"] { --rs2-from: translateY(14px) scale(.9);  animation-delay:.19s; }
#prs.active .rs2-card[data-pos="br"] { --rs2-from: translateY(14px) scale(.9);  animation-delay:.26s; }
#prs.active .rs2-centro { --rs2-from: translate(-50%,-50%) scale(.85); }
.rs2-anillo { animation: rs2Pulso 3.4s ease-in-out infinite; }
@keyframes rs2Pulso { 0%,100% { opacity:.45; } 50% { opacity:.7; } }

@media (prefers-reduced-motion: reduce) {
  #prs.active .rs2-card, #prs.active .rs2-centro { animation: none; opacity: 1; }
  .rs2-anillo { animation: none; }
}
.rs2-svg circle { filter: drop-shadow(0 0 2.5px currentColor); }
