/* ============================================================
   TEMARIUS REX — Acabado 2026 (rediseño de noviembre)
   ------------------------------------------------------------
   La portada nueva de la academia (includes/portada_academia.php)
   marcó el estilo: tinta navy dominante, papel blanco, grises fríos,
   oro solo para lo que se pulsa, titulares en Inter ligera muy
   apretada con Merriweather cursiva de acento, filetes finos en lugar
   de cajas con sombra, esquinas más contenidas.

   Este archivo se carga el ÚLTIMO y lleva ese acabado al resto de la
   web —páginas públicas, área del alumno, tests y panel— sin tocar el
   HTML de cada página. Para volver al aspecto anterior basta con
   quitar su <link> de header.php.
   ============================================================ */

/* ---------- 1. Tokens ---------- */
:root {
    --navy-900: #0A1426;
    --navy-800: #0D1A30;    /* el de la portada */
    --navy-700: #15264A;
    --navy-600: #22365F;
    --gold-700: #9A6C05;
    --gold-600: #C99413;
    --gold-500: #E3A81B;
    --gold-400: #F0B92E;
    --gold-100: #FBF3DD;

    /* Grises fríos (antes zinc, algo cálidos) */
    --n-25:  #FCFCFD;
    --n-50:  #F8F9FB;
    --n-100: #F4F5F7;
    --n-200: #E3E6EC;
    --n-300: #CDD2DB;
    --n-400: #8A93A3;
    --n-500: #5B6576;
    --n-600: #475163;
    --n-700: #1B2433;

    --ink:      var(--navy-900);
    --ink-body: #1B2433;
    --ink-muted: #5B6576;

    --r-sm: 8px;
    --r-md: 12px;
    --r-lg: 14px;
    --r-xl: 20px;

    --sh-sm: 0 1px 2px rgba(13,26,48,.05);
    --sh-md: 0 6px 18px rgba(13,26,48,.06);
    --sh-lg: 0 18px 44px rgba(13,26,48,.09);

    --nav-h: 76px;
    --curva-2026: cubic-bezier(.2, .7, .2, 1);
}
/* Las páginas públicas van sobre papel blanco, como la portada; dentro
   del área se queda el gris frío, que separa mejor paneles y tarjetas. */
body.publico { --surface-page: #FFFFFF; }
body { background: var(--surface-page); }

/* ---------- 2. Tipografía ---------- */
h1, h2 { font-weight: 300; letter-spacing: -.035em; }
h1 em, h2 em, h1 .xp-serif, h2 .xp-serif {
    font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -.02em;
}
/* Fuera las etiquetas en mayúsculas espaciadas: en minúscula y en oro */
.sec-eyebrow, .eyebrow, .plans-badge, .hero-badge, .rexy-tira-eyebrow {
    text-transform: none !important; letter-spacing: 0 !important;
    font-size: var(--fs-sm) !important; font-weight: 600 !important;
    color: var(--gold-700) !important;
}
.sec-head h2 { font-size: clamp(32px, 4.4vw, 52px); line-height: 1.05; }
.sec-head p, .sec-head .lead { font-size: var(--fs-lead); color: var(--ink-muted); }

/* ---------- 3. Menú: barra a todo el ancho, no píldora flotante ---------- */
.navbar {
    position: sticky; top: 0;
    width: 100%; max-width: none; margin: 0;
    border: 0; border-bottom: 1px solid var(--line);
    border-radius: 0; box-shadow: none;
    background: color-mix(in srgb, var(--surface-card) 92%, transparent);
}
.nav-container {
    max-width: 1200px; margin-inline: auto;
    height: var(--nav-h);
    padding-inline: clamp(20px, 5vw, 56px);
    gap: 28px;
}
.nav-logo img { height: 38px; border-radius: 9px; }
.logo-title { font-size: 16px; font-weight: 650; letter-spacing: .01em; text-transform: none; color: var(--ink); }
.logo-badge { font-size: 12px; font-weight: 450; letter-spacing: .01em; text-transform: none; color: var(--ink-muted); }
.nav-menu { gap: 26px; }
.nav-link { font-size: 15px; font-weight: 500; color: var(--ink-body); opacity: .82; }
.nav-link:hover, .nav-link.is-active { opacity: 1; }
.nav-link.is-active::after { height: 1.5px; bottom: -4px; background: var(--gold-500); }
/* En la web pública el menú va sin iconos, como la portada; dentro del
   área se quedan, que ahí ayudan a encontrar cada sección. */
body.publico .nav-link:not(.nav-campana) > i { display: none; }
.nav-cta, .nav-cta-main {
    height: 44px; padding: 0 20px; opacity: 1;
    font-size: 15px; font-weight: 600;
    background: var(--navy-800); color: #fff;
}
.nav-cta-dorado, .nav-cta-main.is-active { background: var(--gold-500); color: var(--navy-900); }
.nav-cta-dorado:hover, .nav-cta-main.is-active:hover { background: var(--gold-400); color: var(--navy-900); }
.nav-cta-main.is-active::after { display: none; }
.nav-toggle { border-radius: 50%; width: 44px; height: 44px; border-color: var(--line); }
@media (max-width: 1024px) {
    .navbar { top: 0; margin-top: 0; }
    .nav-menu { top: 100%; left: 0; right: 0; border-radius: 0 0 var(--r-lg) var(--r-lg); border-top: 0; }
    .nav-link { opacity: 1; font-size: 17px; }
    body.publico .nav-menu .nav-link:not(.nav-cta):not(.nav-cta-main) { font-weight: 300; font-size: 24px; letter-spacing: -.02em; padding: 12px 16px; border-bottom: 1px solid var(--line); border-radius: 0; }
    .nav-cta, .nav-cta-main { height: 52px; font-size: 16px; }
}

/* La barra de accesos solo la ve ya el tutor */
.barra-acceso { background: var(--navy-800); }

/* ---------- 4. Botones ---------- */
.btn, .cta-button, button.cta-button { font-size: 15px; transition: transform .2s var(--curva-2026), background-color .2s, border-color .2s, color .2s; }
.btn:hover:not(:disabled), .cta-button:hover { transform: translateY(-1px); box-shadow: none; }
.btn-lg { height: 54px; padding: 0 26px; font-size: 16px; }
.btn-outline { border-color: var(--line); background: var(--surface-card); }
.btn-outline:hover:not(:disabled) { border-color: var(--ink); background: var(--surface-card); }

/* ---------- 5. Cabecera de las páginas: banda de tinta ---------- */
.page-hero {
    position: relative; overflow: hidden;
    padding-block: clamp(72px, 10vw, 128px) clamp(56px, 7vw, 96px);
    background:
        radial-gradient(60% 90% at 85% 30%, rgba(227,168,27,.13), transparent 70%),
        radial-gradient(70% 80% at 0% 100%, rgba(46,106,62,.18), transparent 70%),
        var(--navy-800);
    border-bottom: 0;
    color: #fff;
}
.page-hero-inner { max-width: 1200px; padding-inline: clamp(20px, 5vw, 56px); }
.page-hero h1 {
    font-size: clamp(40px, 6vw, 80px); font-weight: 300; letter-spacing: -.045em; line-height: 1;
    color: #fff; max-width: 18ch;
}
.page-hero h1 em, .page-hero h1 .xp-serif { color: rgba(255,255,255,.72); }
.page-hero p { color: rgba(255,255,255,.72); font-size: clamp(17px, 1.6vw, 21px); line-height: 1.55; max-width: 56ch; }
.page-hero .hero-badge { color: var(--gold-400) !important; margin-bottom: 18px; }
.page-hero a:not(.btn) { color: #fff; }
.page-hero .btn-outline { background: transparent; color: #fff; border-color: rgba(255,255,255,.35); }
.page-hero .btn-outline:hover { border-color: #fff; color: #fff; background: transparent; }

/* ---------- 6. Secciones y tarjetas ---------- */
body.publico .sec-alt { background: var(--n-100); }
.sec { padding-block: clamp(72px, 10vw, 136px); }
.panel, .feature-card, .rule-card, .canal, .testimonio, .paso, .promo-panel, .auth-card, .mod-card, .plan-card {
    box-shadow: none;
}
.feature-card:hover, .rule-card:hover, .canal:hover { transform: none; box-shadow: none; border-color: var(--ink-faint); }

/* ---------- 7. Banner final: como el cierre de la portada ---------- */
.cta-banner {
    background:
        radial-gradient(60% 90% at 90% 20%, rgba(227,168,27,.12), transparent 70%),
        var(--navy-800);
    padding-block: clamp(88px, 11vw, 150px);
}
.cta-banner .trex-watermark { display: none; }
.cta-content { max-width: 1200px; padding-inline: clamp(20px, 5vw, 56px); text-align: left; }
.cta-content h3 {
    font-size: clamp(44px, 6.5vw, 96px); font-weight: 300; letter-spacing: -.045em; line-height: .98;
    margin-bottom: 24px;
}
.cta-content h3 i { display: none; }
.cta-content p { max-width: 46ch; margin-inline: 0; font-size: clamp(17px, 1.6vw, 21px); color: rgba(255,255,255,.72); }
.cta-actions { justify-content: flex-start; }
.cta-banner .cta-button { height: 54px; padding: 0 26px; font-size: 16px; background: var(--gold-500); border-color: var(--gold-500); color: var(--navy-900); }
.cta-banner .cta-button:hover { background: var(--gold-400); border-color: var(--gold-400); color: var(--navy-900); }
.cta-banner .cta-button-alt { background: transparent; border-color: rgba(255,255,255,.35); color: #fff; }
.cta-banner .cta-button-alt:hover { background: transparent; border-color: #fff; color: #fff; }

/* ---------- 8. Pie ---------- */
.footer { background: #08111F; margin-top: 0; }
.cta-banner + .footer { margin-top: 0; }
main + .footer, .main-content + .footer { margin-top: clamp(64px, 8vw, 120px); }
.footer-container { max-width: 1200px; margin-inline: auto; padding-inline: clamp(20px, 5vw, 56px); }
.footer-col h4 { text-transform: none; letter-spacing: 0; font-size: 15px; color: #fff; }
.footer-col a, .footer-marca p { font-size: 15px; color: rgba(255,255,255,.6); }
.footer-logo { height: 40px; border-radius: 9px; }
.footer-social a { background: transparent; }
.footer-social a:hover { background: transparent; border-color: var(--gold-500); color: var(--gold-500); }
.footer-bottom { max-width: 1200px; padding-inline: clamp(20px, 5vw, 56px); }

/* ---------- 9. WhatsApp flotante: como en la portada ---------- */
.wa-flotante {
    background: var(--navy-800) !important; color: #fff !important;
    box-shadow: 0 10px 30px rgba(13,26,48,.35), inset 0 0 0 1px rgba(255,255,255,.12) !important;
}
.wa-flotante i { color: #25D366; }

/* ---------- 10. Modo oscuro: la tinta pasa a ser el fondo ---------- */
:root[data-theme="dark"] .navbar { background: color-mix(in srgb, var(--surface-card) 92%, transparent); border-color: var(--line); }
:root[data-theme="dark"] body.publico { --surface-page: #0A0F18; }
:root[data-theme="dark"] body.publico .sec-alt { background: var(--surface-subtle); }


/* ---------- 11. La cabecera de página es un panel: esquinas y aire ---------- */
.page-hero { border-radius: var(--r-xl); margin-top: 16px; }
@media (max-width: 640px) { .page-hero { border-radius: var(--r-lg); margin-top: 8px; } }

/* ============================================================
   12. PÁGINAS DE ACCESO — pantalla partida
   ------------------------------------------------------------
   Izquierda: panel de tinta con Rexy y lo que te espera dentro
   (includes/acceso.php). Derecha: el formulario, sin tarjeta.
   ============================================================ */
.auth-section.acceso {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch; gap: clamp(24px, 4vw, 64px);
    min-height: calc(100svh - var(--nav-h) - 32px);
    padding: 16px 0 32px;
}
.acceso-lado {
    position: relative; overflow: hidden;
    display: flex; flex-direction: column; justify-content: space-between;
    min-height: 560px;
    padding: clamp(36px, 4.5vw, 64px);
    border-radius: var(--r-xl);
    background:
        radial-gradient(60% 60% at 85% 85%, rgba(227,168,27,.18), transparent 70%),
        radial-gradient(70% 70% at 0% 0%, rgba(46,106,62,.22), transparent 70%),
        var(--navy-800);
    color: #fff;
}
.acceso-marca { margin: 0 0 clamp(28px, 5vh, 56px); font-size: 14px; font-weight: 600; color: var(--gold-400); }
.acceso-lado h2 {
    margin: 0; max-width: 13ch;
    font-size: clamp(36px, 3.8vw, 56px); font-weight: 300; letter-spacing: -.045em; line-height: 1.02; color: #fff;
}
.acceso-lado h2 em { font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -.02em; color: rgba(255,255,255,.72); }
.acceso-puntos { list-style: none; margin: clamp(24px, 4vh, 40px) 0 0; padding: 0; max-width: 30ch; position: relative; z-index: 2; }
.acceso-puntos li {
    display: grid; grid-template-columns: 22px 1fr; gap: 10px;
    padding: 12px 0; border-top: 1px solid rgba(255,255,255,.14);
    font-size: 15px; color: rgba(255,255,255,.78);
}
.acceso-puntos svg { width: 18px; height: 18px; margin-top: 2px; color: var(--gold-400); }
.acceso-rexy {
    position: absolute; right: -2%; bottom: 0; z-index: 1;
    height: min(52%, 340px); width: auto;
    filter: drop-shadow(0 24px 30px rgba(0,0,0,.35));
    pointer-events: none;
}

.acceso-form { display: grid; place-items: center; padding: clamp(24px, 4vw, 48px) 0; }
.acceso .auth-card {
    max-width: 420px; padding: 0;
    background: transparent; border: 0; box-shadow: none;
}
.acceso .auth-header { text-align: left; margin-bottom: 32px; }
.acceso .auth-header h1, .acceso .auth-header h2 {
    font-size: clamp(34px, 3.2vw, 44px); font-weight: 300; letter-spacing: -.04em; line-height: 1.05; margin-bottom: 10px;
}
.acceso .auth-header p { font-size: 16px; color: var(--ink-muted); }
.acceso .form-group label { font-size: 14px; font-weight: 600; color: var(--ink); }
.acceso .form-group label i { display: none; }
.acceso input[type="email"], .acceso input[type="password"], .acceso input[type="text"],
.acceso input[type="tel"], .acceso select {
    height: 50px; border-radius: 10px; font-size: 16px;
}
.acceso .auth-form .btn { height: 54px; font-size: 16px; margin-top: 6px; background: var(--gold-500); border-color: var(--gold-500); color: var(--navy-900); }
.acceso .auth-form .btn:hover:not(:disabled) { background: var(--gold-400); border-color: var(--gold-400); color: var(--navy-900); }
.acceso .auth-footer { text-align: left; border-top: 1px solid var(--line); margin-top: 28px; padding-top: 20px; }
.acceso .auth-footer p { margin: 0 0 8px; font-size: 15px; color: var(--ink-muted); }
.acceso .auth-footer a { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-color: var(--gold-500); text-underline-offset: 3px; }
.acceso-tutor { margin-top: 14px !important; padding-top: 14px; border-top: 1px dashed var(--line); }
/* El registro es largo: el panel acompaña arriba en vez de estirarse */
.acceso:has(.form-row) .acceso-lado { position: sticky; top: calc(var(--nav-h) + 16px); align-self: start; min-height: calc(100svh - var(--nav-h) - 48px); }

@media (max-width: 900px) {
    .auth-section.acceso { grid-template-columns: 1fr; min-height: 0; padding-top: 8px; gap: 8px; }
    /* En móvil el panel se queda en una franja con el titular */
    .acceso-lado { min-height: 0; padding: 28px 24px 28px; }
    .acceso:has(.form-row) .acceso-lado { position: static; min-height: 0; }
    .acceso-marca { margin-bottom: 14px; }
    .acceso-lado h2 { font-size: 30px; max-width: 16ch; }
    .acceso-puntos, .acceso-rexy { display: none; }
    .acceso-form { padding-top: 24px; }
}
:root[data-theme="dark"] .acceso .auth-footer a { color: var(--ink); }

/* Arreglos: el botón del menú de la página en la que estás (antes salía
   texto oscuro sobre fondo oscuro) y el borde heredado de la sección de acceso */
.nav-link.nav-cta.is-active, .nav-link.nav-cta-main.is-active { background: var(--gold-500); color: var(--navy-900); }
.nav-link.nav-cta:not(.is-active):not(.nav-cta-dorado), .nav-link.nav-cta-main:not(.is-active):not(.nav-cta-dorado) { color: #fff; }
.auth-section.acceso { border: 0; background: none; border-radius: 0; }

/* ---------- 13. Menú con sesión: más secciones, más compacto ----------
   Alumno, tutor y admin tienen hasta 10 entradas más su nombre: con el
   tamaño de la web pública no cabían en un portátil y la página se salía
   de ancho. Aquí va más apretado y a todo el ancho disponible. */
body.con-sesion .nav-container { max-width: 1480px; padding-inline: 24px; gap: 20px; }
body.con-sesion .nav-menu { gap: 16px; }
body.con-sesion .nav-link { font-size: 14px; gap: 6px; }
body.con-sesion .nav-cta, body.con-sesion .nav-cta-main { height: 40px; padding: 0 16px; font-size: 14px; }
body.con-sesion .nav-user { gap: 6px; padding-left: 12px; }
body.con-sesion .logo-badge { display: none; }
@media (min-width: 1025px) and (max-width: 1500px) {
    /* En portátil el nombre del usuario queda solo como icono (con su nombre al pasar por encima) */
    body.con-sesion .nav-user-name { font-size: 0; gap: 0; }
    body.con-sesion .nav-user-name i { font-size: 18px; }
}
@media (min-width: 1025px) and (max-width: 1280px) {
    body.con-sesion .nav-menu { gap: 12px; }
    body.con-sesion .nav-link { font-size: 13px; }
    body.con-sesion .nav-link:not(.nav-cta):not(.nav-cta-main):not(.nav-campana) > i { display: none; }
}


/* ============================================================
   14. LOS EJERCICIOS (curso.php) — tres columnas y la semana tipo
   ============================================================ */
.ejercicios {
    display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
    border-top: 1.5px solid var(--ink);
}
.ejercicios article { padding: 28px 32px 8px 0; }
.ejercicios article + article { padding-left: 32px; border-left: 1px solid var(--line); }
.ejercicios h3 { margin: 0 0 12px; font-size: clamp(28px, 2.8vw, 38px); font-weight: 300; letter-spacing: -.035em; color: var(--ink); }
.ejercicios p { margin: 0; color: var(--ink-muted); font-size: 16px; line-height: 1.65; max-width: 34ch; }

.semana-tipo {
    margin-top: clamp(48px, 6vw, 80px);
    padding: clamp(28px, 4vw, 52px);
    border-radius: var(--r-xl);
    background:
        radial-gradient(60% 90% at 100% 0%, rgba(227,168,27,.14), transparent 70%),
        var(--navy-800);
    color: #fff;
}
.semana-tipo-cab { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 28px; }
.semana-tipo-cab h3 { margin: 0; font-family: var(--font-serif); font-style: italic; font-weight: 400; font-size: 24px; color: var(--gold-400); }
.semana-tipo-enlace { color: #fff; font-weight: 600; font-size: 15px; text-decoration: underline; text-decoration-color: var(--gold-500); text-underline-offset: 4px; }
.semana-tipo-datos { margin: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
.semana-tipo-datos > div { padding: 4px 20px 0 0; }
.semana-tipo-datos > div + div { padding-left: 20px; border-left: 1px solid rgba(255,255,255,.14); }
.semana-tipo-datos dt { font-size: 13px; font-weight: 600; color: rgba(255,255,255,.6); }
.semana-tipo-datos dd { margin: 10px 0 4px; font-size: clamp(26px, 2.6vw, 36px); font-weight: 300; letter-spacing: -.035em; line-height: 1.05; color: #fff; }
.semana-tipo-datos small { font-size: 14px; color: rgba(255,255,255,.6); }
@media (max-width: 900px) {
    .ejercicios { grid-template-columns: 1fr; }
    .ejercicios article, .ejercicios article + article { padding: 22px 0; border-left: 0; border-bottom: 1px solid var(--line); }
    .semana-tipo-datos { grid-template-columns: 1fr 1fr; gap: 22px 0; }
    .semana-tipo-datos > div, .semana-tipo-datos > div + div { padding: 0 12px 0 0; border-left: 0; }
}

/* ============================================================
   15. TEMA A TEMA (curso.php) — índice de libro desplegable
   ============================================================ */
.indice-bloques { border-top: 1.5px solid var(--ink); }
.ib { border-bottom: 1px solid var(--line); }
.ib summary {
    list-style: none; cursor: pointer;
    display: grid; grid-template-columns: 64px minmax(0, 1fr) auto 32px; align-items: baseline; gap: 18px;
    padding: 24px 0;
}
.ib summary::-webkit-details-marker { display: none; }
.ib-n { font-family: var(--font-serif); font-style: italic; font-size: 20px; color: var(--gold-700); }
.ib-t { font-size: clamp(21px, 2.2vw, 30px); font-weight: 300; letter-spacing: -.025em; line-height: 1.2; color: var(--ink); }
.ib-c { font-size: 14px; color: var(--ink-muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ib-mas { position: relative; align-self: center; width: 32px; height: 32px; border-radius: 50%; border: 1px solid var(--line); transition: background-color .2s, border-color .2s; }
.ib-mas::before, .ib-mas::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 1.5px; background: var(--ink); transform: translate(-50%, -50%); transition: transform .3s var(--curva-2026); }
.ib-mas::after { transform: translate(-50%, -50%) rotate(90deg); }
.ib[open] .ib-mas { background: var(--navy-800); border-color: var(--navy-800); }
.ib[open] .ib-mas::before, .ib[open] .ib-mas::after { background: #fff; }
.ib[open] .ib-mas::after { transform: translate(-50%, -50%) rotate(0deg); }
.ib summary:hover .ib-t { color: var(--gold-700); }
.ib summary:focus-visible { outline: 3px solid var(--gold-500); outline-offset: 2px; border-radius: 6px; }
.ib-temas {
    list-style: none; margin: 0; padding: 0 0 28px 82px;
    columns: 2; column-gap: 48px;
}
.ib-temas li { break-inside: avoid; display: grid; grid-template-columns: 44px 1fr; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); font-size: 15px; line-height: 1.5; color: var(--ink-body); }
.ib-temas li span { color: var(--gold-700); font-weight: 600; font-variant-numeric: tabular-nums; }
.ib[open] .ib-temas { animation: ibAbre .35s var(--curva-2026); }
@keyframes ibAbre { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (max-width: 760px) {
    .ib summary { grid-template-columns: 36px minmax(0, 1fr) 32px; }
    .ib-c { display: none; }
    .ib-temas { columns: 1; padding-left: 0; }
}

/* ============================================================
   16. REXY EN LAS PÁGINAS — panel a todo el ancho (como en tests)
   ============================================================ */
.rexy-tira, .rexy-tira.rexy-tira-suave {
    box-sizing: border-box; width: 100%; max-width: none; margin: 0;
    display: grid; grid-template-columns: auto 1fr; align-items: end;
    gap: clamp(24px, 4vw, 64px);
    padding: clamp(28px, 4vw, 48px) clamp(24px, 5vw, 72px) 0;
    background:
        radial-gradient(60% 90% at 12% 100%, rgba(212,160,23,.22), transparent 70%),
        var(--gold-100);
    border: 1px solid rgba(212,160,23,.35);
    border-radius: var(--r-xl);
    overflow: hidden;
}
.rexy-tira .rexy-plinto { margin-bottom: -2px; }
.rexy-tira .rexy-plinto img { height: clamp(220px, 24vw, 310px); width: auto; }
.rexy-tira > div:not(.rexy-plinto) { align-self: center; padding-bottom: clamp(28px, 4vw, 48px); }
.rexy-tira .rexy-tira-eyebrow {
    margin: 0 0 12px !important;
    font-family: var(--font-serif) !important; font-style: italic; font-weight: 400 !important;
    font-size: clamp(20px, 2vw, 26px) !important; color: var(--gold-700) !important;
}
.rexy-tira p:not(.rexy-tira-eyebrow), .rexy-tira.rexy-tira-suave p:not(.rexy-tira-eyebrow) {
    font-size: clamp(19px, 1.9vw, 26px); font-weight: 300; line-height: 1.45; color: var(--ink); max-width: 42ch;
}
@media (max-width: 760px) {
    .rexy-tira, .rexy-tira.rexy-tira-suave { grid-template-columns: 1fr; text-align: center; justify-items: center; padding-top: 32px; }
    .rexy-tira .rexy-plinto { order: 2; }
    .rexy-tira > div:not(.rexy-plinto) { padding-bottom: 0; }
}
:root[data-theme="dark"] .rexy-tira { background: rgba(212,160,23,.08); border-color: rgba(212,160,23,.25); }
:root[data-theme="dark"] .rexy-tira .rexy-tira-eyebrow { color: var(--gold-400) !important; }


/* ============================================================
   17. MODO OSCURO — repaso del acabado 2026
   ------------------------------------------------------------
   Dos cosas fallaban con el tema oscuro:
   · las bandas de tinta (cabeceras, semana tipo, heros, tablero,
     panel de acceso, banner final) eran casi del color del fondo
     y desaparecían: suben un punto de azul y llevan un filo;
   · los botones navy quedaban navy sobre negro: pasan a claros
     con texto de tinta. El oro sigue siendo la acción principal.
   ============================================================ */
:root[data-theme="dark"] :is(.page-hero, .semana-tipo, .mt-hero, .mt-tablero, .hero.hero-tests, .acceso-lado, .cta-banner) {
    background:
        radial-gradient(60% 80% at 85% 20%, rgba(227,168,27,.12), transparent 70%),
        radial-gradient(70% 70% at 0% 100%, rgba(46,106,62,.16), transparent 70%),
        #14233F;
    box-shadow: inset 0 0 0 1px rgba(255,255,255,.07);
}
:root[data-theme="dark"] .cta-banner { box-shadow: none; border-top: 1px solid rgba(255,255,255,.06); }
:root[data-theme="dark"] .footer { background: #060A11; }

:root[data-theme="dark"] :is(.btn-primary, .nav-link.nav-cta:not(.is-active):not(.nav-cta-dorado), .nav-link.nav-cta-main:not(.is-active):not(.nav-cta-dorado)) {
    background: #E8ECF3; border-color: #E8ECF3; color: #0A1426;
}
:root[data-theme="dark"] .btn-primary:hover:not(:disabled) { background: #fff; border-color: #fff; color: #0A1426; }
:root[data-theme="dark"] .cta-content .cta-button:not(.cta-button-alt) { background: var(--gold-500); border-color: var(--gold-500); color: #0A1426; }

/* Portada de tests: la hoja vuelve a ser papel, también de noche */
:root[data-theme="dark"] .hoja-hero { background: #fff; }
:root[data-theme="dark"] .hoja-hero .burbuja { border-color: rgba(28,45,74,.32); color: rgba(28,45,74,.55); }
:root[data-theme="dark"] .hoja-hero .burbuja::after { background: var(--navy-800); }
:root[data-theme="dark"] .hoja-hero::before { background: repeating-linear-gradient(to bottom, var(--navy-800) 0 5px, transparent 5px 16px); }
:root[data-theme="dark"] .hoja-hero-titulo { color: #0A1426; }
:root[data-theme="dark"] .hoja-hero-sub, :root[data-theme="dark"] .hoja-hero-pie p { color: #5B6576; }
:root[data-theme="dark"] .hoja-hero .hoja-num { color: #5B6576; }
/* La semana del hero de Método, igual: es un papel */
:root[data-theme="dark"] .mt-semana { background: #fff; color: #1B2433; }
:root[data-theme="dark"] .mt-semana-tit, :root[data-theme="dark"] .mt-dia { color: #0A1426; }
:root[data-theme="dark"] .mt-semana li, :root[data-theme="dark"] .mt-semana-pie { border-color: #E3E6EC; }
:root[data-theme="dark"] .mt-dia, :root[data-theme="dark"] .mt-barra { background: #F4F5F7; }
:root[data-theme="dark"] .hero-tests .hero-buttons .btn-primary { background: var(--gold-500); border-color: var(--gold-500); color: #0A1426; }

/* ---------- 18. Fondo crema en la web pública ----------
   El blanco puro deslumbraba: el fondo pasa a un crema suave y las
   zonas alternas a un arena claro. Tarjetas y papeles siguen blancos.
   El área del alumno y el panel mantienen su gris. */
body.publico { --surface-page: #FBF8F2; --line: #E6E0D4; }
body.publico .sec-alt, body.publico .mt-dif-sec { background: #F3EEE4; }
body.publico .navbar { background: color-mix(in srgb, #FBF8F2 92%, transparent); }
body.publico .mt-paso-n { background: #FBF8F2; }
:root[data-theme="dark"] body.publico { --line: #22304A; }
:root[data-theme="dark"] body.publico .navbar { background: color-mix(in srgb, var(--surface-card) 92%, transparent); }
:root[data-theme="dark"] body.publico .mt-paso-n { background: var(--surface-page); }


/* ---------- 19. Fondo: crema más apagado (el anterior aún deslumbraba) ---------- */
body.publico { --surface-page: #F5F0E6; --surface-card: #FFFDF8; --line: #E2DACB; }
body.publico .sec-alt, body.publico .mt-dif-sec { background: #ECE5D7; }
body.publico .navbar { background: color-mix(in srgb, #F5F0E6 92%, transparent); }
body.publico .mt-paso-n { background: #F5F0E6; }
:root[data-theme="dark"] body.publico { --surface-card: #111A28; }

/* ============================================================
   20. CONTACTO — formulario limpio + panel de canales
   ============================================================ */
.ct-sec { padding-top: clamp(48px, 6vw, 88px); }
.ct { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.ct-form h2 { margin: 0 0 8px; font-size: clamp(30px, 3vw, 42px); font-weight: 300; letter-spacing: -.04em; color: var(--ink); }
.ct-sub { margin: 0 0 28px; font-size: 16px; color: var(--ink-muted); }
.ct-campos { gap: 18px; }
.ct-campos .form-group label { display: block; margin-bottom: 8px; font-size: 14px; font-weight: 600; color: var(--ink); }
.ct-opc { font-weight: 400; color: var(--ink-muted); }
.ct-campos input[type="text"], .ct-campos input[type="email"], .ct-campos input[type="tel"], .ct-campos select {
    height: 52px; border-radius: 10px; font-size: 16px; background: var(--surface-card);
}
.ct-campos textarea { min-height: 140px; border-radius: 10px; font-size: 16px; background: var(--surface-card); }
.ct-check { font-size: 14px; color: var(--ink-muted); line-height: 1.5; }
.ct-check a { color: var(--ink); text-decoration: underline; text-decoration-color: var(--gold-500); text-underline-offset: 3px; }
.ct-enviar { height: 56px; font-size: 17px; }
.ct-ok { padding: 24px 0; }
.ct-ok-ico { display: inline-grid; place-items: center; width: 56px; height: 56px; border-radius: 50%; background: var(--ok-600); color: #fff; font-size: 22px; margin-bottom: 20px; }
.ct-ok h2 { margin-bottom: 12px; }
.ct-ok p { max-width: 46ch; font-size: 17px; line-height: 1.6; color: var(--ink-muted); }
.ct-ok-acciones { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 24px; }

.ct-lado {
    position: sticky; top: calc(var(--nav-h) + 24px);
    overflow: hidden;
    padding: clamp(28px, 3.5vw, 44px) clamp(24px, 3.5vw, 44px) 0;
    border-radius: var(--r-xl);
    background:
        radial-gradient(60% 60% at 90% 100%, rgba(227,168,27,.2), transparent 70%),
        radial-gradient(70% 60% at 0% 0%, rgba(46,106,62,.2), transparent 70%),
        var(--navy-800);
    color: #fff;
}
.ct-lado-eyebrow { margin: 0 0 16px; font-size: 14px; font-weight: 600; color: var(--gold-400); }
.ct-wa {
    display: flex; align-items: center; gap: 14px;
    padding: 16px 18px; border-radius: 14px;
    background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12);
    color: #fff; text-decoration: none;
    transition: background-color .2s, border-color .2s;
}
.ct-wa:hover { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.25); }
.ct-wa-ico { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: #25D366; color: #fff; font-size: 22px; flex-shrink: 0; }
.ct-wa-txt { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.ct-wa-txt strong { font-size: 17px; font-weight: 600; }
.ct-wa-txt span { font-size: 14px; color: rgba(255,255,255,.7); }
.ct-flecha { color: var(--gold-400); transition: transform .2s; }
.ct-wa:hover .ct-flecha { transform: translateX(4px); }
.ct-canales { list-style: none; margin: 20px 0 0; padding: 0; }
.ct-canales li { border-top: 1px solid rgba(255,255,255,.12); }
.ct-canales a { display: grid; grid-template-columns: 96px 1fr; gap: 12px; align-items: baseline; padding: 14px 0; color: #fff; text-decoration: none; }
.ct-c-et { font-size: 13px; font-weight: 600; color: rgba(255,255,255,.55); }
.ct-c-val { font-size: 15px; color: #fff; overflow-wrap: anywhere; }
.ct-canales a:hover .ct-c-val { color: var(--gold-400); }
.ct-nota { margin: 20px 0 0; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.12); font-size: 14px; line-height: 1.6; color: rgba(255,255,255,.7); max-width: 40ch; }
.ct-nota strong { color: #fff; font-weight: 600; }
.ct-rexy { display: block; height: 200px; width: auto; margin: 12px 0 0 auto; filter: drop-shadow(0 18px 24px rgba(0,0,0,.4)); }
@media (max-width: 900px) {
    .ct { grid-template-columns: 1fr; }
    .ct-lado { position: static; }
    .ct-rexy { height: 160px; }
}
:root[data-theme="dark"] .ct-lado { background: radial-gradient(60% 60% at 90% 100%, rgba(227,168,27,.16), transparent 70%), #14233F; box-shadow: inset 0 0 0 1px rgba(255,255,255,.07); }
.ct-lado .ct-wa-txt strong, .ct-lado .ct-nota strong { color: #fff; }
.ct-sec { padding-bottom: clamp(56px, 7vw, 96px); }
body.publico .main-content > .ct-sec:last-child { margin-bottom: 0; }
.ct-c-val { overflow-wrap: break-word; }
@media (max-width: 520px) { .ct-canales a { grid-template-columns: 76px 1fr; gap: 10px; } .ct-c-val { font-size: 14.5px; } }


/* ============================================================
   21. PREGUNTAS FRECUENTES (faq.php)
   ============================================================ */
.fq-sec { padding-top: clamp(48px, 6vw, 88px); }
.fq { display: grid; grid-template-columns: minmax(0, .72fr) minmax(0, 1.28fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.fq-lado { position: sticky; top: calc(var(--nav-h) + 32px); }
.fq-cuenta { margin: 0 0 20px; font-size: 16px; color: var(--ink-muted); }
.fq-cuenta strong { display: block; font-size: clamp(64px, 7vw, 104px); font-weight: 300; letter-spacing: -.05em; line-height: .9; color: var(--ink); }
.fq-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.fq-buscar { position: relative; display: block; }
.fq-buscar i { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); color: var(--ink-muted); font-size: 15px; pointer-events: none; }
.fq-buscar input {
    width: 100%; height: 54px; padding: 0 18px 0 46px;
    border: 1px solid var(--line); border-radius: 999px; background: var(--surface-card);
    font: inherit; font-size: 16px; color: var(--ink);
    transition: border-color .2s, box-shadow .2s;
}
.fq-buscar input:focus { outline: none; border-color: var(--gold-500); box-shadow: 0 0 0 4px rgba(227,168,27,.18); }
.fq-filtros { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.fq-chip {
    height: 38px; padding: 0 16px; border-radius: 999px;
    border: 1px solid var(--line); background: transparent;
    font: inherit; font-size: 14px; font-weight: 500; color: var(--ink-body); cursor: pointer;
    transition: background-color .2s, border-color .2s, color .2s;
}
.fq-chip:hover { border-color: var(--ink); }
.fq-chip.is-on { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.fq-chip:focus-visible { outline: 3px solid var(--gold-500); outline-offset: 2px; }

.fq-lista { border-top: 1.5px solid var(--ink); }
.fq-item { position: relative; border-bottom: 1px solid var(--line); }
.fq-item::before { content: ""; position: absolute; left: -20px; top: 22px; bottom: 22px; width: 3px; border-radius: 3px; background: var(--gold-500); transform: scaleY(0); transform-origin: top; transition: transform .35s var(--curva-2026); }
.fq-item.is-open::before { transform: scaleY(1); }
.fq-p { margin: 0; }
.fq-p button {
    display: grid; grid-template-columns: 1fr 36px; align-items: center; gap: 24px;
    width: 100%; padding: 26px 0; border: 0; background: none; text-align: left; cursor: pointer;
    font: inherit; font-size: clamp(19px, 1.8vw, 24px); font-weight: 400; letter-spacing: -.02em; line-height: 1.3; color: var(--ink);
}
.fq-p button:hover .fq-p-txt { color: var(--gold-700); }
.fq-p button:focus-visible { outline: 3px solid var(--gold-500); outline-offset: 4px; border-radius: 6px; }
.fq-p-txt { transition: color .2s; }
.fq-mas { position: relative; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); transition: background-color .3s, border-color .3s, transform .4s var(--curva-2026); }
.fq-mas::before, .fq-mas::after { content: ""; position: absolute; left: 50%; top: 50%; width: 13px; height: 1.5px; background: var(--ink); transform: translate(-50%, -50%); transition: background-color .3s; }
.fq-mas::after { transform: translate(-50%, -50%) rotate(90deg); }
.fq-item.is-open .fq-mas { transform: rotate(180deg); background: var(--navy-800); border-color: var(--navy-800); }
.fq-item.is-open .fq-mas::before { background: #fff; }
.fq-item.is-open .fq-mas::after { opacity: 0; }
/* Apertura animada: la fila crece de 0 a su alto real */
.fq-r { display: grid; grid-template-rows: 1fr; }
.fq-js .fq-r { grid-template-rows: 0fr; transition: grid-template-rows .4s var(--curva-2026); }
.fq-js .fq-item.is-open .fq-r { grid-template-rows: 1fr; }
.fq-r > div { overflow: hidden; }
.fq-r-txt { margin: 0; padding: 0 60px 28px 0; max-width: 64ch; font-size: 17px; line-height: 1.7; color: var(--ink-muted); opacity: 1; transition: opacity .3s; }
.fq-js .fq-item:not(.is-open) .fq-r-txt { opacity: 0; }
.fq-lista mark { background: rgba(227,168,27,.3); color: inherit; border-radius: 3px; padding: 0 2px; }
.fq-vacio { padding: 32px 0; }
.fq-vacio p { margin: 0 0 16px; font-size: 17px; color: var(--ink-muted); }
.fq-vacio strong { color: var(--ink); }

.fq-cierre {
    display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 32px;
    padding: clamp(32px, 5vw, 64px) clamp(28px, 5vw, 72px) 0;
    border-radius: var(--r-xl); overflow: hidden;
    background:
        radial-gradient(60% 80% at 90% 100%, rgba(227,168,27,.18), transparent 70%),
        var(--navy-800);
    color: #fff;
}
.fq-cierre > div { padding-bottom: clamp(32px, 5vw, 64px); }
.fq-cierre-eyebrow { margin: 0 0 14px; font-size: 14px; font-weight: 600; color: var(--gold-400); }
.fq-cierre h2 { margin: 0; font-size: clamp(32px, 4vw, 56px); font-weight: 300; letter-spacing: -.045em; line-height: 1.04; color: #fff; max-width: 18ch; }
.fq-cierre h2 em { font-family: var(--font-serif); font-style: italic; font-weight: 400; letter-spacing: -.02em; color: rgba(255,255,255,.72); }
.fq-cierre-acciones { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.fq-btn-hueco { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.35); }
.fq-btn-hueco:hover { border-color: #fff; color: #fff; }
.fq-cierre img { height: clamp(200px, 22vw, 290px); width: auto; filter: drop-shadow(0 20px 26px rgba(0,0,0,.4)); }

@media (max-width: 900px) {
    .fq { grid-template-columns: 1fr; }
    .fq-lado { position: static; }
    .fq-cuenta strong { font-size: 56px; }
    .fq-item::before { left: -12px; }
    .fq-r-txt { padding-right: 0; }
    .fq-cierre { grid-template-columns: 1fr; }
    .fq-cierre img { justify-self: end; height: 180px; margin-top: -40px; }
}
@media (prefers-reduced-motion: reduce) {
    .fq-js .fq-r, .fq-item::before, .fq-mas, .fq-r-txt { transition: none; }
}
:root[data-theme="dark"] .fq-cierre { background: radial-gradient(60% 80% at 90% 100%, rgba(227,168,27,.14), transparent 70%), #14233F; box-shadow: inset 0 0 0 1px rgba(255,255,255,.07); }
:root[data-theme="dark"] .fq-chip.is-on { background: var(--gold-500); border-color: var(--gold-500); color: #0A1426; }
:root[data-theme="dark"] .fq-item.is-open .fq-mas { background: var(--gold-500); border-color: var(--gold-500); }
:root[data-theme="dark"] .fq-item.is-open .fq-mas::before { background: #0A1426; }
:root[data-theme="dark"] .fq-mas::before, :root[data-theme="dark"] .fq-mas::after { background: var(--ink); }


/* ============================================================
   22. QUÉ INCLUYE (curso.php) — recorrido por el área
   ============================================================ */
.qi { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: clamp(28px, 4vw, 64px); align-items: start; }
.qi-grupo + .qi-grupo { margin-top: 26px; }
.qi-grupo-t { margin: 0 0 6px; font-family: var(--font-serif); font-style: italic; font-size: 18px; color: var(--gold-700); }
.qi-grupo ul { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.qi-grupo li { border-bottom: 1px solid var(--line); }
.qi-item {
    position: relative; display: grid; grid-template-columns: 28px 1fr; align-items: center; column-gap: 14px;
    width: 100%; padding: 14px 12px 14px 14px; border: 0; background: none; text-align: left; cursor: pointer;
    font: inherit; color: var(--ink-body); border-radius: 10px;
    transition: background-color .25s, color .25s;
}
.qi-item i { font-size: 15px; color: var(--ink-muted); text-align: center; transition: color .25s, transform .3s var(--curva-2026); }
.qi-nombre { font-size: 18px; font-weight: 400; letter-spacing: -.015em; color: var(--ink); }
.qi-desc { grid-column: 2; margin-top: 4px; font-size: 15px; line-height: 1.55; color: var(--ink-muted); }
.qi-desc em { font-style: normal; font-weight: 600; color: var(--gold-700); }
.qi-item::after { content: "\2192"; position: absolute; right: 14px; top: 50%; transform: translate(-6px, -50%); opacity: 0; color: var(--gold-700); transition: opacity .25s, transform .3s var(--curva-2026); }
.qi-item:focus-visible { outline: 3px solid var(--gold-500); outline-offset: 2px; }
/* Con JS en escritorio: la descripción vive en la ventana */
.qi-js .qi-desc { display: none; }
.qi-js .qi-item.is-on { background: var(--surface-card); box-shadow: inset 3px 0 0 var(--gold-500); }
.qi-js .qi-item.is-on i { color: var(--gold-700); transform: scale(1.12); }
.qi-js .qi-item.is-on::after { opacity: 1; transform: translate(0, -50%); }

.qi-ventana {
    position: sticky; top: calc(var(--nav-h) + 32px);
    min-height: 460px; overflow: hidden;
    border-radius: var(--r-xl);
    background:
        radial-gradient(60% 70% at 90% 100%, rgba(227,168,27,.2), transparent 70%),
        radial-gradient(70% 60% at 0% 0%, rgba(46,106,62,.22), transparent 70%),
        var(--navy-800);
    color: #fff;
}
.qi-barra { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px 22px; border-bottom: 1px solid rgba(255,255,255,.1); }
.qi-barra-t { font-size: 13px; font-weight: 600; color: rgba(255,255,255,.6); }
.qi-barra-t span { color: var(--gold-400); }
.qi-progreso { width: 90px; height: 3px; border-radius: 3px; background: rgba(255,255,255,.12); overflow: hidden; }
.qi-progreso span { display: block; height: 100%; background: var(--gold-500); transform: scaleX(0); transform-origin: left; }
.qi-ventana.corre .qi-progreso span { animation: qiCorre 4.2s linear forwards; }
@keyframes qiCorre { to { transform: scaleX(1); } }
.qi-cuerpo { position: relative; z-index: 1; padding: clamp(32px, 4vw, 56px); max-width: 30em; }
.qi-cuerpo.is-in > * { animation: qiEntra .5s var(--curva-2026) both; }
.qi-cuerpo.is-in > :nth-child(2) { animation-delay: .05s; }
.qi-cuerpo.is-in > :nth-child(3) { animation-delay: .1s; }
@keyframes qiEntra { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.qi-ico { display: inline-grid; place-items: center; width: 72px; height: 72px; border-radius: 20px; background: rgba(227,168,27,.14); color: var(--gold-400); font-size: 30px; margin-bottom: 28px; box-shadow: inset 0 0 0 1px rgba(227,168,27,.3); }
.qi-cuerpo h3 { margin: 0 0 14px; font-size: clamp(32px, 3.4vw, 48px); font-weight: 300; letter-spacing: -.045em; line-height: 1.02; color: #fff; }
.qi-cuerpo p { margin: 0; font-size: 18px; line-height: 1.6; color: rgba(255,255,255,.74); max-width: 32ch; }
.qi-nota { display: inline-block; margin-top: 20px; padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); font-size: 13px; font-weight: 600; color: var(--gold-400); }
.qi-rexy { position: absolute; right: 4%; bottom: 0; height: 190px; width: auto; opacity: 0; transform: translateY(20px); transition: opacity .4s, transform .5s var(--curva-2026); filter: drop-shadow(0 18px 24px rgba(0,0,0,.4)); pointer-events: none; }
.qi-ventana.con-rexy .qi-rexy { opacity: 1; transform: none; }

@media (max-width: 900px) {
    .qi { grid-template-columns: 1fr; }
    .qi-ventana { display: none; }
    .qi-js .qi-desc { display: block; }
    .qi-js .qi-item.is-on { background: none; box-shadow: none; }
    .qi-js .qi-item.is-on i { color: var(--gold-700); transform: none; }
    .qi-item::after { display: none; }
    .qi-item { align-items: start; cursor: default; }
    .qi-item i { margin-top: 4px; }
}
@media (prefers-reduced-motion: reduce) {
    .qi-cuerpo.is-in > * { animation: none; }
    .qi-ventana.corre .qi-progreso span { animation: none; }
}
:root[data-theme="dark"] .qi-ventana { background: radial-gradient(60% 70% at 90% 100%, rgba(227,168,27,.16), transparent 70%), #14233F; box-shadow: inset 0 0 0 1px rgba(255,255,255,.07); }
:root[data-theme="dark"] .qi-js .qi-item.is-on { background: var(--surface-subtle); }
:root[data-theme="dark"] .qi-grupo-t, :root[data-theme="dark"] .qi-desc em { color: var(--gold-400); }
:root[data-theme="dark"] .qi-js .qi-item.is-on i { color: var(--gold-400); }
.qi-nota[hidden] { display: none; }


/* ============================================================
   23. QUÉ INCLUYE — mini pantallas animadas del área
   ------------------------------------------------------------
   Cada herramienta enseña lo que ve el alumno: una pantalla clara,
   como el área de verdad, que se anima al mostrarse. Datos de
   ejemplo. Con "reducir movimiento" se ve el estado final.
   ============================================================ */
@property --n { syntax: "<integer>"; inherits: false; initial-value: 0; }
.qi-ventana { min-height: 0; display: flex; flex-direction: column; }
.qi-ventana.corre .qi-progreso span { animation-duration: 5.6s; }
.qi-pantalla { position: relative; margin: 22px 22px 0; height: 270px; border-radius: 14px; background: #FBFAF7; color: #1B2433; overflow: hidden; box-shadow: 0 20px 40px -18px rgba(0,0,0,.55); }
.qi-mock { position: absolute; inset: 0; padding: 20px 22px; display: flex; flex-direction: column; gap: 10px; opacity: 0; visibility: hidden; transition: opacity .35s; font-size: 14px; }
.qi-mock.is-on { opacity: 1; visibility: visible; }
.qi-pie { padding: 26px clamp(24px, 3vw, 36px) 30px; }
.qi-pie.is-in > * { animation: qiEntra .5s var(--curva-2026) both; }
.qi-pie.is-in > :nth-child(2) { animation-delay: .05s; }
.qi-pie h3 { margin: 0 0 8px; font-size: clamp(26px, 2.6vw, 36px); font-weight: 300; letter-spacing: -.04em; line-height: 1.05; color: #fff; }
.qi-pie p { margin: 0; font-size: 16px; line-height: 1.6; color: rgba(255,255,255,.74); max-width: 42ch; }
.qi-pie .qi-nota { margin-top: 14px; }

/* Piezas comunes */
.mk-tit { margin: 0 0 2px; font-size: 12px; font-weight: 700; color: #5B6576; }
.mk-cab { display: flex; justify-content: space-between; align-items: center; font-size: 12px; font-weight: 700; color: #5B6576; }
.qi-mock mark { background: rgba(227,168,27,.35); color: inherit; border-radius: 3px; padding: 0 2px; }
.mk-sube { opacity: 0; }
@keyframes mkSube { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes mkAncho { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@keyframes mkPop { 0% { transform: scale(0); } 70% { transform: scale(1.15); } 100% { transform: scale(1); } }
.qi-mock.is-on :is(.mk-fila, .mk-arch, .mk-res, .mk-tarea) { animation: mkSube .45s var(--curva-2026) both; animation-delay: calc(.25s + var(--d) * .22s); }

/* Temario: vídeo que avanza y temas con su barra */
.mk-video { position: relative; height: 112px; border-radius: 10px; background: linear-gradient(135deg, #15264A, #22365F); display: grid; place-items: center; overflow: hidden; }
.mk-play { width: 42px; height: 42px; border-radius: 50%; background: rgba(255,255,255,.95); position: relative; }
.mk-play::after { content: ""; position: absolute; left: 16px; top: 12px; border-left: 14px solid #0D1A30; border-top: 9px solid transparent; border-bottom: 9px solid transparent; }
.mk-temario.is-on .mk-play { animation: mkLate 1.6s ease-in-out .3s 2; }
@keyframes mkLate { 50% { transform: scale(1.12); } }
.mk-vt { position: absolute; left: 12px; top: 10px; font-size: 11px; font-weight: 600; color: rgba(255,255,255,.8); }
.mk-vbar { position: absolute; left: 12px; right: 12px; bottom: 10px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.2); overflow: hidden; }
.mk-vbar span { display: block; height: 100%; width: 100%; background: #E3A81B; transform-origin: left; transform: scaleX(.1); }
.mk-temario.is-on .mk-vbar span { animation: mkVid 5s linear .3s both; }
@keyframes mkVid { from { transform: scaleX(.1); } to { transform: scaleX(.75); } }
.mk-lista { display: grid; gap: 7px; }
.mk-fila { display: grid; grid-template-columns: 1fr 90px; align-items: center; gap: 10px; font-size: 13px; }
.mk-bar { height: 6px; border-radius: 6px; background: #ECE5D7; overflow: hidden; }
.mk-bar span { display: block; height: 100%; width: var(--w); background: #2E6A3E; transform-origin: left; transform: scaleX(0); }
.mk-temario.is-on .mk-bar span { animation: mkAncho .8s var(--curva-2026) both; animation-delay: calc(.6s + var(--d, 0) * .25s); }
.mk-fila:nth-child(2) .mk-bar span { --d: 1; } .mk-fila:nth-child(3) .mk-bar span { --d: 2; }

/* Material: archivos que llegan; el último se descarga */
.mk-arch { display: grid; grid-template-columns: 36px 1fr 22px; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; background: #fff; border: 1px solid #E6E0D4; font-size: 13px; }
.mk-ic { display: grid; place-items: center; height: 30px; border-radius: 7px; font-size: 10px; font-weight: 800; color: #fff; }
.mk-pdf { background: #B91C1C; } .mk-vid { background: #22365F; font-size: 12px; }
.mk-dl { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid #CDD2DB; position: relative; }
.mk-dl::after { content: ""; position: absolute; left: 6px; top: 3px; width: 5px; height: 8px; border: solid #5B6576; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg) scale(.0); }
.mk-material.is-on .mk-baja .mk-dl { animation: mkDescarga .4s ease 1.8s both; }
.mk-material.is-on .mk-baja .mk-dl::after { animation: mkPopCheck .3s ease 2.1s both; }
@keyframes mkDescarga { to { background: #2E6A3E; border-color: #2E6A3E; } }
@keyframes mkPopCheck { to { transform: rotate(45deg) scale(1); border-color: #fff; } }

/* Apuntes: la nota se escribe sola y aparece el subrayado */
.mk-nota { padding: 16px; border-radius: 10px; background: #FFFDF5; border: 1px solid #EFE4C6; flex: 1; }
.mk-escribe { margin: 0; font-family: var(--font-serif); font-size: 15px; line-height: 1.6; }
.mk-escribe span { display: inline; background: linear-gradient(#FFFDF5, #FFFDF5) right / 100% 100% no-repeat; }
.mk-apuntes.is-on .mk-escribe span { animation: mkDestapa 2.2s steps(40) .3s both; }
@keyframes mkDestapa { from { background-size: 100% 100%; } to { background-size: 0% 100%; } }
.mk-escribe mark { background: linear-gradient(rgba(227,168,27,.4), rgba(227,168,27,.4)) left / 0% 100% no-repeat; }
.mk-apuntes.is-on .mk-escribe mark { animation: mkSubraya .6s ease 2.6s both; }
@keyframes mkSubraya { to { background-size: 100% 100%; } }
.mk-gris { margin: 10px 0 0; font-size: 13px; color: #8A93A3; opacity: 0; }
.mk-apuntes.is-on .mk-gris { animation: mkSube .4s ease 3.2s both; }

/* Buscar: se teclea y salen los resultados */
.mk-input { display: flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px; border-radius: 999px; background: #fff; border: 1.5px solid #E3A81B; font-size: 14px; }
.mk-lupa { width: 12px; height: 12px; border: 2px solid #5B6576; border-radius: 50%; position: relative; flex-shrink: 0; }
.mk-lupa::after { content: ""; position: absolute; width: 2px; height: 6px; background: #5B6576; right: -4px; bottom: -5px; transform: rotate(-45deg); }
.mk-teclea { display: inline-block; overflow: hidden; white-space: nowrap; width: 23ch; }
.mk-buscar.is-on .mk-teclea { animation: mkTeclea 1.4s steps(23) .2s both; }
@keyframes mkTeclea { from { width: 0; } to { width: 23ch; } }
.mk-cursor { width: 1.5px; height: 18px; background: #0D1A30; animation: mkParpadea 1s steps(1) infinite; }
@keyframes mkParpadea { 50% { opacity: 0; } }
.mk-res { padding: 9px 12px; border-radius: 9px; background: #fff; border: 1px solid #E6E0D4; font-size: 13px; }
.mk-buscar.is-on .mk-res { animation-delay: calc(1.7s + var(--d) * .2s); }

/* Tests: se marca la buena y sube el marcador */
.mk-preg { margin: 2px 0; font-weight: 600; font-size: 14px; line-height: 1.45; }
.mk-op { padding: 9px 12px; border-radius: 9px; border: 1px solid #E6E0D4; background: #fff; font-size: 13px; }
.mk-tests.is-on .mk-buena { animation: mkBuena .4s ease 1.2s both; }
@keyframes mkBuena { to { background: #ECFDF3; border-color: #15803D; color: #15803D; font-weight: 600; } }
.mk-marca { font-size: 14px; color: #0D1A30; }
.mk-cuenta-ok { --n: 7; counter-reset: n var(--n); }
.mk-cuenta-ok::after { content: counter(n); }
.mk-tests.is-on .mk-cuenta-ok { animation: mkSuma .3s steps(1) 1.6s both; }
@keyframes mkSuma { from { --n: 7; } to { --n: 8; } }

/* Casos: correcciones en rojo y la nota estampada */
.mk-estado { padding: 3px 9px; border-radius: 999px; background: #ECFDF3; color: #15803D; font-size: 11px; }
.mk-doc { position: relative; flex: 1; padding: 16px; border-radius: 10px; background: #fff; border: 1px solid #E6E0D4; display: flex; flex-direction: column; gap: 9px; }
.mk-l { height: 7px; border-radius: 4px; background: #E9E4D8; }
.mk-rojo-sub { position: relative; }
.mk-rojo-sub::after { content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 2px; background: #B91C1C; transform-origin: left; transform: scaleX(0); }
.mk-casos.is-on .mk-rojo-sub::after { animation: mkAncho .6s ease .7s both; }
.mk-coment { align-self: flex-start; margin-top: 4px; padding: 6px 10px; border-radius: 8px; background: #FEF2F2; color: #B91C1C; font-family: var(--font-serif); font-style: italic; font-size: 13px; opacity: 0; }
.mk-casos.is-on .mk-coment { animation: mkSube .4s ease 1.3s both; }
.mk-nota-sello { position: absolute; right: 16px; bottom: 14px; width: 58px; height: 58px; border-radius: 50%; border: 2.5px solid #B91C1C; color: #B91C1C; display: grid; place-items: center; font-family: var(--font-serif); font-weight: 700; font-size: 20px; transform: rotate(-12deg) scale(0); }
.mk-casos.is-on .mk-nota-sello { animation: mkSello .45s cubic-bezier(.3,1.5,.5,1) 2s both; }
@keyframes mkSello { to { transform: rotate(-12deg) scale(1); } }

/* Progreso: barras por bloque y el porcentaje que sube */
.mk-pct { font-size: 22px; font-weight: 300; color: #0D1A30; letter-spacing: -.03em; }
.mk-cuenta-pct { --n: 47; counter-reset: n var(--n); }
.mk-cuenta-pct::after { content: counter(n); }
.mk-progreso.is-on .mk-cuenta-pct { animation: mkPct 1.6s ease-out .3s both; }
@keyframes mkPct { from { --n: 0; } to { --n: 47; } }
.mk-barras { flex: 1; display: grid; grid-template-columns: repeat(7, 1fr); align-items: end; gap: 10px; padding-top: 10px; }
.mk-barras span { position: relative; height: var(--h); border-radius: 6px 6px 2px 2px; background: linear-gradient(#E3A81B, #C99413); transform-origin: bottom; transform: scaleY(0); }
.mk-progreso.is-on .mk-barras span { animation: mkCrece .7s var(--curva-2026) both; animation-delay: calc(.3s + var(--d) * .12s); }
@keyframes mkCrece { to { transform: scaleY(1); } }
.mk-barras i { position: absolute; bottom: -18px; left: 0; right: 0; text-align: center; font-family: var(--font-serif); font-size: 11px; color: #8A93A3; }
.mk-barras { padding-bottom: 18px; }

/* Plan: tareas que se tachan */
.mk-tarea { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 9px; background: #fff; border: 1px solid #E6E0D4; font-size: 13px; }
.mk-cb { position: relative; width: 18px; height: 18px; border-radius: 5px; border: 1.5px solid #CDD2DB; flex-shrink: 0; }
.mk-cb::after { content: ""; position: absolute; inset: -1.5px; border-radius: 5px; background: #2E6A3E url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round' d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center/13px no-repeat; transform: scale(0); }
.mk-calendario.is-on .mk-tarea:not(.mk-pend) .mk-cb::after { animation: mkPop .3s ease both; animation-delay: calc(1s + var(--d) * .5s); }
.mk-calendario.is-on .mk-tarea:not(.mk-pend) span:last-child { animation: mkTachado .3s ease both; animation-delay: calc(1.1s + var(--d) * .5s); }
@keyframes mkTachado { to { color: #8A93A3; text-decoration: line-through; } }
.mk-pend { border-color: #E3A81B; background: #FFFBEF; }

/* Chat: tú preguntas, el tutor escribe y contesta */
.qi-mock :is(.mk-chat, .mk-rexy) { justify-content: flex-end; }
.mk-chat, .mk-rexy { justify-content: flex-end; }
.mk-msg { max-width: 82%; padding: 10px 13px; border-radius: 14px; font-size: 13px; line-height: 1.45; opacity: 0; }
.mk-yo { align-self: flex-end; background: #0D1A30; color: #fff; border-bottom-right-radius: 4px; }
.mk-el { align-self: flex-start; background: #fff; border: 1px solid #E6E0D4; border-bottom-left-radius: 4px; }
.mk-el b { display: block; font-size: 11px; color: #9A6C05; margin-bottom: 2px; }
.qi-mock.is-on .mk-yo { animation: mkSube .4s ease .3s both; }
.mk-escribiendo { align-self: flex-start; display: flex; gap: 4px; padding: 10px 13px; border-radius: 14px; background: #fff; border: 1px solid #E6E0D4; opacity: 0; }
.mk-escribiendo span { width: 6px; height: 6px; border-radius: 50%; background: #8A93A3; animation: mkPunto 1s ease-in-out infinite; }
.mk-escribiendo span:nth-child(2) { animation-delay: .15s; } .mk-escribiendo span:nth-child(3) { animation-delay: .3s; }
@keyframes mkPunto { 50% { transform: translateY(-4px); opacity: .5; } }
.mk-chat.is-on .mk-escribiendo { animation: mkAparecePlega 1.6s ease .9s both; }
@keyframes mkAparecePlega { 0% { opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; max-height: 40px; } 100% { opacity: 0; max-height: 0; padding: 0; margin: -5px 0; border-width: 0; } }
.mk-chat.is-on .mk-el { animation: mkSube .4s ease 2.5s both; }
.mk-rx { align-self: flex-start; display: flex; gap: 8px; align-items: flex-start; background: #fff; border: 1px solid #EFE4C6; border-bottom-left-radius: 4px; }
.mk-rx img { width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; }
.mk-rexy.is-on .mk-rx { animation: mkSube .4s ease 1.4s both; }

/* Clases: en directo, asistentes y reloj */
.mk-vivo { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; background: #FEF2F2; color: #B91C1C; }
.mk-vivo i { width: 8px; height: 8px; border-radius: 50%; background: #DC2626; animation: mkLatido 1.2s ease-in-out infinite; }
@keyframes mkLatido { 50% { box-shadow: 0 0 0 6px rgba(220,38,38,.18); } }
.mk-reloj { font-variant-numeric: tabular-nums; color: #0D1A30; }
.mk-cuenta-min { --n: 12; counter-reset: n var(--n); }
.mk-cuenta-min::after { content: counter(n, decimal-leading-zero); }
.mk-clases.is-on .mk-cuenta-min { animation: mkMin 5s linear both; }
@keyframes mkMin { from { --n: 12; } to { --n: 17; } }
.mk-clase { flex: 1; border-radius: 10px; background: linear-gradient(135deg, #15264A, #2C4165); display: grid; place-items: end start; padding: 14px; color: #fff; font-weight: 600; font-size: 14px; }
.mk-asist { display: flex; }
.mk-asist span { width: 32px; height: 32px; margin-right: -8px; border-radius: 50%; border: 2px solid #FBFAF7; background: #22365F; color: #fff; display: grid; place-items: center; font-size: 10px; font-weight: 700; transform: scale(0); }
.mk-asist span:last-child { background: #E3A81B; color: #0D1A30; }
.mk-clases.is-on .mk-asist span { animation: mkPop .3s ease both; }
.mk-clases.is-on .mk-asist span:nth-child(1) { animation-delay: .4s; } .mk-clases.is-on .mk-asist span:nth-child(2) { animation-delay: .55s; }
.mk-clases.is-on .mk-asist span:nth-child(3) { animation-delay: .7s; } .mk-clases.is-on .mk-asist span:nth-child(4) { animation-delay: .85s; }

/* Tutorías: eliges hueco y queda confirmada */
.mk-huecos { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mk-huecos span { padding: 14px 6px; border-radius: 10px; border: 1px solid #E6E0D4; background: #fff; text-align: center; font-size: 13px; font-weight: 600; }
.mk-tutorias.is-on .mk-elegido { animation: mkElige .35s ease 1s both; }
@keyframes mkElige { to { background: #0D1A30; border-color: #0D1A30; color: #fff; transform: scale(1.04); } }
.mk-confirma { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 10px; background: #ECFDF3; color: #15803D; font-weight: 600; font-size: 13px; opacity: 0; }
.mk-tutorias.is-on .mk-confirma { animation: mkSube .4s ease 1.7s both; }
.mk-ok { width: 20px; height: 20px; border-radius: 50%; background: #15803D url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round' d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center/13px no-repeat; flex-shrink: 0; }

/* Menos movimiento: estado final, sin animar */
@media (prefers-reduced-motion: reduce) {
    .qi-mock *, .qi-mock *::after { animation: none !important; }
    .qi-mock :is(.mk-fila, .mk-arch, .mk-res, .mk-tarea, .mk-msg, .mk-coment, .mk-confirma, .mk-gris) { opacity: 1; }
    .mk-bar span, .mk-barras span, .mk-asist span { transform: none; }
    .mk-nota-sello { transform: rotate(-12deg); }
    .mk-escribiendo { display: none; }
}


/* ---------- 24. Iconos de marca sin la fuente de marcas (nov. 2026) ----------
   Solo se usan tres (WhatsApp, Instagram, Google) y la fuente
   fa-brands pesa 115 KB. Se pintan con una máscara SVG en el color del
   texto; al no quedar ningún glifo .fab, el navegador no descarga la
   fuente. Si se añade otro icono de marca, hay que añadirlo aquí. */
.fab { font-family: inherit !important; font-weight: normal !important; }
.fab.fa-whatsapp::before, .fab.fa-instagram::before, .fab.fa-google::before {
    content: "" !important; display: inline-block; width: 1em; height: 1em; vertical-align: -.125em;
    background: currentColor;
    -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat;
}
.fab.fa-whatsapp { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a10 10 0 00-8.6 15.1L2 22l5-1.3A10 10 0 1012 2zm0 18.2c-1.5 0-3-.4-4.3-1.2l-.3-.2-3 .8.8-2.9-.2-.3A8.2 8.2 0 1112 20.2zm4.5-6.1c-.2-.1-1.5-.7-1.7-.8-.2-.1-.4-.1-.6.1l-.8 1c-.1.2-.3.2-.5.1a6.7 6.7 0 01-3.3-2.9c-.2-.4.2-.4.7-1.3.1-.2 0-.3 0-.4l-.8-1.8c-.2-.5-.4-.4-.6-.4h-.5c-.2 0-.4.1-.6.3-.2.2-.8.8-.8 2s.8 2.3.9 2.5c.1.2 1.6 2.5 4 3.5 1.5.6 2.1.7 2.8.6.5-.1 1.5-.6 1.7-1.2.2-.6.2-1.1.1-1.2l-.4-.2z'/%3E%3C/svg%3E"); }
.fab.fa-instagram { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 7a5 5 0 100 10 5 5 0 000-10zm0 8.2a3.2 3.2 0 110-6.4 3.2 3.2 0 010 6.4zM17.3 5.5a1.2 1.2 0 100 2.4 1.2 1.2 0 000-2.4zM12 3.8c2.7 0 3 0 4 .1 2.7.1 4 1.4 4.1 4.1.1 1 .1 1.3.1 4s0 3-.1 4c-.1 2.7-1.4 4-4.1 4.1-1 .1-1.3.1-4 .1s-3 0-4-.1c-2.7-.1-4-1.4-4.1-4.1-.1-1-.1-1.3-.1-4s0-3 .1-4C3.9 5.3 5.3 4 8 3.9c1-.1 1.3-.1 4-.1zM12 2c-2.7 0-3.1 0-4.1.1C4.2 2.2 2.2 4.2 2.1 7.9 2 8.9 2 9.3 2 12s0 3.1.1 4.1c.1 3.7 2.1 5.7 5.8 5.8 1 .1 1.4.1 4.1.1s3.1 0 4.1-.1c3.7-.1 5.7-2.1 5.8-5.8.1-1 .1-1.4.1-4.1s0-3.1-.1-4.1c-.1-3.7-2.1-5.7-5.8-5.8C15.1 2 14.7 2 12 2z'/%3E%3C/svg%3E"); }
.fab.fa-google { --ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M21.6 12.2c0-.7-.1-1.4-.2-2H12v3.8h5.4a4.6 4.6 0 01-2 3v2.5h3.2c1.9-1.7 3-4.3 3-7.3zM12 22c2.7 0 5-.9 6.6-2.4l-3.2-2.5c-.9.6-2 1-3.4 1-2.6 0-4.8-1.8-5.6-4.1H3.1v2.6A10 10 0 0012 22zM6.4 14a6 6 0 010-3.9V7.5H3.1a10 10 0 000 9zM12 6c1.5 0 2.8.5 3.8 1.5l2.9-2.9A10 10 0 003.1 7.5L6.4 10C7.2 7.7 9.4 6 12 6z'/%3E%3C/svg%3E"); }
