/* Grapple Rush — estilo: cronómetro de carreras, tinta oscura y acentos de neón. */
:root {
  --tinta: #12101c; --tinta2: #1c1930; --papel: #f4f6ff;
  --neon: #38e1ff; --lima: #b6ff3d; --oro: #ffc233; --plata: #cdd7e6; --bronce: #e08b48; --diamante: #9d7bff;
  --rojo: #ff4d5e; --verde: #3ddc84;
  --ui: 'Segoe UI', system-ui, -apple-system, 'Helvetica Neue', Arial, sans-serif;
  --st: env(safe-area-inset-top, 0px); --sb: env(safe-area-inset-bottom, 0px);
  --sl: env(safe-area-inset-left, 0px); --sr: env(safe-area-inset-right, 0px);
}
html, body { margin: 0; height: 100%; overflow: hidden; background: var(--tinta); color: var(--papel); font-family: var(--ui);
  touch-action: none; overscroll-behavior: none; -webkit-user-select: none; user-select: none; -webkit-tap-highlight-color: transparent; }
canvas#lienzo { display: block; position: fixed; inset: 0; width: 100%; height: 100%; }
body.capturado canvas#lienzo { cursor: none; }
body.libre canvas#lienzo { cursor: crosshair; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
#ui { position: fixed; inset: 0; z-index: 2; pointer-events: none; }
#vineta { position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(122% 90% at 50% 46%, rgba(0,0,0,0) 50%, rgba(5,4,14,.36) 100%); }
.oculto { display: none !important; }
b, .num { font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------- barras de scroll
   Con el estilo del juego (lo pidió CrazyGames en la revisión de la v83): un carril oscuro redondeado y la barra en
   degradado de neón, más viva al pasar por encima. Chrome y Edge usan ::-webkit-scrollbar; Firefox (que no lo tiene),
   scrollbar-color. Las dos cosas no pueden ir juntas: en Chrome, scrollbar-color anula las ::-webkit-scrollbar. */
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: rgba(255,255,255,.05); border-radius: 99px; margin: 6px; }
::-webkit-scrollbar-thumb { border-radius: 99px; border: 3px solid transparent; background-clip: padding-box;
  background-color: var(--neon); background-image: linear-gradient(180deg, var(--neon), var(--diamante)); }
::-webkit-scrollbar-thumb:hover { border-width: 2px; background-image: linear-gradient(180deg, #7ff0ff, var(--lima)); }
::-webkit-scrollbar-thumb:active { border-width: 2px; background-image: linear-gradient(180deg, var(--lima), var(--neon)); }
::-webkit-scrollbar-corner { background: transparent; }
@supports not selector(::-webkit-scrollbar) { * { scrollbar-width: thin; scrollbar-color: var(--neon) rgba(255,255,255,.05); } }

/* ---------------------------------------------------------- pantallas */
.pantalla { position: absolute; inset: 0; display: none; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; pointer-events: auto; box-sizing: border-box; overflow-y: auto;
  padding: calc(var(--st) + 16px) calc(var(--sr) + 16px) calc(var(--sb) + 16px) calc(var(--sl) + 16px); }
.pantalla.show { display: flex; }
.pantalla { justify-content: safe center; }
.pantalla > * { flex-shrink: 0; }
#cargando { background: radial-gradient(120% 90% at 50% 0%, #2a2150 0%, #12101c 62%), var(--tinta); }
/* La portada deja ver el lobby detrás, solo lo oscurece: se entiende que hay un juego vivo ahí
   esperando, no una pantalla muerta. */
#inicio { z-index: 8; cursor: pointer;
  background: radial-gradient(120% 100% at 50% 34%, rgba(26,22,58,.42) 0%, rgba(8,7,18,.86) 72%);
  backdrop-filter: blur(2px); -webkit-backdrop-filter: blur(2px); }
#inicio .logo { text-shadow: 0 12px 44px rgba(0,0,0,.65); }
/* con la portada delante, el resto del interfaz sobra: es una carátula, no una partida a medias */
body.portada #barraLobby, body.portada #portales, body.portada #hud { opacity: 0; }
#barraLobby, #portales { transition: opacity .35s ease; }
.inicioPista { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-top: 14px; }
.inicioPista b { font-size: clamp(15px, 2.6vw, 23px); font-weight: 900; letter-spacing: .15em; font-style: italic;
  color: #06121a; background: linear-gradient(100deg, var(--neon), #8df3ff); padding: 13px 34px; border-radius: 16px;
  box-shadow: 0 10px 34px rgba(56,225,255,.38); animation: latir 1.7s ease-in-out infinite; }
.inicioPista span { color: #aab4d4; font-weight: 700; font-size: clamp(11px, 1.9vw, 14px); letter-spacing: .04em; }
@keyframes latir { 0%,100% { transform: scale(1); } 50% { transform: scale(1.05); } }
/* detrás del menú gira el circuito: los paneles son velos, no fondos opacos */
#menu { background: linear-gradient(rgba(12,10,26,.32), rgba(12,10,26,.72)); }
/* (la Dulcería también: sin velo, su cabecera no se leía encima de la plaza; revisión de CrazyGames, 2026-10-22) */
#niveles, #retos, #torneo, #copa, #pase, #tienda, #dulceria, #tiendaNeon, #ajustes, #ayuda { background: rgba(12,10,26,.86); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); }
#menu::before, #cargando::before {
  content: ''; position: absolute; inset: 0; opacity: .5; pointer-events: none;
  background: repeating-linear-gradient(115deg, transparent 0 46px, rgba(56,225,255,.055) 46px 48px); }
/* el ratón se soltó en plena carrera: un velo y un clic en cualquier sitio para seguir */
#suelto { background: rgba(10, 8, 20, .55); cursor: pointer; gap: 6px; }
#pausa, #fin { background: rgba(10, 8, 20, .82); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); justify-content: flex-start; }
#niveles, #retos, #torneo, #copa, #pase, #tienda, #dulceria, #tiendaNeon, #ajustes, #ayuda { justify-content: flex-start; }

.logo { position: relative; font-weight: 900; font-size: clamp(40px, 9vw, 96px); line-height: .86; letter-spacing: -.02em;
  font-style: italic; margin: 0 0 6px; text-transform: uppercase; }
.logo span { display: block; color: var(--neon); text-shadow: 0 0 26px rgba(56,225,255,.5); }
.logo i { position: absolute; left: 50%; top: 50%; width: 0; }
.lema { position: relative; margin: 0 0 22px; color: #b9c2e0; font-weight: 600; font-size: clamp(13px, 2.2vw, 17px); letter-spacing: .04em; }
h2 { margin: 0; font-weight: 900; font-size: clamp(20px, 4vw, 30px); letter-spacing: .02em; text-transform: uppercase; font-style: italic; }
h3.mundoTit { margin: 20px 0 8px; font-size: 14px; letter-spacing: .22em; text-transform: uppercase; color: var(--neon); font-weight: 800; }
.nota { color: #96a0c0; font-weight: 600; font-size: 13px; margin: 10px 0 0; }

/* ---------------------------------------------------------- botones */
.btn { position: relative; background: rgba(255,255,255,.07); border: 2px solid rgba(255,255,255,.16); border-radius: 14px;
  padding: 11px 20px; margin: 5px; font-weight: 800; font-size: 15px; letter-spacing: .04em; min-width: 130px;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  transition: transform .08s, background .16s, border-color .16s; }
.btn:hover { background: rgba(255,255,255,.14); border-color: rgba(255,255,255,.34); }
.btn:active { transform: scale(.97); }
.btn small { font-size: 11px; font-weight: 600; opacity: .7; letter-spacing: .02em; }
.btn.grande { background: linear-gradient(100deg, var(--neon), #7af0ff); color: #06121a; border: 0; font-size: clamp(19px, 3.4vw, 26px);
  padding: 15px 46px; border-radius: 18px; box-shadow: 0 10px 34px rgba(56,225,255,.34); font-style: italic; }
.btn.grande:hover { filter: brightness(1.08); }
.btn.grande small { opacity: .72; font-style: normal; }
.btn.oro { background: linear-gradient(100deg, var(--oro), #ffe08a); color: #2a1c00; border: 0; }
/* el rival: el que tienes justo delante en la tabla. Va en morado para que no se confunda ni con el
   botón grande (reintentar) ni con el dorado (anuncio) */
.btn.rival { background: linear-gradient(100deg, #7b46ff, #b57cff); color: #150726; border: 0;
  box-shadow: 0 8px 26px rgba(123,70,255,.32); }
.btn.rival:hover { filter: brightness(1.09); }
.btn.rival small { opacity: .78; }
.btn.chico { padding: 8px 14px; min-width: 0; font-size: 13px; }
.btn:disabled { opacity: .45; cursor: default; }
.fila { display: flex; flex-wrap: wrap; justify-content: center; align-items: stretch; max-width: 640px; }
.cabecera { width: min(880px, 100%); display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.cabecera > span { min-width: 90px; }

/* ---------------------------------------------------------- chips */
.chip { display: inline-flex; align-items: center; justify-content: center; white-space: nowrap; gap: 6px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
  border-radius: 20px; padding: 6px 14px; font-weight: 800; font-size: 14px; }
.arriba { position: absolute; top: calc(var(--st) + 14px); left: calc(var(--sl) + 14px); right: calc(var(--sr) + 14px);
  display: flex; justify-content: space-between; gap: 8px; }
#menuStats { position: absolute; bottom: calc(var(--sb) + 12px); left: 0; right: 0; color: #7d87a8; font-size: 12px; font-weight: 600; }

/* ---------------------------------------------------------- niveles */
#listaNiveles { width: min(1040px, 100%); }
.rejilla { display: grid; grid-template-columns: repeat(auto-fill, minmax(205px, 1fr)); gap: 11px; }
/* la fila de arriba (entrenamiento, reto, torneo, comunidad): las cuatro juntas, también en el móvil */
.rejilla.modos { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 560px) { .rejilla.modos { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tarjetaNivel { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; text-align: left;
  background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.12); border-radius: 14px;
  padding: 0 0 11px; overflow: hidden; transition: transform .1s, border-color .16s; }
/* la foto del circuito, arriba y a todo lo ancho */
.tarjetaNivel.comunidad { border-color: var(--neon); background: rgba(56,225,255,.08); }
.tarjetaNivel.comunidad .nnum { font-style: normal; }
.tarjetaNivel.comunidad .nnom i { color: var(--neon); }
.nchapa { position: absolute; top: 8px; right: 8px; z-index: 1; font-size: 10px; font-weight: 900; letter-spacing: .12em;
  padding: 3px 8px; border-radius: 7px; background: var(--lima); color: #12200a; box-shadow: 0 2px 12px rgba(0,0,0,.4); }
.nport { grid-column: 1 / -1; position: relative; aspect-ratio: 16 / 9; margin-bottom: 8px;
  background-size: cover; background-position: center; background-color: #141826; }
.nport::after { content: ''; position: absolute; inset: 0;
  background: linear-gradient(rgba(10,8,20,0) 45%, rgba(10,8,20,.8) 100%); }
.tarjetaNivel .nnum { position: absolute; left: 10px; bottom: 4px; z-index: 1; font-style: italic;
  font-size: 23px; font-weight: 900; color: #fff; text-shadow: 0 2px 10px rgba(0,0,0,.85); }
.ncand { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center;
  justify-content: center; font-size: 30px; font-style: normal; }
.tarjetaNivel.cerrado .nport { filter: grayscale(.85) brightness(.45); }
.tarjetaNivel > :not(.nport) { margin-left: 13px; }
.tarjetaNivel > .nmed { margin-right: 13px; }
.tarjetaNivel:hover { border-color: var(--neon); transform: translateY(-2px); }
.tarjetaNivel.tuto { border-color: var(--lima); background: rgba(182,255,61,.09); }
.tarjetaNivel.tuto .nnum { color: var(--lima); }
.tarjetaNivel.tuto.hecho { border-color: rgba(255,255,255,.12); background: rgba(255,255,255,.06); }
.tarjetaNivel.cerrado { opacity: .45; cursor: default; }
.tarjetaNivel.cerrado:hover { border-color: rgba(255,255,255,.12); transform: none; }
.nnom { grid-column: 1 / -1; font-weight: 800; font-size: 15px; }
.nnom i { display: block; font-style: normal; font-weight: 600; font-size: 11px; color: var(--neon); opacity: .75; letter-spacing: .06em; text-transform: uppercase; }
.ntiempo { font-size: 13px; font-weight: 700; color: var(--papel); font-variant-numeric: tabular-nums; }
.nobj { grid-column: 1 / -1; font-size: 11px; color: #8b95b6; font-weight: 600; }
.nmed { grid-column: 2; grid-row: 2; width: 15px; height: 15px; border-radius: 50%; align-self: center; justify-self: end; }
.nmed.m0 { background: rgba(255,255,255,.12); }
.nmed.m1 { background: var(--bronce); } .nmed.m2 { background: var(--plata); }
.nmed.m3 { background: var(--oro); box-shadow: 0 0 12px rgba(255,194,51,.6); }
.nmed.m4 { background: var(--diamante); box-shadow: 0 0 14px rgba(157,123,255,.7); }

/* ---------------------------------------------------------- ajustes, tienda, ayuda */
.lista { width: min(430px, 100%); display: flex; flex-direction: column; gap: 8px; }
.opcion { width: 100%; box-sizing: border-box; justify-content: space-between; flex-direction: row; }
.rango { display: flex; align-items: center; gap: 12px; background: rgba(255,255,255,.07); border: 2px solid rgba(255,255,255,.14);
  border-radius: 14px; padding: 10px 16px; font-weight: 800; font-size: 14px; }
.rango input { flex: 1; accent-color: var(--neon); }
/* Los dos menús con probador (personaje y arma). El lado izquierdo se deja transparente a
   propósito: por ahí se ve el muñeco o el arma de verdad, que están colgados de la cámara. */
.probador { justify-content: flex-start; align-items: flex-end;
  background: linear-gradient(90deg, rgba(12,10,26,.12) 0%, rgba(12,10,26,.35) 26%, rgba(12,10,26,.9) 48%, rgba(12,10,26,.95) 100%); }
.probCol { width: min(600px, 62%); display: flex; flex-direction: column; align-items: center; gap: 4px; }
.probCol .cabecera { width: 100%; }
@media (max-width: 780px) {
  .probador { align-items: center; background: rgba(12,10,26,.88); }
  .probCol { width: 100%; }
}
.rejillaEquipo { width: 100%; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 9px; }
/* la barra de abajo: lo que estás probándote y el botón de comprarlo */
/* Siempre a la vista, pegada abajo: al final de una lista larga no la veía nadie (revisión de CrazyGames) */
.barraCompra { position: sticky; bottom: 0; z-index: 3; box-sizing: border-box;
  width: 100%; margin-top: 12px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  background: rgba(20,18,38,.97); border: 2px solid rgba(182,255,61,.55); border-radius: 16px; padding: 10px 12px;
  box-shadow: 0 -10px 26px rgba(0,0,0,.5); }
.barraCompra .bcNom { flex: 1; min-width: 120px; text-align: left; font-weight: 800; font-size: 15px; }
.barraCompra .bcNom small { display: block; font-size: 11px; font-weight: 700; color: var(--lima);
  letter-spacing: .12em; text-transform: uppercase; }
.barraCompra .btn { margin: 0; min-width: 108px; }
.barraCompra .btn.oro:disabled { opacity: .55; }
.tarjetaCuerda.probando { border-color: var(--lima); box-shadow: 0 0 0 2px rgba(182,255,61,.25) inset; }
.tarjetaCuerda.probando .cpre { color: var(--lima); }
/* lo prestado para la próxima carrera (progreso.prestar): puesto, pero con el borde a trazos */
.tarjetaCuerda.prestada { border-style: dashed; }
.tarjetaCuerda.prestada .cpre { color: var(--lima); }
/* el botón de usar algo una carrera a cambio de un anuncio: ni dorado como el de comprar ni más
   llamativo que él */
.btn.video { border-color: rgba(182,255,61,.55); background: rgba(182,255,61,.1); color: var(--lima); }
.btn.video:hover { background: rgba(182,255,61,.18); border-color: var(--lima); }
#peTitulos { width: 100%; gap: 4px; }
.filaRec.titulo { cursor: pointer; grid-template-columns: 30px 1fr auto; text-align: left; font: inherit; font-weight: 700;
  font-size: 14px; color: var(--papel); border: 0; }
.filaRec.titulo:hover { background: rgba(56,225,255,.14); }
.filaRec.titulo i { font-size: 12px; color: #8b95b6; }
.filaRec.titulo.cerrado { opacity: .5; cursor: default; }
.filaRec.titulo.cerrado:hover { background: rgba(255,255,255,.05); }
.filaRec.titulo.yo i { color: var(--lima); }
/* la muestra del armazón: una barra que crece con el largo del cañón */
.muestra.punta.arma em { display: block; height: 6px; border-radius: 3px; background: var(--b); box-shadow: 0 0 8px rgba(0,0,0,.4); }
.tarjetaCuerda { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; background: rgba(255,255,255,.06);
  border: 2px solid rgba(255,255,255,.12); border-radius: 14px; padding: 12px; }
.tarjetaCuerda:hover { border-color: var(--neon); }
.tarjetaCuerda.puesto { border-color: var(--lima); }
.muestra { width: 100%; height: 12px; border-radius: 8px; }
/* la muestra de la ropa ES la prenda, dibujada con la misma geometría que lleva el muñeco */
.muestra.prenda { height: 54px; border-radius: 10px; background-repeat: no-repeat;
  background-position: center; background-size: contain;
  background-color: rgba(255,255,255,.045); }
/* la muestra del garfio: el glifo sobre sus dos colores de verdad */
.muestra.punta { height: 34px; display: flex; align-items: center; justify-content: center; font-size: 19px;
  background: linear-gradient(135deg, var(--a), var(--b)); text-shadow: 0 1px 3px rgba(0,0,0,.55); }
/* la muestra de la mira ES la mira: mismo HTML que verás en pantalla */
.muestra.mira { position: relative; left: auto; top: auto; margin: 0 auto; width: 26px; height: 34px; }
.muestra.mira i, .muestra.mira b { margin-top: 4px; }
.tab em { font-style: normal; background: var(--lima); color: #12200a; border-radius: 999px;
  padding: 0 5px; margin-left: 5px; font-size: 11px; font-weight: 900; }
.tab.on em { background: #06121a; color: var(--neon); }
.cnom { font-weight: 800; font-size: 14px; }
.cpre { font-size: 12px; color: #9aa4c4; font-weight: 700; }
.filaAyuda { display: flex; justify-content: space-between; gap: 14px; padding: 9px 14px; background: rgba(255,255,255,.05); border-radius: 11px; font-size: 14px; }
.filaAyuda b { color: var(--neon); }
#listaTrucos { text-align: left; max-width: 430px; color: #c3cbe6; font-size: 13.5px; line-height: 1.6; padding-left: 18px; }
#listaTrucos li { margin-bottom: 7px; }

/* ---------------------------------------------------------- HUD */
/* Apagado no basta con transparente: lo que lleva pointer-events (JUGAR, la barra de la plaza, los
   botones de saltar) seguía recogiendo clics invisible encima de los paneles. `visibility` va con su
   propia transición para que el fundido de salida se vea entero. */
#hud { position: absolute; inset: 0; opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s; }
/* los avisos con un panel abierto: el HUD está apagado, así que van en su cartel, encima de todo */
#avisoMenu { position: absolute; left: 50%; bottom: calc(var(--sb) + 22px); z-index: 60; transform: translate(-50%, 10px);
  opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; width: max-content; max-width: min(560px, 88vw);
  background: rgba(10,8,20,.94); border: 1px solid rgba(182,255,61,.55); color: var(--papel); padding: 10px 18px;
  border-radius: 14px; font-weight: 800; font-size: 14px; text-align: center; box-shadow: 0 8px 30px rgba(0,0,0,.55); }
#avisoMenu.ver { opacity: 1; transform: translate(-50%, 0); }
/* mientras se pide y se ve un anuncio no se toca nada (portal.js) */
body.anuncio #ui { pointer-events: none; }
body.anuncio #ui * { pointer-events: none !important; }
/* el icono de vídeo del botón del anuncio con premio */
.icoVideo { width: 1.15em; height: 1.15em; vertical-align: -.2em; margin-right: .45em; fill: currentColor; }
#ajNombre:disabled { opacity: .75; cursor: default; }
/* la foto de perfil de CrazyGames (menus.pintaPerfil) */
.chip.perfil { gap: 7px; padding-left: 4px; }
.chip.perfil img, .avatar { width: 24px; height: 24px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  background: rgba(255,255,255,.12); }
.chip.perfil b { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar { width: 30px; height: 30px; margin-right: 8px; }
/* con la barra aligerada (cuarta revisión) el nombre cabe también en el móvil: se recorta, no se quita */
#hud.jugando { opacity: 1; visibility: visible; }
.hTiempo { position: absolute; top: calc(var(--st) + 8px); left: 50%; transform: translateX(-50%);
  font-size: clamp(30px, 5.6vw, 52px); font-weight: 900; font-style: italic; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums; text-shadow: 0 2px 10px rgba(0,0,0,.55), 0 0 26px rgba(0,0,0,.4); }
.hTiempo.tarde { color: #ff8a95; }
.hMedalla { position: absolute; top: calc(var(--st) + 60px); left: 50%; transform: translateX(-50%);
  font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; padding: 3px 12px; border-radius: 20px;
  background: rgba(0,0,0,.34); font-variant-numeric: tabular-nums; }
.hMedalla.m-bronce { color: var(--bronce); } .hMedalla.m-plata { color: var(--plata); }
.hMedalla.m-oro { color: var(--oro); } .hMedalla.m-autor { color: var(--diamante); }
.hMedalla.fuera { color: #ff8a95; }
.hDelta { position: absolute; top: calc(var(--st) + 88px); left: 50%; transform: translateX(-50%) scale(.9);
  font-size: clamp(22px, 4vw, 36px); font-weight: 900; font-style: italic; opacity: 0; transition: opacity .2s, transform .2s;
  font-variant-numeric: tabular-nums; text-shadow: 0 2px 14px rgba(0,0,0,.7); }
.hDelta.ver { opacity: 1; transform: translateX(-50%) scale(1); }
.hDelta.bueno { color: var(--verde); } .hDelta.malo { color: var(--rojo); }
#hPunto { position: absolute; top: calc(var(--st) + 14px); left: calc(var(--sl) + 16px); font-weight: 800; font-size: 15px; opacity: .85; }
#hFantasma { position: absolute; top: calc(var(--st) + 38px); left: calc(var(--sl) + 16px); font-size: 11.5px; font-weight: 700; color: #7fd6ff; opacity: .9; }
#hSplits { position: absolute; top: calc(var(--st) + 14px); right: calc(var(--sr) + 16px); display: flex; flex-direction: column; gap: 3px; align-items: flex-end; }
body.tactil #hSplits { top: calc(var(--st) + 58px); }   /* en tactil ahi arriba esta el boton de pausa */
.split { display: flex; gap: 8px; align-items: baseline; font-size: 12.5px; font-weight: 700; background: rgba(0,0,0,.32); padding: 3px 9px; border-radius: 8px; font-variant-numeric: tabular-nums; }
.split b { color: var(--neon); } .split i { font-style: normal; }
.split.bueno i { color: var(--verde); } .split.malo i { color: var(--rojo); }

#hVel { position: absolute; bottom: calc(var(--sb) + 16px); left: 50%; transform: translateX(-50%); text-align: center;
  --k: 0; color: color-mix(in srgb, var(--papel) calc(100% - var(--k) * 100%), var(--lima)); }
#hVelNum { font-size: clamp(34px, 6vw, 58px); font-weight: 900; font-style: italic; line-height: .9; font-variant-numeric: tabular-nums;
  text-shadow: 0 0 calc(var(--k) * 26px) rgba(182,255,61,.75), 0 3px 14px rgba(0,0,0,.6); }
#hVel small { display: block; font-size: 11px; letter-spacing: .24em; opacity: .6; font-weight: 700; }

.hAviso { position: absolute; top: 62%; left: 50%; transform: translate(-50%, 0) scale(.94); opacity: 0; transition: opacity .18s, transform .18s;
  font-size: clamp(15px, 2.6vw, 21px); font-weight: 800; letter-spacing: .04em; text-align: center;
  background: rgba(10,8,20,.6); padding: 7px 18px; border-radius: 22px; backdrop-filter: blur(3px); }
.hAviso.ver { opacity: 1; transform: translate(-50%, 0) scale(1); }
/* En la plaza, el aviso crece hacia ARRIBA desde encima de JUGAR (los círculos del grupo van a su lado): con tres
   líneas bajaba hasta tapar el botón (revisión del 2026-11-04) */
body.enLobby .hAviso { top: auto; bottom: calc(var(--sb) + 150px); max-width: min(760px, 76vw); z-index: 3;
  font-size: clamp(13px, 1.7vw, 17px); }   /* (más pequeño y ancho: en dos líneas no llega a la mira del centro, y si llega, va encima) */
/* en pantallas bajas el aviso y la carga del portal caían encima del botón de JUGAR (sexta revisión) */
@media (max-height: 480px) { body.enLobby .hAviso { bottom: calc(var(--sb) + 108px); } body.enLobby #avisoPortal { top: 30%; } }

/* la medalla del resultado: anillo de metal, disco y una onda que sale una vez al aparecer */
.emblema { display: none; position: relative; width: 86px; height: 86px; margin: 8px auto 4px; }
.emblema.ver { display: block; animation: medallaEntra .5s cubic-bezier(.2, 1.5, .4, 1) both; }
.emblema::before { content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: conic-gradient(from 210deg, var(--c1), var(--c2), var(--c1), var(--c2), var(--c1));
  box-shadow: 0 0 0 4px rgba(255,255,255,.12) inset, 0 10px 30px var(--brillo); }
.emblema::after { content: ''; position: absolute; inset: 14px; border-radius: 50%;
  background: radial-gradient(circle at 34% 26%, rgba(255,255,255,.6), rgba(255,255,255,0) 60%), var(--c2);
  box-shadow: 0 2px 9px rgba(0,0,0,.38) inset; }
.emblema b { position: absolute; inset: 0; z-index: 1; display: flex; align-items: center; justify-content: center;
  font-size: 30px; color: rgba(30,20,6,.72); filter: drop-shadow(0 1px 2px rgba(255,255,255,.35)); }
.emblema i { position: absolute; inset: -12px; border-radius: 50%; border: 2px solid var(--c2);
  animation: medallaOnda .95s ease-out .12s both; }
.emblema.m1 { --c1: #b5713f; --c2: #f0a869; --brillo: rgba(240,168,105,.4); }
.emblema.m2 { --c1: #8792ab; --c2: #dce4f2; --brillo: rgba(220,228,242,.4); }
.emblema.m3 { --c1: #c2931a; --c2: #ffd75e; --brillo: rgba(255,215,94,.48); }
.emblema.m4 { --c1: #2f95bb; --c2: #9ff2ff; --brillo: rgba(159,242,255,.5); }
@keyframes medallaEntra { from { transform: scale(.3) rotate(-25deg); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes medallaOnda { from { transform: scale(.62); opacity: .85; } to { transform: scale(1.75); opacity: 0; } }

/* ---------------------------------------------------------- pestañas */
.tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; width: min(700px, 100%); margin: 10px 0 12px; }
.tab { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: 999px;
  padding: 7px 15px; font: inherit; font-weight: 800; font-size: 13px; color: #b9c2e0; }
.tab:hover { border-color: rgba(255,255,255,.32); color: var(--papel); }
.tab.on { background: var(--neon); border-color: var(--neon); color: #06121a; }

/* ---------------------------------------------------------- taller */
#taller { background: rgba(12,10,26,.9); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); justify-content: flex-start; }
.talPanel { width: min(700px, 100%); display: flex; flex-direction: column; align-items: center; gap: 12px; }
.talBloque { width: 100%; text-align: left; }
.talBloque > label { display: block; font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
  color: var(--neon); font-weight: 800; margin: 0 0 6px 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips .chip { border: 1px solid rgba(255,255,255,.16); cursor: pointer; font-size: 13px; padding: 6px 13px; }
.chips .chip:hover:not(:disabled) { border-color: var(--neon); }
.chips .chip:disabled { opacity: .35; cursor: default; }
.chip.tema { border-left: 5px solid var(--c); }
.chip.tema.on { background: var(--c); border-color: var(--c); color: #0d0a18; }

/* Tu circuito: las secciones en el orden en que se recorren, todas en una caja. Se arrastran para
   reordenarlas (taller.agarra) */
.receta { display: flex; flex-wrap: wrap; gap: 6px; min-height: 40px; padding: 8px; box-sizing: border-box;
  border: 1px dashed rgba(56,225,255,.38); border-radius: 14px; background: rgba(56,225,255,.04); }
.talBloque > label i { font-style: normal; color: #8b95b6; letter-spacing: .08em; margin-left: 6px; }
.talArrastra { margin: 5px 0 0 4px; font-size: 11.5px; text-align: left; }
.trozo { display: flex; align-items: center; gap: 5px; background: rgba(56,225,255,.1);
  border: 1px solid rgba(56,225,255,.34); border-radius: 12px; padding: 4px 6px 4px 6px; font-weight: 800; font-size: 13px;
  cursor: grab; touch-action: none; }
.trozo .asa { font-style: normal; color: rgba(255,255,255,.45); font-size: 14px; line-height: 1; }
.trozo.cogido { opacity: .35; }
/* la copia que sigue al puntero mientras se arrastra */
.trozo.flota { position: fixed; z-index: 70; pointer-events: none; cursor: grabbing; color: var(--papel);
  background: rgba(20,40,60,.96); box-shadow: 0 10px 26px rgba(0,0,0,.55); transform: rotate(-3deg); font-family: var(--ui); }
/* la raya verde: dónde caerá al soltarla */
.trozo.antes { box-shadow: -5px 0 0 -1px var(--lima); }
.receta.alFinal::after { content: ''; width: 4px; border-radius: 2px; background: var(--lima); }
.trozo b { color: var(--neon); font-size: 11px; }
.trozo button { background: rgba(255,255,255,.09); border: 0; border-radius: 7px; color: var(--papel);
  font: inherit; font-size: 12px; width: 22px; height: 22px; line-height: 1; }
.trozo button:hover:not(:disabled) { background: var(--neon); color: #06121a; }
.trozo button:disabled { opacity: .28; }
.trozo .quita:hover { background: #ff5d6c; color: #fff; }

.talCols { display: flex; flex-wrap: wrap; gap: 14px; align-items: stretch; justify-content: center; width: 100%; }
#talMapa { width: 260px; height: 260px; background: rgba(0,0,0,.28); border: 1px solid rgba(255,255,255,.12); border-radius: 14px; }
.talDatos { flex: 1; min-width: 190px; display: flex; flex-direction: column; gap: 5px; justify-content: center; }
.dato { display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
  background: rgba(255,255,255,.05); border-radius: 9px; padding: 8px 13px; font-weight: 700; font-size: 13px; }
.dato span { color: #96a0c0; }
.dato b { font-size: 15px; }
.dato.oro b { color: var(--oro); } .dato.plata b { color: var(--plata); } .dato.bronce b { color: var(--bronce); }

/* el código: es el producto del taller, así que se ve como tal */
.codigo { font-weight: 900; font-size: clamp(22px, 5vw, 34px); letter-spacing: .22em; font-style: italic;
  color: var(--lima); text-shadow: 0 0 22px rgba(182,255,61,.35); word-break: break-all; }
#talEntrada { font: inherit; font-weight: 900; font-size: 24px; letter-spacing: .18em; text-align: center;
  text-transform: uppercase; background: rgba(0,0,0,.34); border: 2px solid rgba(255,255,255,.2);
  border-radius: 12px; color: var(--lima); padding: 10px 14px; outline: none; width: min(340px, 100%); }
#talEntrada:focus { border-color: var(--lima); }
#talLista .filaRec { cursor: pointer; }
#talLista .filaRec:hover { background: rgba(56,225,255,.14); }
/* mis circuitos: código, mundo, tiempo y cómo le va en la comunidad (o el botón de publicarlo) */
#talLista { width: min(560px, 100%); }
.filaRec.filaMia { grid-template-columns: auto 1fr auto auto; text-align: left; }
#talLista .filaMia b { letter-spacing: .08em; color: #cfd6ee; }   /* no es una tabla: sin oro, plata ni bronce */
.miaEstado { font-size: 13px; font-weight: 800; color: var(--neon); white-space: nowrap; min-width: 70px; text-align: right; }
.miaEstado.falta { color: #8b95b6; font-weight: 600; font-size: 11px; white-space: normal; max-width: 130px; }
.miaEstado .btn { padding: 5px 12px; }

/* ---------------------------------------------------------- comunidad */
.comCab { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; width: 100%; }
.tabs.chicas { width: auto; margin: 0; justify-content: flex-start; }
.btn.lima { border-color: var(--lima); color: var(--lima); }
.comLista { width: 100%; display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 9px; }
/* una tarjeta por circuito: el plano a la izquierda (se ve de un vistazo si es una recta o un lío),
   los datos a la derecha, y el color del mundo en el borde */
.comTar { display: grid; grid-template-columns: 124px 1fr; gap: 11px; align-items: center; text-align: left;
  background: rgba(255,255,255,.06); border: 2px solid rgba(255,255,255,.1); border-left: 5px solid var(--c);
  border-radius: 13px; padding: 8px 11px 8px 8px; font: inherit; color: var(--papel); cursor: pointer;
  transition: transform .1s, border-color .16s; }
.comTar:hover { border-color: var(--neon); border-left-color: var(--c); transform: translateY(-2px); }
.comPlano { width: 124px; height: 78px; border-radius: 9px; background: rgba(0,0,0,.3); display: block; }
.comDatos { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.comMundo { font-size: 14px; font-weight: 900; display: flex; align-items: center; gap: 6px; }
.comChapa { font-style: normal; font-size: 9px; font-weight: 900; letter-spacing: .1em; padding: 2px 6px;
  border-radius: 6px; background: var(--lima); color: #12200a; }
.comChapa.of { background: var(--neon); color: #06121a; }
.comSecs { font-size: 11px; color: #96a0c0; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.comAutor { font-size: 12px; font-weight: 700; color: #cfd6ee; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.comAutor.mio { color: var(--lima); }
.comNums { display: flex; align-items: center; gap: 10px; font-size: 12px; font-weight: 800; margin-top: 2px; }
.comNums i { font-style: normal; font-variant-numeric: tabular-nums; }
.comNums .gusta { color: #ff8fa3; }
.comNums .gusta.on { color: #ff4f73; }
.comDif { display: flex; gap: 2px; margin-left: auto; }
.comDif i { width: 5px; height: 9px; border-radius: 2px; background: rgba(255,255,255,.14); }
.comDif i.on { background: var(--c); }
.comMejor { display: flex; align-items: center; gap: 5px; font-size: 11px; font-weight: 700; color: var(--lima); }
.comMed { width: 9px; height: 9px; border-radius: 50%; background: rgba(255,255,255,.2); }
.comMed.m1 { background: var(--bronce); } .comMed.m2 { background: var(--plata); }
.comMed.m3 { background: var(--oro); } .comMed.m4 { background: var(--diamante); }
#comNota { text-align: center; line-height: 1.5; }
#comNota .btn { margin-top: 8px; }

/* en la pantalla de resultado: de quién es el circuito, el me gusta, o publicarlo */
.finCom { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 6px 0 2px; }
.fcAutor { font-size: 13px; font-weight: 700; color: #cfd6ee; }
.fcAutor b { color: var(--papel); }
.fcGusta.on { background: #ff4f73; border-color: #ff4f73; color: #fff; }
.fcReporta { opacity: .7; }
.fcPublica { border-color: var(--lima); }
.fcPublica span { color: var(--lima); }

/* ---------------------------------------------------------- récords */
#records { background: radial-gradient(120% 90% at 50% 0%, #2a2150 0%, #12101c 62%), var(--tinta); justify-content: flex-start; }
#recLista { width: min(460px, 100%); gap: 3px; }
.filaRec { display: grid; grid-template-columns: 42px 1fr auto; align-items: center; gap: 10px;
  background: rgba(255,255,255,.05); border-radius: 10px; padding: 8px 14px; font-weight: 700; font-size: 14px; }
.filaRec b { color: #8b95b6; font-size: 13px; }
.filaRec i { font-style: normal; font-variant-numeric: tabular-nums; }
.filaRec.yo { background: rgba(56,225,255,.16); border: 1px solid rgba(56,225,255,.4); }
.filaRec:nth-child(1) b { color: var(--oro); } .filaRec:nth-child(2) b { color: var(--plata); }
.filaRec:nth-child(3) b { color: var(--bronce); }
.finMundial { font-weight: 800; font-size: 14px; color: var(--neon); min-height: 18px; }
.finMundial.record { color: var(--lima); font-size: 17px; font-weight: 900; font-style: italic; }
#ajNombre { flex: 1; min-width: 0; font: inherit; font-weight: 800; font-size: 14px; text-align: center; background: rgba(0,0,0,.3);
  border: 1px solid rgba(255,255,255,.2); border-radius: 9px; color: var(--papel); padding: 5px 8px; outline: none; }
#ajNombre:focus { border-color: var(--neon); }
.etiJugador { position: absolute; display: none; transform: translate(-50%,-50%); white-space: nowrap; text-align: center;
  font-size: 12px; font-weight: 800; color: #fff; text-shadow: 0 2px 6px rgba(0,0,0,.9); pointer-events: none; line-height: 1.2; }
/* el título, encima del nombre y en pequeño y dorado: pegado al nombre parecía parte de él (sexta revisión) */
.etiJugador i { display: block; font-style: normal; font-size: 9.5px; font-weight: 900; letter-spacing: .14em;
  text-transform: uppercase; color: var(--oro); margin-bottom: 1px; }
#hFantasma.rival { color: var(--oro); }

/* ---------------------------------------------------------- lobby */
#barraLobby { position: absolute; top: calc(var(--st) + 12px); left: calc(var(--sl) + 14px); right: calc(var(--sr) + 14px);
  display: none; align-items: center; gap: 8px; pointer-events: none; }
#barraLobby.ver { display: flex; }
#barraLobby .hueco { flex: 1; }
#barraLobby .btn { pointer-events: auto; margin: 0; background: rgba(10,8,20,.55); border-color: rgba(255,255,255,.2); }
#barraLobby .chip { background: rgba(10,8,20,.55); flex-shrink: 0; }
/* el nombre de la cuenta es lo único que puede encogerse: la barra cabe hasta en 568 px */
#barraLobby .chip.perfil { flex-shrink: 1; min-width: 0; }
@media (max-width: 700px) { #barraLobby .chip.perfil b { max-width: 84px; } }

/* El boton de jugar: abajo y en medio, que es donde se mira. En la plaza sustituye al velocimetro,
   que ahi no dice nada porque se va andando. */
#btnPlay { position: absolute; left: 50%; bottom: calc(var(--sb) + 26px); transform: translateX(-50%) scale(.94);
  display: none; flex-direction: column; align-items: center; gap: 1px; pointer-events: auto;
  padding: 15px 52px; border-radius: 18px; border: 0; cursor: pointer;
  background: linear-gradient(100deg, var(--neon), #8df3ff); color: #06121a;
  font-weight: 900; font-style: italic; font-size: clamp(19px, 3vw, 27px); letter-spacing: .14em;
  box-shadow: 0 12px 38px rgba(56,225,255,.42); transition: transform .12s, box-shadow .12s; }
/* por encima de #tactil, que cubre la pantalla entera para mirar y va despues en el DOM: sin esto
   el dedo (o el raton) atraviesa el boton y se lo come el juego */
#btnPlay { z-index: 5; }
/* Animacion propia y no la de la portada: `latir` redefine `transform` entero, y al hacerlo se
   lleva por delante el translateX(-50%) que centra el boton. Se iba justo media anchura a la
   derecha. Cualquier cosa centrada con translate necesita sus propios keyframes. */
body.enLobby #btnPlay { display: flex; animation: latirPlay 1.9s ease-in-out infinite; }
@keyframes latirPlay {
  0%, 100% { transform: translateX(-50%) scale(1); }
  50% { transform: translateX(-50%) scale(1.045); }
}
/* en tactil solo se estrecha: los mandos van a las esquinas y el centro de abajo queda libre */
body.tactil #btnPlay { padding: 12px 40px; }
#btnPlay:hover { box-shadow: 0 14px 46px rgba(56,225,255,.6); }
#btnPlay small { font-size: 10.5px; font-style: normal; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; opacity: .72; }
body.enLobby #hVel { opacity: 0; }
body.tour #btnPlay, body.portada #btnPlay { display: none; }
@media (max-height: 520px) { #btnPlay { bottom: calc(var(--sb) + 10px); padding: 10px 34px; } }
#barraLobby .btn span { white-space: nowrap; }
/* en pantallas cortas la barra se comía dos líneas y pisaba los rótulos del mundo */
@media (max-width: 900px), (max-height: 520px) {
  #barraLobby { gap: 5px; top: calc(var(--st) + 8px); }
  #barraLobby .btn { min-width: 0; padding: 7px 10px; font-size: 12px; }
  #barraLobby .chip { padding: 5px 9px; font-size: 12px; }
}

#portales { position: absolute; inset: 0; pointer-events: none; }
/* ---------------------------------------------------------- Carrera de fantasmas */
#carreraEtis { position: absolute; inset: 0; pointer-events: none; }
.etiJugador.etiCarrera { border: 2px solid; }
#carreraTabla { position: absolute; left: calc(var(--sl) + 12px); top: 50%; transform: translateY(-50%);
  display: none; flex-direction: column; gap: 3px; pointer-events: none; min-width: 150px; }
body.enCarrera #hud.jugando #carreraTabla { display: flex; }
/* en carrera los rivales son los fantasmas: fuera el cartel de «persiguiendo tu récord» */
body.enCarrera #hFantasma { display: none; }
.ctPuesto { font-size: 22px; font-weight: 900; font-style: italic; color: #fff; text-shadow: 0 2px 8px rgba(0,0,0,.6); margin-bottom: 4px; }
.ctFila { display: flex; align-items: center; gap: 6px; padding: 3px 10px 3px 6px; border-radius: 9px;
  background: rgba(10,8,20,.55); font-size: 12.5px; font-weight: 800; color: #dfe5f7; white-space: nowrap; }
.ctFila i { font-style: normal; width: 14px; text-align: center; color: #9aa4c8; }
.ctFila em { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; }
.ctFila.yo { background: rgba(56,225,255,.32); color: #fff; }
@media (max-height: 420px) { #carreraTabla { min-width: 0; } .ctPuesto { font-size: 17px; } .ctFila { font-size: 11px; padding: 2px 8px 2px 5px; } }
/* en el móvil la mitad izquierda es para andar: la clasificación, arriba y estrecha */
body.tactil #carreraTabla { top: calc(var(--st) + 54px); transform: none; }
.finCarrera { font-size: 16px; font-weight: 900; color: var(--neon); margin-top: 4px; }
.finCarrera:empty { display: none; }
.finCarrera.gana { color: var(--oro); }
.tarjetaNivel.carreraModo.on { border-color: var(--neon); box-shadow: 0 0 0 3px rgba(56,225,255,.35); }
#listaNiveles.eligeCarrera .rejilla:not(.modos) .tarjetaNivel:not(.cerrado) { border-color: var(--neon); }
.etiPortal { position: absolute; display: none; transform-origin: 50% 50%; text-align: center; white-space: nowrap;
  background: rgba(10,8,20,.62); border: 1px solid rgba(255,255,255,.16); border-radius: 12px; padding: 6px 14px;
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.etiPortal b { display: block; font-size: 14px; font-weight: 900; letter-spacing: .02em; }
.etiPortal span { display: block; font-size: 12px; font-weight: 700; color: #b9c2e0; font-variant-numeric: tabular-nums; }
.etiPortal i { display: inline-block; width: 11px; height: 11px; border-radius: 50%; margin-top: 3px; }
.etiPortal.cerrado { opacity: .6; }
.etiPortal.puesto { border-color: rgba(47,212,208,.5); }
.etiMundo { position: absolute; display: none; white-space: nowrap; text-align: center; pointer-events: none;
  transform-origin: 50% 50%; }
.etiMundo b { font-size: 19px; font-weight: 900; font-style: italic; letter-spacing: .16em; text-transform: uppercase;
  color: #fff; text-shadow: 0 3px 16px rgba(0,0,0,.85), 0 0 30px rgba(0,0,0,.5); }
.etiPortal.puesto b { color: var(--neon); }

#avisoPortal { position: absolute; left: 50%; top: 63%; transform: translateX(-50%); --c: 0;
  opacity: 0; transition: opacity .18s; font-weight: 800; font-size: clamp(14px, 2.3vw, 18px);
  background: rgba(10,8,20,.7); border-radius: 22px; padding: 9px 22px; overflow: hidden; }
#avisoPortal.ver { opacity: 1; }
#avisoPortal::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0;
  width: calc(var(--c) * 100%); background: rgba(47,212,208,.35); transition: width .06s linear; }

/* cuenta atrás de salida */
.cuenta { position: absolute; left: 50%; top: 44%; transform: translate(-50%, -50%) scale(.6); opacity: 0;
  font-size: clamp(64px, 14vw, 150px); font-weight: 900; font-style: italic; line-height: 1;
  letter-spacing: -.03em; color: #fff; text-shadow: 0 6px 40px rgba(0,0,0,.6); pointer-events: none; }
.cuenta.ver { animation: cuentaPop .95s ease-out forwards; }
.cuenta.ver.ya { color: var(--lima); animation: cuentaYa .8s ease-out forwards; }
@keyframes cuentaPop {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(1.5); }
  18% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  75% { opacity: .95; transform: translate(-50%, -50%) scale(.96); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(.9); }
}
@keyframes cuentaYa {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.7); }
  15% { opacity: 1; transform: translate(-50%, -50%) scale(1.15); }
  60% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(1.3); }
}

/* entrenamiento: ARRIBA y estrecho. Iba abajo en el centro, y en un movil apaisado eso es el
   centro de la pantalla: tapaba justo la plataforma donde vas a caer. Un jugador lo dijo con estas
   palabras, «blocks my view». Arriba solo hay cielo, y durante el entrenamiento el cronometro no se
   ensena, asi que el sitio esta libre. No recoge toques (pasan a la zona de mirar), salvo su boton. */
#tutorial { position: absolute; left: 50%; top: calc(var(--st) + 12px); transform: translateX(-50%) translateY(-8px);
  max-width: min(520px, 64vw); box-sizing: border-box; opacity: 0; transition: opacity .25s, transform .25s;
  background: rgba(10,8,20,.66); border: 2px solid rgba(255,255,255,.16); border-radius: 14px;
  padding: 7px 14px; text-align: center; font-size: clamp(12px, 1.8vw, 15px); font-weight: 700; line-height: 1.4;
  backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); z-index: 5; pointer-events: none; }
#tutorial.ver { opacity: 1; transform: translateX(-50%) translateY(0); }
/* La diana del entrenamiento: un anillo que late sobre el bloque al que engancharse. Se coloca con
   left/top y late con `scale`, que no pisa su posición (con `transform` se iba a la esquina) */
#tutoDiana { position: absolute; left: 50%; top: 50%; width: 70px; height: 70px; margin: -35px 0 0 -35px;
  border-radius: 50%; border: 4px solid var(--lima); pointer-events: none; opacity: 0; transition: opacity .2s;
  box-shadow: 0 0 22px rgba(182,255,61,.75), inset 0 0 14px rgba(182,255,61,.5); }
#tutoDiana.ver { opacity: 1; animation: dianaLate 1s ease-in-out infinite; }
@keyframes dianaLate { 0%, 100% { scale: 1; } 50% { scale: 1.3; } }
/* en la plaza con el ratón capturado: cómo se suelta para usar la barra */
#pistaEsc { display: none; position: absolute; top: calc(var(--st) + 60px); left: 50%; transform: translateX(-50%);
  font-size: 12px; font-weight: 800; letter-spacing: .04em; color: #dfe5f7; background: rgba(10,8,20,.62);
  border: 1px solid rgba(255,255,255,.18); border-radius: 999px; padding: 5px 13px; pointer-events: none; white-space: nowrap; }
body.capturado.enLobby #pistaEsc { display: block; }
body.tactil #pistaEsc, body.tour #pistaEsc { display: none !important; }
/* en el aire se aparta: a mitad de columpio lo que importa es ver, y la instruccion ya se leyo */
#tutorial.ver.enAire { opacity: .28; }
#tutorial b { color: var(--neon); font-weight: 900; }
#tutorial.listo { border-color: var(--lima); background: rgba(30,50,10,.72); }
/* el visto bueno va en la misma linea: antes anadia una linea entera y el cartel crecia de golpe */
#tutorial.listo #tutoTexto::after { content: ' \2713'; color: var(--lima); font-weight: 900; }
/* solo se pulsa con el cartel a la vista: escondido seguía tapando la mitad de mirar del móvil */
#tutorial:not(.ver) #tutoSaltar { pointer-events: none; }
#tutoSaltar { pointer-events: auto; margin-left: 10px; padding: 3px 9px; border-radius: 8px; font-size: .82em;
  font-weight: 700; color: rgba(255,255,255,.62); border: 1px solid rgba(255,255,255,.22); vertical-align: 1px; }
/* con raton el puntero esta capturado y no hay cursor para pulsarlo: ahi se salta desde la pausa */
body:not(.tactil) #tutoSaltar { display: none; }

/* El entrenamiento SENALA el boton que toca en vez de describirlo: un anillo que late alrededor. Va
   con box-shadow y no con transform, que los botones ya usan para colocarse. */
@keyframes tutoPulso { 0%, 100% { box-shadow: 0 0 0 0 rgba(182,255,61,.6); } 60% { box-shadow: 0 0 0 16px rgba(182,255,61,0); } }
body.tactil[data-tuto="salta"] .tbtn.salta,
body.tactil[data-tuto="gancho"] .tbtn.gancho,
body.tactil[data-tuto="tira"] .tbtn.tira,
body.tactil[data-tuto="subir"] .tbtn.gancho { border-color: var(--lima); animation: tutoPulso 1.15s ease-out infinite; }
body.tactil[data-tuto="subir"] .tbtn.gancho::before { color: var(--lima); animation: flechaSube .9s ease-in-out infinite; }
/* y en el primer paso, donde esta el joystick: la mitad izquierda no se ve hasta que la tocas */
#tutoStick { position: absolute; left: calc(var(--sl) + 58px); bottom: calc(var(--sb) + 96px); width: 90px; height: 90px;
  border-radius: 50%; border: 2px dashed rgba(182,255,61,.75); display: none; pointer-events: none;
  animation: tutoPulso 1.15s ease-out infinite; }
#tutoStick i { position: absolute; left: 50%; top: 50%; width: 40px; height: 40px; margin: -20px 0 0 -20px;
  border-radius: 50%; background: rgba(182,255,61,.35); }
body.tactil[data-tuto="stick"] #hud.jugando #tutoStick { display: block; }

/* ---------------------------------------------------------- recorrido de bienvenida */
/* La tarjeta que acompaña a la cámara de kiosco en kiosco. Va abajo y estrecha: lo que importa es
   el kiosco que se está viendo, no el texto. */
#tour { position: absolute; left: 50%; bottom: calc(var(--sb) + 26px); transform: translateX(-50%) translateY(14px);
  width: min(520px, 90vw); box-sizing: border-box; opacity: 0; pointer-events: none;
  transition: opacity .28s ease, transform .28s ease;
  background: rgba(10,8,20,.82); border: 2px solid rgba(56,225,255,.35); border-radius: 18px;
  padding: 16px 22px 14px; text-align: center;
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  box-shadow: 0 18px 48px rgba(0,0,0,.45); }
#tour.ver { opacity: 1; transform: translateX(-50%) translateY(0); pointer-events: auto; }
/* durante el recorrido la pantalla es del kiosco, no del interfaz de partida */
body.tour #mira, body.tour #hVel, body.tour #hPunto { opacity: 0; }
/* en táctil los mandos en pantalla taparían la tarjeta, y además durante el recorrido no valen
   para nada porque la entrada está apagada */
body.tour #tactil, body.tour #btnPausa { display: none !important; }
body.tactil #tour { bottom: calc(var(--sb) + 14px); }
#mira, #hVel, #hPunto { transition: opacity .3s ease; }
#tour i { display: block; font-style: normal; font-size: 11px; font-weight: 800; letter-spacing: .2em;
  color: var(--neon); margin-bottom: 4px; }
#tour b { display: block; font-size: clamp(17px, 2.6vw, 22px); font-weight: 900; font-style: italic;
  letter-spacing: .01em; margin-bottom: 6px; }
#tour span { display: block; font-size: clamp(12px, 1.9vw, 14.5px); font-weight: 600; line-height: 1.5;
  color: #c3cbe6; }
.tourPie { display: flex; flex-direction: column; align-items: center; gap: 4px; margin-top: 13px; }
.tourPie .btn { margin: 0; min-width: 190px; }
.enlace { pointer-events: auto; background: none; border: 0; padding: 6px 10px; font-size: 12px;
  font-weight: 700; color: #7c86a8; letter-spacing: .04em; text-decoration: underline; }
.enlace:hover { color: #b9c2e0; }
#tour:not(.ver) .enlace { pointer-events: none; }
/* En pantallas bajas (un móvil en horizontal) una tarjeta centrada abajo se come el kiosco, que es
   justo lo que hay que mirar. Ahí se va al costado. */
@media (max-height: 560px) {
  /* debajo de la barra de arriba (Tienda, Diarias, Récords, Ajustes): pegada a ella la tapaba
     (revisión de CrazyGames de la v72) */
  #tour, body.tactil #tour { left: auto; right: calc(var(--sr) + 14px); top: calc(var(--st) + 60px); bottom: auto; width: min(330px, 44vw);
    max-height: calc(100% - var(--st) - var(--sb) - 72px); overflow-y: auto;
    text-align: left; padding: 12px 16px 11px; transform: translateX(16px); }
  #tour.ver, body.tactil #tour.ver { transform: translateX(0); }
  #tour span { line-height: 1.38; }
  .tourPie { flex-direction: row; align-items: center; margin-top: 9px; }
  .tourPie .btn { min-width: 0; flex: 1; }
}
@media (max-height: 400px) {
  #tour { padding: 9px 13px 8px; }
  #tour i { margin-bottom: 2px; }
  #tour b { font-size: 15px; margin-bottom: 3px; }
  #tour span { font-size: 12px; line-height: 1.3; }
  .tourPie { margin-top: 6px; }
  .tourPie .btn { padding: 7px 12px; font-size: 13px; }
}

/* mira */
.mira { position: absolute; left: 50%; top: 50%; width: 26px; height: 26px; margin: -13px 0 0 -13px; }
.mira i { position: absolute; background: rgba(255,255,255,.85); box-shadow: 0 0 4px rgba(0,0,0,.7); transition: all .12s; }
.mira i:nth-child(1), .mira i:nth-child(2) { width: 2px; height: 7px; left: 12px; }
.mira i:nth-child(1) { top: 0; } .mira i:nth-child(2) { bottom: 0; }
.mira i:nth-child(3), .mira i:nth-child(4) { height: 2px; width: 7px; top: 12px; }
.mira i:nth-child(3) { left: 0; } .mira i:nth-child(4) { right: 0; }
.mira b { position: absolute; left: 11px; top: 11px; width: 4px; height: 4px; border-radius: 50%; background: #fff; box-shadow: 0 0 5px rgba(0,0,0,.8); }
.mira.listo i { background: var(--lima); }
.mira.listo i:nth-child(1) { top: -3px; } .mira.listo i:nth-child(2) { bottom: -3px; }
.mira.listo i:nth-child(3) { left: -3px; } .mira.listo i:nth-child(4) { right: -3px; }
.mira.listo b { background: var(--lima); box-shadow: 0 0 10px var(--lima); }
.mira.lejos i { background: rgba(255,77,94,.9); }
.mira.lejos b { background: var(--rojo); box-shadow: 0 0 6px rgba(255,77,94,.8); }
.mira.pegado i { background: var(--neon); opacity: .5; }
.mira.pegado b { background: var(--neon); box-shadow: 0 0 12px var(--neon); }

/* Miras de la tienda. Todas heredan el color de estado (verde llega / rojo no llega / azul pegado),
   así que cambiar de mira nunca te quita la información: solo cambia la forma. */
.mira[data-m="m_punto"] i { opacity: 0; }
.mira[data-m="m_punto"] b { left: 9px; top: 9px; width: 8px; height: 8px; }

.mira[data-m="m_anillo"] i:nth-child(1), .mira[data-m="m_anillo"] i:nth-child(2) { opacity: 0; }
.mira[data-m="m_anillo"] i:nth-child(3) { left: 3px; top: 3px; width: 20px; height: 20px;
  background: transparent; border: 2px solid rgba(255,255,255,.85); border-radius: 50%; box-shadow: none; }
.mira[data-m="m_anillo"] i:nth-child(4) { opacity: 0; }
.mira[data-m="m_anillo"].listo i:nth-child(3) { border-color: var(--lima); left: 1px; top: 1px; width: 24px; height: 24px; }
.mira[data-m="m_anillo"].lejos i:nth-child(3) { border-color: rgba(255,77,94,.9); }
.mira[data-m="m_anillo"].pegado i:nth-child(3) { border-color: var(--neon); }

.mira[data-m="m_uve"] i:nth-child(2), .mira[data-m="m_uve"] i:nth-child(4) { opacity: 0; }
.mira[data-m="m_uve"] i:nth-child(1) { width: 2px; height: 11px; left: 7px; top: 9px; transform: rotate(-38deg); }
.mira[data-m="m_uve"] i:nth-child(3) { width: 2px; height: 11px; left: 17px; top: 9px; transform: rotate(38deg); }
.mira[data-m="m_uve"] b { top: 4px; }
.mira[data-m="m_uve"].listo i:nth-child(1) { top: 6px; } .mira[data-m="m_uve"].listo i:nth-child(3) { top: 6px; }

.mira[data-m="m_rombo"] i { width: 2px; height: 9px; }
.mira[data-m="m_rombo"] i:nth-child(1) { left: 7px; top: 4px; transform: rotate(45deg); }
.mira[data-m="m_rombo"] i:nth-child(2) { left: 17px; top: 4px; bottom: auto; transform: rotate(-45deg); }
.mira[data-m="m_rombo"] i:nth-child(3) { left: 7px; top: 13px; width: 2px; transform: rotate(-45deg); }
.mira[data-m="m_rombo"] i:nth-child(4) { left: 17px; top: 13px; right: auto; width: 2px; transform: rotate(45deg); }
.mira[data-m="m_rombo"] b { opacity: 0; }

.mira[data-m="m_diana"] i:nth-child(1) { left: 3px; top: 3px; width: 20px; height: 20px;
  background: transparent; border: 2px solid rgba(255,255,255,.5); border-radius: 50%; box-shadow: none; }
.mira[data-m="m_diana"] i:nth-child(2) { left: 8px; top: 8px; bottom: auto; width: 10px; height: 10px;
  background: transparent; border: 2px solid rgba(255,255,255,.85); border-radius: 50%; box-shadow: none; }
.mira[data-m="m_diana"] i:nth-child(3), .mira[data-m="m_diana"] i:nth-child(4) { opacity: 0; }
.mira[data-m="m_diana"] b { left: 11.5px; top: 11.5px; width: 3px; height: 3px; }
.mira[data-m="m_diana"].listo i:nth-child(1) { border-color: rgba(182,255,61,.55); }
.mira[data-m="m_diana"].listo i:nth-child(2) { border-color: var(--lima); }
.mira[data-m="m_diana"].lejos i:nth-child(1) { border-color: rgba(255,77,94,.5); }
.mira[data-m="m_diana"].lejos i:nth-child(2) { border-color: rgba(255,77,94,.9); }
.mira[data-m="m_diana"].pegado i:nth-child(1), .mira[data-m="m_diana"].pegado i:nth-child(2) { border-color: var(--neon); }

/* cruz abierta: los cuatro brazos separados y sin punto en medio */
.mira[data-m="m_hueca"] i:nth-child(1) { top: -4px; } .mira[data-m="m_hueca"] i:nth-child(2) { bottom: -4px; }
.mira[data-m="m_hueca"] i:nth-child(3) { left: -4px; } .mira[data-m="m_hueca"] i:nth-child(4) { right: -4px; }
.mira[data-m="m_hueca"] b { opacity: 0; }
.mira[data-m="m_hueca"].listo i:nth-child(1) { top: -7px; } .mira[data-m="m_hueca"].listo i:nth-child(2) { bottom: -7px; }
.mira[data-m="m_hueca"].listo i:nth-child(3) { left: -7px; } .mira[data-m="m_hueca"].listo i:nth-child(4) { right: -7px; }

/* equis: los mismos cuatro brazos, girados 45 grados */
.mira[data-m="m_equis"] i { width: 2px; height: 9px; }
.mira[data-m="m_equis"] i:nth-child(1) { left: 5px; top: 1px; transform: rotate(45deg); }
.mira[data-m="m_equis"] i:nth-child(2) { left: 19px; top: 1px; bottom: auto; transform: rotate(-45deg); }
.mira[data-m="m_equis"] i:nth-child(3) { left: 5px; top: 16px; width: 2px; transform: rotate(-45deg); }
.mira[data-m="m_equis"] i:nth-child(4) { left: 19px; top: 16px; right: auto; width: 2px; transform: rotate(45deg); }
.mira[data-m="m_equis"] b { left: 11.5px; top: 11.5px; width: 3px; height: 3px; }

/* trípode: arriba y a los lados, nada debajo. Deja el suelo despejado al mirar hacia abajo */
.mira[data-m="m_triple"] i:nth-child(2) { opacity: 0; }
.mira[data-m="m_triple"] i:nth-child(1) { top: -2px; height: 9px; }
.mira[data-m="m_triple"] i:nth-child(3) { left: -2px; width: 9px; } .mira[data-m="m_triple"] i:nth-child(4) { right: -2px; width: 9px; }

/* corchetes: dos barras a los lados, como los de un menú */
.mira[data-m="m_corchetes"] i:nth-child(1), .mira[data-m="m_corchetes"] i:nth-child(2) { opacity: 0; }
.mira[data-m="m_corchetes"] i:nth-child(3) { left: 2px; top: 7px; width: 3px; height: 12px; }
.mira[data-m="m_corchetes"] i:nth-child(4) { right: 2px; top: 7px; width: 3px; height: 12px; }
.mira[data-m="m_corchetes"].listo i:nth-child(3) { left: -2px; } .mira[data-m="m_corchetes"].listo i:nth-child(4) { right: -2px; }

/* estrella: cuatro púas en diagonal y el punto en medio */
.mira[data-m="m_estrella"] i { width: 2px; height: 7px; }
.mira[data-m="m_estrella"] i:nth-child(1) { left: 6px; top: 2px; transform: rotate(45deg); }
.mira[data-m="m_estrella"] i:nth-child(2) { left: 18px; top: 2px; bottom: auto; transform: rotate(-45deg); }
.mira[data-m="m_estrella"] i:nth-child(3) { left: 6px; top: 17px; width: 2px; transform: rotate(-45deg); }
.mira[data-m="m_estrella"] i:nth-child(4) { left: 18px; top: 17px; right: auto; width: 2px; transform: rotate(45deg); }
.mira[data-m="m_estrella"] b { left: 10px; top: 10px; width: 6px; height: 6px; }

/* lente: círculo con una línea horizontal, como la retícula de un visor */
.mira[data-m="m_lente"] i:nth-child(1) { left: 2px; top: 2px; width: 22px; height: 22px;
  background: transparent; border: 2px solid rgba(255,255,255,.85); border-radius: 50%; box-shadow: none; }
.mira[data-m="m_lente"] i:nth-child(2) { left: 0; top: 12px; bottom: auto; width: 9px; height: 2px; }
.mira[data-m="m_lente"] i:nth-child(3) { left: auto; right: 0; top: 12px; width: 9px; height: 2px; }
.mira[data-m="m_lente"] i:nth-child(4) { opacity: 0; }
.mira[data-m="m_lente"] b { left: 11.5px; top: 11.5px; width: 3px; height: 3px; }
.mira[data-m="m_lente"].listo i:nth-child(1) { border-color: var(--lima); }
.mira[data-m="m_lente"].lejos i:nth-child(1) { border-color: rgba(255,77,94,.9); }
.mira[data-m="m_lente"].pegado i:nth-child(1) { border-color: var(--neon); }

/* la muestra de la cuerda en la tienda: grosor y núcleo de verdad */
.muestra.cuerda { height: 34px; display: flex; align-items: center; justify-content: center; position: relative; }
.muestra.cuerda::before { content: ''; position: absolute; left: 0; right: 0; height: var(--h);
  border-radius: 999px; background: var(--a); box-shadow: var(--g); }
.muestra.cuerda em { position: relative; z-index: 1; display: block; width: 100%;
  height: calc(var(--h) * .42); border-radius: 999px; background: var(--b); }
#hDash { position: absolute; left: 50%; top: 50%; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.14); opacity: .45; transition: border-color .2s, opacity .2s; }
#hDash.listo { border-color: rgba(182,255,61,.55); opacity: .8; }

#tinte { position: absolute; inset: 0; mix-blend-mode: soft-light; }
#velo { position: absolute; inset: 0; opacity: 0; transition: opacity .14s;
  background: radial-gradient(58% 58% at 50% 50%, transparent 40%, rgba(10,6,26,.92) 100%); }
#flash { position: absolute; inset: 0; opacity: 0; transition: opacity .25s; }

/* ---------------------------------------------------------- resultado */
.tarjeta { width: min(520px, 100%); background: rgba(20,17,36,.9); border: 2px solid rgba(255,255,255,.12); border-radius: 20px;
  padding: 20px 18px; display: flex; flex-direction: column; align-items: center; gap: 6px; margin-top: 4vh; }
.finTitulo { font-size: clamp(20px, 4vw, 30px); font-weight: 900; font-style: italic; letter-spacing: .02em; margin: 0; }
.finTitulo.record { color: var(--lima); text-shadow: 0 0 24px rgba(182,255,61,.5); }
#finNivel { font-size: 13px; color: #96a0c0; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; overflow-wrap: anywhere; max-width: 100%; }
#finTiempo { font-size: clamp(44px, 9vw, 78px); font-weight: 900; font-style: italic; line-height: 1; font-variant-numeric: tabular-nums; }
.finMedalla { font-weight: 900; font-size: 15px; letter-spacing: .08em; }
.finMedalla.m1 { color: var(--bronce); } .finMedalla.m2 { color: var(--plata); }
.finMedalla.m3 { color: var(--oro); } .finMedalla.m4 { color: var(--diamante); }
#finSub, #finFalta { font-size: 13px; color: #b3bcd8; font-weight: 700; }
#finMonedas { color: var(--oro); font-weight: 900; font-size: 15px; }
#finPrestado { color: var(--lima); font-weight: 800; font-size: 13px; }
#finSplits { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center; margin: 6px 0; }
/* el resultado en dos partes (ver index.html): de normal una encima de otra */
.finInfo, .finAcciones { display: flex; flex-direction: column; align-items: center; gap: 6px; width: 100%; }
/* bajo y ancho: lado a lado. Con 720 de alto ya no cabía una encima de otra */
@media (max-height: 760px) and (min-width: 700px) {
  #fin { justify-content: safe center; }
  .finTarjeta { flex-direction: row; align-items: center; width: min(900px, 100%); box-sizing: border-box; gap: 24px; margin-top: 0; }
  .finInfo { flex: 1.15; min-width: 0; }
  .finAcciones { flex: 1; min-width: 0; }
}
/* y en lo más bajo, más apretado: la medalla más pequeña y fuera los parciales, que son lo único
   prescindible (el tiempo y la medalla también se dicen con palabras) */
@media (max-height: 560px) {
  .finTarjeta { padding: 12px 16px; }
  .finInfo, .finAcciones { gap: 3px; }
  .finTarjeta .emblema { width: 54px; height: 54px; margin: 2px auto; }
  .finTarjeta .emblema::after { inset: 9px; }
  .finTarjeta .emblema b { font-size: 20px; }
  .finTarjeta .emblema i { inset: -8px; }
  #finTiempo { font-size: 42px; }
  .finTitulo { font-size: 21px; }
  #finSplits { display: none; }
  .finTarjeta .btn.grande { padding: 11px 36px; }
}
@media (max-height: 420px) { .finTarjeta #finEmblema { display: none; } }

/* ---------------------------------------------------------- controles a la vista (hud.panelCtrl) */
/* Abajo a la derecha y siempre a la vista con ratón (revisión de CrazyGames): cada acción con su tecla
   dibujada. En táctil no, que ahí los botones ya lo dicen; y fuera del recorrido y de la portada. */
#panelCtrl { position: absolute; right: calc(var(--sr) + 14px); bottom: calc(var(--sb) + 14px);
  display: flex; flex-direction: column; align-items: flex-end; gap: 4px; pointer-events: none;
  padding: 7px 9px; border-radius: 11px; background: rgba(10,8,20,.34);
  font-size: 12px; font-weight: 800; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.9); }
#panelCtrl:empty { display: none; }
.pcFila { display: flex; align-items: center; gap: 8px; }
.pcFila b { display: flex; align-items: center; gap: 3px; }
.pcFila i { font-style: normal; font-size: 10px; opacity: .65; }
#panelCtrl kbd { display: inline-flex; align-items: center; justify-content: center; min-width: 9px; height: 17px;
  padding: 0 5px; border-radius: 4px; font: 800 10px var(--ui); letter-spacing: .02em; text-transform: uppercase;
  background: rgba(244,246,255,.93); color: #12101c; box-shadow: 0 2px 0 rgba(0,0,0,.45); text-shadow: none; }
#panelCtrl kbd.raton { width: 13px; padding: 0; background: none; box-shadow: none; }
#panelCtrl kbd.raton svg { width: 12px; height: 18px; fill: none; stroke: #fff; stroke-width: 1.3;
  filter: drop-shadow(0 1px 2px rgba(0,0,0,.8)); }
#panelCtrl kbd.raton .izq, #panelCtrl kbd.raton .der { fill: var(--lima); stroke: none; }
body.tactil #panelCtrl, body.tour #panelCtrl, body.portada #panelCtrl { display: none; }
@media (max-height: 520px) {
  #panelCtrl { gap: 2px; padding: 5px 7px; font-size: 11px; right: calc(var(--sr) + 10px); bottom: calc(var(--sb) + 10px); }
  #panelCtrl kbd { height: 15px; font-size: 9.5px; padding: 0 4px; }
}

/* el fundido a oscuro al caerse de la plaza (juego.caidaPlaza) */
#fundido { position: absolute; inset: 0; z-index: 6; background: #07060f; opacity: 0; pointer-events: none; }

/* la tabla alrededor de tu puesto, en el resultado (menus.pintaTablaFin) */
#finTabla { width: min(320px, 100%); display: flex; flex-direction: column; gap: 2px; margin: 1px 0 2px; }
#finTabla .filaRec { padding: 3px 10px; font-size: 12.5px; gap: 8px; grid-template-columns: 30px 1fr auto; text-align: left; }
#finTabla .filaRec b { color: #8b95b6; font-size: 12px; }
#finTabla .filaRec.p1 b { color: var(--oro); } #finTabla .filaRec.p2 b { color: var(--plata); }
#finTabla .filaRec.p3 b { color: var(--bronce); }
#finTabla .filaRec span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-height: 560px) { #finTabla .filaRec { padding: 2px 8px; font-size: 11.5px; } }

/* ---------------------------------------------------------- táctil */
#tactil { position: absolute; inset: 0; display: none; }
body.tactil #hud.jugando #tactil { display: block; }
#tactil .zona { position: absolute; top: 0; bottom: 0; width: 50%; pointer-events: auto; }
#tactilIzq { left: 0; } #tactilDer { right: 0; }
#stickBase { position: absolute; width: 100px; height: 100px; margin: -50px 0 0 -50px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,.2); background: rgba(0,0,0,.16); display: none; }
#stickBase.on { display: block; }
#stickNub { position: absolute; left: 29px; top: 29px; width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.32); }
.tbtn { position: absolute; pointer-events: auto; border-radius: 50%; background: rgba(255,255,255,.13); border: 2px solid rgba(255,255,255,.28);
  color: #fff; font-weight: 900; font-size: 12px; letter-spacing: .04em; display: flex; align-items: center; justify-content: center; }
.tbtn.on { background: rgba(56,225,255,.5); }
/* Más pequeños que antes (tapaban demasiado, revisión de CrazyGames), pero el dedo acierta igual: el
   ::after agranda la zona que recoge el toque 8 px por cada lado sin dibujar nada */
.tbtn::after { content: ''; position: absolute; inset: -8px; border-radius: 50%; }
.tbtn.gancho { right: calc(var(--sr) + 22px); bottom: calc(var(--sb) + 92px); width: 86px; height: 86px; font-size: 13px; }
.tbtn.tira { right: calc(var(--sr) + 124px); bottom: calc(var(--sb) + 120px); width: 56px; height: 56px; font-size: 11px; }
.tbtn.salta { right: calc(var(--sr) + 22px); bottom: calc(var(--sb) + 16px); width: 58px; height: 58px; font-size: 11px; }
.tbtn.agacha { right: calc(var(--sr) + 112px); bottom: calc(var(--sb) + 22px); width: 48px; height: 48px; font-size: 9.5px; }
/* GANCHO + deslizar el dedo hacia arriba = recoger cuerda. La flecha lo recuerda y se enciende al
   hacerlo (entrada.js, `subida`) */
.tbtn.gancho::before { content: '\25B2'; position: absolute; top: -18px; left: 50%; transform: translateX(-50%);
  font-size: 11px; color: rgba(255,255,255,.5); pointer-events: none; }
.tbtn.gancho.sube { background: rgba(182,255,61,.4); border-color: var(--lima); }
.tbtn.gancho.sube::before { color: var(--lima); }
@keyframes flechaSube { 0%, 100% { transform: translate(-50%, 0); opacity: .45; } 50% { transform: translate(-50%, -7px); opacity: 1; } }
/* en el entrenamiento, solo los botones que enseña */
body.entrenando .tbtn.agacha { display: none; }
/* la «R» bajo REINTENTAR es una tecla: en el móvil no hay R (se quitó el botón), así que no se dice */
body.tactil #btnOtra small, body.tactil #btnReiniciaPausa small { display: none; }
/* en los móviles más bajos (un iPhone apaisado con la barra de Safari) todavía un punto más pequeños */
@media (max-height: 380px) {
  .tbtn.gancho { right: calc(var(--sr) + 18px); bottom: calc(var(--sb) + 80px); width: 74px; height: 74px; font-size: 12px; }
  .tbtn.tira { right: calc(var(--sr) + 106px); bottom: calc(var(--sb) + 104px); width: 48px; height: 48px; font-size: 10px; }
  .tbtn.salta { right: calc(var(--sr) + 18px); bottom: calc(var(--sb) + 12px); width: 52px; height: 52px; font-size: 10px; }
  .tbtn.agacha { right: calc(var(--sr) + 96px); bottom: calc(var(--sb) + 18px); width: 42px; height: 42px; font-size: 8.5px; }
  #stickBase { width: 90px; height: 90px; margin: -45px 0 0 -45px; }
  #stickNub { left: 26px; top: 26px; width: 34px; height: 34px; }
}
#btnPausa { position: absolute; top: calc(var(--st) + 10px); right: calc(var(--sr) + 12px); width: 38px; height: 38px; border-radius: 50%;
  background: rgba(0,0,0,.34); border: 1px solid rgba(255,255,255,.2); pointer-events: auto; display: none; align-items: center; justify-content: center; }
body.tactil #hud.jugando #btnPausa { display: flex; }
/* con «Solo ratón» (seguimiento ocular) no hay teclado: la pausa (y desde ella, reintentar), en pantalla */
body.ojos #hud.jugando #btnPausa { display: flex; }
body.ojos canvas#lienzo { cursor: crosshair; }
/* encima de #tactil, como JUGAR: la zona de mirar va después en el DOM y se comía el toque (séptima
   revisión: «el botón de pausa no se puede pulsar en el móvil») */
#btnPausa { z-index: 5; }
/* y la barra de la plaza (Retos, Récords, Ajustes), por lo mismo: en el móvil no se podía tocar
   ninguno de sus botones (jugadores, 2026-10-11) */
#barraLobby { z-index: 5; }
/* en el entrenamiento, GANCHO no va hasta su paso */
body.tactil.sinGancho .tbtn.gancho, body.tactil.sinImpulso .tbtn.tira { opacity: .35; }
/* un móvil con «Controles: ratón y teclado» no tiene ni P ni ratón: sin esto no había forma de salir
   de una carrera */
@media (hover: none) and (pointer: coarse) { #hud.jugando #btnPausa { display: flex; } }
/* en la plaza no hay carrera que pausar (pausa() no hace nada fuera de una), y el botón caía justo
   encima del último de la barra, «Ajustes»: se veía en la captura que mandó el usuario */
body.enLobby #btnPausa { display: none !important; }

/* carga y giro de pantalla */
.barra { width: min(300px, 66vw); height: 8px; background: rgba(255,255,255,.14); border-radius: 6px; overflow: hidden; margin: 18px 0; }
.barra i { display: block; height: 100%; width: 40%; background: var(--neon); border-radius: 6px; animation: carga 1.1s ease-in-out infinite; }
@keyframes carga { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }
#girar { position: fixed; inset: 0; z-index: 9; background: var(--tinta); display: none; flex-direction: column;
  align-items: center; justify-content: center; gap: 14px; text-align: center; padding: 20px; font-weight: 700; }
#girar { background: radial-gradient(120% 80% at 50% 22%, #2a2150 0%, #12101c 62%), var(--tinta); }
#girar .logo { font-size: clamp(34px, 11vw, 62px); margin-bottom: 18px; }
#girar .icono { font-size: 54px; animation: gira 2s ease-in-out infinite; }
#girar p { color: #b9c2e0; font-size: clamp(13px, 4vw, 17px); max-width: 16em; }
@keyframes gira { 0%, 40% { transform: rotate(0); } 60%, 100% { transform: rotate(90deg); } }
/* en vertical el campo de vision se estrecha y los botones tapan medio circuito: se juega en horizontal */
/* `dedo` es la pista del navegador (probablemente un móvil) y se borra en cuanto aparece un ratón:
   así un PC con la ventana estrecha no pide girar un móvil que no tiene */
@media (orientation: portrait) { body.tactil #girar, body.dedo #girar { display: flex; } }
@media (max-width: 480px) { .btn { min-width: 110px; font-size: 14px; } .tarjeta { padding: 16px 12px; } }

/* el selector de idioma: el <select> nativo, invisible, encima del botón. Se pulsa el botón y sale
   el selector del sistema, que en un móvil es el que la gente sabe usar. */
.selIdioma { position: relative; display: block; }
.selIdioma select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font: inherit; }

/* ---------------------------------------------------------- retos del día
   La racha y las tres misiones. Todo en una columna estrecha: es una lista que se lee de arriba
   abajo, no una rejilla que se explora. */
.retosCaja { width: min(560px, 100%); display: flex; flex-direction: column; gap: 12px; text-align: left; }
.retosTit { margin: 6px 0 0; font-size: 15px; letter-spacing: .04em; text-transform: uppercase; opacity: .75; }
.retosSub { margin: -8px 0 0; font-size: 12px; opacity: .5; }

/* la racha: número gordo a la izquierda y la semana en siete casillas */
.rachaCaja { background: linear-gradient(140deg, rgba(255,138,61,.16), rgba(255,77,94,.09));
  border: 2px solid rgba(255,138,61,.4); border-radius: 16px; padding: 13px 15px; }
.rachaCab { display: flex; align-items: center; gap: 13px; }
.rachaCab b { font-size: 40px; font-weight: 900; line-height: 1; color: #ff9d4d;
  text-shadow: 0 0 22px rgba(255,138,61,.55); }
.rachaCab h3 { margin: 0; font-size: 15px; }
.rachaCab span { font-size: 12px; opacity: .6; }
.rachaSemana { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin: 11px 0 8px; }
.rd { display: flex; align-items: center; justify-content: center; font-style: normal;
  aspect-ratio: 1; border-radius: 9px; background: rgba(255,255,255,.05);
  border: 1.5px solid rgba(255,255,255,.1); font-size: 11px; font-weight: 800; opacity: .5; }
.rd.gordo { background: rgba(255,194,51,.1); border-color: rgba(255,194,51,.3); }
.rd.hecho { opacity: 1; background: rgba(255,138,61,.28); border-color: #ff8a3d; color: #ffd8b0; }
/* el escalón de hoy late hasta que lo cobras: es lo que se pierde si no juegas */
.rd.hoy { opacity: 1; border-color: #ffc233; color: var(--oro); animation: latirRacha 1.5s ease-in-out infinite; }
@keyframes latirRacha { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.11); } }
.rachaCaja p { margin: 0; font-size: 12.5px; font-weight: 700; color: #ffd8b0; }

/* una misión: icono, texto con barra, y el botón de cobrar */
.mision { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 12px;
  background: rgba(255,255,255,.05); border: 2px solid rgba(255,255,255,.1);
  border-radius: 13px; padding: 10px 13px; }
.mision.lista { border-color: var(--verde); background: rgba(61,220,132,.1); }
.mision.cobrada { opacity: .5; border-color: rgba(255,255,255,.1); background: rgba(255,255,255,.04); }
.misIco { font-size: 22px; line-height: 1; }
.misCuerpo { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.misCuerpo b { font-size: 13.5px; font-weight: 700; }
.misCuerpo small { font-size: 11px; opacity: .55; font-variant-numeric: tabular-nums; }
.misBarra { height: 5px; border-radius: 3px; background: rgba(255,255,255,.1); overflow: hidden; }
.misBarra i { display: block; height: 100%; border-radius: 3px; background: var(--neon); transition: width .3s; }
.mision.lista .misBarra i { background: var(--verde); }
.misCobra { white-space: nowrap; font-size: 12.5px; font-weight: 800; padding: 7px 11px; }
button.misCobra:disabled { opacity: .35; cursor: default; }
.mision.lista:not(.cobrada) button.misCobra { background: var(--verde); color: #0b2016; border-color: var(--verde); }
.misCobra.fijo { opacity: .6; }
.mision.bono { border-style: dashed; }

/* el reto diario, al final del panel: es un circuito, no una misión */
.diarioCard { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px;
  text-align: left; padding: 12px 15px; border: 2px solid rgba(157,123,255,.5);
  background: linear-gradient(120deg, rgba(157,123,255,.18), rgba(56,225,255,.07)); }
.dcIcono { font-size: 25px; }
.dcTexto b { display: block; font-size: 15px; }
.dcTexto i { font-style: normal; font-size: 11.5px; opacity: .6; }
.dcVamos { font-size: 19px; color: var(--diamante); }

/* la chapa roja del botón de Retos: cuántas recompensas hay esperando */
.chapa { position: absolute; top: -6px; right: -6px; min-width: 17px; height: 17px; padding: 0 4px;
  box-sizing: border-box; border-radius: 9px; background: var(--rojo); color: #fff;
  font-size: 11px; font-weight: 900; font-style: normal; line-height: 17px; text-align: center;
  box-shadow: 0 2px 8px rgba(255,77,94,.6); }
#lobRetos { position: relative; overflow: visible; }

/* racha y misiones en la pantalla de resultado */
.finRetos { display: flex; flex-direction: column; gap: 5px; margin: 4px 0 2px; }
.finRetos span { font-size: 13px; font-weight: 700; padding: 6px 12px; border-radius: 9px;
  background: rgba(255,255,255,.07); }
.finRetos .frRacha { background: rgba(255,138,61,.18); color: #ffd8b0; }
.finRetos .frMision { background: rgba(61,220,132,.16); color: #bff5d6; }
.finRetos b { color: var(--oro); }

/* la tarjeta del reto diario en el menú de circuitos */
.tarjetaNivel.diario { border-color: var(--diamante); background: rgba(157,123,255,.1); }
.tarjetaNivel.diario .nnum { color: var(--diamante); }
.tarjetaNivel.diario .nport { background-image: linear-gradient(140deg, #3d1a6e, #c86bff 70%, #ffe066); }

/* ---------------------------------------------------------- torneo semanal
   Dorado de arriba abajo: es lo único del juego que se gana contra otros, y tiene que leerse así
   de un vistazo, al lado del morado del reto diario y del naranja de la racha. */
.torneoCaja { width: min(560px, 100%); display: flex; flex-direction: column; gap: 11px; text-align: left; }
/* la foto nunca pasa de un tercio de la pantalla: en un móvil apaisado se comía el alto entero y el
   botón de JUGAR quedaba por debajo, fuera de la vista */
.torneoPortada { position: relative; aspect-ratio: 16 / 7; max-height: 28vh; border-radius: 16px; overflow: hidden;
  background-size: cover; background-position: center; background-color: #1a1626;
  border: 2px solid rgba(255,194,51,.55); }
.torneoPortada::after { content: ''; position: absolute; inset: 0;
  background: linear-gradient(rgba(10,8,20,.05) 30%, rgba(10,8,20,.85) 100%); }
#torneoGlifo { position: absolute; top: 10px; left: 12px; z-index: 1; font-size: 34px; line-height: 1;
  filter: drop-shadow(0 3px 10px rgba(0,0,0,.6)); }
.tpTexto { position: absolute; left: 14px; right: 14px; bottom: 10px; z-index: 1; }
.tpTexto h3 { margin: 0; font-size: 21px; font-weight: 900; text-shadow: 0 2px 10px rgba(0,0,0,.8); }
.tpTexto span { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--oro); }
.torneoRegla { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border-radius: 12px;
  background: rgba(255,194,51,.1); border: 1.5px solid rgba(255,194,51,.35); }
.torneoRegla b { font-size: 15px; color: var(--oro); }
.torneoRegla span { font-size: 12.5px; opacity: .8; }
.torneoPendiente { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 14px; border-radius: 12px; background: linear-gradient(120deg, rgba(255,194,51,.28), rgba(255,138,61,.18));
  border: 2px solid var(--oro); font-size: 13px; font-weight: 700; }
.torneoPendiente .btn { background: var(--oro); color: #2a1d00; border-color: var(--oro); white-space: nowrap; }
.torneoYo { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 13.5px; }
.torneoYo b { color: var(--oro); font-variant-numeric: tabular-nums; }
.torneoTabla { display: flex; flex-direction: column; gap: 3px; }
.torneoTabla .nota { margin: 4px 0; font-size: 12.5px; opacity: .6; text-align: center; }
.tfila { display: grid; grid-template-columns: 30px 1fr auto; align-items: center; gap: 8px; padding: 6px 10px;
  border-radius: 9px; background: rgba(255,255,255,.04); font-size: 13px; }
.tfila b { text-align: center; opacity: .7; }
.tfila span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 700; }
.tfila i { font-style: normal; font-variant-numeric: tabular-nums; opacity: .85; }
.tfila.podio.p1 b { color: var(--oro); opacity: 1; } .tfila.podio.p2 b { color: var(--plata); opacity: 1; }
.tfila.podio.p3 b { color: var(--bronce); opacity: 1; }
.tfila.yo { background: rgba(56,225,255,.16); outline: 1.5px solid var(--neon); }
.tfila.hueco { display: block; text-align: center; background: none; opacity: .4; padding: 0; }
.torneoPremios { display: flex; flex-wrap: wrap; gap: 5px; justify-content: center; margin-top: 2px; }
.torneoPremios span { font-size: 11px; padding: 3px 8px; border-radius: 7px; background: rgba(255,255,255,.06); }
.torneoPremios b { color: var(--oro); }
#btnTorneoTabla { align-self: center; }
/* la tarjeta del torneo en el panel de retos; late cuando hay premio por cobrar */
.torneoCard { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px; text-align: left;
  padding: 12px 15px; border: 2px solid rgba(255,194,51,.6);
  background: linear-gradient(120deg, rgba(255,194,51,.2), rgba(255,138,61,.08)); }
.torneoCard .dcVamos { color: var(--oro); }
.torneoCard.listo { animation: latirRacha 1.5s ease-in-out infinite; border-color: var(--oro); }
/* y en el menú de circuitos, al lado del entrenamiento y del reto diario */
.tarjetaNivel.torneo { border-color: var(--oro); background: rgba(255,194,51,.09); }
.tarjetaNivel.torneo .nnum { color: var(--oro); font-style: normal; }
.tarjetaNivel.torneo .nnom i { color: var(--oro); }
/* la regla del torneo, debajo del rótulo del fantasma, toda la carrera */
#hMod { position: absolute; top: calc(var(--st) + 56px); left: calc(var(--sl) + 16px); font-size: 11.5px;
  font-weight: 800; color: var(--oro); padding: 3px 9px; border-radius: 8px; background: rgba(10,8,20,.55); }

/* ---------------------------------------------------------------- Copa del Lanzamiento (js/copa.js)
   Los colores de rango, los de siempre en los juegos: gris común, azul raro, morado épico, dorado
   legendario y la mítica en degradado. Se usan en el panel, en la armería y en el aviso de premio. */
:root { --r-comun: #b9c0cc; --r-raro: #4fa3ff; --r-epica: #b46bff; --r-legendaria: #ffc23a; --r-mitica: #ff6bd5; }
.r-comun { --rc: var(--r-comun); } .r-raro { --rc: var(--r-raro); } .r-epica { --rc: var(--r-epica); }
.r-legendaria { --rc: var(--r-legendaria); } .r-mitica { --rc: var(--r-mitica); }
.copaPortada { background-color: #2a2466; }
.copaPortada > b { position: absolute; top: 10px; left: 12px; z-index: 1; font-size: 34px; line-height: 1; }
.copaMedallas { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; font-size: 12.5px; font-variant-numeric: tabular-nums; }
.copaMedallas span { display: flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 8px; background: rgba(255,255,255,.06); }
.copaMedallas .nmed { position: static; }
.copaArmas { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.copaArma { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; text-align: left; padding: 9px 10px;
  border-radius: 12px; border: 2px solid color-mix(in srgb, var(--rc) 55%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--rc) 18%, transparent), rgba(255,255,255,.03)); }
.copaArma em, .tarjetaCuerda .crango { font-style: normal; font-size: 11px; font-weight: 900; letter-spacing: .08em;
  text-transform: uppercase; color: var(--rc); }
.copaArma b { font-size: 13.5px; }
.copaArma span { font-size: 11.5px; opacity: .78; line-height: 1.3; }
.copaArma.tiene span { color: var(--lima); opacity: 1; font-weight: 800; }
.copaArma:not(.tiene) .muestra { filter: saturate(.55) brightness(.8); }
.copaArma.r-mitica, #premioCopa.r-mitica .pcCaja { border-image: linear-gradient(120deg, #ff6bd5, #9ff0ff, #ffc23a) 1; }
.tarjetaCuerda.r-comun, .tarjetaCuerda.r-raro, .tarjetaCuerda.r-epica, .tarjetaCuerda.r-legendaria, .tarjetaCuerda.r-mitica {
  border-color: color-mix(in srgb, var(--rc) 50%, transparent); }
.tarjetaCuerda.puesto[class*=" r-"] { border-color: var(--lima); }
.torneoTabla .tfila.top10 { box-shadow: inset 3px 0 0 var(--r-mitica); }
.tarjetaNivel.copa { border-color: var(--r-mitica); background: linear-gradient(140deg, rgba(255,107,213,.14), rgba(255,194,51,.1)); }
.tarjetaNivel.copa .nnum { font-style: normal; }
.tarjetaNivel.copa .nnom i { color: var(--r-mitica); }
/* el aviso de arma ganada: encima de todo, con su rango */
#premioCopa { position: fixed; inset: 0; z-index: 60; display: none; align-items: center; justify-content: center;
  background: rgba(8,6,20,.62); }
#premioCopa.ver { display: flex; }
.pcCaja { width: min(340px, 92vw); display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 20px 22px;
  border-radius: 18px; border: 3px solid var(--rc); text-align: center;
  background: radial-gradient(120% 80% at 50% 0%, color-mix(in srgb, var(--rc) 35%, #141d44), #10142e 70%);
  box-shadow: 0 0 40px color-mix(in srgb, var(--rc) 45%, transparent); animation: pcEntra .45s ease-out; }
.pcCaja small { font-size: 12px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; opacity: .85; }
.pcCaja em { font-style: normal; font-size: 13px; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; color: var(--rc); }
.pcCaja b { font-size: 24px; }
.pcCaja > span { font-size: 13px; opacity: .8; }
.pcFoto { width: 100%; }
.pcFoto .muestra { display: block; height: 120px; background-size: contain; background-position: center; }
.pcBotones { display: flex; gap: 8px; margin-top: 6px; }
@keyframes pcEntra { from { transform: scale(.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }

/* la pregunta de los gráficos (juego.preguntaGraficos): tres tarjetas, la recomendada marcada */
/* cómo se derrota al Rey Calabaza (js/rey.js): la primera vez que se entra a pelear */
#reyComo { position: fixed; inset: 0; z-index: 62; display: none; align-items: center; justify-content: center; background: rgba(8,4,20,.62); padding: 14px; pointer-events: auto; }
#reyComo.ver { display: flex; }
.rcoCaja { width: min(560px, 100%); max-height: calc(100% - 8px); overflow-y: auto; display: flex; flex-direction: column; align-items: center; gap: 12px;
  padding: 20px; border-radius: 18px; background: #1a1030; border: 2px solid rgba(255,138,42,.6); text-align: left; animation: pcEntra .4s ease-out; }
.rcoCaja h2 { margin: 0; font-size: 22px; color: #ffb04a; text-align: center; }
.rcoFilas { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.rcoFilas div { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 12px; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); }
.rcoFilas i { font-style: normal; font-size: 24px; line-height: 1; flex-shrink: 0; width: 30px; text-align: center; }
.rcoFilas span { font-size: 14px; font-weight: 700; line-height: 1.35; }
@media (max-height: 520px) { .rcoCaja { padding: 12px 14px; gap: 8px; } .rcoCaja h2 { font-size: 18px; } .rcoFilas div { padding: 6px 10px; } .rcoFilas span { font-size: 12.5px; } }
#graficos { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center;
  background: rgba(8,6,20,.66); padding: 16px; }
#graficos.ver { display: flex; }
.grCaja { width: min(560px, 100%); display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 22px;
  border-radius: 18px; background: #141b3d; border: 2px solid rgba(56,225,255,.45); text-align: center;
  animation: pcEntra .4s ease-out; }
.grCaja h2 { margin: 0; font-size: 22px; }
.grCaja small { font-size: 12px; opacity: .65; }
.grOpciones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; width: 100%; }
.grOp { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 16px 10px 14px;
  border-radius: 14px; border: 2px solid rgba(255,255,255,.14); background: rgba(255,255,255,.05); color: inherit; }
.grOp:hover { border-color: var(--neon); background: rgba(56,225,255,.1); }
.grOp i { font-style: normal; font-size: 30px; line-height: 1; color: var(--neon); }
.grOp b { font-size: 17px; }
.grOp span { font-size: 11.5px; opacity: .75; line-height: 1.3; }
.grOp em { display: none; position: absolute; top: -10px; left: 50%; transform: translateX(-50%); white-space: nowrap;
  font-style: normal; font-size: 10px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase;
  padding: 2px 8px; border-radius: 8px; background: var(--lima); color: #16200a; }
.grOp.reco { border-color: var(--lima); }
.grOp.reco em { display: block; }
@media (max-width: 480px) { .grOpciones { grid-template-columns: 1fr; } .grOp { flex-direction: row; justify-content: flex-start; text-align: left; }
  .grOp em { left: auto; right: 8px; transform: none; } }

/* las novedades de la actualización (js/novedades.js): el tráiler a pantalla completa y, al acabar
   u omitirlo, dos tarjetas de la Copa. Por encima de todo, también de la pregunta de los gráficos */
#novedades { position: fixed; inset: 0; z-index: 63; display: none; align-items: center; justify-content: center;
  background: #05040d; padding: 16px; }
#novedades.ver { display: flex; }
#novedades.cartas { background: rgba(8,6,20,.82); }
#novVideo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #05040d; display: none; }
#novedades.video #novVideo { display: block; }
#novSaltar { position: absolute; top: max(14px, env(safe-area-inset-top)); right: max(14px, env(safe-area-inset-right));
  z-index: 2; display: none; min-height: 44px; padding: 0 18px; font-size: 15px; background: rgba(10,12,30,.6);
  border: 2px solid rgba(255,255,255,.55); }
#novedades.video #novSaltar { display: block; }
#novLetrero { position: absolute; left: 0; right: 0; bottom: 0; z-index: 1; display: flex; flex-direction: column;
  align-items: center; gap: 4px; padding: 60px 16px max(6%, 24px); text-align: center;
  background: linear-gradient(180deg, transparent, rgba(5,4,13,.62)); pointer-events: none; opacity: 0;
  transform: translateY(10px); transition: opacity .35s, transform .35s; text-shadow: 0 2px 0 rgba(0,0,0,.45), 0 0 18px rgba(0,0,0,.6); }
#novedades.video #novLetrero.ver { opacity: 1; transform: none; }
/* en el podio va arriba: abajo están los escalones */
#novLetrero.arriba { bottom: auto; top: 0; padding: max(5%, 20px) 16px 60px; background: linear-gradient(0deg, transparent, rgba(5,4,13,.62)); }
#novGrande { font-size: clamp(22px, min(5.2vw, 8.5vh), 54px); line-height: 1.05; font-weight: 900; letter-spacing: .02em; text-transform: uppercase; }
#novChico { font-size: clamp(16px, 2.7vw, 30px); font-weight: 900; color: var(--oro); }
#novLetrero[class*=" r-"] #novChico { color: var(--rc); }
.novCarta { display: none; width: min(560px, 100%); max-height: 100%; overflow-y: auto; flex-direction: column; align-items: center;
  gap: 10px; padding: 18px; border-radius: 18px; text-align: center; background: #141b3d;
  border: 3px solid var(--r-mitica); box-shadow: 0 0 40px rgba(255,107,213,.3); animation: pcEntra .4s ease-out; }
.novCarta.ver { display: flex; }
.novCarta h2 { margin: 0; font-size: 24px; }
.novCarta p { margin: 0; font-size: 14px; line-height: 1.4; opacity: .9; }
.novPortada { position: relative; width: 100%; min-height: 150px; border-radius: 12px; overflow: hidden; display: flex;
  flex-direction: column; justify-content: flex-end; align-items: flex-start; gap: 2px; padding: 12px 14px; text-align: left;
  background-size: cover; background-position: center; }
.novPortada::before { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 20%, rgba(8,6,20,.85)); }
.novPortada > * { position: relative; }
.novPortada small { font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; color: var(--r-mitica); }
.novPortada span { font-size: 15px; font-weight: 800; color: var(--oro); }
#novArmasLista { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; width: 100%; }
.novArma { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 6px 8px; border-radius: 11px;
  border: 2px solid color-mix(in srgb, var(--rc) 60%, transparent);
  background: linear-gradient(160deg, color-mix(in srgb, var(--rc) 20%, transparent), rgba(255,255,255,.03)); }
.novArma .muestra { height: 64px; }
.novArma em { font-style: normal; font-size: 11px; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; color: var(--rc); }
.novArma b { font-size: 12.5px; line-height: 1.15; }
.novArma span { font-size: 10.5px; opacity: .75; line-height: 1.25; }
.novArma.r-mitica { border-image: linear-gradient(120deg, #ff6bd5, #9ff0ff, #ffc23a) 1; }
@media (max-height: 520px) {
  .novCarta { padding: 12px; gap: 7px; }
  .novPortada { min-height: 96px; }
  .novArma .muestra { height: 34px; }
  .novArma span { display: none; }
}

/* la tarjeta del Traje del Lanzamiento: la foto a la izquierda y las tres misiones */
.novTraje { display: flex; gap: 14px; align-items: center; width: 100%; text-align: left; }
.novTraje img { width: 38%; max-width: 190px; aspect-ratio: 2 / 3; object-fit: cover; border-radius: 12px; flex: none;
  background: radial-gradient(circle at 50% 40%, #3b3a8a, #141b3d); border: 2px solid var(--r-legendaria); }
.novTraje small { font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; color: var(--r-legendaria); }
.novTraje h2 { margin: 2px 0 6px; }
#novTrajeLista { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.novMision { display: flex; align-items: center; gap: 8px; padding: 5px 8px; border-radius: 10px;
  border: 2px solid color-mix(in srgb, var(--rc) 55%, transparent); background: rgba(255,255,255,.04); }
.novMision .muestra { width: 44px; height: 44px; flex: none; }
.novMision span { display: flex; flex-direction: column; font-size: 11.5px; line-height: 1.25; opacity: .9; }
.novMision b { font-size: 13px; }
@media (max-height: 520px) { .novTraje img { width: 26%; } .novMision .muestra { width: 32px; height: 32px; } }

/* Las ventanas que esperan un clic (novedades, gráficos, arma o ropa ganada) viven dentro de #ui, que deja pasar el
   ratón al juego (pointer-events: none). Sin esto los clics las atravesaban y se los comía el lienzo: los botones
   no hacían nada (lo encontró el usuario en CrazyGames el 2026-10-12; las pruebas pulsaban por código y no lo veían) */
#novedades, #graficos, #premioCopa { pointer-events: auto; }
#novLetrero { pointer-events: none; }
/* la tarjeta de la Copa se salía unos píxeles a lo ancho y sacaba una barra de desplazamiento */
.novCarta { overflow-x: hidden; }
.novPortada { box-sizing: border-box; }

/* Revisión de CrazyGames (2026-10-12): «los botones son transparentes y su texto cuesta de leer». El panel de la
   Copa no tenía el fondo oscuro de los demás (arriba), y sus tarjetas y el botón de «Empieza en…» (desactivado,
   a media opacidad) dejaban ver el mundo: fondo macizo a todo lo que se pulsa ahí */
.copaArma { background-color: #1b2247; }
.copaCaja .btn:disabled { opacity: 1; background: #2a3058; color: #d9def0; border-color: rgba(255,255,255,.18); }

/* ---------------------------------------------------------------- el pase de temporada (js/pase.js) */
/* en fila (el número al lado, no debajo) y con el mismo alto que los demás botones de la barra: la revisión de
   CrazyGames vio el del Pase más alto que el resto (2026-10-22) */
#barraLobby .btn.pase { display: inline-flex; flex-direction: row; align-items: center; gap: 7px; border-color: rgba(143,224,74,.7); background: rgba(40,70,20,.6); }
#barraLobby .btn.pase.oculto { display: none; }
#barraLobby .btn.pase b { background: #8fe04a; color: #13240a; border-radius: 6px; padding: 2px 6px; min-width: 20px; text-align: center;
  font-size: 12px; line-height: 1; font-weight: 900; font-variant-numeric: tabular-nums; margin: -3px 0; }
.paseCaja { width: min(720px, 100%); display: flex; flex-direction: column; gap: 12px; text-align: left; }
.paseCab { display: flex; align-items: center; gap: 16px; padding: 14px 16px; border-radius: 16px;
  background: linear-gradient(120deg, rgba(143,224,74,.18), rgba(56,225,255,.07)); border: 2px solid rgba(143,224,74,.45); }
.paseNv { display: flex; flex-direction: column; align-items: center; min-width: 70px; }
.paseNv small { font-size: 11px; letter-spacing: .12em; opacity: .7; font-weight: 800; }
.paseNv b { font-size: 44px; line-height: 1; font-weight: 900; color: #b6ff3d; }
.paseProg { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.paseProg .misBarra { height: 12px; border-radius: 6px; }
.paseProg .misBarra i { background: linear-gradient(90deg, #8fe04a, #b6ff3d); border-radius: 6px; }
.paseProg span:last-child { font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; opacity: .85; }
#btnPaseDoble { display: flex; flex-direction: column; align-items: center; }
#btnPaseDoble.oculto { display: none; }
#btnPaseDoble small { font-size: 11px; opacity: .75; font-weight: 700; }
.paseTira { display: flex; gap: 8px; overflow-x: auto; padding: 4px 2px 10px; scroll-behavior: smooth; }
.paseCelda { position: relative; flex: 0 0 92px; height: 128px; border-radius: 12px; padding: 22px 6px 6px;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between; text-align: center;
  background: rgba(255,255,255,.05); border: 2px solid rgba(255,255,255,.1); cursor: default; }
.paseCelda[class*=" r-"] { border-color: var(--rc); background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(0,0,0,.15)); cursor: pointer; }
.paseCelda.gorda { flex-basis: 104px; }
.paseCelda em { position: absolute; top: 4px; left: 0; right: 0; font-style: normal; font-size: 11px; font-weight: 900; opacity: .7; }
.paseCelda b { font-size: 11.5px; line-height: 1.15; font-weight: 800; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.paseCelda .muestra { width: 64px; height: 56px; }
.paseIco { font-size: 30px; line-height: 56px; }
.paseCelda.hecho { opacity: .55; }
.paseCelda.siguiente { box-shadow: 0 0 0 3px #b6ff3d; opacity: 1; }
.paseOk { position: absolute; top: 3px; right: 6px; font-style: normal; font-weight: 900; color: var(--verde); }
.paseSemXp { font-size: 12px; font-weight: 900; color: #b6ff3d; white-space: nowrap; }
.finPase { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; margin: 4px 0 2px; padding: 7px 12px; border-radius: 10px;
  background: rgba(143,224,74,.14); color: #dfffc4; font-size: 13px; font-weight: 700; }
.finPase.oculto { display: none; }
.finPase b { color: #b6ff3d; font-weight: 900; }
.finPase .misBarra { flex: 1 1 100%; height: 6px; }
.finPase .misBarra i { background: #8fe04a; }
.finPase small { flex: 1 1 100%; font-size: 11.5px; opacity: .85; }
.finPase.sube { background: rgba(143,224,74,.28); box-shadow: 0 0 0 2px rgba(182,255,61,.6); }
.paseX2 { font-style: normal; background: var(--oro); color: #2a1a00; border-radius: 6px; padding: 0 5px; font-size: 11px; }
#paseSemanas { display: flex; flex-direction: column; gap: 8px; }
#paseSemanas .mision { width: 100%; box-sizing: border-box; }
@supports not selector(::-webkit-scrollbar) { .paseTira { scrollbar-width: thin; scrollbar-color: rgba(182,255,61,.5) transparent; } }
.paseTira::-webkit-scrollbar { height: 6px; }
.paseTira::-webkit-scrollbar-thumb { background: rgba(182,255,61,.5); border: 0; border-radius: 3px; }
.paseTira::-webkit-scrollbar-track { background: transparent; }

/* ---------------------------------------------------------------- subir de rango (js/rangos.js)
   Fases: f1 el emblema viejo (tiembla o crece), f2 destello y entra el nuevo con rayos y chispas, f3 el nombre
   y los niveles, f4 el botón. --rs es el color de la división nueva y --rsLuz su brillo. */
#rangoSube { position: fixed; inset: 0; z-index: 64; display: none; align-items: center; justify-content: center;
  pointer-events: auto; overflow: hidden; --rs: #ffc233; --rsLuz: #fff0b3; }
#rangoSube.ver { display: flex; animation: rsAparece .35s ease-out; }
#rangoSube.sale { animation: rsSale .28s ease-in forwards; }
@keyframes rsAparece { from { opacity: 0; } }
@keyframes rsSale { to { opacity: 0; } }
.rsFondo { position: absolute; inset: 0; background: rgba(8,6,18,.94); }
body.rangoVer #hAviso { opacity: 0 !important; }
.rsFondo::after { content: ''; position: absolute; inset: 0; background: radial-gradient(circle at 50% 40%, var(--rs), transparent 52%);
  opacity: 0; transition: opacity .6s; }
#rangoSube.f2 .rsFondo::after { opacity: .26; }
#rangoSube.t-nivel.f2 .rsFondo::after { opacity: .18; }
#rangoSube.t-baja .rsFondo::after { opacity: .12 !important; }
.rsRayos { position: absolute; left: 50%; top: 40%; width: 170vmax; height: 170vmax; margin: -85vmax 0 0 -85vmax;
  background: repeating-conic-gradient(var(--rsLuz) 0deg 6deg, transparent 6deg 20deg);
  -webkit-mask: radial-gradient(circle, #000 0, rgba(0,0,0,.6) 12%, transparent 34%); mask: radial-gradient(circle, #000 0, rgba(0,0,0,.6) 12%, transparent 34%);
  opacity: 0; transform: scale(.6); transition: opacity .5s, transform .9s cubic-bezier(.2,1.2,.4,1); }
#rangoSube.f2 .rsRayos { opacity: .3; transform: scale(1); animation: rsGira 16s linear infinite; }
#rangoSube.t-nivel.f2 .rsRayos { opacity: .16; }
#rangoSube.t-maestro.f2 .rsRayos { opacity: .45; animation-duration: 10s; }
#rangoSube.t-baja .rsRayos { display: none; }
@keyframes rsGira { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
.rsChispas { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; }
.rsCentro { position: relative; z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; padding: 0 16px; }
.rsEmblema { position: relative; width: min(46vmin, 300px); aspect-ratio: 1; margin-bottom: 6px; }
.rsEmblema img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.rsNuevo { opacity: 0; transform: scale(.2); }
#rangoSube.f1 .rsViejo { animation: rsTiembla .9s ease-in-out both; }
#rangoSube.t-nivel.f1 .rsViejo { animation: rsCrece .4s ease-out both; }
#rangoSube.t-colocacion.f1 .rsViejo { animation: rsTiembla .3s ease-in-out both; }
#rangoSube.f2 .rsViejo { opacity: 0; transform: scale(1.35); filter: blur(6px) brightness(2); transition: opacity .18s, transform .18s, filter .18s; }
#rangoSube.f2 .rsNuevo { animation: rsEntra .75s cubic-bezier(.2,1.5,.45,1) forwards, rsLate 2.2s ease-in-out .9s infinite; }
#rangoSube.t-baja.f1 .rsViejo { animation: none; }
#rangoSube.t-baja.f2 .rsViejo { transform: translateY(26px) scale(.9); filter: grayscale(.6); opacity: 0; transition: all .6s ease-in; }
#rangoSube.t-baja.f2 .rsNuevo { animation: rsBaja .7s ease-out forwards; }
@keyframes rsTiembla { 0%, 100% { transform: none; } 10% { transform: translate(-4px, 2px) rotate(-2deg); } 20% { transform: translate(5px, -2px) rotate(2deg); }
  30% { transform: translate(-6px, -1px) rotate(-3deg) scale(1.02); } 40% { transform: translate(6px, 2px) rotate(3deg) scale(1.03); }
  55% { transform: translate(-7px, 1px) rotate(-4deg) scale(1.05); } 70% { transform: translate(7px, -2px) rotate(4deg) scale(1.07); }
  85% { transform: translate(-4px, 0) rotate(-2deg) scale(1.1); filter: brightness(1.5); } }
@keyframes rsCrece { to { transform: scale(1.12); filter: brightness(1.4); } }
@keyframes rsEntra { 0% { opacity: 0; transform: scale(.2) rotate(-12deg); } 45% { opacity: 1; } 70% { transform: scale(1.18) rotate(3deg); } 100% { opacity: 1; transform: scale(1) rotate(0); } }
@keyframes rsLate { 0%, 100% { filter: drop-shadow(0 0 10px var(--rs)); } 50% { filter: drop-shadow(0 0 28px var(--rs)) brightness(1.08); } }
@keyframes rsBaja { from { opacity: 0; transform: translateY(-20px) scale(.92); } to { opacity: 1; transform: none; } }
.rsFlash { position: absolute; left: 50%; top: 50%; width: 10px; height: 10px; margin: -5px; border-radius: 50%; background: #fff; opacity: 0; pointer-events: none; }
#rangoSube.f2 .rsFlash { animation: rsFlash .55s ease-out; }
#rangoSube.t-baja.f2 .rsFlash { animation: none; }
@keyframes rsFlash { 0% { opacity: .75; transform: scale(1); box-shadow: 0 0 50px 34px #fff; } 100% { opacity: 0; transform: scale(28); box-shadow: 0 0 50px 34px var(--rsLuz); } }
.rsTit, .rsNombre, .rsNiveles, .rsPr { opacity: 0; transform: translateY(14px); transition: opacity .4s, transform .5s cubic-bezier(.2,1.4,.4,1); }
#rangoSube.f3 .rsTit { opacity: 1; transform: none; }
#rangoSube.f3 .rsNombre { opacity: 1; transform: none; transition-delay: .08s; }
#rangoSube.f3 .rsNiveles { opacity: 1; transform: none; transition-delay: .2s; }
#rangoSube.f3 .rsPr { opacity: .8; transform: none; transition-delay: .3s; }
.rsTit { text-shadow: 0 1px 3px rgba(0,0,0,.8); font-size: clamp(12px, 2.4vmin, 16px); font-weight: 900; letter-spacing: .22em; color: var(--rsLuz); text-transform: uppercase; }
.rsNombre { font-size: clamp(30px, 7vmin, 60px); font-weight: 900; line-height: 1; text-transform: uppercase; color: var(--rs);
  text-shadow: 0 2px 0 rgba(0,0,0,.7), 0 0 2px rgba(0,0,0,.9), 0 0 6px rgba(0,0,0,.6), 0 0 26px var(--rs); }
#rangoSube.t-maestro .rsNombre { background: linear-gradient(90deg, #ffd36b, #ffffff 30%, #b46bff 60%, #ffd36b); -webkit-background-clip: text; background-clip: text;
  color: transparent; background-size: 200% 100%; animation: rsBrilla 2.4s linear infinite; text-shadow: none; filter: drop-shadow(0 0 14px rgba(180,107,255,.8)); }
@keyframes rsBrilla { to { background-position: -200% 0; } }
.rsNiveles { display: flex; gap: 8px; margin-top: 4px; }
.rsNiveles i { width: 30px; height: 9px; border-radius: 5px; background: rgba(255,255,255,.14); transition: background .3s, box-shadow .3s; }
.rsNiveles i.on { background: var(--rs); box-shadow: 0 0 10px var(--rs); }
.rsPr { font-size: 13px; font-weight: 800; font-variant-numeric: tabular-nums; }
.rsVale { margin-top: 12px; opacity: 0; transform: translateY(10px); pointer-events: none; transition: opacity .35s, transform .35s; }
#rangoSube.f4 .rsVale { opacity: 1; transform: none; pointer-events: auto; }
@media (max-height: 420px) { .rsEmblema { width: min(42vmin, 200px); } .rsVale { margin-top: 6px; } }

/* ---------------------------------------------------------------- el podio de la plaza (js/podio.js) */
.etiJugador.etiPodio { padding: 4px 11px 5px; border: 2px solid; border-radius: 10px; background: rgba(10,8,20,.62); font-size: 13px; }
.etiJugador.etiPodio b { font-variant-numeric: tabular-nums; color: var(--lima); margin-left: 4px; }
.etiJugador.etiPodio.p1 { border-color: #ffc233; } .etiJugador.etiPodio.p2 { border-color: #cdd7e6; } .etiJugador.etiPodio.p3 { border-color: #e08b48; }

/* ---- el pase, segunda versión: escaparate, reclamar a mano y la tarjeta de «¡Conseguido!» */
#barraLobby .btn.pase { position: relative; }
.paseFichas { margin-left: auto; background: rgba(255,194,51,.16); border: 1px solid rgba(255,194,51,.5); color: #ffe08a; white-space: nowrap; }
.paseEscaparate { display: flex; align-items: center; gap: 16px; padding: 12px 16px; border-radius: 16px; cursor: pointer;
  background: linear-gradient(110deg, rgba(0,0,0,.25), rgba(255,255,255,.05)); border: 2px solid var(--rc, rgba(255,255,255,.2)); }
.paseEscaparate .peMuestra .muestra { width: 120px; height: 104px; }
.paseEscaparate .peMuestra .paseIco { font-size: 56px; line-height: 104px; }
.peTexto { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.peTexto small { font-size: 11px; letter-spacing: .14em; font-weight: 900; opacity: .7; text-transform: uppercase; }
.peTexto b { font-size: 22px; font-weight: 900; line-height: 1.1; }
.peTexto em { font-style: normal; font-size: 12px; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; color: var(--rc); }
.peTexto span { font-size: 13px; font-weight: 700; opacity: .85; }
.paseEscaparate.r-mitica { box-shadow: 0 0 22px rgba(255,107,213,.35); }
#btnPaseTodo.oculto { display: none; }
.paseCelda { cursor: pointer; }
.paseCelda.bloq { opacity: .72; }
.paseCelda.bloq .muestra, .paseCelda.bloq .paseIco { filter: saturate(.55) brightness(.8); }
.paseCelda.listo { opacity: 1; border-color: #b6ff3d !important; box-shadow: 0 0 0 2px rgba(182,255,61,.35), 0 0 16px rgba(182,255,61,.35); animation: paseListo 1.4s ease-in-out infinite; }
@keyframes paseListo { 50% { transform: translateY(-3px); box-shadow: 0 0 0 2px rgba(182,255,61,.5), 0 0 24px rgba(182,255,61,.55); } }
.paseRec { position: absolute; left: 4px; right: 4px; bottom: 4px; font-style: normal; font-size: 10.5px; font-weight: 900; letter-spacing: .06em;
  background: #b6ff3d; color: #13240a; border-radius: 6px; padding: 3px 0; }
.paseCelda.listo b { visibility: hidden; }
.muestra.placa { border-radius: 8px; box-shadow: inset 0 0 0 3px var(--b); }
#paseConseguido { position: fixed; inset: 0; z-index: 62; display: none; align-items: center; justify-content: center; background: rgba(8,6,18,.7); pointer-events: auto; }
#paseConseguido.ver { display: flex; animation: rsAparece .25s ease-out; }
#paseConseguido .pcCaja { animation: rsEntra .55s cubic-bezier(.2,1.5,.45,1); }
#lobPaseChapa { position: absolute; top: -7px; right: -7px; }
.finPase .finListo { color: #b6ff3d; font-weight: 900; opacity: 1; }
.paseCelda .muestra.punta { font-size: 30px; display: flex; align-items: center; justify-content: center; }
.paseEscaparate .muestra.punta { font-size: 56px; display: flex; align-items: center; justify-content: center; }
#paseConseguido .pcFoto .muestra.punta { font-size: 72px; display: flex; align-items: center; justify-content: center; }

/* ---- las placas de nombre (temporada 1): el marco de la etiqueta del nombre, en la plaza y en el podio */
.etiJugador[data-placa] { padding: 3px 11px 4px; border-radius: 9px; border: 2px solid; }
.etiJugador[data-placa="pl_corteza"] { background: linear-gradient(180deg, #7a5532, #4a321c); border-color: #c9a227; }
.etiJugador[data-placa="pl_musgo"] { background: linear-gradient(180deg, #2f5a2a, #1f3a24); border-color: #b6ff3d; box-shadow: 0 0 10px rgba(182,255,61,.45); }
.etiJugador[data-placa="pl_oro"] { background: linear-gradient(110deg, #8a5f10, #c9a227 40%, #fff0b3 50%, #c9a227 60%, #8a5f10); background-size: 250% 100%;
  border-color: #fff0b3; color: #2a1a00; text-shadow: 0 1px 0 rgba(255,255,255,.35); animation: placaBrillo 3s linear infinite; }
.etiJugador[data-placa="pl_oro"] i { color: #3a2500; }
.etiJugador[data-placa="pl_ascenso"] { border: 3px solid transparent;
  background: linear-gradient(#10142e, #1c2a14) padding-box, linear-gradient(90deg, #b6ff3d, #c9a227, #8fe04a, #fff0b3, #b6ff3d) border-box;
  background-size: 100% 100%, 300% 100%; animation: placaBorde 3s linear infinite, placaLate 2.2s ease-in-out infinite; }
.etiJugador[data-placa="pl_ascenso"]:not(.etiPodio)::before { content: "🌿 "; }
.etiJugador[data-placa="pl_ascenso"]:not(.etiPodio)::after { content: " 🌿"; }
@keyframes placaBrillo { to { background-position: -250% 0; } }
@keyframes placaBorde { to { background-position: 0 0, -300% 0; } }
@keyframes placaLate { 50% { box-shadow: 0 0 16px rgba(182,255,61,.55); } }
#placaPrevia { position: absolute; left: 25%; top: 17%; display: block; z-index: 3; transform: translate(-50%, -50%) scale(1.7); font-size: 13px; }
#placaPrevia.oculto { display: none; }
#barraLobby #lobGesto kbd { font-size: 10px; padding: 0 4px; margin-left: 3px; border-radius: 4px; background: rgba(255,255,255,.15); }
body.tactil #lobGesto kbd { display: none; }
#barraLobby #lobChat { white-space: nowrap; flex-direction: row; align-items: center; gap: 5px; }
#barraLobby #lobChat kbd { display: inline-block; font-size: 10px; padding: 0 4px; margin: 0; border-radius: 4px; background: rgba(255,255,255,.15); }
body.tactil #lobChat kbd { display: none; }

/* las tarjetas de la temporada (js/novedades.js): el color de la temporada en vez del de la mítica */
.novCarta.temporada { border-color: #8fe04a; box-shadow: 0 0 40px rgba(143,224,74,.28); }
.novTempPortada { position: relative; width: 100%; box-sizing: border-box; display: flex; align-items: flex-end; justify-content: space-between;
  gap: 10px; min-height: 170px; padding: 14px 4px 0 16px; border-radius: 12px; overflow: hidden; text-align: left;
  background: radial-gradient(circle at 78% 30%, rgba(216,255,122,.35), transparent 55%), linear-gradient(160deg, #2f5a2a, #142a17 70%); }
.novTempPortada > div { padding-bottom: 14px; }
.novTempPortada small { font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; color: #d8ff7a; }
.novTempPortada h2 { margin: 2px 0 4px; font-size: 26px; line-height: 1.1; }
.novTempPortada span { font-size: 15px; font-weight: 800; color: var(--oro); }
.novTempPortada img { width: 34%; max-width: 150px; aspect-ratio: 2 / 3; object-fit: contain; flex: none; display: block;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,.45)); }
#novTemp2 .novTraje img { border-color: var(--r-mitica); object-fit: contain;
  background: radial-gradient(circle at 50% 40%, #4f6b2a, #141b3d); }
#novTemp2 .novTraje small { color: var(--r-mitica); }
#novTempLista { display: flex; flex-direction: column; gap: 6px; margin-top: 8px; }
.novTempMas { margin-top: 8px !important; font-size: 12.5px !important; opacity: .8 !important; }
#novTempFormas { display: flex; flex-direction: column; gap: 8px; width: 100%; text-align: left; }
.novForma { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 11px;
  background: rgba(143,224,74,.08); border: 2px solid rgba(143,224,74,.3); font-size: 14px; line-height: 1.3; }
.novForma i { font-style: normal; font-size: 24px; flex: none; width: 30px; text-align: center; }
.novBotones { display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; }
@media (max-height: 520px) {
  .novTempPortada { min-height: 110px; } .novTempPortada img { width: 22%; } .novTempPortada h2 { font-size: 21px; }
  .novForma { padding: 5px 10px; font-size: 12.5px; } .novForma i { font-size: 18px; } .novTempMas { display: none; }
}
.novTambien { margin-top: 4px; font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; color: var(--oro); }
#novTempFormas .novTambien + .novForma { background: rgba(255,194,58,.07); border-color: rgba(255,194,58,.3); }
/* el escaparate: la muestra de ropa o arma es un <span> y se quedaba en línea, a 0x0 (no se veía la imagen) */
.paseEscaparate .peMuestra { flex: none; }
.paseEscaparate .peMuestra .muestra:not(.punta) { display: block; }
/* los anuncios con premio de los retos (2026-10-13): el cofre del día, salvar la racha y las misiones x2 */
.cofreCard { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 13px; text-align: left; padding: 12px 15px;
  border: 2px solid rgba(182,255,61,.6); background: linear-gradient(120deg, rgba(182,255,61,.2), rgba(56,225,255,.08)); }
.cofreCard.listo { animation: latirRacha 1.5s ease-in-out infinite; border-color: var(--lima); }
.cofreCard.hecho { opacity: .6; }
.cofreCard .dcVamos .icoVideo { width: 26px; height: 26px; fill: var(--lima); }
#btnSalvaRacha, #btnX2 { width: 100%; margin-top: 8px; display: flex; flex-direction: column; align-items: center; gap: 1px; }
#btnSalvaRacha.oculto, #btnX2.oculto, .cofreCard.oculto { display: none; }
#btnX2.activo { opacity: .7; }
#oferta { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center; background: rgba(8,6,20,.62); pointer-events: auto; }
#oferta.ver { display: flex; }
#oferta .ofIco { font-size: 64px; line-height: 1.1; animation: latirRacha 1.5s ease-in-out infinite; }
#oferta .pcCaja b { font-size: 26px; }

/* ---- la Tienda (js/tienda.js): destacados grandes y la diaria, con el color de su rareza, al estilo de Fortnite */
#barraLobby .tiendaBtn { position: relative; background: linear-gradient(135deg, #ffc233, #ff8a3d); color: #2a1600; border-color: #ffd36b; font-weight: 900; }
#barraLobby .tiendaBtn:hover { filter: brightness(1.08); }
.tiCaja { width: min(980px, 100%); display: flex; flex-direction: column; gap: 10px; }
.tiQueda { align-self: flex-start; }
.tiTit { margin: 6px 0 0; font-size: 14px; letter-spacing: .14em; text-transform: uppercase; opacity: .85; text-align: left; }
.tiRejilla { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.tiRejilla.grande { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
/* la tienda de neón, por secciones (lanzagarfios, cada skin, lo demás) */
.tnSec { grid-column: 1 / -1; margin: 8px 0 -2px; text-align: left; font-size: 16px; font-weight: 900; color: #fff; letter-spacing: .02em;
  display: flex; align-items: center; gap: 8px; }
.tnSec:first-child { margin-top: 0; }
.tnSec em { font-style: normal; font-size: 11px; font-weight: 800; text-transform: uppercase; color: var(--rc); padding: 2px 8px;
  border-radius: 99px; border: 2px solid color-mix(in srgb, var(--rc) 60%, transparent); }
.tiCarta { position: relative; display: flex; flex-direction: column; padding: 0; overflow: hidden; border-radius: 14px; text-align: left;
  border: 2px solid color-mix(in srgb, var(--rc) 70%, transparent); cursor: pointer; font: inherit; color: var(--papel);
  background: radial-gradient(120% 90% at 50% 10%, color-mix(in srgb, var(--rc) 55%, #1c2350), #10142e 75%);
  box-shadow: 0 6px 18px rgba(0,0,0,.35); transition: transform .12s, box-shadow .12s; }
.tiCarta:hover { transform: translateY(-3px); box-shadow: 0 10px 24px color-mix(in srgb, var(--rc) 40%, transparent); }
.tiCarta.elegido { outline: 3px solid var(--lima); outline-offset: -3px; }
.tiCarta.r-legendaria, .tiCarta.r-mitica { border-image: linear-gradient(120deg, #ffc23a, #ff6bd5, #9ff0ff) 1; }
.tiFoto { display: flex; align-items: center; justify-content: center; height: 110px; padding: 10px; }
.tiCarta.grande .tiFoto { height: 170px; }
.tiFoto .muestra { width: 100%; height: 100%; }
.tiFoto .muestra.prenda { background-color: transparent; }
.tiFoto .muestra.punta { height: 70%; font-size: 44px; border-radius: 14px; }
.tiCarta.grande .tiFoto .muestra.punta { font-size: 64px; }
.tiFoto .muestra.cuerda { height: 18px; }
.tiFoto .muestra.mira { width: 26px; height: 34px; flex: none; transform: scale(2.2); }
.tiInfo { display: flex; flex-direction: column; gap: 2px; padding: 8px 11px 10px; background: rgba(8,8,22,.55); }
.tiInfo em { font-style: normal; font-size: 10.5px; font-weight: 900; letter-spacing: .1em; text-transform: uppercase; color: var(--rc); }
.tiInfo b { font-size: 15px; line-height: 1.15; }
.tiCarta.grande .tiInfo b { font-size: 19px; }
.tiInfo i { font-style: normal; font-weight: 900; color: var(--oro); }
.tiCarta.tuyo .tiInfo i { color: var(--lima); }
.tiCarta.tuyo .tiFoto { opacity: .75; }
@media (max-height: 520px) { .tiFoto { height: 74px; } .tiCarta.grande .tiFoto { height: 96px; } .tiRejilla.grande { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* el arma y el garfio de muestra dejan mucho aire alrededor: en la tienda se acercan y se aclaran un poco */
.tiFoto.c-arma .muestra, .tiFoto.c-garfio .muestra { background-size: auto 135%; filter: brightness(1.18) drop-shadow(0 0 12px rgba(255,255,255,.22)); }
.tiCarta.grande .tiFoto.c-arma .muestra, .tiCarta.grande .tiFoto.c-garfio .muestra { background-size: auto 175%; }

/* las placas de la tienda (fase 2) */
.etiJugador[data-placa="pl_hielo"] { background: linear-gradient(180deg, #d8f2ff, #7fbfe6); border-color: #ffffff; color: #0b2a3a; text-shadow: none; box-shadow: 0 0 10px rgba(191,233,255,.55); }
.etiJugador[data-placa="pl_hielo"] i { color: #1b4a66; }
.etiJugador[data-placa="pl_fuego"] { background: linear-gradient(180deg, #ff8a1f, #b0301a); border-color: #ffd257; box-shadow: 0 0 12px rgba(255,138,31,.55); }
.etiJugador[data-placa="pl_noche"] { background: linear-gradient(180deg, #2a1650, #0b0716); border-color: #9d4bff; box-shadow: 0 0 12px rgba(157,75,255,.55); }

/* el lote del día: una tarjeta ancha con sus piezas dentro (js/tienda.js) */
.tiLote { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: 16px;
  border: 3px solid var(--rc); background: radial-gradient(120% 120% at 0% 0%, color-mix(in srgb, var(--rc) 45%, #1c2350), #10142e 70%);
  box-shadow: 0 8px 26px color-mix(in srgb, var(--rc) 30%, transparent); }
.tiLote.elegido { outline: 3px solid var(--lima); outline-offset: -3px; }
.tiLote.r-legendaria, .tiLote.r-mitica { border-image: linear-gradient(120deg, #ffc23a, #ff6bd5, #9ff0ff) 1; }
.tiLoteCab { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left; background: none; border: 0;
  color: var(--papel); font: inherit; cursor: pointer; padding: 2px 4px; }
.tiLoteCab em { font-style: normal; font-size: 11px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; color: var(--rc); }
.tiLoteCab b { font-size: 26px; line-height: 1.1; }
.tiLoteCab i { font-style: normal; font-weight: 900; font-size: 17px; color: var(--oro); }
.tiLoteCab s { opacity: .55; font-weight: 700; margin-right: 4px; }
.tiLote.tuyo .tiLoteCab i { color: var(--lima); }
.tiLotePiezas { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.tiLotePiezas .tiFoto { height: 92px; }
.tiAhorro { font-style: normal; font-size: 12px; font-weight: 900; color: var(--lima); margin-left: 6px; }
@media (max-height: 520px) { .tiLoteCab b { font-size: 20px; } .tiLotePiezas .tiFoto { height: 64px; } }

/* la Huida del Tronador (js/huida.js): el resumen (como el del Infinito) y a cuántos metros va el monstruo */
/* el chat rápido (js/chat.js): la rueda, las burbujas encima de los demás y la tuya abajo */
#chatRueda { position: fixed; inset: 0; z-index: 62; display: none; align-items: center; justify-content: center; background: rgba(8,6,30,.5); pointer-events: auto; }
#chatRueda.ver { display: flex; }
#chatRueda .pcCaja { width: min(560px, 95vw); max-height: 94vh; overflow-y: auto; gap: 10px; }
#chEmos { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; width: 100%; }
.chEmo { position: relative; aspect-ratio: 1; border-radius: 16px; border: 2px solid rgba(255,255,255,.14); background: rgba(255,255,255,.06); cursor: pointer; padding: 4px;
  display: flex; align-items: center; justify-content: center; transition: transform .12s, background .12s; }
.chEmo:hover { transform: scale(1.07); background: rgba(154,107,255,.25); border-color: #c9b8ff; }
.chEmo img { width: 92%; height: 92%; object-fit: contain; pointer-events: none; }
.chEmo kbd { position: absolute; left: 6px; top: 4px; font-size: 11px; opacity: .6; }
.chEmo .chCarga { width: 30px; height: 30px; border-radius: 50%; border: 3px solid rgba(255,255,255,.25); border-top-color: #fff; animation: chGira .8s linear infinite; }
@keyframes chGira { to { transform: rotate(360deg); } }
#chFrases { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; width: 100%; }
#chatRueda .chFrase { margin: 0; min-width: 0; text-transform: none; letter-spacing: 0; font-size: 13px; padding: 8px 6px; }
#chMudos { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; width: 100%; }
#chMudos:empty { display: none; }
#chMudos small { width: 100%; }
#chatRueda .chMudo { margin: 0; text-transform: none; font-size: 12px; }
#chatRueda .chMudo.callado { opacity: .55; }
@media (max-height: 560px) { #chEmos { grid-template-columns: repeat(8, 1fr); } #chFrases { grid-template-columns: repeat(4, 1fr); } #chatRueda .pcCaja { padding: 10px 14px; gap: 6px; } }
#chatBurbujas { position: fixed; inset: 0; pointer-events: none; z-index: 3; }
.chBurbuja { position: absolute; display: none; transform: translate(-50%,-50%); pointer-events: none; text-align: center; }
/* el bocadillo: blanco, con su pico hacia la cabeza; con tres puntos que saltan mientras elige, y luego el mensaje */
.chGlobo { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 5px; background: #fff; color: #1a1030;
  border-radius: 18px; padding: 6px 13px; box-shadow: 0 3px 0 rgba(20,10,40,.45); font-weight: 900; font-size: 15px; white-space: nowrap; transform-origin: 50% 100%; }
.chGlobo::after { content: ''; position: absolute; left: 50%; bottom: -8px; margin-left: -8px; border: 8px solid transparent; border-top-color: #fff; border-bottom: 0; }
.chGlobo.emo { padding: 3px 8px; }
.chGlobo img { width: 62px; height: 62px; display: block; }
.chGlobo b { font-size: 40px; }
.chGlobo.escribe { padding: 10px 13px; }
.chGlobo.escribe i { width: 9px; height: 9px; border-radius: 50%; background: #7a6f9a; animation: chPunto 1.1s ease-in-out infinite; }
.chGlobo.escribe i:nth-child(2) { animation-delay: .15s; } .chGlobo.escribe i:nth-child(3) { animation-delay: .3s; }
@keyframes chPunto { 0%, 60%, 100% { transform: translateY(0); opacity: .45; } 30% { transform: translateY(-5px); opacity: 1; } }
.chBurbuja.pop > * { animation: chPop .32s cubic-bezier(.3,1.6,.6,1); }
.chBurbuja.crece > * { animation: chCrece .34s cubic-bezier(.3,1.6,.6,1); }
@keyframes chCrece { from { transform: scale(.5); } to { transform: none; } }
@keyframes chPop { from { transform: scale(.3); opacity: 0; } to { transform: none; opacity: 1; } }
/* la ventana del chat, arriba a la izquierda (como la de Roblox) */
#chatLog { position: fixed; left: 14px; top: 66px; z-index: 4; width: min(310px, 44vw); display: none; flex-direction: column; gap: 3px; padding: 8px 10px;
  border-radius: 12px; background: rgba(10,8,28,.42); pointer-events: none; }
#chatLog.ver { display: flex; }
#chatLog .chLinea { font-size: 13px; font-weight: 800; color: #fff; text-shadow: 0 1px 2px rgba(0,0,0,.7); line-height: 1.3; display: flex; align-items: center; gap: 4px;
  flex-wrap: wrap; animation: chEntra .25s ease-out; transition: opacity .9s; }
#chatLog .chLinea img { width: 26px; height: 26px; vertical-align: middle; }
#chatLog .chLinea b { font-weight: 900; }
#chatLog .chLinea.vieja { opacity: 0; }
@keyframes chEntra { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: none; } }
@media (max-width: 700px), (max-height: 500px) { #chatLog { top: 52px; width: min(240px, 46vw); padding: 5px 8px; } #chatLog .chLinea { font-size: 11px; } #chatLog .chLinea img { width: 20px; height: 20px; } }
#chatYo { position: fixed; left: 50%; bottom: 120px; transform: translateX(-50%); z-index: 55; pointer-events: none; display: none; }
#chatYo.ver { display: block; animation: chPop .32s cubic-bezier(.3,1.6,.6,1), chSale .4s ease-in 2.2s forwards; }
@keyframes chSale { to { opacity: 0; transform: translateX(-50%) translateY(-12px); } }
/* la cinemática de Rush (js/sueno.js): bandas de cine, la noche, el rayo, el remolino del sueño y el texto */
#suCine { position: fixed; inset: 0; z-index: 60; pointer-events: none; display: none; }
#suCine.ver { display: block; pointer-events: auto; cursor: pointer; }
#suCine.sale { display: block; animation: suSale .7s ease-out forwards; }
#suCine.sale .suBarra, #suCine.sale .suTexto, #suCine.sale .suSalta, #suCine.sale .suNoche { opacity: 0; transition: opacity .3s; }
@keyframes suSale { to { opacity: 0; } }
#suCine .suNoche { position: absolute; inset: 0; background: rgba(8,10,34,.12); transition: background .25s; }
#suCine .suRayo { position: absolute; inset: 0; background: #e8e4ff; opacity: 0; }
#suCine .suVelo { position: absolute; inset: 0; opacity: 0; background: radial-gradient(circle at 50% 50%, rgba(60,20,120,.2) 0%, rgba(40,10,90,.85) 35%, #07031a 70%); }
#suCine .suBarra { position: absolute; left: 0; right: 0; height: 11vh; background: #000; }
#suCine .suBarra.arriba { top: 0; } #suCine .suBarra.abajo { bottom: 0; }
#suCine .suTexto { position: absolute; left: 0; right: 0; bottom: 13vh; text-align: center; font-size: clamp(20px, 3.4vw, 34px); font-weight: 900;
  color: #fff; text-shadow: 0 3px 0 #1a1030, 0 0 18px rgba(154,107,255,.7); opacity: 0; transform: translateY(8px); transition: opacity .35s, transform .35s; padding: 0 16px; }
#suCine .suTexto.ver { opacity: 1; transform: none; }
#suCine .suSalta { position: absolute; right: 18px; bottom: calc(11vh + 10px); font-size: 13px; font-weight: 800; color: rgba(255,255,255,.6); }
body.enCine #hud, body.enCine #huDist { opacity: 0 !important; visibility: hidden !important; }
/* el premio del buzón de ideas (js/ideas.js): el emblema del título y lo que te llevas */
#ideasPremio { position: fixed; inset: 0; z-index: 64; display: none; align-items: center; justify-content: center; background: rgba(8,6,30,.66); pointer-events: auto; }
#ideasPremio.ver { display: flex; }
#ideasPremio .ipEmblema { width: 150px; height: 150px; display: flex; align-items: center; justify-content: center; animation: ipBrilla 2.4s ease-in-out infinite; }
#ideasPremio .ipEmblema img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 0 18px rgba(255,210,87,.55)); }
#ideasPremio .ipEmblema b { font-size: 90px; }
@keyframes ipBrilla { 50% { transform: translateY(-5px) rotate(-2deg); } }
#ideasPremio b#ipTitulo { font-size: 22px; color: var(--oro); }
#ideasPremio .ipCosas { display: flex; flex-direction: column; gap: 4px; width: 100%; }
#ideasPremio .ipCosas span { padding: 6px 10px; border-radius: 10px; background: rgba(255,255,255,.07); font-weight: 800; font-size: 14px; }
#huElige { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center; background: rgba(8,6,30,.66); pointer-events: auto; }
#huElige.ver { display: flex; }
#huElige .pcCaja { width: min(380px, 94vw); }
#huElige .hfIco { font-size: 46px; line-height: 1; font-weight: 900; color: #ffe14a; text-shadow: 0 0 18px rgba(255,225,74,.7); }
#huElige .heDia { width: 100%; margin: 0; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 12px; }
#huElige .heDia b { font-size: 18px; }
#huElige .heDia span { font-size: 12px; font-weight: 800; opacity: .8; }
#heDifs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100%; }
#huElige .heDif { margin: 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 9px 8px; text-transform: none; }
#huElige .heDif b { font-size: 16px; color: var(--dc); }
#huElige .heDif span { font-size: 11px; font-weight: 700; line-height: 1.25; opacity: .8; text-align: center; letter-spacing: 0; }
#huElige .heDif em { font-style: normal; font-size: 12px; font-weight: 900; color: var(--oro); }
#huElige .heDif.elegida { border-color: var(--dc); box-shadow: 0 0 0 2px var(--dc) inset; }
#huElige .heOk { font-style: normal; color: var(--lima); }
#huElige .pcCaja { max-height: 96vh; overflow-y: auto; }
@media (max-height: 560px) {
  #huElige .pcCaja { width: min(760px, 96vw); padding: 10px 14px; gap: 5px; }
  #huElige .hfIco { display: none; }
  #huElige .heDia { padding: 6px 10px; }
  #heDifs { grid-template-columns: repeat(4, 1fr); gap: 6px; }
  #huElige .heDif { padding: 6px 5px; }
}
#huElige .d-facil { --dc: #7dff9a; } #huElige .d-normal { --dc: #4de1ff; } #huElige .d-dificil { --dc: #ffb03a; } #huElige .d-pesadilla { --dc: #ff5ad8; }
#huFin { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center; background: rgba(8,6,30,.66); pointer-events: auto; }
#huFin.ver { display: flex; }
#huFin .hfIco { font-size: 58px; line-height: 1; font-weight: 900; color: #ffe14a; text-shadow: 0 0 18px rgba(255,225,74,.7); }
#huFin .pcCaja b#hfGrande { font-size: 40px; color: #c9b8ff; }
#huFin.escapa .pcCaja b#hfGrande { color: var(--lima); }
#huFin.record .pcCaja b#hfGrande { color: var(--oro); }
#huFin .ifPremio { display: flex; flex-direction: column; align-items: center; font-weight: 900; font-size: 20px; color: var(--oro); }
#huFin .ifTabla { display: flex; flex-direction: column; gap: 3px; width: 100%; margin-top: 4px; }
#huFin .ifTabla:empty { display: none; }
#huFin .ifTabla small { text-align: center; margin-bottom: 2px; }
#huFin .ifTabla span { text-transform: none; letter-spacing: 0; display: grid; grid-template-columns: 26px 1fr auto; gap: 8px; padding: 3px 8px; border-radius: 8px; background: rgba(255,255,255,.05); font-size: 13px; }
#huFin .ifTabla span.yo { background: rgba(255,225,74,.16); color: #fff2b0; }
#huFin .ifTabla i { font-style: normal; font-weight: 900; opacity: .7; }
#huFin .ifTabla b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; font-size: 13px; color: inherit; text-align: left; }
#huFin .ifTabla em { text-transform: none; font-style: normal; font-weight: 900; color: var(--oro); }
#huDist { position: absolute; top: 112px; left: 50%; transform: translateX(-50%); display: none; align-items: center; gap: 8px; padding: 6px 14px;
  border-radius: 999px; background: rgba(20,16,48,.78); border: 2px solid #7a5cff; color: #fff; font-weight: 900; pointer-events: none; z-index: 4; white-space: nowrap; }
#huDist.ver { display: flex; }
#huDist em { font-style: normal; font-size: 14px; color: #fff2c8; opacity: .9; margin-left: 6px; }
#huManchas { position: fixed; inset: 0; pointer-events: none; opacity: 0; z-index: 3;
  background: radial-gradient(circle at 22% 30%, rgba(8,4,20,.95) 0 11%, transparent 18%), radial-gradient(circle at 70% 62%, rgba(8,4,20,.95) 0 14%, transparent 22%),
    radial-gradient(circle at 48% 44%, rgba(8,4,20,.92) 0 9%, transparent 16%), radial-gradient(circle at 82% 22%, rgba(8,4,20,.9) 0 8%, transparent 14%),
    radial-gradient(circle at 30% 78%, rgba(8,4,20,.92) 0 10%, transparent 17%), radial-gradient(ellipse at center, rgba(8,4,20,.35), rgba(8,4,20,.8)); }
#huVineta.apagon { background: radial-gradient(ellipse at center, rgba(2,1,6,.8) 0%, rgba(2,1,6,.94) 45%, #000 100%) !important; }
#huLatido { position: fixed; inset: 0; pointer-events: none; opacity: 0; z-index: 2; background: radial-gradient(ellipse at center, rgba(2,1,6,.55) 0%, rgba(2,1,6,.86) 40%, #000 85%); }
#huVineta { position: fixed; inset: 0; pointer-events: none; opacity: 0; z-index: 2;
  background: radial-gradient(ellipse at center, rgba(8,4,20,0) 42%, rgba(8,4,20,.32) 68%, rgba(6,3,16,.62) 100%); transition: opacity .6s linear; }
#huDist i { font-style: normal; color: #ffe14a; font-size: 20px; }
#huDist b { font-size: 20px; }
#huDist span { font-size: 13px; color: #ffe14a; }
#huDist.cerca { border-color: #ffe14a; animation: huLate .5s ease-in-out infinite alternate; }
@keyframes huLate { from { transform: translateX(-50%) scale(1); } to { transform: translateX(-50%) scale(1.08); } }

/* el resumen del modo Infinito (js/infinito.js) */
#infFin { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center; background: rgba(8,6,30,.66); pointer-events: auto; }
#infFin.ver { display: flex; }
#infFin .ifIco { font-size: 58px; line-height: 1; font-weight: 900; color: #7ff6ff; text-shadow: 0 0 18px rgba(63,240,255,.7); }
#infFin .pcCaja b { font-size: 40px; }
#infFin.record .pcCaja b { color: var(--oro); }
#infFin .ifPremio { display: flex; flex-direction: column; align-items: center; font-weight: 900; font-size: 20px; color: var(--oro); }
#infFin .ifPremio small { font-size: 13px; color: var(--lima); text-transform: none; letter-spacing: 0; }
#infFin .ifTabla { display: flex; flex-direction: column; gap: 3px; width: 100%; margin-top: 4px; }
#infFin .ifTabla:empty { display: none; }
#infFin .ifTabla small { text-align: center; margin-bottom: 2px; }
#infFin .ifTabla span { text-transform: none; letter-spacing: 0; display: grid; grid-template-columns: 26px 1fr auto; gap: 8px; padding: 3px 8px; border-radius: 8px; background: rgba(255,255,255,.05); font-size: 13px; }
#infFin .ifTabla span.yo { background: rgba(127,246,255,.16); color: #bffaff; }
#infFin .ifTabla i { font-style: normal; font-weight: 900; opacity: .7; }
#infFin .ifTabla b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; font-size: 13px; color: inherit; text-align: left; }
#infFin .ifTabla em { text-transform: none; font-style: normal; font-weight: 900; color: var(--oro); }

/* la pantalla de JUGAR (v71): el destacado, seguir y el reto; los modos; los mundos en pestañas (js/menus.js) */
.jgHero { display: grid; grid-template-columns: 2fr 1fr; gap: 12px; margin-top: 4px; }
.jgLado { display: grid; grid-template-rows: 1fr 1fr; gap: 12px; min-width: 0; }
.jgLado .tarjetaNivel .nport { aspect-ratio: 16 / 6.4; }
.tarjetaNivel.continuar { border-color: var(--lima); background: rgba(182,255,61,.07); }
.tarjetaNivel.continuar .nnom i { color: var(--lima); opacity: 1; }
.jgDestacado { position: relative; min-height: 310px; border-radius: 18px; overflow: hidden; border: 2px solid #7a5cff; text-align: left;
  padding: 0; background: #120c2e; box-shadow: 0 12px 44px rgba(122,92,255,.35); cursor: pointer; transition: transform .12s, border-color .16s; }
.jgDestacado:hover { transform: translateY(-2px); border-color: var(--neon); }
.jgFondo { position: absolute; inset: 0; background-size: cover; background-position: center; }
.jgFondo::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10,6,30,0) 25%, rgba(10,6,30,.94) 90%), radial-gradient(110% 80% at 0% 100%, rgba(122,92,255,.5), transparent 62%); }
.jgTexto { position: absolute; left: 20px; right: 20px; bottom: 18px; display: flex; flex-direction: column; gap: 5px; }
.jgTexto small { font-size: 11px; font-weight: 900; letter-spacing: .18em; text-transform: uppercase; color: var(--neon); }
.jgTexto > b { font-size: 40px; font-weight: 900; font-style: italic; line-height: 1; color: #fff; text-shadow: 0 0 24px rgba(127,246,255,.6); }
.jgTexto > i { font-style: normal; font-size: 14px; font-weight: 600; color: #ddd6ff; }
.jgDatos { display: flex; flex-wrap: wrap; gap: 6px; }
.jgDatos:empty { display: none; }
.jgDatos em { font-style: normal; font-size: 12px; font-weight: 800; padding: 3px 10px; border-radius: 999px; background: rgba(255,255,255,.12); color: var(--oro); }
.jgBoton { align-self: flex-start; margin-top: 6px; pointer-events: none; padding: 10px 26px; font-size: 17px; }
.jgPestanas { display: flex; gap: 8px; flex-wrap: wrap; margin: 22px 0 10px; }
.jgTab { --c: var(--neon); display: flex; flex-direction: column; align-items: flex-start; gap: 1px; padding: 8px 15px; border-radius: 12px;
  border: 2px solid rgba(255,255,255,.12); background: rgba(255,255,255,.05); color: var(--papel); font: inherit; cursor: pointer; text-align: left; transition: border-color .15s; }
.jgTab b { font-size: 14px; font-weight: 900; }
.jgTab small { font-size: 11px; font-weight: 700; opacity: .75; }
.jgTab:hover { border-color: var(--c); }
.jgTab.sel { border-color: var(--c); background: color-mix(in srgb, var(--c) 20%, rgba(12,10,26,.6)); box-shadow: 0 0 20px color-mix(in srgb, var(--c) 35%, transparent); }
.jgTab.sel b { color: var(--c); }
.jgTab.cerrado { opacity: .5; }
.rejilla.modos { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.rejilla.modos .nport { aspect-ratio: 16 / 8; }
.rejilla.jgMundo { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.rejilla.jgMundo .nnom { font-size: 14px; }
@media (max-width: 760px) {
  .jgHero { grid-template-columns: 1fr; }
  .jgDestacado { min-height: 220px; }
  .jgTexto > b { font-size: 30px; }
  .rejilla.jgMundo { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-height: 520px) { .jgDestacado { min-height: 200px; } .jgTexto > b { font-size: 28px; } }
/* (2026-11-03) la fila de abajo de la portada: cuatro, la última Circuitos con su mosaico; y la cabecera de su vista
   (js/menus.js, pintaCircuitos) */
#listaNiveles > .rejilla.modos { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.tarjetaNivel.circuitosModo { --ac: #7ff6ff; }
.jcMosaico { display: grid !important; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 2px; background: #0d0b18 !important; }
.jcMosaico i:not(.nnum) { background-size: cover; background-position: center; }
.jcMosaico .nnum { position: absolute; }
.jcArriba { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin: 2px 0 4px; }
.jcTit { flex: 1; margin: 0 0 0 2px; font-size: 18px; font-weight: 900; color: var(--papel); }
.jcChip { padding: 8px 14px; font-size: 13px; }
@media (max-width: 560px) { .jcTit { flex-basis: 100%; order: 3; margin: 4px 0 0; } #listaNiveles > .rejilla.modos { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* las tarjetas de la v71: El Vacío y el Infinito (js/novedades.js) */
.novCarta.vacio { border-color: #7a5cff; background: radial-gradient(120% 90% at 50% 0%, #2a1a66, #0e0a24 75%); }
.novCarta.vacio > small { color: var(--neon); font-weight: 900; letter-spacing: .16em; text-transform: uppercase; font-size: 12px; }
.novCarta.vacio h2 { color: #fff; text-shadow: 0 0 20px rgba(127,246,255,.5); }
.novVacioFotos { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; width: 100%; }
.novVacioFotos span { position: relative; aspect-ratio: 16 / 11; border-radius: 8px; background-size: cover; background-position: center; overflow: hidden; border: 1px solid rgba(127,246,255,.35); }
.novVacioFotos b { position: absolute; left: 4px; right: 4px; bottom: 3px; font-size: 10px; font-weight: 800; color: #fff; text-shadow: 0 1px 4px #000; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* el vídeo de la actualización de las ideas (la tarjeta 7 de las mejoras): con sus controles y su sonido */
.novActVideo { width: 100%; aspect-ratio: 16 / 9; max-height: 40vh; border-radius: 12px; border: 1px solid rgba(127,246,255,.35); background: #000; object-fit: contain; }
.novInfFoto { width: 100%; max-height: 150px; object-fit: cover; border-radius: 12px; border: 1px solid rgba(127,246,255,.35); }
@media (max-width: 560px) { .novVacioFotos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* revisión de la v71: en un móvil tumbado (375 px de alto) el resumen del Infinito, la cabecera de JUGAR y la tarjeta
   del Infinito dejaban sus botones fuera de la pantalla */
#infFin .pcCaja { box-sizing: border-box; width: min(390px, 92vw); max-height: calc(100% - 16px); overflow-y: auto; }   /* border-box: como #editTeclas */
#infFin.record .ifTabla b { color: inherit; }
@media (max-height: 520px) {
  #infFin .ifIco { display: none; }
  #infFin .pcCaja { gap: 4px; padding: 12px 16px; }
  #infFin .pcCaja > b { font-size: 26px; }
  #infFin .ifTabla span { padding: 2px 8px; }
  #infFin .ifTabla span:nth-of-type(n+4):not(.yo) { display: none; }
  .jgDestacado { min-height: 170px; }
  .jgTexto > i { display: none; }
  .jgBoton { padding: 6px 18px; font-size: 14px; margin-top: 2px; }
  .jgLado .tarjetaNivel .nport { aspect-ratio: 16 / 3.4; }
  .novInfFoto { max-height: 64px; }
}

/* los mandos a gusto de cada uno (js/mandos.js) */
#editTeclas, #editMandos { position: fixed; inset: 0; z-index: 75; display: none; pointer-events: auto; }
#editTeclas { align-items: center; justify-content: center; background: rgba(8,6,20,.7); }
#editTeclas.ver, #editMandos.ver { display: flex; }
/* border-box: el alto máximo no contaba el relleno ni el borde (26 px) y en 800x450 la caja se salía por arriba y por
   abajo (revisión de CrazyGames, 2026-10-28); la lista es la que encoge y se desplaza */
#editTeclas .pcCaja { box-sizing: border-box; width: min(470px, 94vw); max-height: calc(100% - 20px); overflow: hidden; }
@media (max-height: 520px) {
  #editTeclas .pcCaja { gap: 4px; padding: 10px 16px; }
  #editTeclas .pcCaja > span { font-size: 12px; }
  #editTeclas .pcBotones { margin-top: 2px; }
  .mdFila .btn { padding-top: 3px; padding-bottom: 3px; }
}
#teclasLista { display: flex; flex-direction: column; gap: 2px; width: 100%; flex: 1 1 auto; min-height: 0; overflow-y: auto; }
.mdFila { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 1px 4px; font-weight: 700; font-size: 14px; }
.mdFila .btn { padding-top: 5px; padding-bottom: 5px; }
.mdTecla { min-width: 108px; text-transform: none; }
.mdTecla.espera { border-color: var(--lima); color: var(--lima); animation: tutoPulso 1.15s ease-out infinite; }
#editMandos { background: rgba(8,6,20,.88); }
#mdZona { position: absolute; inset: 0; }
#mdZona .tbtn { touch-action: none; cursor: grab; }
#mdZona .tbtn.on { border-color: var(--lima); background: rgba(182,255,61,.3); }
.mdBarra { position: absolute; left: 50%; top: calc(var(--st) + 10px); transform: translateX(-50%); width: min(440px, 70vw);
  display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 14px; border-radius: 14px;
  background: rgba(18,16,40,.92); border: 2px solid rgba(255,255,255,.14); color: var(--papel); text-align: center; font-weight: 700; font-size: 13px; }
.mdTamano { display: flex; align-items: center; gap: 10px; width: 100%; }
.mdTamano b { min-width: 64px; color: var(--lima); }
.mdTamano input { flex: 1; }
@media (max-height: 520px) { .mdBarra { gap: 3px; padding: 6px 10px; font-size: 11px; } .mdBarra .btn { padding: 5px 12px; } }

/* el objetivo del que acaba de llegar (js/lobby.js, objetivo): arriba en la plaza hasta su primer circuito */
#objetivo { position: absolute; left: 50%; top: calc(var(--st) + 66px); transform: translateX(-50%); display: none; flex-direction: column;
  align-items: center; gap: 2px; padding: 8px 18px; border-radius: 16px; background: rgba(14,12,32,.82); border: 2px solid var(--lima);
  box-shadow: 0 6px 24px rgba(182,255,61,.25); color: var(--papel); text-align: center; pointer-events: none; max-width: min(520px, 86vw); }
body.enLobby #objetivo.ver { display: flex; }
#objetivo small { font-size: 11px; font-weight: 900; letter-spacing: .16em; text-transform: uppercase; color: var(--lima); }
#objetivo b { font-size: 17px; font-weight: 900; }
#objetivo span { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; color: #d9dcf2; }
#objetivo em { font-style: normal; }
.objFlecha { display: inline-block; font-style: normal; font-size: 20px; color: var(--lima); transition: transform .12s linear; }
@media (max-height: 520px) { #objetivo { top: calc(var(--st) + 52px); padding: 5px 14px; } #objetivo b { font-size: 14px; } }
/* con el ratón capturado está encima la pista de la P (#pistaEsc): el objetivo, debajo de ella
   (revisión de CrazyGames de la v72: se pisaban) */
body.capturado.enLobby:not(.tactil) #objetivo { top: calc(var(--st) + 98px); }
@media (max-height: 520px) {
  body.capturado.enLobby #pistaEsc { top: calc(var(--st) + 48px); padding: 4px 11px; font-size: 11px; }
  body.capturado.enLobby:not(.tactil) #objetivo { top: calc(var(--st) + 78px); }
}

/* la tarjeta de la v72: los mandos (js/novedades.js) */
.novMandosDibujo { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 4px 0 2px; }
.nmTecla { width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; border-radius: 7px; font-weight: 900;
  background: #2a2a52; border: 2px solid #7a7ab8; box-shadow: 0 3px 0 #15152e; color: #fff; }
.nmFlecha { margin: 0 8px; font-size: 22px; font-weight: 900; color: var(--lima); }
.nmMovil { position: relative; width: 92px; height: 50px; border-radius: 9px; border: 3px solid #7a7ab8; background: #15152e; }
.nmMovil i { position: absolute; border-radius: 50%; border: 2px solid rgba(255,255,255,.5); background: rgba(255,255,255,.12); }
.nmMovil i:nth-child(1) { width: 18px; height: 18px; right: 6px; top: 6px; border-color: var(--lima); background: rgba(182,255,61,.35); }
.nmMovil i:nth-child(2) { width: 12px; height: 12px; right: 28px; top: 10px; }
.nmMovil i:nth-child(3) { width: 12px; height: 12px; right: 8px; bottom: 5px; }
#novMandosFormas { display: flex; flex-direction: column; gap: 6px; width: 100%; }
#novMandosFormas .novForma.tuyo { border-color: var(--lima); }

/* el sello del evento en sus premios (js/eventos.js, sello): aparte del rango, una pastilla con el color del evento */
.sello { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; font-style: normal; font-size: 9.5px; font-weight: 900;
  letter-spacing: .02em; text-transform: uppercase; line-height: 1.25; padding: 2px 7px 2px 5px; border-radius: 999px; white-space: normal;
  color: var(--sc); background: color-mix(in srgb, var(--sc) 15%, #0d1030); border: 1px solid color-mix(in srgb, var(--sc) 70%, transparent); }
#premioSello:empty { display: none; }
#premioSello .sello { font-size: 11.5px; padding: 3px 11px 3px 9px; }

/* el resumen de la pelea contra el Rey Calabaza (js/rey.js): el mismo molde que el del Infinito */
#reyFin { position: fixed; inset: 0; z-index: 61; display: none; align-items: center; justify-content: center; background: rgba(14,6,30,.66); pointer-events: auto; }
#reyFin.ver { display: flex; }
#reyFin .pcCaja { box-sizing: border-box; width: min(390px, 92vw); max-height: calc(100% - 16px); overflow-y: auto; }   /* border-box: como #editTeclas */
#reyFin .ifIco { font-size: 58px; line-height: 1; }
#reyFin .pcCaja b { font-size: 40px; }
#reyFin.record .pcCaja b { color: var(--oro); }
#reyFin .ifPremio { display: flex; flex-direction: column; align-items: center; font-weight: 900; font-size: 20px; color: var(--oro); }
#reyFin .ifPremio:empty { display: none; }
@media (max-height: 520px) { #reyFin .ifIco { display: none; } #reyFin .pcCaja { gap: 4px; padding: 12px 16px; } #reyFin .pcCaja > b { font-size: 26px; } }

/* la vida del Rey Calabaza (js/rey.js): debajo de los faroles, la misma para todo el mundo */
#reyVida { display: none; position: absolute; top: calc(var(--st) + 90px); left: 50%; transform: translateX(-50%);
  width: min(340px, 64vw); text-align: center; pointer-events: none; }
#reyVida.ver { display: block; }
#reyVida small { display: block; font-size: 11px; font-weight: 900; letter-spacing: .14em; text-transform: uppercase; color: #ffb04a;
  text-shadow: 0 1px 6px rgba(0,0,0,.6); }
#reyVida .rvBarra { height: 10px; margin-top: 3px; border-radius: 6px; background: rgba(20,10,40,.7); border: 1px solid rgba(255,176,74,.55); overflow: hidden; }
#reyVida .rvBarra i { display: block; height: 100%; width: 100%; background: linear-gradient(90deg, #b46bff, #ff8a2a); transition: width .4s ease; }
#reyVida b { display: block; margin-top: 2px; font-size: 11px; font-weight: 800; color: #f3e6ff; text-shadow: 0 1px 6px rgba(0,0,0,.6); font-variant-numeric: tabular-nums; }
@media (max-height: 520px) { #reyVida { top: calc(var(--st) + 78px); } }
/* la Caza de dulces: el marcador de los cuatro, a la derecha (js/dulces.js) */
#dulMarcador { display: none; position: absolute; right: 14px; top: calc(var(--st) + 12px); width: 190px; pointer-events: none; }
#dulMarcador.ver { display: flex; flex-direction: column; gap: 4px; }
#dulMarcador span { display: flex; align-items: center; gap: 7px; padding: 5px 9px; border-radius: 10px; background: rgba(20,8,38,.72); color: #f3e6ff; font-size: 13px; font-weight: 800; }
#dulMarcador span.yo { background: rgba(255,170,60,.85); color: #241200; }
#dulMarcador i { font-style: normal; width: 14px; opacity: .8; }
#dulMarcador b { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; }
#dulMarcador em { font-style: normal; font-variant-numeric: tabular-nums; }
@media (max-width: 600px) { #dulMarcador { width: 150px; right: 8px; } #dulMarcador span { font-size: 11px; padding: 4px 7px; } }
body.tactil #dulMarcador { top: calc(var(--st) + 54px); }   /* en táctil, ahí arriba está el botón de pausa */
/* tus vidas contra el Rey y el −1 que le sale al apagarle un farol */
#reyVidas { display: none; position: absolute; top: calc(var(--st) + 136px); left: 50%; transform: translateX(-50%); pointer-events: none;
  font-size: 24px; line-height: 1; letter-spacing: 3px; filter: drop-shadow(0 2px 3px rgba(0,0,0,.65)); white-space: nowrap; }
#reyVidas.ver { display: block; }
#reyVidas i { font-style: normal; display: inline-block; transition: opacity .3s, transform .3s, filter .3s; }
#reyVidas i.fuera { opacity: .3; filter: grayscale(1); transform: scale(.78); }
#reyVidas i.pierde { animation: rvPierde .7s ease-out; }
#reyVidas.ultima i:not(.fuera) { animation: rvLate .6s ease-in-out infinite alternate; }
@keyframes rvPierde { 0% { transform: scale(1.7); filter: brightness(2.2); } 100% { transform: scale(.78); } }
@keyframes rvLate { from { transform: scale(1); } to { transform: scale(1.22); } }
@media (max-height: 520px) { #reyVidas { top: calc(var(--st) + 122px); font-size: 20px; } }
.reyDano { position: absolute; transform: translate(-50%, -50%); pointer-events: none; font-size: 26px; font-weight: 900; color: #ffd25a;
  text-shadow: 0 2px 0 #3a1460, 0 0 12px rgba(255,170,60,.7); animation: reyDano 1s ease-out forwards; }
@keyframes reyDano { 0% { opacity: 0; margin-top: 0; transform: translate(-50%, -50%) scale(.6); } 15% { opacity: 1; transform: translate(-50%, -50%) scale(1.25); }
  100% { opacity: 0; margin-top: -60px; transform: translate(-50%, -50%) scale(1); } }
#reyFin .rfRey { font-size: 13px; line-height: 1.45; text-align: center; color: #e9dcff; }
#reyFin .rfRey:empty { display: none; }
#reyFin .rfRey b { color: #ffb04a; font-size: 15px; font-weight: 900; }
#reyFin .ifTabla { display: flex; flex-direction: column; gap: 3px; width: 100%; margin-top: 4px; }
#reyFin .ifTabla:empty { display: none; }
#reyFin .ifTabla small { text-align: center; margin-bottom: 2px; }
#reyFin .ifTabla span { text-transform: none; letter-spacing: 0; display: grid; grid-template-columns: 26px 1fr auto; gap: 8px; padding: 3px 8px; border-radius: 8px; background: rgba(255,255,255,.05); font-size: 13px; }
#reyFin .ifTabla span.yo { background: rgba(255,176,74,.18); color: #ffe2b8; }
#reyFin .ifTabla i { font-style: normal; font-weight: 900; opacity: .7; }
#reyFin .ifTabla b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 800; font-size: 13px; color: inherit; text-align: left; }
#reyFin .ifTabla em { text-transform: none; font-style: normal; font-weight: 900; color: var(--oro); }
@media (max-height: 520px) { #reyFin .ifTabla span:nth-of-type(n+4):not(.yo) { display: none; } }

/* la tarjeta del Rey Calabaza (novedades): que la foto recortada no le corte la cabeza */
#novReyFoto { object-position: 50% 12%; }

/* cómo van las misiones del traje, debajo de las monedas */
#reyFin .rfMis { display: block; margin-top: 4px; font-size: 13px; font-weight: 800; color: #f3e6ff; opacity: .8; }

/* el cuadro de la isla del Rey (js/rey.js): la cuenta atrás para entrar en equipo */
#reyZona { position: absolute; left: 50%; top: calc(var(--st) + 66px); transform: translateX(-50%); display: none; flex-direction: column;
  align-items: center; gap: 2px; padding: 9px 20px; border-radius: 16px; background: rgba(22,10,40,.85); border: 2px solid #ff8a2a;
  box-shadow: 0 6px 24px rgba(255,138,42,.3); color: #f3e6ff; text-align: center; pointer-events: none; max-width: min(520px, 88vw); }
body.enLobby #reyZona.ver { display: flex; }
body.enCuadroRey #objetivo { visibility: hidden !important; }
/* en pantallas bajas el aviso de la plaza sube al 22 %: con la cuenta del cuadro, debajo de ella */
@media (max-height: 480px) { body.enLobby.enCuadroRey .hAviso { top: 40%; bottom: auto; } }
#reyZona b { font-size: 19px; font-weight: 900; color: #ffb04a; }
#reyZona span { font-size: 14px; font-weight: 800; }
#reyZona small { font-size: 11px; opacity: .75; }
body.capturado.enLobby:not(.tactil) #reyZona { top: calc(var(--st) + 98px); }
@media (max-height: 520px) { #reyZona { top: calc(var(--st) + 52px); padding: 5px 14px; } #reyZona b { font-size: 15px; }
  body.capturado.enLobby:not(.tactil) #reyZona { top: calc(var(--st) + 78px); } }

/* la llegada del Rey a la plaza (js/rey.js): fuera todo el HUD, franjas de cine, relámpagos y el título al final */
body.cine #hud > :not(#tinte):not(#velo):not(#reyCine):not(#fundido) { visibility: hidden !important; }
#reyCine { position: absolute; inset: 0; display: none; pointer-events: none; overflow: hidden; }
body.cine #reyCine { display: block; }
#reyCine .franja { position: absolute; left: 0; right: 0; height: 11vh; background: #05020a; animation: rcFranja .7s ease-out both; }
#reyCine .arriba { top: 0; }
#reyCine .abajo { bottom: 0; }
@keyframes rcFranja { from { height: 0; } }
#reyCine .destello { position: absolute; inset: 0; background: #e6dcff; opacity: 0; }
#reyCine.rayo .destello { animation: rcRayo .8s ease-out; }
@keyframes rcRayo { 0% { opacity: 0; } 8% { opacity: .7; } 18% { opacity: .08; } 28% { opacity: .45; } 100% { opacity: 0; } }
#reyCine .rcTitulo { position: absolute; left: 16px; right: 16px; bottom: calc(11vh + 22px); display: flex; flex-direction: column; align-items: center;
  gap: 6px; text-align: center; opacity: 0; transform: translateY(16px); transition: opacity .7s, transform .7s; }
#reyCine.titulo .rcTitulo { opacity: 1; transform: none; }
#reyCine .rcTitulo b { font-size: clamp(26px, 5vw, 58px); font-weight: 900; color: #ffb04a; line-height: 1.05;
  text-shadow: 0 3px 0 #3a1460, 0 0 28px rgba(255,140,40,.55); }
#reyCine .rcTitulo span { font-size: clamp(14px, 2vw, 21px); font-weight: 800; color: #f3e6ff; text-shadow: 0 2px 6px rgba(0,0,0,.7); }
#reyCine small { position: absolute; right: 18px; bottom: 3.6vh; font-size: 13px; font-weight: 800; color: rgba(243,230,255,.6); }

/* Pasar la calabaza (js/calabaza.js): a oscuras por los murciélagos, el borde naranja si la llevas tú y las etiquetas */
#calNiebla { position: absolute; inset: 0; pointer-events: none; opacity: 0; background: radial-gradient(ellipse at 50% 55%, rgba(26,10,44,.5) 0%, rgba(12,4,22,.96) 62%); }
#calBorde { position: absolute; inset: 0; pointer-events: none; opacity: 0; box-shadow: inset 0 0 70px 14px rgba(255,190,70,.55); transition: opacity .25s; }
body.calTuya #calBorde { opacity: 1; animation: calLate .7s ease-in-out infinite alternate; }
@keyframes calLate { from { box-shadow: inset 0 0 50px 8px rgba(255,190,70,.4); } to { box-shadow: inset 0 0 90px 20px rgba(255,205,90,.65); } }
.hTiempo.calTuya { color: #ffb04a; }
.etiJugador.calLleva { background: #ff8a2a; color: #1d0e00; border-color: #ffd25a !important; }
.etiJugador.calApunta { box-shadow: 0 0 0 2px #fff, 0 0 14px rgba(255,255,255,.7); }
body.enCalabaza #hFantasma, body.enCalabaza #hVel { display: none; }
body.calFantasma #calBorde { opacity: 1; animation: none; box-shadow: inset 0 0 90px 18px rgba(214,200,255,.42); }
.etiJugador.calFant { background: rgba(232,222,252,.9); color: #2a1840; }
/* al reventar: la cámara te mira desde fuera (sin mira) y la ruleta dice en qué monstruo vuelves */
body.calBoom #mira { display: none; }
#calRuleta { position: absolute; left: 50%; top: 18%; transform: translate(-50%, 0) scale(.9); display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 18px 14px; border-radius: 18px; background: rgba(20,8,38,.82); border: 2px solid rgba(180,107,255,.7); box-shadow: 0 8px 30px rgba(0,0,0,.45);
  pointer-events: none; opacity: 0; transition: opacity .25s, transform .25s; max-width: calc(100% - 32px); z-index: 40; }
#calRuleta.ver { opacity: 1; transform: translate(-50%, 0) scale(1); }
#calRuleta b { font-size: 17px; font-weight: 900; color: #f3e6ff; text-align: center; }
#calRuleta .crVentana { position: relative; width: 288px; height: 96px; overflow: hidden; border-radius: 12px; background: rgba(255,255,255,.06); }
#calRuleta .crVentana::after { content: ''; position: absolute; left: 96px; top: 0; width: 96px; height: 96px; box-sizing: border-box; border: 3px solid #ffd25a; border-radius: 12px; }
#crTira { display: flex; height: 96px; will-change: transform; }
#crTira i { flex: 0 0 96px; font-style: normal; font-size: 58px; line-height: 96px; text-align: center; }
#calRuleta span, #calRuleta small { opacity: 0; transition: opacity .2s; text-align: center; }
#calRuleta span { font-size: 22px; font-weight: 900; color: #ffd25a; text-shadow: 0 2px 0 #3a1460; }
#calRuleta small { font-size: 13px; font-weight: 700; color: #e6dcff; }
#calRuleta.listo span, #calRuleta.listo small { opacity: 1; }
@media (max-width: 360px) { #calRuleta .crVentana { transform: scale(.85); margin: -7px 0; } }
/* en pantallas bajas (el móvil en horizontal), más pequeña y más arriba: si no, el aviso de debajo la tapaba */
@media (max-height: 520px) { #calRuleta { top: calc(var(--st) + 84px); transform-origin: 50% 0; transform: translate(-50%, 0) scale(.56); } #calRuleta.ver { transform: translate(-50%, 0) scale(.62); } }
#calEncuesta { position: fixed; inset: 0; z-index: 62; display: none; align-items: center; justify-content: center; background: rgba(14,6,30,.55); pointer-events: auto; padding: 12px; }
#calEncuesta.ver { display: flex; }
#calEncuesta .pcCaja { box-sizing: border-box; position: relative; max-width: 450px; width: 100%; max-height: calc(100% - 8px); overflow-y: auto; }   /* border-box: como #editTeclas */
#calEncuesta p { margin: 10px 0 6px; font-weight: 800; font-size: 15px; text-align: center; text-transform: none; letter-spacing: 0; }
.ceCerrar { position: absolute; top: 8px; right: 10px; width: 34px; height: 34px; border: 0; border-radius: 10px; background: rgba(255,255,255,.08); color: #fff; font-size: 16px; cursor: pointer; }
.ceCaras { display: flex; gap: 6px; justify-content: center; }
.ceCaras button { width: 54px; height: 54px; font-size: 30px; line-height: 1; border-radius: 12px; border: 2px solid transparent; background: rgba(255,255,255,.07); cursor: pointer; }
.ceOpciones { display: flex; flex-direction: column; gap: 6px; width: 100%; }
.ceOpciones button { padding: 10px 12px; border-radius: 10px; border: 2px solid transparent; background: rgba(255,255,255,.07); color: #fff; font: inherit; font-weight: 700; font-size: 14px; text-align: left; cursor: pointer; }
.ceCaras button.sel, .ceOpciones button.sel { border-color: var(--oro); background: rgba(255,210,90,.18); }
#ceEnviar:disabled { opacity: .45; cursor: default; }
@media (max-width: 380px) { .ceCaras button { width: 46px; height: 46px; font-size: 26px; } }
.jgDestacado.calabaza { border-color: #ff8a2a; }
.jgDestacado.calabaza:hover { border-color: #ffc23a; }

/* ---------------------------------------------------------- la intro del logo (js/introJuego.js; la escena, css/intro.css) */
#introJuego { position: fixed; inset: 0; z-index: 30; background: var(--tinta); cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; }
.grSaltar { position: absolute; right: calc(var(--sr) + 20px); bottom: calc(var(--sb) + 16px); pointer-events: none;
  color: rgba(244,246,255,.5); font-weight: 800; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; }
.grSaltar:empty { display: none; }
.grCarga { position: absolute; left: 50%; bottom: calc(var(--sb) + 12%); width: min(300px, 66vw); height: 8px; transform: translateX(-50%);
  background: rgba(255,255,255,.14); border-radius: 6px; overflow: hidden; opacity: 0; transition: opacity .4s ease; pointer-events: none; }
.grCarga.ver { opacity: 1; }
.grCarga i { display: block; height: 100%; width: 40%; background: var(--neon); border-radius: 6px; animation: carga 1.1s ease-in-out infinite; }

/* ---------------------------------------------------------- el grupo de amigos (js/grupo.js) */
#grupo, #ideas { background: rgba(12,10,26,.86); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); justify-content: flex-start; }
.grCaja { width: min(640px, 100%); align-items: stretch; text-align: left; }
.grCaja > .btn.grande { align-self: center; margin-top: 12px; }
.grSec { margin: 10px 0 0; font-size: 15px; font-weight: 900; color: #fff; }
.grMiembros { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.grMiembro { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,.05);
  border: 2px solid rgba(255,255,255,.1); min-width: 0; }
.grMiembro b { font-size: 15px; font-weight: 900; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grMiembro i { font-style: normal; font-size: 12px; font-weight: 700; color: #96a0c0; }
.grMiembro.ok { border-color: color-mix(in srgb, var(--lima) 60%, transparent); }
.grMiembro.ok i { color: var(--lima); }
.grMiembro.yo { background: rgba(56,225,255,.1); }
.grMiembro.vacio { opacity: .45; border-style: dashed; }
.grNivel { padding: 12px; border-radius: 14px; background: rgba(255,255,255,.04); border: 2px solid rgba(56,225,255,.25);
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px; justify-content: space-between; }
.grNivel p { margin: 0; flex: 1 1 220px; font-size: 14px; }
.grNivel .nota { margin: 0; }
.grInvitar { display: flex; gap: 8px; flex-wrap: wrap; }
.grConectados { display: flex; flex-direction: column; gap: 6px; max-height: 240px; overflow-y: auto; padding-right: 4px; }
.grConectado { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 6px 8px 6px 12px; border-radius: 10px;
  background: rgba(255,255,255,.05); }
.grConectado b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.grConectado .btn { margin: 0; }
#grSalir { align-self: center; margin-top: 14px; background: rgba(255,77,94,.16); border-color: rgba(255,77,94,.5); }
/* en la plaza, el aviso del grupo (css/ui.css) va debajo de la barra de arriba: si no, tapaba Retos, Récords y Ajustes */
body.enLobby #grupoAviso { top: calc(var(--st) + 64px); }
@media (max-width: 520px) { .grMiembros { grid-template-columns: 1fr; } }
.finGrupo { margin: 8px auto 0; width: min(360px, 100%); padding: 8px 10px; border-radius: 12px; background: rgba(255,255,255,.05);
  border: 2px solid rgba(56,225,255,.3); text-align: left; }
.finGrupo h4 { margin: 0 0 6px; font-size: 13px; font-weight: 900; color: var(--neon); text-transform: uppercase; letter-spacing: .04em; }
.fgFila { display: flex; align-items: center; gap: 8px; padding: 3px 0; font-size: 14px; font-weight: 800; }
.fgFila i { width: 22px; font-style: normal; color: #96a0c0; }
.fgFila b { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fgFila span { font-variant-numeric: tabular-nums; }
.fgFila.yo b { color: var(--lima); }
.fgFila.corre span { color: #96a0c0; font-weight: 700; }
.finGrupo .btn { margin: 6px 0 0; width: 100%; }
/* la fila del grupo encima de JUGAR (como en Roblox): círculos con la foto de cada uno y un «+» */
#grupoBarra { position: absolute; left: 50%; bottom: calc(var(--sb) + 128px); transform: translateX(-50%); z-index: 5;
  display: none; gap: 10px; align-items: flex-start; pointer-events: auto; }
body.enLobby #grupoBarra { display: flex; }
body.tour #grupoBarra, body.portada #grupoBarra, #grupoBarra.oculto { display: none !important; }
.gbCirculo { display: flex; flex-direction: column; align-items: center; gap: 3px; width: 58px; padding: 0; border: 0; background: none;
  cursor: pointer; font: inherit; color: #fff; }
.gbFoto { position: relative; width: 48px; height: 48px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  overflow: hidden; background: var(--c, #2a2350); border: 3px solid #fff; box-shadow: 0 4px 0 rgba(0,0,0,.35), 0 0 0 2px rgba(0,0,0,.35);
  font-size: 21px; font-weight: 900; color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.35); }
.gbFoto img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.gbCirculo i { max-width: 58px; font-style: normal; font-size: 10.5px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  text-shadow: 0 1px 2px rgba(0,0,0,.8); }
.gbCirculo.lider .gbFoto { border-color: var(--oro); }
.gbCirculo.lider .gbFoto::after { content: '👑'; position: absolute; top: -2px; right: -2px; font-size: 14px; text-shadow: none; }
.gbCirculo.listo .gbFoto { border-color: var(--lima); }
.gbCirculo.mas .gbFoto { background: rgba(18,16,40,.75); border: 3px dashed rgba(255,255,255,.75); font-size: 28px; color: var(--lima); }
.gbCirculo:hover .gbFoto { transform: translateY(-2px); }
.gbCirculo:active .gbFoto { transform: translateY(1px); }
body.tactil #grupoBarra { bottom: calc(var(--sb) + 108px); gap: 6px; }
/* al lado de JUGAR (js/grupo.js, posBarra): centrados con el botón, con los nombres debajo */
#grupoBarra.alLado { align-items: center; }
body.tactil .gbFoto { width: 40px; height: 40px; font-size: 17px; }
body.tactil .gbCirculo { width: 48px; }
/* el resultado con la tabla del grupo (js/grupo.js, pintaFin): fuera la tabla mundial, los parciales y la de la
   carrera (repetía a los del grupo), y la medalla más pequeña */
#fin.enGrupo #finMundial, #fin.enGrupo #finTabla, #fin.enGrupo #finSplits, #fin.enGrupo #finCarrera { display: none !important; }
#fin.enGrupo .finTarjeta .emblema { width: 54px; height: 54px; margin: 2px auto; }
#fin.enGrupo .finTarjeta .emblema::after { inset: 9px; }
#fin.enGrupo .finTarjeta .emblema b { font-size: 20px; }
#fin.enGrupo #finTiempo { font-size: clamp(38px, 6vw, 56px); }
/* «¡Todos listos! Empieza en 3, 2, 1» (js/grupo.js, cuentaAtras), encima de todo */
#grupoCuenta { position: absolute; left: 50%; top: 28%; transform: translate(-50%, -50%) scale(.9); z-index: 70; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 14px 28px 16px; border-radius: 20px;
  border: 3px solid var(--trazo); background: linear-gradient(180deg, rgba(38,42,85,.96), rgba(23,26,58,.96));
  box-shadow: 0 5px 0 var(--trazo), 0 14px 36px rgba(0,0,0,.45); opacity: 0; visibility: hidden; transition: opacity .18s, transform .18s, visibility .18s; }
#grupoCuenta.ver { opacity: 1; visibility: visible; transform: translate(-50%, -50%) scale(1); }
#grupoCuenta b { font-size: clamp(16px, 2.4vw, 22px); font-weight: 900; color: var(--lima); }
#grupoCuenta span { font-size: clamp(22px, 3.6vw, 34px); font-weight: 900; font-style: italic; color: #fff; font-variant-numeric: tabular-nums; }
/* el buzón de ideas (js/ideas.js) */
#lobIdeas { flex-direction: row; align-items: center; gap: 4px; white-space: nowrap; }
.idCats { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 10px; }
.idCampo { position: relative; margin: 0 0 10px; }
.idCampo textarea { width: 100%; box-sizing: border-box; min-height: 84px; resize: none; padding: 10px 12px 22px; border-radius: 12px;
  border: 3px solid var(--trazo); background: rgba(10,10,30,.55); color: #fff; font: inherit; font-size: 16px; font-weight: 700; }
.idCampo textarea:focus { outline: none; border-color: var(--neon); }
.idCampo small { position: absolute; right: 12px; bottom: 8px; font-size: 12px; opacity: .6; font-variant-numeric: tabular-nums; }
.idPronto { margin-top: 10px; }
.idMias { display: flex; flex-direction: column; gap: 6px; }
.idMia { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.05); text-align: left; }
.idMia b { flex: 1; font-size: 14px; font-weight: 700; word-break: break-word; }
.idMia i { font-style: normal; font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: rgba(255,255,255,.08); white-space: nowrap; }
.idMia i.elegida { background: var(--lima); color: #13210a; }
/* el buzón de ideas, fase 2: las pestañas y la votación */
/* las ideas hechas (js/ideas.js, pintaHechas) */
.idHechas { display: flex; flex-direction: column; gap: 6px; margin: 0 0 12px; }
.idHecha { display: flex; gap: 10px; align-items: center; padding: 9px 12px; border-radius: 12px; background: rgba(182,255,61,.07); border: 1px solid rgba(182,255,61,.22); text-align: left; }
.idHecha > i { font-style: normal; font-size: 24px; width: 32px; text-align: center; }
.idHecha span { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.idHecha b { font-size: 14px; font-weight: 800; }
.idHecha small { font-size: 12px; opacity: .75; font-weight: 700; }
.idHecha em { font-style: normal; font-size: 18px; }
.idTabs { flex-wrap: wrap; }
.idTabs { display: flex; gap: 8px; justify-content: center; margin: 0 0 12px; }
.idRetoTit { margin: 0 0 4px; font-size: 18px; font-weight: 900; color: var(--lima); }
.idQuedan { font-weight: 800; }
.idLogin { display: flex; flex-direction: column; align-items: center; gap: 6px; margin: 0 0 10px; }
.idVotos { display: flex; flex-direction: column; gap: 8px; margin: 8px 0 0; }
.idVoto { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 12px; background: rgba(255,255,255,.05);
  border: 2px solid transparent; text-align: left; }
.idVoto.mio { border-color: var(--oro); background: rgba(255,210,87,.08); }
.idVotoTxt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.idVotoTxt b { font-size: 15px; font-weight: 800; word-break: break-word; }
.idVotoTxt small { font-size: 12px; opacity: .65; }
.idBarra { display: block; height: 6px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; }
.idBarra i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--neon), var(--lima)); }
.idVoto em { font-style: normal; font-weight: 900; font-variant-numeric: tabular-nums; min-width: 40px; text-align: right; }
.idVoto .btn { white-space: nowrap; }
.idVacia { margin: 10px 0 14px; }
/* el buzón de ideas, fase 3: la cuenta atrás, la ganadora y su tarjeta en la plaza */
.idFin { font-weight: 800; }
.idGana { display: flex; flex-direction: column; gap: 3px; padding: 10px 12px; margin: 4px 0 8px; border-radius: 12px; border: 2px solid var(--oro);
  background: rgba(255,210,87,.1); text-align: left; }
.idGana b { font-size: 16px; font-weight: 900; color: var(--oro); }
.idGana small { font-size: 13px; opacity: .8; }
.idVoto.gana { border-color: var(--oro); box-shadow: 0 0 0 2px rgba(255,210,87,.25) inset; }
#idAnuncio { position: absolute; inset: 0; z-index: 65; display: none; align-items: center; justify-content: center; background: rgba(8,8,20,.55);
  backdrop-filter: blur(3px); pointer-events: auto; }
#idAnuncio.ver { display: flex; }
.idAnTarjeta { width: min(460px, 88vw); display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 20px 22px 18px; text-align: center;
  border-radius: 20px; border: 3px solid var(--trazo); background: linear-gradient(180deg, #2a2f63, #171a3d); box-shadow: 0 6px 0 var(--trazo), 0 18px 40px rgba(0,0,0,.5);
  animation: uiEntra .32s cubic-bezier(.2, 1.4, .4, 1) both; }
.idAnTarjeta small { font-size: 13px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; color: var(--lima); }
.idAnTarjeta b { font-size: clamp(18px, 3vw, 24px); font-weight: 900; color: #fff; word-break: break-word; }
.idAnTarjeta i { font-style: normal; font-size: 13px; font-weight: 800; opacity: .75; }
.idAnTarjeta p { margin: 2px 0 6px; font-size: 14px; font-weight: 700; opacity: .9; }
.novCarta small b.novMejN { font-weight: inherit; }
/* el buzón de ideas: los comentarios de cada idea */
.idVoto { flex-wrap: wrap; }
.idComBtn.on { filter: brightness(1.25); }
.idComs { margin: -4px 0 4px; padding: 8px 12px; border-radius: 0 0 12px 12px; background: rgba(255,255,255,.035); text-align: left; display: flex; flex-direction: column; gap: 5px; }
.idComs p { margin: 0; font-size: 13px; font-weight: 600; word-break: break-word; }
.idComs p b { color: var(--neon); font-weight: 900; margin-right: 4px; }
.idComNuevo { display: flex; gap: 6px; margin-top: 4px; }
.idComNuevo input { flex: 1; min-width: 0; padding: 7px 10px; border-radius: 10px; border: 2px solid var(--trazo); background: rgba(10,10,30,.55); color: #fff;
  font: inherit; font-size: 14px; font-weight: 700; }
.idComNuevo input:focus { outline: none; border-color: var(--neon); }
.idComs small.nota { font-size: 11px; }
/* la tarjeta de la cámara (v94): el interruptor para probar la tercera persona ahí mismo */
.novTercera { align-self: center; margin: 2px auto 0; display: block; }
@media (max-height: 450px) { .novTercera { margin: 0 auto; padding: 5px 12px; } #novMej5 .novForma { padding-top: 3px; padding-bottom: 3px; } #novMej5 .novInfFoto { max-height: 52px; } }
/* el filtro de palabras (js/filtro.js): el campo en rojo suave y el aviso en vez de la cuenta */
#ideas textarea.idMal, .idComNuevo input.idMal { border-color: #ff8a5c; }
#idCuenta.idMal { color: #ffb08a; font-weight: 800; }
/* la votación de ideas (2026-11-08): más ancha, en dos columnas, ordenada por votos y con trofeos para las tres primeras */
#ideasCaja.grCaja { width: min(980px, 100%); }
.idVotos { display: grid; grid-template-columns: repeat(auto-fill, minmax(400px, 1fr)); gap: 8px 10px; align-items: start; }
.idItem { display: flex; flex-direction: column; min-width: 0; }
.idPuesto { flex: 0 0 auto; min-width: 26px; display: flex; align-items: center; justify-content: center; gap: 2px; }
.idPuesto b { font-weight: 900; font-size: 16px; opacity: .6; font-variant-numeric: tabular-nums; }
.idPuesto svg { width: 30px; height: 30px; filter: drop-shadow(0 2px 2px rgba(0,0,0,.45)); }
.idPuesto.p1 b, .idPuesto.p2 b, .idPuesto.p3 b { font-size: 21px; opacity: 1; text-shadow: 0 2px 0 rgba(0,0,0,.45); }
.idPuesto.p1 b { color: #ffd23f; } .idPuesto.p2 b { color: #dfe6f2; } .idPuesto.p3 b { color: #e0905a; }
.idVoto.top1 { border-color: rgba(255,210,63,.75); background: linear-gradient(90deg, rgba(255,210,63,.16), rgba(255,255,255,.04)); }
.idVoto.top2 { border-color: rgba(223,230,242,.6); background: linear-gradient(90deg, rgba(223,230,242,.12), rgba(255,255,255,.04)); }
.idVoto.top3 { border-color: rgba(224,144,90,.6); background: linear-gradient(90deg, rgba(224,144,90,.13), rgba(255,255,255,.04)); }
@media (max-width: 760px) { .idVotos { grid-template-columns: 1fr; } }
/* el botón de la cámara en el móvil (2026-11-08): al lado de la pausa, en carrera y en la ciudad */
#btnCamara { position: absolute; top: calc(var(--st) + 10px); right: calc(var(--sr) + 58px); width: 38px; height: 38px; border-radius: 50%;
  background: rgba(0,0,0,.34); border: 1px solid rgba(255,255,255,.2); pointer-events: auto; display: none; align-items: center; justify-content: center;
  font-size: 18px; z-index: 5; }
body.tactil #hud.jugando #btnCamara { display: flex; }
@media (hover: none) and (pointer: coarse) { #hud.jugando #btnCamara { display: flex; } }
body.tour #btnCamara { display: none !important; }
/* ajustes por pestañas (2026-11-08) */
.ajTabs { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin: 0 0 12px; }
#ajustes .lista { width: min(520px, 100%); }
.rango input.ajNum { flex: 0 0 76px; width: 76px; padding: 5px 8px; border-radius: 10px; border: 2px solid rgba(255,255,255,.18);
  background: rgba(10,10,30,.55); color: #fff; font: inherit; font-weight: 900; text-align: center; accent-color: auto; }
.rango input.ajNum:focus { outline: none; border-color: var(--neon); }
.rango b { min-width: 52px; text-align: right; }
#ajGrafNota { font-size: 12px; opacity: .7; margin: 2px 4px 0; }
/* me gusta / no me gusta en los comentarios (2026-11-08) */
.idCom { display: flex; align-items: flex-start; gap: 8px; }
.idCom p { flex: 1; min-width: 0; }
.idCvs { display: flex; gap: 4px; flex: 0 0 auto; }
.idCv { display: inline-flex; align-items: center; gap: 3px; padding: 2px 7px; border-radius: 9px; border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.06); color: #fff; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; pointer-events: auto; }
.idCv i { font-style: normal; font-variant-numeric: tabular-nums; }
.idCv:hover:not([disabled]) { background: rgba(255,255,255,.14); }
.idCv.on { border-color: var(--neon); background: rgba(56,225,255,.2); }
.idCv.no.on { border-color: #ff9a6a; background: rgba(255,140,90,.2); }
.idCv[disabled] { opacity: .6; cursor: default; }
/* el editor del taller (js/editor.js, 2026-11-08) */
#editor { position: fixed; inset: 0; display: none; pointer-events: none; z-index: 40; }
#editor.ver { display: block; }
body.editando #hud, body.editando #barraLobby { display: none !important; }
body.editando canvas#lienzo { cursor: crosshair; }
#editor button, #editor input, #editor .edProp, #editor .edPaleta, #editor .edBarra { pointer-events: auto; }
.edBarra { position: absolute; top: calc(var(--st, 0px) + 10px); left: 50%; transform: translateX(-50%); display: flex; gap: 8px; align-items: center;
  background: rgba(12,10,26,.82); border: 2px solid rgba(255,255,255,.14); border-radius: 16px; padding: 6px 8px; }
.edPaleta { position: absolute; left: calc(var(--sl, 0px) + 10px); top: 50%; transform: translateY(-50%); display: flex; flex-direction: column; gap: 6px; }
.edPieza { display: flex; flex-direction: column; align-items: center; gap: 2px; width: 82px; padding: 8px 4px; border-radius: 14px; cursor: pointer;
  background: rgba(12,10,26,.84); border: 2px solid rgba(255,255,255,.16); color: #fff; font: inherit; font-weight: 800; font-size: 12px; }
.edPieza i { font-style: normal; font-size: 22px; line-height: 1; }
.edPieza:hover { border-color: rgba(127,246,255,.6); }
.edPieza.on { border-color: var(--neon); background: rgba(56,225,255,.22); box-shadow: 0 0 14px rgba(56,225,255,.35); }
.edProp { position: absolute; right: calc(var(--sr, 0px) + 10px); top: 70px; width: 280px; max-height: calc(100% - 150px); overflow-y: auto;
  display: flex; flex-direction: column; gap: 8px; background: rgba(12,10,26,.86); border: 2px solid rgba(255,255,255,.14); border-radius: 16px; padding: 12px; }
.edProp h3 { margin: 0; font-size: 16px; } .edProp h3 i { font-style: normal; }
.edDim { display: grid; grid-template-columns: 54px 1fr 54px; align-items: center; gap: 6px; font-size: 12px; font-weight: 800; }
.edDim input { accent-color: var(--neon); } .edDim b { text-align: right; font-variant-numeric: tabular-nums; }
.edColores { display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; }
.edColores button { aspect-ratio: 1; border-radius: 7px; border: 2px solid rgba(255,255,255,.2); background: var(--c); cursor: pointer; }
.edColores button.on { border-color: #fff; box-shadow: 0 0 0 2px var(--neon); }
.edFila { display: flex; flex-wrap: wrap; gap: 6px; }
.edFila .btn { flex: 1 1 auto; }
/* Neón y Se engancha: su estado (SÍ / NO) y, debajo, qué hace cada uno */
.edTog b { margin-left: 2px; }
.edTogNota { margin: 2px 2px 0; font-size: 11.5px; line-height: 1.35; color: #aeb6d4; }
.edMueve .btn { flex: 1 1 0; padding-left: 0; padding-right: 0; min-width: 0; }
.edAviso { position: absolute; left: 50%; transform: translateX(-50%); top: 64px; margin: 0; font-weight: 800; font-size: 14px; text-shadow: 0 2px 4px rgba(0,0,0,.6); white-space: nowrap; }
.edAyuda { position: absolute; left: 50%; transform: translateX(-50%); bottom: calc(var(--sb, 0px) + 10px); margin: 0; max-width: 92%; text-align: center;
  font-size: 12px; font-weight: 700; opacity: .85; background: rgba(12,10,26,.7); padding: 6px 12px; border-radius: 10px; }
.edMovil { display: none; position: absolute; left: calc(var(--sl, 0px) + 104px); bottom: calc(var(--sb, 0px) + 46px); grid-template-columns: repeat(4, 44px); gap: 6px; }
.edMovil button { width: 44px; height: 44px; border-radius: 12px; background: rgba(12,10,26,.8); border: 2px solid rgba(255,255,255,.2); color: #fff; font-size: 18px; pointer-events: auto; }
body.tactil .edMovil { display: grid; }
@media (max-height: 480px) {
  .edPieza { width: 64px; padding: 4px 2px; font-size: 10px; } .edPieza i { font-size: 18px; }
  .edProp { top: 56px; width: 240px; max-height: calc(100% - 110px); padding: 8px; gap: 6px; }
}
