/* ═══════════════════════════════════════════════════════════════
   VISTA "ALUMNO" (guiada) — rediseño Luz y Saber (mockup Stitch)
   Todo el scope vive bajo body.hsa-student-view: la vista clásica
   queda intacta cuando la clase no está presente.

   Tokens (del tailwind-config del mockup = luz-saber.css):
     surface #f9f9fb · surface-container-low #f3f3f5 · container #edeef0
     container-high #e8e8ea · highest #e2e2e4 · outline-variant #c4c7c7
     primary #000/#1a1c1d · secondary #735c00 · secondary-container #fed65b
     on-secondary-container #745c00 · success #10B981 · error #EF4444
     Manrope (titulares) · Inter (cuerpo) · Material Symbols (iconos)
   ═══════════════════════════════════════════════════════════════ */

/* ── Anti-FOUC: el template pone html.hsa-sv-pending; el JS la quita ── */
html.hsa-sv-pending .hsa-article .entry-content,
html.hsa-sv-pending #hsa-sidebar {
    visibility: hidden;
}

/* ── Toggle de vistas (hero) — visible en ambos modos ── */
.hsa-sv-toggle {
    display: inline-flex;
    gap: 4px;
    margin-top: 1rem;
    padding: 4px;
    background: #edeef0;
    border-radius: 8px;
}
.hsa-sv-toggle-btn {
    border: none;
    background: transparent;
    padding: 7px 16px;
    border-radius: 6px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.72rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #444748;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}
.hsa-sv-toggle-btn:hover:not(.is-disabled) { color: #1a1c1d; }
.hsa-sv-toggle-btn.is-active {
    background: #1a1c1d !important;
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}
.hsa-sv-toggle-btn.is-disabled { opacity: 0.4; cursor: not-allowed; }

/* ═══════════════════════════════════════════════════════════════
   1. SHELL — fondo, hero compacto, hueco para el footer sticky
   ═══════════════════════════════════════════════════════════════ */
body.hsa-student-view { padding-bottom: 96px; }
body.hsa-student-view .hsa-activity-page { background: #f9f9fb !important; }

/* Sin banda superior: el contenido llega directo hasta el header. El hero
   sigue en el DOM (buildSidebar lee su título/badge) pero no se muestra.
   La regla html.hsa-sv-pending evita el parpadeo antes de montar la vista. */
body.hsa-student-view .hsa-hero-wrap,
html.hsa-sv-pending .hsa-hero-wrap { display: none !important; }
body.hsa-student-view .hsa-crumbs-wrap,
html.hsa-sv-pending .hsa-crumbs-wrap { display: none !important; }

/* Grid: sidebar 256px pegado al borde izquierdo + zona de contenido a ancho
   completo (sin centrado), responsive vía los breakpoints más abajo */
body.hsa-student-view #hsa-sidebar { display: none !important; }
body.hsa-student-view .hsa-outer { padding: 0; }
body.hsa-student-view .hsa-grid {
    grid-template-columns: 256px minmax(0, 1fr);
    gap: 0;
    max-width: none;
    margin: 0;
    align-items: stretch;
}
body.hsa-student-view .hsa-grid > * { min-width: 0; }
body.hsa-student-view .hsa-content-zone {
    max-width: none !important;
    padding: 2.5rem 1.5rem 3rem;
    background: #f9f9fb;
}

/* El contenedor del contenido pierde su tarjeta del template:
   la "tarjeta" es cada paso; centrado a 720px (por defecto), 960 en pasos
   de lectura (body.hsa-sv-wide-step) */
body.hsa-student-view .hsa-article .entry-content {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
    max-width: min(900px, 100%);
    margin: 0 auto;
    transition: max-width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
body.hsa-student-view.hsa-sv-wide-step .hsa-article .entry-content,
body.hsa-student-view.hsa-sv-wide-step #hsa-sv-stephead {
    max-width: min(1080px, 100%);
}
/* Pasos de ejercicio: ancho extra fluido (llena la columna en portátiles,
   se limita en monitores grandes). Va después → gana ante wide-step. */
body.hsa-student-view.hsa-sv-exercise-step .hsa-article .entry-content,
body.hsa-student-view.hsa-sv-exercise-step #hsa-sv-stephead {
    max-width: min(1240px, 100%);
}
body.hsa-student-view .entry-content .container {
    max-width: none !important;
    width: auto !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
}

/* ═══════════════════════════════════════════════════════════════
   2. CABECERA DEL PASO — chip + titular (fuera de la tarjeta)
   ═══════════════════════════════════════════════════════════════ */
#hsa-sv-stephead {
    display: none;
    max-width: min(900px, 100%);
    margin: 0 auto 1.5rem;
    text-align: center;
    transition: max-width 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
body.hsa-student-view #hsa-sv-stephead { display: block; }
.hsa-sv-chip {
    display: inline-block;
    padding: 4px 12px;
    background: rgba(254, 214, 91, 0.3);
    color: #735c00;
    font-family: 'Inter', sans-serif;
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.04em;
    font-weight: 500;
    border-radius: 9999px;
    margin-bottom: 8px;
}
.hsa-sv-headline {
    font-family: 'Manrope', 'Inter', sans-serif !important;
    font-size: 32px !important;
    line-height: 40px !important;
    letter-spacing: -0.01em !important;
    font-weight: 700 !important;
    color: #1a1c1d !important;
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
}

/* El h2 del contenido cuyo texto ya está en la cabecera se oculta */
body.hsa-student-view .hsa-sv-h2-hoisted { display: none !important; }

/* La cabecera interna del ejercicio (badge numérico + título + dificultad)
   duplica al chip/titular de la cabecera del paso */
body.hsa-student-view .hsa-step-current .exercise-header { display: none !important; }

/* ═══════════════════════════════════════════════════════════════
   3. MOTOR DE PASOS — visibilidad y tarjeta
   ═══════════════════════════════════════════════════════════════ */
body.hsa-student-view .hsa-step-hidden { display: none !important; }
body.hsa-student-view .hsa-q-hidden,
body.hsa-student-view .hsa-q-tail-hidden { display: none !important; }

/* Elementos del contenido que duplican al hero o al progreso propio */
body.hsa-student-view .entry-content .container > .header,
body.hsa-student-view .entry-content > .header,
body.hsa-student-view .entry-content .container > .progress-container,
body.hsa-student-view .entry-content .container > .progress-bar,
body.hsa-student-view .entry-content .container > .progress-text,
body.hsa-student-view .entry-content > .progress-container,
body.hsa-student-view .entry-content > .progress-bar,
body.hsa-student-view .entry-content > .progress-text,
body.hsa-student-view .entry-content .container > .progress-bar-container,
body.hsa-student-view .entry-content .container > p:has(#progressText),
body.hsa-student-view .entry-content > p:has(#progressText) {
    display: none !important;
}

/* La sección activa = tarjeta principal del mockup */
body.hsa-student-view .hsa-step-current {
    background: #ffffff !important;
    border: 1px solid rgba(0, 0, 0, 0.05) !important;
    border-radius: 0.75rem !important;
    box-shadow: 0px 4px 20px rgba(0, 0, 0, 0.04) !important;
    padding: 1.5rem !important;
    margin: 0 0 1rem !important;
    max-height: calc(100dvh - 250px);
    overflow-y: auto;
    overflow-x: auto;
    overscroll-behavior: contain;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
@media (min-width: 901px) {
    body.hsa-student-view .hsa-step-current { padding: 2rem 3rem !important; }
}
body.hsa-student-view .hsa-step-current h2 {
    font-family: 'Manrope', 'Inter', sans-serif !important;
    font-weight: 700 !important;
    color: #1a1c1d !important;
    margin-top: 0 !important;
}
body.hsa-student-view .hsa-step-current h3 {
    font-family: 'Manrope', 'Inter', sans-serif !important;
    color: #1a1c1d !important;
}

/* Animación de entrada entre tarjetas */
@keyframes hsaSvStepIn {
    from { opacity: 0; transform: translateY(12px); }
    to   { opacity: 1; transform: translateY(0); }
}
body.hsa-student-view .hsa-step-current.hsa-step-enter {
    animation: hsaSvStepIn 0.25s cubic-bezier(0.4, 0, 0.2, 1) both;
}

/* Cajas de teoría: tiras de título claras (mockup no usa bloques negros) */
body.hsa-student-view .hsa-step-current .grammar-title,
body.hsa-student-view .hsa-step-current .theory-title,
body.hsa-student-view .hsa-step-current .example-title,
body.hsa-student-view .hsa-step-current .box-title {
    background: #edeef0 !important;
    color: #1a1c1d !important;
    border-radius: 0.5rem !important;
    padding: 0.6rem 1rem !important;
    font-family: 'Manrope', sans-serif !important;
    font-weight: 700 !important;
    display: block;
    margin-bottom: 0.85rem;
}
body.hsa-student-view .hsa-step-current .grammar-title *,
body.hsa-student-view .hsa-step-current .theory-title *,
body.hsa-student-view .hsa-step-current .example-title *,
body.hsa-student-view .hsa-step-current .box-title * {
    color: #1a1c1d !important;
}
body.hsa-student-view .hsa-step-current .grammar-box,
body.hsa-student-view .hsa-step-current .theory-box,
body.hsa-student-view .hsa-step-current .example-box,
body.hsa-student-view .hsa-step-current .practice-box,
body.hsa-student-view .hsa-step-current .example-card {
    border-radius: 0.75rem !important;
}

/* Opciones de ejercicio (mockup): blancas, borde outline-variant,
   seleccionada NEGRA sólida con sombra y scale */
body.hsa-student-view .hsa-step-current .option {
    background: #ffffff !important;
    border: 1px solid #c4c7c7 !important;
    border-radius: 0.5rem !important;
    padding: 1rem !important;
    font-family: 'Inter', sans-serif !important;
    font-size: 16px;
    font-weight: 400 !important;
    color: #444748;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}
body.hsa-student-view .hsa-step-current .option:hover {
    border-color: #1a1c1d !important;
    color: #1a1c1d;
}
body.hsa-student-view .hsa-step-current .option.selected {
    background: #000000 !important;
    border-color: #000000 !important;
    color: #ffffff !important;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1) !important;
    transform: scale(1.02);
}
body.hsa-student-view .hsa-step-current .option.selected *,
body.hsa-student-view .hsa-step-current .option.correct *,
body.hsa-student-view .hsa-step-current .option.incorrect *,
body.hsa-student-view .hsa-step-current .option.wrong * {
    color: #ffffff !important;
}
body.hsa-student-view .hsa-step-current .option.correct {
    background: #10B981 !important;
    border-color: #10B981 !important;
    color: #ffffff !important;
    transform: none;
}
body.hsa-student-view .hsa-step-current .option.incorrect,
body.hsa-student-view .hsa-step-current .option.wrong {
    background: #EF4444 !important;
    border-color: #EF4444 !important;
    color: #ffffff !important;
    transform: none;
}

/* Navegador de preguntas: puntos centrados bajo la tarjeta (mockup) */
/* Sub-paginación: solo hay una pregunta visible, así que colapsamos el
   contenedor (rejilla/flex de 2+ columnas) a una sola columna para que la
   pregunta aproveche TODO el ancho disponible y no se quede a la izquierda. */
body.hsa-student-view .hsa-sv-subpaged {
    display: block !important;
}
/* Refuerzo: la pregunta visible ocupa todas las columnas de cualquier rejilla. */
body.hsa-student-view .hsa-q-current {
    grid-column: 1 / -1 !important;
    width: 100% !important;
}

#hsa-sv-qnav {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin: 1.5rem 0 0.25rem;
    font-family: 'Inter', sans-serif;
    /* El navegador se inserta como hermano de las preguntas; si el
       contenedor es una rejilla/flex de 2 columnas, sin esto caería en la
       celda de al lado (a la derecha de la pregunta). Forzamos ancho completo
       para que quede SIEMPRE debajo de la pregunta. */
    grid-column: 1 / -1;
    width: 100%;
    flex-basis: 100%;
}
.hsa-sv-qnav-arrow {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    border-radius: 50%;
    border: 1px solid #c4c7c7 !important;
    background: #ffffff !important;
    color: #444748 !important;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.hsa-sv-qnav-arrow:hover:not(:disabled) {
    border-color: #000000 !important;
    color: #000000 !important;
}
.hsa-sv-qnav-arrow:disabled { opacity: 0.3; cursor: default; }
.hsa-sv-qnav-label {
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: #747878;
    white-space: nowrap;
}
.hsa-sv-qnav-dots {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}
.hsa-sv-qnav-dot {
    width: 8px;
    height: 8px;
    flex-shrink: 0;
    border-radius: 50%;
    border: none !important;
    background: #c4c7c7 !important;
    padding: 0 !important;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.hsa-sv-qnav-dot:hover { transform: scale(1.3); }
.hsa-sv-qnav-dot.is-past { background: #747878 !important; }
.hsa-sv-qnav-dot.is-current {
    background: #000000 !important;
    transform: scale(1.25);
}

/* ═══════════════════════════════════════════════════════════════
   4. SIDEBAR (mockup: surface-container-low, actual en oro)
   ═══════════════════════════════════════════════════════════════ */
#hsa-sv-sidebar {
    position: sticky;
    top: 80px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background: #f3f3f5;
    border-right: 1px solid #c4c7c7;
    padding: 1.5rem 0.75rem 1rem;
    font-family: 'Inter', sans-serif;
    height: calc(100dvh - 160px);
    min-height: 420px;
    overflow-y: auto;
}
/* Toggle reubicado al tope del sidebar: ocupa el ancho, botones al 50% */
#hsa-sv-sidebar .hsa-sv-toggle {
    display: flex;
    width: 100%;
    margin: 0;
}
#hsa-sv-sidebar .hsa-sv-toggle-btn {
    flex: 1;
    justify-content: center;
    padding: 7px 8px;
}
.hsa-sv-side-head { padding: 0 0.75rem; }
/* Badge de nivel (🌱 A1) clonado del hero, alineado a la izquierda */
.hsa-sv-side-badge {
    display: inline-flex;
    margin-bottom: 8px;
}
.hsa-sv-side-title {
    font-family: 'Manrope', 'Inter', sans-serif;
    font-size: 20px;
    line-height: 1.3;
    font-weight: 600;
    color: #000000;
}
.hsa-sv-side-sub {
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.04em;
    font-weight: 500;
    color: #444748;
    margin-top: 4px;
}
.hsa-sv-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
}
.hsa-sv-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    color: #444748;
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0.02em;
    font-weight: 600;
    user-select: none;
}
.hsa-sv-item:hover { background: #e8e8ea; }
.hsa-sv-item-ico {
    flex-shrink: 0;
    font-size: 22px;
    line-height: 1;
    color: inherit;
}
.hsa-sv-item-label {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
/* Paso actual: oro secondary-container */
.hsa-sv-item.is-current {
    background: #fed65b !important;
    color: #745c00 !important;
}
.hsa-sv-item.is-current .hsa-sv-item-ico { color: #745c00 !important; }
/* Completados: check verde */
.hsa-sv-item.is-done { color: #747878; }
.hsa-sv-item.is-done .hsa-sv-item-ico { color: #10B981; }

/* Tarjeta de progreso (mockup: "Lesson Progress") */
.hsa-sv-side-progress {
    margin-top: auto;
    padding: 12px;
    background: #e2e2e4;
    border-radius: 0.75rem;
}
.hsa-sv-side-progress-lbl {
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.04em;
    font-weight: 700;
    color: #000000;
    margin: 0 0 8px;
}
.hsa-sv-progress {
    width: 100%;
    height: 4px;
    background: #c4c7c7;
    border-radius: 9999px;
    overflow: hidden;
}
.hsa-sv-progress-fill {
    height: 100%;
    width: 0%;
    background: #10B981;
    border-radius: 9999px;
    transition: width 0.4s ease;
}
.hsa-sv-side-progress-pct {
    font-size: 12px;
    line-height: 16px;
    letter-spacing: 0.04em;
    font-weight: 500;
    color: #444748;
    margin: 8px 0 0;
}

/* ═══════════════════════════════════════════════════════════════
   5. FOOTER STICKY — feedback inline + CONTINUAR (mockup)
   ═══════════════════════════════════════════════════════════════ */
#hsa-sv-footer {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9000;
    background: #ffffff;
    border-top: 1px solid #c4c7c7;
    font-family: 'Inter', sans-serif;
}
.hsa-sv-progress-mobile { display: none; border-radius: 0; }
.hsa-sv-footer-row {
    max-width: none;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 2.5rem calc(1rem + env(safe-area-inset-bottom, 0px));
}
#hsa-sv-prev {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #c4c7c7;
    background: #ffffff;
    color: #444748;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
#hsa-sv-prev:hover { border-color: #000000; color: #000000; }

/* Feedback inline (mockup: verified verde + mensaje) */
.hsa-sv-feedback {
    display: none;
    align-items: center;
    gap: 12px;
    min-width: 0;
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0.02em;
    font-weight: 600;
}
.hsa-sv-feedback.is-in { display: flex; }
.hsa-sv-feedback.is-ok { color: #10B981; }
.hsa-sv-feedback.is-err { color: #EF4444; }
.hsa-sv-feedback-ico {
    font-size: 22px;
    line-height: 1;
    font-variation-settings: 'FILL' 1;
    flex-shrink: 0;
}
.hsa-sv-feedback-txt {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#hsa-sv-counter {
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: #747878;
    white-space: nowrap;
}
.hsa-sv-footer-actions {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}
#hsa-sv-skip {
    border: none;
    background: transparent;
    color: #747878;
    font-family: inherit;
    font-weight: 600;
    font-size: 12px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    padding: 0.6rem 0.85rem;
    border-radius: 0.5rem;
    transition: all 0.2s ease;
}
#hsa-sv-skip:hover { color: #1a1c1d; background: #f3f3f5; }

/* CONTINUAR: negro, rounded-lg, uppercase tracking-wider (mockup) */
#hsa-sv-continue {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    border-radius: 0.5rem;
    padding: 12px 40px;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 14px;
    line-height: 20px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}
#hsa-sv-continue:active { transform: scale(0.95); }
#hsa-sv-continue.is-ready {
    background: #000000 !important;
    color: #ffffff !important;
}
#hsa-sv-continue.is-ready *,
#hsa-sv-continue.is-ready #hsa-sv-continue-label {
    color: #ffffff !important;
}
#hsa-sv-continue.is-ready:hover { opacity: 0.9; }
#hsa-sv-continue.is-soft {
    background: #ffffff !important;
    color: #747878 !important;
    border: 1px solid #c4c7c7;
    box-shadow: none;
}
#hsa-sv-continue.is-soft *,
#hsa-sv-continue.is-soft #hsa-sv-continue-label {
    color: #747878 !important;
}
#hsa-sv-continue.is-soft:hover { border-color: #747878; color: #444748 !important; }
#hsa-sv-continue.is-confirm {
    background: #fed65b !important;
    color: #1a1c1d !important;
}
#hsa-sv-continue.is-confirm *,
#hsa-sv-continue.is-confirm #hsa-sv-continue-label {
    color: #1a1c1d !important;
}

/* ═══════════════════════════════════════════════════════════════
   6. PASO FINAL — completación + likes solo en la última tarjeta
   ═══════════════════════════════════════════════════════════════ */
body.hsa-student-view .hsa-completion-block,
body.hsa-student-view .hsa-likes-block {
    display: none;
}
body.hsa-student-view.hsa-sv-last-step .hsa-completion-block,
body.hsa-student-view.hsa-sv-last-step .hsa-likes-block {
    display: block;
    animation: hsaSvStepIn 0.25s cubic-bezier(0.4, 0, 0.2, 1) both;
}
body.hsa-student-view.hsa-sv-last-step .hsa-step-current[style*="none"] {
    display: none !important;
}

/* ═══════════════════════════════════════════════════════════════
   7. RESPONSIVE + ACCESIBILIDAD
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 1024px) {
    body.hsa-student-view .hsa-grid { grid-template-columns: 232px minmax(0, 1fr); }
}
@media (max-width: 900px) {
    body.hsa-student-view .hsa-grid { grid-template-columns: 1fr; }
    /* En móvil el sidebar se colapsa a una barra superior con solo el toggle
       (la navegación de pasos va por el footer sticky) */
    #hsa-sv-sidebar {
        position: static;
        flex-direction: row;
        justify-content: flex-end;
        gap: 0;
        height: auto;
        min-height: 0;
        background: transparent;
        border-right: none;
        padding: 0.6rem 1rem;
        overflow: visible;
    }
    #hsa-sv-sidebar .hsa-sv-side-head,
    #hsa-sv-sidebar .hsa-sv-list,
    #hsa-sv-sidebar .hsa-sv-side-progress { display: none; }
    #hsa-sv-sidebar .hsa-sv-toggle { width: auto; }
    body.hsa-student-view .hsa-content-zone { padding: 1.25rem 1rem 2.5rem; }
    #hsa-sv-stephead { margin-bottom: 1rem; }
    .hsa-sv-headline { font-size: 24px !important; line-height: 32px !important; }
    body.hsa-student-view .hsa-step-current {
        padding: 1.15rem 1rem !important;
        max-height: none;
        max-width: 100%;
        overflow-y: visible;
        overflow-x: auto;
    }
    .hsa-sv-progress-mobile { display: block; height: 3px; background: #edeef0; }
    .hsa-sv-footer-row { padding: 0.7rem 1rem calc(0.7rem + env(safe-area-inset-bottom, 0px)); gap: 0.6rem; }
    #hsa-sv-continue { padding: 11px 22px; font-size: 13px; }
    #hsa-sv-skip { display: none !important; }
    .hsa-sv-feedback-txt { display: none; } /* en móvil basta el icono */
    .hsa-sv-qnav-dots { display: none; }
    #hsa-sv-qnav { justify-content: space-between; }
}
@media (prefers-reduced-motion: reduce) {
    body.hsa-student-view .hsa-step-current.hsa-step-enter,
    body.hsa-student-view.hsa-sv-last-step .hsa-completion-block,
    body.hsa-student-view.hsa-sv-last-step .hsa-likes-block {
        animation: none;
    }
    #hsa-sv-continue, .hsa-sv-item, .hsa-sv-progress-fill, .hsa-sv-qnav-dot {
        transition: none;
    }
}

/* ═══════════════════════════════════════════════════════════════
   8. BOTONES FLOTANTES (flashcards / reportar error) del template:
      en guiada el footer sticky (z-index 9000) los tapaba → subir
      por encima y apilarlos sobre el footer
   ═══════════════════════════════════════════════════════════════ */
body.hsa-student-view .report-error-floating-btn {
    bottom: 88px !important;
    z-index: 9001 !important;
}
body.hsa-student-view .add-dictionary-floating-btn {
    bottom: 148px !important;
    z-index: 9001 !important;
}
@media (max-width: 900px) {
    body.hsa-student-view .report-error-floating-btn {
        bottom