/* =============================================================================
   naturalab.cl · portada · diseño "Observatorio" (octubre de 2026)
   -----------------------------------------------------------------------------
   Cielo profundo, paneles de vidrio con líneas de luz y la División Diamante
   a la vista desde la primera pantalla (pedido de Paola, 03-10-2026: el ranking
   es lo que anima a los estudiantes a seguir participando).

   Los bloques que ya funcionaban (buscador, tarjetas, carrusel, calendario,
   pastelito, personaje, medalla, top 10) conservan sus id y sus clases: los
   siguen manejando script.js e inicio.js. Aquí solo cambia cómo se ven y dónde
   van. Los colores y las letras son los de MARCA.md.
   ========================================================================== */

@font-face {
  font-family: "Montserrat";
  src: url("assets/fonts/montserrat-regular.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("assets/fonts/montserrat-medium.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("assets/fonts/montserrat-semibold.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Montserrat";
  src: url("assets/fonts/montserrat-bold.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}
/* Letra alta y angosta del título de la División (licencia libre, SIL OFL) */
@font-face {
  font-family: "Bebas Neue";
  src: url("assets/fonts/bebas-neue-regular.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap;
}
/* Letra redondeada de los títulos (licencia libre, SIL OFL) */
@font-face {
  font-family: "Fredoka";
  src: url("assets/fonts/fredoka-semibold.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Fredoka";
  src: url("assets/fonts/fredoka-bold.woff2") format("woff2");
  font-weight: 700; font-style: normal; font-display: swap;
}

:root {
  /* Cielo y vidrio */
  --noche: #0A0B1E;
  --noche-2: #10132E;
  --vidrio: rgba(14, 18, 46, .66);
  --linea: rgba(125, 225, 240, .28);
  --linea-suave: rgba(125, 225, 240, .16);

  /* Acentos del sitio */
  --cian: #55DDEA;
  --lima: #9FD442;
  --lima-claro: #CAED4D;
  --lima-tinta: #13260B;      /* texto sobre lima */
  --amarillo: #FFD23F;

  /* Texto */
  --texto: #EEF3FF;
  --suave: #AEB9D6;
  --tinta: #17233D;
  --tinta-suave: #4A5870;

  /* Pastelito, del diseño de Paola */
  --pastel-boton: #8A5D07;
  --pastel-marco: #F6ECE1;

  --fuente: "Montserrat", Arial, Helvetica, sans-serif;
  --fuente-titulo: "Fredoka", "Montserrat", Arial, sans-serif;

  --ancho: 1200px;
  --alto-cabecera: 86px;
  --sombra: 0 14px 36px rgba(0, 0, 0, .4);
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 104px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--fuente);
  font-size: 17px;
  line-height: 1.55;
  color: var(--texto);
  background: var(--noche);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }

.contenedor { width: min(100% - 2rem, var(--ancho)); margin-inline: auto; }

.visualmente-oculto {
  position: absolute !important; width: 1px; height: 1px; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.salto-contenido {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: #fff; color: var(--tinta); padding: .8rem 1.2rem;
  border-radius: 0 0 14px 0; font-weight: 600;
}
.salto-contenido:focus { left: 0; }

:where(a, button, input, select, summary):focus-visible {
  outline: 3px solid var(--amarillo); outline-offset: 3px;
}


/* ==========================================================================
   CABECERA · barra de vidrio que se queda arriba al bajar
   ========================================================================== */
.encabezado {
  position: sticky; top: 0; z-index: 50;
  height: var(--alto-cabecera); margin-bottom: calc(-1 * var(--alto-cabecera));
  padding-top: 12px;
  transition: background .25s ease;
}
/* Al bajar, un velo oscuro detrás de la barra para que no se mezcle con lo de abajo */
.encabezado--desplazado {
  background: linear-gradient(180deg, rgba(10, 11, 30, .92) 0%, rgba(10, 11, 30, .7) 70%, rgba(10, 11, 30, 0) 100%);
}

.encabezado__interior {
  position: relative;
  display: flex; align-items: center; gap: 1rem;
  width: min(100% - 2rem, var(--ancho)); min-height: 62px; margin-inline: auto;
  padding: .45rem .6rem;
  background: rgba(12, 15, 40, .72);
  border: 1px solid var(--linea); border-radius: 20px;
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 12px 34px rgba(0, 0, 0, .35);
}

/* El logo va sobre una placa blanca: se lee perfecto y no se recolorea */
.marca {
  display: flex; align-items: center; gap: .5rem; flex: none;
  padding: 4px 14px 4px 5px; border-radius: 14px; background: #fff;
  text-decoration: none;
}
.marca__pajaro { width: 42px; height: auto; flex: none; }
.marca__nombre { height: 28px; width: auto; flex: none; }

.navegacion { margin-left: auto; }
.navegacion__lista {
  list-style: none; margin: 0; padding: 0;
  display: flex; align-items: center; gap: .2rem;
}
.navegacion__enlace, .lupa-boton {
  display: inline-flex; align-items: center; gap: .45rem;
  min-height: 44px; padding: .5rem .85rem;
  background: transparent; color: #DCE6FF;
  border: 0; border-radius: 12px;
  font-family: var(--fuente); font-size: .92rem; font-weight: 600;
  text-decoration: none; white-space: nowrap; cursor: pointer;
  transition: background .2s ease, color .2s ease;
}
.navegacion__enlace:hover, .lupa-boton:hover { background: rgba(125, 225, 240, .12); color: #fff; }
.navegacion__enlace[aria-current="page"] {
  color: #fff; background: rgba(125, 225, 240, .14); box-shadow: inset 0 -2px 0 var(--cian);
}
.lupa-boton svg { color: var(--cian); }

/* "Mi perfil": el único botón lleno del menú */
.navegacion__enlace--perfil,
.navegacion__enlace--perfil[aria-current="page"] {
  margin-left: .35rem; padding-inline: 1rem;
  background: linear-gradient(180deg, var(--lima-claro), var(--lima));
  color: var(--lima-tinta); box-shadow: none;
}
.navegacion__enlace--perfil:hover { background: var(--lima-claro); color: var(--lima-tinta); }

/* Botón de menú para pantallas angostas */
.menu-boton {
  display: none; margin-left: auto;
  align-items: center; gap: .5rem;
  min-height: 46px; padding: .4rem 1rem;
  background: rgba(125, 225, 240, .12); border: 1px solid var(--linea); border-radius: 12px;
  font-family: var(--fuente); font-size: .95rem; font-weight: 600; color: #fff;
  cursor: pointer;
}
.menu-boton__barras { display: grid; gap: 4px; }
.menu-boton__barras span { display: block; width: 20px; height: 2.5px; background: currentColor; border-radius: 2px; }

/* Panel del buscador, que se abre con la lupa */
.panel-buscador { position: absolute; left: 0; right: 0; top: 100%; padding-top: .35rem; }
.buscador {
  display: block; padding: .9rem 1rem 1rem;
  background: rgba(12, 15, 40, .96);
  border: 1px solid var(--linea); border-radius: 18px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, .5);
}
.buscador__etiqueta { display: block; font-weight: 600; font-size: .95rem; margin-bottom: .45rem; color: #fff; }
.buscador__caja {
  display: flex; align-items: center; gap: .5rem;
  background: #fff; border-radius: 14px; padding: .3rem .4rem .3rem 1rem;
}
.buscador__lupa { color: #2F6FD8; display: grid; }
.buscador__campo {
  flex: 1; min-width: 0; border: 0; outline: 0;
  font-family: var(--fuente); font-size: 1.05rem; min-height: 44px; background: none; color: var(--tinta);
}
.buscador__cerrar {
  flex: none; width: 44px; height: 44px; border: 0; border-radius: 12px;
  background: #EEF2FB; color: var(--tinta); cursor: pointer; display: grid; place-items: center;
}
.buscador__resultado { margin: .5rem 0 0; font-size: .95rem; color: var(--lima-claro); font-weight: 600; }
.buscador__resultado:empty { display: none; }


/* ==========================================================================
   PORTADA · cielo, título, personaje y División Diamante
   ========================================================================== */
.portada {
  position: relative; isolation: isolate; overflow: hidden;
  padding: calc(var(--alto-cabecera) + 1.3rem) 0 3rem;
  background:
    linear-gradient(180deg, rgba(10, 11, 30, .62) 0%, rgba(10, 11, 30, .2) 38%, rgba(10, 11, 30, .86) 88%, var(--noche) 100%),
    linear-gradient(90deg, rgba(10, 11, 30, .78) 0%, rgba(10, 11, 30, .25) 55%, rgba(10, 11, 30, 0) 100%),
    url("assets/images/portada.webp") center 28% / cover no-repeat,
    var(--noche);
}
@media (max-width: 1400px) {
  .portada {
    background:
      linear-gradient(180deg, rgba(10, 11, 30, .62) 0%, rgba(10, 11, 30, .2) 38%, rgba(10, 11, 30, .86) 88%, var(--noche) 100%),
      linear-gradient(90deg, rgba(10, 11, 30, .78) 0%, rgba(10, 11, 30, .25) 55%, rgba(10, 11, 30, 0) 100%),
      url("assets/images/portada-1400.webp") center 28% / cover no-repeat,
      var(--noche);
  }
}
/* Cuadrícula tenue, como una carta de navegación */
.portada::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(125, 225, 240, .09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(125, 225, 240, .09) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 60% 70% at 60% 42%, #000 0%, transparent 72%);
          mask-image: radial-gradient(ellipse 60% 70% at 60% 42%, #000 0%, transparent 72%);
}

/* Tres columnas: texto · personaje · ranking */
.portada__rejilla {
  display: grid; grid-template-columns: minmax(0, 1fr) 300px 350px;
  gap: 1.6rem; align-items: center;
}
/* Si el ranking no llega (sin conexión al servidor), quedan dos columnas */
.portada__rejilla:has(> .top10[hidden]) { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); }

.portada__texto { min-width: 0; }

.portada__etiqueta {
  display: inline-flex; align-items: center; gap: .6rem;
  padding: .4rem .85rem; border-radius: 999px;
  border: 1px solid var(--linea); background: rgba(85, 221, 234, .09);
  font-size: .7rem; font-weight: 600; letter-spacing: .13em; text-transform: uppercase;
  color: var(--cian);
}
.portada__etiqueta::before {
  content: ""; width: 8px; height: 8px; border-radius: 50%; flex: none;
  background: var(--lima); box-shadow: 0 0 0 4px rgba(159, 212, 66, .22), 0 0 12px var(--lima);
}

.portada__titulo {
  margin-top: 1.1rem;
  font-family: var(--fuente-titulo); font-weight: 700;
  font-size: clamp(2.4rem, .9rem + 3.1vw, 3.45rem);
  line-height: 1.02; letter-spacing: -.01em; color: #fff;
  text-shadow: 0 6px 30px rgba(8, 10, 30, .6);
}
.portada__titulo span { display: inline-block; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; }
.portada__titulo .t-nat { background-image: linear-gradient(180deg, #DDF76A, #7FD46B); }
.portada__titulo .t-tec { background-image: linear-gradient(180deg, #8DEFF6, #7FA8FF); }

.portada__bajada { margin-top: 1rem; max-width: 34rem; font-size: 1.06rem; color: #DCE4F8; }

.portada__frase {
  display: flex; align-items: center; gap: .6rem;
  margin-top: 1.1rem; font-weight: 600; color: var(--amarillo);
}
.portada__frase svg { flex: none; }

.portada__acciones { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.portada__boton {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 52px; padding: .8rem 1.35rem; border-radius: 14px;
  font-weight: 700; font-size: 1rem; text-decoration: none;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}
.portada__boton:hover { transform: translateY(-2px); }
.portada__boton--principal {
  background: linear-gradient(180deg, var(--lima-claro), var(--lima));
  color: var(--lima-tinta); box-shadow: 0 12px 30px rgba(159, 212, 66, .32);
}
.portada__boton--linea {
  border: 1px solid rgba(255, 255, 255, .45); color: #fff;
  background: rgba(255, 255, 255, .08);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.portada__boton--linea:hover { background: rgba(255, 255, 255, .16); }

.portada__cifras { list-style: none; margin: 1.7rem 0 0; padding: 0; display: flex; gap: 1.4rem; }
.portada__cifras li { padding-left: 1.4rem; border-left: 1px solid var(--linea); }
.portada__cifras li:first-child { padding-left: 0; border-left: 0; }
.portada__cifras strong {
  display: block; font-family: var(--fuente-titulo); font-weight: 700;
  font-size: 1.9rem; line-height: 1; color: #fff;
}
.portada__cifras span { font-size: .8rem; font-weight: 500; color: var(--suave); }

/* ── El personaje del centro, dentro de su "radar" ── */
.escenario-columna { display: flex; flex-direction: column; align-items: center; gap: 1rem; min-width: 0; }
.escenario {
  position: relative; width: min(100%, 300px); min-height: 300px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
}
.escenario__orbita {
  position: absolute; left: 50%; top: 50%; width: 100%; aspect-ratio: 1;
  translate: -50% -50%; pointer-events: none;
}
.anillo { position: absolute; border-radius: 50%; }
.anillo--1 { inset: 0; border: 1px dashed rgba(125, 225, 240, .45); }
.anillo--2 { inset: 10%; border: 1px solid rgba(125, 225, 240, .22); }
.anillo--3 {
  inset: 20%;
  background: radial-gradient(circle, rgba(85, 221, 234, .26) 0%, rgba(85, 221, 234, .08) 45%, transparent 70%);
}
.anillo--1::before, .anillo--1::after {
  content: ""; position: absolute; width: 12px; height: 12px; border-radius: 50%;
}
.anillo--1::before { top: 13%; left: 14%; background: var(--lima); box-shadow: 0 0 14px var(--lima); }
.anillo--1::after { bottom: 9%; right: 21%; background: var(--amarillo); box-shadow: 0 0 14px var(--amarillo); }
@media (prefers-reduced-motion: no-preference) {
  .anillo--1 { animation: girar 60s linear infinite; }
}
@keyframes girar { to { rotate: 360deg; } }

.esquina { position: absolute; width: 22px; height: 22px; border: 2px solid var(--cian); opacity: .8; }
.esquina--1 { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.esquina--2 { top: 0; right: 0; border-left: 0; border-bottom: 0; }
.esquina--3 { bottom: 0; left: 0; border-right: 0; border-top: 0; }
.esquina--4 { bottom: 0; right: 0; border-left: 0; border-top: 0; }

/* Sin cuenta: la ilustración de Paola. Todo el conjunto es un solo enlace. */
.ilustracion {
  position: relative; display: flex; flex-direction: column; align-items: center;
  text-decoration: none; border-radius: 18px;
}
.ilustracion:focus-visible { outline: 3px solid #fff; outline-offset: 6px; }
.ilustracion__letrero {
  width: 62%; height: auto;
  /* En su dibujo el letrero es una calcomanía con borde blanco */
  filter: drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 2px #fff)
          drop-shadow(0 8px 14px rgba(0, 0, 0, .45));
  transition: transform .25s ease;
}
.ilustracion__figura {
  width: 55%; height: auto; margin-top: -.3rem;
  filter: drop-shadow(0 18px 26px rgba(0, 0, 0, .5));
  transition: transform .25s ease;
}
.ilustracion:hover .ilustracion__letrero { transform: scale(1.04) rotate(-1.5deg); }
.ilustracion:hover .ilustracion__figura { transform: translateY(-5px); }

/* Con cuenta: letrero, su personaje y el pedestal, uno bajo otro */
.propio { position: relative; display: flex; flex-direction: column; align-items: center; }

.escenario__letrero {
  display: inline-flex; align-items: center; gap: .55rem;
  margin: 0 0 .3rem; padding: .35rem .6rem;
  font-family: var(--fuente-titulo); font-weight: 700;
  font-size: 1.45rem; line-height: .95; text-transform: uppercase; text-align: left;
  color: var(--amarillo);
  -webkit-text-stroke: 2px #6B3A08; paint-order: stroke fill;
  text-shadow: 0 3px 0 #6B3A08;
  text-decoration: none;
}
.escenario__letrero-cara {
  width: 46px; height: 46px; flex: none; border-radius: 14px;
  background: #BDEBFA; display: grid; place-items: center; overflow: hidden;
  border: 2px solid #fff;
}
.escenario__letrero-cara svg { width: 100%; height: 100%; }

/* El personaje es un enlace: tocarlo lleva a su perfil */
.escenario__figura {
  position: relative; display: block;
  width: min(100%, 170px); aspect-ratio: 240 / 330;
  margin: 0 auto -28px; z-index: 2;
  text-decoration: none;
  filter: drop-shadow(0 12px 14px rgba(0, 0, 0, .4));
  transition: transform .25s ease;
}
.escenario__figura:hover { transform: translateY(-6px); }
.escenario__figura svg { width: 100%; height: 100%; }
@media (prefers-reduced-motion: no-preference) {
  .escenario__figura { animation: flotar 4.5s ease-in-out infinite; }
  .escenario__figura:hover { animation-play-state: paused; }
}
@keyframes flotar {
  0%, 100% { translate: 0 0; }
  50%      { translate: 0 -8px; }
}

/* Pedestal */
.escenario__pedestal { position: relative; width: min(100%, 210px); height: 50px; }
.escenario__pedestal::before {       /* cara de arriba */
  content: ""; position: absolute; inset: 0 0 14px;
  background: radial-gradient(ellipse at 50% 42%, #E9C7A6 0 48%, #D6A987 49% 100%);
  border-radius: 50%;
  box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .08);
}
.escenario__pedestal::after {        /* costado */
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 28px;
  background: linear-gradient(#C8987A, #A8785C);
  border-radius: 0 0 50% 50% / 0 0 100% 100%;
  z-index: -1;
}

.escenario__pie {
  margin: .7rem 0 0; font-size: .92rem; font-weight: 600;
  text-shadow: 0 2px 6px rgba(0, 0, 0, .7);
}

/* Su oro, bajo el personaje de la portada */
.escenario__oro {
  display: inline-flex; align-items: center; gap: .35rem;
  margin-left: .5rem; padding: .15rem .7rem; border-radius: 999px;
  background: #FFF6DB; color: #6B4B00; font-weight: 700; text-shadow: none;
}
.escenario__oro::before {
  content: ""; width: .8em; height: .8em; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #FFE49A, #E9A400 70%);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .1);
}

/* Aviso de recados sin leer, sobre el personaje de la portada */
.escenario__recados {
  display: inline-flex; align-items: center; gap: .45rem; margin: 0 0 .5rem;
  padding: .35rem .95rem; border-radius: 999px; text-decoration: none;
  background: #FFEDE8; color: #8A2A18; border: 2px solid #FFB2A0;
  font-weight: 700; font-size: .92rem; box-shadow: 0 4px 12px rgba(0, 0, 0, .25);
}
.escenario__recados::before {
  content: ""; width: .6rem; height: .6rem; border-radius: 50%; background: #E0452B;
  box-shadow: 0 0 0 3px rgba(224, 69, 43, .25);
}
.escenario__recados:hover { background: #fff; }

.escenario__nota {
  display: inline-flex; align-items: center; gap: .45rem;
  padding: .45rem .95rem; border-radius: 999px;
  background: rgba(12, 15, 40, .72); border: 1px solid var(--linea);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  font-size: .82rem; font-weight: 600; color: #fff; white-space: nowrap;
}
.escenario__nota svg { color: var(--amarillo); flex: none; }


/* ==========================================================================
   DIVISIÓN DIAMANTE · los 10 con más oro, siempre a la vista
   Mantiene lo que Paola aprobó el 24 y 25-09-2026: panel negro con borde
   dorado, título dorado en Bebas Neue y un color distinto para cada puesto.
   ========================================================================== */
.top10 {
  position: relative; overflow: hidden; isolation: isolate; min-width: 0;
  padding: .95rem .85rem 1rem; border-radius: 20px;
  background: #0B0B0B; border: 2px solid #E0B040;
  box-shadow: 0 18px 44px rgba(0, 0, 0, .55), 0 0 44px rgba(255, 183, 3, .2);
}
.top10::before {           /* franjas que dan sensación de velocidad */
  content: ""; position: absolute; inset: -40% -10%; z-index: -1; pointer-events: none;
  background: repeating-linear-gradient(115deg, rgba(255, 255, 255, .06) 0 14px, transparent 14px 42px);
}
.top10__titulo {
  text-align: center; text-transform: uppercase; line-height: .95;
  font-family: "Bebas Neue", "Fredoka", Impact, sans-serif; font-weight: 400;
  font-size: 2.35rem; letter-spacing: .05em;
  background: linear-gradient(180deg, #FFE066, #FFB703);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 2px 0 rgba(0, 0, 0, .5));
}
.top10__bajada { margin: .2rem 0 .7rem; text-align: center; font-size: .78rem; font-weight: 600; color: #F3E7C4; }
.top10__lista { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.top10__uno {
  display: flex; align-items: center; gap: .5rem; min-width: 0; height: 36px;
  padding: 0 .65rem 0 .4rem; border-radius: 11px; color: #fff;
  border: 1.5px solid rgba(255, 255, 255, .5);
}
.top10__puesto {
  flex: none; width: 1.4rem; text-align: center; line-height: 1;
  font-family: "Bebas Neue", Impact, sans-serif; font-size: 1.5rem;
  text-shadow: 0 2px 0 rgba(0, 0, 0, .25);
}
.top10__cara {
  flex: none; width: 28px; height: 28px; border-radius: 50%; overflow: hidden;
  background: #fff; border: 1.5px solid rgba(255, 255, 255, .9); display: grid; place-items: center;
}
.top10__cara svg { width: 100%; height: 100%; }
/* Nombre a la izquierda y oro a la derecha, en una sola línea */
.top10__quien { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: space-between; gap: .5rem; }
.top10__quien b { min-width: 0; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top10__oro { flex: none; display: flex; align-items: center; gap: .3rem; font-size: .8rem; font-weight: 700; white-space: nowrap; }
/* En la columna angosta del computador las palabras "de oro" no se dibujan
   (queda la moneda y el número) para que ningún nombre largo se corte.
   Siguen ahí para quien usa lector de pantalla. */
.top10__de {
  position: absolute; width: 1px; height: 1px; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.top10__oro::before {      /* la moneda de oro */
  content: ""; flex: none; width: .95rem; height: .95rem; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #FFF6B8, #FFC933 55%, #C98300);
  box-shadow: 0 0 0 1.5px #8A5D07;
}

/* Un color distinto para cada puesto: oro, plata y bronce, y luego colores vivos */
.top10__uno--1 { height: 46px; background: linear-gradient(135deg, #FFE066, #FFB703); color: #3B2A00; border-color: #fff; }
.top10__uno--1 .top10__puesto { font-size: 1.9rem; }
.top10__uno--1 .top10__cara { width: 34px; height: 34px; }
.top10__uno--1 .top10__quien b { font-size: .95rem; }
.top10__uno--2 { background: linear-gradient(135deg, #F3F4F6, #B8C0CC); color: #1F2937; }
.top10__uno--3 { background: linear-gradient(135deg, #F4B183, #D9772B); color: #2B1400; }
.top10__uno--4 { background: linear-gradient(135deg, #7C3AED, #5B21B6); }
.top10__uno--5 { background: linear-gradient(135deg, #0E7490, #155E75); }
.top10__uno--6 { background: linear-gradient(135deg, #DB2777, #9D174D); }
.top10__uno--7 { background: linear-gradient(135deg, #15803D, #166534); }
.top10__uno--8 { background: linear-gradient(135deg, #C2410C, #9A3412); }
.top10__uno--9 { background: linear-gradient(135deg, #2563EB, #1D4ED8); }
.top10__uno--10 { background: linear-gradient(135deg, #B91C1C, #7F1D1D); }
.top10__uno--1 .top10__oro::before, .top10__uno--2 .top10__oro::before, .top10__uno--3 .top10__oro::before { box-shadow: 0 0 0 1.5px #6B4500; }

@media (prefers-reduced-motion: no-preference) {
  .top10__uno--1 { animation: top10-brillo 2.4s ease-in-out infinite; }
}
@keyframes top10-brillo {
  0%, 100% { box-shadow: 0 0 0 0 rgba(255, 224, 102, 0); }
  50%      { box-shadow: 0 0 22px 4px rgba(255, 224, 102, .7); }
}


/* ==========================================================================
   ACCESOS DIRECTOS · cinco casillas de vidrio bajo la portada
   ========================================================================== */
.accesos {
  list-style: none; margin: 1.7rem 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: .8rem;
}
.acceso {
  display: flex; align-items: center; gap: .75rem;
  width: 100%; height: 100%; min-height: 72px; padding: .8rem .9rem;
  background: var(--vidrio); border: 1px solid var(--linea); border-radius: 16px;
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  font-family: var(--fuente); color: #fff; text-align: left; text-decoration: none; cursor: pointer;
  transition: transform .18s ease, border-color .18s ease, background .18s ease;
}
.acceso:hover { transform: translateY(-3px); border-color: var(--cian); background: rgba(20, 28, 66, .8); }
.acceso__icono {
  display: grid; place-items: center; width: 42px; height: 42px; flex: none;
  border-radius: 12px; background: rgba(85, 221, 234, .14); color: var(--cian);
}
.acceso__icono svg {
  width: 24px; height: 24px;
  fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round;
}
.acceso__icono--letra { font-family: var(--fuente-titulo); font-weight: 700; font-size: 1.4rem; line-height: 1; }
.acceso__texto { display: flex; flex-direction: column; min-width: 0; }
.acceso__nombre { font-weight: 600; font-size: .98rem; line-height: 1.2; }
.acceso__tipo { font-size: .72rem; font-weight: 500; color: var(--suave); }
.acceso--pronto .acceso__tipo { color: var(--amarillo); }


/* ==========================================================================
   SECCIONES · cada una con su número y su título a la vista
   ========================================================================== */
.seccion { padding: 3.6rem 0; }
.seccion--alterna {
  background: linear-gradient(180deg, var(--noche-2), var(--noche));
  border-top: 1px solid rgba(125, 225, 240, .12);
}
.seccion__cabeza { margin-bottom: 1.7rem; }
.seccion__numero {
  display: inline-flex; align-items: center; gap: .7rem;
  font-size: .72rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--cian);
}
.seccion__numero::after { content: ""; width: 64px; height: 1px; background: linear-gradient(90deg, var(--cian), transparent); }
.seccion__titulo {
  margin-top: .4rem; font-family: var(--fuente-titulo); font-weight: 700;
  font-size: clamp(1.7rem, 1.2rem + 1.6vw, 2.4rem); line-height: 1.1; color: #fff;
}
.seccion__bajada { margin-top: .35rem; max-width: 46rem; color: var(--suave); }


/* ==========================================================================
   TARJETAS (las arma script.js)
   ========================================================================== */
.tarjetas { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; }
.tarjetas--anchas { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.tarjeta {
  display: flex; flex-direction: column; overflow: hidden; min-width: 0;
  background: linear-gradient(180deg, rgba(27, 33, 76, .92), rgba(15, 19, 48, .96));
  border: 1px solid rgba(125, 225, 240, .22); border-radius: 18px;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.tarjeta:hover { transform: translateY(-4px); border-color: var(--cian); box-shadow: 0 18px 40px rgba(0, 0, 0, .45); }
.tarjeta__imagen {
  width: 100%; height: auto; aspect-ratio: 16 / 10;
  object-fit: cover; background: #16203F;
}
.tarjeta__cuerpo {
  flex: 1; display: flex; flex-direction: column; gap: .45rem; min-width: 0;
  padding: 1rem 1.1rem 1.15rem;
}
.tarjeta__titulo {
  font-family: var(--fuente-titulo); font-weight: 600; font-size: 1.22rem; line-height: 1.2; color: #fff;
  overflow-wrap: break-word; text-wrap: balance;
}
/* La descripción sigue en projects.js (el buscador y el carrusel la usan),
   pero en la tarjeta no se muestra: pedido de Paola del 13-09-2026. */
.tarjeta__descripcion { display: none; }
.tarjeta__nivel {
  display: flex; align-items: center; gap: .4rem; margin-bottom: .45rem;
  font-size: .86rem; color: var(--suave);
}
.tarjeta__nivel svg { flex: none; width: 17px; height: 17px; color: var(--cian); }
.tarjeta__estado { font-size: .8rem; font-weight: 700; color: var(--amarillo); }
.tarjeta__pie { margin-top: auto; }
.boton--tarjeta {
  width: 100%;
  display: grid; place-items: center;
  min-height: 44px; padding: .5rem 1rem;
  background: transparent; color: var(--lima-claro);
  border: 1px solid rgba(159, 212, 66, .6); border-radius: 12px;
  font-family: var(--fuente); font-size: .88rem; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; text-decoration: none; cursor: pointer;
  transition: background .18s ease, color .18s ease;
}
.tarjeta:hover .boton--tarjeta, .boton--tarjeta:hover { background: var(--lima); color: var(--lima-tinta); }

/* Juegos: tarjetas anchas, con la imagen al lado */
.tarjetas--anchas .tarjeta { flex-direction: row; }
.tarjetas--anchas .tarjeta__imagen { width: 44%; flex: none; aspect-ratio: auto; align-self: stretch; min-height: 170px; }
.tarjetas--anchas .tarjeta__cuerpo { justify-content: center; padding: 1.3rem; }
.tarjetas--anchas .tarjeta__pie { margin-top: .2rem; }
.tarjetas--anchas .boton--tarjeta { width: auto; display: inline-grid; padding-inline: 1.8rem; }

.sin-resultados { margin: 1.2rem 0 0; text-align: center; color: #fff; font-weight: 600; }
.aviso-noscript { color: var(--suave); }


/* ==========================================================================
   DESTACADOS · carrusel y Medalla de Honor
   ========================================================================== */
.destacados { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.destacados:has(> .panel--medalla[hidden]) { grid-template-columns: minmax(0, 1fr); }

.panel {
  min-width: 0;
  background: rgba(18, 23, 56, .78);
  border: 1px solid rgba(125, 225, 240, .22); border-radius: 20px;
  padding: clamp(1rem, 2vw, 1.5rem);
}
.panel__titulo { font-family: var(--fuente-titulo); font-weight: 700; font-size: 1.5rem; line-height: 1.15; color: #fff; }
.panel__bajada { margin: .2rem 0 1rem; font-size: .9rem; color: var(--suave); }

/* Carrusel (lo arma script.js): la pista se mueve de a 100% */
.carrusel { position: relative; display: flex; flex-direction: column; }
.carrusel__ventana { overflow: hidden; border-radius: 14px; }
.carrusel__pista {
  list-style: none; margin: 0; padding: 0; display: flex; align-items: center;
  transition: transform .55s ease;
}
.carrusel__diapositiva {
  flex: 0 0 100%; min-width: 0;
  display: grid; grid-template-columns: 1.2fr 1fr; align-items: center;
  gap: 1.3rem; padding: .2rem;
}
.carrusel__figura { margin: 0; border-radius: 14px; overflow: hidden; background: #16203F; }
.carrusel__figura img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.carrusel__titulo {
  margin: 0 0 .5rem; font-family: var(--fuente-titulo); font-weight: 700;
  font-size: clamp(1.25rem, 1rem + .8vw, 1.7rem); line-height: 1.15; color: #fff;
}
.carrusel__descripcion { margin: 0 0 1rem; font-size: .95rem; color: #DCE4F8; }
.carrusel__nivel {
  margin: 0 0 1rem; font-size: .84rem; color: var(--cian);
  display: flex; align-items: center; gap: .35rem;
}
.carrusel__accion .boton {
  display: inline-grid; place-items: center;
  min-height: 46px; padding: .5rem 1.3rem;
  background: linear-gradient(180deg, var(--lima-claro), var(--lima)); color: var(--lima-tinta);
  border: 0; border-radius: 12px;
  font-family: var(--fuente); font-size: .88rem; font-weight: 700; letter-spacing: .05em;
  text-decoration: none; cursor: pointer;
}
.carrusel__accion .boton:hover { background: var(--lima-claro); }

.carrusel__controles {
  display: flex; align-items: center; justify-content: center; gap: .6rem; margin-top: 1rem;
  flex-wrap: wrap;   /* con muchos proyectos, en celular el botón Pausar baja a otra línea */
}
.carrusel__flecha {
  width: 44px; height: 44px; border: 1px solid var(--linea); border-radius: 50%;
  background: rgba(125, 225, 240, .08); color: #fff; cursor: pointer; display: grid; place-items: center;
}
.carrusel__flecha:hover { background: rgba(125, 225, 240, .2); }
.carrusel__flecha svg { width: 22px; height: 22px; }
.carrusel__puntos { display: flex; gap: .4rem; }
.carrusel__punto {
  position: relative; width: 12px; height: 12px; padding: 0; border: 0; border-radius: 50%;
  background: #47507A; cursor: pointer;
}
.carrusel__punto[aria-current="true"] { background: var(--lima); width: 26px; border-radius: 999px; }
/* Área de toque cómoda sin agrandar el punto que se ve */
.carrusel__punto::after { content: ""; position: absolute; inset: -14px; }
.carrusel__pausa {
  min-height: 36px; padding: 0 .8rem; border: 1px solid var(--linea); border-radius: 999px;
  background: rgba(125, 225, 240, .08); color: #DCE6FF; cursor: pointer;
  font-family: var(--fuente); font-size: .78rem; font-weight: 600;
  display: inline-flex; align-items: center; gap: .35rem;
}

/* Medalla de Honor a la mejor historia */
.panel--medalla {
  border-color: rgba(255, 210, 63, .65);
  background: linear-gradient(180deg, rgba(70, 52, 10, .6) 0%, rgba(18, 23, 56, .85) 46%);
  box-shadow: 0 0 34px rgba(255, 183, 3, .14);
}
.panel--medalla .panel__titulo { color: var(--amarillo); }
.medalla-portada__quien { display: flex; align-items: center; gap: .6rem; margin-bottom: .6rem; }
.medalla-portada__quien b { color: #fff; }
.medalla-portada__cara {
  width: 54px; height: 54px; flex: none; border-radius: 50%; overflow: hidden;
  background: #fff; border: 2px solid #E9A400; display: grid; place-items: center;
}
.medalla-portada__cara svg { width: 100%; height: 100%; }
.medalla-portada__oro { display: block; font-size: .85rem; color: var(--amarillo); font-weight: 700; }
.medalla-portada__imagen { width: 100%; border-radius: 12px; display: block; margin: .5rem 0; }
.medalla-portada__titulo { margin: .5rem 0 .25rem; font-family: var(--fuente-titulo); font-size: 1.2rem; color: #fff; }
.medalla-portada__historia { margin: 0 0 .9rem; line-height: 1.5; color: #DCE4F8; font-size: .95rem; overflow-wrap: anywhere; }
.medalla-portada__ir {
  display: inline-flex; align-items: center; min-height: 44px; padding: .4em 1.2em;
  background: linear-gradient(180deg, var(--lima-claro), var(--lima)); color: var(--lima-tinta);
  border-radius: 12px; font-weight: 700; text-decoration: none;
}
.medalla-portada__ir:hover { background: var(--lima-claro); }


/* ==========================================================================
   CALENDARIO (lo arma script.js)
   ========================================================================== */
.calendario { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1.2rem; align-items: start; }
.calendario__panel, .calendario__detalle {
  min-width: 0; padding: 1.1rem;
  background: rgba(18, 23, 56, .78); border: 1px solid rgba(125, 225, 240, .22); border-radius: 20px;
}
.calendario__barra {
  display: flex; align-items: center; justify-content: space-between; gap: .4rem;
  margin-bottom: .7rem;
}
.calendario__mes { flex: 1; text-align: center; font-size: 1.1rem; font-weight: 700; text-transform: capitalize; color: #fff; }
.calendario__nav, .calendario__hoy {
  min-width: 40px; height: 40px; border: 1px solid var(--linea); border-radius: 999px;
  background: rgba(125, 225, 240, .08); color: #fff; cursor: pointer;
  display: grid; place-items: center; font-family: var(--fuente); font-size: .82rem; font-weight: 600;
}
.calendario__nav:hover, .calendario__hoy:hover { background: rgba(125, 225, 240, .2); }
.calendario__hoy { padding: 0 .8rem; }
.calendario__nav svg { width: 18px; height: 18px; }
.calendario__tabla { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: .92rem; text-align: center; }
.calendario__tabla th { font-weight: 700; color: var(--suave); padding: .3rem 0; }
.calendario__tabla abbr { text-decoration: none; }
.calendario__tabla td { padding: 3px; }

/* Días del calendario */
.calendario__dia {
  width: 100%; height: 40px;
  display: grid; place-items: center;
  border: 0; border-radius: 10px; background: transparent;
  font-family: var(--fuente); font-size: .92rem; color: var(--texto);
}
button.calendario__dia { cursor: pointer; }
button.calendario__dia:hover { filter: brightness(1.25); }
.calendario__dia--fuera { color: #55608A; }
.calendario__dia--feriado { background: rgba(255, 122, 100, .22); color: #FFB8AE; font-weight: 700; }
.calendario__dia--actividad { background: rgba(120, 165, 255, .24); color: #BCD3FF; font-weight: 700; }
.calendario__dia--hoy { box-shadow: inset 0 0 0 2px var(--lima); font-weight: 700; color: #fff; }

.calendario__leyenda {
  list-style: none; margin: .8rem 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: .3rem 1rem; font-size: .8rem; color: var(--suave);
}
.calendario__leyenda li { display: flex; align-items: center; gap: .35rem; }
.calendario__marca { width: 12px; height: 12px; border-radius: 4px; display: inline-block; }
.calendario__marca--feriado   { background: #FF9C8C; }
.calendario__marca--actividad { background: #8FB4FF; }
.calendario__marca--hoy       { box-shadow: inset 0 0 0 2px var(--lima); }

/* Fechas del mes, con el botón a Google Calendar */
.calendario__detalle-titulo { margin: 0 0 .7rem; font-size: 1.05rem; font-weight: 700; color: #fff; }
.calendario__lista { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; font-size: .9rem; }
.calendario__lista > li {
  display: flex; gap: .7rem; align-items: flex-start; min-width: 0;
  background: rgba(125, 225, 240, .06); border: 1px solid var(--linea-suave); border-radius: 14px;
  padding: .7rem;
}
.calendario__lista > li > div { flex: 1; min-width: 0; }
.calendario__fecha {
  flex: none; width: 46px; text-align: center; line-height: 1.1;
  border-radius: 10px; padding: .35rem 0;
}
.calendario__fecha--feriado   { background: rgba(255, 122, 100, .22); color: #FFB8AE; }
.calendario__fecha--actividad { background: rgba(120, 165, 255, .24); color: #BCD3FF; }
.calendario__fecha-numero { display: block; font-weight: 800; font-size: 1.1rem; }
.calendario__fecha-dia { display: block; font-size: .66rem; text-transform: uppercase; }
.calendario__evento-nombre { font-weight: 700; color: #fff; line-height: 1.3; }
.calendario__evento-nota { margin-top: .1rem; font-size: .82rem; color: var(--suave); }
.calendario__google {
  display: inline-flex; align-items: center; gap: .3rem; margin-top: .45rem;
  min-height: 32px; padding: .2rem .7rem;
  border: 1px solid rgba(125, 225, 240, .45); border-radius: 999px;
  font-size: .78rem; font-weight: 600; color: var(--cian); text-decoration: none;
  white-space: normal; text-align: left;
}
.calendario__google:hover { background: rgba(125, 225, 240, .12); }
.calendario__vacio { color: var(--suave); }


/* ==========================================================================
   CIERRE · logo grande y pastelito
   ========================================================================== */
.cierre { padding: 3.2rem 0 3.4rem; }
.cierre__fila { display: flex; align-items: center; justify-content: center; gap: 2.5rem; }

.marca-grande {
  display: flex; align-items: center; gap: .6rem; flex: none;
  pointer-events: none; user-select: none;
}
/* El círculo ya trae su borde verde: solo sombra. Los width/height del HTML
   le ganan a aspect-ratio, por eso el "auto" de cada uno. */
.marca-grande__circulo {
  width: clamp(80px, 9vw, 124px); height: auto;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .4));
}
/* Borde blanco alrededor de las letras: sobre el cielo oscuro el verde se pierde */
.marca-grande__texto {
  height: clamp(48px, 1rem + 4.2vw, 84px); width: auto;
  filter: drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 2px #fff)
          drop-shadow(0 6px 12px rgba(0, 0, 0, .4));
}

/* Pastelito (aportes voluntarios): tarjeta ancha con el pastel a la
   izquierda, el texto al medio y el botón a la derecha, como en su diseño */
.cafe {
  flex: 0 1 740px; min-width: 0;
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center; gap: .6rem 1.2rem;
  padding: .8rem 1.4rem .8rem 1rem;
  background: #fff; border-radius: 16px; color: var(--tinta);
  box-shadow: 0 0 0 5px var(--pastel-marco), var(--sombra);
}
.cafe__icono { width: 96px; }
.cafe__icono img {
  display: block; width: 100%; height: auto;
  filter: drop-shadow(0 6px 8px rgba(90, 30, 50, .18));
}
.cafe__titulo { font-size: 1.2rem; line-height: 1.3; font-weight: 700; color: var(--tinta); }
.cafe__parrafo { margin: .25rem 0 0; font-size: .8rem; line-height: 1.5; color: var(--tinta-suave); }
.cafe__boton {
  display: inline-flex; align-items: center; justify-content: center; text-align: center;
  min-height: 48px; padding: .55rem 1.3rem;
  background: var(--pastel-boton); color: #fff; border-radius: 8px;
  box-shadow: 0 5px 12px rgba(138, 93, 7, .35);
  font-size: .9rem; font-weight: 700; white-space: nowrap; text-decoration: none;
  transition: background .15s ease, transform .15s ease;
}
.cafe__boton:hover { background: #6F4A05; transform: translateY(-1px); }
.cafe__boton:focus-visible { outline: 3px solid var(--pastel-boton); outline-offset: 3px; }


/* ==========================================================================
   PIE
   ========================================================================== */
.pie {
  border-top: 1px solid rgba(125, 225, 240, .14);
  color: var(--suave); text-align: center; font-size: .88rem; padding: 1.4rem 1rem 1.8rem;
}
.pie a { color: var(--lima-claro); }


/* ==========================================================================
   AVISO "PRÓXIMAMENTE"
   ========================================================================== */
.aviso { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 1rem; }
.aviso__fondo { position: absolute; inset: 0; background: rgba(4, 6, 18, .72); }
.aviso__caja {
  position: relative; max-width: 440px; padding: 1.6rem; text-align: center;
  background: #141A40; border: 1px solid var(--linea); border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, .6);
}
.aviso__caja h2 { margin: 0 0 .5rem; font-family: var(--fuente-titulo); font-size: 1.4rem; line-height: 1.2; color: #fff; }
.aviso__caja p { margin: 0 0 1.1rem; color: #DCE4F8; }
.aviso__cerrar {
  min-height: 46px; padding: .5rem 1.6rem; border: 0; border-radius: 12px;
  background: linear-gradient(180deg, var(--lima-claro), var(--lima)); color: var(--lima-tinta);
  font-family: var(--fuente); font-weight: 700; font-size: 1rem; cursor: pointer;
}


/* ==========================================================================
   PANTALLAS MÁS ANGOSTAS
   ========================================================================== */

/* Notebook angosto y tablet acostada: el ranking baja a lo ancho, en dos
   columnas de 5, y sigue completo sin tener que abrir nada. */
@media (max-width: 1180px) {
  .navegacion__enlace, .lupa-boton { padding-inline: .6rem; font-size: .88rem; }
  .portada__rejilla,
  .portada__rejilla:has(> .top10[hidden]) { grid-template-columns: minmax(0, 1fr) 300px; }
  .top10 { grid-column: 1 / -1; padding: 1.1rem 1.1rem 1.2rem; }
  .top10__lista {
    grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(5, auto);
    grid-auto-flow: column; gap: 6px .7rem;
  }
  .top10__uno, .top10__uno--1 { height: 42px; }
  .top10__de { position: static; width: auto; height: auto; margin: 0; overflow: visible; clip: auto; }
  .cierre__fila { flex-direction: column-reverse; gap: 2rem; }
  .cafe { flex: none; width: min(100%, 740px); }
}

/* Desde aquí el menú se abre con el botón (script.js usa este mismo ancho) */
@media (max-width: 1080px) {
  .menu-boton { display: inline-flex; }
  .navegacion {
    position: absolute; left: 0; right: 0; top: calc(100% + 8px);
    padding: .7rem;
    background: rgba(12, 15, 40, .97); border: 1px solid var(--linea); border-radius: 18px;
    box-shadow: 0 18px 40px rgba(0, 0, 0, .5);
    display: none;
  }
  .navegacion[data-abierto="true"] { display: block; }
  .navegacion__lista { flex-direction: column; align-items: stretch; gap: .3rem; }
  .navegacion__enlace, .lupa-boton { width: 100%; justify-content: center; min-height: 48px; font-size: 1rem; }
  .navegacion__enlace--perfil { margin-left: 0; }

  .accesos { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .destacados { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 900px) {
  .portada__rejilla,
  .portada__rejilla:has(> .top10[hidden]) { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
  /* En una sola columna el ranking sube: va antes que el personaje, para que
     se alcance a ver apenas se abre la página. */
  .escenario-columna { order: 1; }
  .escenario { width: min(100%, 320px); min-height: 320px; }
  .tarjetas { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .portada {
    background:
      linear-gradient(180deg, rgba(10, 11, 30, .7) 0%, rgba(10, 11, 30, .3) 38%, rgba(10, 11, 30, .86) 88%, var(--noche) 100%),
      url("assets/images/portada-900.webp") center 28% / cover no-repeat,
      var(--noche);
  }
  .calendario { grid-template-columns: minmax(0, 1fr); }
  .marca-grande__circulo { width: 64px; }
  .marca-grande__texto { height: 42px; }
}

/* ── Teléfono ── */
@media (max-width: 620px) {
  .portada { padding-top: calc(var(--alto-cabecera) + .9rem); }
  .portada__bajada { font-size: 1rem; }
  .portada__acciones .portada__boton { flex: 1 1 100%; }
  .portada__cifras { gap: .9rem; }
  .portada__cifras li { padding-left: .9rem; }
  .portada__cifras strong { font-size: 1.6rem; }

  .top10 { padding: .95rem .8rem 1rem; }
  .top10__lista { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; grid-auto-flow: row; gap: 6px; }

  .accesos { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
  .accesos li:last-child { grid-column: 1 / -1; }
  .acceso { padding: .7rem; gap: .6rem; min-height: 64px; }
  .acceso__icono { width: 38px; height: 38px; }
  .acceso__nombre { font-size: .9rem; }

  .seccion { padding: 2.6rem 0; }
  .tarjetas, .tarjetas--anchas { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; }
  .tarjetas--anchas .tarjeta { flex-direction: column; }
  .tarjetas--anchas .tarjeta__imagen { width: 100%; aspect-ratio: 16 / 10; min-height: 0; align-self: auto; }
  .tarjeta__cuerpo, .tarjetas--anchas .tarjeta__cuerpo { padding: .8rem; justify-content: flex-start; }
  .tarjetas--anchas .tarjeta__pie { margin-top: auto; }
  .tarjeta__titulo { font-size: 1.02rem; }
  .tarjeta__nivel { font-size: .78rem; }
  .tarjeta__nivel svg { display: none; }
  .boton--tarjeta, .tarjetas--anchas .boton--tarjeta { width: 100%; display: grid; padding: .5rem; font-size: .82rem; letter-spacing: .04em; }

  .carrusel__diapositiva { grid-template-columns: minmax(0, 1fr); }
  .calendario__panel, .calendario__detalle { padding: .8rem; }
  .calendario__dia { height: 38px; }

  .cafe { grid-template-columns: 76px minmax(0, 1fr); padding: 1rem; }
  .cafe__icono { width: 76px; align-self: start; }
  .cafe__boton { grid-column: 1 / -1; white-space: normal; }
}

@media (max-width: 380px) {
  .marca__pajaro { width: 38px; }
  .marca__nombre { height: 24px; }
  .menu-boton__texto { display: none; }
  .portada__etiqueta { letter-spacing: .08em; }
  .marca-grande__texto { height: 36px; }
}

/* El ranking se queda arriba aunque la columna del personaje sea más alta. */
.portada__rejilla > .top10 { align-self: start; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
