/* ===== tests/tests.css ===== */
/* TESTS · aquí cada test tiene su propio aspecto, así que la sección se queda neutra a propósito:
     · el listado es una franja clara y las tarjetas toman los colores («tema») de cada test;
     · la página de un test no impone cabecera: el test pone su <h1>, sus colores y su CSS (app.css).
   Este archivo trae además el «kit» .tt- que usan los tests (zona de prueba, botones, resultados, texto para buscadores).
   Cada categoría añade su sello con una clase en el <section>: .tt--velocidad, .tt--raton, .tt--reaccion, .tt--vista, .tt--memoria. */
body[data-seccion="tests"] .seccion-cabecera { background: var(--papel); border-bottom: 2px solid var(--tinta); }
body[data-seccion="tests"] .seccion-titulo { letter-spacing: -0.05em; }
body[data-seccion="tests"] .rejilla { gap: var(--e5); }
body[data-seccion="tests"] .ficha-libre-migas { padding-block: var(--e4); }

/* ---- Listado agrupado, con buscador */
body[data-seccion="tests"] .filtros--tests { gap: var(--e3); padding: var(--e4); background: var(--papel); border: 2px solid var(--tinta); border-radius: var(--radio-trabajo); box-shadow: 4px 4px 0 var(--tinta); }
body[data-seccion="tests"] .filtro-barra { display: grid; gap: var(--e3); }
body[data-seccion="tests"] .filtro-campo { display: grid; gap: 0.25rem; margin: 0; min-width: 0; font-weight: 700; font-size: var(--t-1); }
body[data-seccion="tests"] .filtro-campo input, body[data-seccion="tests"] .filtro-campo select { width: 100%; min-height: 2.75rem; padding: 0.5rem 0.8rem; border: 2px solid var(--tinta); border-radius: var(--radio-trabajo); background: var(--papel); color: var(--tinta); font: 400 1rem / 1.4 var(--f-trabajo); }
body[data-seccion="tests"] .filtro-campo input:focus-visible, body[data-seccion="tests"] .filtro-campo select:focus-visible { outline: 3px solid var(--limon); outline-offset: 1px; box-shadow: 0 0 0 5px var(--tinta); }
body[data-seccion="tests"] .filtro-resumen { display: flex; flex-wrap: wrap; align-items: center; gap: var(--e3); margin: 0; min-height: 2rem; font-size: var(--t-1); }
body[data-seccion="tests"] .filtro-estado { min-height: 0; }
@media (min-width: 40rem) { body[data-seccion="tests"] .filtro-barra { grid-template-columns: minmax(0, 1fr) minmax(0, 20rem); } }
body[data-seccion="tests"] .grupo { margin-top: var(--e7); }
body[data-seccion="tests"] .grupo:first-of-type { margin-top: 0; }
body[data-seccion="tests"] .grupo[hidden] { display: none; }
body[data-seccion="tests"] .grupo-titulo { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--e3); margin-bottom: var(--e4); padding-bottom: var(--e2); border-bottom: 3px solid var(--tinta); font-size: var(--t3); line-height: 1.1; }
body[data-seccion="tests"] .grupo-cuenta { font-size: var(--t-1); font-weight: 400; color: var(--tinta-suave); }
body[data-seccion="tests"] .grupo .tarjeta-meta { display: none; }

/* ======================================================================================================
   KIT DE LOS TESTS (.tt-)  ·  los colores salen del «tema» de cada ficha: --t-fondo, --t-texto, --t-acento
   ====================================================================================================== */
.tt {
  --tt-panel: color-mix(in srgb, var(--t-texto) 9%, var(--t-fondo));
  --tt-linea: color-mix(in srgb, var(--t-texto) 32%, var(--t-fondo));
  --tt-suave: color-mix(in srgb, var(--t-texto) 80%, var(--t-fondo));
  --tt-radio: 6px;
  --tt-fuente-num: var(--f-trabajo);
  --tt-fuente-tit: var(--f-trabajo);
  padding-block: var(--e5) var(--e7);
  color: var(--t-texto);
}
.tt-cab { max-width: 46rem; margin-bottom: var(--e5); }
.tt-titulo { margin: 0 0 var(--e3); font: 700 clamp(2rem, 6.5vw, 3.6rem) / 1 var(--tt-fuente-tit); letter-spacing: -0.03em; text-wrap: balance; }
.tt-lead { margin: 0; font-size: var(--t1); line-height: 1.5; color: var(--tt-suave); }
.tt-app { display: grid; gap: var(--e4); }
.tt-aviso { margin: 0; padding: var(--e3) var(--e4); border-left: 6px solid var(--t-acento); background: var(--tt-panel); color: var(--t-texto); line-height: 1.5; }

/* La zona donde ocurre la prueba */
.tt-zona { position: relative; display: grid; place-items: center; gap: var(--e3); min-height: 16rem; padding: var(--e5); text-align: center; background: var(--tt-panel); border: 3px solid var(--t-acento); border-radius: var(--tt-radio); }
.tt-arena { appearance: none; width: 100%; min-height: clamp(14rem, 42vh, 24rem); margin: 0; padding: var(--e5); cursor: pointer; display: grid; place-content: center; gap: var(--e2); text-align: center;
  background: var(--tt-panel); color: var(--t-texto); border: 3px solid var(--t-acento); border-radius: var(--tt-radio); font: 700 clamp(1.1rem, 3.6vw, 1.7rem) / 1.2 var(--tt-fuente-tit);
  touch-action: manipulation; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
.tt-arena:hover { background: color-mix(in srgb, var(--t-acento) 12%, var(--tt-panel)); }
.tt-arena:active { transform: scale(0.992); }   /* sin cambios de brillo: al pulsar muy rápido no hay parpadeo */
.tt-arena:focus-visible { outline: 4px solid var(--t-texto); outline-offset: 3px; }
.tt-arena small { font: 400 var(--t-1) / 1.4 var(--f-trabajo); opacity: 0.85; }
.tt-arena[data-estado="jugando"] { border-style: solid; }
.tt-arena[data-estado="fin"] { cursor: default; }
.tt-zona-total { width: 100%; }

/* Lo que lleva «hidden» se oculta aunque su clase le dé una pantalla propia */
.tt [hidden] { display: none !important; }

/* Controles */
.tt-fila { display: flex; flex-wrap: wrap; align-items: center; gap: var(--e3); }
.tt-fila--centro { justify-content: center; }
.tt-etiqueta { margin: 0; font-weight: 700; }
.tt-chips { display: flex; flex-wrap: wrap; gap: var(--e2); }
.tt-chip, .tt-boton { appearance: none; cursor: pointer; font: 700 1rem / 1.2 var(--tt-fuente-tit); border-radius: var(--tt-radio); }
.tt-chip { padding: 0.55rem 0.95rem; min-height: 2.75rem; background: transparent; color: var(--t-texto); border: 2px solid var(--tt-linea); }
.tt-chip:hover { border-color: var(--t-acento); }
.tt-chip[aria-pressed="true"] { background: var(--t-acento); color: var(--t-fondo); border-color: var(--t-acento); }
.tt-chip:disabled { opacity: 0.55; cursor: not-allowed; }
.tt-boton { padding: 0.8rem 1.4rem; min-height: 3rem; background: var(--t-acento); color: var(--t-fondo); border: 3px solid var(--t-acento); }
.tt-boton:hover { background: transparent; color: var(--t-acento); }
.tt-boton--sec { background: transparent; color: var(--t-texto); border-color: var(--tt-linea); }
.tt-boton--sec:hover { color: var(--t-texto); border-color: var(--t-acento); }
.tt-boton:disabled { opacity: 0.55; cursor: not-allowed; }
.tt-chip:focus-visible, .tt-boton:focus-visible, .tt-campo:focus-visible { outline: 3px solid var(--t-texto); outline-offset: 3px; }
.tt-campo { padding: 0.8rem 1rem; min-height: 3rem; background: var(--t-fondo); color: var(--t-texto); border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); font: 700 1.3rem / 1.2 var(--tt-fuente-num); }

/* Cifras en vivo */
.tt-datos { display: grid; grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr)); gap: var(--e3); margin: 0; padding: 0; list-style: none; }
.tt-dato { display: grid; gap: 0.15rem; padding: var(--e3) var(--e4); background: var(--tt-panel); border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); }
.tt-dato-v { font: 700 clamp(1.5rem, 5vw, 2.4rem) / 1.05 var(--tt-fuente-num); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.tt-dato-e { font-size: var(--t-1); color: var(--tt-suave); }
.tt-dato[data-alerta="1"] .tt-dato-v { color: var(--t-acento); }

/* Resultado */
.tt-res { display: grid; gap: var(--e4); padding: var(--e5); background: var(--tt-panel); border: 3px solid var(--t-acento); border-radius: var(--tt-radio); }
.tt-res-tit { margin: 0; font: 700 var(--t1) / 1.2 var(--tt-fuente-tit); color: var(--tt-suave); }
.tt-res-grande { margin: 0; font: 700 clamp(3rem, 14vw, 6.5rem) / 0.95 var(--tt-fuente-num); color: var(--t-acento); font-variant-numeric: tabular-nums; }
.tt-res-grande small { font-size: 0.32em; margin-left: 0.3em; color: var(--t-texto); }
.tt-res-rango { margin: 0; font-size: var(--t1); font-weight: 700; }
.tt-res-texto { margin: 0; max-width: 46rem; line-height: 1.55; color: var(--tt-suave); }
.tt-tabla { display: grid; grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr)); gap: var(--e2) var(--e5); margin: 0; }
.tt-tabla div { display: flex; justify-content: space-between; gap: var(--e3); padding-block: 0.4rem; border-bottom: 1px solid var(--tt-linea); }
.tt-tabla dt { color: var(--tt-suave); }
.tt-tabla dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; }
.tt-copia { width: 100%; min-height: 4.5rem; padding: var(--e3); background: var(--t-fondo); color: var(--t-texto); border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); font: 400 1rem / 1.4 var(--f-trabajo); }

/* Barras (resultado por segundo, por intento…) */
.tt-barras { display: flex; align-items: flex-end; gap: 3px; height: 10.5rem; padding: 1.4rem 0 0; box-sizing: border-box; border-bottom: 2px solid var(--tt-linea); }
.tt-barra { position: relative; flex: 1 1 0; min-width: 3px; display: flex; align-items: flex-end; height: 100%; }
.tt-barra i { display: block; width: 100%; min-height: 2px; background: var(--t-acento); border-radius: 2px 2px 0 0; }
.tt-barra span { position: absolute; left: 50%; transform: translateX(-50%); padding-bottom: 2px; font-size: 0.7rem; line-height: 1.2; color: var(--tt-suave); font-variant-numeric: tabular-nums; white-space: nowrap; }
.tt-barras-pie { margin: 0; display: flex; justify-content: space-between; font-size: var(--t-1); color: var(--tt-suave); }

/* ---- Texto para buscadores y lectores (debajo del test) */
.tt-texto { max-width: 46rem; margin-top: var(--e7); padding-top: var(--e5); border-top: 2px solid var(--tt-linea); }
.tt-texto h2 { margin: var(--e6) 0 var(--e3); font: 700 var(--t3) / 1.15 var(--tt-fuente-tit); letter-spacing: -0.02em; }
.tt-texto h2:first-child { margin-top: 0; }
.tt-texto p, .tt-texto li { line-height: 1.65; }
.tt-texto p { margin: 0 0 var(--e3); }
.tt-texto a { color: var(--t-acento); text-decoration: underline; text-underline-offset: 3px; }
.tt-texto a:hover { text-decoration-thickness: 3px; }
.tt-texto details { margin-bottom: var(--e2); padding: var(--e3) var(--e4); background: var(--tt-panel); border: 1px solid var(--tt-linea); border-radius: var(--tt-radio); }
.tt-texto summary { cursor: pointer; font-weight: 700; }
.tt-texto details p { margin: var(--e2) 0 0; }
.tt-texto .tt-nota { padding: var(--e3) var(--e4); border-left: 6px solid var(--t-acento); background: var(--tt-panel); }

/* ---- Sellos de cada categoría */
/* Velocidad y clics: píxel y sombra dura, como las máquinas recreativas */
.tt--velocidad { --tt-radio: 0; --tt-fuente-num: var(--f-pixel); --tt-fuente-tit: var(--f-pixel); }
.tt--velocidad .tt-zona, .tt--velocidad .tt-arena, .tt--velocidad .tt-res { box-shadow: 8px 8px 0 var(--t-acento); border-color: var(--t-acento); }
.tt--velocidad .tt-titulo { letter-spacing: 0; line-height: 1.1; }
.tt--velocidad .tt-arena:active { transform: translate(4px, 4px); box-shadow: 4px 4px 0 var(--t-acento); }
.tt-arena-n { font: 700 clamp(3rem, 14vw, 6rem) / 1 var(--tt-fuente-num); font-variant-numeric: tabular-nums; color: var(--t-acento); }
.tt--velocidad .tt-dato-v, .tt--velocidad .tt-res-grande { letter-spacing: -0.04em; }
/* Ratón y teclado: papel milimetrado, trazo fino y números de ingeniería */
.tt--raton { --tt-radio: 4px; --tt-fuente-num: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; }
.tt--raton .tt-zona, .tt--raton .tt-arena { background-image: linear-gradient(var(--tt-linea) 1px, transparent 1px), linear-gradient(90deg, var(--tt-linea) 1px, transparent 1px); background-size: 28px 28px; background-color: var(--tt-panel); background-blend-mode: normal; border-width: 2px; }
.tt--raton .tt-arena:hover { background-color: color-mix(in srgb, var(--t-acento) 10%, var(--tt-panel)); }
/* Reacción y puntería: formas grandes, redondas y de un solo color */
.tt--reaccion { --tt-radio: 22px; --tt-fuente-num: var(--f-trabajo); }
.tt--reaccion .tt-zona, .tt--reaccion .tt-arena, .tt--reaccion .tt-res { border-width: 4px; }
.tt--reaccion .tt-chip, .tt--reaccion .tt-boton { border-radius: 999px; }
/* Vista y oído: gris neutro y sin adornos, para no influir en lo que se mide */
.tt--vista { --tt-radio: 12px; }
.tt--vista .tt-zona, .tt--vista .tt-res { border-width: 2px; border-color: var(--tt-linea); }
/* Memoria y percepción: hoja de examen con borde inferior marcado */
.tt--memoria { --tt-radio: 10px; --tt-fuente-num: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; }
.tt--memoria .tt-zona, .tt--memoria .tt-res, .tt--memoria .tt-dato { border-width: 2px; border-bottom-width: 6px; border-color: var(--tt-linea); border-bottom-color: var(--t-acento); }

@media (max-width: 40rem) {
  .tt-zona, .tt-res, .tt-arena { padding: var(--e4); }
  .tt--velocidad .tt-zona, .tt--velocidad .tt-arena, .tt--velocidad .tt-res { box-shadow: 5px 5px 0 var(--t-acento); }
}
@media (prefers-reduced-motion: reduce) { .tt-arena:active { transform: none; } }

/* Reacción: la zona cambia de color con la señal (y de texto, para quien no distingue los colores) */
.tt--reaccion .tt-arena--senal { min-height: clamp(16rem, 52vh, 28rem); }
.tt--reaccion .tt-arena--senal[data-estado="espera"] { background: #B3202F; color: #FFFFFF; border-color: #FFFFFF; }
.tt--reaccion .tt-arena--senal[data-estado="ya"] { background: #3DDC84; color: #06210F; border-color: #06210F; }
.tt--reaccion .tt-arena--senal[data-estado="pronto"] { background: #FFC247; color: #2A1018; border-color: #2A1018; }
.tt--reaccion .tt-arena--senal[data-estado="espera"] small, .tt--reaccion .tt-arena--senal[data-estado="ya"] small, .tt--reaccion .tt-arena--senal[data-estado="pronto"] small { color: inherit; }
.tt--reaccion .tt-arena--audio[data-estado="espera"] { background: var(--tt-panel); color: var(--t-texto); border-color: var(--t-acento); }
.tt-nowrap { white-space: nowrap; }

/* ======================================================================================================
   CUESTIONARIOS (.tc-, .tl-) Y GRÁFICAS (.tg-)  ·  los usan los tests de personalidad, relaciones y cultura pop
   ====================================================================================================== */
.tc { display: grid; gap: var(--e4); }
.tc[hidden], .tl[hidden], .tl-barra[hidden] { display: none; }
.tc-progreso { display: flex; align-items: center; gap: var(--e3); font-weight: 700; }
.tc-num { flex: none; font-variant-numeric: tabular-nums; }
.tc-pista { flex: 1; height: 10px; background: var(--tt-panel); border: 1px solid var(--tt-linea); border-radius: 999px; overflow: hidden; }
.tc-pista i { display: block; height: 100%; width: 0; background: var(--t-acento); transition: width 0.25s ease; }
.tc-pregunta { display: grid; gap: var(--e3); padding: var(--e5); background: var(--tt-panel); border: 3px solid var(--t-acento); border-radius: var(--tt-radio); }
.tc-pregunta:focus { outline: none; }
.tc-pregunta:focus-visible { outline: 4px solid var(--t-texto); outline-offset: 3px; }
.tc-t { margin: 0; font: 700 clamp(1.2rem, 3.8vw, 1.7rem) / 1.3 var(--tt-fuente-tit); text-wrap: balance; }
.tc-nota { margin: 0; color: var(--tt-suave); line-height: 1.5; }
.tc-opciones { display: grid; gap: var(--e2); }
.tc-opciones--escala { grid-template-columns: repeat(auto-fit, minmax(9.5rem, 1fr)); }
.tc-opcion { appearance: none; display: flex; align-items: center; gap: var(--e3); width: 100%; min-height: 3.2rem; padding: 0.75rem 1rem; text-align: left; cursor: pointer; background: var(--t-fondo); color: var(--t-texto);
  border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); font: 600 1.05rem / 1.35 var(--tt-fuente-tit); touch-action: manipulation; }
.tc-opciones--escala .tc-opcion { flex-direction: column; justify-content: center; text-align: center; gap: 0.2rem; }
.tc-opcion:hover { border-color: var(--t-acento); }
.tc-opcion[aria-pressed="true"] { background: var(--t-acento); color: var(--t-fondo); border-color: var(--t-acento); }
.tc-opcion:focus-visible { outline: 4px solid var(--t-texto); outline-offset: 2px; }
.tc-tecla { flex: none; display: grid; place-items: center; width: 1.7rem; height: 1.7rem; font: 700 0.85rem / 1 var(--tt-fuente-num); border: 2px solid currentColor; border-radius: 6px; opacity: 0.85; }

.tl { display: grid; gap: var(--e5); }
.tl-grupo { margin: 0; padding: var(--e4); display: grid; gap: 2px; background: var(--tt-panel); border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); }
.tl-grupo legend { padding-inline: var(--e2); font: 700 var(--t1) / 1.2 var(--tt-fuente-tit); }
.tl-item { display: flex; align-items: flex-start; gap: var(--e3); padding: 0.55rem 0.4rem; cursor: pointer; line-height: 1.4; border-radius: 6px; }
.tl-item:hover { background: color-mix(in srgb, var(--t-acento) 12%, transparent); }
.tl-item input { flex: none; width: 1.35rem; height: 1.35rem; margin-top: 0.1rem; accent-color: var(--t-acento); }
.tl-barra { position: sticky; bottom: 0; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--e3); padding: var(--e3) var(--e4); background: var(--t-fondo); border: 3px solid var(--t-acento); border-radius: var(--tt-radio); }
.tl-cuenta { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }

.tt-res-titular { margin: 0; font: 700 clamp(1.9rem, 7vw, 3.4rem) / 1.05 var(--tt-fuente-tit); letter-spacing: -0.02em; color: var(--t-acento); text-wrap: balance; }
.tt-res-extra { display: grid; gap: var(--e5); }
.tt-res h3 { margin: 0; font: 700 var(--t0) / 1.3 var(--tt-fuente-tit); color: var(--tt-suave); }
.tt-res-lista { margin: 0; padding-left: 1.2rem; display: grid; gap: var(--e2); line-height: 1.5; }

/* Gráficas */
.tg-barras { margin: 0; padding: 0; list-style: none; display: grid; gap: var(--e3); }
.tg-barra { display: grid; grid-template-columns: minmax(7rem, 13rem) 1fr 5.2rem; align-items: center; gap: var(--e3); }
.tg-nombre { display: grid; line-height: 1.25; font-weight: 600; overflow-wrap: anywhere; }
.tg-nombre small { font-weight: 400; color: var(--tt-suave); }
.tg-pista { position: relative; display: block; height: 14px; background: var(--t-fondo); border: 1px solid var(--tt-linea); border-radius: 999px; overflow: hidden; }
.tg-pista i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--t-acento); border-radius: 999px; }
.tg-top .tg-nombre, .tg-top .tg-valor { font-weight: 800; }
.tg-valor { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 34rem) { .tg-barra { grid-template-columns: 1fr auto; } .tg-pista { grid-column: 1 / -1; grid-row: 2; } }
.tg-ejes { display: grid; gap: var(--e4); }
.tg-eje { display: grid; grid-template-columns: 1fr 1fr; gap: 0.2rem var(--e3); }
.tg-polo { grid-row: 1; font-weight: 600; color: var(--tt-suave); }
.tg-polo--der { grid-column: 2; text-align: right; }
.tg-gana { color: var(--t-texto); font-weight: 800; }
.tg-pista--eje { grid-column: 1 / -1; grid-row: 2; height: 16px; }
.tg-pista--eje i { border-radius: 0; }
.tg-pista--eje b { position: absolute; top: -2px; bottom: -2px; width: 2px; background: var(--t-texto); }
.tg-balanza .tg-pista--eje { height: 14px; }
.tg-resta { background: var(--t-texto) !important; opacity: 0.55; }
.tg-eje-v { grid-column: 1 / -1; grid-row: 3; font-size: var(--t-1); color: var(--tt-suave); font-variant-numeric: tabular-nums; }
.tg-svg { display: block; width: 100%; max-width: 30rem; height: auto; margin-inline: auto; overflow: visible; }
.tg-t { fill: var(--t-texto); font: 600 13.5px / 1.2 var(--tt-fuente-tit); }
.tg-t--suave { fill: var(--tt-suave); font-weight: 400; font-size: 12px; }
.tg-t--grande { font-size: 34px; font-weight: 800; fill: var(--t-acento); }
.tg-malla { fill: none; stroke: var(--tt-linea); stroke-width: 1; }
.tg-malla.tg-relleno { fill: var(--t-fondo); }
.tg-area { fill: color-mix(in srgb, var(--t-acento) 38%, transparent); stroke: var(--t-acento); stroke-width: 2.5; stroke-linejoin: round; }
.tg-punto { fill: var(--t-acento); stroke: var(--t-fondo); stroke-width: 2; }
.tg-punto--grande { stroke: var(--t-texto); stroke-width: 3; }
.tg-aguja { fill: var(--t-acento); stroke: var(--t-texto); stroke-width: 2; stroke-linejoin: round; }
.tg-aguja-l { stroke: var(--t-texto); stroke-width: 4; stroke-linecap: round; }
.tg-arco { fill: none; stroke: var(--tt-linea); stroke-width: 22; }
.tg-arco--v { stroke: var(--t-acento); }
.tg-trazo { fill: none; stroke: var(--t-acento); stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.tg-espectro { display: grid; gap: var(--e2); padding-top: var(--e2); }
.tg-espectro-pista { position: relative; height: 18px; border: 2px solid var(--tt-linea); border-radius: 999px; background: linear-gradient(90deg, var(--t-fondo), var(--t-acento)); }
.tg-espectro-pista b { position: absolute; top: -8px; width: 8px; height: 32px; margin-left: -4px; background: var(--t-texto); border: 2px solid var(--t-fondo); border-radius: 4px; }
.tg-espectro-pie { display: flex; justify-content: space-between; gap: var(--e3); font-size: var(--t-1); color: var(--tt-suave); }
.tg-espectro-marcas { position: relative; height: 1.4rem; font-size: var(--t-1); color: var(--tt-suave); }
.tg-espectro-marcas span { position: absolute; transform: translateX(-50%); white-space: nowrap; }
.tg-espectro-marcas .tg-m-ini { transform: none; }
.tg-espectro-marcas .tg-m-fin { transform: translateX(-100%); }
.tg-semanas { display: block; width: 100%; max-width: 34rem; height: auto; margin-inline: auto; image-rendering: pixelated; }
.tg-leyenda { display: flex; flex-wrap: wrap; gap: var(--e2) var(--e4); margin: 0; padding: 0; list-style: none; font-size: var(--t-1); color: var(--tt-suave); }
.tg-leyenda li { display: flex; align-items: center; gap: var(--e2); }
.tg-leyenda i { width: 1rem; height: 1rem; border-radius: 3px; border: 1px solid var(--tt-linea); }

/* ---- QUIZ CON CORRECCIÓN (.tq-): los tests de idiomas. Pensado para temas oscuros: verde y rojo claros sobre el fondo del test. */
.tq { --tq-ok: #6FE39A; --tq-mal: #FF8F8F; }
.tq .tc-opcion { position: relative; flex-wrap: wrap; }
.tq .tq-texto { flex: 1 1 8rem; min-width: 0; overflow-wrap: anywhere; }
.tq .tc-opcion[aria-disabled="true"] { cursor: default; }
.tq .tc-opcion[aria-disabled="true"]:hover { border-color: var(--tt-linea); }
.tq .tq-ok, .tq .tq-ok:hover { border: 3px solid var(--tq-ok); background: color-mix(in srgb, var(--tq-ok) 20%, var(--t-fondo)); }
.tq .tq-mal, .tq .tq-mal:hover { border: 3px dashed var(--tq-mal); background: color-mix(in srgb, var(--tq-mal) 18%, var(--t-fondo)); }
.tq .tq-marca { flex: none; padding: 0.1rem 0.5rem; font: 700 0.85rem / 1.3 var(--tt-fuente-tit); border-radius: 6px; }
.tq .tq-ok .tq-marca { color: var(--t-fondo); background: var(--tq-ok); }
.tq .tq-mal .tq-marca { color: var(--t-fondo); background: var(--tq-mal); }
.tq-expl { margin: 0; padding: var(--e3) var(--e4); line-height: 1.55; border-left: 5px solid var(--t-acento); background: color-mix(in srgb, var(--t-texto) 7%, var(--t-fondo)); }
.tq-expl[hidden], .tq .tt-fila [hidden] { display: none; }
.tq-repaso { margin-top: var(--e3); border: 2px solid var(--tt-linea); border-radius: var(--tt-radio); padding: var(--e3) var(--e4); }
.tq-repaso summary { cursor: pointer; font-weight: 700; }
.tq-repaso-lista { margin: var(--e3) 0 0; padding: 0; list-style: none; display: grid; gap: var(--e4); }
.tq-repaso-lista li { display: grid; gap: 0.2rem; padding-bottom: var(--e3); border-bottom: 1px solid var(--tt-linea); }
.tq-repaso-lista li:last-child { border-bottom: 0; padding-bottom: 0; }
.tq-repaso-e { color: var(--tt-suave); }


/* Sellos de las categorías nuevas */
.tt--utilidades { --tt-radio: 4px; --tt-fuente-num: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; }
.tt--utilidades .tt-zona, .tt--utilidades .tt-res { border-width: 2px; border-left-width: 8px; }
.tt--personalidad { --tt-radio: 16px; }
.tt--personalidad .tc-pregunta, .tt--personalidad .tt-res { box-shadow: 6px 6px 0 color-mix(in srgb, var(--t-acento) 45%, transparent); }
.tt--relaciones { --tt-radio: 22px; }
.tt--relaciones .tc-opcion { border-radius: 999px; }
.tt--relaciones .tc-opciones--escala .tc-opcion { border-radius: 18px; }
.tt--anime { --tt-radio: 0; }
.tt--anime .tt-titulo, .tt--anime .tt-res-titular { font-family: var(--f-pixel); letter-spacing: 0; line-height: 1.15; }
.tt--anime .tc-pregunta, .tt--anime .tt-res { box-shadow: 8px 8px 0 var(--t-acento); }

/* Muestra de color del test del color del alma */
.tg-color { width: min(100%, 14rem); height: 5.5rem; margin-inline: auto; border: 4px solid var(--t-texto); border-radius: var(--tt-radio); }
.tt--series { --tt-radio: 10px; }
.tt--series .tt-titulo, .tt--series .tt-res-titular { letter-spacing: -0.03em; }
.tt--series .tc-pregunta, .tt--series .tt-res { box-shadow: 0 0 0 2px color-mix(in srgb, var(--t-acento) 35%, transparent), 6px 6px 0 color-mix(in srgb, var(--t-acento) 40%, transparent); }
.tt--idiomas { --tt-radio: 14px; }
.tt--idiomas .tt-titulo { letter-spacing: -0.03em; }
.tt--idiomas .tc-pregunta, .tt--idiomas .tt-res { box-shadow: 6px 6px 0 color-mix(in srgb, var(--t-acento) 45%, transparent); }
