/* =====================================
   VARIABLES DE ACCESIBILIDAD
===================================== */

:root{
    --bg:#121212;
    --surface:#1e1e1e;
    --surface2:#262626;
    --text:#ffffff;
    --text-soft:#d4d4d4;
    --primary:#ea5207;
    --primary-hover:#ff6d24;
}


*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

html{
    font-size:18px;
    scroll-behavior:smooth;
}

body{
    font-family: Tahoma, Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.8;
}

.skip-link{
    position:absolute;
    left:-9999px;
}

.skip-link:focus{
    left:20px;
    top:20px;
    background:#fff;
    color:#000;
    padding:10px;
    z-index:9999;
}

*:focus-visible{
    outline:4px solid #ffd54f;
    outline-offset:3px;
}

.topbar{
    display:flex;
    justify-content:center;
    gap:10px;
    padding:15px;
    background:#000;
}

.topbar button{
    padding:12px 18px;
    border:none;
    cursor:pointer;
    font-weight:bold;
    border-radius:6px;
}

.hero{
    text-align:center;
    padding:60px 20px;
}

.logo{
    max-width:180px;
    margin-bottom:20px;
}

.hero h1{
    font-size:3rem;
    color:var(--primary);
}

.hero p{
    color:var(--text-soft);
}

section{
    max-width:1200px;
    margin:auto;
    padding:50px 20px;
}

h2{
    margin-bottom:30px;
    color:var(--primary);
    border-left:5px solid var(--primary);
    padding-left:15px;
}

.grid-info,
.stats,
.cards{
    display:grid;
    gap:20px;
    grid-template-columns:repeat(auto-fit,minmax(250px,1fr));
}

.grid-info article,
.stat-card,
.card-servicio{
    background:var(--surface);
    padding:25px;
    border-radius:10px;
    border:1px solid #333;
}

.card-servicio{
    text-decoration:none;
    color:white;
    transition:.3s;
}

.card-servicio:hover{
    transform:translateY(-4px);
    border-color:var(--primary);
}

.stat-card{
    text-align:center;
}

.stat-card span{
    font-size:2rem;
}

.stat-card strong{
    display:block;
    color:var(--primary);
    font-size:2rem;
}

.expediente{
    background:var(--surface);
    border-radius:12px;
}

.expediente ul{
    padding-left:25px;
}

footer{
    text-align:center;
    padding:40px;
    background:#000;
    color:#ccc;
}

body.high-contrast{
    --bg:#000;
    --surface:#000;
    --surface2:#000;
    --text:#fff;
    --text-soft:#fff;
}

body.high-contrast{
    --bg:#000000;
    --surface:#000000;
    --surface2:#111111;
    --text:#ffffff;
    --text-soft:#ffffff;
    --primary:#ffff00;
}

body.high-contrast .card-servicio,
body.high-contrast .stat-card,
body.high-contrast article{
    border:2px solid #ffff00;
}

body.high-contrast a{
    color:#ffff00;
}

body.high-contrast button{
    border:2px solid #ffff00;
}

footer{
    text-align:center;
    padding:40px;
    background:#000;
    color:#ccc;
}

body.high-contrast{
    --bg:#000;
    --surface:#000;
    --surface2:#000;
    --text:#fff;
    --text-soft:#fff;
}

/* =====================================
   BARRA DE ACCESIBILIDAD
===================================== */

.topbar{
    position:sticky;
    top:0;
    z-index:9999;
    display:flex;
    justify-content:center;
    flex-wrap:wrap;
    gap:10px;
    padding:15px;
    background:#000;
    border-bottom:2px solid #ea5207;
}

.topbar button{
    background:#ea5207;
    color:#fff;
    border:none;
    border-radius:6px;
    padding:12px 16px;
    font-weight:700;
    cursor:pointer;
    min-height:44px;
    transition:0.3s;
}

.topbar button:hover{
    background:#ff6d24;
}

.topbar button:focus-visible{
    outline:4px solid #ffd54f;
    outline-offset:2px;
}

/* =====================================
   MODO ALTO CONTRASTE
===================================== */

body.high-contrast{
    --bg:#000000;
    --surface:#000000;
    --surface2:#111111;
    --text:#ffffff;
    --text-soft:#ffffff;
    --primary:#ffff00;
}

body.high-contrast .card-servicio,
body.high-contrast .stat-card,
body.high-contrast article{
    border:2px solid #ffff00;
}

body.high-contrast a{
    color:#ffff00;
}

body.high-contrast button{
    border:2px solid #ffff00;
}

.expediente-grid{
    display:grid;
    grid-template-columns:2fr 1fr;
    gap:30px;
    align-items:start;
}

.institucional{
    display:flex;
    flex-direction:column;
    gap:15px;
}

.institucional .card-servicio{
    display:block;
}

.institucional h4{
    margin-bottom:8px;
}

@media (max-width:768px){

.expediente-grid{
        grid-template-columns:1fr;
    }

}

.menu-principal{
    display:flex;
    justify-content:center;
    flex-wrap:wrap;
    gap:20px;
    padding:15px;
    background:#111;
    border-bottom:1px solid #333;
}

.menu-principal a{
    color:var(--text);
    text-decoration:none;
    font-weight:700;
    padding:10px 14px;
    border-radius:6px;
    transition:.3s;
}

.menu-principal a:hover{
    background:var(--surface);
    color:var(--primary);
}

.menu-principal a:focus-visible{
    outline:4px solid #ffd54f;
    outline-offset:2px;
}