/*
 * Estilos de los Shows Lumbre (formato `lumbre-show/1.0`): galería /shows y página del show.
 * Se cargan SÓLO en las vistas de /shows. La INTERFAZ reutiliza los tokens de app.css (paleta, radios,
 * espaciados, tipografías) — no define colores de tema propios, igual que tours.css. El ARTE del
 * escenario (cielos, charco, sol, vapor, nubes, lluvia…) sí usa colores literales: es ilustración
 * vectorial propia con licencia «Lumbre-Original» (cero fotos, cero librerías, cero peticiones), no
 * paleta de producto.
 *
 * Mobile-first: una columna y escenario alto en teléfono; controles ≥44px para táctil (§50/§51).
 * Sin JS la página YA es legible (elenco + índice + guion completo + resumen): nada de aquí es
 * necesario para leer; el escenario y la animación son mejora progresiva. El fondo del escenario es un
 * degradado; los elementos son divs posicionados por show.js con left/top/width/height en %.
 */

/* =========================================================== GALERÍA /shows */
.shows-gallery { padding-top: var(--space-6); }
.shows-head { display: flex; align-items: flex-end; justify-content: space-between; gap: var(--space-4); flex-wrap: wrap; }
.shows-head h1 { margin: 0 0 var(--space-2); font: 400 clamp(30px, 5vw, 46px)/1.1 var(--font-reading); }
.shows-head .lede { margin: 0; max-width: 62ch; color: var(--muted); line-height: 1.55; }
.shows-count { margin: 0; color: var(--muted); font-size: 15px; white-space: nowrap; }
.shows-count strong { color: var(--accent); font-size: 22px; font-weight: 700; margin-right: 4px; }

/* Barra de filtros en una sola fila; controles grandes para táctil. */
.show-filters { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: center; margin: var(--space-5) 0 var(--space-6); padding: var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.show-filter-search { flex: 1 1 220px; }
.show-filter-search input { width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--bg); color: var(--ink); font-size: 16px; }
.show-filter-select select, .show-filter-level { min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--bg); color: var(--ink); font-size: 15px; }
.show-filter-go { min-height: 44px; }
.show-filter-clear { color: var(--muted); text-decoration: underline; padding: 8px; }
.show-filter-clear:hover { color: var(--accent); }

/* Rejilla plana a ANCHO COMPLETO (auto-fit colapsa carriles vacíos). */
.show-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: var(--space-5); }
.show-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-sm); overflow: hidden; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.show-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--accent); }
.show-card-cover { position: relative; display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--accent-soft); }
.show-card-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.show-card-cover .generated-cover { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; color: var(--accent); }
.show-card-diff { position: absolute; top: 10px; left: 10px; padding: 3px 10px; border-radius: 999px; background: rgba(10, 14, 20, .72); color: #fff; font-size: 12px; font-weight: 600; letter-spacing: .02em; }
.show-card-body { display: flex; flex-direction: column; gap: var(--space-2); padding: var(--space-4); flex: 1 1 auto; }
.show-card-eyebrow { margin: 0; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); font-weight: 600; }
.show-card-body h3 { margin: 0; font: 400 20px/1.25 var(--font-reading); }
.show-card-body h3 a { color: var(--ink); text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.show-card-body h3 a:hover { color: var(--accent); }
.show-card-desc { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.show-card-meta { display: flex; flex-wrap: wrap; gap: 6px; margin: var(--space-2) 0 0; }
.show-card-meta .chip { font-size: 12px; }
.show-card-cta { margin-top: auto; }
.chip-tag { background: var(--bg); border-color: var(--line); color: var(--muted); }

.shows-empty { text-align: center; padding: var(--space-8) var(--space-4); border: 1px dashed var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.show-empty-icon { color: var(--accent); margin: 0 0 var(--space-3); }
.shows-empty h2 { margin: 0 0 var(--space-2); font: 400 22px/1.3 var(--font-reading); }
.shows-cta { margin-top: var(--space-7); text-align: center; }

/* ============================================================ PÁGINA DEL SHOW */
.show-shell { padding-top: var(--space-6); padding-bottom: var(--space-8); }

/* Portada (umbral del show) */
.show-cover { position: relative; display: flex; flex-direction: column; justify-content: flex-end; min-height: 40vh; padding: var(--space-7) var(--space-5); border-radius: var(--radius-lg); background: var(--accent-soft) center / cover no-repeat; overflow: hidden; }
.show-cover-veil { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 14, 20, .18), rgba(10, 14, 20, .74)); }
.show-cover-inner { position: relative; max-width: 760px; }
.show-cover h1 { margin: 0 0 var(--space-3); font: 400 clamp(26px, 5vw, 42px)/1.12 var(--font-reading); color: #fff; text-wrap: balance; }
.show-cover .eyebrow { color: rgba(255, 255, 255, .78); }
.show-cover .lede { color: rgba(255, 255, 255, .92); line-height: 1.6; margin: 0 0 var(--space-3); }
.show-chips { margin: 0; font-size: 13px; color: rgba(255, 255, 255, .82); }

/* Medidor de progreso (escenas vistas) */
.show-meter { position: relative; display: block; height: 8px; margin: var(--space-5) 0 var(--space-3); border-radius: 999px; background: var(--line); overflow: hidden; }
.show-meter-fill { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: inherit; transition: width .3s ease; }
.show-meter-label { position: absolute; right: 0; top: -22px; font-size: 12px; color: var(--muted); }

/* ---- Escenario (surface donde la runtime pinta cielo, elementos y coloca agentes) ---- */
.show-stage-wrap { margin-top: var(--space-4); }
.show-begin { text-align: center; margin: var(--space-4) 0; }
.show-stage { position: relative; width: 100%; aspect-ratio: 16 / 9; min-height: 340px; max-height: 55vh; border-radius: var(--radius-lg); overflow: hidden; border: 1px solid var(--line); background: var(--bg); box-shadow: var(--shadow-sm); contain: paint; }
.show-stage noscript { position: absolute; inset: auto 0 0 0; padding: var(--space-4); background: rgba(10, 14, 20, .72); color: #fff; text-align: center; }

/* ---- Modo embed (formmodal «Ver intro»): el documento mínimo OCUPA EXACTAMENTE el viewport del
   iframe — cero scroll interno y cero recortes: el escenario se estira/encoge con flex y medidor,
   subtítulo y controles quedan pegados a sus bordes. show.js relayouta al cambiar el tamaño. ---- */
.show-embed-body { margin: 0; padding: 0; background: var(--bg); height: 100vh; height: 100dvh; overflow: hidden; display: flex; flex-direction: column; }
.show-embed-body .show-shell { flex: 1; min-height: 0; display: flex; flex-direction: column; max-width: none; margin: 0; padding: 6px 8px 8px; }
.show-embed-body .show-stage-wrap { flex: 1; min-height: 0; margin: 0; padding: 0; display: flex; flex-direction: column; }
.show-embed-body .show-meter { margin: 0 0 6px; flex: none; }
.show-embed-body .show-stage { flex: 1; min-height: 0; max-height: none; aspect-ratio: auto; height: auto; width: 100%; border-radius: var(--radius-md); }
.show-embed-body .show-subtitle { margin-top: 6px; flex: none; }
.show-embed-body .show-controls { margin-top: 6px; padding: 6px; flex: none; }
.show-embed-body .show-begin { margin: 6px 0; flex: none; }

/* Fondos por estado del tiempo/naturaleza (degradados, cero imágenes). y% del manifiesto crece hacia
   arriba: el suelo (charco) vive abajo, el sol/nubes arriba. */
.show-bg-claro    { background: linear-gradient(180deg, #8fd0ff 0%, #cdeaff 55%, #eaf6ff 100%); }
.show-bg-soleado  { background: linear-gradient(180deg, #37b6ff 0%, #8ad4ff 45%, #ffe9a8 100%); }
.show-bg-nublado  { background: linear-gradient(180deg, #9fb3c9 0%, #c4d2e0 60%, #e6ebef 100%); }
.show-bg-lluvia   { background: linear-gradient(180deg, #5b6b7e 0%, #7e8da0 55%, #aebccb 100%); }
.show-bg-atardecer{ background: linear-gradient(180deg, #4b3a72 0%, #e8794f 55%, #ffcf8b 100%); }
.show-bg-noche    { background: linear-gradient(180deg, #0d1430 0%, #1b264f 55%, #2c3a66 100%); }
.show-bg-interior { background: linear-gradient(180deg, #efe6d6 0%, #e2d3bb 70%, #cbb896 100%); }

/* ---- Botón «Iniciar» centrado SOBRE el escenario: arrancar no debe exigir mover la pantalla ---- */
.show-play-overlay { position: absolute; inset: 0; z-index: 30; display: flex; align-items: center; justify-content: center; gap: 14px; flex-direction: column; width: auto; margin: 0; border: 0; background: rgba(10, 14, 20, .38); color: #fff; font: 700 clamp(19px, 2.6vw, 26px)/1 var(--font-ui); cursor: pointer; }
.show-play-ico { display: grid; place-items: center; width: 84px; height: 84px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 34px; box-shadow: 0 10px 30px rgba(191, 64, 24, .45); transition: transform .15s ease; }
.show-play-overlay:hover .show-play-ico { transform: scale(1.08); }

/* ---- Subtítulo: barra DEBAJO del escenario (no tapa nada) ---- */
.show-subtitle { margin: var(--space-2) 0 0; padding: 10px 16px; border-radius: var(--radius-md); background: var(--surface); border: 1px solid var(--line); color: var(--ink); font: 400 clamp(15px, 2.1vw, 19px)/1.45 var(--font-reading); text-align: center; min-height: 2.4em; }
.show-subtitle:empty { display: none; }
.show-sub-name { color: var(--accent); font-weight: 700; }

/* ---- Globo de habla propio de Lumbre (AL LADO del personaje, nunca sobre la cabeza: la utilería vive
   arriba — queja 2026-09-28 «el balloon tapa el show»). Traslúcida: si roza un dibujo, se ve a través. ---- */
.show-balloon { position: fixed; z-index: 10002; max-width: min(300px, 62vw); padding: 9px 13px; border-radius: 16px; border: 2px solid var(--accent); background: rgba(255, 255, 255, .86); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); color: #1d232b; font: 500 14.5px/1.35 var(--font-reading); box-shadow: 0 6px 22px rgba(0, 0, 0, .18); pointer-events: none; }
.show-balloon::after { content: ''; position: absolute; left: 50%; bottom: -12px; width: 18px; height: 18px; transform: translateX(-50%) rotate(45deg); background: rgba(255, 255, 255, .86); border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); }
/* globo a la DERECHA del personaje → cola apuntando a la izquierda */
.show-balloon.is-right::after { left: -10px; right: auto; top: 50%; bottom: auto; transform: translateY(-50%) rotate(45deg); border-right: 0; border-bottom: 2px solid var(--accent); border-left: 2px solid var(--accent); border-top: 0; }
/* globo a la IZQUIERDA del personaje → cola apuntando a la derecha */
.show-balloon.is-left::after { right: -10px; left: auto; top: 50%; bottom: auto; transform: translateY(-50%) rotate(45deg); border-left: 0; border-bottom: 0; border-right: 2px solid var(--accent); border-top: 2px solid var(--accent); }
/* apilado (móvil): el globo cae BAJO los pies → cola apuntando hacia arriba */
.show-balloon.is-stack::after { left: 50%; top: -10px; bottom: auto; transform: translateX(-50%) rotate(45deg); border-right: 2px solid var(--accent); border-top: 2px solid var(--accent); border-bottom: 0; border-left: 0; }
.show-balloon-name { display: block; color: var(--accent); font: 700 12px/1 var(--font-ui); text-transform: uppercase; letter-spacing: .07em; margin-bottom: 4px; }

/* ---- Barra de controles (≥44px táctil; show.js engancha los eventos) ---- */
.show-controls { display: flex; align-items: center; justify-content: center; gap: var(--space-3); flex-wrap: wrap; margin-top: var(--space-4); padding: var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-sm); }
.show-btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--bg); color: var(--ink); font: 600 15px/1 var(--font-ui); cursor: pointer; transition: border-color .15s ease, color .15s ease, background .15s ease; }
.show-btn:hover[aria-disabled="false"], .show-btn:not([aria-disabled="true"]):hover { border-color: var(--accent); color: var(--accent); }
.show-btn[aria-disabled="true"] { opacity: .45; cursor: default; }
.show-btn[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.show-btn-play { background: var(--accent); color: #fff; border-color: var(--accent); }
.show-btn-play:hover { background: var(--accent-hover); color: #fff; border-color: var(--accent-hover); }
.show-scene-nav { display: inline-flex; align-items: center; gap: var(--space-2); }
.show-btn-prev, .show-btn-next { width: 44px; justify-content: center; font-size: 22px; padding: 8px 0; }
.show-scene-pos { min-width: 56px; text-align: center; font: 600 14px/1 var(--font-ui); color: var(--muted); letter-spacing: .04em; }

/* ---- Región de participación: overlay CENTRADO sobre el escenario (el niño no mueve la pantalla) ---- */
.show-check { position: absolute; inset: 0; z-index: 28; display: grid; place-items: center; padding: var(--space-3); background: rgba(10, 14, 20, .52); backdrop-filter: blur(2px); }
.show-check[hidden] { display: none; }
.show-check-box { width: min(620px, 100%); max-height: 100%; overflow: auto; padding: var(--space-5); border: 2px solid var(--accent); border-radius: var(--radius-lg); background: var(--surface); box-shadow: 0 8px 32px rgba(0,0,0,.35); text-align: center; animation: showCheckIn .3s ease both; }
@keyframes showCheckIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.show-check-kind { margin: 0 0 var(--space-1); font: 700 12px/1 var(--font-ui); text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.show-check-prompt { margin: 0 0 var(--space-4); font: 400 clamp(18px, 2.6vw, 23px)/1.4 var(--font-reading); color: var(--ink); }
.show-check-options { display: grid; gap: var(--space-3); grid-template-columns: 1fr; }
@media (min-width: 560px) { .show-check-options { grid-template-columns: 1fr 1fr; } }
.show-opt { min-height: 52px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--bg); color: var(--ink); font: 500 16px/1.3 var(--font-ui); cursor: pointer; transition: border-color .15s ease, background .15s ease, transform .1s ease; }
.show-opt:hover { border-color: var(--accent); }
.show-opt:active { transform: scale(.99); }
.show-opt.is-correct { border-color: var(--ok); background: var(--ok-soft); color: var(--ok); font-weight: 700; }
.show-opt.is-wrong { border-color: var(--danger); background: var(--danger-soft); color: var(--danger); animation: showNo .4s ease; }
@keyframes showNo { 0%,100% { transform: translateX(0); } 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.show-check-feedback { margin: var(--space-4) 0 0; min-height: 1.4em; font: 400 16px/1.5 var(--font-reading); color: var(--ink); }

/* ---- Resumen final (la runtime lo pinta dentro de show-check) ---- */
.show-finale-box { padding: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); text-align: center; display: grid; gap: var(--space-4); }
.show-finale-box h2 { margin: 0; font: 400 22px/1.3 var(--font-reading); }
.show-finale-box p { margin: 0; color: var(--muted); line-height: 1.6; }
.show-replay-all { justify-self: center; }

/* =========================================================== ELENCO / ÍNDICE / GUION */
.show-cast { margin-top: var(--space-7); }
.show-cast h2, .show-finale h2, .show-related h2 { font: 400 19px/1.3 var(--font-reading); margin: 0 0 var(--space-3); }
.show-cast-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.show-cast-item { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3); border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--surface); }
.show-cast-swatch { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%; background: var(--accent); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line); }
.show-cast-item strong { color: var(--ink); }
.show-cast-role { margin-left: auto; }

.show-index { margin: var(--space-6) 0; }
.show-index ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; counter-reset: esc; }
.show-index-item a { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 40px; color: var(--ink); text-decoration: none; border-left: 2px solid var(--line); padding-left: var(--space-3); }
.show-index-item a:hover { color: var(--accent); border-left-color: var(--accent); }
.show-index-item.is-done a { opacity: .66; }
.show-index-item.is-done a::before { content: "✓"; font-weight: 700; color: var(--ok); }
.show-resume, .show-begin { margin: var(--space-4) 0 0; }

.show-script { margin-top: var(--space-6); border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--bg); padding: var(--space-3) var(--space-4); }
.show-script summary { cursor: pointer; font-weight: 600; color: var(--accent); min-height: 32px; }
.show-script-scenes { list-style: none; margin: var(--space-4) 0 0; padding: 0; display: grid; gap: var(--space-5); }
.show-script-scene { scroll-margin-top: var(--space-6); }
.show-script-scene h3 { margin: 0 0 var(--space-2); font: 400 18px/1.3 var(--font-reading); }
.show-line { margin: 0 0 var(--space-2); line-height: 1.6; }
.show-line strong { color: var(--accent); }
.show-script-check { margin: var(--space-3) 0 0; padding: var(--space-3); border-left: 3px solid var(--accent-soft); background: var(--surface); border-radius: var(--radius-sm); }
.show-script-check ul { margin: var(--space-2) 0 0; padding-left: var(--space-5); display: grid; gap: 4px; line-height: 1.5; }

.show-finale { margin-top: var(--space-7); padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-lg); background: var(--surface); }
.show-finale p { margin: 0; line-height: 1.6; color: var(--ink); }
.show-finale-next { margin: var(--space-4) 0 0; }

.show-related { margin-top: var(--space-7); }
.show-related-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-2); }
.show-related-link { display: inline-flex; align-items: center; gap: var(--space-2); color: var(--ink); text-decoration: none; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-md); }
.show-related-link:hover { border-color: var(--accent); color: var(--accent); }
.show-related-kind { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.show-related-reason { color: var(--muted); }

.show-credits { margin-top: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius-md); background: var(--bg); padding: var(--space-3) var(--space-4); }
.show-credits summary { cursor: pointer; font-weight: 600; color: var(--accent); min-height: 32px; }
.show-credits ul { margin: var(--space-3) 0 0; padding-left: var(--space-5); display: grid; gap: 6px; line-height: 1.5; }

.show-foot { margin-top: var(--space-6); border-top: 1px solid var(--line); padding-top: var(--space-4); }

/* =========================================================== SPRITE DEL AGENTE */
/* Agent._el ya es position:fixed con z-index alto (ClippyJS). Aquí sólo el halo sobre el escenario. */
.show-agent { filter: drop-shadow(0 6px 10px rgba(10, 14, 20, .28)); }

/* =========================================================== ELEMENTOS DE ESCENA */
/* Piezas vectoriales propias (licencia Lumbre-Original). Cada elemento es un div posicionado en %
   (izquierda/centro = el punto x%,y% del manifiesto). width/height los pone show.js. */
.show-el { position: absolute; transform: translate(var(--ax, -50%), var(--ay, -50%)); pointer-events: none; color: #fff; font: 700 clamp(13px, 2vw, 18px)/1.2 var(--font-ui); text-align: center; }
.show-el img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: var(--radius-sm); display: block; margin: 0 auto; }

/* Agua y clima */
.show-el-puddle { background: radial-gradient(ellipse at 50% 40%, rgba(90, 190, 245, .95), rgba(40, 130, 200, .85) 70%, rgba(40, 130, 200, .0) 100%); border-radius: 50% / 40%; box-shadow: inset 0 -4px 8px rgba(255, 255, 255, .35); }
.show-el-drop { width: auto; }
.show-el-drop::before { content: ""; display: block; width: 18px; height: 24px; margin: 0 auto; background: linear-gradient(180deg, #bfe9ff, #2f97e0); border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%; transform: rotate(45deg); box-shadow: inset -2px -2px 4px rgba(255, 255, 255, .5); }
.show-el-sun { border-radius: 50%; background: radial-gradient(circle at 50% 50%, #fff2b0 0%, #ffd23f 45%, #ff9d2f 70%, rgba(255, 157, 47, 0) 78%); box-shadow: 0 0 40px 10px rgba(255, 210, 80, .55); }
.show-el-vapor { background: radial-gradient(circle at 50% 70%, rgba(255, 255, 255, .75), rgba(255, 255, 255, .12) 60%, rgba(255, 255, 255, 0) 75%); border-radius: 50%; filter: blur(1px); }
.show-el-cloud { background: radial-gradient(circle at 30% 60%, #fff 0 28%, rgba(255, 255, 255, 0) 30%), radial-gradient(circle at 55% 45%, #fff 0 34%, rgba(255, 255, 255, 0) 36%), radial-gradient(circle at 75% 62%, #fff 0 26%, rgba(255, 255, 255, 0) 28%), linear-gradient(180deg, #f3f8ff, #d7e3f0); border-radius: 50% / 60%; box-shadow: 0 8px 16px rgba(40, 60, 90, .18); }
.show-el-rain { background: radial-gradient(circle at 50% 20%, #dfe8f2 0 40%, rgba(223, 232, 242, 0) 42%) no-repeat top / 100% 34%, repeating-linear-gradient(105deg, rgba(120, 170, 220, 0) 0 8px, rgba(120, 170, 220, .8) 8px 10px); border-radius: var(--radius-sm); }
.show-el-wind { height: 6px; background: repeating-linear-gradient(90deg, rgba(255, 255, 255, .0) 0 10px, rgba(255, 255, 255, .8) 10px 26px); border-radius: 999px; filter: blur(.3px); opacity: .9; }

/* Instrumentos y objetos de ciencia */
.show-el-thermometer { width: 16px; background: linear-gradient(180deg, #eef 0 55%, #ff5a4d 55%); border: 2px solid #fff; border-radius: 999px 999px 12px 12px; box-shadow: 0 0 0 1px var(--line); }
.show-el-thermometer::after { content: ""; position: absolute; left: 50%; bottom: -10px; transform: translateX(-50%); width: 24px; height: 24px; border-radius: 50%; background: #ff5a4d; border: 2px solid #fff; }
.show-el-mirror { background: linear-gradient(135deg, #d8f2ff 0 35%, #a7d8f0 35% 55%, #eaf7ff 55% 100%); border: 3px solid #cbd5e1; border-radius: var(--radius-md); box-shadow: inset 0 0 12px rgba(255, 255, 255, .8); }
.show-el-magnifier { width: 40px; height: 40px; border: 5px solid #7a5a2a; border-radius: 50%; background: rgba(200, 235, 255, .35); }
.show-el-magnifier::after { content: ""; position: absolute; right: -14px; bottom: -8px; width: 18px; height: 5px; background: #7a5a2a; border-radius: 3px; transform: rotate(45deg); }
.show-el-beaker { background: linear-gradient(180deg, rgba(200, 235, 255, .2) 0 40%, rgba(90, 190, 245, .85) 40%); clip-path: polygon(20% 0, 80% 0, 92% 100%, 8% 100%); border-top: 4px solid #cbd5e1; }
.show-el-ice { background: linear-gradient(135deg, #eafaff, #bfe4ff 60%, #9fd0f5); border: 2px solid #fff; border-radius: var(--radius-sm); box-shadow: inset 0 0 10px rgba(120, 180, 220, .5); }
.show-el-plant { width: auto; background: none; }
.show-el-plant::before { content: "🌱"; font-size: clamp(28px, 5vw, 48px); }

/* Marcas y símbolos */
.show-el-arrow { color: var(--accent); }
.show-el-arrow::before { content: "➜"; font-size: clamp(28px, 6vw, 56px); }
.show-el-label { background: rgba(10, 14, 20, .78); color: #fff; padding: 4px 12px; border-radius: 999px; font-weight: 600; white-space: nowrap; }
.show-el-sparkle { color: #ffd23f; }
.show-el-sparkle::before { content: "✦"; font-size: clamp(20px, 4vw, 36px); text-shadow: 0 0 10px rgba(255, 210, 63, .8); }
.show-el-moon { border-radius: 50%; background: radial-gradient(circle at 65% 40%, #f6f3d8 0 55%, rgba(246, 243, 216, 0) 56%); box-shadow: -10px 6px 0 0 #d9d4a8 inset, 0 0 24px rgba(246, 243, 216, .5); }
.show-el-star { color: #fff6c8; }
.show-el-star::before { content: "★"; font-size: clamp(16px, 3vw, 30px); text-shadow: 0 0 8px rgba(255, 246, 200, .9); }
.show-el-question { color: var(--accent); }
.show-el-question::before { content: "?"; font: 700 clamp(40px, 10vw, 96px)/1 var(--font-reading); }
.show-el-checkmark { color: var(--ok); }
.show-el-checkmark::before { content: "✓"; font: 700 clamp(36px, 8vw, 72px)/1 var(--font-ui); }
.show-el-crossmark { color: var(--danger); }
.show-el-crossmark::before { content: "✕"; font: 700 clamp(36px, 8vw, 72px)/1 var(--font-ui); }
.show-el-image { background: transparent; }
/* Fotos reales: recorte elptico orgánico (máscara radial) para que la imagen no parezca una estampa pegada. */
.show-el-image.is-photo { -webkit-mask-image: radial-gradient(ellipse at center, #000 62%, transparent 98%); mask-image: radial-gradient(ellipse at center, #000 62%, transparent 98%); }
.show-el-image.is-photo img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; filter: saturate(1.08) contrast(1.04); }
/* Dibujos de la biblioteca (@lib, SVG propios): nítidos y con proporción honesta, SIN máscara de foto ni
   fondo. El <img> llena el cuadro (show.js fija aspect-ratio desde `ar`); una sombra leve da volumen escénico. */
.show-el-image.is-drawn { background: transparent; }
.show-el-image.is-drawn img { width: 100%; height: 100%; object-fit: contain; border-radius: 0; filter: drop-shadow(0 6px 10px rgba(10, 20, 35, .28)); }

/* =========================================================== ANIMACIONES DE ELEMENTO */
/* FOCO DE EXPLICACIÓN (show.js point/face): lo señalado late y brilla mientras dura el turno. La animación
   pisa la del bucle propio durante el énfasis (es a propósito: el ojo del niño va a lo que se explica).
   El transform usa --ax/--ay para componerse con el anclaje, igual que los demás keyframes. */
.show-el.is-focus { animation: showFocus 1.05s ease-in-out infinite; }
.show-el.is-focus img { filter: drop-shadow(0 0 14px rgba(255, 214, 90, .95)) drop-shadow(0 6px 10px rgba(10, 20, 35, .28)); }
@keyframes showFocus {
    0%, 100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1); }
    50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1.08); }
}
.show-anim-shine  { animation: showShine 2.4s ease-in-out infinite; }
.show-anim-rise   { animation: showRise 3.2s ease-in-out infinite; }
.show-anim-drift  { animation: showDrift 6s ease-in-out infinite; }
.show-anim-fall   { animation: showFall 1.4s linear infinite; }
.show-anim-wobble { animation: showWobble 2s ease-in-out infinite; }
.show-anim-pulse  { animation: showPulse 2s ease-in-out infinite; }
.show-anim-grow   { animation: showGrow 2.6s ease-in-out infinite; }
.show-anim-twinkle{ animation: showTwinkle 1.8s ease-in-out infinite; }
.show-anim-sway   { animation: showSway 3s ease-in-out infinite; }
@keyframes showShine  { 0%,100% { filter: brightness(1); } 50% { filter: brightness(1.25); } }
@keyframes showRise   { 0% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateY(6px); opacity: .35; } 100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateY(-24px); opacity: 0; } }
@keyframes showDrift  { 0%,100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateX(-10px); } 50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateX(10px); } }
@keyframes showFall   { 0% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateY(-40%); opacity: 0; } 20% { opacity: 1; } 100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) translateY(60%); opacity: 0; } }
@keyframes showWobble { 0%,100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) rotate(-4deg); } 50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) rotate(4deg); } }
@keyframes showPulse  { 0%,100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1); } 50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1.12); } }
@keyframes showGrow   { 0%,100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1); } 50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1.28); } }
@keyframes showTwinkle{ 0%,100% { opacity: .35; } 50% { opacity: 1; } }
@keyframes showSway   { 0%,100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) rotate(-2deg); } 50% { transform: translate(var(--ax, -50%), var(--ay, -50%)) rotate(2deg); } }

/* REVEAL (act do:reveal, show.js): el elemento ENTRA con pop elástico — la mitad cortada aparece cuando el
   mago la nombra. Se quita la clase al terminar (show.js) para no pisar la animación en bucle del propio bulto. */
.show-el.is-pop { animation: showPop .55s cubic-bezier(.34, 1.56, .64, 1) both; }
@keyframes showPop {
    0% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(.2); opacity: 0; }
    60% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1.15); opacity: 1; }
    100% { transform: translate(var(--ax, -50%), var(--ay, -50%)) scale(1); opacity: 1; }
}

/* =========================================================== SHOWMANSHIP (el espectáculo) */
/* Confeti que lanza show.js al celebrar (createElement, cero innerHTML): cae con deriva y giro. */
.show-confetti { position: absolute; top: -6%; width: 10px; height: 14px; border-radius: 2px; opacity: .95; pointer-events: none; z-index: 4; animation-name: showConfetti; animation-timing-function: linear; animation-fill-mode: forwards; }
@keyframes showConfetti { 0% { transform: translate(-50%, 0) rotate(0deg); opacity: 1; } 100% { transform: translate(calc(-50% + var(--dx, 0px)), 640%) rotate(var(--rot, 540deg)); opacity: 0; } }

/* Telón que se abre al pulsar Iniciar (show.js lo crea y lo retira). */
.show-curtain { position: absolute; inset: 0; z-index: 6; display: flex; pointer-events: none; }
.show-curtain-panel { flex: 1 1 50%; height: 100%; background: repeating-linear-gradient(90deg, #7a1206 0 14px, #a3160a 14px 22px, #c0392b 22px 30px); box-shadow: inset 0 0 40px rgba(0, 0, 0, .5); transition: transform 1.1s cubic-bezier(.7, 0, .3, 1); }
.show-curtain-left { transform-origin: left center; }
.show-curtain-right { transform-origin: right center; }
.show-curtain.is-open .show-curtain-left { transform: translateX(-104%); }
.show-curtain.is-open .show-curtain-right { transform: translateX(104%); }

/* Elementos de escena de espectáculo (los usa el manifiesto si quiere decoración extra). */
.show-el-spotlight { background: radial-gradient(circle at 50% 0%, rgba(255, 244, 200, .85), rgba(255, 244, 200, .12) 55%, rgba(255, 244, 200, 0) 70%); clip-path: polygon(38% 0, 62% 0, 100% 100%, 0 100%); }
.show-el-balloon { border-radius: 50% 50% 50% 50% / 55% 55% 45% 45%; background: radial-gradient(circle at 35% 30%, #fff8, transparent 40%), var(--accent); box-shadow: inset -3px -4px 6px rgba(0, 0, 0, .2); }
.show-el-balloon::after { content: ""; position: absolute; left: 50%; top: 100%; width: 1px; height: 22px; background: rgba(255, 255, 255, .6); }
.show-el-trophy { color: #FFB000; }
.show-el-trophy::before { content: "🏆"; font-size: clamp(30px, 7vw, 64px); filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .3)); }
.show-el-curtain, .show-el-curtainLeft, .show-el-curtainRight { background: repeating-linear-gradient(90deg, #7a1206 0 12px, #a3160a 12px 20px, #c0392b 20px 26px); height: 100%; }
.show-el-curtainLeft { border-radius: 0 40% 40% 0; } .show-el-curtainRight { border-radius: 40% 0 0 40%; }
.show-el-confetti { background: conic-gradient(from 0deg, #BF4018, #FFB000, #138A72, #7557E8, #2f97e0, #BF4018); border-radius: 3px; }

/* Animaciones de espectáculo en bucle (respetan reduce). */
.show-anim-bounce { animation: showBounce 1.1s ease-in-out infinite; }
.show-anim-flash  { animation: showFlash 1.4s steps(2, jump-none) infinite; }
.show-anim-blackout { animation: showBlackout 3s ease-in-out infinite; }
.show-anim-curtain  { animation: showCurtainTug 2.6s ease-in-out infinite; }
@keyframes showBounce { 0%,100% { transform: translate(-50%, -50%) translateY(0); } 50% { transform: translate(-50%, -50%) translateY(-16px); } }
@keyframes showFlash  { 0% { opacity: .25; } 100% { opacity: 1; } }
@keyframes showBlackout { 0%,100% { opacity: .15; } 50% { opacity: .8; } }
@keyframes showCurtainTug { 0%,100% { transform: translate(-50%, -50%) scaleY(1); } 50% { transform: translate(-50%, -50%) scaleY(1.05); } }

/* Final apoteósico: marco de «bravo» sobre el resumen. */
.show-finale-box { position: relative; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft), var(--shadow-sm); }
.show-finale-box::before { content: "👏"; font-size: 34px; line-height: 1; }

/* =========================================================== MÓVIL Y MOVIMIENTO REDUCIDO */
@media (max-width: 640px) {
    .show-cover { min-height: 34vh; padding: var(--space-6) var(--space-4); }
    .show-stage { aspect-ratio: 4 / 3; min-height: 300px; }
    .show-controls { gap: var(--space-2); }
    .show-btn { padding: 8px 12px; font-size: 14px; }
    .show-scene-nav { order: 5; width: 100%; justify-content: center; margin-top: var(--space-2); }
}

/* El modo «reducir movimiento» del show (this.reduce) y la preferencia del sistema: todo quieto. */
.show-shell.is-reduced .show-el, .show-shell.is-reduced .show-check-box, .show-shell.is-reduced .show-confetti, .show-shell.is-reduced .show-curtain { animation: none !important; }
.show-shell.is-reduced .show-curtain { display: none; }
.show-shell.is-reduced .show-agent { transition: none; }
@media (prefers-reduced-motion: reduce) {
    .show-card, .show-meter-fill, .show-opt, .show-btn, .show-related-link, .show-index-item a { transition: none; }
    .show-el, .show-check-box, .show-confetti { animation: none !important; }
    .show-curtain { display: none; }
    .show-stage { contain: none; }
}
