/* PowerAdmin — GUÍA POWER · ESTILOS PROPIOS (T0) · guia-power.js
 * Portado de referencias-visuales/tutoriales/estructura-base-v1/prototipo_guia_power.html (tokens, medidas, textos) y de
 * las láminas 02 y 05. El velo, el foco y «Saltar» del HUD v367/v465 (power-ui.css, #powi-tuto) se REUSAN sin tocarlos:
 * acá solo van las capas del motor (#powi-tuto[data-gp], #gp-tip, #gp-toast, #gp-biblio) y las entradas a la Biblioteca.
 * Diferencias declaradas con el prototipo (reglas de la casa, UI_VISUAL §6):
 *   · botones de 36 / 30 px del prototipo → caja táctil de 44 px; la píldora visible conserva su alto en ::before (§6.4);
 *   · el prototipo mueve el foco y el aviso con left/top/width/height y `ease` → acá solo transform/opacity con las curvas
 *     oficiales (§6.1, §6.2): el foco se desliza y su medida cambia de una vez;
 *   · el latido del halo (box-shadow con ease-in-out) → la segunda sombra vive en ::after y late con opacity;
 *   · el buscador escribe a 16 px (14 px en el prototipo) para que iOS no haga zoom al tocarlo.
 * Solo transform / opacity / filter en transiciones (V-10). 44 px en la regla base de cada botón (V-33). min-width: 0 en
 * los hijos de flex. «Reducir movimiento»: sin rebote, sin latido, sin deslizamientos. */

/* ── tokens del prototipo (:root del prototipo, con prefijo) ─────────────────────────────────────────────────────── */
#powi-tuto[data-gp], #gp-tip, #gp-toast, #gp-biblio, #gp-halo-momento, .gp-campana-fila, #btn-pf-dial-guias, #gp-punto-tuerca {
  --gp-bg: #07060c; --gp-panel: #100e18; --gp-line: #2a2638; --gp-txt: #f1eff7; --gp-mut: #a39fb5;
  --gp-mashita: #ffb43a; --gp-pley: #38e1ff; --gp-rojo: #ff3b4a; --gp-oro: #ffd25a; --gp-verde: #2bff88;
  --gp-font: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --gp-pop: cubic-bezier(0.34, 1.56, 0.64, 1); --gp-deriva: cubic-bezier(0.16, 1, 0.3, 1);
  --c: var(--gp-mashita); --c-rgb: 255, 180, 58;
}
/* Las capas propias de la guía no heredan la tipografía de la página (body de la app: espaciado, rasgos y suavizado de cada skin):
 * en navegador el texto del HUD salía más angosto que en el prototipo con la misma fuente y el mismo tamaño (2026-11-14 08:14). */
#powi-tuto[data-gp], #gp-tip, #gp-toast, #gp-biblio {
  letter-spacing: normal; word-spacing: normal; font-feature-settings: normal; font-variation-settings: normal; font-kerning: auto;
  font-stretch: normal; text-rendering: auto; -webkit-font-smoothing: auto; text-transform: none;
}
#powi-tuto[data-gp][data-guia="pinguino"], #gp-tip[data-guia="pinguino"], #gp-toast[data-guia="pinguino"], #gp-halo-momento[data-guia="pinguino"] { --c: var(--gp-pley); --c-rgb: 56, 225, 255; }

/* ── L0 · bienvenida: velo y foco v367 con los valores del prototipo; HUD .hud del prototipo ───────────────────── */
#powi-tuto[data-gp] { --pt-c: 255, 180, 58; --pt-c2: 255, 210, 90; }
#powi-tuto[data-gp][data-guia="pinguino"] { --pt-c: 56, 225, 255; --pt-c2: 56, 225, 255; }
#powi-tuto[data-gp] .powi-tuto-foco {
  border-radius: 14px; box-shadow: 0 0 0 2000px rgba(4, 3, 10, 0.68);
  outline: 2px solid rgba(255, 255, 255, 0.85); outline-offset: 3px;
  transition: transform 380ms cubic-bezier(0.16, 1, 0.3, 1);
}
#powi-tuto[data-gp][data-interactivo="1"] .powi-tuto-foco,
#powi-tuto[data-gp][data-foco="multi"] .powi-tuto-foco { box-shadow: 0 0 0 2px rgba(var(--pt-c), 0.95), 0 0 18px rgba(var(--pt-c), 0.55); }
#powi-tuto[data-gp][data-interactivo="1"] .powi-tuto-velo,
#powi-tuto[data-gp][data-foco="multi"] .powi-tuto-velo,
#powi-tuto[data-gp][data-foco="no"] .powi-tuto-velo { background: rgba(4, 3, 10, 0.68); }
#powi-tuto[data-gp][data-interactivo="1"] .gp-hud { pointer-events: auto; }

/* «Saltar guía ✕» (prototipo .saltar: arriba a la derecha, 30 px de píldora; la caja táctil de v465 queda en 44+) */
#powi-tuto[data-gp] .powi-tuto-saltar-top {
  top: calc(39px + env(safe-area-inset-top)); right: max(0px, env(safe-area-inset-right));
  min-width: 68px; min-height: 68px; padding: 0 14px;
  font: 700 12px/30px var(--gp-font); letter-spacing: 0; text-transform: none; color: #fff; text-shadow: none;
}
#powi-tuto[data-gp] .powi-tuto-saltar-top::before {
  inset: 19px 2px; border-radius: 15px; background: rgba(10, 9, 18, 0.8); border: 1px solid rgba(255, 255, 255, 0.2); box-shadow: none;
}

#powi-tuto[data-gp] .gp-hud {
  position: absolute; left: 0; right: 0; margin: 0 auto; top: auto; bottom: calc(18px + env(safe-area-inset-bottom));   /* centrado sin translate(-50%): caja en píxeles enteros, como el .hud del prototipo (left/right 12) */
  width: min(520px, calc(100% - 24px)); box-sizing: border-box;
  display: flex; gap: 10px; align-items: flex-end; padding: 12px 12px 12px 10px;
  border-radius: 16px; color: var(--gp-txt); font: 15px/1.4 var(--gp-font); cursor: pointer;
  background: linear-gradient(180deg, rgba(22, 19, 34, 0.94), rgba(10, 9, 18, 0.96));
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 0 0 1px var(--c) inset, 0 0 18px -2px var(--c), 0 18px 40px rgba(0, 0, 0, 0.6);
}
#powi-tuto[data-gp][data-lado="arriba"] .gp-hud { top: calc(86px + env(safe-area-inset-top)); bottom: auto; }
#powi-tuto[data-gp][data-burst="a"] .gp-hud { animation: gpEntraA 220ms cubic-bezier(0.34, 1.56, 0.64, 1); }
#powi-tuto[data-gp][data-burst="b"] .gp-hud { animation: gpEntraB 220ms cubic-bezier(0.34, 1.56, 0.64, 1); }
#powi-tuto[data-gp][data-hecho="a"] .gp-hud { animation: gpHechoA 700ms cubic-bezier(0.16, 1, 0.3, 1); }
#powi-tuto[data-gp][data-hecho="b"] .gp-hud { animation: gpHechoB 700ms cubic-bezier(0.16, 1, 0.3, 1); }
/* Guion de Beat Surge: sobre su lobby, abajo a la izquierda (como el v367, el menú vive en el tercio derecho). */
#powi-tuto[data-gp][data-flujo="bso"] .gp-hud { left: max(12px, 2.4%); right: auto; margin: 0; width: min(56%, 500px); transform: none; top: auto; bottom: calc(10px + env(safe-area-inset-bottom)); }
#powi-tuto[data-gp][data-flujo="bso"][data-burst] .gp-hud { animation: none; }
#powi-tuto[data-gp] .gp-hud-cv {
  flex: 0 0 72px; width: 72px; height: 96px; margin-top: -34px; max-width: none;
  image-rendering: crisp-edges; image-rendering: pixelated;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.6));
}
#powi-tuto[data-gp] .gp-hud-cuerpo { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 8px; }
#powi-tuto[data-gp] .gp-hud-nom {
  align-self: flex-start; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  font: 800 11px/1 var(--gp-font); letter-spacing: 1.4px; text-transform: uppercase;
  color: #0b0910; background: var(--c); padding: 4px 8px; border-radius: 6px;
}
#powi-tuto[data-gp] .gp-hud-txt { margin: 0; font-size: 15px; line-height: 1.38; min-height: 42px; overflow-wrap: anywhere; }
#powi-tuto[data-gp] .gp-hud-cuenta { margin: 0; font: 800 13px/1.2 var(--gp-font); letter-spacing: 0.08em; color: var(--c); white-space: nowrap; }
#powi-tuto[data-gp] .gp-hud-cuenta[hidden] { display: none; }
#powi-tuto[data-gp] .gp-hud-pie { display: flex; align-items: center; gap: 8px; min-width: 0; }
#powi-tuto[data-gp] .gp-puntos { display: flex; gap: 5px; flex: 1; min-width: 0; }
#powi-tuto[data-gp] .gp-puntos i { flex: 0 0 7px; width: 7px; height: 7px; border-radius: 50%; background: #3a3550; }
#powi-tuto[data-gp] .gp-puntos i[data-on="1"] { background: var(--c); }

/* ── botones (prototipo .btn: píldora de 36 px; caja táctil de 44 px) ───────────────────────────────────────────── */
#powi-tuto[data-gp] .gp-btn, #gp-tip .gp-btn, #gp-biblio .gp-btn {
  position: relative; isolation: isolate; box-sizing: border-box; flex: 0 0 auto; min-width: 44px; min-height: 44px; margin: 0;
  display: inline-flex; align-items: center; justify-content: center; padding: 0 14px;
  border: 0; border-radius: 10px; background: transparent; color: var(--gp-mut);
  font: 700 13px/36px var(--gp-font); white-space: nowrap; text-align: center;
  cursor: pointer; user-select: none; touch-action: manipulation; -webkit-tap-highlight-color: transparent;
  transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#powi-tuto[data-gp] .gp-btn::before, #gp-tip .gp-btn::before, #gp-biblio .gp-btn::before {
  content: ''; position: absolute; left: 0; right: 0; top: 4px; bottom: 4px; z-index: -1; border-radius: 10px; background: transparent;
}
#powi-tuto[data-gp] .gp-hud-pie .gp-btn { margin: -4px 0; }   /* caja táctil 44 con la píldora de 36 del prototipo: el HUD no crece 8 px */
#powi-tuto[data-gp] .gp-btn-si, #gp-tip .gp-btn-si, #gp-biblio .gp-btn-si { color: #0b0910; }
#powi-tuto[data-gp] .gp-btn-si::before, #gp-tip .gp-btn-si::before, #gp-biblio .gp-btn-si::before { background: var(--c); }
#gp-biblio .gp-btn-si[data-guia="pinguino"] { --c: var(--gp-pley); }
#powi-tuto[data-gp] .gp-btn[hidden], #gp-tip .gp-btn[hidden] { display: none; }
#powi-tuto[data-gp] .gp-btn:active, #gp-tip .gp-btn:active, #gp-biblio .gp-btn:active { transform: scale(0.95); }
#powi-tuto[data-gp] .gp-btn:focus-visible, #gp-tip .gp-btn:focus-visible, #gp-biblio button:focus-visible, #gp-biblio input:focus-visible { outline: 2px solid var(--c); outline-offset: 2px; }

/* ── L1 · tip de sección: halo + burbuja, sin velo ──────────────────────────────────────────────────────────────── */
#gp-tip { position: fixed; inset: 0; z-index: 2147482900; pointer-events: none; color: var(--gp-txt); font: 15px/1.4 var(--gp-font); }
#gp-tip[hidden] { display: none !important; }
#gp-tip .gp-halo, #gp-halo-momento {
  position: absolute; left: 0; top: 0; width: 100px; height: 100px; border-radius: 18px; pointer-events: none; transform-origin: 0 0;
  box-shadow: 0 0 0 2px var(--c), 0 0 22px 4px rgba(var(--c-rgb), 0.55);
}
#gp-halo-momento { position: fixed; z-index: 2147482940; }
#gp-halo-momento[hidden] { display: none !important; }
#gp-tip[data-foco="no"] .gp-halo { opacity: 0; }
#gp-tip .gp-halo::after, #gp-halo-momento::after {
  content: ''; position: absolute; inset: 0; border-radius: inherit; opacity: 0;
  box-shadow: 0 0 0 2px var(--c), 0 0 34px 8px rgba(var(--c-rgb), 0.35);
  animation: gpLatir 1600ms cubic-bezier(0.16, 1, 0.3, 1) infinite;
}
#gp-tip .gp-burbuja {
  position: absolute; left: 0; top: 0; box-sizing: border-box; max-width: min(250px, calc(100vw - 24px));
  display: flex; gap: 8px; align-items: center; padding: 9px 11px 9px 7px;
  border-radius: 12px; background: rgba(14, 12, 24, 0.95); border: 1px solid var(--c);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55); font-size: 13.5px; line-height: 1.3; pointer-events: auto;
  opacity: 0; transform: var(--gp-pos, translate(0, 0)) translateY(6px);
  transition: opacity 250ms cubic-bezier(0.16, 1, 0.3, 1), transform 250ms cubic-bezier(0.16, 1, 0.3, 1);
}
#gp-tip .gp-burbuja[data-ver="1"] { opacity: 1; transform: var(--gp-pos, translate(0, 0)); }
#gp-tip .gp-burbuja canvas { flex: 0 0 36px; width: 36px; height: 48px; image-rendering: crisp-edges; image-rendering: pixelated; }
#gp-tip .gp-burbuja-cuerpo { min-width: 0; overflow-wrap: anywhere; }
#gp-tip .gp-burbuja small { display: block; color: var(--c); font-weight: 800; font-size: 10px; letter-spacing: 1px; }
#gp-tip .gp-burbuja::after {
  content: ''; position: absolute; left: 24px; bottom: -7px; width: 12px; height: 12px;
  background: rgba(14, 12, 24, 0.95); border-right: 1px solid var(--c); border-bottom: 1px solid var(--c); transform: rotate(45deg);
}
#gp-tip .gp-burbuja[data-cola="arriba"]::after { bottom: auto; top: -7px; border: 0; border-left: 1px solid var(--c); border-top: 1px solid var(--c); }
#gp-tip .gp-tip-sig { position: absolute; left: 50%; top: 0; pointer-events: auto; transform: var(--gp-pos, translate(-50%, 0)); }
#gp-tip .gp-tip-sig::before { box-shadow: 0 0 14px var(--c); }
#gp-tip .gp-tip-sig:active { transform: var(--gp-pos, translate(-50%, 0)) scale(0.95); }
#gp-tip .gp-tip-sig { transition: none; }   /* la caja táctil no se desliza cuando el motor la recoloca (--gp-pos): quieta de inmediato */
/* power-ui.css:9778 (body.power-hud button:active) pone `scale: .95` a TODO botón al apretarlo. La propiedad `scale` se compone
 * ENCIMA del transform que ubica a «Siguiente» (translate de ~510 px desde su origen): al bajar el dedo la caja saltaba ~25 px y el
 * pointerup caía en el hábitat (#power-companion-box), así que el clic nunca llegaba (medido en navegador 2026-11-14 08:11; mismo
 * caso que beat-surge-prisma-lobby.css:38). Con id en el selector gana sin depender del orden; el «apretado» lo da :active. */
#gp-tip button, #gp-tip button:active, #powi-tuto[data-gp] button, #powi-tuto[data-gp] button:active, #gp-biblio button, #gp-biblio button:active { scale: none; translate: none; }

/* ── L2 · momento justo (prototipo .toast) ──────────────────────────────────────────────────────────────────────── */
#gp-toast {
  position: fixed; left: 50%; top: calc(58px + env(safe-area-inset-top)); z-index: 2147482950;
  width: min(520px, calc(100% - 24px)); box-sizing: border-box; min-height: 44px;
  display: flex; gap: 10px; align-items: center; padding: 8px 12px 8px 8px;
  border-radius: 14px; background: rgba(14, 12, 24, 0.96); border: 1px solid var(--gp-oro);
  box-shadow: 0 0 16px -2px var(--gp-oro), 0 12px 30px rgba(0, 0, 0, 0.6);
  color: var(--gp-txt); font: 15px/1.4 var(--gp-font); cursor: pointer;
  transform: translate(-50%, calc(-100% - 80px)); opacity: 0;
  transition: transform 450ms cubic-bezier(0.34, 1.56, 0.64, 1), opacity 200ms cubic-bezier(0.16, 1, 0.3, 1);
}
#gp-toast[hidden] { display: none !important; }
#gp-toast[data-ver="1"] { transform: translate(-50%, 0); opacity: 1; }
#gp-toast canvas { flex: 0 0 42px; width: 42px; height: 56px; image-rendering: crisp-edges; image-rendering: pixelated; }
#gp-toast .gp-toast-cuerpo { min-width: 0; overflow-wrap: anywhere; }
#gp-toast b { display: block; font-size: 10px; letter-spacing: 1.2px; color: var(--gp-oro); }

/* ── L3 · Biblioteca de guías (prototipo .hoja) ─────────────────────────────────────────────────────────────────── */
#gp-biblio { position: fixed; inset: 0; z-index: 2147482800; color: var(--gp-txt); font: 15px/1.4 var(--gp-font); --c: var(--gp-pley); --c-rgb: 56, 225, 255; }
#gp-biblio[hidden] { display: none !important; }
#gp-biblio .gp-biblio-fondo { position: absolute; inset: 0; background: transparent; }
#gp-biblio .gp-hoja {
  position: absolute; left: 0; right: 0; bottom: 0; height: 78%; max-width: 560px; margin: 0 auto; box-sizing: border-box;
  display: flex; flex-direction: column; padding-bottom: env(safe-area-inset-bottom);
  border-radius: 22px 22px 0 0; background: linear-gradient(180deg, #141221, #0b0a13);
  border-top: 1px solid rgba(255, 255, 255, 0.12); box-shadow: 0 -20px 50px rgba(0, 0, 0, 0.6);
  transform: translateY(100%); transition: transform 380ms cubic-bezier(0.16, 1, 0.3, 1);
}
#gp-biblio[data-ver="1"] .gp-hoja { transform: none; }   /* quieta = sin transform (como el .hoja del prototipo): el texto se suaviza igual que fuera de una capa */
#gp-biblio .gp-hoja-cab { display: flex; align-items: center; gap: 10px; padding: 14px 16px 8px; min-width: 0; }
#gp-biblio .gp-hoja-cab canvas { flex: 0 0 42px; width: 42px; height: 56px; image-rendering: crisp-edges; image-rendering: pixelated; }
#gp-biblio .gp-hoja-tit { flex: 1; min-width: 0; }
#gp-biblio .gp-hoja-tit h3 { margin: 0; font: 700 17px/1.4 var(--gp-font); letter-spacing: 0.6px; text-transform: none; color: var(--gp-txt); }   /* h3 del prototipo: negrita del navegador (700), no 800 */
#gp-biblio .gp-hoja-tit p { margin: 0; font: 12px/1.4 var(--gp-font); letter-spacing: 0; color: var(--gp-mut); }
#gp-biblio .gp-x {
  flex: 0 0 44px; width: 44px; height: 44px; margin: 0 -3px 0 auto; padding: 0; border: 0; border-radius: 10px;   /* -3: el .btn.no del prototipo mide ~38 px; así el ✕ cae en el mismo centro con caja de 44 */
  background: transparent; color: var(--gp-mut); font: 700 13px/44px var(--gp-font); cursor: pointer; touch-action: manipulation;   /* ✕ = .btn.no del prototipo: 700 13px */
  transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#gp-biblio .gp-x:active { transform: scale(0.92); }
#gp-biblio .gp-buscar {
  margin: 0 16px 2px; display: flex; align-items: center; gap: 8px; padding: 0 12px; min-height: 40px; box-sizing: border-box;
  border-radius: 12px; background: #17142a; border: 1px solid var(--gp-line); color: var(--gp-mut); font-size: 13px;
}
#gp-biblio .gp-buscar[hidden], #gp-biblio .gp-chips[hidden] { display: none; }
#gp-biblio .gp-buscar input {
  flex: 1; min-width: 0; height: 44px; margin: -5px 0 -1px; padding: 0;   /* -5/-1: el texto de 14 px sobre la línea de 16 quedaba 2 px más abajo que en el prototipo */ border: 0; border-radius: 0; outline: 0; background: transparent none;   /* campo de 44 px, píldora de 40 */
  border-color: transparent !important; box-shadow: none !important; transition: none !important;   /* power-alfa.css:655-666 pinta TODO input con sombra interior y una raya de acento a la izquierda (!important); el prototipo no la tiene */
  color: #fff; font: 16px/1.2 var(--gp-font); letter-spacing: 0; text-transform: none; -webkit-appearance: none; appearance: none;
}
#gp-biblio .gp-buscar input:focus, #gp-biblio .gp-buscar input:hover { border-color: transparent !important; box-shadow: none !important; outline: 0 !important; }
#gp-biblio .gp-buscar:focus-within { border-color: var(--c, var(--gp-mashita)); }   /* el foco se ve en la píldora, no en el campo */
#gp-biblio .gp-buscar input::placeholder { color: var(--gp-mut); font-size: 14px; }   /* prototipo: .buscar input 14 px; lo escrito queda en 16 (iOS no hace zoom) */
#gp-biblio .gp-buscar input::-webkit-search-cancel-button { -webkit-appearance: none; }
#gp-biblio .gp-chips { display: flex; gap: 6px; padding: 6px 16px 10px; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
#gp-biblio .gp-chips::-webkit-scrollbar { display: none; }
#gp-biblio .gp-chips button {
  position: relative; isolation: isolate; flex: 0 0 auto; box-sizing: border-box; height: 44px; margin: -6px 0; padding: 0 12px; white-space: nowrap; cursor: pointer;   /* caja de 44 px; la píldora de 32 vive en ::before. 12 = 11 de relleno + 1 del borde del prototipo, que acá vive en ::before y no suma ancho */
  font: 700 11.5px/44px var(--gp-font); letter-spacing: 0; text-transform: none; border: 0; background: transparent; color: var(--gp-mut);
  touch-action: manipulation; transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#gp-biblio .gp-chips button::before { content: ''; position: absolute; left: 0; right: 0; top: 6px; bottom: 6px; z-index: -1; box-sizing: border-box; border-radius: 16px; border: 1px solid var(--gp-line); background: transparent; }
#gp-biblio .gp-chips button[data-on="1"] { color: #0b0910; }
#gp-biblio .gp-chips button[data-on="1"]::before { background: #fff; border-color: #fff; }
#gp-biblio .gp-chips button:active { transform: scale(0.95); }
#gp-biblio .gp-tabs { display: flex; gap: 6px; padding: 0 16px 10px; min-width: 0; }
#gp-biblio .gp-tabs button {
  position: relative; isolation: isolate; flex: 1 1 0; box-sizing: border-box; min-width: 0; height: 44px; margin: -4px 0; padding: 0 4px; cursor: pointer; overflow: hidden; white-space: nowrap; text-overflow: clip;   /* caja de 44 px; la píldora de 36 vive en ::before */
  text-align: center; font: 800 11px/44px var(--gp-font); letter-spacing: 1px; text-transform: uppercase; border: 0; background: transparent; color: var(--gp-mut); touch-action: manipulation;
}
#gp-biblio .gp-tabs button::before { content: ''; position: absolute; left: 0; right: 0; top: 4px; bottom: 4px; z-index: -1; box-sizing: border-box; border-radius: 10px; border: 1px solid var(--gp-line); background: transparent; }
#gp-biblio .gp-tabs button[hidden] { display: none; }
#gp-biblio .gp-tabs button[aria-selected="true"] { color: #0b0910; }
#gp-biblio .gp-tabs button[aria-selected="true"]::before { background: var(--gp-pley); border-color: var(--gp-pley); }
#gp-biblio .gp-lista { flex: 1; min-height: 0; overflow: auto; overscroll-behavior: contain; padding: 0 16px 16px; display: flex; flex-direction: column; gap: 8px; }
#gp-biblio .gp-grupo { font: 800 10.5px/1 var(--gp-font); letter-spacing: 1.4px; color: var(--gp-mut); margin: 8px 0 2px; }
#gp-biblio .gp-cred { font: 500 10.5px/1.4 var(--gp-font); color: var(--gp-mut); margin: 10px 0 0; padding-top: 8px; border-top: 1px solid var(--gp-line); }
#gp-biblio .gp-cred a { color: inherit; text-decoration: underline; }
#gp-biblio .gp-item {
  display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 6px 10px; box-sizing: border-box;
  border-radius: 12px; background: #17142a; border: 1px solid var(--gp-line);
}
#gp-biblio .gp-ic { flex: 0 0 28px; width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; font-size: 14px; background: #221e38; }
#gp-biblio .gp-t { flex: 1; min-width: 0; }
#gp-biblio .gp-t b { display: block; font-size: 13.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#gp-biblio .gp-t span { display: block; font-size: 11.5px; color: var(--gp-mut); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#gp-biblio .gp-ok { flex: 0 0 auto; color: var(--gp-verde); font-weight: 800; }
#gp-biblio .gp-ok[data-falta="1"] { color: #5a5470; }
#gp-biblio .gp-dur { flex: 0 0 auto; font-size: 11px; color: var(--gp-mut); margin-right: 4px; }
#gp-biblio .gp-play {
  position: relative; isolation: isolate; flex: 0 0 44px; box-sizing: border-box; width: 44px; height: 44px; margin: -4px; padding: 0; border: 0;   /* caja de 44 px; la píldora de 36 vive en ::before */
  display: grid; place-items: center; background: transparent; color: #fff; font-size: 13px; cursor: pointer; touch-action: manipulation;
  transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#gp-biblio .gp-play::before { content: ''; position: absolute; inset: 4px; z-index: -1; border-radius: 10px; background: #262140; }
#gp-biblio .gp-demo {
  position: relative; isolation: isolate; flex: 0 0 auto; box-sizing: border-box; height: 44px; margin: -7px 0; border: 0; cursor: pointer; touch-action: manipulation;   /* caja de 44 px; la píldora de 30 vive en ::before */
  font: 800 10.5px/44px var(--gp-font); letter-spacing: 1px; padding: 0 10px; background: transparent; color: #0b0910;
  transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#gp-biblio .gp-demo::before { content: ''; position: absolute; left: 0; right: 0; top: 7px; bottom: 7px; z-index: -1; border-radius: 9px; background: var(--gp-pley); }
#gp-biblio .gp-demo[disabled] { opacity: 0.45; cursor: default; }
#gp-biblio .gp-play:active, #gp-biblio .gp-demo:not([disabled]):active { transform: scale(0.92); }
#gp-biblio .gp-barra { height: 8px; border-radius: 4px; background: #221e38; overflow: hidden; margin: 4px 0 8px; }
#gp-biblio .gp-barra i { display: block; width: 100%; height: 100%; transform-origin: 0 50%; background: linear-gradient(90deg, var(--gp-mashita), var(--gp-oro)); }
#gp-biblio .gp-nov { padding: 12px; border-radius: 14px; background: linear-gradient(135deg, #1c1733, #141022); border: 1px solid #3b2f63; }
#gp-biblio .gp-nov b { display: block; font-size: 14px; }
#gp-biblio .gp-nov span { font-size: 12px; color: var(--gp-mut); }
#gp-biblio .gp-nov em { font-style: normal; font: 800 10px/1 var(--gp-font); letter-spacing: 1.2px; color: var(--gp-oro); }
#gp-biblio .gp-nov-pie { margin-top: 8px; }
#gp-biblio .gp-hoja-pie { padding: 4px 16px 10px; border-top: 1px solid rgba(255, 255, 255, 0.06); }
/* Interruptor «Guías automáticas» (D5): apagado = solo desde la Biblioteca. */
#gp-biblio .gp-interruptor {
  width: 100%; min-height: 44px; margin: 0; padding: 0; border: 0; background: transparent; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--gp-txt); font: 600 13.5px/1.2 var(--gp-font); touch-action: manipulation;
}
#gp-biblio .gp-interruptor-txt { min-width: 0; text-align: left; }
#gp-biblio .gp-interruptor-pista { position: relative; flex: 0 0 40px; width: 40px; height: 22px; border-radius: 11px; background: var(--gp-line); }
#gp-biblio .gp-interruptor-pista::after {
  content: ''; position: absolute; left: 2px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: var(--gp-mut);
  transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
#gp-biblio .gp-interruptor[aria-checked="true"] .gp-interruptor-pista { background: rgba(56, 225, 255, 0.35); }
#gp-biblio .gp-interruptor[aria-checked="true"] .gp-interruptor-pista::after { transform: translateX(18px); background: var(--gp-pley); }
@media (max-width: 380px) {
  #gp-biblio .gp-tabs button { font-size: 10px; letter-spacing: 0.3px; }
}

/* ── entradas: ⚙️ → Guías (speed dial de la tarjeta) y la campana ───────────────────────────────────────────────── */
/* Con el motor encendido, «Guías» toma el lugar del 🎓 de Dirección en el dial (la Biblioteca repite cualquier guía):
   el dial conserva sus 5 botones y no se sale de la tarjeta a 360 px (ficha v540_perfil_botones-sueltos). */
html[data-guia-on="1"]:not(#hd-a):not(#hd-b):not(#hd-c):not(#hd-d) body #pf-dial > #btn-powi-tutorial { display: none; }
#btn-pf-dial-guias .gp-dial-ic { font-size: 18px; line-height: 1; }
#btn-pf-dial-guias .gp-punto, #gp-punto-tuerca {
  position: absolute; right: 2px; top: 2px; width: 9px; height: 9px; border-radius: 50%; pointer-events: none;
  background: var(--gp-rojo); box-shadow: 0 0 6px var(--gp-rojo);
}
#btn-pf-dial-guias .gp-punto[hidden], #gp-punto-tuerca[hidden] { display: none; }
#gp-punto-tuerca { right: 0; top: 0; width: 8px; height: 8px; }
.gp-campana-fila {
  display: flex; align-items: center; justify-content: center; gap: 8px; box-sizing: border-box;
  width: calc(100% - 24px); min-height: 44px; margin: 8px 12px 12px; padding: 0 12px;
  border-radius: 12px; background: rgba(23, 20, 42, 0.9); border: 1px solid var(--gp-line);
  color: var(--gp-txt); font: 700 13px/1 var(--gp-font); cursor: pointer; touch-action: manipulation;
  transition: transform 120ms cubic-bezier(0.34, 1.56, 0.64, 1);
}
.gp-campana-fila:active { transform: scale(0.97); }

/* ── keyframes (varias líneas, la llave de cierre sola: lección R187) ───────────────────────────────────────────── */
@keyframes gpEntraA {
  from { transform: translateY(8px) scale(0.96); opacity: 0; }
  to { transform: none; opacity: 1; }
}
@keyframes gpEntraB {
  from { transform: translateY(8px) scale(0.96); opacity: 0; }
  to { transform: none; opacity: 1; }
}
@keyframes gpHechoA {
  0% { filter: brightness(1); }
  30% { filter: brightness(1.35); }
  100% { filter: brightness(1); }
}
@keyframes gpHechoB {
  0% { filter: brightness(1); }
  30% { filter: brightness(1.35); }
  100% { filter: brightness(1); }
}
@keyframes gpLatir {
  0% { opacity: 0; }
  50% { opacity: 1; }
  100% { opacity: 0; }
}

/* ── reducir movimiento: sin rebote, sin latido, sin deslizamientos ─────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  #powi-tuto[data-gp] .gp-hud, #powi-tuto[data-gp] .powi-tuto-foco, #gp-tip .gp-burbuja, #gp-tip .gp-halo::after, #gp-halo-momento::after,
  #gp-toast, #gp-biblio .gp-hoja, #gp-biblio .gp-interruptor-pista::after, .gp-campana-fila, #gp-biblio button, #gp-tip .gp-btn, #powi-tuto[data-gp] .gp-btn {
    transition: none !important; animation: none !important;
  }
}

/* T2 · tarjeta «¿De dónde salen mis ⚡?» de la Biblioteca: cristal liso, dos columnas, sin movimiento */
#gp-biblio .gp-tarjeta { margin: 8px 0 4px; padding: 12px; border-radius: 14px; background: rgba(23, 20, 42, 0.72); border: 1px solid rgba(255, 210, 90, 0.45); box-shadow: 0 0 14px -4px var(--gp-oro); }
#gp-biblio .gp-tarjeta > b { display: block; margin-bottom: 8px; font: 800 14px/1.2 var(--gp-font); color: var(--gp-oro); }
#gp-biblio .gp-tarjeta-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; }
#gp-biblio .gp-tarjeta-col { min-width: 0; }
#gp-biblio .gp-tarjeta-col em { display: block; margin-bottom: 4px; font: 800 10.5px/1 var(--gp-font); letter-spacing: 1.4px; font-style: normal; color: var(--gp-pley); }
#gp-biblio .gp-tarjeta-col ul { margin: 0; padding: 0; list-style: none; }
#gp-biblio .gp-tarjeta-col li { padding: 3px 0; font: 600 12.5px/1.3 var(--gp-font); color: var(--gp-txt); overflow-wrap: anywhere; }
