/* collina-pld · hoja de estilos (rediseño glassmorphism). Sin framework ni build step.
Orden: 1 tokens → 2 base → 3 estructura → 4 componentes → 5 pantallas → 6 utilidades →
7 adaptable. Color, tipografía y forma salen de los tokens de :root; una pantalla nueva no
debería necesitar valores sueltos. Componentes de plantilla: app/templates/_componentes/.
Las clases siguen el vocabulario de las macros (tarjeta, tabla, badge, aviso…): no las
renombres sin revisar los tests que leen el HTML. */
/* 1. Tokens ================================================================================ */
:root {
/* Marca */
--color-marino: #111D2E;
--color-marino-hover: #24324A;
--color-verde: #3F8A7C;
--color-verde-fuerte: #2F6C61;
--color-verde-activo: #35766A;
--color-verde-texto: var(--color-verde-fuerte); /* verde como color de texto: 6.1:1 sobre blanco (AA) */
--color-verde-10: rgba(63, 138, 124, 0.10);
--color-verde-12: rgba(63, 138, 124, 0.12);
--color-verde-06: rgba(63, 138, 124, 0.06);
/* Superficies */
--color-fondo: #F2F2F2;
--color-superficie: #FFFFFF;
--color-sutil: #F7F7F7;
--color-sutil-2: #FCFCFC;
/* Bordes */
--color-borde: #D5D7DA;
--color-borde-suave: #ECEDEE;
--color-borde-fuerte: #C3C7CC;
--color-borde-hover: #8A929C;
/* Texto */
--color-texto: #111D2E;
--color-texto-cuerpo: #2A3647;
--color-texto-suave: #5B6572;
--color-texto-tenue: #6B7480; /* 4.7:1 sobre blanco (AA); la referencia usaba #8A929C (3.2:1) */
/* Tonos semánticos: texto / fondo (badge, aviso, etiqueta, toast) */
--tono-exito: #2F6C61; --tono-exito-fondo: rgba(63, 138, 124, 0.12); /* riesgo bajo */
--tono-aviso: #8A5A0B; --tono-aviso-fondo: #FBF0D9; /* riesgo medio */
--tono-aviso-punto: #B7791F; --tono-aviso-oscuro: #5E3E08;
--tono-peligro: #A8321F; --tono-peligro-fondo: #FBE9E7; /* riesgo alto */
--tono-peligro-borde: #F0C4BC; --tono-peligro-oscuro: #7A2416;
--tono-info: #33435A; --tono-info-fondo: #E9EDF3;
--tono-neutro: #5B6572; --tono-neutro-fondo: #F2F2F2;
--tono-acento: #111D2E; --tono-acento-fondo: rgba(17, 29, 46, 0.08);
/* Gráfica del laboratorio (Chart.js la lee con getComputedStyle; no la reutilices) */
--grafica-vigente: #111D2E;
--grafica-simulada: #3F8A7C;
--grafica-rejilla: #F0F1F2;
--grafica-ejes: #8A929C;
/* Tipografía (self-hosted en /static/fuentes; ver 2. Base) */
--fuente: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
--fuente-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
--fuente-acceso: "Manrope", var(--fuente);
/* Forma */
--radio-sm: 6px;
--radio-xs: 8px;
--radio-boton: 10px;
--radio-md: 12px;
--radio-tarjeta: 14px;
--radio-acceso: 20px;
--radio-pildora: 999px;
/* Vidrio y sombras */
--vidrio: rgba(255, 255, 255, 0.55);
--vidrio-fuerte: rgba(255, 255, 255, 0.75);
--desenfoque: blur(14px);
--sombra-vidrio: inset 0 1px 0 rgba(255, 255, 255, 0.7);
--sombra-primario: inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 10px 22px -12px rgba(63, 138, 124, 0.9);
--sombra-flotante: 0 6px 18px -10px rgba(17, 29, 46, 0.25);
--sombra-acceso: 0 1px 0 rgba(17, 29, 46, 0.04), 0 24px 60px -24px rgba(17, 29, 46, 0.25);
--sombra-cajon: -24px 0 48px rgba(17, 29, 46, 0.12);
--sombra-toast: 0 12px 32px rgba(17, 29, 46, 0.24);
--anillo-foco: 0 0 0 3px rgba(63, 138, 124, 0.18);
/* Layout */
--ancho-lateral: 252px;
--ancho-contenido: 1180px;
--ancho-contenido-amplio: 1280px;
--ancho-contenido-extra: 1360px;
/* Compatibilidad: nombres de la hoja anterior que siguen usando plantillas no rediseñadas
(screening/*) y static/beneficiario.js. No los borres sin buscar sus usos. */
--color-primario: var(--color-verde);
--color-primario-fuerte: var(--color-verde-fuerte);
--color-foco: rgba(63, 138, 124, 0.18);
--radio: 8px;
--espacio-1: 0.25rem; --espacio-2: 0.5rem; --espacio-3: 0.75rem; --espacio-4: 1rem; --espacio-5: 1.5rem; --espacio-6: 2rem;
--texto-xs: 0.75rem; --texto-sm: 0.875rem; --texto-base: 1rem; --texto-lg: 1.25rem; --texto-xl: 1.625rem;
--sombra: 0 1px 2px rgb(17 29 46 / 6%), 0 1px 3px rgb(17 29 46 / 10%);
}
/* 2. Base ================================================================================== */
/* Fuentes: subconjunto latin de @fontsource 5.3.0 (static/fuentes/LEEME.txt). Solo se descargan
las que una página usa; Manrope solo la pide el acceso. */
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 400; font-display: swap; src: url("fuentes/ibm-plex-sans-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 500; font-display: swap; src: url("fuentes/ibm-plex-sans-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Sans"; font-style: normal; font-weight: 600; font-display: swap; src: url("fuentes/ibm-plex-sans-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 400; font-display: swap; src: url("fuentes/ibm-plex-mono-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "IBM Plex Mono"; font-style: normal; font-weight: 500; font-display: swap; src: url("fuentes/ibm-plex-mono-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 600; font-display: swap; src: url("fuentes/manrope-latin-600-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 700; font-display: swap; src: url("fuentes/manrope-latin-700-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Manrope"; font-style: normal; font-weight: 800; font-display: swap; src: url("fuentes/manrope-latin-800-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
margin: 0; min-height: 100vh; background: var(--color-fondo); color: var(--color-texto);
font-family: var(--fuente); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased;
}
h1, h2, h3, p, dl, dd, figure { margin: 0; }
a { color: var(--color-verde-texto); text-decoration: none; }
a:hover { color: var(--color-marino); text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
code { font-family: var(--fuente-mono); font-size: 12.5px; padding: 1px 6px; border-radius: 5px; background: var(--color-fondo); color: var(--color-texto); }
strong { font-weight: 600; }
:focus-visible { outline: 2px solid var(--color-verde); outline-offset: 2px; }
[hidden] { display: none !important; }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }
/* Íconos: sprite de _componentes/iconos.html, un solo color por currentColor. Van en la base
para que las clases de cada componente (nav__candado, campo__valido…) les ganen. */
.sprite-iconos { position: absolute; width: 0; height: 0; overflow: hidden; }
.icono { width: 18px; height: 18px; flex: none; display: inline-block; vertical-align: middle; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.icono--12 { width: 12px; height: 12px; } .icono--14 { width: 14px; height: 14px; }
.icono--15 { width: 15px; height: 15px; } .icono--16 { width: 16px; height: 16px; }
.icono--20 { width: 20px; height: 20px; } .icono--22 { width: 22px; height: 22px; }
.icono--tenue { opacity: 0.45; }
.icono--abajo { transform: rotate(90deg); }
/* Logo:
*/
.logo { display: block; max-width: 100%; height: auto; }
/* 3. Estructura (base.html) ================================================================ */
.app { display: grid; grid-template-columns: var(--ancho-lateral) minmax(0, 1fr); min-height: 100vh; }
.lateral {
position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 8px;
padding: 24px 16px; background: var(--color-superficie); border-right: 1px solid var(--color-borde); z-index: 30;
}
.marca { display: block; padding: 8px 12px 20px; color: inherit; }
.marca:hover { text-decoration: none; }
.marca .logo { width: 138px; }
.marca__ceja { display: block; margin-top: 10px; font-family: var(--fuente-mono); font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-verde-texto); }
/* Un solo