/* ==========================================================================
   INV-2026 · Reset y fundamentos
   ========================================================================== */

*, *::before, *::after { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  font-family: var(--ff);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, p, figure { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
a { color: inherit; text-decoration: none; }
/* Tamaño por defecto de íconos. Sin esto, un SVG sin regla propia adopta el
   tamaño intrínseco del viewport (300x150) y revienta el layout. Las reglas
   específicas de cada componente lo sobrescriben. */
svg { display: block; flex-shrink: 0; width: 16px; height: 16px; }

/* Toda cifra tabular se alinea: metros y piezas no se pueden confundir. */
.num { font-variant-numeric: tabular-nums; }

/* Foco visible siempre. Requisito de accesibilidad, no opcional. */
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--r-sm); }

/* Respeta la preferencia del sistema. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
}

.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;
}

::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: var(--r-full); border: 2px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: var(--text-faint); }
