/* ===== VARIABLES ===== */
:root {
  --azul-oscuro:    #1B3A6B;
  --azul-medio:     #2563EB;
  --azul-claro:     #EFF6FF;
  --dorado:         #B45309;
  --dorado-claro:   #FEF3C7;

  --color-judicial: #2563EB;
  --color-uedv:     #B45309;
  --color-lineas:   #0891B2;
  --color-pj:       #059669;

  --fondo:          #F8FAFC;
  --card:           #FFFFFF;
  --borde:          #E2E8F0;
  --texto:          #1E293B;
  --texto-suave:    #64748B;

  --radio:          12px;
  --sombra:         0 1px 3px rgba(0,0,0,0.08);
  --sombra-hover:   0 4px 16px rgba(27,58,107,0.12);
}

/* ===== RESET Y BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'IBM Plex Sans', sans-serif;
  background: var(--fondo);
  color: var(--texto);
  min-height: 100vh;
  font-size: 15px;
  line-height: 1.5;
}

/* ===== HEADER ===== */
header {
  background: var(--azul-oscuro);
  color: white;
  height: 64px;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.header-izquierda {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header-logo {
  font-size: 22px;
}

#header-titulo {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

/* ===== NAVEGACIÓN ===== */
nav {
  background: white;
  border-bottom: 1px solid var(--borde);
  padding: 0 24px;
  display: flex;
  gap: 4px;
}

.nav-item {
  background: none;
  border: none;
  padding: 14px 18px;
  font-size: 14px;
  font-weight: 500;
  color: var(--texto-suave);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: inherit;
}

.nav-item:hover { color: var(--azul-medio); }
.nav-item.activo {
  color: var(--azul-medio);
  border-bottom-color: var(--azul-medio);
}

.badge-nav {
  background: #EF4444;
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}

/* ===== LAYOUT PRINCIPAL ===== */
main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 32px 24px;
}

.pantalla { display: none; }

/* ===== CARDS ===== */
.card {
  background: var(--card);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 24px;
  box-shadow: var(--sombra);
}

/* ===== DASHBOARD ===== */
.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 28px;
}

.dashboard-titulo h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--azul-oscuro);
}

.select-mes {
  padding: 8px 14px;
  border: 1px solid var(--borde);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  background: white;
  color: var(--texto);
  cursor: pointer;
}

/* KPI Grid */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 28px;
}

.kpi-card {
  background: white;
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 24px;
  box-shadow: var(--sombra);
  transition: transform 0.2s, box-shadow 0.2s;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.kpi-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
}

.kpi-judicial::before { background: var(--color-judicial); }
.kpi-uedv::before     { background: var(--color-uedv); }
.kpi-lineas::before   { background: var(--color-lineas); }
.kpi-pj::before       { background: var(--color-pj); }

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--sombra-hover);
}

.kpi-icono { font-size: 28px; margin-bottom: 8px; }
.kpi-numero {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 3rem;
  font-weight: 700;
  color: var(--texto);
  line-height: 1;
  margin-bottom: 8px;
}
.kpi-label { font-size: 13px; color: var(--texto-suave); font-weight: 500; }

/* Gráficos */
.graficos-grid {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 20px;
  margin-bottom: 28px;
}

.card-titulo {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--azul-oscuro);
}

.grafico-contenedor {
  height: 260px;
  position: relative;
}

.accion-principal {
  text-align: center;
  margin-top: 8px;
}

/* ===== ESTADOS ===== */
.estado-loading,
.estado-vacio,
.estado-error {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 24px;
  gap: 12px;
  text-align: center;
}

.spinner {
  width: 36px;
  height: 36px;
  border: 3px solid var(--borde);
  border-top-color: var(--azul-medio);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin { to { transform: rotate(360deg); } }

.vacio-icono { font-size: 48px; }
.estado-error p { color: #EF4444; }

/* ===== PANTALLA HEADER ===== */
.pantalla-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 28px;
}

.pantalla-header h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--azul-oscuro);
  flex: 1;
}

/* ===== BOTONES ===== */
.btn-primario {
  background: var(--azul-medio);
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s, transform 0.1s;
}

.btn-primario:hover { background: #1d4ed8; }
.btn-primario:active { transform: scale(0.98); }
.btn-primario:disabled {
  background: var(--borde);
  color: var(--texto-suave);
  cursor: not-allowed;
}

.btn-grande { padding: 14px 32px; font-size: 15px; }

.btn-secundario {
  background: white;
  color: var(--azul-medio);
  border: 1px solid var(--azul-medio);
  padding: 10px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}

.btn-secundario:hover { background: var(--azul-claro); }

.btn-volver {
  background: none;
  border: 1px solid var(--borde);
  color: var(--texto-suave);
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}

.btn-volver:hover { background: var(--fondo); color: var(--texto); }

/* ===== PASOS DE CARGA ===== */
.carga-pasos { display: flex; flex-direction: column; gap: 20px; }

.paso-card {
  background: white;
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 28px;
  box-shadow: var(--sombra);
}

.paso-numero {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--azul-medio);
  margin-bottom: 8px;
}

.paso-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--azul-oscuro);
}

/* Campo grupo (label + input) */
.campo-grupo {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 480px;
}

.campo-grupo label {
  font-size: 13px;
  font-weight: 500;
  color: var(--texto-suave);
  margin-top: 8px;
}

.campo-grupo select,
.campo-grupo input[type="number"] {
  padding: 10px 14px;
  border: 1px solid var(--borde);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  color: var(--texto);
  background: white;
  transition: border-color 0.15s;
}

.campo-grupo select:focus,
.campo-grupo input:focus {
  outline: none;
  border-color: var(--azul-medio);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

/* ===== CARGA — PERÍODO ===== */
.periodo-fila {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

/* ===== CARGA — LOADING ===== */
.loading-bloque {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  padding: 32px 0;
}

.loading-texto {
  font-size: 14px;
  color: var(--texto-suave);
  margin: 0;
}

/* ===== CARGA — TABS ===== */
.tabs-header {
  display: flex;
  gap: 0;
  border-bottom: 2px solid var(--borde);
  margin-bottom: 24px;
}

.tab-btn {
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  padding: 12px 20px;
  font-size: 14px;
  font-weight: 500;
  color: var(--texto-suave);
  cursor: pointer;
  font-family: inherit;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.15s, border-color 0.15s;
}

.tab-btn:hover { color: var(--azul-medio); }

.tab-btn.activo {
  color: var(--azul-medio);
  border-bottom-color: var(--azul-medio);
  font-weight: 600;
}

.badge-tab {
  background: #EF4444;
  color: white;
  font-size: 11px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}

.tab-contenido { animation: fadeIn 0.15s ease; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ===== CARGA — KPI pendiente ===== */
.kpi-pendiente-carga::before { background: #F59E0B; }

/* ===== CARGA — CAMPOS MANUALES ===== */
.label-campo {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--texto);
  margin-bottom: 6px;
}

.input-grande {
  width: 100%;
  max-width: 320px;
  padding: 12px 16px;
  border: 1px solid var(--borde);
  border-radius: 8px;
  font-size: 18px;
  font-family: 'IBM Plex Mono', monospace;
  color: var(--texto);
  background: white;
  display: block;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.input-grande:focus {
  outline: none;
  border-color: var(--azul-medio);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

.nota-descartados {
  font-size: 12px;
  color: var(--texto-suave);
  margin: 12px 0 0;
}

/* ===== CARGA — MENSAJES ===== */
.msg-error {
  color: #B91C1C;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
}

.msg-exito {
  color: #065F46;
  background: #D1FAE5;
  border: 1px solid #6EE7B7;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  font-weight: 600;
}

/* ===== PENDIENTES — TABLA ===== */
.tabla-pendientes {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: var(--radio);
  overflow: hidden;
  box-shadow: var(--sombra);
  font-size: 13px;
}

.tabla-pendientes th {
  background: var(--fondo);
  padding: 10px 12px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--texto-suave);
  border-bottom: 1px solid var(--borde);
}

.tabla-pendientes td {
  padding: 11px 12px;
  border-bottom: 1px solid var(--borde);
  vertical-align: middle;
}

.tabla-pendientes tr:last-child td { border-bottom: none; }
.tabla-pendientes tr:hover td { background: var(--fondo); }

.td-iue   { font-family: 'IBM Plex Mono', monospace; font-size: 12px; }
.td-razon { white-space: nowrap; font-size: 12px; }

.td-acciones-pend {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
}

/* Botones de acción de pendientes */
.btn-pend {
  padding: 5px 10px;
  border: none;
  border-radius: 5px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.15s, transform 0.1s;
  white-space: nowrap;
}

.btn-pend:hover  { opacity: 0.82; }
.btn-pend:active { transform: scale(0.96); }

.btn-pend-judicial  { background: #DBEAFE; color: #1D4ED8; }
.btn-pend-uedv      { background: #FEF3C7; color: #92400E; }
.btn-pend-pj        { background: #D1FAE5; color: #065F46; }
.btn-pend-descartar { background: #F1F5F9; color: #64748B; }

/* Estimado referencia y nota de campo */
.estimado-referencia {
  font-size: 13px;
  color: #64748B;
  background: #FFFBEB;
  border: 1px solid #FDE68A;
  border-radius: 7px;
  padding: 8px 12px;
  margin-top: 4px;
}

.campo-nota {
  font-size: 12px;
  color: #94A3B8;
  margin-top: 2px;
}

/* Dropzone */
.dropzone {
  border: 2px dashed var(--borde);
  border-radius: var(--radio);
  padding: 40px 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

.dropzone:hover, .dropzone-activo {
  border-color: var(--azul-medio);
  background: var(--azul-claro);
}

.dropzone-icono { font-size: 40px; }

/* Barra de progreso */
.progreso-wrapper {
  margin-top: 16px;
}

.progreso-texto {
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 8px;
  color: var(--texto-suave);
}

.progreso-barra-contenedor {
  background: var(--borde);
  border-radius: 100px;
  height: 8px;
  overflow: hidden;
}

.progreso-barra {
  height: 100%;
  background: var(--azul-medio);
  border-radius: 100px;
  transition: width 0.3s ease;
}

/* Resultados clasificador */
.resultados-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 500px;
  margin-bottom: 16px;
}

.resultado-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--fondo);
}

.resultado-ok { background: #F0FDF4; }
.resultado-ref { background: #FFFBEB; }
.resultado-pendiente { background: #FFF7ED; }

.resultado-icono { font-size: 16px; }
.resultado-label { flex: 1; font-size: 14px; }
.resultado-valor {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 700;
  font-size: 18px;
}

/* Acciones guardar */
.paso-acciones {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

/* Error */
.error-mensaje {
  color: #EF4444;
  font-size: 13px;
  padding: 10px 14px;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 8px;
}

/* ===== PENDIENTES ===== */
.badge-pendientes {
  background: #EF4444;
  color: white;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 10px;
}

.tarjeta-pendiente {
  background: white;
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  padding: 20px;
  margin-bottom: 16px;
  box-shadow: var(--sombra);
  transition: opacity 0.3s, transform 0.3s;
}

.pendiente-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 6px;
  display: inline-block;
  margin-bottom: 10px;
}

.badge-advertencia { background: #FEF3C7; color: #92400E; }
.badge-info { background: #EFF6FF; color: #1D4ED8; }

.pendiente-remitente {
  font-size: 13px;
  color: var(--texto-suave);
  margin-bottom: 4px;
}

.pendiente-asunto {
  font-size: 15px;
  font-weight: 500;
  margin-bottom: 4px;
}

.pendiente-iue {
  font-size: 12px;
  color: var(--texto-suave);
  font-family: 'IBM Plex Mono', monospace;
}

.pendiente-info { margin-bottom: 14px; }

.pendiente-acciones { display: flex; gap: 8px; flex-wrap: wrap; }

.btn-categoria {
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  border: none;
  transition: opacity 0.15s, transform 0.1s;
}

.btn-categoria:hover { opacity: 0.85; }
.btn-categoria:active { transform: scale(0.97); }

.btn-judicial  { background: #DBEAFE; color: #1D4ED8; }
.btn-uedv      { background: #FEF3C7; color: #92400E; }
.btn-pj        { background: #D1FAE5; color: #065F46; }
.btn-descartar { background: #F1F5F9; color: #64748B; }

/* ===== HISTORIAL ===== */
.tabla-scroll { overflow-x: auto; }

.tabla-historial,
.tabla-detalle {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: var(--radio);
  overflow: hidden;
  box-shadow: var(--sombra);
}

.tabla-historial th,
.tabla-detalle th {
  background: var(--fondo);
  padding: 12px 16px;
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--texto-suave);
  border-bottom: 1px solid var(--borde);
  text-transform: uppercase;
}

.tabla-historial td,
.tabla-detalle td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--borde);
  font-size: 14px;
  vertical-align: middle;
}

.tabla-historial tr:last-child td,
.tabla-detalle tr:last-child td {
  border-bottom: none;
}

.tabla-historial tr:hover td,
.tabla-detalle tr:hover td {
  background: var(--fondo);
}

.td-mes { font-weight: 600; }
.td-numero { text-align: center; }
.td-acciones { display: flex; gap: 8px; justify-content: flex-end; }
.td-vacio { text-align: center; padding: 40px; color: var(--texto-suave); }

.btn-tabla {
  padding: 5px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  border: 1px solid var(--borde);
  background: white;
  transition: background 0.15s;
}

.btn-tabla:hover { background: var(--fondo); }
.btn-peligro { color: #EF4444; border-color: #FECACA; }
.btn-peligro:hover { background: #FEF2F2; }

/* ===== DETALLE ===== */
.filtros-categoria {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.filtro-label {
  font-size: 13px;
  color: var(--texto-suave);
  font-weight: 500;
}

.btn-filtro {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  border: 1px solid var(--borde);
  background: white;
  transition: background 0.15s, border-color 0.15s;
}

.btn-filtro:hover { background: var(--azul-claro); border-color: var(--azul-medio); }
.btn-filtro.activo {
  background: var(--azul-medio);
  color: white;
  border-color: var(--azul-medio);
}

.td-fecha { white-space: nowrap; color: var(--texto-suave); font-size: 13px; }
.td-remitente { font-size: 13px; color: var(--texto-suave); max-width: 220px; }
.td-asunto { max-width: 320px; }

.iue-label {
  font-size: 11px;
  color: var(--texto-suave);
  font-family: 'IBM Plex Mono', monospace;
  margin-top: 3px;
}

.manual-label {
  font-size: 11px;
  color: var(--dorado);
  margin-top: 2px;
}

/* ===== BADGES DE CATEGORÍA ===== */
.badge-judicial, .badge-uedv, .badge-lineas, .badge-pj, .badge-otro {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}

.badge-judicial  { background: #DBEAFE; color: #1D4ED8; }
.badge-uedv      { background: #FEF3C7; color: #92400E; }
.badge-lineas    { background: #CFFAFE; color: #155E75; }
.badge-pj        { background: #D1FAE5; color: #065F46; }
.badge-otro      { background: #F1F5F9; color: #475569; }

/* ===== UTILIDADES ===== */
.texto-suave { color: var(--texto-suave); }
.pequeño { font-size: 12px; }

/* ===== LOGIN ===== */
#pantalla-login {
  display: none;
  min-height: 100vh;
  background: var(--fondo);
  align-items: center;
  justify-content: center;
}

.login-card {
  background: var(--card);
  border: 1px solid var(--borde);
  border-radius: var(--radio);
  box-shadow: var(--sombra-hover);
  padding: 48px 40px;
  width: 100%;
  max-width: 380px;
  text-align: center;
}

.login-logo {
  font-size: 48px;
  margin-bottom: 12px;
}

.login-card h1 {
  font-size: 20px;
  font-weight: 700;
  color: var(--azul-oscuro);
  margin-bottom: 4px;
}

.login-subtitulo {
  font-size: 14px;
  color: var(--texto-suave);
  margin-bottom: 32px;
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
  text-align: left;
}

.login-form label {
  font-size: 13px;
  font-weight: 500;
  color: var(--texto-suave);
}

.login-form input[type="password"] {
  padding: 12px 14px;
  border: 1px solid var(--borde);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  width: 100%;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.login-form input[type="password"]:focus {
  outline: none;
  border-color: var(--azul-medio);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

.login-error {
  color: #B91C1C;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 13px;
  text-align: center;
}

/* ===== HEADER — botón logout y lado derecho ===== */
.header-derecha {
  display: flex;
  align-items: center;
}

.btn-logout {
  background: rgba(255,255,255,0.12);
  color: white;
  border: 1px solid rgba(255,255,255,0.25);
  padding: 7px 14px;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}

.btn-logout:hover {
  background: rgba(255,255,255,0.22);
}

/* Fix nav dentro del header — quitar estilos de nav standalone */
header nav {
  background: transparent;
  border-bottom: none;
  flex: 1;
  justify-content: center;
}

header .nav-item {
  color: rgba(255,255,255,0.75);
  border-bottom-color: transparent;
}

header .nav-item:hover { color: white; }
header .nav-item.activo {
  color: white;
  border-bottom-color: white;
}

/* ===== TOASTS ===== */
#toast-container {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  pointer-events: none;
}

.toast {
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  opacity: 0;
  transform: translateY(-12px);
  transition: opacity 0.25s, transform 0.25s;
  pointer-events: auto;
  max-width: 480px;
  text-align: center;
}

.toast-visible {
  opacity: 1;
  transform: translateY(0);
}

.toast-exito { background: #D1FAE5; color: #065F46; border: 1px solid #6EE7B7; }
.toast-error  { background: #FEF2F2; color: #B91C1C; border: 1px solid #FECACA; }
.toast-info   { background: #EFF6FF; color: #1D4ED8; border: 1px solid #BFDBFE; }

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .graficos-grid { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  main { padding: 16px; }
  header { padding: 0 16px; }
}
