/* ==========================================================================
   WIDGET DE ACCESIBILIDAD VISUAL Y PANEL DE 12 HERRAMIENTAS
   ========================================================================== */
/* Botón Flotante Trigger */
.accessibility-trigger-btn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    width: 52px;
    height: 52px;
    background-color: #800020;
    /* Borgoña institucional */
    color: #ffffff;
    border: 2px solid #d4af37;
    /* Dorado */
    border-radius: 50%;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, background-color 0.3s ease;
}

.accessibility-trigger-btn:hover {
    transform: scale(1.1);
    background-color: #580016;
}

/* Panel Principal */
.accessibility-panel {
    position: fixed;
    bottom: 85px;
    right: 25px;
    width: 310px;
    background-color: #ffffff;
    border: 1px solid rgba(128, 0, 32, 0.2);
    z-index: 1050;
    display: none;
    animation: fadeInAcc 0.25s ease forwards;
}

.accessibility-panel.show {
    display: block;
}

/* Panel a la izquierda */
.accessibility-panel.panel-left {
    right: auto;
    left: 25px;
}

.accessibility-header {
    background-color: #800020;
}

.accessibility-body {
    max-height: 420px;
    overflow-y: auto;
}

/* Botones de herramientas */
.access-btn {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0 !important;
    color: #334155;
    font-size: 0.78rem;
    font-weight: 600;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 62px;
    transition: all 0.2s ease;
}

.access-btn:hover {
    background-color: #f1f5f9;
    border-color: #cbd5e1 !important;
}

.access-btn.active {
    background-color: #800020 !important;
    color: #ffffff !important;
    border-color: #800020 !important;
}

.access-btn.active .access-icon {
    color: #d4af37 !important;
}

.access-icon {
    font-size: 1.25rem;
    margin-bottom: 3px;
    color: #800020;
}

.integra2-bar {
    background-color: #800020;
    font-size: 0.7rem;
    border-radius: 4px;
    letter-spacing: 0.5px;
}

/* Línea de Lectura */
.reading-line {
    position: fixed;
    left: 0;
    width: 100%;
    height: 8px;
    background-color: rgba(212, 175, 55, 0.85);
    /* Línea dorada */
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
    pointer-events: none;
    z-index: 9999;
}

/* CLASES DE ACCESIBILIDAD APLICADAS AL BODY */

/* 1. Navegación Teclado (Focus visible resaltado) */
body.acc-keyboard-nav *:focus {
    outline: 4px solid #d4af37 !important;
    outline-offset: 2px !important;
}

/* 3. Contrastes */
body.acc-contrast {
    background-color: #000000 !important;
    color: #ffffff !important;
}

body.acc-contrast section,
body.acc-contrast div,
body.acc-contrast .card {
    background-color: #121212 !important;
    color: #ffffff !important;
}

/* 4. Hipervínculos */
body.acc-links a {
    outline: 2px solid #d4af37 !important;
    background-color: rgba(212, 175, 55, 0.2) !important;
    text-decoration: underline !important;
}

/* 6. Espacios Expandidos */
body.acc-spacing * {
    letter-spacing: 2px !important;
    word-spacing: 4px !important;
    line-height: 2 !important;
}

/* 7. Sin Animaciones */
body.acc-no-anim *,
body.acc-no-anim *::before,
body.acc-no-anim *::after {
    animation: none !important;
    transition: none !important;
}

/* 8. Texto Legible (Fuente limpia) */
body.acc-legible-font * {
    font-family: Arial, Helvetica, sans-serif !important;
}

/* 9. Puntero Gigante */
body.acc-large-pointer,
body.acc-large-pointer * {
    cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='32' height='32' viewBox='0 0 24 24' fill='%23800020' stroke='%23ffffff' stroke-width='2'%3E%3Cpath d='M3 3l7 18 3-7 7-3L3 3z'/%3E%3C/svg%3E"), auto !important;
}

@keyframes fadeInAcc {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}