/* Hablando EnSeñas — panel de accesibilidad centralizado WCAG 2.2 AAA. Cambios limitados al widget y a estados opt-in del usuario. */

:root{
    --hesa-a11y-primary:#345c5c;
    --hesa-a11y-accent:#a3c34c;
    --hesa-a11y-bg:#fff;
    --hesa-a11y-text:#111827;
    --hesa-a11y-border:#d1d5db;
    --hesa-a11y-shadow:0 20px 50px rgba(0,0,0,.25)
}

#hesa-a11y-root,
#hesa-a11y-root *{
    box-sizing:border-box
}

#hesa-a11y-button{
    position:fixed;
    right:24px;
    bottom:24px;
    z-index:2147483000;
    width:64px;
    height:64px;
    border-radius:999px;
    border:3px solid #fff;
    background:linear-gradient(135deg,var(--hesa-a11y-primary),var(--hesa-a11y-accent));
    color:#fff;
    box-shadow:var(--hesa-a11y-shadow);
    display:flex;
    align-items:center;
    justify-content:center;
    cursor:pointer;
    transition:transform .2s ease,box-shadow .2s ease;
    font:700 26px/1 Arial,sans-serif
}

#hesa-a11y-button:hover,
#hesa-a11y-button:focus-visible{
    transform:translateY(-2px) scale(1.04);
    outline:4px solid #a3c34c71;
    outline-offset:3px
}

#hesa-a11y-button svg{
    width:34px;
    height:34px;
    fill:currentColor;
    pointer-events:none
}

#hesa-a11y-panel{
    position:fixed;
    top:0;
    right:0;
    bottom:0;
    z-index:2147482999;
    width:min(430px,calc(100vw - 20px));
    background:var(--hesa-a11y-bg);
    color:var(--hesa-a11y-text);
    box-shadow:var(--hesa-a11y-shadow);
    transform:translateX(105%);
    transition:transform .25s ease;
    display:flex;
    flex-direction:column;
    border-left:1px solid var(--hesa-a11y-border);
    font-family:Arial,Helvetica,sans-serif;
    text-align:left
}

#hesa-a11y-panel[aria-hidden="false"]{
    transform:translateX(0)
}

.hesa-a11y-header{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    padding:18px 18px 12px;
    border-bottom:1px solid var(--hesa-a11y-border);
    background:#f9fafb
}

.hesa-a11y-title{
    margin:0;
    font-size:1.25rem;
    font-weight:800;
    color:#111827;
    line-height:1.25
}

.hesa-a11y-close{
    border:2px solid transparent;
    background:#a3c34c;
    color:#fff;
    border-radius:10px;
    width:40px;
    height:40px;
    font-size:26px;
    line-height:1;
    cursor:pointer
}

.hesa-a11y-close:focus-visible,
.hesa-a11y-control:focus-visible,
.hesa-a11y-select:focus-visible,
.hesa-a11y-range:focus-visible{
    outline:4px solid #345c5c;
    outline-offset:2px
}

.hesa-a11y-body{
    padding:14px 18px 22px;
    overflow:auto
}

.hesa-a11y-section{
    margin:0 0 18px;
    padding:0 0 14px;
    border-bottom:1px solid #e5e7eb
}

.hesa-a11y-section h3{
    margin:0 0 10px;
    font-size:1rem;
    font-weight:800;
    color:#1f2937
}

.hesa-a11y-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:8px
}

.hesa-a11y-control{
    min-height:42px;
    border:2px solid #cbd5e1;
    border-radius:10px;
    background:#fff;
    color:#111827;
    cursor:pointer;
    padding:9px 10px;
    font:700 .9rem/1.2 Arial,sans-serif;
    text-align:center
}

.hesa-a11y-control:hover{
    border-color:var(--hesa-a11y-primary)
}

.hesa-a11y-control[aria-pressed="true"],
.hesa-a11y-control.active{
    background:var(--hesa-a11y-primary);
    border-color:var(--hesa-a11y-primary);
    color:#fff
}

.hesa-a11y-control.wide{
    grid-column:1/-1
}

.hesa-a11y-field{
    display:grid;
    gap:5px;
    margin:9px 0
}

.hesa-a11y-field label{
    font-weight:700;
    font-size:.9rem;
    color:#111827
}

.hesa-a11y-select,
.hesa-a11y-range{
    width:100%;
    min-height:38px;
    border:2px solid #cbd5e1;
    border-radius:8px;
    background:#fff;
    color:#111827;
    padding:6px
}

.hesa-a11y-status{
    border:2px solid #cbd5e1;
    background:#f9fafb;
    border-radius:10px;
    padding:10px;
    margin-top:8px;
    font-weight:700;
    color:#111827
}

.hesa-a11y-sr{
    position:absolute!important;
    width:1px!important;
    height:1px!important;
    padding:0!important;
    margin:-1px!important;
    overflow:hidden!important;
    clip:rect(0,0,0,0)!important;
    white-space:nowrap!important;
    border:0!important
}

.hesa-a11y-reading-highlight{
    outline:4px solid #345c5c!important;
    outline-offset:3px!important;
    background:rgba(255,213,79,.35)!important;
    transition:background .2s ease,outline .2s ease!important
}

html.hesa-a11y-font-90{font-size:90%!important}
html.hesa-a11y-font-100{font-size:100%!important}
html.hesa-a11y-font-110{font-size:110%!important}
html.hesa-a11y-font-120{font-size:120%!important}
html.hesa-a11y-font-130{font-size:130%!important}
html.hesa-a11y-font-140{font-size:140%!important}

html.hesa-a11y-high-contrast body{
    background:#000!important;
    color:#fff!important
}

html.hesa-a11y-high-contrast body *:not(#hesa-a11y-root):not(#hesa-a11y-root *){
    background-color:#000!important;
    color:#fff!important;
    border-color:#fff!important;
    text-shadow:none!important;
    box-shadow:none!important
}

html.hesa-a11y-high-contrast a:not(#hesa-a11y-root a){
    color:#ffff00!important;
    text-decoration:underline!important
}

html.hesa-a11y-grayscale{filter:grayscale(1)!important}

html.hesa-a11y-highlight-links a:not(#hesa-a11y-root a){
    outline:3px solid #ffd54f!important;
    outline-offset:2px!important;
    text-decoration:underline!important;
    background:rgba(255,213,79,.2)!important
}

html.hesa-a11y-large-cursor,
html.hesa-a11y-large-cursor *{
    cursor:url("data:image/svg+xml,%3Csvg xmlns=\'http://www.w3.org/2000/svg\' width=\'42\' height=\'42\' viewBox=\'0 0 42 42\'%3E%3Cpath fill=\'black\' stroke=\'white\' stroke-width=\'2\' d=\'M3 2l28 18-12 2 8 14-6 3-8-15-8 9z\'/%3E%3C/svg%3E") 3 2,auto!important
}

html.hesa-a11y-spacing body *:not(#hesa-a11y-root):not(#hesa-a11y-root *){
    letter-spacing:.08em!important;
    word-spacing:.16em!important
}

html.hesa-a11y-line-height body *:not(#hesa-a11y-root):not(#hesa-a11y-root *){
    line-height:1.85!important
}

/*html.hesa-a11y-reading-mode body{
    max-width:980px!important;
    margin-left:auto!important;
    margin-right:auto!important
}

html.hesa-a11y-reading-mode header,
html.hesa-a11y-reading-mode nav,
html.hesa-a11y-reading-mode footer,
html.hesa-a11y-reading-mode aside{
    opacity:.25!important
}

html.hesa-a11y-dyslexia body *:not(#hesa-a11y-root):not(#hesa-a11y-root *){
    font-family:OpenDyslexic,Atkinson Hyperlegible,Arial,sans-serif!important
}

html.hesa-a11y-reduce-motion *,
html.hesa-a11y-pause-animations *,
html.hesa-a11y-reduce-motion *::before,
html.hesa-a11y-pause-animations *::before,
html.hesa-a11y-reduce-motion *::after,
html.hesa-a11y-pause-animations *::after{
    animation-duration:.001ms!important;
    animation-iteration-count:1!important;
    transition-duration:.001ms!important;
    scroll-behavior:auto!important
}

html.hesa-a11y-pause-animations *,
html.hesa-a11y-pause-animations *::before,
html.hesa-a11y-pause-animations *::after{
    animation-play-state:paused!important
}

@media (prefers-reduced-motion:reduce){
    *,
    *::before,
    *::after{
        animation-duration:.001ms!important;
        animation-iteration-count:1!important;
        transition-duration:.001ms!important;
        scroll-behavior:auto!important
    }
}*/

@media (max-width:520px){
    #hesa-a11y-button{
        right:16px;
        bottom:16px;
        width:58px;
        height:58px
    }
    .hesa-a11y-grid{
        grid-template-columns:1fr
    }
    #hesa-a11y-panel{
        width:100vw
    }
}
