/* ============================================================
   base.css — Raleway self-hosted (PERF-003), reset ligero,
   CONTRATO UX de pantalla: skip-link, focus-visible, reduced-motion
   (sello ?v= administrado por scripts/deploy/bump-version.py — BAS-4)
   ============================================================ */

/* ── Raleway subsets latin/latin-ext (13 KB c/u) ── */
@font-face {
    font-family: "Raleway";
    font-style: normal;
    font-weight: 400;
    font-display: swap;
    src: url("../fonts/raleway-latin-400.woff2?v=0.2.0") format("woff2");
}
@font-face {
    font-family: "Raleway";
    font-style: normal;
    font-weight: 600;
    font-display: swap;
    src: url("../fonts/raleway-latin-600.woff2?v=0.2.0") format("woff2");
}
@font-face {
    font-family: "Raleway";
    font-style: normal;
    font-weight: 700;
    font-display: swap;
    src: url("../fonts/raleway-latin-700.woff2?v=0.2.0") format("woff2");
}

/* ── Reset ligero ── */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
    font-family: var(--font-family);
    font-size: var(--fs-base);
    line-height: var(--lh-body);
    color: var(--color-text);
    background: var(--color-page);
    -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; height: auto; }
a { color: var(--color-link); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
h1, h2, h3 { line-height: var(--lh-heading); color: var(--color-heading); font-weight: var(--fw-bold); }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p { max-width: 65ch; }

/* ── CONTRATO UX: skip-link + foco visible (#364900 — dorado prohibido 1.4.11) ── */
.skip-link {
    position: absolute;
    left: var(--space-4);
    top: var(--space-2);
    transform: translateY(-300%);
    background: var(--color-surface);
    color: var(--color-heading);
    padding: var(--space-3) var(--space-6);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-soft);
    z-index: 100;
    text-decoration: none;
    font-weight: var(--fw-semibold);
}
.skip-link:focus { transform: translateY(0); }

:focus-visible {
    outline: 3px solid var(--color-focus-ring);
    outline-offset: 3px;
    border-radius: var(--radius-sm);
}

/* ── Contenedor ── */
.container {
    max-width: var(--container-max);
    margin-inline: auto;
    padding-inline: var(--container-pad);
}

/* ── Utilidad: texto sobre fondo oscuro (footer / CTA band) ── */
.on-dark, .on-dark a { color: #FFFFFF; }
.on-dark a:hover { color: var(--tint-green-soft); }

/* ── Visually hidden (labels accesibles) ── */
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
    border: 0;
}
