/* ==========================================================================
   Base — reset moderno y estilos globales
   ========================================================================== */

/* ---------- Fuentes (self-hosted) ----------
   Archivos variables de Google Fonts, subconjunto latin (cubre el
   español: acentos, ñ, ¡, ¿, comillas y guiones). Playfair Display
   (títulos, Didone de alto contraste con trazos finos firmes) lleva el
   eje wght 400–900, igual que su itálica ("fácil y seguro" del H1);
   Outfit, wght 300–600. Playfair Display y Outfit se precargan en
   index.html, cotizar.html y 404.html; si se renombran, actualizar
   allá. */
@font-face {
  font-family: "Playfair Display";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("../assets/fonts/playfair-display-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Playfair Display";
  font-style: italic;
  font-weight: 400 900;
  font-display: swap;
  src: url("../assets/fonts/playfair-display-italic-latin.woff2") format("woff2");
}

@font-face {
  font-family: "Outfit";
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url("../assets/fonts/outfit-latin.woff2") format("woff2");
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
}

/* Pantallas grandes: a partir de 1440px (90rem) el rem crece poco a
   poco con el ancho (18px a 1920, tope de 20px desde 2400). Como todo
   el sitio está en rem, el diseño escala parejo y deja un margen sutil
   a los lados, sin llenar la pantalla. Abajo de 1440 vale 100%, que
   respeta el tamaño de letra del usuario. */
html {
  font-size: clamp(100%, 100% + (100vw - 90rem) / 240, 125%);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100svh;
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img,
picture,
svg,
video,
canvas {
  display: block;
  max-width: 100%;
}

input,
button,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

:where(ul, ol)[role="list"] {
  list-style: none;
  padding: 0;
}

p,
h1,
h2,
h3,
h4 {
  overflow-wrap: break-word;
}

/* ---------- Documento ---------- */
body {
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: var(--fs-base);
  font-weight: var(--fw-light);
  overflow-x: hidden;
}

/* ---------- Tipografía ----------
   Títulos en Playfair Display: mayúsculas, peso regular y letras
   juntas, como la referencia del cliente. */
h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: var(--fw-regular);
  line-height: var(--lh-tight);
  text-transform: uppercase;
  letter-spacing: var(--tracking-display);
}

strong,
b {
  font-weight: var(--fw-semibold);
}

/* ---------- Accesibilidad ---------- */
:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: var(--space-3);
  left: var(--space-3);
  z-index: var(--z-modal);
  padding: var(--space-2) var(--space-4);
  background: var(--color-accent);
  color: var(--klein-900);
  font-weight: var(--fw-semibold);
  border-radius: var(--radius-pill);
  transform: translateY(-200%);
}

.skip-link:focus-visible {
  transform: none;
}

/* ---------- Movimiento reducido ---------- */
@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;
  }
}
