/* ==========================================================================
   ASODIB
   Archivo: assets/css/estilo.css
   Estilos globales del Portal Web.
   Responsabilidades:
   - Reset global.
   - Tipografía base.
   - Elementos HTML generales.
   - Enlaces.
   - Títulos.
   - Imágenes.
   - Tablas.
   - Formularios básicos.
   - Utilidades globales simples.
   - Accesibilidad.
   NO contiene:
   - Header.
   - Menú.
   - Banner.
   - Footer.
   - Sidebar.
   - Tarjetas específicas.
   - Estilos de módulos.
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
}
/* ==========================================================================
   HTML
   ========================================================================== */
html {
    scroll-behavior: smooth;
}
/* ==========================================================================
   BODY
   ========================================================================== */
body {
    margin: 0;
    padding: 0;
    font-family: var(--fuente-principal);
    font-size: var(--texto-md);
    font-weight: 400;
    line-height: 1.6;
    color: var(--color-texto);
    background: var(--color-fondo);
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}
/* ==========================================================================
   ELEMENTOS DE TEXTO
   ========================================================================== */
p {
    margin-top: 0;
    margin-bottom: var(--espacio-4);
}
small {
    font-size: var(--texto-sm);
}
strong {
    font-weight: 600;
}
hr {
    margin: var(--espacio-5) 0;
    border: 0;
    border-top: 1px solid var(--color-borde);
    opacity: 1;
}
/* ==========================================================================
   TÍTULOS
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    margin-top: 0;
    margin-bottom: var(--espacio-3);
    font-family: var(--fuente-titulos);
    font-weight: 700;
    line-height: 1.25;
    color: var(--color-texto);
}
h1 {
    font-size: var(--titulo-h1);
}
h2 {
    font-size: var(--titulo-h2);
}
h3 {
    font-size: var(--titulo-h3);
}
h4 {
    font-size: var(--titulo-h4);
}
h5 {
    font-size: var(--titulo-h5);
}
h6 {
    font-size: var(--titulo-h6);
}
/* ==========================================================================
   ENLACES
   ========================================================================== */
a {
    color: var(--color-primario);
    text-decoration: none;
    transition:
        color var(--transicion-rapida),
        background-color var(--transicion-rapida);
}
a:hover {
    color: var(--color-primario-hover);
}
a:focus-visible {
    outline: 3px solid var(--color-acento);
    outline-offset: 2px;
}
/* ==========================================================================
   IMÁGENES
   ========================================================================== */
img {
    display: block;
    max-width: 100%;
    height: auto;
}
figure {
    margin: 0;
}
figcaption {
    color: var(--color-texto-secundario);
    font-size: var(--texto-sm);
}
/* ==========================================================================
   LISTAS
   ========================================================================== */
ul,
ol {
    margin-top: 0;
    margin-bottom: var(--espacio-4);
    padding-left: 1.5rem;
}
/* ==========================================================================
   TABLAS
   ========================================================================== */
table {
    width: 100%;
    border-collapse: collapse;
}
th,
td {
    vertical-align: middle;
}
/* ==========================================================================
   FORMULARIOS
   ========================================================================== */
button,
input,
select,
textarea {
    font: inherit;
}
button {
    cursor: pointer;
}
textarea {
    resize: vertical;
}
/* ==========================================================================
   SELECCIÓN DE TEXTO
   ========================================================================== */
::selection {
    background: var(--color-primario);
    color: var(--color-blanco);
}
/* ==========================================================================
   ACCESIBILIDAD
   ========================================================================== */
:focus-visible {
    outline: 3px solid var(--color-acento);
    outline-offset: 2px;
}
:disabled {
    cursor: not-allowed;
}
/* ==========================================================================
   UTILIDADES GLOBALES
   ========================================================================== */
.sombra-sm {
    box-shadow: var(--sombra-sm);
}
.sombra-md {
    box-shadow: var(--sombra-md);
}
.sombra-lg {
    box-shadow: var(--sombra-lg);
}
.radio-sm {
    border-radius: var(--radio-sm);
}
.radio-md {
    border-radius: var(--radio-md);
}
.radio-lg {
    border-radius: var(--radio-lg);
}
.fondo-blanco {
    background-color: var(--color-blanco);
}
.fondo-gris {
    background-color: var(--color-gris-50);
}
.texto-secundario {
    color: var(--color-texto-secundario);
}
.texto-centrado {
    text-align: center;
}
.texto-justificado {
    text-align: justify;
}
.oculto {
    display: none !important;
}
.borde {
    border: 1px solid var(--color-borde);
}
.centrado {
    display: flex;
    align-items: center;
    justify-content: center;
}
/* ==========================================================================
   ANIMACIÓN GLOBAL
   ========================================================================== */
.animacion-hover {
    transition:
        transform var(--transicion-normal),
        box-shadow var(--transicion-normal);
}
.animacion-hover:hover {
    transform: translateY(-3px);
}
/* ==========================================================================
   REDUCCIÓN DE MOVIMIENTO
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
/* ==========================================================================
   IMPRESIÓN
   ========================================================================== */
@media print {
    *,
    *::before,
    *::after {
        box-shadow: none !important;
        text-shadow: none !important;
    }
    body {
        color: #000;
        background: #fff;
    }
    a {
        color: #000;
        text-decoration: underline;
    }
}