/* Tokens y base. Aspecto tomado del diseño «Agente de esquemas eléctricos · interfaz»:
   papel cálido, azul marino, banda naranja e IBM Plex servida en local (sin CDN). */

@font-face {
  font-family: 'IBM Plex Sans';
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-sans-latin-400-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Sans';
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-sans-latin-700-normal.woff2') format('woff2');
}
@font-face {
  font-family: 'IBM Plex Mono';
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url('../assets/fonts/ibm-plex-mono-latin-400-normal.woff2') format('woff2');
}

:root {
  --paper: #efeadf;          /* fondo de la aplicación */
  --panel: #fbf9f3;          /* paneles, lienzo y campos */
  --navy: #14213d;           /* texto, cabecera, trazo de dato recibido */
  --muted: #4a4f5c;          /* texto secundario */
  --line: #cdc5b2;           /* separadores */
  --line-strong: #6b6552;    /* borde de lienzo y controles */
  --on-navy-muted: #cdc5b2;

  --band: #e07a1f;           /* banda de cabecera */
  --action: #b4540a;         /* acción principal y trazo «propuesto» */
  --action-hover: #8f4208;

  --select: #1b6b38;         /* seleccionado, añadido, escrito */
  --select-bg: #e3f3e8;
  --warn: #7a4f00;           /* pendiente, simulado, modificado */
  --warn-bg: #fdf0d2;
  --error: #a32119;          /* solo errores bloqueantes */
  --error-bg: #fbe4e1;
  --neutral-bg: #e2ddd0;
  --navy-bg: #dfe3ec;        /* fuente verificada / control superado: nunca verde */

  --font-sans: 'IBM Plex Sans', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--navy);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 22px;
}

h1, h2, h3, p, dl, dd, figure, ul, ol { margin: 0; }
ul, ol { padding: 0; }
h1 { font-size: 24px; line-height: 30px; font-weight: 700; }
h2 { font-size: 18px; line-height: 24px; font-weight: 700; }

a { color: var(--navy); }
a:hover { color: var(--action); }

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

:focus-visible { outline: 3px solid var(--action); outline-offset: 2px; }
.app-header :focus-visible, .status-bar :focus-visible { outline-color: #ffffff; }

.data { font-family: var(--font-mono); font-size: 13px; line-height: 20px; }
.small { font-size: 13px; line-height: 18px; }
.muted { color: var(--muted); }
.label { font-size: 12px; line-height: 16px; font-weight: 700; color: var(--muted); }
.strike { text-decoration: line-through; }
.measure { max-width: 640px; }
[hidden] { display: none !important; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 10;
  background: var(--panel); padding: 12px 16px;
}
.skip-link:focus { left: 8px; top: 8px; }

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
