/* =============================================================================
   Sistema Sterling — reset y tipografía base
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--fuente);
  font-size: var(--texto-base);
  line-height: 1.5;
  color: var(--texto);
  background: var(--fondo);
}

h1,
h2,
h3,
h4,
p,
figure,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

h1 {
  font-size: var(--texto-2xl);
  font-weight: 600;
  letter-spacing: -0.01em;
}

h2 {
  font-size: var(--texto-lg);
  font-weight: 600;
}

h3 {
  font-size: var(--texto-md);
  font-weight: 600;
}

a {
  color: var(--marca-acento);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

img,
svg {
  max-width: 100%;
  display: block;
}

/* Foco siempre visible: se navega mucho con teclado en formularios largos. */
:focus-visible {
  outline: 2px solid var(--marca-acento);
  outline-offset: 2px;
  border-radius: var(--radio-sm);
}

/* --- Utilidades tipográficas ---------------------------------------------- */

.numero {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}

.texto-suave {
  color: var(--texto-suave);
}

.texto-tenue {
  color: var(--texto-tenue);
}

.texto-sm {
  font-size: var(--texto-sm);
}

.texto-xs {
  font-size: var(--texto-xs);
}

.texto-derecha {
  text-align: right;
}

.texto-centro {
  text-align: center;
}

.negrita {
  font-weight: 600;
}

.mono {
  font-family: var(--fuente-numeros);
  font-size: 0.95em;
}

.nowrap {
  white-space: nowrap;
}

.positivo {
  color: var(--exito);
}

.negativo {
  color: var(--peligro);
}

/* Solo para lectores de pantalla. */
.solo-lectores {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@media print {
  .no-imprimir {
    display: none !important;
  }
  body {
    background: #fff;
  }
}
