/* ============================================================
   MARTIN SISTEMS — styles-nuevo.css
   Rediseño CORE Térmico · v1.0
   ------------------------------------------------------------
   Este archivo se carga ENCIMA de styles.css.
   No reemplaza nada: solo añade el nuevo tema visual.
   
   Temas:
   - light-ice  (Claro Glaciar)  → DEFAULT
   - dark-fire  (Oscuro Volcán)  → toggle
   
   Autor: Rediseño CORE
   Fecha: 2026-10-31
   ============================================================ */


/* ============================================================
   PARTE 1 — VARIABLES DE TEMA + RESET + BASE
   ============================================================ */

/* ---------- TEMA CLARO GLACIAR (DEFAULT) ---------- */
:root,
[data-theme="light-ice"] {
  /* --- Fondos --- */
  --bg-primary: #e0e5ec;
  --bg-secondary: #eef2f7;
  --bg-gradient: linear-gradient(135deg, #e0e5ec 0%, #eef2f7 100%);
  --bg-card: #e6eaf0;
  --bg-card-soft: #eef2f7;

  /* --- Neones Glaciar --- */
  --primary: #0093c4;
  --primary-dark: #006a8e;
  --primary-light: #4dd0ff;
  --accent: #7c3aed;
  --neon-1: #0093c4;
  --neon-2: #7c3aed;
  --neon-3: #2563eb;
  --neon-glow: rgba(0, 147, 196, 0.35);

  /* --- Semánticos --- */
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;

  /* --- Texto --- */
  --text-primary: #14203c;
  --text-secondary: #2a3a5e;
  --text-muted: #6a7a9a;
  --text-light: #9aa8c0;
  --text-on-dark: #e8ecf2;

  /* --- Tarjetas --- */
  --card-bg: #e6eaf0;
  --card-border: transparent;

  /* --- Neumorfismo claro (sombras duales) --- */
  --shadow-sm:
    -3px -3px 8px #ffffff,
    3px 3px 8px #b8bdc9;
  --shadow-md:
    -6px -6px 16px #ffffff,
    6px 6px 16px #b8bdc9;
  --shadow-lg:
    -10px -10px 24px #ffffff,
    10px 10px 24px #b8bdc9;

  /* --- Sombras duras (para modales / overlays) --- */
  --shadow-dark-sm: 0 4px 12px rgba(0,0,0,.08);
  --shadow-dark-md: 0 8px 24px rgba(0,0,0,.12);
  --shadow-dark-lg: 0 12px 40px rgba(0,0,0,.18);

  /* --- Radios --- */
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 28px;
  --radius-xl: 40px;
  --radius-pill: 999px;

  /* --- Auroras (blobs de fondo) --- */
  --halo-color: rgba(0, 147, 196, 0.12);
  --halo-color-2: rgba(124, 58, 237, 0.10);

  /* --- Acentos tipo CORE --- */
  --neon-blue: rgba(0, 147, 196, 0.15);
  --neon-amber: rgba(245, 158, 11, 0.20);
}


/* ---------- TEMA OSCURO VOLCÁN ---------- */
[data-theme="dark-fire"] {
  /* --- Fondos --- */
  --bg-primary: #0d0604;
  --bg-secondary: #1a0f0a;
  --bg-gradient: linear-gradient(135deg, #0d0604 0%, #1a0f0a 100%);
  --bg-card: #241410;
  --bg-card-soft: #2f1a14;

  /* --- Neones Volcán --- */
  --primary: #ff6b1a;
  --primary-dark: #b84700;
  --primary-light: #ffb347;
  --accent: #ff2d2d;
  --neon-1: #ff6b1a;
  --neon-2: #ff2d2d;
  --neon-3: #ffb347;
  --neon-glow: rgba(255, 107, 26, 0.45);

  /* --- Semánticos --- */
  --success: #22c55e;
  --warning: #f59e0b;
  --danger: #ef4444;

  /* --- Texto --- */
  --text-primary: #ffe0c8;
  --text-secondary: #d8b8a0;
  --text-muted: #8a7060;
  --text-light: #5a4a3a;
  --text-on-dark: #ffe0c8;

  /* --- Tarjetas --- */
  --card-bg: #241410;
  --card-border: transparent;

  /* --- Neumorfismo oscuro (sombras duales) --- */
  --shadow-sm:
    -3px -3px 8px rgba(255, 100, 30, 0.08),
    3px 3px 8px #0a0402;
  --shadow-md:
    -6px -6px 16px rgba(255, 100, 30, 0.06),
    6px 6px 16px #0a0402;
  --shadow-lg:
    -10px -10px 24px rgba(255, 100, 30, 0.06),
    10px 10px 24px #0a0402;

  /* --- Sombras duras --- */
  --shadow-dark-sm: 0 4px 12px rgba(0, 0, 0, 0.5);
  --shadow-dark-md: 0 8px 24px rgba(0, 0, 0, 0.6);
  --shadow-dark-lg: 0 12px 40px rgba(0, 0, 0, 0.7);

  /* --- Auroras --- */
  --halo-color: rgba(255, 107, 26, 0.18);
  --halo-color-2: rgba(255, 45, 45, 0.12);

  /* --- Acentos tipo CORE --- */
  --neon-blue: rgba(255, 107, 26, 0.15);
  --neon-amber: rgba(245, 158, 11, 0.20);
}


/* ============================================================
   RESET / BASE GLOBAL
   ============================================================ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  min-height: 100dvh;
}

body {
  overflow-y: auto;
  overflow-x: hidden;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  background: var(--bg-primary);
  background-image: var(--bg-gradient);
  color: var(--text-primary);
  transition: background 0.8s ease, color 0.8s ease;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  position: relative;
}

/* Scrollbar del tema */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 20px;
}
* {
  scrollbar-width: thin;
  scrollbar-color: var(--primary) transparent;
}

.hidden, .oculto {
  display: none !important;
}


/* ============================================================
   AURORA ANIMADA DE FONDO
   (2 blobs con blur, flotan suavemente, cambian con el tema)
   ============================================================ */

.aurora {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.aurora::before,
.aurora::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  transition: background 0.8s ease;
}

.aurora::before {
  width: 560px;
  height: 560px;
  background: radial-gradient(circle, var(--halo-color) 0%, transparent 70%);
  top: 6%;
  left: 10%;
  animation: auroraFloatA 16s ease-in-out infinite;
}

.aurora::after {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, var(--halo-color-2) 0%, transparent 70%);
  bottom: 4%;
  right: 10%;
  animation: auroraFloatB 20s ease-in-out infinite;
}

@keyframes auroraFloatA {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(40px, -30px) scale(1.12); }
}

@keyframes auroraFloatB {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-35px, 30px) scale(1.1); }
}

/* Añadir la aurora automáticamente al body si no existe el div */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(circle at 15% 20%, var(--halo-color) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, var(--halo-color-2) 0%, transparent 45%);
  animation: auroraShift 20s ease-in-out infinite;
  transition: opacity 0.8s ease;
}

@keyframes auroraShift {
  0%, 100% { transform: translate(0, 0) scale(1); opacity: 1; }
  50%      { transform: translate(20px, -15px) scale(1.05); opacity: 0.85; }
}


/* ============================================================
   TRANSICIÓN SUAVE ENTRE TEMAS
   (todos los componentes cambian de color en 0.8s)
   ============================================================ */

body,
.header-main,
.side-menu,
.card,
.module-card,
.admin-card,
.grafica-card,
.stat,
.item-historial,
.modal-card,
.modal-content,
.pin-card,
.btn,
.btn-mini,
.btn-volver,
input,
select,
textarea,
.icon-btn,
.menu-item,
.badge,
.toast,
th,
td {
  transition:
    background 0.8s ease,
    background-color 0.8s ease,
    color 0.8s ease,
    border-color 0.8s ease,
    box-shadow 0.8s ease;
}


/* ============================================================
   BOTÓN TOGGLE DE TEMA (FLOTANTE)
   ============================================================ */

#btn-tema {
  position: fixed;
  top: 16px;       /* Un poco más arriba */
  left: 24px;      /* ¡LO MOVIDO A LA IZQUIERDA! */
  z-index: 1000;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  background: var(--bg-card);
  color: var(--primary);
  font-size: 1.15rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  transition: all 0.3s ease;
}
/* Y en móvil lo ajustamos también */
@media (max-width: 480px) {
  #btn-tema {
    top: 12px;
    left: 12px;
  }
}

#btn-tema:hover {
  transform: translateY(-2px) scale(1.05);
  box-shadow: var(--shadow-lg);
}

#btn-tema:active {
  transform: scale(0.94);
  box-shadow: var(--shadow-sm);
}

#btn-tema i {
  transition: transform 0.4s ease, color 0.4s ease;
}

/* Icono del sol (en tema oscuro, para cambiar a claro) */
#btn-tema .fa-sun {
  color: #f59e0b;
  text-shadow: 0 0 10px rgba(245, 158, 11, 0.6);
}

/* Icono de la luna (en tema claro, para cambiar a oscuro) */
#btn-tema .fa-moon {
  color: var(--primary);
  text-shadow: 0 0 10px var(--neon-glow);
}

/* Rotación al hover */
#btn-tema:hover i {
  transform: rotate(20deg);
}

/* Responsive: en móvil, más chico y un poco más cerca del borde */
@media (max-width: 480px) {
  #btn-tema {
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
    font-size: 1rem;
  }
}


/* ============================================================
   FIN PARTE 1
   (Continúa en Parte 2: Splash + Login + Header)
   ============================================================ */
   /* ============================================================
   PARTE 2 — SPLASH + LOGIN + APP LAYOUT + HEADER
   ============================================================ */


/* ============================================================
   SPLASH (pantalla de carga inicial)
   ============================================================ */

#splash {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  background-image: var(--bg-gradient);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease;
}

#splash.oculto {
  opacity: 0;
  pointer-events: none;
}

.splash-logo {
  width: 140px;
  height: 140px;
  border-radius: 30px;
  background: var(--bg-card);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 60px;
  margin-bottom: 22px;
  box-shadow: var(--shadow-lg);
  animation: splashPulse 1.6s ease-in-out infinite;
  color: var(--primary);
}

@keyframes splashPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.05); }
}

.splash-texto {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 32px;
  font-weight: 400;
  letter-spacing: 3px;
  color: var(--text-primary);
  margin-bottom: 4px;
  transition: color 0.8s ease;
}

.splash-sub {
  font-size: 11px;
  letter-spacing: 3px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
  transition: color 0.8s ease;
}

.loader-line {
  width: 180px;
  height: 4px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  overflow: hidden;
  margin-top: 26px;
  position: relative;
}

[data-theme="dark-fire"] .loader-line {
  background: rgba(255, 255, 255, 0.08);
}

.loader-line::after {
  content: '';
  position: absolute;
  height: 100%;
  width: 40%;
  background: var(--primary);
  border-radius: 10px;
  animation: loaderSlide 1.5s infinite;
  box-shadow: 0 0 12px var(--neon-glow);
}

@keyframes loaderSlide {
  from { left: -40%; }
  to   { left: 140%; }
}


/* ============================================================
   PANTALLA DE LOGIN
   ============================================================ */

#pinPantalla {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  background-image: var(--bg-gradient);
  z-index: 9998;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 30px;
  overflow-y: auto;
}

.pin-card {
  max-width: 440px;
  width: 100%;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 40px 32px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
  z-index: 2;
  border: 1px solid var(--card-border);
}

.pin-card .pin-emoji {
  font-size: 56px;
  margin-bottom: 16px;
  display: block;
  filter: drop-shadow(0 0 20px var(--neon-glow));
  animation: pinEmojiPulse 3s ease-in-out infinite;
}

@keyframes pinEmojiPulse {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.06); }
}

.pin-card h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px;
  letter-spacing: 2px;
  color: var(--text-primary);
  margin-bottom: 8px;
  transition: color 0.8s ease;
}

.pin-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 24px;
  transition: color 0.8s ease;
}

.pin-card input {
  width: 100%;
  padding: 18px 22px;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  background: var(--bg-card-soft);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 16px;
  letter-spacing: 1px;
  outline: none;
  box-shadow: var(--shadow-sm);
  transition: all 0.25s ease;
  margin-bottom: 12px;
}

.pin-card input::placeholder {
  color: var(--text-muted);
  letter-spacing: 0.5px;
}

.pin-card input:focus {
  border-color: var(--primary);
  box-shadow: var(--shadow-sm), 0 0 0 4px var(--neon-blue);
}

.pin-card .pin-error {
  color: var(--danger);
  font-size: 13px;
  margin-top: 12px;
  min-height: 20px;
  font-weight: 600;
  transition: color 0.3s ease;
}

.pin-card button#btn-login {
  width: 100%;
  padding: 18px;
  border-radius: var(--radius-pill);
  border: none;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  cursor: pointer;
  margin-top: 16px;
  box-shadow:
    0 8px 20px var(--neon-glow),
    inset 0 2px 0 rgba(255, 255, 255, 0.15);
  transition: all 0.25s ease;
}

.pin-card button#btn-login:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 12px 28px var(--neon-glow),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

.pin-card button#btn-login:active:not(:disabled) {
  transform: scale(0.98);
}

.pin-card button#btn-login:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}


/* ============================================================
   NÚCLEO ORBITAL (gota de mercurio del login)
   ============================================================ */

.nucleo-orbital {
  position: relative;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: var(--bg-card);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  margin: 0 auto 30px;
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

.nucleo-orbital-inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: var(--bg-card-soft);
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 8px;
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

#neonCanvas {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  pointer-events: none;
  filter: drop-shadow(0 0 8px var(--neon-glow));
  transition: filter 0.8s ease;
}

.nucleo-centro {
  position: absolute;
  width: 90px;
  height: 90px;
  border-radius: 50%;
  background: var(--bg-card);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2;
  text-align: center;
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

.nucleo-centro .icono {
  font-size: 1.6rem;
  color: var(--primary);
  filter: drop-shadow(0 0 8px var(--neon-glow));
  transition: color 0.8s ease;
}

@media (max-width: 480px) {
  .nucleo-orbital {
    width: 180px;
    height: 180px;
    margin-bottom: 24px;
  }
  .nucleo-centro {
    width: 75px;
    height: 75px;
  }
  .nucleo-centro .icono {
    font-size: 1.35rem;
  }
}


/* ============================================================
   APP LAYOUT
   ============================================================ */

#app {
  display: none;
  flex-direction: column;
  height: 100dvh;
  position: relative;
  z-index: 1;
}

#app.active {
  display: flex;
}


/* ============================================================
   HEADER PRINCIPAL
   ============================================================ */

.header-main {
  position: relative;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 32px;
  background: var(--bg-card);
  border-radius: 0 0 var(--radius-xl) var(--radius-xl);
  box-shadow: var(--shadow-dark-md);
  min-height: 84px;
  flex-shrink: 0;
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

.logo-container {
  display: flex;
  align-items: center;
  gap: 16px;
  cursor: pointer;
}

.logo-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #fff;
  box-shadow:
    var(--shadow-sm),
    0 0 20px var(--neon-glow);
  transition: all 0.5s ease;
}

.logo-container:hover .logo-icon {
  transform: rotate(-8deg) scale(1.05);
}

.logo-text {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  font-weight: 400;
  letter-spacing: 2px;
  color: var(--text-primary);
  line-height: 1;
  transition: color 0.8s ease;
}

.logo-text span {
  color: var(--primary);
  transition: color 0.8s ease;
}

.logo-text .sub {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  letter-spacing: 1.5px;
  margin-top: 4px;
  text-transform: uppercase;
  transition: color 0.8s ease;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.icon-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--card-border);
  background: var(--bg-card-soft);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  transition: all 0.25s ease;
  box-shadow: var(--shadow-sm);
}

.icon-btn:hover {
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.icon-btn:active {
  transform: scale(0.95);
  box-shadow: var(--shadow-sm);
}

/* Ocultar el botón viejo #btn-tema si está dentro del header */
.header-actions #btn-tema {
  position: static;
  width: 52px;
  height: 52px;
}


/* ============================================================
   RESPONSIVE HEADER / LOGIN
   ============================================================ */

@media (max-width: 480px) {
  .header-main {
    padding: 12px 18px;
    min-height: 72px;
  }

  .logo-icon {
    width: 46px;
    height: 46px;
    font-size: 20px;
  }

  .logo-text {
    font-size: 20px;
  }

  .logo-text .sub {
    font-size: 10px;
  }

  .icon-btn {
    width: 46px;
    height: 46px;
    font-size: 18px;
  }

  .pin-card {
    padding: 32px 24px;
  }

  .pin-card h2 {
    font-size: 24px;
  }

  .pin-card input {
    padding: 16px 20px;
    font-size: 15px;
  }

  .pin-card button#btn-login {
    padding: 16px;
    font-size: 14px;
  }
}


/* ============================================================
   FIN PARTE 2
   (Continúa en Parte 3: Side menu + Main + Cards grid)
   ============================================================ */
   /* ============================================================
   PARTE 3 — SIDE MENU + MAIN + SECTION HEADER + CARDS GRID
   ============================================================ */


/* ============================================================
   OVERLAY DEL MENÚ (fondo oscuro al abrir menú)
   ============================================================ */

.menu-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 100;
  transition: opacity 0.3s ease;
}

.menu-overlay.active {
  display: block;
}


/* ============================================================
   SIDE MENU (menú lateral deslizante)
   ============================================================ */

.side-menu {
  position: fixed;
  top: 0;
  right: -420px;
  width: 380px;
  max-width: 88vw;
  height: 100%;
  background: var(--bg-card);
  z-index: 101;
  transition: right 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  padding: 32px 24px;
  overflow-y: auto;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.3);
  border-radius: var(--radius-xl) 0 0 var(--radius-xl);
}

.side-menu.open {
  right: 0;
}

.menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.menu-header h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  letter-spacing: 2px;
  color: var(--text-primary);
  transition: color 0.8s ease;
}

.menu-header h3 i {
  color: var(--primary);
  margin-right: 8px;
  transition: color 0.8s ease;
}

.close-menu {
  background: var(--bg-card-soft);
  border: 1px solid var(--card-border);
  color: var(--text-secondary);
  font-size: 20px;
  cursor: pointer;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.close-menu:hover {
  color: var(--primary);
  transform: rotate(90deg) scale(1.05);
  box-shadow: var(--shadow-md);
}

.close-menu:active {
  transform: rotate(90deg) scale(0.95);
  box-shadow: var(--shadow-sm);
}


/* ---------- Secciones del menú ---------- */

.menu-section {
  margin-bottom: 8px;
}

.menu-section .section-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--text-muted);
  padding: 8px 18px;
  margin-bottom: 6px;
  font-weight: 700;
  transition: color 0.8s ease;
}

.menu-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--text-light), transparent);
  margin: 16px 0;
  border-radius: 2px;
  opacity: 0.4;
  transition: background 0.8s ease;
}


/* ---------- Items del menú ---------- */

.menu-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: var(--radius-pill);
  color: var(--text-secondary);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.25s ease;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  margin-bottom: 6px;
  font-family: inherit;
  -webkit-tap-highlight-color: transparent;
}

.menu-item:hover {
  background: var(--bg-card-soft);
  transform: translateX(-4px);
  box-shadow: var(--shadow-sm);
  color: var(--primary);
}

.menu-item:active {
  transform: scale(0.98);
}

.menu-item i {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  font-size: 15px;
  background: var(--neon-blue);
  border-radius: 50%;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.menu-item:hover i {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 0 12px var(--neon-glow);
}

.menu-item.active {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow:
    0 6px 16px var(--neon-glow),
    var(--shadow-sm);
}

.menu-item.active i {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.menu-item.danger {
  color: var(--danger);
}

.menu-item.danger i {
  color: var(--danger);
  background: rgba(239, 68, 68, 0.15);
}

.menu-item.danger:hover {
  background: rgba(239, 68, 68, 0.08);
  color: var(--danger);
}

.menu-item.danger:hover i {
  background: var(--danger);
  color: #fff;
}


/* ============================================================
   MAIN CONTAINER
   ============================================================ */

.main-container {
  position: relative;
  z-index: 10;
  flex: 1;
  overflow-y: auto;
  padding: 32px 32px 100px 32px;
  height: calc(100dvh - 84px);
  max-width: 1600px;
  margin: 0 auto;
  width: 100%;
}


/* ============================================================
   VIEW SECTIONS (pantallas internas)
   ============================================================ */

.view-section {
  display: none;
}

.view-section.active {
  display: block;
  animation: viewFadeIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes viewFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}


/* ============================================================
   SECTION HEADER (título de cada pantalla)
   ============================================================ */

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.section-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 32px;
  font-weight: 400;
  letter-spacing: 2px;
  color: var(--text-primary);
  transition: color 0.8s ease;
}

.section-title small {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--text-muted);
  margin-left: 12px;
  text-transform: none;
  transition: color 0.8s ease;
}


/* ============================================================
   CARD GENÉRICA (contenedor neumórfico)
   ============================================================ */

.card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-dark-md);
  border: 1px solid var(--card-border);
  transition: background 0.8s ease, box-shadow 0.8s ease;
}


/* ============================================================
   CARDS GRID (grid de tarjetas de módulos)
   ============================================================ */

.cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 28px;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (min-width: 600px) {
  .cards-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .cards-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
  }
  .main-container {
    padding: 40px 48px 120px 48px;
  }
}

@media (max-width: 480px) {
  .main-container {
    padding: 22px 18px 100px 18px;
    height: calc(100dvh - 72px);
  }

  .cards-grid {
    gap: 12px;
  }

  .section-title {
    font-size: 26px;
  }

  .section-title small {
    font-size: 12px;
    margin-left: 8px;
  }

  .side-menu {
    padding: 24px 18px;
  }

  .menu-item {
    padding: 14px 16px;
    font-size: 14px;
  }

  .menu-item i {
    width: 28px;
    height: 28px;
    font-size: 13px;
  }

  .card {
    padding: 20px;
  }
}


/* ============================================================
   FIN PARTE 3
   (Continúa en Parte 4: Module cards + Foqutos + Formularios + Botones)
   ============================================================ */
   /* ============================================================
   PARTE 4 — MODULE CARDS + FOQUITOS + FORMULARIOS + BOTONES
   ============================================================ */


/* ============================================================
   MODULE CARD (tarjetas de módulos con LED)
   ============================================================ */

.module-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 36px 24px 44px 24px;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
  text-align: center;
  position: relative;
  box-shadow: var(--shadow-md);
  min-height: 180px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--card-border);
  font-family: inherit;
  color: inherit;
  overflow: visible;
}

.module-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.module-card:active {
  transform: translateY(-2px) scale(0.98);
  box-shadow: var(--shadow-sm);
}

.module-card i {
  width: 72px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-radius: 50%;
  margin-bottom: 16px;
  box-shadow:
    var(--shadow-sm),
    0 0 24px var(--neon-glow);
  transition: all 0.4s ease;
}

.module-card:hover i {
  transform: scale(1.1) rotate(-4deg);
  box-shadow:
    var(--shadow-md),
    0 0 32px var(--neon-glow);
}

.module-card h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  letter-spacing: 1.5px;
  font-weight: 400;
  color: var(--text-primary);
  margin-bottom: 4px;
  transition: color 0.8s ease;
}

.module-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
  font-weight: 500;
  transition: color 0.8s ease;
}

/* LED decorativo debajo del icono (opcional, se activa con data-led) */
.module-card[data-led="1"]::after,
.module-card[data-led="2"]::after,
.module-card[data-led="3"]::after {
  content: '';
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 35px;
  height: 8px;
  border-radius: 8px;
  animation: ledBreathe 3.2s ease-in-out infinite;
}

.module-card[data-led="1"]::after {
  background: var(--neon-1);
  box-shadow:
    0 0 12px var(--neon-1),
    0 0 24px var(--neon-1);
}

.module-card[data-led="2"]::after {
  background: var(--neon-2);
  box-shadow:
    0 0 12px var(--neon-2),
    0 0 24px var(--neon-2);
}

.module-card[data-led="3"]::after {
  background: var(--neon-3);
  box-shadow:
    0 0 12px var(--neon-3),
    0 0 24px var(--neon-3);
}

@keyframes ledBreathe {
  0%, 100% { opacity: 0.5; }
  50%      { opacity: 1; }
}


/* ============================================================
   FOQUITOS DE ESTADO (deudores / al corriente)
   ============================================================ */

.foquito-rojo {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow:
    0 0 0 2px var(--bg-card),
    0 0 12px rgba(239, 68, 68, 0.9);
  animation: foquitoPulse 1.6s infinite;
  z-index: 2;
}

@keyframes foquitoPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50%      { transform: scale(1.3); opacity: 0.7; }
}

.foquito-verde {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow:
    0 0 0 2px var(--bg-card),
    0 0 12px rgba(34, 197, 94, 0.9);
  z-index: 2;
}

.foquito-inline {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.8);
  margin-left: 0.5rem;
  vertical-align: middle;
  animation: foquitoPulse 1.6s infinite;
}

.foquito-inline.foquito-verde {
  background: #22c55e;
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.8);
  animation: none;
}


/* ============================================================
   FORMULARIOS
   ============================================================ */

.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  transition: color 0.8s ease;
}

.form-group input,
.form-group select,
.form-group textarea {
  padding: 14px 20px;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  background: var(--bg-card-soft);
  color: var(--text-primary);
  outline: none;
  transition: all 0.25s ease;
  width: 100%;
  font-size: 15px;
  font-family: inherit;
  font-weight: 500;
  box-shadow: var(--shadow-sm);
}

.form-group textarea {
  border-radius: var(--radius-md);
  resize: vertical;
  line-height: 1.6;
  padding: 16px 20px;
  min-height: 100px;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.7;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--primary);
  box-shadow: var(--shadow-sm), 0 0 0 4px var(--neon-blue);
}

.form-group input.mono,
.form-group textarea.mono {
  font-family: 'Roboto Mono', 'Courier New', monospace;
  font-size: 13.5px;
  letter-spacing: 0;
}

/* Select con flecha custom */
.form-group select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236a7a9a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 18px center;
  background-size: 18px;
  padding-right: 50px;
}

[data-theme="dark-fire"] .form-group select {
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%238a7060' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
}

/* Row (grid de 2 columnas para formularios) */
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 480px) {
  .row {
    grid-template-columns: 1fr;
  }
}

/* Checkbox item */
.checkbox-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  color: var(--text-secondary);
  transition: color 0.8s ease;
}

.checkbox-item input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
  cursor: pointer;
  flex-shrink: 0;
}


/* ============================================================
   BOTONES
   ============================================================ */

.btn {
  padding: 14px 24px;
  border: none;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  -webkit-tap-highlight-color: transparent;
}

.btn:active {
  transform: scale(0.97);
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
}

/* Botón primario */
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow:
    0 6px 16px var(--neon-glow),
    inset 0 2px 0 rgba(255, 255, 255, 0.15);
}

.btn-primary:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 10px 24px var(--neon-glow),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

/* Botón éxito */
.btn-success {
  background: linear-gradient(135deg, var(--success), #16a34a);
  color: #fff;
  box-shadow:
    0 6px 16px rgba(34, 197, 94, 0.35),
    inset 0 2px 0 rgba(255, 255, 255, 0.15);
}

.btn-success:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 10px 24px rgba(34, 197, 94, 0.45),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

/* Botón peligro */
.btn-danger {
  background: linear-gradient(135deg, var(--danger), #dc2626);
  color: #fff;
  box-shadow:
    0 6px 16px rgba(239, 68, 68, 0.35),
    inset 0 2px 0 rgba(255, 255, 255, 0.15);
}

.btn-danger:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 10px 24px rgba(239, 68, 68, 0.45),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

/* Botón warning */
.btn-warn {
  background: linear-gradient(135deg, var(--warning), #d97706);
  color: #fff;
  box-shadow:
    0 6px 16px rgba(245, 158, 11, 0.35),
    inset 0 2px 0 rgba(255, 255, 255, 0.15);
}

.btn-warn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    0 10px 24px rgba(245, 158, 11, 0.45),
    inset 0 2px 0 rgba(255, 255, 255, 0.2);
}

/* Botón secundario (neumórfico) */
.btn-secondary {
  background: var(--bg-card-soft);
  color: var(--text-secondary);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover:not(:disabled) {
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Tamaños */
.btn-sm {
  padding: 10px 16px;
  font-size: 12px;
}

.btn-block {
  width: 100%;
}

/* Botón volver (link) */
.btn-volver {
  background: transparent;
  border: none;
  color: var(--primary);
  cursor: pointer;
  font-family: inherit;
  font-size: 14px;
  padding: 8px 0;
  margin-bottom: 16px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-weight: 700;
  transition: all 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.btn-volver:hover {
  color: var(--primary-light);
  transform: translateX(-3px);
}

.btn-volver i {
  transition: transform 0.2s ease;
}

.btn-volver:hover i {
  transform: translateX(-2px);
}

/* Botón mini (barra de selección) */
.btn-mini {
  flex: 1;
  min-width: 140px;
  padding: 12px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--card-border);
  background: var(--bg-card-soft);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  -webkit-tap-highlight-color: transparent;
}

.btn-mini:hover {
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-mini:active {
  transform: scale(0.97);
  box-shadow: var(--shadow-sm);
}

.btn-mini-zip {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 6px 16px var(--neon-glow);
}

.btn-mini-zip:hover {
  color: #fff;
  box-shadow: 0 10px 24px var(--neon-glow);
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 480px) {
  .module-card {
    padding: 24px 16px 36px 16px;
    min-height: 150px;
  }

  .module-card i {
    width: 56px;
    height: 56px;
    font-size: 24px;
  }

  .module-card h3 {
    font-size: 16px;
  }

  .module-card p {
    font-size: 11.5px;
  }

  .module-card[data-led="1"]::after,
  .module-card[data-led="2"]::after,
  .module-card[data-led="3"]::after {
    width: 28px;
    height: 6px;
    bottom: 12px;
  }

  .btn {
    padding: 12px 18px;
    font-size: 13px;
  }

  .btn-mini {
    min-width: 100px;
    font-size: 11px;
  }

  .form-group input,
  .form-group select,
  .form-group textarea {
    padding: 12px 18px;
    font-size: 14px;
  }
}


/* ============================================================
   FIN PARTE 4
   (Continúa en Parte 5: Tablas + Badges + Stats + Modales + Toasts)
   ============================================================ */
   /* ============================================================
   PARTE 5 — TABLAS + BADGES + STATS + MODALES + TOASTS
   ============================================================ */


/* ============================================================
   TABLAS
   ============================================================ */

.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  padding: 4px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.04);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

th, td {
  padding: 16px 18px;
  text-align: left;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  white-space: nowrap;
  transition: background 0.8s ease, color 0.8s ease, border-color 0.8s ease;
}

[data-theme="dark-fire"] th,
[data-theme="dark-fire"] td {
  border-bottom-color: rgba(255, 255, 255, 0.06);
}

th {
  background: var(--bg-card-soft);
  color: var(--text-secondary);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  font-weight: 800;
}

td {
  color: var(--text-primary);
  font-weight: 500;
}

tr:hover {
  background: var(--neon-blue);
}

tr:last-child td {
  border-bottom: none;
}

/* Indicadores de estatus dentro de tablas */
.estatus-si {
  color: var(--danger);
  font-weight: 700;
}

.estatus-no {
  color: var(--success);
  font-weight: 600;
}


/* ============================================================
   BADGES
   ============================================================ */

.badge {
  display: inline-block;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.badge-green {
  background: rgba(34, 197, 94, 0.15);
  color: var(--success);
}

.badge-red {
  background: rgba(239, 68, 68, 0.15);
  color: var(--danger);
}

.badge-yellow {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
}

.badge-blue {
  background: var(--neon-blue);
  color: var(--primary);
}


/* ============================================================
   STATS (tarjetas de estadísticas)
   ============================================================ */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  text-align: center;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--card-border);
  transition: all 0.3s ease;
}

.stat:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.stat .label {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.2px;
  font-weight: 700;
  transition: color 0.8s ease;
}

.stat .value {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 36px;
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--primary);
  margin-top: 8px;
  transition: color 0.8s ease;
  text-shadow: 0 0 20px var(--neon-glow);
}


/* ============================================================
   MODALES
   ============================================================ */

.modal-overlay,
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9999;
  justify-content: center;
  align-items: center;
  padding: 20px;
}

.modal-overlay.active,
.modal-backdrop.activo {
  display: flex;
}

.modal-content,
.modal-card {
  max-width: 540px;
  width: 100%;
  max-height: 90dvh;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-dark-lg);
  overflow-y: auto;
  border: 1px solid var(--card-border);
  animation: modalIn 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.94) translateY(12px); }
  to   { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px;
  letter-spacing: 1.5px;
  font-weight: 400;
  margin-bottom: 20px;
  color: var(--text-primary);
  transition: color 0.8s ease;
}

.modal-actions,
.modal-card .acciones {
  display: flex;
  gap: 12px;
  margin-top: 22px;
  justify-content: flex-end;
}

.modal-actions .btn {
  flex: 1;
}


/* ============================================================
   TOASTS (notificaciones flotantes)
   ============================================================ */

#toastContainer {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99999;
  width: 90%;
  max-width: 440px;
  pointer-events: none;
}

.toast {
  background: var(--bg-card);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 10px;
  box-shadow: var(--shadow-dark-md);
  color: var(--text-primary);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 12px;
  animation: toastIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  pointer-events: all;
  border-left: 5px solid var(--primary);
  transition: all 0.3s ease;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(-20px) scale(0.95); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

.toast.success {
  border-left-color: var(--success);
}

.toast.error {
  border-left-color: var(--danger);
}

.toast.info {
  border-left-color: var(--accent);
}

.toast .toast-icon {
  font-size: 18px;
}

.toast.success .toast-icon {
  color: var(--success);
}

.toast.error .toast-icon {
  color: var(--danger);
}

.toast.info .toast-icon {
  color: var(--accent);
}

.toast .toast-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 18px;
  margin-left: auto;
  padding: 0 4px;
  font-weight: 700;
  transition: color 0.2s ease;
}

.toast .toast-close:hover {
  color: var(--text-primary);
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 480px) {
  th, td {
    padding: 12px 14px;
    font-size: 13px;
  }

  .stat {
    padding: 18px;
  }

  .stat .value {
    font-size: 30px;
  }

  .modal-content,
  .modal-card {
    padding: 24px 20px;
  }

  .modal-title {
    font-size: 22px;
  }

  .modal-actions,
  .modal-card .acciones {
    flex-direction: column;
  }

  #toastContainer {
    left: 12px;
    right: 12px;
    transform: none;
    width: auto;
  }
}


/* ============================================================
   FIN PARTE 5
   (Continúa en Parte 6: Empty states + Mensajes + Historial + Credenciales + Admin cards)
   ============================================================ */
   /* ============================================================
   PARTE 6 — EMPTY STATES + MENSAJES + HISTORIAL + CREDENCIALES + ADMIN CARDS
   ============================================================ */


/* ============================================================
   EMPTY STATE (cuando no hay datos)
   ============================================================ */

.empty-state,
.vacio {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
  transition: color 0.8s ease;
}

.empty-state i,
.vacio .emoji {
  font-size: 56px;
  margin-bottom: 14px;
  opacity: 0.4;
  color: var(--primary);
  display: block;
  filter: drop-shadow(0 0 16px var(--neon-glow));
  transition: color 0.8s ease;
}

.empty-state p,
.vacio p {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.6;
}

.contador {
  display: inline-block;
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  background: var(--neon-blue);
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
  margin-left: 8px;
  transition: all 0.3s ease;
}


/* ============================================================
   MENSAJES DE RESULTADO (msg-res)
   ============================================================ */

.msg-res {
  padding: 14px 18px;
  border-radius: var(--radius-md);
  font-size: 13.5px;
  font-weight: 600;
  margin: 14px 0;
  border-left: 4px solid transparent;
  white-space: pre-wrap;
  line-height: 1.5;
  animation: msgFadeIn 0.3s ease;
}

@keyframes msgFadeIn {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.msg-res.ok {
  background: rgba(34, 197, 94, 0.12);
  color: var(--success);
  border-left-color: var(--success);
}

.msg-res.error {
  background: rgba(239, 68, 68, 0.12);
  color: var(--danger);
  border-left-color: var(--danger);
}

.msg-res.info {
  background: var(--neon-blue);
  color: var(--primary);
  border-left-color: var(--primary);
}


/* ============================================================
   LISTA DE HISTORIAL (item-historial)
   ============================================================ */

.lista-historial {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 40px;
}

.item-historial {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  box-shadow: var(--shadow-md);
  position: relative;
  cursor: pointer;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border: 1px solid var(--card-border);
}

.item-historial:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.item-historial.seleccionado {
  border: 2px solid var(--accent);
  box-shadow:
    0 0 0 3px var(--neon-blue),
    var(--shadow-lg);
}

.item-info h4 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
  color: var(--text-primary);
  transition: color 0.8s ease;
}

.item-info p {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
  transition: color 0.8s ease;
}

.item-info .folio {
  font-family: 'Courier New', monospace;
  font-weight: 700;
  color: var(--primary);
  font-size: 12px;
  transition: color 0.8s ease;
}

.item-acciones {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  flex-wrap: wrap;
}


/* ============================================================
   CREDENCIALES (tarjeta verde con usuario/contraseña)
   ============================================================ */

.credenciales-card {
  background: rgba(34, 197, 94, 0.1);
  border-left: 4px solid var(--success);
  padding: 16px 18px;
  border-radius: var(--radius-md);
  margin-top: 15px;
  font-size: 13.5px;
  line-height: 1.7;
  color: var(--text-primary);
  animation: credencialesIn 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  transition: background 0.8s ease, color 0.8s ease;
}

@keyframes credencialesIn {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

.credenciales-card b {
  color: var(--primary);
  transition: color 0.8s ease;
}

.credenciales-card small {
  color: var(--text-muted);
  transition: color 0.8s ease;
}


/* ============================================================
   ADMIN CARDS (íconos 3D con glow)
   ============================================================ */

.admin-subgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.admin-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px 18px;
  text-align: center;
  cursor: pointer;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: var(--shadow-md);
  border: 2px solid transparent;
  position: relative;
  overflow: hidden;
}

.admin-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.admin-card:hover .icono-3d {
  transform: scale(1.08) rotate(-4deg);
  box-shadow:
    inset 0 -4px 8px rgba(0, 0, 0, 0.25),
    inset 0 3px 6px rgba(255, 255, 255, 0.25),
    0 8px 24px var(--neon-glow);
}

.admin-card .icono-3d {
  width: 64px;
  height: 64px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow:
    inset 0 -4px 8px rgba(0, 0, 0, 0.25),
    inset 0 3px 6px rgba(255, 255, 255, 0.25),
    0 6px 16px var(--neon-glow);
  transition: all 0.4s ease;
}

.admin-card h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 18px;
  letter-spacing: 1.5px;
  font-weight: 400;
  color: var(--text-primary);
  margin: 0 0 4px;
  transition: color 0.8s ease;
}

.admin-card p {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
  transition: color 0.8s ease;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 480px) {
  .empty-state {
    padding: 32px 16px;
  }

  .empty-state i,
  .vacio .emoji {
    font-size: 42px;
  }

  .empty-state p,
  .vacio p {
    font-size: 13px;
  }

  .item-historial {
    padding: 16px 18px;
  }

  .item-info h4 {
    font-size: 14px;
  }

  .admin-card {
    padding: 20px 14px;
  }

  .admin-card .icono-3d {
    width: 56px;
    height: 56px;
    font-size: 24px;
  }

  .admin-card h3 {
    font-size: 16px;
  }

  .credenciales-card {
    font-size: 12.5px;
    padding: 14px;
  }
}


/* ============================================================
   FIN PARTE 6
   (Continúa en Parte 7: Gráficas + Lista empleados + Detalle + Total + Overlay + Dev)
   ============================================================ */
   /* ============================================================
   PARTE 7 — GRÁFICAS + LISTA EMPLEADOS + DETALLE + TOTAL + OVERLAY + DEV
   ============================================================ */


/* ============================================================
   GRÁFICAS
   ============================================================ */

.graficas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
  margin-top: 20px;
}

.grafica-card {
  background: var(--bg-card-soft);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--card-border);
  transition: background 0.8s ease, box-shadow 0.8s ease;
}

.grafica-card h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 16px;
  letter-spacing: 1.5px;
  font-weight: 400;
  color: var(--text-secondary);
  text-transform: uppercase;
  margin-bottom: 16px;
  transition: color 0.8s ease;
}

.grafica-card .num-grande {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 42px;
  font-weight: 400;
  color: var(--primary);
  line-height: 1;
  letter-spacing: 1px;
  text-shadow: 0 0 20px var(--neon-glow);
  transition: color 0.8s ease;
}

.grafica-card .num-grande small {
  font-size: 16px;
  color: var(--text-muted);
  margin-left: 4px;
  text-shadow: none;
}


/* ============================================================
   TOP 5 ASESORES (barras de progreso)
   ============================================================ */

.top-asesores {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.top-item {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  align-items: center;
  gap: 12px;
  font-size: 13.5px;
}

.top-pos {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  background: var(--neon-blue);
  color: var(--primary);
  transition: all 0.3s ease;
}

.top-item:nth-child(1) .top-pos {
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: #78350f;
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.5);
}

.top-item:nth-child(2) .top-pos {
  background: linear-gradient(135deg, #cbd5e1, #94a3b8);
  color: #1e293b;
}

.top-item:nth-child(3) .top-pos {
  background: linear-gradient(135deg, #fdba74, #ea580c);
  color: #7c2d12;
}

.top-info {
  min-width: 0;
}

.top-info .top-nombre {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.8s ease;
}

.top-barra {
  height: 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: background 0.8s ease;
}

[data-theme="dark-fire"] .top-barra {
  background: rgba(255, 255, 255, 0.08);
}

.top-barra > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--primary));
  border-radius: 999px;
  transition: width 0.5s ease;
  box-shadow: 0 0 12px var(--neon-glow);
}

.top-item .valor {
  font-weight: 800;
  color: var(--primary);
  font-size: 14px;
  white-space: nowrap;
  transition: color 0.8s ease;
}


/* ============================================================
   LISTA DE EMPLEADOS (SUA / DISMAG / selección)
   ============================================================ */

.lista-empleados {
  max-height: 400px;
  overflow-y: auto;
  border-radius: var(--radius-md);
  background: var(--bg-card-soft);
  padding: 8px;
  margin-top: 15px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.04);
  transition: background 0.8s ease;
}

.emp-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 6px;
  border: 1px solid transparent;
}

.emp-item:hover {
  background: var(--neon-blue);
}

.emp-item.seleccionado {
  background: var(--neon-blue);
  border-color: var(--primary);
}

.emp-item input[type="checkbox"] {
  width: 22px;
  height: 22px;
  accent-color: var(--primary);
  cursor: pointer;
  flex-shrink: 0;
}

.emp-item .emp-info {
  flex: 1;
  min-width: 0;
}

.emp-item .emp-nombre {
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
  margin-bottom: 2px;
  transition: color 0.8s ease;
}

.emp-item .emp-meta {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.8s ease;
}


/* ============================================================
   DETALLE DE MOVIMIENTO (tabla del capturista)
   ============================================================ */

.detalle-tabla {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  margin-top: 12px;
}

.detalle-tabla th {
  text-align: left;
  width: 40%;
  color: var(--text-secondary);
  font-weight: 700;
  padding: 10px 12px;
  background: var(--bg-card-soft);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: background 0.8s ease, color 0.8s ease;
}

.detalle-tabla td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  color: var(--text-primary);
  font-weight: 500;
  word-break: break-word;
  white-space: normal;
  transition: color 0.8s ease, border-color 0.8s ease;
}

[data-theme="dark-fire"] .detalle-tabla th,
[data-theme="dark-fire"] .detalle-tabla td {
  border-bottom-color: rgba(255, 255, 255, 0.08);
}


/* ============================================================
   TOTAL MONETARIO (pendientes)
   ============================================================ */

.total-monetario {
  background: rgba(34, 197, 94, 0.12);
  border: 2px solid var(--success);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin-top: 20px;
  font-size: 15px;
  font-weight: 700;
  color: var(--success);
  text-align: right;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  box-shadow: 0 0 24px rgba(34, 197, 94, 0.2);
  transition: all 0.8s ease;
}

.total-monetario .monto {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 36px;
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--success);
  line-height: 1;
}


/* ============================================================
   BARRA DE SELECCIÓN (botones mini)
   ============================================================ */

.barra-seleccion {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}


/* ============================================================
   OVERLAY DE PROGRESO
   ============================================================ */

.overlay-progreso {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  z-index: 99999;
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  padding: 30px;
}

.overlay-progreso.active {
  display: flex;
}

.overlay-card {
  max-width: 420px;
  width: 100%;
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 36px 30px;
  text-align: center;
  box-shadow: var(--shadow-dark-lg);
  animation: overlayIn 0.35s ease;
}

@keyframes overlayIn {
  from { opacity: 0; transform: scale(0.94); }
  to   { opacity: 1; transform: scale(1); }
}

.overlay-card .emoji {
  font-size: 48px;
  margin-bottom: 16px;
  display: block;
  filter: drop-shadow(0 0 20px var(--neon-glow));
  animation: pinEmojiPulse 2s ease-in-out infinite;
}

.overlay-card h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  letter-spacing: 1.5px;
  color: var(--text-primary);
  margin-bottom: 8px;
  font-weight: 400;
  transition: color 0.8s ease;
}

.overlay-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
  min-height: 20px;
  transition: color 0.8s ease;
}

.overlay-barra {
  height: 10px;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 12px;
  transition: background 0.8s ease;
}

[data-theme="dark-fire"] .overlay-barra {
  background: rgba(255, 255, 255, 0.08);
}

.overlay-barra > div {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 6px;
  transition: width 0.3s ease;
  box-shadow: 0 0 12px var(--neon-glow);
}

.overlay-contador {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 700;
  transition: color 0.8s ease;
}

/* Spinner overlay (cuando carga algo) */
.spinner-overlay {
  width: 44px;
  height: 44px;
  border: 3px solid rgba(0, 0, 0, 0.1);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spinOverlay 0.8s linear infinite;
  margin: 0 auto 16px;
  box-shadow: 0 0 20px var(--neon-glow);
}

[data-theme="dark-fire"] .spinner-overlay {
  border-color: rgba(255, 255, 255, 0.1);
  border-top-color: var(--primary);
}

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


/* ============================================================
   PANEL DEL DESARROLLADOR
   ============================================================ */

.dev-header {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-lg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
}

.dev-header::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.15), transparent 60%);
  pointer-events: none;
}

.dev-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 28px;
  letter-spacing: 2px;
  margin: 0;
  color: #fff;
  position: relative;
  z-index: 1;
}

.dev-header p {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.75);
  margin: 4px 0 0;
  letter-spacing: 1px;
  position: relative;
  z-index: 1;
}

.dev-header .dev-badge {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  padding: 6px 14px;
  border-radius: 999px;
  text-transform: uppercase;
  backdrop-filter: blur(4px);
  position: relative;
  z-index: 1;
}

.dev-escenarios {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.dev-escenario-btn {
  padding: 10px 16px;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  background: var(--bg-card-soft);
  color: var(--text-secondary);
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dev-escenario-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
}

.dev-escenario-btn.activo {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-color: transparent;
  box-shadow: 0 6px 16px var(--neon-glow);
}

.dev-grupo {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--card-border);
}

.dev-grupo h3 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 20px;
  letter-spacing: 1.5px;
  color: var(--primary);
  margin-bottom: 14px;
  font-weight: 400;
  transition: color 0.8s ease;
}

.dev-modulo {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-radius: var(--radius-pill);
  background: var(--bg-card-soft);
  margin-bottom: 8px;
  transition: all 0.2s ease;
  cursor: pointer;
}

.dev-modulo:hover {
  background: var(--neon-blue);
  transform: translateX(4px);
}

.dev-modulo-info {
  display: flex;
  align-items: center;
  gap: 14px;
  flex: 1;
  min-width: 0;
}

.dev-modulo-info .icono {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--neon-blue);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.dev-modulo-info .texto h4 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 2px;
  transition: color 0.8s ease;
}

.dev-modulo-info .texto p {
  font-size: 11px;
  color: var(--text-muted);
  margin: 0;
  transition: color 0.8s ease;
}

.dev-switch {
  position: relative;
  width: 52px;
  height: 30px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.15);
  cursor: pointer;
  transition: all 0.25s ease;
  flex-shrink: 0;
  border: none;
  padding: 0;
}

[data-theme="dark-fire"] .dev-switch {
  background: rgba(255, 255, 255, 0.15);
}

.dev-switch::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: #fff;
  transition: all 0.25s ease;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

.dev-switch.activo {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  box-shadow: 0 0 12px var(--neon-glow);
}

.dev-switch.activo::after {
  left: 25px;
}

.dev-switch:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.dev-precio {
  background: var(--bg-card-soft);
  border: 2px solid var(--primary);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
  margin-bottom: 16px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  box-shadow: 0 0 32px var(--neon-glow);
  transition: all 0.8s ease;
}

.dev-precio .label {
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 700;
  transition: color 0.8s ease;
}

.dev-precio .monto {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 42px;
  color: var(--primary);
  line-height: 1;
  letter-spacing: 1px;
  text-shadow: 0 0 20px var(--neon-glow);
  transition: color 0.8s ease;
}

.dev-precio .monto small {
  font-size: 16px;
  color: var(--text-secondary);
  margin-left: 4px;
  text-shadow: none;
}

.dev-precio .plan-nombre {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  letter-spacing: 1.5px;
  color: var(--text-primary);
  margin-bottom: 4px;
  transition: color 0.8s ease;
}

.dev-acciones {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.dev-acciones .btn {
  flex: 1;
  min-width: 200px;
}


/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 480px) {
  .grafica-card {
    padding: 18px;
  }

  .grafica-card .num-grande {
    font-size: 32px;
  }

  .total-monetario {
    font-size: 13px;
    padding: 16px 18px;
  }

  .total-monetario .monto {
    font-size: 28px;
  }

  .emp-item {
    padding: 12px;
  }

  .emp-item .emp-nombre {
    font-size: 13px;
  }

  .emp-item .emp-meta {
    font-size: 11px;
  }

  .detalle-tabla {
    font-size: 12px;
  }

  .detalle-tabla th,
  .detalle-tabla td {
    padding: 8px 10px;
  }

  .dev-header {
    padding: 18px 20px;
  }

  .dev-header h2 {
    font-size: 22px;
  }

  .dev-precio {
    padding: 18px 20px;
  }

  .dev-precio .monto {
    font-size: 32px;
  }

  .dev-modulo {
    padding: 12px 14px;
  }

  .dev-acciones .btn {
    min-width: 100%;
  }

  .overlay-card {
    padding: 28px 22px;
  }

  .overlay-card h3 {
    font-size: 20px;
  }
}


/* ============================================================
   FIN PARTE 7
   (Continúa en Parte 8: Responsive global + Utilidades + Cierre)
   ============================================================ */
   /* ============================================================
   PARTE 8 — RESPONSIVE GLOBAL + UTILIDADES + FIXES + CIERRE
   ============================================================ */


/* ============================================================
   FIXES DE COMPATIBILIDAD CON styles.css VIEJO
   (neutraliza estilos que ya no queremos)
   ============================================================ */

/* El body viejo usa background-image con gradiente morado.
   Lo sobreescribimos con el nuevo. */
body {
  background: var(--bg-primary) !important;
  background-image: var(--bg-gradient) !important;
  color: var(--text-primary) !important;
}

/* El #splash viejo puede tener fondo distinto */
#splash {
  background: var(--bg-primary) !important;
  background-image: var(--bg-gradient) !important;
}

/* El #pinPantalla viejo puede tener fondo distinto */
#pinPantalla {
  background: var(--bg-primary) !important;
  background-image: var(--bg-gradient) !important;
}

/* El .header-main viejo tiene background: var(--bg-card) — se respeta,
   pero nos aseguramos que use la transición correcta */
.header-main {
  transition: background 0.8s ease, box-shadow 0.8s ease !important;
}

/* El .side-menu viejo puede tener border-radius distinto */
.side-menu {
  border-radius: var(--radius-xl) 0 0 var(--radius-xl) !important;
}

/* El .module-card viejo puede tener border distinto */
.module-card {
  border: 1px solid var(--card-border) !important;
  box-shadow: var(--shadow-md) !important;
}

/* El .card viejo puede tener padding distinto */
.card {
  background: var(--bg-card) !important;
  box-shadow: var(--shadow-dark-md) !important;
  border: 1px solid var(--card-border) !important;
}

/* Los modales viejos */
.modal-content,
.modal-card {
  background: var(--bg-card) !important;
  box-shadow: var(--shadow-dark-lg) !important;
  border: 1px solid var(--card-border) !important;
}

/* Inputs viejos */
.form-group input,
.form-group select,
.form-group textarea {
  background: var(--bg-card-soft) !important;
  color: var(--text-primary) !important;
  box-shadow: var(--shadow-sm) !important;
}

/* Botones viejos */
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important;
}

.btn-secondary {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
}

/* Tablas viejas */
th {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
}

td {
  color: var(--text-primary) !important;
}

/* Badges viejos */
.badge-blue {
  background: var(--neon-blue) !important;
  color: var(--primary) !important;
}

/* El icon-btn viejo */
.icon-btn {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  box-shadow: var(--shadow-sm) !important;
}

/* El menu-item viejo */
.menu-item {
  color: var(--text-secondary) !important;
}

.menu-item i {
  color: var(--primary) !important;
  background: var(--neon-blue) !important;
}

/* El module-card icon viejo */
.module-card i {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important;
  color: #fff !important;
}

/* El admin-card icon viejo */
.admin-card .icono-3d {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important;
  color: #fff !important;
}

/* El nav-header del index viejo (si existe) */
.navbar {
  background: var(--bg-card) !important;
  color: var(--text-primary) !important;
}

/* El pin-card viejo */
.pin-card {
  background: var(--bg-card) !important;
  box-shadow: var(--shadow-lg) !important;
}

/* El btn-volver viejo */
.btn-volver {
  color: var(--primary) !important;
}

/* El foquito-rojo viejo (mantener) */
.foquito-rojo {
  background: #ef4444 !important;
  box-shadow: 0 0 0 2px var(--bg-card), 0 0 12px rgba(239, 68, 68, 0.9) !important;
}

.foquito-verde {
  background: #22c55e !important;
  box-shadow: 0 0 0 2px var(--bg-card), 0 0 12px rgba(34, 197, 94, 0.9) !important;
}


/* ============================================================
   RESPONSIVE GLOBAL (móvil, tablet, desktop)
   ============================================================ */

/* Móvil pequeño (hasta 480px) */
@media (max-width: 480px) {
  .main-container {
    padding: 22px 16px 100px 16px;
  }

  .section-title {
    font-size: 26px;
  }

  .cards-grid {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
  }

  .graficas-grid {
    grid-template-columns: 1fr;
  }

  .admin-subgrid {
    grid-template-columns: 1fr 1fr;
  }

  .modal-actions,
  .modal-card .acciones {
    flex-direction: column;
  }

  .modal-actions .btn,
  .modal-card .acciones .btn {
    width: 100%;
  }

  #btn-tema {
    top: 16px;
    right: 16px;
    width: 42px;
    height: 42px;
    font-size: 1rem;
  }

  .header-main {
    padding: 12px 16px;
    min-height: 72px;
  }

  .logo-icon {
    width: 46px;
    height: 46px;
    font-size: 20px;
  }

  .logo-text {
    font-size: 18px;
  }

  .icon-btn {
    width: 46px;
    height: 46px;
    font-size: 18px;
  }
}

/* Tablet (481px - 768px) */
@media (min-width: 481px) and (max-width: 768px) {
  .cards-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .graficas-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Desktop (1024px+) */
@media (min-width: 1024px) {
  .main-container {
    padding: 40px 48px 120px 48px;
  }

  .graficas-grid {
    grid-template-columns: 1fr 1fr;
  }

  .modal-content,
  .modal-card {
    max-width: 600px;
  }
}

/* Pantallas grandes (1440px+) */
@media (min-width: 1440px) {
  .main-container {
    max-width: 1400px;
  }
}


/* ============================================================
   UTILIDADES
   ============================================================ */

.texto-centro { text-align: center; }
.texto-derecha { text-align: right; }
.texto-izquierda { text-align: left; }

.mt-1 { margin-top: .5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mb-1 { margin-bottom: .5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

.fila-flex {
  display: flex;
  align-items: center;
  gap: .6rem;
  flex-wrap: wrap;
}

.fila-flex-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .6rem;
  flex-wrap: wrap;
}

.w-100 { width: 100%; }
.h-100 { height: 100%; }


/* ============================================================
   ANIMACIÓN DEL ICONO DEL TOGGLE DE TEMA
   ============================================================ */

#btn-tema[data-current="light-ice"] .fa-moon {
  display: inline-block;
}

#btn-tema[data-current="light-ice"] .fa-sun {
  display: none;
}

#btn-tema[data-current="dark-fire"] .fa-moon {
  display: none;
}

#btn-tema[data-current="dark-fire"] .fa-sun {
  display: inline-block;
}

/* En caso de que el HTML use clases en vez de data-current */
#btn-tema .icon-sun { display: none; }
#btn-tema .icon-moon { display: inline-block; }

[data-theme="dark-fire"] #btn-tema .icon-sun { display: inline-block; }
[data-theme="dark-fire"] #btn-tema .icon-moon { display: none; }


/* ============================================================
   TRANSICIÓN GLOBAL ENTRE TEMAS
   (asegura que TODOS los elementos transicionen suavemente)
   ============================================================ */

*,
*::before,
*::after {
  transition-property: background-color, border-color, color, box-shadow;
  transition-duration: 0.8s;
  transition-timing-function: ease;
}

/* Excepción: elementos que deben mantener transiciones propias */
.btn,
.btn-mini,
.icon-btn,
.menu-item,
.module-card,
.admin-card,
.item-historial {
  transition: all 0.25s ease, background-color 0.8s ease, color 0.8s ease;
}

/* Excepción: animaciones que no deben transicionar */
.aurora::before,
.aurora::after,
.spinner-overlay,
.loader-line::after {
  transition: none;
}
/* Botón de instalación PWA */
#btn-instalar-pwa {
  width: 100%;
  padding: 16px;
  border-radius: var(--radius-pill);
  border: 2px solid var(--primary);
  background: transparent;
  color: var(--primary);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
  cursor: pointer;
  margin-top: 12px;
  transition: all 0.25s ease;
}

#btn-instalar-pwa:hover {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 8px 20px var(--neon-glow);
  transform: translateY(-2px);
}

#btn-instalar-pwa[hidden] {
  display: none !important;
}

/* Ocultar el banner de Netlify */
#netlify-badge, 
.netlify-badge, 
iframe[title="Netlify"], 
[id^="netlify"], 
[class^="netlify"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: -9999 !important;
}

/* ============================================================
   ============================================================
   GRAFITO VOLCÁNICO ROJO — v6.0
   Override del tema dark-fire
   Basado en "CERTIFICA PREMIUM — DISEÑO X ROJO"
   ============================================================
   Este bloque SOLO afecta [data-theme="dark-fire"].
   El tema light-ice queda intacto.
   ============================================================ */

/* ─────────── 1. NUEVA PALETA ─────────── */
[data-theme="dark-fire"] {
  /* Fondos grafito (no negro puro, da profundidad) */
  --bg-primary: #14161a;
  --bg-secondary: #1a1d24;
  --bg-gradient: linear-gradient(135deg, #14161a 0%, #1a1d24 100%);
  --bg-card: #1f232b;
  --bg-card-soft: #292e38;
  --card-bg: #1f232b;
  --card-border: rgba(255, 255, 255, 0.04);

  /* Rojo premium (antes era naranja) */
  --primary: #ff2d2d;
  --primary-dark: #cc0000;
  --primary-light: #ff6b6b;
  --accent: #ff2d2d;
  --neon-1: #ff2d2d;
  --neon-2: #ff6b6b;
  --neon-3: #cc0000;
  --neon-glow: rgba(255, 45, 45, 0.45);
  --neon-blue: rgba(255, 45, 45, 0.18);

  /* Textos */
  --text-primary: #ffffff;
  --text-secondary: #a1a1aa;
  --text-muted: #71717a;
  --text-light: #52525b;
  --text-on-dark: #ffffff;

  /* Sombras grafito */
  --shadow-dark-sm: 4px 4px 10px rgba(0, 0, 0, 0.5), -4px -4px 10px rgba(255, 255, 255, 0.03);
  --shadow-dark-md: 8px 8px 20px rgba(0, 0, 0, 0.6), -6px -6px 16px rgba(255, 255, 255, 0.04);
  --shadow-dark-lg: 12px 12px 30px rgba(0, 0, 0, 0.7), -8px -8px 24px rgba(255, 255, 255, 0.05);
  --shadow-sm: 4px 4px 10px rgba(0, 0, 0, 0.5), -4px -4px 10px rgba(255, 255, 255, 0.03);
  --shadow-md: 8px 8px 20px rgba(0, 0, 0, 0.6), -6px -6px 16px rgba(255, 255, 255, 0.04);
  --shadow-lg: 12px 12px 30px rgba(0, 0, 0, 0.7), -8px -8px 24px rgba(255, 255, 255, 0.05);

  /* Halos del fondo */
  --halo-color: rgba(255, 45, 45, 0.12);
  --halo-color-2: rgba(204, 0, 0, 0.08);
}

/* ─────────── 2. FONDOS EN TARJETAS ─────────── */
[data-theme="dark-fire"] body {
  background-color: var(--bg-primary) !important;
  background-image: var(--bg-gradient) !important;
  color: var(--text-primary) !important;
}

[data-theme="dark-fire"] .card,
[data-theme="dark-fire"] .module-card,
[data-theme="dark-fire"] .stat,
[data-theme="dark-fire"] .admin-card,
[data-theme="dark-fire"] .grafica-card,
[data-theme="dark-fire"] .header-main,
[data-theme="dark-fire"] .side-menu,
[data-theme="dark-fire"] .modal-card,
[data-theme="dark-fire"] .modal-content,
[data-theme="dark-fire"] .item-historial,
[data-theme="dark-fire"] .pin-card {
  background: var(--bg-card) !important;
  border: 1px solid rgba(255, 255, 255, 0.04) !important;
}

/* ─────────── 3. LED EN TODAS LAS TARJETAS ─────────── */
/* (No depende de data-led — aplica a cualquier .module-card) */
[data-theme="dark-fire"] .module-card::after {
  content: '';
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 6px;
  border-radius: 8px;
  background: var(--primary);
  box-shadow:
    0 0 8px rgba(255, 45, 45, 0.55),
    0 0 16px rgba(255, 45, 45, 0.25);
  opacity: 0.5;
  transition: all 0.35s cubic-bezier(.22, 1, .36, 1);
  z-index: 1;
  pointer-events: none;
}

[data-theme="dark-fire"] .module-card:hover::after {
  opacity: 1;
  width: 56px;
  height: 7px;
  box-shadow:
    0 0 12px rgba(255, 45, 45, 1),
    0 0 24px rgba(255, 45, 45, 0.7),
    0 0 44px rgba(255, 45, 45, 0.4);
}

/* ─────────── 4. ICONOS ROJOS + AURA AL HOVER ─────────── */
[data-theme="dark-fire"] .module-card i {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow: var(--shadow-dark-sm) !important;
  transition: all 0.35s cubic-bezier(.22, 1, .36, 1) !important;
}

[data-theme="dark-fire"] .module-card:hover i {
  transform: scale(1.12) rotate(-3deg) !important;
  color: var(--primary-light) !important;
  filter:
    drop-shadow(0 0 10px var(--primary))
    drop-shadow(0 0 4px var(--primary)) !important;
  box-shadow:
    var(--shadow-dark-md),
    0 0 28px rgba(255, 45, 45, 0.55) !important;
}

/* ─────────── 5. TEXTO EN TARJETAS ─────────── */
[data-theme="dark-fire"] .module-card h3 {
  color: var(--text-primary) !important;
}

[data-theme="dark-fire"] .module-card p {
  color: var(--text-muted) !important;
}

[data-theme="dark-fire"] .section-title {
  color: var(--text-primary) !important;
}

/* ─────────── 6. MENÚ LATERAL SÓLIDO + HUNDIDO ─────────── */
[data-theme="dark-fire"] .side-menu {
  background: var(--bg-card) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  border-left: 1px solid rgba(255, 45, 45, 0.15) !important;
}

[data-theme="dark-fire"] .menu-item {
  color: var(--text-secondary);
}

[data-theme="dark-fire"] .menu-item i {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow: var(--shadow-dark-sm) !important;
}

[data-theme="dark-fire"] .menu-item:hover {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
}

[data-theme="dark-fire"] .menu-item.active {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow:
    inset 4px 4px 8px rgba(0, 0, 0, 0.6),
    inset -4px -4px 8px rgba(255, 255, 255, 0.04) !important;
}

[data-theme="dark-fire"] .menu-item.active i {
  background: var(--bg-card) !important;
  color: var(--primary) !important;
  box-shadow: var(--shadow-dark-sm) !important;
}

[data-theme="dark-fire"] .close-menu {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary);
}

[data-theme="dark-fire"] .menu-divider {
  background: linear-gradient(90deg, transparent, rgba(255, 45, 45, 0.3), transparent) !important;
}

[data-theme="dark-fire"] .section-label {
  color: var(--text-muted);
}

/* ─────────── 7. HEADER CON HILO ROJO ─────────── */
[data-theme="dark-fire"] .header-main {
  background: #0d0f12 !important;
  position: relative;
}

[data-theme="dark-fire"] .header-main::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 10%;
  right: 10%;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  box-shadow:
    0 0 10px var(--primary),
    0 0 22px var(--primary);
  opacity: 0.85;
  pointer-events: none;
}

[data-theme="dark-fire"] .logo-icon {
  background: #f0f0f0 !important;
  color: var(--primary) !important;
  box-shadow:
    4px 4px 10px #050505,
    -4px -4px 10px #1c1c1c !important;
}

[data-theme="dark-fire"] .logo-text {
  color: var(--text-primary) !important;
}

[data-theme="dark-fire"] .logo-text span {
  color: var(--primary) !important;
}

[data-theme="dark-fire"] .logo-text .sub {
  color: var(--text-muted) !important;
}

[data-theme="dark-fire"] .icon-btn {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  box-shadow: var(--shadow-dark-sm) !important;
}

[data-theme="dark-fire"] .icon-btn:hover {
  color: var(--primary) !important;
}

/* ─────────── 8. INPUTS / FORMULARIOS ─────────── */
[data-theme="dark-fire"] .form-group input,
[data-theme="dark-fire"] .form-group select,
[data-theme="dark-fire"] .form-group textarea {
  background: var(--bg-card-soft) !important;
  color: var(--text-primary) !important;
  box-shadow:
    inset 4px 4px 8px rgba(0, 0, 0, 0.5),
    inset -4px -4px 8px rgba(255, 255, 255, 0.03) !important;
}

[data-theme="dark-fire"] .form-group input:focus,
[data-theme="dark-fire"] .form-group select:focus,
[data-theme="dark-fire"] .form-group textarea:focus {
  border-color: var(--primary) !important;
  box-shadow:
    inset 4px 4px 8px rgba(0, 0, 0, 0.5),
    inset -4px -4px 8px rgba(255, 255, 255, 0.03),
    0 0 0 4px rgba(255, 45, 45, 0.15) !important;
}

[data-theme="dark-fire"] .form-group label {
  color: var(--text-secondary) !important;
}

/* ─────────── 9. BOTONES ─────────── */
[data-theme="dark-fire"] .btn-primary {
  background: var(--primary) !important;
  box-shadow: 0 6px 16px rgba(255, 45, 45, 0.35) !important;
}

[data-theme="dark-fire"] .btn-primary:hover:not(:disabled) {
  background: var(--primary-light) !important;
  box-shadow: 0 10px 24px rgba(255, 45, 45, 0.5) !important;
}

[data-theme="dark-fire"] .btn-secondary {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  border: 1px solid rgba(255, 255, 255, 0.05) !important;
}

[data-theme="dark-fire"] .btn-secondary:hover:not(:disabled) {
  color: var(--primary) !important;
}

[data-theme="dark-fire"] .btn-volver {
  color: var(--primary) !important;
}

/* ─────────── 10. TABLAS ─────────── */
[data-theme="dark-fire"] .table-wrap {
  background: var(--bg-card) !important;
}

[data-theme="dark-fire"] th {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  border-bottom-color: rgba(255, 255, 255, 0.06) !important;
}

[data-theme="dark-fire"] td {
  color: var(--text-primary) !important;
  border-bottom-color: rgba(255, 255, 255, 0.06) !important;
}

[data-theme="dark-fire"] tr:hover {
  background: rgba(255, 45, 45, 0.06) !important;
}

/* ─────────── 11. BADGES ─────────── */
[data-theme="dark-fire"] .badge-blue {
  background: rgba(255, 45, 45, 0.15) !important;
  color: var(--primary) !important;
}

/* ─────────── 12. MODALES ─────────── */
[data-theme="dark-fire"] .modal-backdrop,
[data-theme="dark-fire"] .modal-overlay {
  background: rgba(0, 0, 0, 0.75) !important;
  backdrop-filter: blur(10px) !important;
}

[data-theme="dark-fire"] .modal-card,
[data-theme="dark-fire"] .modal-content {
  background: var(--bg-card) !important;
  box-shadow: var(--shadow-dark-lg) !important;
}

[data-theme="dark-fire"] .modal-title {
  color: var(--text-primary) !important;
}

/* ─────────── 13. BOTÓN TOGGLE DE TEMA ─────────── */
[data-theme="dark-fire"] #btn-tema {
  background: var(--bg-card) !important;
  color: var(--primary) !important;
  box-shadow:
    var(--shadow-dark-md),
    0 0 20px rgba(255, 45, 45, 0.25) !important;
}

[data-theme="dark-fire"] #btn-tema:hover {
  box-shadow:
    var(--shadow-dark-lg),
    0 0 32px rgba(255, 45, 45, 0.45) !important;
}

[data-theme="dark-fire"] #btn-tema .fa-sun {
  color: #fbbf24 !important;
  text-shadow: 0 0 12px rgba(251, 191, 36, 0.7) !important;
}

/* ─────────── 14. FOQUITOS SIGUEN FUNCIONANDO ─────────── */
[data-theme="dark-fire"] .foquito-rojo {
  background: #ff2d2d !important;
  box-shadow:
    0 0 0 2px var(--bg-card),
    0 0 14px rgba(255, 45, 45, 1) !important;
}

[data-theme="dark-fire"] .foquito-verde {
  background: #22c55e !important;
  box-shadow:
    0 0 0 2px var(--bg-card),
    0 0 12px rgba(34, 197, 94, 0.9) !important;
}

/* ─────────── 15. STATS ─────────── */
[data-theme="dark-fire"] .stat .value {
  color: var(--primary) !important;
  text-shadow: 0 0 20px rgba(255, 45, 45, 0.5) !important;
}

/* ─────────── 16. ADMIN CARDS (íconos) ─────────── */
[data-theme="dark-fire"] .admin-card .icono-3d {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important;
  box-shadow:
    inset 0 -4px 8px rgba(0, 0, 0, 0.3),
    inset 0 3px 6px rgba(255, 255, 255, 0.15),
    0 6px 20px rgba(255, 45, 45, 0.4) !important;
}

[data-theme="dark-fire"] .admin-card:hover .icono-3d {
  box-shadow:
    inset 0 -4px 8px rgba(0, 0, 0, 0.3),
    inset 0 3px 6px rgba(255, 255, 255, 0.15),
    0 10px 32px rgba(255, 45, 45, 0.6) !important;
}

/* ─────────── 17. AURORA DEL FONDO (roja tenue) ─────────── */
[data-theme="dark-fire"] body::before {
  background:
    radial-gradient(circle at 15% 20%, rgba(255, 45, 45, 0.08) 0%, transparent 40%),
    radial-gradient(circle at 85% 80%, rgba(204, 0, 0, 0.06) 0%, transparent 45%);
}

/* ─────────── 18. LOGIN PIN (núcleo orbital rojo) ─────────── */
[data-theme="dark-fire"] .nucleo-orbital,
[data-theme="dark-fire"] .nucleo-orbital-inner,
[data-theme="dark-fire"] .nucleo-centro {
  background: var(--bg-card) !important;
}

[data-theme="dark-fire"] .pin-card button#btn-login {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark)) !important;
  box-shadow:
    0 8px 20px rgba(255, 45, 45, 0.4),
    inset 0 2px 0 rgba(255, 255, 255, 0.15) !important;
}

[data-theme="dark-fire"] .pin-card input {
  background: var(--bg-card-soft) !important;
  color: var(--text-primary) !important;
}

[data-theme="dark-fire"] .pin-card input:focus {
  border-color: var(--primary) !important;
  box-shadow:
    inset 4px 4px 8px rgba(0, 0, 0, 0.5),
    inset -4px -4px 8px rgba(255, 255, 255, 0.03),
    0 0 0 4px rgba(255, 45, 45, 0.15) !important;
}

/* ─────────── 19. TOTAL MONETARIO / CREDENCIALES ─────────── */
[data-theme="dark-fire"] .total-monetario {
  background: rgba(34, 197, 94, 0.1) !important;
  border-color: var(--success) !important;
}

[data-theme="dark-fire"] .credenciales-card {
  background: rgba(34, 197, 94, 0.08) !important;
}
/* ============================================================
   PARCHE v6.1 — Menú neumórfico (ambos temas)
              + LEDs y aura también en modo claro
   ============================================================ */

/* ═══════════════════════════════════════════════════════
   1. LED EN TODAS LAS TARJETAS — MODO CLARO (light-ice)
   ═══════════════════════════════════════════════════════ */
[data-theme="light-ice"] .module-card::after,
[data-theme="light-ice"] .module-card[data-led="1"]::after,
[data-theme="light-ice"] .module-card[data-led="2"]::after,
[data-theme="light-ice"] .module-card[data-led="3"]::after {
  content: '';
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  width: 40px;
  height: 6px;
  border-radius: 8px;
  background: var(--primary);
  box-shadow:
    0 0 8px rgba(0, 147, 196, 0.55),
    0 0 16px rgba(0, 147, 196, 0.25);
  opacity: 0.5;
  transition: all 0.35s cubic-bezier(.22, 1, .36, 1);
  z-index: 1;
  pointer-events: none;
}

[data-theme="light-ice"] .module-card:hover::after,
[data-theme="light-ice"] .module-card[data-led="1"]:hover::after,
[data-theme="light-ice"] .module-card[data-led="2"]:hover::after,
[data-theme="light-ice"] .module-card[data-led="3"]:hover::after {
  opacity: 1;
  width: 56px;
  height: 7px;
  box-shadow:
    0 0 12px rgba(0, 147, 196, 1),
    0 0 24px rgba(0, 147, 196, 0.7),
    0 0 44px rgba(0, 147, 196, 0.4);
}

/* ═══════════════════════════════════════════════════════
   2. AURA EN EL ICONO AL HOVER — MODO CLARO
   ═══════════════════════════════════════════════════════ */
[data-theme="light-ice"] .module-card i {
  transition: all 0.35s cubic-bezier(.22, 1, .36, 1);
}

[data-theme="light-ice"] .module-card:hover i {
  transform: scale(1.12) rotate(-3deg);
  color: var(--primary-light) !important;
  filter:
    drop-shadow(0 0 10px var(--primary))
    drop-shadow(0 0 4px var(--primary));
  box-shadow:
    var(--shadow-md),
    0 0 28px rgba(0, 147, 196, 0.55) !important;
}

/* ═══════════════════════════════════════════════════════
   3. MENÚ NEUMÓRFICO — MODO CLARO (light-ice)
   ═══════════════════════════════════════════════════════ */
[data-theme="light-ice"] .side-menu {
  border-left: 1px solid rgba(0, 0, 0, 0.04);
}

/* Íconos del menú: círculo neumórfico con doble sombra */
[data-theme="light-ice"] .menu-item i {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow:
    -2px -2px 6px #ffffff,
    2px 2px 6px #b8bdc9 !important;
  transition: all 0.25s ease;
}

/* Hover del item */
[data-theme="light-ice"] .menu-item:hover {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow: none !important;
}

[data-theme="light-ice"] .menu-item:hover i {
  color: var(--primary) !important;
  box-shadow:
    -2px -2px 6px #ffffff,
    2px 2px 6px #b8bdc9,
    0 0 14px rgba(0, 147, 196, 0.4) !important;
}

/* Item activo: HUNDIDO (neumorfismo interior) */
[data-theme="light-ice"] .menu-item.active {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow:
    inset 3px 3px 7px #b8bdc9,
    inset -3px -3px 7px #ffffff !important;
  transform: none;
}

[data-theme="light-ice"] .menu-item.active i {
  background: var(--bg-card) !important;
  color: var(--primary) !important;
  box-shadow:
    -2px -2px 6px #ffffff,
    2px 2px 6px #b8bdc9 !important;
}

/* Divisor del menú más sutil y neumórfico */
[data-theme="light-ice"] .menu-divider {
  height: 2px !important;
  background: linear-gradient(90deg, transparent, rgba(0, 147, 196, 0.25), transparent) !important;
  box-shadow: none !important;
  opacity: 1;
}

[data-theme="light-ice"] .section-label {
  color: var(--text-muted) !important;
}

[data-theme="light-ice"] .close-menu {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  box-shadow:
    -2px -2px 6px #ffffff,
    2px 2px 6px #b8bdc9 !important;
}

[data-theme="light-ice"] .close-menu:hover {
  color: var(--primary) !important;
}

/* ═══════════════════════════════════════════════════════
   4. MENÚ NEUMÓRFICO — MODO OSCURO (dark-fire)
   (reescribe lo anterior para que sea consistente)
   ═══════════════════════════════════════════════════════ */
[data-theme="dark-fire"] .menu-item i {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow:
    -3px -3px 8px rgba(255, 45, 45, 0.06),
    3px 3px 8px #050505 !important;
  transition: all 0.25s ease;
}

[data-theme="dark-fire"] .menu-item:hover {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow: none !important;
}

[data-theme="dark-fire"] .menu-item:hover i {
  color: var(--primary-light) !important;
  box-shadow:
    -3px -3px 8px rgba(255, 45, 45, 0.06),
    3px 3px 8px #050505,
    0 0 16px rgba(255, 45, 45, 0.4) !important;
}

[data-theme="dark-fire"] .menu-item.active {
  background: var(--bg-card-soft) !important;
  color: var(--primary) !important;
  box-shadow:
    inset 4px 4px 8px #050505,
    inset -4px -4px 8px rgba(255, 45, 45, 0.05) !important;
  transform: none;
}

[data-theme="dark-fire"] .menu-item.active i {
  background: var(--bg-card) !important;
  color: var(--primary) !important;
  box-shadow:
    -3px -3px 8px rgba(255, 45, 45, 0.06),
    3px 3px 8px #050505 !important;
}

[data-theme="dark-fire"] .menu-divider {
  height: 2px !important;
  background: linear-gradient(90deg, transparent, rgba(255, 45, 45, 0.25), transparent) !important;
  box-shadow: none !important;
  opacity: 1;
}

[data-theme="dark-fire"] .close-menu {
  background: var(--bg-card-soft) !important;
  color: var(--text-secondary) !important;
  box-shadow:
    -3px -3px 8px rgba(255, 45, 45, 0.06),
    3px 3px 8px #050505 !important;
}

[data-theme="dark-fire"] .close-menu:hover {
  color: var(--primary) !important;
}

/* ═══════════════════════════════════════════════════════
   FIN PARCHE v6.1
   ═══════════════════════════════════════════════════════ */
/* ─────────── FIN GRAFITO VOLCÁNICO ROJO ─────────── */

/* ============================================================
   CIERRE — Versión del archivo
   ============================================================ */

/*
  ============================================================
  MARTIN SISTEMS — styles-nuevo.css
  Rediseño CORE Térmico · v1.0 · COMPLETO
  
  Temas:
  - light-ice  (Claro Glaciar)  → DEFAULT
  - dark-fire  (Oscuro Volcán)  → toggle
  
  Partes:
  ✅ Parte 1 — Variables + Reset + Aurora + Transición + Botón toggle
  ✅ Parte 2 — Splash + Login + Núcleo + App Layout + Header
  ✅ Parte 3 — Side menu + Main + Section header + Cards grid
  ✅ Parte 4 — Module cards + Foqutos + Formularios + Botones
  ✅ Parte 5 — Tablas + Badges + Stats + Modales + Toasts
  ✅ Parte 6 — Empty states + Mensajes + Historial + Credenciales + Admin cards
  ✅ Parte 7 — Gráficas + Lista empleados + Detalle + Total + Overlay + Dev
  ✅ Parte 8 — Responsive + Utilidades + Fixes + Cierre
  
  Autor: Rediseño CORE
  Fecha: 2026-10-31
  ============================================================
*/