/*Style bueno/*
/* ====================== */
/* BOTONES GENERALES */
/* ====================== */
.btn {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  cursor: pointer;
  font-weight: 500;
  border: none;
  white-space: nowrap;
  margin: 0 2px;
  gap: 0.5rem;
  padding: 0.5rem 1.25rem;
  font-size: 0.875rem;
  border-radius: 4px;
  min-width: 80px;
  height: 38px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Tamaños alternativos */
.btn-lg {
  padding: 0.65rem 1.5rem;
  font-size: 1rem;
  height: 46px;
  min-width: 100px;
  gap: 0.6rem;
}

.btn-sm {
  padding: 0.25rem 0.75rem;
  font-size: 0.8125rem;
  height: 32px;
  min-width: 70px;
  gap: 0.4rem;
}

/* Variantes de color */
.btn-primary {
  background-color: var(--primary);
  color: white;
}
.btn-secondary {
  background-color: var(--secondary);
  color: white;
}
.btn-success {
  background-color: var(--success);
  color: white;
}
.btn-danger {
  background-color: var(--danger);
  color: white;
}
.btn-warning {
  background-color: var(--warning);
  color: var(--dark);
}
.btn-info {
  background-color: var(--info);
  color: white;
}

.bg-primary {
  background-color: var(--primary) !important;
  color: white;
}
.bg-secondary {
  background-color: var(--secondary) !important;
  color: white;
}
.bg-success {
  background-color: var(--success) !important;
  color: white;
}
.bg-danger {
  background-color: var(--danger) !important;
  color: white;
}
.bg-warning {
  background-color: var(--warning) !important;
  color: var(--dark);
}
.bg-info {
  background-color: var(--info) !important;
  color: white;
}

.border-primary {
  border-color: var(--primary) !important;
}
.border-secondary {
  border-color: var(--secondary) !important;
}
.border-success {
  border-color: var(--success) !important;
}
.border-danger {
  border-color: var(--danger) !important;
}
.border-warning {
  border-color: var(--warning) !important;
}
.border-info {
  border-color: var(--info) !important;
}

/* Efectos hover para elementos con clases bg- */
.bg-primary:hover,
.bg-primary:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

.bg-secondary:hover,
.bg-secondary:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

.bg-success:hover,
.bg-success:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

.bg-danger:hover,
.bg-danger:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

.bg-warning:hover,
.bg-warning:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

.bg-info:hover,
.bg-info:focus-within {
  filter: brightness(95%);
  transition: filter 0.2s ease;
}

/* Efectos hover para bordes */
.border-primary:hover,
.border-primary:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--primary-rgb), 0.25);
}

.border-secondary:hover,
.border-secondary:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--secondary-rgb), 0.25);
}

.border-success:hover,
.border-success:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--success-rgb), 0.25);
}

.border-danger:hover,
.border-danger:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--danger-rgb), 0.25);
}

.border-warning:hover,
.border-warning:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--warning-rgb), 0.25);
}

.border-info:hover,
.border-info:focus {
  box-shadow: 0 0 0 0.2rem rgba(var(--info-rgb), 0.25);
}

/* Efectos hover */
.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  color: white;
}
.btn-primary:hover {
  background-color: #1a252f;
}
.btn-secondary:hover {
  background-color: #2980b9;
}

/* ================================== */
/* ESTILOS ESPECÍFICOS PARA EL DROPDOWN */
/* ================================== */
.btn-group .dropdown-toggle {
  transition: all 0.3s ease !important; /* Mantiene la transición suave */
}

/* Mantiene el efecto hover en el botón PERO solo para el contenedor */
.btn-group .btn-primary.dropdown-toggle:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  background-color: #1a252f; /* Mantiene tu color hover */
}

/* Estilos específicos para el ICONO dentro del dropdown */
.btn-group .dropdown-toggle i.fas {
  color: white !important;
  transition: none !important;
  display: inline-block; /* Necesario para que transform funcione */
}

/* Anula cualquier transformación en el icono */
.btn-group .dropdown-toggle:hover i.fas,
.btn-group .dropdown-toggle:focus i.fas {
  transform: none !important;
  color: white !important;
}

/* Mantiene el cursor pointer solo en el botón principal */
.btn-group > .btn {
  cursor: pointer;
}

/* ====================== */
/* BOTONES DE TABLA (CON VARIABLES PERSONALIZADAS) */
/* ====================== */
.table_editar,
.table_eliminar {
  padding: 0.5rem 0.7rem; /* Mismo padding vertical que .btn */
  height: 38px; /* Misma altura que .btn */
  font-size: 0.82rem;
  height: 40px;
  min-width: 50px;
  border-radius: 0.25rem;
  box-shadow: var(--accent-shadow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-speed) ease-in-out;
  border: 1px solid transparent;
  cursor: pointer;
  gap: 0.4rem;
  font-weight: 500;
}

/* ESTILO EDITAR (USANDO TU VARIABLE WARNING) */
.table_editar {
  background-color: var(--warning) !important;
  color: var(--dark) !important;
  border-color: var(--warning);
}

/* ESTILO ELIMINAR (USANDO TU VARIABLE DANGER) */
.table_eliminar {
  background-color: var(--danger);
  color: var(--white) !important;
  border-color: var(--danger);
}

/* ESTILO CREAR (USANDO TU VARIABLE PRIMARY) */
/* HOVER STATES (CON VARIABLES) */
.table_editar:hover {
  background-color: color-mix(in srgb, var(--warning), white 15%) !important;
  border-color: color-mix(in srgb, var(--warning), black 10%);
  color: var(--dark) !important;
  box-shadow: var(--deep-shadow);
}

.table_eliminar:hover {
  background-color: color-mix(in srgb, var(--danger), black 10%) !important;
  border-color: color-mix(in srgb, var(--danger), black 15%);
}

/* FOCUS STATES (CON VARIABLES) */
.table_editar:focus,
.table_eliminar:focus {
  box-shadow: 0 0 0 0.25rem color-mix(in srgb, var(--warning), transparent 50%);
  outline: 0;
}

/* ICONOS */
.table_editar i,
.table_eliminar i {
  font-size: 0.9em;
  transition: transform var(--transition-speed) ease;
  color: inherit !important;
}

/* EFECTO HOVER ICONOS */
.table_editar:hover i,
.table_eliminar:hover i {
  transform: scale(1.15);
}

/* AJUSTES PARA PANTALLAS MUY GRANDES */
@media (min-width: 1600px) {
  .table_editar,
  .table_eliminar {
    padding: 0.4rem 0.8rem;
    font-size: 0.85rem;
    height: 42px;
    min-width: 55px;
  }
}

/* ====================== */
/* HEADER PROFESIONAL */
/* ====================== */
.table-header-pro thead th {
  background: linear-gradient(to bottom, #3a4f6b, #2c3e50);
  color: white;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  position: relative;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  padding: 12px 15px;
  border: none;
  white-space: nowrap;
  vertical-align: middle;
}

.table-header-pro thead th:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(to right, #3498db, #2ecc71);
}

.table-header-pro tbody td {
  font-weight: 500;
}

/* ====================== */
/* CLASE REUTILIZABLE */
/* ====================== */
.table-header-gradient {
  width: 100%;
  margin-bottom: 1rem;
  color: #212529;
  border-collapse: collapse;
}

.table-header-gradient thead th {
  background: linear-gradient(to bottom, #3a4f6b, #2c3e50);
  color: white;
  position: relative;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.5px;
  padding: 12px 15px;
  border: none;
  white-space: nowrap;
  vertical-align: middle;
}

.table-header-gradient thead {
  position: relative;
}

.table-header-gradient thead:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(to right, #3498db, #2ecc71);
  z-index: 2;
}

/* ====================== */
/* FOOTER DE TABLA */
/* ====================== */
.table-footer-pro tfoot td {
  background: #f8f9fa;
  border-top: 1px solid #dee2e6;
  border-bottom: 3px solid #3a4f6b;
}

/* ====================== */
/* ICONOS */
/* ====================== */
.table-hover tbody tr:hover td i {
  transition: color 0.2s ease-in-out;
}

/* CORRECCIÓN PARA BOTONES EN TABLAS (SOLUCIÓN DEFINITIVA) */
.table_editar:hover {
  background-color: var(--warning) !important; /* Mantiene el color original */
}

.table_eliminar:hover {
  background-color: var(--danger) !important; /* Mantiene el color original */
}

/* Excepción para botón crear con estilo primario */

.table_editar i,
.table_eliminar i {
  transition: all 0.2s ease;
}

.table_editar:hover i {
  transform: scale(1.1);
}

.table_eliminar:hover i {
  transform: scale(1.1);
}

.table-header-gradient thead th i,
.table-header-pro thead th i {
  transition: all 0.2s ease;
}

.table-header-gradient thead th:hover i,
.table-header-pro thead th:hover i {
  color: #2ecc71 !important;
  transform: scale(1.1);
}

/* =================================== */
/* BADGES PREMIUM CON HOVER CORREGIDO */
/* =================================== */
.status-badge {
  border-radius: 24px !important;
  padding: 0.6rem 1.2rem !important;
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  min-width: 125px !important;
  width: 125px !important;
  text-transform: uppercase !important;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1) !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  box-sizing: border-box !important;
  text-align: center !important;
  line-height: 1.2 !important;
  cursor: default !important;
  transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1) !important;
  position: relative !important;
  overflow: hidden !important;
  border: none !important;
  z-index: 1 !important;
}

/* Efecto hover mejorado - CORREGIDO */
.status-badge:hover {
  transform: translateY(-3px) !important;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15) !important;
  filter: brightness(
    0.95
  ) !important; /* Reemplaza el overlay por un filtro más fiable */
}

/* ELIMINADO el :before que causaba problemas de color */

/* Estados con gradientes - versión optimizada */
.status-active {
  background: linear-gradient(135deg, #28a745 0%, #5cb85c 100%) !important;
  color: white !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2) !important;
}

.status-inactive {
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
  color: white !important;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.2) !important;
}

/* Iconos con efecto - versión mejorada */
.status-badge i {
  font-size: 0.95em !important;
  min-width: 16px !important;
  text-align: center !important;
  transition: transform 0.3s ease !important;
  filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.2)) !important;
  display: inline-block !important;
}

.status-badge:hover i {
  transform: scale(1.15) translateZ(0) !important;
}

/* Efecto ripple optimizado */
.status-badge:after {
  content: "" !important;
  position: absolute !important;
  top: 50% !important;
  left: 50% !important;
  width: 8px !important;
  height: 8px !important;
  background: rgba(255, 255, 255, 0.4) !important;
  opacity: 0 !important;
  border-radius: 100% !important;
  transform: scale(0) translate(-50%, -50%) !important;
  transform-origin: 50% 50% !important;
  z-index: -1 !important;
  pointer-events: none !important;
}

.status-badge:hover:after {
  animation: ripple 0.6s ease-out forwards !important;
}

@keyframes ripple {
  0% {
    transform: scale(0);
    opacity: 0.4;
  }
  100% {
    transform: scale(12);
    opacity: 0;
  }
}

/* Responsividad mejorada */
@media (max-width: 768px) {
  .status-badge {
    min-width: 110px !important;
    width: auto !important;
    padding: 0.5rem 1rem !important;
    font-size: 0.9rem !important;
  }

  .status-badge:hover {
    transform: translateY(-2px) !important;
  }
}

/* =================================== */
/* ESTILOS PARA EJEMPLOS */
/* =================================== */
#ejemplo_calculo .ejemplo-contenedor {
  background-color: var(--primary);
  border: 2px solid var(--secondary);
  color: white;
  padding: 15px;
  border-radius: 8px;
  margin-top: 15px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* ==================== */
/* ESTILOS PARA TOPBAR - REVISADO */
/* ==================== */
.sb-topnav {
  background-color: var(--topnav-bg);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  padding: 0.5rem 1.5rem;
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  height: 60px;
  z-index: 1060; /* Alto pero por debajo del sidebar cuando está abierto */
  display: flex;
  align-items: center;
  transition: all var(--transition-speed) ease;
}

/* Logo en topbar - Aseguramos que esté siempre visible */
.sb-topnav .navbar-brand {
  margin-right: 1.5rem;
  display: flex;
  align-items: center;
  z-index: 1070; /* Más alto que el sidebar */
  position: relative; /* Necesario para z-index */
}

.sb-topnav .navbar-brand .logo {
  max-height: 40px;
  transition: all var(--transition-speed) ease;
  z-index: inherit;
}

.sb-topnav .navbar-brand:hover .logo {
  transform: scale(1.05);
}

/* Botón del sidebar toggle */
#sidebarToggle {
  color: var(--topnav-text) !important;
  margin-right: 1rem;
  margin-left: 0;
  font-size: 1.25rem;
  transition: all var(--transition-speed) ease;
  background: transparent;
  border: none;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 1070; /* Igual que el logo */
  position: relative;
}

.sb-topnav #global-fullscreen-btn {
  color: var(--topnav-text);
  margin-right: 1rem;
  font-size: 1.25rem;
  transition: all var(--transition-speed) ease;
  background: transparent;
  border: none;
  outline: none;
  padding: 0.5rem 0.7rem;
}

.sb-topnav #sidebarToggle:hover,
.sb-topnav #global-fullscreen-btn:hover {
  color: var(--topnav-text-hover);
  text-decoration: none;
}

#sidebarToggle i.fa-lg {
  font-size: 1.1rem;
  color: inherit !important;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}

#sidebarToggle:hover {
  background-color: var(--topnav-hover-bg);
  color: var(--topnav-text-hover) !important;
  transform: rotate(90deg);
}

.sb-topnav #global-fullscreen-btn:hover {
  transform: scale(1.1);
}

/* Iconos en el topbar */
.sb-topnav .fa-lg {
  color: var(--topnav-text);
  transition: all var(--transition-speed) ease;
}

.sb-topnav .nav-link:hover .fa-lg,
.sb-topnav .dropdown-item:hover .fa-lg {
  color: var(--topnav-text-hover);
}

/* Menú principal del topbar */
.sb-topnav .navbar-nav {
  display: flex;
  flex-direction: row;
  align-items: center;
  margin-right: auto;
}

.sb-topnav .navbar-nav .nav-item {
  margin: 0 0.1rem;
}

.sb-topnav .navbar-nav .nav-link {
  color: var(--topnav-text);
  padding: 0.5rem 0.6rem;
  border-radius: 6px;
  transition: all var(--transition-speed) ease;
  display: flex;
  align-items: center;
  position: relative;
}

.sb-topnav .navbar-nav .nav-link i {
  margin-right: 0.25rem;
  font-size: 1.1rem;
  color: inherit;
}

.sb-topnav .navbar-nav .nav-link:hover {
  background-color: var(--topnav-hover-bg);
  color: var(--topnav-text-hover);
  transform: translateY(-2px);
}

.sb-topnav .navbar-nav .nav-link.active {
  background-color: var(--topnav-active-bg);
  color: var(--topnav-text-hover);
  font-weight: 600;
}

.sb-topnav .navbar-nav .nav-link::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 2px;
  background-color: var(--secondary);
  transition: all var(--transition-speed) ease;
}

.sb-topnav .navbar-nav .nav-link:hover::after,
.sb-topnav .navbar-nav .nav-link.active::after {
  width: 70%;
}

/* Menú desplegable en topbar */
.sb-topnav .dropdown-menu {
  border: none;
  border-radius: 8px;
  box-shadow: var(--deep-shadow);
  margin-top: 0.5rem;
  animation: dropdownFadeIn var(--transition-speed) ease;
  background-color: white;
  z-index: 1070; /* Más alto que el sidebar */
}

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

.sb-topnav .dropdown-item {
  padding: 0.5rem 1.25rem;
  transition: all var(--transition-speed) ease;
  color: var(--dark);
  display: flex;
  align-items: center;
}

.sb-topnav .dropdown-item i {
  margin-right: 0.5rem;
  color: var(--gray-600);
  width: 1.25rem;
  text-align: center;
}

.sb-topnav .dropdown-item:hover,
.sb-topnav .dropdown-item:focus {
  background-color: var(--secondary);
  color: white;
}

.sb-topnav .dropdown-item:hover i,
.sb-topnav .dropdown-item:focus i {
  color: white;
}

.sb-topnav .dropdown-divider {
  border-color: var(--gray-300);
}

/* Menú de usuario en topbar */
.navbar-nav-user {
  margin-left: auto;
  padding-right: 0.5rem;
}

.navbar-nav-user .nav-item.dropdown {
  margin-left: 0.5rem;
}

.navbar-nav-user .nav-link {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  border-radius: 30px;
  transition: all var(--transition-speed) ease;
  color: var(--topnav-text) !important;
  background: transparent;
}

.navbar-nav-user .nav-link:hover {
  background-color: var(--topnav-hover-bg) !important;
  color: var(--topnav-text-hover) !important;
}

.navbar-nav-user .nav-link i {
  margin-right: 0.25rem;
  color: inherit !important;
}

.navbar-nav-user .dropdown-menu {
  right: 10px;
  left: auto;
}

.navbar-nav-user .dropdown-item {
  color: var(--dark) !important;
}

.navbar-nav-user .dropdown-item i {
  color: var(--gray-600) !important;
}

.navbar-nav-user .dropdown-item:hover,
.navbar-nav-user .dropdown-item:focus {
  color: white !important;
}

.navbar-nav-user .dropdown-item:hover i,
.navbar-nav-user .dropdown-item:focus i {
  color: white !important;
}

/* Menú rápido para móviles en topbar */
.sb-topnav .dropdown.d-md-none .dropdown-menu {
  min-width: 250px;
  z-index: 1070;
}

.sb-topnav .dropdown.d-md-none .dropdown-item {
  padding: 0.75rem 1.25rem;
}

/* ESTILOS ESPECÍFICOS PARA EL LOGO - solución */
.logo-container .logo {
  filter: none !important; /* Elimina cualquier filtro que lo haga blanco */
  -webkit-filter: none !important; /* Para navegadores WebKit */
  width: auto !important; /* Asegura que mantenga proporciones */
  height: 40px !important; /* Altura fija (ajusta según necesites) */
  opacity: 1 !important; /* Asegura visibilidad completa */
}

/* Si el SVG tiene elementos internos con fill */
.logo-container .logo path,
.logo-container .logo polygon {
  fill: inherit !important; /* Respeta colores originales */
}

/* ==================== */
/* ESTILOS PARA SIDEBAR - REVISADO */
/* ==================== */
.sb-sidenav {
  background-color: var(--sidebar-bg);
  color: var(--sidebar-text);
  transition: all var(--transition-speed) ease;
  overflow-y: auto;
  height: 100vh;
  position: fixed;
  z-index: 1050; /* Por debajo del topbar normalmente */
  box-shadow: 2px 0 15px rgba(0, 0, 0, 0.2);
  font-size: 0.9rem;
  width: 240px;
  top: 0;
  left: 0;
  transform: translateX(0);
}

/* Sidebar cuando está activo en móviles */
.sb-sidenav.show-mobile {
  z-index: 1065 !important; /* Por encima del topbar cuando está abierto */
  transform: translateX(0);
  box-shadow: 5px 0 25px rgba(0, 0, 0, 0.3);
}

.sb-sidenav .custom-header {
  padding: 1rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.sb-sidenav .custom-header .logo {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 0 auto;
}

.sb-sidenav-menu {
  padding: 0.75rem 0;
  margin-top: 0;
  height: calc(100vh - 120px);
  overflow-y: auto;
}

.sb-sidenav-menu .nav {
  flex-direction: column;
  padding: 0 0.6rem;
}

/* Enlaces del sidebar */
.sb-sidenav-menu .nav-link {
  color: var(--sidebar-text);
  padding: 0.55rem 0.8rem;
  margin: 0.15rem 0;
  border-radius: 5px;
  display: flex;
  align-items: center;
  transition: all var(--transition-speed) ease;
  position: relative;
  font-size: 0.88rem;
}

.sb-sidenav-menu .nav-link:hover {
  background-color: var(--sidebar-hover-bg);
  color: var(--sidebar-text-hover);
  transform: translateX(3px);
}

.sb-sidenav-menu .nav-link.active {
  background-color: var(--sidebar-active-bg);
  color: var(--sidebar-text-hover);
  font-weight: 600;
  border-left: 2px solid var(--secondary);
}

/* Iconos del sidebar */
.sb-sidenav-menu .nav-link .sb-nav-link-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.5rem;
  min-width: 1.2rem;
  font-size: 0.85rem;
  color: inherit;
  transition: all var(--transition-speed) ease;
}

.sb-sidenav-menu .nav-link .sb-nav-link-icon i {
  font-size: 0.9em;
  width: 1em;
  height: 1em;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Flecha de colapso */
.sb-sidenav-menu .nav-link .sb-sidenav-collapse-arrow {
  margin-left: auto;
  font-size: 0.8rem;
  transition: transform var(--transition-speed) ease;
  color: inherit;
  opacity: 0.7;
}

.sb-sidenav-menu .nav-link[aria-expanded="true"] .sb-sidenav-collapse-arrow {
  transform: rotate(180deg);
}

/* Submenús del sidebar */
.sb-sidenav-menu .collapse {
  padding-left: 1rem;
}

.sb-sidenav-menu .collapse .nav-link {
  padding: 0.4rem 0.7rem;
  margin: 0.1rem 0;
  border-radius: 4px;
  font-size: 0.85rem;
}

.sb-sidenav-menu .collapse .nav-link.active {
  background-color: rgba(0, 0, 0, 0.1);
  border-left: 2px solid var(--secondary);
}

/* Footer del sidebar */
.sb-sidenav-footer {
  padding: 0.75rem;
  font-size: 0.8rem;
  text-align: center;
  position: absolute;
  bottom: 0;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.1);
  color: var(--sidebar-text);
}

/* ===== ESTADO NORMAL (expandido) ===== */
.sb-sidenav:not(.collapsed) {
  width: 240px;
  transition: width 0.3s ease;
}

.sb-sidenav:not(.collapsed) .nav-link {
  padding: 0.75rem 1rem;
  justify-content: flex-start;
}

.sb-sidenav:not(.collapsed) .sb-nav-link-icon {
  margin-right: 0.5rem;
}

/* ===== ESTADO COLAPSADO ===== */
.sb-sidenav.collapsed {
  width: 70px !important;
  overflow: visible;
}

.sb-sidenav.collapsed .nav-link {
  justify-content: center !important;
  padding: 0.75rem 0 !important;
  position: relative;
}

.sb-sidenav.collapsed .menu-text,
.sb-sidenav.collapsed .sb-sidenav-collapse-arrow {
  display: none !important;
}

.sb-sidenav.collapsed .sb-nav-link-icon {
  margin: 0 auto !important;
  font-size: 1.25rem;
  width: 40px;
  height: 40px;
  display: flex !important;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.1);
}

/* Tooltips */
.sb-sidenav.collapsed .nav-link::after {
  content: attr(data-tooltip);
  position: absolute;
  left: calc(100% + 15px);
  top: 50%;
  transform: translateY(-50%);
  background: #2c3e50;
  color: white;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  font-size: 0.85rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 1000;
  min-width: 120px;
  text-align: center;
}

.sb-sidenav.collapsed .nav-link:hover::after {
  opacity: 1;
}

/* Flecha del tooltip */
.sb-sidenav.collapsed .nav-link::before {
  content: "";
  position: absolute;
  left: 100%;
  top: 50%;
  transform: translateY(-50%);
  border: 6px solid transparent;
  border-right-color: #2c3e50;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 1001;
}

.sb-sidenav.collapsed .nav-link:hover::before {
  opacity: 1;
}

/* ==================== */
/* OVERLAY PARA MÓVILES */
/* ==================== */
.sb-content-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1060 !important; /* Por debajo del sidebar pero encima de todo lo demás */
  display: none;
  transition: opacity var(--transition-speed) ease;
}

.sb-content-overlay.active {
  display: block;
  opacity: 1;
}

/* ==================== */
/* COMPORTAMIENTO RESPONSIVE */
/* ==================== */
@media (max-width: 992px) {
  /* Sidebar en móviles */
  .sb-sidenav {
    transform: translateX(-100%);
    z-index: 1070 !important;
    width: 280px !important;
    transition: transform var(--transition-speed) ease;
  }

  .sb-sidenav.show-mobile {
    transform: translateX(0);
  }

  /* Topbar en móviles */
  .sb-topnav {
    z-index: 1065 !important;
  }

  /* Ajustes para el logo en móviles */
  .sb-topnav .navbar-brand {
    z-index: 1075 !important; /* Más alto que el sidebar */
  }

  /* Ajuste para el botón de toggle en móviles */
  #sidebarToggle {
    z-index: 1075 !important;
  }
}

@media (min-width: 993px) {
  .sb-content-overlay {
    display: none !important;
  }

  /* Comportamiento desktop */
  .sb-sidenav:not(.collapsed) {
    width: 240px;
  }

  .sb-sidenav.collapsed {
    width: 70px;
  }

  /* Ajuste del topbar cuando sidebar está colapsado */
  .sb-sidenav.collapsed ~ .sb-topnav {
    left: 70px;
  }

  /* Ajuste del topbar cuando sidebar está expandido */
  .sb-sidenav:not(.collapsed) ~ .sb-topnav {
    left: 240px;
  }
}

/* ==================== */
/* MEDIA QUERIES RESPONSIVE */
/* ==================== */
@media (max-width: 992px) {
  .sb-sidenav {
    transform: translateX(-100%);
    z-index: 1040;
  }

  .sb-sidenav.show {
    transform: translateX(0);
  }

  .sb-topnav .navbar-nav {
    display: none;
  }

  .sb-topnav .dropdown.d-md-none {
    display: block;
    margin-right: auto;
  }
}

@media (min-width: 992px) {
  .sb-sidenav:not(.collapsed) + .sb-topnav,
  .sb-sidenav:not(.collapsed) + .sb-topnav + #layoutSidenav_content {
    margin-left: 225px;
    transition: margin var(--transition-speed) ease;
  }

  .sb-sidenav.collapsed + .sb-topnav,
  .sb-sidenav.collapsed + .sb-topnav + #layoutSidenav_content {
    margin-left: 80px;
    transition: margin var(--transition-speed) ease;
  }

  .sb-topnav .dropdown.d-md-none {
    display: none;
  }
}

@media (max-width: 576px) {
  .sb-topnav {
    padding: 0.5rem;
  }

  .sb-topnav .navbar-brand {
    margin-right: 0.5rem;
  }

  .sb-topnav .navbar-brand .logo {
    max-height: 30px;
  }

  .float-ws {
    width: 50px;
    height: 50px;
    font-size: 1.75rem;
    bottom: 15px;
    right: 15px;
  }
}

/* ====================== */
/* ESTILO PREMIUM UNIVERSAL PARA TABLAS EN MODALES - VERSIÓN RESPONSIVE */
/* ====================== */

/* ENCABEZADO DEL MODAL (general para todos) */
.modal-header {
  background: linear-gradient(135deg, #1a2a3a 0%, #0d1620 100%);
  color: white;
  border-bottom: none;
  padding: 1.25rem 1.75rem;
  position: relative;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  /* Nuevos estilos para responsive */
  padding-top: 3.5rem; /* Espacio para el navbar en móviles */
  min-height: 80px; /* Altura mínima garantizada */
}

/* Ajuste específico para pantallas grandes */
@media (min-width: 768px) {
  .modal-header {
    padding-top: 1.25rem; /* Vuelve al padding original en desktop */
    min-height: auto;
  }
}

.modal-header:after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3498db, #2ecc71, #3498db);
  background-size: 200% auto;
  animation: gradientFlow 3s linear infinite;
  z-index: 1; /* Asegura que esté sobre el contenido */
}

@keyframes gradientFlow {
  0% {
    background-position: 0% center;
  }
  100% {
    background-position: 200% center;
  }
}

/* CONTENIDO DEL MODAL (general) */
.modal-content {
  border: none;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  /* Nuevos estilos para responsive */
  max-height: calc(100vh - 2rem); /* Limita la altura máxima */
  overflow-y: auto; /* Permite scroll interno */
  margin: 0.5rem; /* Margen mínimo en móviles */
}

@media (min-width: 576px) {
  .modal-content {
    margin: 1.75rem auto; /* Centrado en pantallas más grandes */
    max-width: 95%; /* Ancho máximo */
  }
}

/* ESTILOS GENERALES PARA TABLAS EN MODALES */
/* Footer de tabla */
.modal-body .card-footer {
  background: rgba(0, 0, 0, 0.02);
  border-top: 1px solid rgba(0, 0, 0, 0.05);
  padding: 0.75rem 1.5rem;
  font-size: 0.8rem;
  position: sticky;
  bottom: 0;
  z-index: 10;
}

/* Botón cerrar mejorado - Versión responsive */
.modal-header .close {
  opacity: 0.8;
  color: rgba(255, 255, 255, 0.9);
  transition: all 0.3s;
  font-size: 1.5rem;
  padding: 0.5rem;
  margin: -0.8rem -0.8rem -0.8rem auto;
  position: absolute;
  right: 1rem;
  top: 1rem;
  z-index: 1056; /* Por encima del gradiente */
}

@media (max-width: 576px) {
  .modal-header .close {
    top: 0.5rem; /* Posición más alta en móviles */
    right: 0.5rem;
    font-size: 1.25rem; /* Tamaño ligeramente menor */
  }
}

.modal-header .close:hover {
  opacity: 1;
  transform: rotate(90deg);
  color: #e74c3c;
}

/* Ajuste adicional para el título del modal */
.modal-title {
  width: calc(100% - 3rem); /* Asegura que no se solape con el botón cerrar */
  padding-right: 1rem; /* Espacio para el botón */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Corrección para el body del modal */
.modal-body {
  overflow-y: auto;
  max-height: calc(100vh - 200px); /* Altura dinámica */
}

/* Ajuste para cuando el sidebar está colapsado */
.sb-sidenav.collapsed ~ .modal {
  left: 70px;
  width: calc(100% - 70px);
}

@media (max-width: 992px) {
  .sb-sidenav.collapsed ~ .modal {
    left: 0;
    width: 100%;
  }
}

/* ====================== */
/* ESTILOS PARA SELECTORES DE AÑO/MESES EN GRÁFICOS */
/* ====================== */

/* Estilos base para los botones de selector */
.year-selector .btn {
  background-color: #f8f9fa;
  color: #495057;
  border: 1px solid #dee2e6;
  transition: all 0.2s ease;
}

/* Estado activo */
.year-selector .btn.active {
  background-color: #3a4f6b;
  color: white;
  border-color: #2c3e50;
}

/* Hover - Mantiene el color del texto original */
.year-selector .btn:hover {
  color: #495057 !important; /* Sobreescribe el color blanco */
  background-color: #e9ecef;
  transform: translateY(0); /* Elimina el efecto de movimiento */
  box-shadow: none; /* Elimina la sombra */
}

/* Hover para botón activo */
.year-selector .btn.active:hover {
  color: white !important;
  background-color: #2c3e50;
}

/* Efecto al hacer clic */
.year-selector .btn:active {
  transform: scale(0.98);
}

/* Tamaño pequeño consistente */
.year-selector.btn-group-sm .btn {
  padding: 0.25rem 0.5rem;
  font-size: 0.8125rem;
  line-height: 1.5;
  border-radius: 0.2rem;
}

/* Bordes para el grupo de botones */
.year-selector.btn-group {
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Estilo específico para ventas */
.btn-year-ventas.active {
  background-color: #1cc88a;
  border-color: #17a673;
}

.btn-year-ventas.active:hover {
  background-color: #17a673;
}

/* Estilo específico para compras */
.btn-year-compras.active {
  background-color: #36b9cc;
  border-color: #2a96a5;
}

.btn-year-compras.active:hover {
  background-color: #2a96a5;
}

/* Estilo específico para productos */
.btn-year-productos.active {
  background-color: #f6c23e;
  border-color: #dda20a;
  color: #212529;
}

.btn-year-productos.active:hover {
  background-color: #dda20a;
  color: #212529 !important;
}
/* =================================== */
/* ESTILOS PARA ICONOS EN TABLAS */
/* =================================== */

/* Contenedores de iconos */
.btn.btn-link,
.btn-outline-success {
  padding: 0.25rem !important;
  min-width: 30px !important;
  height: 30px !important;
  align-items: center !important;
  justify-content: center !important;
  margin: 0 !important;
}

/* Iconos principales */
.fa-search,
.aplicar_precio,
.aplicar_descuento,
.aplicar_precio_cotizacion,
.aplicar_descuento_cotizacion {
  font-size: 1rem !important;
  width: 1rem !important;
  height: 1rem !important;
  margin: 0 !important;
  padding: 0 !important;
  line-height: 1 !important;
}

/* Grupos de input con iconos */
.input-group-append {
  width: auto !important;
  margin-left: 0.25rem !important;
}

/* Alineación vertical */
.input-group {
  align-items: center !important;
}

/* Efectos hover */
.btn-link:hover .fa-search,
.btn-outline-success:hover .aplicar_precio,
.btn-outline-success:hover .aplicar_descuento,
.btn-outline-success:hover .aplicar_precio_cotizacion,
.btn-outline-success:hover .aplicar_descuento_cotizacion {
  transform: scale(1.1) !important;
  transition: transform 0.2s ease !important;
}

/* Tooltips */
[data-toggle="tooltip"] {
  cursor: pointer;
}

/* Colores específicos */
.icon-color {
  color: #6c757d !important;
}

.btn-outline-success .fas {
  color: #28a745 !important;
}

.btn-outline-success:hover .fas {
  color: white !important;
}

/* =================================== */
/* RESPONSIVE PARA DISPOSITIVOS MÓVILES */
/* =================================== */
@media (max-width: 768px) {
  .btn.btn-link,
  .btn-outline-success {
    padding: 0.2rem !important;
    min-width: 26px !important;
    height: 26px !important;
  }

  .fa-search,
  .aplicar_precio,
  .aplicar_descuento,
  .aplicar_precio_cotizacion,
  .aplicar_descuento_cotizacion {
    font-size: 0.9rem !important;
  }

  .input-group-append {
    margin-left: 0.15rem !important;
  }
}

/* ====================== */
/* ESTILOS DASHBOARD PREMIUM (fix números en 1 línea) */
/* ====================== */

/* Card base */
.dashboard-card {
  border: none;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  background: #fff;
  position: relative;
  z-index: 1;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.03);
}
.dashboard-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.3) 0%,
    rgba(255, 255, 255, 0) 100%
  );
  z-index: -1;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.dashboard-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.05);
}
.dashboard-card:hover::before {
  opacity: 1;
}

/* Borde superior de color */
.dashboard-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
}
.bg-gradient-primary::after {
  background: linear-gradient(90deg, #4e73df 0%, #224abe 100%);
}
.bg-gradient-success::after {
  background: linear-gradient(90deg, #1cc88a 0%, #13855c 100%);
}
.bg-gradient-warning::after {
  background: linear-gradient(90deg, #f6c23e 0%, #dda20a 100%);
}
.bg-gradient-danger::after {
  background: linear-gradient(90deg, #e74a3b 0%, #be2617 100%);
}

/* Body */
.card-body {
  padding: 1.25rem 1.5rem;
  position: relative;
}

/* Layout interno según tu HTML (.d-flex) */
.dashboard-card .card-body .d-flex {
  align-items: center !important;
  gap: 12px;
}
.dashboard-card .card-body .d-flex > div:first-child {
  flex: 1 1 auto;
  min-width: 0;
}
.dashboard-card .card-body .icon-circle {
  flex: 0 0 56px;
}

/* Icono */
.icon-circle {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.06);
}
.icon-circle i {
  position: relative;
  z-index: 1;
}
.bg-gradient-primary .icon-circle i {
  color: #4e73df;
}
.bg-gradient-success .icon-circle i {
  color: #1cc88a;
}
.bg-gradient-warning .icon-circle i {
  color: #f6c23e;
}
.bg-gradient-danger .icon-circle i {
  color: #e74a3b;
}

/* Subtítulo */
.dashboard-card h6 {
  font-size: clamp(0.66rem, 0.54rem + 0.25vw, 0.84rem);
  font-weight: 600;
  letter-spacing: 0.4px;
  color: #6c757d;
  margin-bottom: 0.3rem;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* NÚMERO: una sola línea + escalado agresivo */
.dashboard-card h2 {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: clip;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  font-size: clamp(0.84rem, 0.52rem + 1.1vw, 1.45rem);
  line-height: 1.05;
  font-weight: 700;
  margin: 0.2rem 0 0.45rem;
  color: #2d3748;
  letter-spacing: 0.06px;
  display: block;
}
.dashboard-card:hover h2 {
  color: #1a202c;
}

/* acento opcional */
.dashboard-card h2::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: 0;
  width: 40px;
  height: 3px;
  border-radius: 3px;
}
.bg-gradient-primary h2::after {
  background: #4e73df;
}
.bg-gradient-success h2::after {
  background: #1cc88a;
}
.bg-gradient-warning h2::after {
  background: #f6c23e;
}
.bg-gradient-danger h2::after {
  background: #e74a3b;
}

/* Pie */
.card-footer-text {
  font-size: 0.8rem;
  color: #718096;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.3s ease;
}
.card-footer-text i {
  margin-right: 6px;
  font-size: 0.9em;
}
.bg-gradient-primary .card-footer-text i {
  color: #4e73df;
}
.bg-gradient-success .card-footer-text i {
  color: #1cc88a;
}
.bg-gradient-warning .card-footer-text i {
  color: #f6c23e;
}
.bg-gradient-danger .card-footer-text i {
  color: #e74a3b;
}

/* Header normal */
.card-header.bg-white {
  background: #fff;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  padding: 1rem 1.5rem;
}

/* Gráficos */
.card-body canvas {
  width: 100% !important;
  height: auto !important;
  max-height: 250px;
}

/* Tabla */
.table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
}
.table-responsive::-webkit-scrollbar {
  height: 8px;
  background: #f5f5f5;
}
.table-responsive::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 4px;
}
.table-responsive::-webkit-scrollbar-thumb:hover {
  background: #555;
}

/* Animación */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.dashboard-card {
  animation: fadeInUp 0.5s ease forwards;
}
.dashboard-card:nth-child(1) {
  animation-delay: 0.1s;
}
.dashboard-card:nth-child(2) {
  animation-delay: 0.2s;
}
.dashboard-card:nth-child(3) {
  animation-delay: 0.3s;
}
.dashboard-card:nth-child(4) {
  animation-delay: 0.4s;
}

/* ====================== */
/* GRÁFICOS PREMIUM (igual que antes) */
/* ====================== */
.chart-container {
  position: relative;
  padding: 1rem;
  margin: -0.5rem;
}
.chartjs-render-monitor {
  animation: chartFadeIn 1s ease;
  transition: all 0.3s ease;
}
@keyframes chartFadeIn {
  from {
    opacity: 0.4;
    transform: scale(0.98);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
.chart-card {
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.03);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.03);
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  background: #fff;
}
.chart-card:hover {
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}
.chart-header {
  padding: 1.25rem 1.5rem 0.75rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.03);
  background: linear-gradient(to right, #f8f9fa, #fff);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.chart-title {
  font-size: 1rem;
  font-weight: 600;
  color: #2d3748;
  margin: 0;
  display: flex;
  align-items: center;
}
.chart-title i {
  margin-right: 10px;
  color: #4e73df;
  font-size: 1.1em;
}
.chart-actions {
  display: flex;
  gap: 8px;
}
.chart-btn {
  background: rgba(0, 0, 0, 0.03);
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #718096;
  cursor: pointer;
  transition: all 0.2s ease;
}
.chart-btn:hover {
  background: rgba(0, 0, 0, 0.05);
  color: #4a5568;
}
.chart-btn i {
  font-size: 0.9em;
}
.chartjs-tooltip {
  opacity: 1 !important;
  position: absolute;
  background: rgba(255, 255, 255, 0.95) !important;
  border: 1px solid rgba(0, 0, 0, 0.08) !important;
  border-radius: 8px !important;
  padding: 8px 12px !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
  transition: all 0.2s ease !important;
  pointer-events: none !important;
  backdrop-filter: blur(4px);
}
.chartjs-tooltip-key {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-right: 6px;
}
.chart-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  gap: 12px;
  margin-top: -10px;
}
.legend-item {
  display: flex;
  align-items: center;
  font-size: 0.75rem;
  color: #718096;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 4px 8px;
  border-radius: 20px;
  background: rgba(0, 0, 0, 0.02);
}
.legend-item:hover {
  background: rgba(0, 0, 0, 0.05);
}
.legend-color {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  margin-right: 6px;
  transition: all 0.2s ease;
}
.legend-item:hover .legend-color {
  transform: scale(1.2);
}
.bar-chart {
  padding: 0.5rem 1rem 1rem;
}
.bar-chart .chart-container {
  padding-bottom: 0;
}
.line-chart {
  padding: 0.5rem 1rem 1rem;
}
.line-chart .chart-container {
  padding-bottom: 0;
}
.chart-element-hover {
  transition: all 0.2s ease;
}
.chart-element-hover:hover {
  opacity: 0.8;
  transform: translateY(-1px);
}
@media (max-width: 768px) {
  .chart-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    padding: 1rem;
  }
  .chart-actions {
    align-self: flex-end;
  }
  .chart-legend {
    justify-content: flex-start;
    padding: 0.75rem 1rem;
  }
}

/* ====================== */
/* AGRESIVO PARA TABLET EN LANDSCAPE */
/* ====================== */

/* 1) Cualquier landscape con alto bajo */
@media (orientation: landscape) and (max-height: 820px) {
  .card-body {
    padding: 0.9rem 1rem;
  }
  .dashboard-card .card-body .d-flex {
    gap: 8px;
  }
  .icon-circle {
    width: 44px;
    height: 44px;
    flex-basis: 44px;
    font-size: 1.1rem;
  }
  .dashboard-card h6 {
    font-size: clamp(0.52rem, 0.42rem + 0.14vw, 0.7rem);
    margin-bottom: 0.15rem;
  }
  .dashboard-card h2 {
    /* MUY pequeño para garantizar 1 línea */
    font-size: clamp(0.58rem, 0.28rem + 0.75vw, 0.95rem);
    letter-spacing: 0.02px;
    margin: 0.12rem 0 0.3rem;
  }
  .dashboard-card h2::after {
    display: none;
  }
}

/* 2) 992–1199 ancho en landscape */
@media (min-width: 992px) and (max-width: 1199.98px) and (orientation: landscape) {
  .dashboard-card h2 {
    font-size: clamp(0.6rem, 0.3rem + 0.8vw, 1rem);
  }
}

/* 3) 1200–1366 ancho en landscape con poco alto */
@media (min-width: 1200px) and (max-width: 1366px) and (orientation: landscape) and (max-height: 820px) {
  .dashboard-card h2 {
    font-size: clamp(0.62rem, 0.32rem + 0.85vw, 1.05rem);
  }
}

/* ====== OVERRIDES DUROS (pegar al FINAL del CSS) ====== */

/* nunca ocultes el icono y hazlo compacto en pantallas bajas */
@media (orientation: landscape) and (max-height: 820px) {
  .dashboard-card .card-body {
    padding: 0.8rem 1rem !important;
  }
  .dashboard-card .card-body .d-flex {
    gap: 8px !important;
  }
  .dashboard-card .icon-circle {
    width: 40px !important;
    height: 40px !important;
    flex: 0 0 40px !important;
    font-size: 1rem !important;
  }
}

/* reduce AGRESIVO el número (1 línea garantizada) */
.dashboard-card h2,
#main_clientes,
#main_proveedores,
#main_facturas,
#main_compras {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: clip !important;
  line-height: 1.05 !important;
  margin: 0.15rem 0 0.3rem !important;
}

/* tablet landscape genérico */
@media (orientation: landscape) and (max-height: 820px) {
  #main_clientes,
  #main_proveedores,
  #main_facturas,
  #main_compras {
    font-size: clamp(0.56rem, 0.26rem + 0.7vw, 0.95rem) !important;
    letter-spacing: 0.02px !important;
  }
}

/* 992–1199px ancho en landscape */
@media (min-width: 992px) and (max-width: 1199.98px) and (orientation: landscape) {
  #main_clientes,
  #main_proveedores,
  #main_facturas,
  #main_compras {
    font-size: clamp(0.58rem, 0.28rem + 0.75vw, 1rem) !important;
  }
}

/* 1200–1366 ancho + landscape (alto bajo) */
@media (min-width: 1200px) and (max-width: 1366px) and (orientation: landscape) and (max-height: 820px) {
  #main_clientes,
  #main_proveedores,
  #main_facturas,
  #main_compras {
    font-size: clamp(0.6rem, 0.3rem + 0.8vw, 1.05rem) !important;
  }
}

/* por si tenías una regla que re-agranda el h2 en desktop */
@media (min-width: 1200px) {
  .dashboard-card h2 {
    font-size: 1.35rem !important;
  } /* desktop normal */
}

/*BOTON PANTALLA COMPLETA*/
#global-fullscreen-btn {
  color: #333; /* Color oscuro (casi negro) */
  padding: 0.5rem 0.75rem;
  margin: 0 0.25rem;
  transition: all 0.3s ease;
  border-radius: 4px;
  background-color: rgba(0, 0, 0, 0.1); /* Fondo oscuro semi-transparente */
  border: none;
  outline: none;
  font-size: 1rem;
  cursor: pointer;
}

/* Hover (mantiene colores oscuros) */
#global-fullscreen-btn:hover {
  color: #000; /* Negro sólido al pasar el cursor */
  background-color: rgba(0, 0, 0, 0.2); /* Fondo un poco más oscuro */
  transform: scale(1.05);
}

/* Efecto al hacer clic */
#global-fullscreen-btn:active {
  transform: scale(0.95);
}

/* Icono (siempre hereda el color del botón) */
#global-fullscreen-btn i {
  transition: all 0.3s ease;
  color: inherit;
}

/* Estado en pantalla completa (mantiene colores oscuros) */
#global-fullscreen-btn.fullscreen-active {
  color: #000; /* Negro sólido */
  background-color: rgba(0, 0, 0, 0.2); /* Fondo más oscuro */
}

/* Hover en pantalla completa */
#global-fullscreen-btn.fullscreen-active:hover {
  background-color: rgba(
    0,
    0,
    0,
    0.3
  ); /* Fondo más oscuro al pasar el cursor */
}

/* Ajuste de posición para alinear con otros elementos */
.navbar .btn-link {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
}

/* Asegurar que los botones estén alineados verticalmente */
.navbar > .btn-link {
  margin-top: auto;
  margin-bottom: auto;
}

/* ====================== */
/* ESTILOS PARA ICONOS EN MENÚ */
/* ====================== */

/* Iconos en el menú principal */
.navbar-nav .nav-link i {
  width: 20px;
  text-align: center;
  font-size: 0.95rem;
  transition: all 0.2s ease;
  margin-right: 0.5rem;
}

/* Efecto hover para iconos del menú */
.navbar-nav .nav-link:hover i {
  transform: scale(1.1);
  color: rgba(255, 255, 255, 0.9);
}

/* Iconos en el menú desplegable */
.dropdown-menu .dropdown-item i {
  width: 20px;
  text-align: center;
  font-size: 0.9rem;
  margin-right: 0.5rem;
  color: #6c757d;
  transition: all 0.2s ease;
}

/* Efecto hover para iconos del menú desplegable */
.dropdown-menu .dropdown-item:hover i {
  color: #fff;
  transform: scale(1.1);
}

/* Ajuste de espaciado para menú de usuario */
.navbar-nav-user .nav-link i {
  margin-right: 0.5rem;
}

/* Iconos en el menú de usuario desplegable */
.dropdown-menu-right .dropdown-item i {
  width: 20px;
  text-align: center;
  margin-right: 0.75rem;
}

/* Asegurar que los iconos no distorsionen el diseño */
.navbar-nav .nav-link,
.dropdown-menu .dropdown-item {
  display: flex;
  align-items: center;
  white-space: nowrap;
}

/* Ajuste para pantallas pequeñas */
@media (max-width: 768px) {
  .navbar-nav .nav-link i,
  .dropdown-menu .dropdown-item i {
    font-size: 0.85rem;
    margin-right: 0.4rem;
  }

  .dropdown-toggle i {
    margin-right: 0.5rem;
  }
}

/* Añade esto al final de tu CSS */

/* Estado activo para menú superior */
.navbar-nav .nav-item .nav-link.top-active {
  color: #ffffff !important;
  font-weight: 600;
  background-color: rgba(52, 152, 219, 0.2) !important;
}

.navbar-nav .nav-item .nav-link.top-active::after {
  width: 70% !important;
}

/* Estado activo para menú lateral */
.sb-sidenav .nav-link.side-active {
  background-color: rgba(0, 0, 0, 0.2) !important;
  color: #fff !important;
  font-weight: bold !important;
  border-left: 4px solid #3498db !important;
}

/* Cuando el sidebar está colapsado */
.sb-sidenav.collapsed .nav-link.side-active {
  border-left: none !important;
  border-right: 4px solid #3498db !important;
}

/* Para submenús activos */
.sb-sidenav .collapse .nav-link.side-active {
  background-color: rgba(0, 0, 0, 0.15) !important;
  padding-left: 2.5rem !important;
}

/* ========================== */
/* FOOTER DE TOTALES – PREMIUM COMPACTO (CENTRADO) */
/* ========================== */

/* Variables para alturas */
:root {
  --footer-h: 118px; /* alto aprox del footer en desktop */
  --control-h: 52px; /* alto de cada campo en desktop */
  --metric-w: 240px; /* ANCHO de cada tarjeta del total (clave para centrar) */
}

.footer1 {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  background: #fff;
  border-top: 1px solid #e0e0e0;
  box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.08);
  padding: 10px 0; /* compacto */
  transition: all 0.3s ease;
  width: 100%;
}

/* deja espacio para que el footer no tape el contenido */
body#view_bill {
  padding-bottom: calc(var(--footer-h) + 12px);
}

.footer1 .form-row {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 12px;
}

/* ========= GRILLA CENTRADA =========
     Usamos columnas de ancho fijo y centramos el bloque completo */
.footer1 .totals-grid {
  display: grid;
  grid-template-columns: repeat(5, var(--metric-w)); /* 5 columnas fijas */
  gap: 12px;
  justify-content: center; /* centra el conjunto dentro del contenedor */
  align-items: start;
}

/* Tarjeta de cada métrica */
.footer1 .metric {
  width: var(--metric-w);
  margin: 0 auto;
  text-align: center; /* centra textos dentro de la tarjeta */
}

.footer1 .metric label {
  display: block;
  font-size: 20px;
  font-weight: 600;
  color: #2c3e50;
  margin: 0 0 6px 0;
  text-align: center; /* centrado */
}

/* Grupo L | campo */
.footer1 .metric .input-group {
  display: flex;
  align-items: stretch;
  justify-content: center;
}

/* Caja del símbolo de moneda */
.footer1 .metric .input-group .input-group-text {
  font-size: 20px;
  padding: 0.25rem 0.5rem;
  background: #f8f9fa;
  border: 1px solid #ced4da;
  border-right: 0;
  border-radius: 0.5rem 0 0 0.5rem;
  display: flex;
  align-items: center; /* centra vertical */
  justify-content: center; /* centra horizontal */
  height: var(--control-h);
  min-width: 36px;
}

/* Campo de valor (textarea como display) */
.footer1 .metric .form-control {
  text-align: center; /* centra horizontal */
  background: #eef2f5;
  color: #495057;
  border: 1px solid #ced4da;
  border-left: 0;
  border-radius: 0 0.5rem 0.5rem 0;
  height: var(--control-h); /* alto fijo */
  line-height: var(--control-h); /* centra vertical una línea */
  padding: 0; /* sin padding para que el line-height mande */
  resize: none;
  overflow: hidden;
}

/* ==================== */
/* RESPONSIVE (centrado real por número de columnas) */
/* ==================== */

@media (max-width: 1399.98px) {
  :root {
    --footer-h: 114px;
  }
}

/* 4 columnas centradas */
@media (max-width: 1199.98px) {
  .footer1 .totals-grid {
    grid-template-columns: repeat(4, var(--metric-w));
  }
  :root {
    --footer-h: 112px;
  }
}

/* 3 columnas centradas */
@media (max-width: 991.98px) {
  :root {
    --control-h: 48px;
    --footer-h: 108px;
    --metric-w: 230px; /* un poco más compacto */
  }
  .footer1 {
    padding: 8px 0;
  }
  .footer1 .metric label {
    font-size: 18px;
  }
  .footer1 .metric .input-group .input-group-text {
    font-size: 18px;
  }
  .footer1 .totals-grid {
    grid-template-columns: repeat(3, var(--metric-w));
  }
}

/* 2 columnas centradas y footer relativo en móvil */
@media (max-width: 767.98px) {
  .footer1 {
    position: relative !important;
    width: 100% !important;
  }
  body#view_bill {
    padding-bottom: 24px;
  }

  :root {
    --control-h: 44px;
    --metric-w: 220px;
    --footer-h: 0px; /* no se usa en relative */
  }

  .footer1 .metric label {
    font-size: 16px;
  }
  .footer1 .metric .input-group .input-group-text {
    font-size: 16px;
  }
  .footer1 .totals-grid {
    grid-template-columns: repeat(2, var(--metric-w));
  }
}

/* 1 columna centrada */
@media (max-width: 575.98px) {
  :root {
    --control-h: 40px;
    --metric-w: 260px;
  }
  .footer1 .totals-grid {
    grid-template-columns: repeat(1, var(--metric-w));
  }
  .footer1 .metric label {
    font-size: 15px;
  }
  .footer1 .metric .input-group .input-group-text {
    font-size: 15px;
  }
}

/* MODO SOPORTE */
.modo_soporte {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: linear-gradient(135deg, #3498db 0%, #2c3e50 100%);
  color: white;
  padding: 5px 20px;
  font-weight: 500;
  position: fixed;
  top: 60px;
  left: 0;
  right: 0;
  font-size: 0.88rem;
  z-index: 1035;
  letter-spacing: 0.5px;
  height: 28px;
  overflow: hidden;
  font-family: "Segoe UI", system-ui, sans-serif;
  animation: pulse-soporte 2s infinite; /* Efecto de pulso */
}

@keyframes pulse-soporte {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 152, 219, 0.5);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(52, 152, 219, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(52, 152, 219, 0);
  }
}

/* Efecto de pulso sutil */
.soporte-pulse {
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    circle at center,
    rgba(255, 255, 255, 0.15) 0%,
    transparent 70%
  );
  opacity: 0;
  animation: pulseEffect 3s infinite;
}

@keyframes pulseEffect {
  0% {
    transform: scale(0.8);
    opacity: 0;
  }
  50% {
    transform: scale(1.1);
    opacity: 0.4;
  }
  100% {
    transform: scale(1.3);
    opacity: 0;
  }
}

/* Subrayado animado */
.soporte-underline {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.7),
    transparent
  );
  background-size: 200% auto;
  animation: shine 2s linear infinite;
}

@keyframes shine {
  0% {
    background-position: -100% 0;
  }
  100% {
    background-position: 100% 0;
  }
}

.modo_soporte i {
  font-size: 1em;
  position: relative;
  animation: float 3s ease-in-out infinite;
  color: #f1c40f;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-2px);
  } /* Animación más sutil */
}

/* Ajuste cuando sidebar está colapsado */
.sb-sidenav.collapsed ~ .modo_soporte {
  left: 70px;
  width: calc(100% - 70px); /* Asegura el 100% del ancho disponible */
}

/* Ajustes responsive */
@media (max-width: 992px) {
  .modo_soporte {
    left: 70px !important;
    width: calc(100% - 70px) !important;
  }
}

@media (max-width: 768px) {
  .modo_soporte {
    top: 56px;
    left: 0 !important;
    width: 100% !important;
    font-size: 0.82rem;
    padding: 4px 15px; /* Más compacto en móviles */
    height: 26px; /* Altura reducida en móviles */
  }
}

/* Efecto hover adicional */
.modo_soporte:hover {
  background: linear-gradient(135deg, #2980b9 0%, #1a252f 100%);
}

/* Efecto de respiración para el texto */
.modo_soporte span {
  animation: textBreath 4s ease-in-out infinite;
}

@keyframes textBreath {
  0%,
  100% {
    opacity: 0.9;
    text-shadow: 0 0 0 rgba(255, 255, 255, 0);
  }
  50% {
    opacity: 1;
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
  }
}

/* Efecto de brillo en el gradiente */
.modo_soporte {
  animation: gradientGlow 6s ease infinite;
  background-size: 200% 200%;
}

@keyframes gradientGlow {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* Efecto de vibración sutil */
@keyframes gentleVibration {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-1px);
  }
  75% {
    transform: translateX(1px);
  }
}

.modo_soporte:hover {
  animation:
    gentleVibration 0.3s linear infinite,
    gradientGlow 6s ease infinite;
}

/*PRUEBA SISTEMA*/
/* ESTILOS PARA ENTORNO DE PRUEBAS - Versión ajustada */
.env-badge {
  position: fixed;
  bottom: 60px; /* Subido 40px más que antes (de 20px a 60px) */
  right: 20px;
  padding: 12px 20px; /* Aumentado el padding para más tamaño */
  background-color: #ff9800; /* Naranja para entorno de pruebas */
  color: white;
  border-radius: 20px;
  font-size: 16px; /* Aumentado de 12px a 16px */
  font-weight: 700; /* Más grueso (de 600 a 700) */
  z-index: 99999;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.25); /* Sombra más pronunciada */
  text-transform: uppercase;
  letter-spacing: 1.5px; /* Más espacio entre letras */
  opacity: 0.95;
  display: flex;
  align-items: center;
  animation: pulse 2s infinite;
  min-width: 200px; /* Ancho mínimo para mejor legibilidad */
  text-align: center;
  justify-content: center;
}

.env-badge i {
  margin-right: 10px; /* Más espacio entre icono y texto */
  font-size: 18px; /* Icono más grande (de 14px a 18px) */
}

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

/* Para modo desarrollo */
.env-badge.dev {
  background-color: #2196f3; /* Azul */
}

/* Para modo producción */
.env-badge.prod {
  background-color: #4caf50; /* Verde */
  display: none;
}

/* Estilo profesional para el badge de base de datos */
.sb-sidenav-footer {
  padding: 12px 15px;
  background: linear-gradient(135deg, #2c3e50, #34495e);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.db-badge {
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 8px 12px;
  transition: all 0.3s ease;
}

.db-badge:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.db-icon {
  font-size: 16px;
  color: #3498db;
  margin-right: 10px;
  background: rgba(52, 152, 219, 0.2);
  padding: 8px;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.db-info {
  display: flex;
  flex-direction: column;
}

.db-label {
  font-size: 10px;
  color: #bdc3c7;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 2px;
}

.db-name {
  font-size: 13px;
  font-weight: 600;
  color: #ecf0f1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 150px;
}

/* Animación sutil para dar sensación de "flotar" */
@keyframes floatText {
  0% {
    transform: rotate(-15deg) translateY(-10px);
    opacity: 0.8; /* Opacidad ligeramente mayor */
  }
  100% {
    transform: rotate(-15deg) translateY(10px);
    opacity: 1; /* Máxima opacidad */
  }
}

/* Ajustes para pantallas más pequeñas */
@media (max-width: 768px) {
  .prueba-sistema {
    font-size: 8vw;
    transform: rotate(-10deg);
    color: rgba(255, 160, 160, 0.75); /* Un poco más fuerte en móviles */
  }

  @keyframes floatText {
    0% {
      transform: rotate(-10deg) translateY(-5px);
    }
    100% {
      transform: rotate(-10deg) translateY(5px);
    }
  }
}

/* Ajustes para pantallas muy grandes */
@media (min-width: 1600px) {
  .prueba-sistema {
    font-size: 80px;
  }
}

/* ====================== */
/* CONTADOR DE FACTURAS - VERSIÓN MEJORADA */
/* ====================== */
.customer-bill-box-center {
  position: absolute;
  left: 65%;
  transform: translateX(-50%) translateY(-5px);
  top: 50px;
  z-index: 10;
  width: auto;
  max-width: 35%;
  text-align: center;
  margin-bottom: 5px;
}

.facturas-counter {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 30px;
  padding: 10px 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  display: inline-flex;
  align-items: flex-start;
  font-size: 1rem;
  font-weight: 600;
  color: #3a4f6b;
  transition: all 0.3s ease;
  border-left: 4px solid #3a4f6b;
  animation: pulse-facturas-normal 3s infinite;
  backdrop-filter: blur(2px);
  gap: 12px;
  min-height: auto;
  line-height: 1.4;
}

.facturas-counter .counter-content {
  display: flex;
  flex-direction: column;
  gap: 3px;
  width: 100%;
}

.facturas-counter .counter-line {
  line-height: 1.3;
  padding: 1px 0;
}

.facturas-counter .days-left {
  font-size: 1rem;
  font-weight: normal;
  margin-top: 2px;
}

.facturas-counter .counter-link {
  color: inherit;
  text-decoration: underline;
  font-weight: bold;
  display: inline-block;
  margin-top: 3px;
  background: rgba(255, 255, 255, 0.2);
  padding: 2px 6px;
  border-radius: 3px;
}

.facturas-counter .counter-link:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Estados mejorados */
.facturas-counter.alert-normal {
  background: rgba(235, 241, 248, 0.9);
  border-left-color: #3a4f6b;
  animation: pulse-facturas-normal 3s infinite;
}

.facturas-counter.alert-warning {
  background: rgba(255, 248, 230, 0.9);
  border-left-color: #f6c23e;
  color: #856404;
  animation: pulse-facturas-warning 2s infinite;
}

.facturas-counter.alert-danger {
  background: rgba(255, 238, 238, 0.9);
  border-left-color: #e74a3b;
  color: #721c24;
  padding: 8px 15px;
  white-space: normal;
}

.facturas-counter.alert-danger .counter-line:first-child {
  font-weight: bold;
  margin-bottom: 3px;
}

/* Animaciones para cada estado */
@keyframes pulse-facturas-normal {
  0% {
    box-shadow: 0 0 0 0 rgba(58, 79, 107, 0.2);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(58, 79, 107, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(58, 79, 107, 0);
  }
}

@keyframes pulse-facturas-warning {
  0% {
    transform: translateY(0);
    box-shadow: 0 0 0 0 rgba(246, 194, 62, 0.3);
  }
  50% {
    transform: translateY(-2px);
    box-shadow: 0 0 0 8px rgba(246, 194, 62, 0);
  }
  100% {
    transform: translateY(0);
    box-shadow: 0 0 0 0 rgba(246, 194, 62, 0);
  }
}

@keyframes pulse-facturas-danger {
  0% {
    transform: translateY(0);
    box-shadow: 0 0 0 0 rgba(231, 74, 59, 0.3);
  }
  50% {
    transform: translateY(-3px);
    box-shadow: 0 0 0 10px rgba(231, 74, 59, 0);
  }
  100% {
    transform: translateY(0);
    box-shadow: 0 0 0 0 rgba(231, 74, 59, 0);
  }
}

/* Efecto de cambio de estado */
.facturas-counter.state-change {
  animation: state-change 0.3s ease;
}

@keyframes state-change {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

/* Responsive (Móvil) */
@media (max-width: 992px) {
  .customer-bill-box-center {
    position: relative;
    left: 0;
    transform: none;
    width: 100%;
    max-width: 100%;
    top: 0;
    margin: 15px 0;
    order: 1;
    display: flex;
    justify-content: center;
  }

  .facturas-counter {
    width: 90%;
    max-width: 400px;
    padding: 10px 15px;
    font-size: 1rem;
  }

  .facturas-counter .counter-line {
    font-size: 0.95rem;
  }

  .facturas-counter .days-left {
    font-size: 0.85rem;
  }
}

@media (max-width: 576px) {
  .facturas-counter {
    width: 95%;
    padding: 8px 12px;
    font-size: 0.95rem;
  }
}

/* ====================== */
/* ESTILOS ORIGINALES (SE MANTIENEN EXACTAMENTE IGUAL) */
/* ====================== */
.customer-bill-box-left {
  padding-left: 10px;
  padding-top: 10px;
  margin-left: 10px;
  float: left;
  position: relative;
  width: 600px;
  height: 82px;
  word-wrap: break-word;
  background-color: #e9ecef;
}

.customer-bill-box-right {
  padding-top: 10px;
  padding-left: 10px;
  margin-right: 10px;
  position: relative;
  float: right;
  width: 300px;
  height: 82px;
  word-wrap: break-word;
  background-color: #e9ecef;
}

.bill {
  padding-left: 10px;
  margin-left: 10px;
  position: relative;
  float: left;
}

/* ====================== */
/* ESTILOS ORIGINALES (SE MANTIENEN EXACTAMENTE IGUAL) */
/* ====================== */
.customer-bill-box-left {
  padding-left: 10px;
  padding-top: 10px;
  margin-left: 10px;
  float: left;
  position: relative;
  width: 600px;
  height: 82px;
  word-wrap: break-word;
  background-color: #e9ecef;
}

.customer-bill-box-right {
  padding-top: 10px;
  padding-left: 10px;
  margin-right: 10px;
  position: relative;
  float: right;
  width: 300px;
  height: 82px;
  word-wrap: break-word;
  background-color: #e9ecef;
}

.bill {
  padding-left: 10px;
  margin-left: 10px;
  position: relative;
  float: left;
}

/* ====================== */
/* ESTILOS PARA CONTENEDORES PRINCIPALES */
/* ====================== */
.customer-bill-box-left {
  padding: 15px;
  margin-left: 10px;
  float: left;
  position: relative;
  width: 600px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #3498db;
}

.customer-bill-box-right {
  padding: 15px;
  margin-right: 10px;
  position: relative;
  float: right;
  width: 300px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #2ecc71;
}

/* ====================== */
/* ESTILOS PARA CONTENEDORES PRINCIPALES */
/* ====================== */
.customer-bill-box-left {
  padding: 15px;
  margin-left: 10px;
  float: left;
  position: relative;
  width: 600px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #3498db;
}

.customer-bill-box-right {
  padding: 15px;
  margin-right: 10px;
  position: relative;
  float: right;
  width: 300px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #2ecc71;
}

/* ====================== */
/* ESTILOS PARA CONTENEDORES PRINCIPALES */
/* ====================== */
.customer-bill-box-left {
  padding: 15px;
  margin-left: 10px;
  float: left;
  position: relative;
  width: 600px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #3498db;
}

.customer-bill-box-right {
  padding: 15px;
  margin-right: 10px;
  position: relative;
  float: right;
  width: 300px;
  min-height: 82px;
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
  border-left: 4px solid #2ecc71;
}

/* ====================== */
/* ORGANIZACIÓN DE CAMPOS - VERSIÓN FINAL */
/* ====================== */

/* Contenedor para RTN + Cliente en misma línea */
.bill-main-fields {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 20px;
  margin-bottom: 8px;
}

/* Contenedor para Vendedor (opcional, debajo) */
.bill-secondary-fields {
  margin-bottom: 8px;
}

/* Estilos base para texto */
.customer-bill-box-left span,
.customer-bill-box-right span {
  font-size: 0.9rem;
  color: #4a5568;
  position: relative;
  padding-left: 22px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Ajuste específico para el campo Cliente */
#client-customers-bill,
#client-customers-quote {
  font-weight: 600;
  color: #2c3e50;
  display: inline-flex;
  align-items: center;
  margin: 0;
  white-space: pre;
}

/* ====================== */
/* ESTILOS DE ICONOS */
/* ====================== */

/* Iconos solo cuando hay contenido */
#rtn-customers-bill:not(:empty)::before,
#vendedor-customers-bill:not(:empty)::before,
#comentario-customers-bill:not(:empty)::before,
#fecha-customers-bill:not(:empty)::before,
#hora-customers-bill:not(:empty)::before,
#rtn-customers-quote:not(:empty)::before,
#vendedor-customers-quote:not(:empty)::before,
#comentario-customers-quote:not(:empty)::before,
#fecha-customers-quote:not(:empty)::before,
#hora-customers-quote:not(:empty)::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  color: #3498db;
  font-size: 0.9em;
}

/* Colores específicos para iconos */
#rtn-customers-bill:not(:empty)::before,
#rtn-customers-quote:not(:empty)::before {
  content: "\f2bb";
  color: #3a4f6b;
}

#vendedor-customers-bill:not(:empty)::before,
#vendedor-customers-quote:not(:empty)::before {
  content: "\f0c0";
  color: #2980b9;
}

#comentario-customers-bill:not(:empty)::before,
#comentario-customers-quote:not(:empty)::before {
  content: "\f075";
  color: #e67e22;
}

#fecha-customers-bill:not(:empty)::before,
#fecha-customers-quote:not(:empty)::before {
  content: "\f073";
  color: #27ae60;
}

#hora-customers-bill:not(:empty)::before,
#hora-customers-quote:not(:empty)::before {
  content: "\f017";
  color: #9b59b6;
}

/* Icono para Cliente (siempre visible) */
#client-customers-bill::before,
#client-customers-quote::before {
  content: "\f007";
  position: absolute;
  left: 0;
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  color: #3498db;
  font-size: 0.9em;
}

/* ====================== */
/* RESPONSIVIDAD */
/* ====================== */
@media (max-width: 768px) {
  .customer-bill-box-left,
  .customer-bill-box-right {
    width: 100%;
    float: none;
    margin: 10px 0;
  }

  .bill-main-fields {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }

  .customer-bill-box-left span,
  .customer-bill-box-right span {
    white-space: normal;
  }
}

/* ====================== */
/* REORGANIZACIÓN RESPONSIVE DE BOTONES */
/* ====================== */
@media (max-width: 992px) {
  /* Contenedores principales */
  .form-group.row > .col-xs-12.col-sm-12.col-md-12.col-lg-12,
  .col-xs-12.col-sm-12.col-md-12.col-lg-12:not(.form-group) {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  /* Botones - mantienen todos sus estilos originales */
  .btn.btn-secondary {
    flex-grow: 1;
    flex-basis: calc(50% - 4px); /* 2 columnas con gap */
  }

  /* Labels y switches - mantienen su alineación */
  .col-form-label,
  .switch,
  .question {
    flex-shrink: 0; /* Evita que se compriman */
  }
}

@media (max-width: 576px) {
  /* En móviles muy pequeños, 1 columna */
  .btn.btn-secondary {
    flex-basis: 100%;
  }
}

/* ====================== */
/* BOTÓN WHATSAPP PREMIUM */
/* ====================== */
.float-ws {
  position: fixed;
  width: 60px;
  height: 60px;
  bottom: 90px; /* Más elevado para mejor visibilidad */
  left: 20px; /* Mayor margen del borde */
  background-color: #25d366;
  color: white !important;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
  z-index: 1000; /* Mayor z-index para asegurar visibilidad */
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  animation: pulse-ws 2s infinite ease-in-out;
  border: 2px solid white; /* Borde blanco para mejor contraste */
  outline: none;
  cursor: pointer;
  overflow: hidden; /* Para el efecto de onda */
}

.float-ws:hover {
  transform: scale(1.1) translateY(-5px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
  animation: none; /* Detiene la animación al hacer hover */
}

/* Efecto de onda al hacer click */
.float-ws:active:after {
  content: "";
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.4) 0%,
    rgba(255, 255, 255, 0) 70%
  );
  border-radius: 50%;
  animation: click-wave 0.5s ease-out;
}

@keyframes pulse-ws {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 15px rgba(37, 211, 102, 0);
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
  }
}

@keyframes click-wave {
  0% {
    transform: scale(0.8);
    opacity: 1;
  }
  100% {
    transform: scale(2.5);
    opacity: 0;
  }
}

/* Efecto de notificación (opcional) */
.float-ws.notification:before {
  content: "";
  position: absolute;
  width: 12px;
  height: 12px;
  background-color: #ff3b30;
  border-radius: 50%;
  border: 2px solid white;
  top: 5px;
  right: 5px;
  animation: notification-pulse 1.5s infinite;
}

@keyframes notification-pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}

/* ====================== */
/* FOOTER PROFESIONAL */
/* ====================== */
.footer {
  position: fixed;
  left: 0;
  bottom: 0;
  width: 100%;
  background: linear-gradient(135deg, #1a2a3a 0%, #0d1620 100%);
  color: white;
  padding: 10px 0;
  z-index: 99;
  box-shadow: 0 -1px 8px rgba(0, 0, 0, 0.15);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

/* ====================== */
/* AJUSTES RESPONSIVE */
/* ====================== */
@media (max-width: 768px) {
  .float-ws {
    bottom: 65px;
    left: 20px;
    width: 52px;
    height: 52px;
    font-size: 1.6rem;
  }

  .footer {
    padding: 8px 0;
  }
}

@media (max-width: 480px) {
  .float-ws {
    bottom: 60px;
    left: 15px;
    width: 48px;
    height: 48px;
    font-size: 1.5rem;
  }

  body {
    padding-bottom: 50px;
  }
}

/* ====================== */
/* ESTILOS PARA INPUT GROUPS CON ICONOS */
/* ====================== */
.input-group-text {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 38px; /* Altura estándar de inputs Bootstrap */
  padding: 0.375rem 0.75rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #495057;
  background-color: #e9ecef;
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
}

/* Ajuste específico para iconos dentro del input-group-text */
.input-group-text i {
  font-size: 1rem;
  width: 1em;
  height: 1em;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ESTILO BASE PARA TEXTAREAS */
/* ESTILO CORREGIDO - USANDO EL ATRIBUTO ROWS DIRECTAMENTE */
textarea.form-control {
  /* Eliminamos el calc con attr() que no funciona */
  height: auto; /* Permite crecimiento natural */
  min-height: calc(1.5em * 3 + 1rem + 2px); /* Valor base para 3 filas */
  padding: 0.65rem 0.75rem;
  line-height: 1.5; /* Valor estándar legible */
  width: 100%;
  resize: vertical;
}

/* ESTILO ESPECÍFICO SEGÚN FILAS */
textarea.form-control[rows="2"] {
  min-height: calc(1.5em * 2 + 1rem + 2px);
}

textarea.form-control[rows="3"] {
  min-height: calc(1.5em * 3 + 1rem + 2px);
}

textarea.form-control[rows="4"] {
  min-height: calc(1.5em * 4 + 1rem + 2px);
}

textarea.form-control[rows="5"] {
  min-height: calc(1.5em * 5 + 1rem + 2px);
}

/* INTEGRACIÓN CON BOTONES LATERALES */
.input-group > textarea.form-control {
  flex: 1 1 auto;
  border-right: none;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.input-group-append > .btn {
  border-left: none;
  height: 100%;
  align-self: stretch;
}

/* CONTADOR DE CARACTERES */
.char-counter {
  font-size: 0.8rem;
  color: #6c757d;
  text-align: right;
  margin-top: 0.25rem;
}

/* Alinear correctamente el grupo completo */
.input-group {
  align-items: stretch;
}

/* Corrección para bordes redondeados cuando hay iconos */
.input-group > .input-group-prepend > .input-group-text {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.input-group > .input-group-append > .input-group-text {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}

.switch {
  position: relative;
  display: inline-block;
  width: 50px; /* Más estrecho */
  height: 24px; /* Más bajo */
  margin-bottom: 0; /* Elimina espacio inferior */
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px; /* Más pequeño */
  width: 16px; /* Más pequeño */
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
}

.slider.round {
  border-radius: 24px;
}

.slider.round:before {
  border-radius: 50%;
}

input:checked + .slider {
  background-color: #2196f3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

/* Estilo profesional para el enlace de íconos */
.icon-explorer-link {
  color: #2962ff !important;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  font-size: 0.875rem;
}

.icon-explorer-link:hover {
  color: #0039cb !important;
  text-decoration: underline;
}

.icon-explorer-link i {
  margin-right: 6px;
  font-size: 0.8em;
}

/* Mejora para el input group */
.input-group-text {
  min-width: 40px;
  justify-content: center;
  background-color: #f8f9fa;
}

/*******************************
 * ESTILOS PARA NOTIFICACIONES *
 *******************************/

/* Contenedor de la campana */
.nav-item.dropdown.mx-1 {
  transition: all 0.3s ease;
}

/* Ocultar campana cuando no hay notificaciones */
.nav-item.dropdown.mx-1:not(.new-notification) {
  opacity: 1;
}

/* Campana de notificaciones */
#notification-bell {
  position: relative;
  font-size: 1.25rem;
  color: #6c757d;
  padding: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  transition: all 0.3s ease;
}

#notification-bell:hover {
  background-color: rgba(0, 0, 0, 0.05);
  color: #495057;
}

/* Badge de notificación en la campana */
#notification-count {
  position: absolute;
  top: 2px;
  right: 2px;
  font-size: 0.65rem;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: #dc3545;
  color: white !important;
  font-weight: bold;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  border: 2px solid #f8f9fa;
}

/* Dropdown de notificaciones */
.notification-dropdown {
  min-width: 250px;
  border: none;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  padding: 0;
  border-radius: 0.25rem;
  overflow: hidden;
}

.notification-dropdown .dropdown-header {
  background-color: #f8f9fa;
  border-bottom: 1px solid #e9ecef;
  padding: 0.75rem 1rem;
  font-weight: 600;
  color: #495057;
  font-size: 0.9rem;
}

.notification-dropdown .dropdown-item {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid #f1f1f1;
  display: flex;
  align-items: center;
  transition: all 0.2s;
  font-size: 0.9rem;
}

.notification-dropdown .dropdown-item i {
  width: 20px;
  text-align: center;
  margin-right: 10px;
  color: #6c757d;
}

/* Badge en dropdown de notificaciones */
#notification-dropdown-count {
  font-size: 0.75rem;
  min-width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 11px;
  background: #dc3545;
  color: white !important;
  font-weight: bold;
  margin-left: auto;
  padding: 0 0.35em;
}

/*******************************
 * BADGE EN MENÚ DE USUARIO *
 *******************************/

/* Badge en dropdown de usuario */
#badge-facturas-pendientes-dropdown {
  font-size: 0.75rem;
  min-width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 11px;
  background: #dc3545;
  color: white !important;
  font-weight: bold;
  margin-left: auto;
  padding: 0 0.35em;
}

/* Animación para nueva notificación */
.new-notification {
  animation: pulse 1.5s ease infinite;
}

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

/*******************************
 * Hover general para filas *
 *******************************/

/* 1. Hover general para filas */
.table-hover tbody tr:hover {
  background-color: #f5f5f5;
}

/* 2. Excluir última columna del hover */
.table-hover tbody tr:hover td:last-child {
  background-color: transparent;
}

/* 3. Mantener colores de botones e iconos en última columna */
.table-hover tbody tr:hover td:last-child a,
.table-hover tbody tr:hover td:last-child i {
  color: inherit !important;
}

/* 4. Solución NUCLEAR para badges (fondo + texto + iconos) */
.table-hover tbody tr:hover .badge {
  background-color: var(--bg-color, initial) !important;
  color: var(--text-color, initial) !important;
}
.table-hover tbody tr:hover .badge i {
  color: var(--icon-color, inherit) !important;
}

/* 5. Definir colores específicos para cada tipo de badge */
.badge-primary {
  --bg-color: #007bff;
  --text-color: white;
  --icon-color: white;
}

.badge-info {
  --bg-color: #17a2b8;
  --text-color: white;
  --icon-color: white;
}

.badge-success {
  --bg-color: #28a745;
  --text-color: white;
  --icon-color: white;
}

.badge-warning {
  --bg-color: #ffc107;
  --text-color: #212529;
  --icon-color: #212529;
}

.badge-danger {
  --bg-color: #dc3545;
  --text-color: white;
  --icon-color: white;
}

.badge-secondary {
  --bg-color: #6c757d;
  --text-color: white;
  --icon-color: white;
}

/*******************************
 * BADGE CODIGO DE CLIENTE *
 *******************************/

#badge-codigo-cliente {
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35em 0.65em;
  border-radius: 4px;
  min-width: 3em;
  text-align: center;
  color: #fff;
  background-color: #2c7be5; /* Azul más vibrante */
  border: 1px solid #1a68d1;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
  margin-left: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Estilo hover */
.dropdown-item:hover #badge-codigo-cliente {
  background-color: #1a68d1 !important;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* Estilo para el tooltip */
#badge-codigo-cliente[title] {
  position: relative;
}

#badge-codigo-cliente[title]:hover::after {
  content: attr(title);
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background-color: #333;
  color: #fff;
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  white-space: nowrap;
  margin-bottom: 5px;
  z-index: 1000;
}

/* Para el avatar con iniciales */
.avatar-initials {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #2c7be5, #1a68d1);
  color: white;
  border-radius: 50%;
  font-weight: bold;
  margin-right: 10px;
  font-size: 0.9rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Estilos para el popover del PIN */
.pin-popover {
  border: none;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
  border-radius: 8px;
  min-width: 220px;
}

.pin-popover .popover-arrow {
  display: none;
}

.pin-popover-content {
  padding: 12px;
  text-align: center;
}

.pin-header {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  color: #495057;
  font-weight: 600;
  font-size: 0.95rem;
}

.pin-header i {
  color: #4e73df;
}

.pin-value {
  font-size: 1.8rem;
  font-weight: bold;
  letter-spacing: 3px;
  color: #2c3e50;
  background: #f8f9fa;
  padding: 8px 12px;
  border-radius: 6px;
  margin: 8px 0;
  font-family: "Courier New", monospace;
}

.pin-footer {
  margin-top: 10px;
}

.btn-regenerate-pin {
  padding: 0.25rem 0.5rem;
  font-size: 0.8rem;
  width: 100%;
}

/* Estilo para el badge del PIN */
#badge-pin-cliente {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.3em 0.6em;
  border-radius: 4px;
  background-color: #17a2b8;
  color: white;
  margin-left: 6px;
}

/* Asegurar que el elemento esté oculto por defecto */
#ver-pin-usuario.d-none {
  display: none !important;
}

/* Estilo para cuando está visible */
#ver-pin-usuario:not(.d-none) {
  display: flex !important;
}

/* Estilos generales para los campos del formulario */
/* Estos estilos mantendrán la posición original pero aplicarán negrita */
/* Campos de cotización */
.inputfield-details1, /* Código del Producto */
.product-description, /* Descripción del Producto */
.buscar_cantidad,     /* CANTIDAD (quantityQuote) */
#priceQuote_ + count,  /* PRECIO */
#discountQuote_ + count, /* DESCUENTO */
.total,               /* TOTAL */
/* Campos de factura */
.product-bar-code,     /* Código del Producto (factura) */
.product-description,  /* Descripción del Producto (factura) */
#quantity_ + count,    /* CANTIDAD (factura) */
.medida-description,   /* Medida (aunque no estaba en tu lista original) */
#price_ + count,       /* PRECIO (factura) */
#discount_ + count,    /* DESCUENTO (factura) */
/* Campos de compra */
.product-bar-codePurchase, /* Código del Producto (compra) */
#productNamePurchase_ + count, /* Nombre del Producto (compra) */
.buscar_cantidad_purchase, /* CANTIDAD (compra) */
.buscar_medida_purchase, /* Medida (compra) */
.buscar_price_purchase, /* PRECIO (compra) */
#isvPurchaseWrite_ + count, /* ISV (compra) */
#discountPurchase_ + count, /* DESCUENTO (compra) */
#totalPurchase_ + count,    /* TOTAL (compra) */
/* Campos de solo lectura también en negrita */
input[readonly] {
  font-weight: bold !important;
}

/* Ajustes específicos para los placeholders */
.inputfield-details1::placeholder,
.buscar_cantidad::placeholder,
.product-bar-code::placeholder,
.product-bar-codePurchase::placeholder,
.buscar_cantidad_purchase::placeholder {
  font-weight: bold !important;
}

/* Ajuste para los textos de descripción (producto y medida) */
.product-description,
.medida-description,
#productNamePurchase_ + count {
  font-weight: bold !important;
  display: inline-block; /* Mantiene la posición original */
  vertical-align: middle; /* Alineación vertical */
  line-height: normal; /* Altura de línea normal */
  margin-top: 0; /* Elimina cualquier margen superior */
  padding: 0; /* Elimina cualquier padding */
}

/* Asegurar que los inputs mantengan su tamaño */
.form-control {
  box-sizing: border-box !important;
}

/* Estilos para los botones de búsqueda para mantener consistencia */
.btn-link {
  font-weight: normal !important; /* Los íconos no necesitan negrita */
}

.notyf__toast--error a.alert-link {
  color: #ffeb3b !important; /* Amarillo claro */
  text-decoration: underline;
  font-weight: bold;
}

/* Contenedor principal */
.total-container {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.25rem;
}

/* Estilo para el monto total */
.total-amount {
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  background-color: #f8f9fa; /* Fondo gris claro */
  border-left: 3px solid #6c757d; /* Borde izquierdo */
  transition: all 0.2s ease;
}

/* Badge de estado */
.status-badge {
  padding: 0.35rem 0.75rem;
  border-radius: 1rem;
  font-size: 0.75rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
}

/* Resaltar el monto total */
.total-amount {
  font-size: 16px;
  font-weight: 600;
  color: #333;
}

/* Estilo para los badges de estado */
.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.3px;
  max-width: fit-content;
}

/* Iconos dentro del badge */
.status-badge i {
  margin-right: 3px;
  font-size: 10px;
}

/* =========================================================
   INICIO CUENTAS CONTABLES - DISEÑO PREMIUM
========================================================= */

/* ==============================
   CONTENEDOR GENERAL
============================== */

.cuentas-premium-page {
  background: #f8fafc;
}

/* ==============================
   CARD DE FILTROS
============================== */

.cuentas-filter-card {
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
  overflow: visible;
  position: relative;
  z-index: 5;
}

.cuentas-filter-card .card-body {
  padding: 1.25rem 1.35rem;
}

.cuentas-filter-card label {
  color: #334155;
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

/* Inputs normales */
.cuentas-filter-card input.form-control {
  min-height: 44px;
  background: #ffffff !important;
  color: #334155 !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  font-weight: 600;
}

.cuentas-filter-card input.form-control:focus {
  border-color: #0d6efd !important;
  box-shadow: 0 0 0 0.18rem rgba(13, 110, 253, 0.12) !important;
}

/* Selectpicker sin doble borde */
.cuentas-filter-card .bootstrap-select.form-control {
  width: 100% !important;
  height: auto !important;
  min-height: 44px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}

.cuentas-filter-card .bootstrap-select > .dropdown-toggle {
  width: 100% !important;
  min-height: 44px !important;
  height: 44px !important;
  padding: 0.55rem 0.95rem !important;
  background: #ffffff !important;
  color: #334155 !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  font-weight: 600 !important;
  outline: none !important;
}

.cuentas-filter-card .bootstrap-select > .dropdown-toggle:hover,
.cuentas-filter-card .bootstrap-select > .dropdown-toggle:focus,
.cuentas-filter-card .bootstrap-select.show > .dropdown-toggle {
  background: #ffffff !important;
  color: #0f172a !important;
  border-color: #0d6efd !important;
  box-shadow: 0 0 0 0.18rem rgba(13, 110, 253, 0.12) !important;
  outline: none !important;
}

.cuentas-filter-card .bootstrap-select .filter-option {
  display: flex;
  align-items: center;
}

.cuentas-filter-card .bootstrap-select .filter-option-inner-inner {
  color: #334155 !important;
  font-weight: 600;
}

.cuentas-filter-card .bootstrap-select .dropdown-menu {
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 14px;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.16);
  overflow: hidden;
  padding: 0.35rem;
  z-index: 1060;
}

.cuentas-filter-card .bootstrap-select .dropdown-item {
  border-radius: 10px;
  color: #334155;
  font-weight: 700;
  padding: 0.55rem 0.75rem;
}

.cuentas-filter-card .bootstrap-select .dropdown-item:hover,
.cuentas-filter-card .bootstrap-select .dropdown-item:focus,
.cuentas-filter-card .bootstrap-select .dropdown-item.active {
  background: #eff6ff;
  color: #0d6efd;
}

/* Fechas con input-group */
.cuentas-filter-card .input-group {
  align-items: stretch !important;
}

.cuentas-filter-card .input-group-prepend {
  margin-right: 0 !important;
}

.cuentas-filter-card .input-group-text {
  min-height: 44px;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #dbe3ef;
  border-right: 0;
  border-radius: 12px 0 0 12px;
}

.cuentas-filter-card .input-group .form-control {
  border-radius: 0 12px 12px 0 !important;
}

.cuentas-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.6rem;
  flex-wrap: wrap;
}

/* ==============================
   CARD RESUMEN
============================== */

.cuentas-summary-card {
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
  overflow: visible;
  position: relative;
  z-index: 1;
}

.cuentas-summary-card .card-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  padding: 1rem 1.2rem;
  border-radius: 18px 18px 0 0;
  position: relative;
  z-index: 2;
}

.cuentas-summary-title {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: #0f172a;
  font-weight: 900;
  margin: 0;
}

.cuentas-summary-title i {
  color: #0d6efd;
}

.cuentas-summary-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.cuentas-summary-card .card-body {
  background: #f8fafc;
  padding: 1rem 1.2rem;
  overflow: visible;
  position: relative;
  z-index: 1;
}

.cuentas-summary-card .card-footer {
  background: #ffffff;
  border-top: 1px solid rgba(148, 163, 184, 0.22);
  color: #64748b;
  font-weight: 700;
  border-radius: 0 0 18px 18px;
}

/* ==============================
   CONTENEDOR DE CARDS
============================== */

#cuentas-container {
  overflow: visible;
  position: relative;
}

#cuentas-container > [class*="col-"] {
  overflow: visible;
  position: relative;
}

/* ==============================
   CARD DE CUENTAS
============================== */

.card-account {
  background: #ffffff !important;
  border: 1px solid rgba(148, 163, 184, 0.2) !important;
  border-radius: 20px !important;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06) !important;
  overflow: visible !important;
  position: relative !important;
  z-index: 1;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    border-color 0.18s ease !important;
}

/* Línea lateral curvada, continua y profesional */
.card-account::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 5px;
  background: #0d6efd;
  border-radius: 20px 0 0 20px;
  z-index: 20;
  pointer-events: none;
  transition: background-color 0.18s ease;
}

.card-account.positive-balance::before {
  background: #16a34a;
}

.card-account.negative-balance::before {
  background: #dc2626;
}

.card-account.account-investment::before {
  background: #7c3aed;
}

.card-account:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 38px rgba(15, 23, 42, 0.1) !important;
  border-color: rgba(13, 110, 253, 0.22) !important;
  color: inherit;
  z-index: 50;
}

.card-account:has(.acciones-menu.show),
.card-account:has(.dropdown-menu.show) {
  z-index: 9999 !important;
}

/* ==============================
   HEADER DE CARD CUENTA
============================== */

.cuenta-card-header {
  padding: 1rem 1.05rem 0.85rem 1.35rem;
  background: linear-gradient(180deg, #ffffff 0%, #fbfdff 100%);
  border-bottom: 1px solid #e8edf5;
  border-radius: 20px 20px 0 0;
  position: relative;
  z-index: 2;
  overflow: hidden;
}

.cuenta-card-title-wrap {
  min-width: 0;
  padding-right: 0.75rem;
}

.cuenta-card-title {
  color: #0f172a;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.2;
  letter-spacing: 0.02em;
  margin: 0;
  text-transform: uppercase;
}

.cuenta-card-code {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.35rem;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 800;
}

.cuenta-card-code i {
  color: #94a3b8;
}

/* ==============================
   BADGES DE CUENTA
============================== */

.cuenta-badges-wrap {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.badge-cuenta-activa,
.badge-cuenta-inactiva,
.badge-cuenta-inversion,
.badge-cuenta-normal {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.35rem 0.7rem;
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid transparent;
}

.badge-cuenta-activa {
  background: #dcfce7;
  color: #15803d;
  border-color: #bbf7d0;
}

.badge-cuenta-inactiva {
  background: #fee2e2;
  color: #dc2626;
  border-color: #fecaca;
}

.badge-cuenta-inversion {
  background: #ede9fe;
  color: #7c3aed;
  border-color: #ddd6fe;
}

.badge-cuenta-normal {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

/* ==============================
   BODY DE CARD CUENTA
============================== */

.cuenta-card-body {
  padding: 1rem 1.15rem 1rem 1.35rem;
  position: relative;
  z-index: 2;
  background: #ffffff;
}

.cuenta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.38rem 0;
}

.cuenta-row-label {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: #334155;
  font-weight: 850;
  font-size: 0.88rem;
}

.cuenta-row-label i {
  width: 17px;
  color: #64748b;
  text-align: center;
}

.cuenta-row-value {
  color: #334155;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.cuenta-divider {
  border-top: 1px dashed #cbd5e1;
  margin: 0.65rem 0;
}

/* ==============================
   TOTAL DE CARD CUENTA
============================== */

.cuenta-total-box {
  margin-top: 0.85rem;
  border-radius: 16px;
  padding: 0.9rem 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.cuenta-total-label {
  color: #475569;
  font-weight: 900;
  font-size: 0.83rem;
}

.cuenta-total-value {
  font-size: 1.08rem;
  font-weight: 950;
  font-variant-numeric: tabular-nums;
}

/* ==============================
   FOOTER DE CARD CUENTA
============================== */

.cuenta-card-footer {
  padding: 0.9rem 1.05rem 0.9rem 1.35rem;
  background: #ffffff;
  border-top: 1px solid #e8edf5;
  border-radius: 0 0 20px 20px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  position: relative;
  z-index: 2;
  overflow: visible;
}

/* ==============================
   DROPDOWN ACCIONES EN CARDS
============================== */

.cuenta-card-footer .acciones-dropdown,
.card-account .acciones-dropdown {
  position: relative;
  z-index: 10000;
}

.cuenta-card-footer .acciones-menu,
.card-account .acciones-menu,
.cuenta-card-footer .dropdown-menu,
.card-account .dropdown-menu {
  z-index: 10001 !important;
}

.cuenta-card-footer .acciones-menu.show,
.card-account .acciones-menu.show,
.cuenta-card-footer .dropdown-menu.show,
.card-account .dropdown-menu.show {
  display: block !important;
  position: absolute !important;
  z-index: 10001 !important;
}

/* ==============================
   MODAL CUENTAS PREMIUM
============================== */

#modalCuentascontables .modal-content {
  border: 0;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.32);
}

#modalCuentascontables .modal-header {
  background: linear-gradient(135deg, #111827 0%, #1e293b 100%) !important;
  border-bottom: 4px solid #0d6efd;
}

#modalCuentascontables .modal-title {
  color: #ffffff;
  font-weight: 900;
}

#modalCuentascontables .card {
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
}

#modalCuentascontables .card-header {
  background: #ffffff !important;
  color: #0f172a !important;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
  font-weight: 900;
  padding: 1rem 1.15rem;
}

#modalCuentascontables .card-header h5 {
  color: #0f172a;
  font-weight: 900;
}

#modalCuentascontables .card-header i {
  color: #0d6efd;
}

#modalCuentascontables label {
  color: #334155;
  font-weight: 850;
}

#modalCuentascontables .form-control {
  min-height: 44px;
  border: 1px solid #dbe3ef;
  border-radius: 12px;
  box-shadow: none;
}

#modalCuentascontables .form-control:focus {
  border-color: #0d6efd;
  box-shadow: 0 0 0 0.18rem rgba(13, 110, 253, 0.12);
}

#modalCuentascontables .modal-footer {
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
}

/* ==============================
   SWITCH INVERSIÓN CUENTAS
============================== */

.cuenta-invest-box {
  border: 1px solid rgba(124, 58, 237, 0.18);
  background: rgba(124, 58, 237, 0.06);
  border-radius: 16px;
  padding: 0.95rem 1rem;
}

.cuenta-invest-title {
  color: #5b21b6;
  font-weight: 900;
  margin-bottom: 0.2rem;
}

.cuenta-invest-help {
  color: #64748b;
  font-size: 0.82rem;
  margin-bottom: 0;
}

#modalCuentascontables .categoria-switch {
  position: relative;
  display: inline-block;
  width: 58px;
  height: 32px;
  flex: 0 0 auto;
}

#modalCuentascontables .categoria-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

#modalCuentascontables .categoria-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #cbd5e1;
  transition: 0.25s;
  border-radius: 999px;
  box-shadow: inset 0 1px 3px rgba(15, 23, 42, 0.2);
}

#modalCuentascontables .categoria-slider::before {
  content: "";
  position: absolute;
  width: 26px;
  height: 26px;
  left: 3px;
  top: 3px;
  background: #ffffff;
  transition: 0.25s;
  border-radius: 50%;
  box-shadow: 0 3px 8px rgba(15, 23, 42, 0.25);
}

#modalCuentascontables .categoria-switch input:checked + .categoria-slider {
  background: #7c3aed;
}

#modalCuentascontables
  .categoria-switch
  input:checked
  + .categoria-slider::before {
  transform: translateX(26px);
}

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

@media (max-width: 992px) {
  .cuentas-toolbar {
    justify-content: flex-start;
  }

  .cuentas-summary-card .card-header {
    align-items: flex-start !important;
    flex-direction: column;
    gap: 0.75rem;
  }

  .cuentas-summary-actions {
    width: 100%;
    justify-content: flex-start;
  }
}

@media (max-width: 768px) {
  .cuentas-filter-card .card-body,
  .cuentas-summary-card .card-body {
    padding: 1rem;
  }

  .cuenta-card-header .d-flex {
    align-items: flex-start !important;
    flex-direction: column;
    gap: 0.65rem;
  }

  .cuenta-badges-wrap {
    justify-content: flex-start;
  }

  .cuenta-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.2rem;
  }

  .cuenta-row-value {
    width: 100%;
    text-align: left;
  }

  .cuenta-total-box {
    align-items: flex-start !important;
    flex-direction: column;
    gap: 0.35rem;
  }

  .cuenta-card-footer {
    justify-content: flex-start;
  }

  .cuenta-invest-box {
    align-items: flex-start !important;
    flex-direction: column;
    gap: 0.85rem;
  }
}

/* =========================================================
   FIN CUENTAS CONTABLES - DISEÑO PREMIUM
========================================================= */

.notation {
  font-size: 0.8rem;
  color: var(--gray-500);
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px dashed var(--gray-200);
  /* Iconos en notaciones */
  & .icon {
    margin-right: 0.3rem;
  }
}

/* Estilo para el texto de copyright */
.col-11.text-left small:first-child {
  font-size: 0.85em;
  color: #edeff1;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* Estilo para el texto de versión */
.col-11.text-left small:last-child {
  font-size: 0.85em;
  color: #edeff1;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* Estilo para los iconos */
.col-11.text-left small i {
  font-size: 0.9em;
  opacity: 0.8;
}

/* Estilos para los controles reorganizados */
.d-flex.flex-wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.mb-2 {
  margin-bottom: 0.5rem;
}

.mr-2 {
  margin-right: 0.5rem;
}

.mr-3 {
  margin-right: 1rem;
}

.ml-1 {
  margin-left: 0.25rem;
}

.mb-0 {
  margin-bottom: 0;
}

/* Estilo para el botón de exoneración */
.btn-outline-info {
  color: #17a2b8;
  border-color: #17a2b8;
  background-color: transparent;
  transition: all 0.3s ease;
}

.btn-outline-info:hover {
  color: white;
  background-color: #17a2b8;
  border-color: #17a2b8;
}

/* Asegurar que el modal esté centrado */
.modal-dialog-centered {
  display: flex;
  align-items: center;
  min-height: calc(100% - 1rem);
}

/* Estilos para los switches */
.switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: 0.4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.4s;
}

input:checked + .slider {
  background-color: #2196f3;
}

input:focus + .slider {
  box-shadow: 0 0 1px #2196f3;
}

input:checked + .slider:before {
  transform: translateX(26px);
}

.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

/* Estilo para las etiquetas de los controles */
.col-form-label {
  padding-top: calc(0.375rem + 1px);
  padding-bottom: calc(0.375rem + 1px);
  margin-bottom: 0;
  font-size: inherit;
  line-height: 1.5;
}

/* Estilo que combina con tu diseño actual */
.breadcrumb-harmony {
  background: #f8fafc; /* Fondo similar al de tu sidebar */
  padding: 8px 15px;
  border-radius: 4px;
  font-size: 14px;
  display: flex;
  align-items: center;
  list-style: none;
  margin: 15px 0 20px 0;
  border-left: 3px solid #3b82f6; /* Azul similar al de tu interfaz */
  color: #334155; /* Color de texto oscuro pero no negro */
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05); /* Sombra muy sutil */
}

.breadcrumb-harmony .breadcrumb-item {
  display: flex;
  align-items: center;
}

.breadcrumb-harmony .breadcrumb-link {
  color: #475569; /* Gris azulado similar a tu diseño */
  text-decoration: none;
  font-weight: 500; /* Peso medio como en tu interfaz */
  transition: all 0.2s;
  display: flex;
  align-items: center;
}

.breadcrumb-harmony .breadcrumb-link:hover {
  color: #2563eb; /* Azul más intenso al hover */
}

.breadcrumb-harmony .breadcrumb-item.active {
  color: #1e40af; /* Azul oscuro para el ítem activo */
  font-weight: 600; /* Un poco más grueso que el normal */
}

.breadcrumb-harmony .breadcrumb-icon {
  margin-right: 8px;
  font-size: 13px;
  color: #64748b; /* Gris para los iconos */
}

.breadcrumb-harmony .breadcrumb-separator {
  margin: 0 8px;
  color: #94a3b8; /* Gris claro para el separador */
  font-weight: normal;
}

/* =========================
   📂 ESTILOS PARA SUBIDA DE ARCHIVOS PDF
   ========================= */
.file-upload-container {
  margin-bottom: 15px;
}

.file-upload-area {
  border: 2px dashed #ccc;
  border-radius: 5px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s;
  background-color: #f9f9f9;
  position: relative;
  overflow: hidden;
  cursor: default;
  outline: none;
}

.file-upload-area:hover {
  border-color: #007bff;
  background-color: #f0f7ff;
}

.file-upload-area i {
  color: #dc3545; /* Rojo para iconos de PDF */
}

.file-upload-area p {
  margin: 10px 0 0;
  color: #666;
}

.file-info {
  margin-top: 10px;
  font-size: 14px;
  color: #666;
  word-break: break-all;
}

.file-upload-area.drag-over {
  border-color: #28a745;
  background-color: #e8f5e9;
}

.file-upload-area:focus {
  border: 2px dashed #28a745;
}

/* Botón para seleccionar archivo */
.select-file-container {
  display: inline-block;
  position: relative;
}

.select-file-text {
  color: #007bff;
  cursor: pointer;
  text-decoration: underline;
  position: relative;
  z-index: 1;
}

.select-file-text:hover {
  color: #0056b3;
}

.file-upload-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  overflow: hidden;
}

/* Vista previa PDF */
.pdf-preview {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8f9fa;
  padding: 8px 10px;
  border-radius: 4px;
  margin-top: 10px;
}

.pdf-preview a {
  color: #dc3545;
  text-decoration: none;
  word-break: break-all;
  flex: 1;
  margin-left: 8px;
}

.pdf-preview a:hover {
  text-decoration: underline;
}

/* Botón eliminar PDF */
.btn-remove-pdf {
  background: transparent;
  border: none;
  color: #e74c3c;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 5px;
}

.btn-remove-pdf:hover {
  color: #c0392b;
}

/* Archivo existente */
.existing-file {
  margin-top: 10px;
  padding: 10px;
  background: #f0f8ff;
  border-radius: 4px;
  border-left: 3px solid #007bff;
}

/* Vista previa genérica */
.file-preview {
  margin-top: 15px;
  display: none;
  text-align: center;
}

/* =========================
   📷 SUBIDA DE IMÁGENES (PRODUCTO)
   ========================= */
.file-upload-container {
  margin-bottom: 15px;
}

.file-upload-area {
  border: 2px dashed #ccc;
  border-radius: 5px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s;
  background-color: #f9f9f9;
  position: relative;
  overflow: hidden;
  cursor: default;
  outline: none;
}

.file-upload-area:hover {
  border-color: #007bff;
  background-color: #f0f7ff;
}

.image-upload-area i {
  color: #007bff; /* Azul para icono de imagen */
}

.file-upload-area p {
  margin: 10px 0 0;
  color: #666;
}

.file-info {
  margin-top: 10px;
  font-size: 14px;
  color: #666;
  word-break: break-all;
}

/* Estados de arrastre/hover/focus */
.file-upload-area.drag-over {
  border-color: #28a745;
  background-color: #e8f5e9;
}
.file-upload-area:focus {
  border: 2px dashed #28a745;
}

/* Texto/trigger para seleccionar */
.select-file-container {
  display: inline-block;
  position: relative;
}
.select-file-text {
  color: #007bff;
  cursor: pointer;
  text-decoration: underline;
  position: relative;
  z-index: 1;
}
.select-file-text:hover {
  color: #0056b3;
}

/* Oculta el input nativo */
.file-upload-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  overflow: hidden;
}

/* Vista previa de imagen */
.file-preview {
  margin-top: 15px;
  display: none; /* se muestra cuando hay imagen */
  text-align: center;
  position: relative;
}

.file-preview img {
  max-width: 100%;
  max-height: 220px;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
}

/* Botón eliminar (ícono de basura) */
.btn-remove-image {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(220, 53, 69, 0.95);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px; /* tamaño del ícono */
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.18);
  opacity: 0.95;
  transition:
    transform 0.15s ease,
    opacity 0.15s ease;
}

.btn-remove-image:hover {
  opacity: 1;
  transform: scale(1.05);
}

/* Mostrar el botón solo al pasar el mouse (opcional: comenta si quieres que siempre se vea) */
.file-preview .btn-remove-image {
  opacity: 0;
}
.file-preview:hover .btn-remove-image {
  opacity: 0.95;
}

/* Resaltado genérico compartido */
.highlight {
  background-color: #f8f9fa;
  border: 2px dashed #007bff;
}

/* =========================
   🎨 ESTILOS COMPARTIDOS
   ========================= */
.highlight {
  background-color: #f8f9fa;
  border: 2px dashed #007bff;
}

/* ===== Cuerpo del visor (oscuro para la imagen) ===== */
.image-viewer-modal .modal-body {
  background: #000;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.image-viewer-modal .iv-img {
  width: 100%;
  height: 80vh;
  object-fit: contain;
  background: #000;
}

/* ===== Header oscuro (con close blanco) ===== */
.image-viewer-modal .modal-header {
  background: #111 !important;
  color: #fff !important;
  border: 0 !important;
}
.image-viewer-modal .close {
  color: #fff;
  opacity: 0.85;
  text-shadow: none;
}
.image-viewer-modal .close:hover,
.image-viewer-modal .close:focus {
  color: #fff;
  opacity: 1;
}

/* ===== Footer CLARO ===== */
.image-viewer-modal .modal-footer {
  background: #fff !important; /* <- claro */
  color: #212529 !important; /* texto oscuro */
  border-top: 1px solid rgba(0, 0, 0, 0.1) !important;
}

/* Botones del footer sobre fondo claro */
.image-viewer-modal .modal-footer .btn-outline-light {
  /* en fondo claro, el outline-light casi no se ve; lo reasignamos a gris */
  color: #495057 !important;
  border-color: #ced4da !important;
  background: transparent !important;
}
.image-viewer-modal .modal-footer .btn-outline-light:hover,
.image-viewer-modal .modal-footer .btn-outline-light:focus,
.image-viewer-modal .modal-footer .btn-outline-light:active,
.image-viewer-modal .modal-footer .btn-outline-light.active {
  background: #e9ecef !important;
  color: #212529 !important;
  border-color: #ced4da !important;
  box-shadow: none !important;
}

/* Botón outline-success sigue funcionando bien en claro */
.image-viewer-modal .modal-footer .btn-outline-success {
  color: #28a745;
  border-color: #28a745;
}
.image-viewer-modal .modal-footer .btn-outline-success:hover,
.image-viewer-modal .modal-footer .btn-outline-success:focus,
.image-viewer-modal .modal-footer .btn-outline-success:active,
.image-viewer-modal .modal-footer .btn-outline-success.active {
  background: #28a745;
  color: #fff;
  border-color: #28a745;
  box-shadow: none;
}

/* Quitar halos de foco */
.image-viewer-modal .btn:focus,
.image-viewer-modal .close:focus {
  box-shadow: none;
  outline: none;
}

/* ===== Miniaturas globales para tablas (opcional, reutilizable) ===== */
.table-image {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.12);
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}
.table-image:hover {
  transform: scale(1.03);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.18);
  cursor: zoom-in;
}

/* Botón “ver imagen” junto a la miniatura */
.btn-view-image {
  padding: 0.2rem 0.4rem;
  line-height: 1;
  border-radius: 6px;
}
.btn-view-image i {
  font-size: 0.9rem;
}

/* Link SIEMPRE azul */
#filePreview .existing-file a.no-link-hover,
#filePreview .existing-file a.no-link-hover:visited {
  color: var(--link-blue) !important;
  text-decoration: underline;
  background: transparent !important;
}
#filePreview .existing-file a.no-link-hover:hover,
#filePreview .existing-file a.no-link-hover:focus {
  color: var(--link-blue-hover) !important;
  outline: none;
  box-shadow: none;
  background: transparent !important;
}

/* Evita que el hover del contenedor cambie colores */
#filePreview .existing-file,
#filePreview .existing-file:hover {
  color: inherit !important;
}

/* --- BOTÓN Cambiar archivo (outline-danger) --- */
/* Haz que el ícono herede el color del texto del botón */
#filePreview .existing-file .btn-outline-danger i {
  color: inherit !important; /* <- CLAVE: hereda rojo/ blanco */
  transition: color 0.15s ease-in-out;
}

/* Estados hover/focus del botón: fondo rojo, texto blanco */
#filePreview .existing-file .btn-outline-danger:hover,
#filePreview .existing-file .btn-outline-danger:focus {
  color: #fff !important;
  background-color: var(--danger) !important;
  border-color: var(--danger) !important;
}

/* Asegura que el ícono también se vuelva blanco */
#filePreview .existing-file .btn-outline-danger:hover i,
#filePreview .existing-file .btn-outline-danger:focus i {
  color: #fff !important;
}

/* Anillo de enfoque accesible (rojo suave) en lugar de blanco */
#filePreview .existing-file .btn-outline-danger:focus,
#filePreview .existing-file .btn-outline-danger:active {
  box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.25) !important;
}

/* (Opcional) El ícono PDF al lado del link en rojo */
#filePreview .existing-file > i.fa-file-pdf {
  color: var(--danger);
}

/* ====== Estilo general del modal de ayuda ====== */
.help-modal {
  border: 0;
  border-radius: 0.9rem;
  overflow: hidden;
}

/* ====== Header ====== */
.help-header {
  background: #0d2742; /* tu azul oscuro */
  color: #fff;
  border-bottom: none;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Bloque izquierdo (icono + textos) con uso de ancho */
.help-header > .d-flex:first-child {
  flex: 1 1 auto;
  min-width: 0;
}

.help-badge {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  margin-right: 0.75rem;
  flex: 0 0 auto;
}
.help-badge i {
  font-size: 1.1rem;
  color: #fff;
}

.help-title {
  margin: 0;
  font-weight: 700;
  line-height: 1.1;
  font-size: 1.35rem;
  white-space: nowrap; /* una sola línea */
  overflow: hidden;
  text-overflow: ellipsis;
}
.text-white-75 {
  color: rgba(255, 255, 255, 0.8) !important;
}

/* Acciones de la derecha (botones + cerrar) */
.help-header .d-flex:last-child {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-left: 1rem;
}
/* Fallback para navegadores sin gap */
.help-header .d-flex:last-child > * + * {
  margin-left: 0.6rem;
}

/* ———— FIX específico para btn-group de Bootstrap ———— */
/* Evita que Bootstrap pegue los botones y quite el borde redondeado */
.help-header .btn-group {
  display: flex;
  align-items: center;
}
.help-header .btn-group > .btn {
  border-radius: 0.6rem !important; /* restaura el radio en todos */
}
.help-header .btn-group > .btn + .btn {
  margin-left: 0.6rem !important; /* cancela el -1px de Bootstrap */
  border-left-width: 1px; /* asegura borde limpio */
}
/* ———————————————————————————————————————————————— */

.help-header .btn.btn-light {
  background: #fff;
  color: #212529;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 0.38rem 0.7rem;
  border-radius: 0.6rem;
  font-weight: 500;
}
.help-header .btn.btn-light:hover,
.help-header .btn.btn-light:focus {
  background: #f8f9fa;
  color: #212529; /* texto legible en hover */
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: none;
}
.help-header .btn.btn-light:active {
  background: #eef1f5;
  color: #212529;
  border-color: rgba(255, 255, 255, 0.35);
}
.help-header .btn i {
  margin-right: 0.35rem;
}

.help-header .close {
  margin-left: 0.4rem; /* separa de “Imprimir” */
  color: #fff;
  opacity: 0.85;
  text-shadow: none;
  line-height: 1;
}
.help-header .close:hover {
  opacity: 1;
}

/* ====== Callout ====== */
.callout {
  border-radius: 0.6rem;
  padding: 0.8rem 1rem;
  background: #f6fbff;
  border-left: 4px solid #2ea3f2;
}
.callout i {
  color: #2ea3f2;
}

/* ====== Buscador ====== */
.help-search-icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  pointer-events: none;
  opacity: 0.7;
}

/* ====== Tabla ====== */
.table-shortcuts thead th {
  text-transform: uppercase;
  font-size: 0.75rem;
  color: #6c757d;
  border-top: 0;
  border-bottom: 1px solid #e9ecef;
}
.table-shortcuts tbody td {
  vertical-align: middle;
}
.table-shortcuts kbd {
  background: #111;
  color: #fff;
  border-radius: 0.35rem;
  padding: 0.18rem 0.45rem;
  font-size: 0.85rem;
}

/* ====== Tarjetas laterales ====== */
.card.shadow-sm {
  border: 0;
  box-shadow:
    0 6px 18px rgba(9, 30, 66, 0.06),
    0 2px 4px rgba(9, 30, 66, 0.04);
  border-radius: 0.6rem;
}

/* ====== Footer ====== */
.help-modal .modal-footer {
  border-top: 1px solid #eef1f5;
}

/* ====== Responsivo ====== */
@media (max-width: 992px) {
  .help-title {
    font-size: 1.15rem;
  }
  .text-white-75 {
    display: none;
  }
}

/* ==================== */
/* MENÚ USUARIO EN MÓVILES + ARREGLOS FINALES */
/* ==================== */

/* Mantén el dropdown por debajo del modal si por alguna razón quedara abierto */
.user-dropdown {
  z-index: 1045;
}

/* Mobile */
@media (max-width: 768px) {
  .user-dropdown {
    position: fixed !important;
    top: 60px !important;
    right: 8px;
    left: auto;
    width: 280px;
    max-width: 90vw;
    transform: none !important;
    margin-top: 0;
    max-height: 80vh;
    overflow-y: auto;
  }
  .user-dropdown .dropdown-item {
    font-size: 0.9rem;
    padding: 0.75rem 1.25rem;
    white-space: normal;
    line-height: 1.4;
  }
  .user-dropdown .dropdown-item i {
    font-size: 0.95rem;
    min-width: 20px;
    margin-right: 0.75rem;
  }
  .user-dropdown .badge {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    margin-left: auto;
  }
}

/* Muy pequeñas */
@media (max-width: 480px) {
  .user-dropdown {
    width: 250px;
    right: 4px;
  }
  .user-dropdown .dropdown-item {
    font-size: 0.85rem;
    padding: 0.65rem 1rem;
  }
}

/* Nombre de usuario más pequeño y con elipsis en móviles */
@media (max-width: 576px) {
  #user_session {
    max-width: 110px;
    font-size: 0.85rem; /* más pequeño */
    font-weight: 600;
    letter-spacing: 0.2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: inline-block;
    vertical-align: middle;
  }
  .nav-link#userDropdown {
    padding: 0.5rem;
  }
  .nav-link#userDropdown i {
    margin-right: 0.25rem;
    font-size: 1.1rem;
  }
}

/* Si hay un modal abierto, esconde el dropdown sí o sí */
body.modal-open .user-dropdown {
  display: none !important;
}

/* ===== Bootstrap 4.6 – Forzar menú móvil en tablet landscape (992–1399px) ===== */

/* Z-index modal vs topbar (opcional, deja igual si ya lo tienes) */
.modal {
  z-index: 2000 !important;
}
.modal-backdrop {
  z-index: 1990 !important;
}
.modal .popover,
.modal .tooltip {
  z-index: 2010 !important;
}
body.modal-open .sb-topnav {
  z-index: 1000 !important;
  pointer-events: none;
}

/* Estilo botón (si no lo tienes) */
#mobile-mainmenu-btn {
  background: var(--topnav-hover-bg, #f2f3f5);
  color: var(--topnav-text, #333);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 12px;
  padding: 0.5rem 0.9rem;
  font-weight: 600;
}

/* Core layout */
.sb-topnav {
  display: flex;
  align-items: center;
}
.mobile-mainmenu-wrapper {
  margin: 0 auto;
}

/* >>> OVERRIDE CLAVE PARA BS 4.6 <<< */
@media (min-width: 992px) and (max-width: 1399.98px) {
  /* 1) Anular d-lg-none del wrapper: mostrar botón en tablet landscape */
  .mobile-mainmenu-wrapper {
    display: flex !important;
  }

  /* 2) Mostrar el botón explícitamente */
  #mobile-mainmenu-btn {
    display: inline-flex !important;
    align-items: center;
    gap: 0.5rem;
  }

  /* 3) Ocultar el menú desktop (d-none d-lg-flex) para liberar espacio */
  .sb-topnav > ul.navbar-nav.d-none.d-lg-flex {
    display: none !important;
  }

  /* 4) Asegurar que el menú de usuario quede a la derecha */
  .navbar-nav-user {
    margin-left: auto !important;
  }
}

/* Desde 1400px vuelve el layout de escritorio */
@media (min-width: 1400px) {
  .mobile-mainmenu-wrapper {
    display: none !important;
  }
  #mobile-mainmenu-btn {
    display: none !important;
  }
}

/* Dropdown móvil: ancho cómodo */
#mobile-mainmenu {
  min-width: 260px;
}
#mobile-mainmenu .dropdown-item i {
  width: 1.25rem;
  text-align: center;
  margin-right: 0.5rem;
}

/* ============================
   Animación y estilos base
   ============================ */

/* Pulso del input cuando se carga una fecha recordada */
@keyframes rememberPulse {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.8);
  }
  100% {
    box-shadow: 0 0 0 8px rgba(255, 193, 7, 0);
  }
}
.remembered-highlight {
  animation: rememberPulse 1s ease-out 2;
  border-color: #ffc107 !important; /* amarillo */
}

/* Tarjeta "Usando última fecha" */
.remember-hint {
  position: relative;
  background: #fff !important;
  border: 1px solid #ffe69c;
  border-left: 6px solid #ffc107;
  border-radius: 0.5rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  font-size: 0.88rem;
}
.remember-hint .fa-exclamation-triangle {
  color: #d39e00;
}
.remember-hint .remember-date {
  font-weight: 600;
}

/* Botón "Usar hoy" */
.remember-hint .btn-use-today {
  background-color: #007bff;
  border-color: #007bff;
  color: #fff !important;
  border-radius: 999px;
  padding: 0.25rem 0.6rem;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}
.remember-hint .btn-use-today i {
  margin-right: 0.35rem;
}
.remember-hint .btn-use-today:hover {
  filter: brightness(0.95);
}

/* Botón de cerrar "x" */
.remember-hint .btn-hide-hint {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid #d9d9d9;
  background: #f8f9fa;
  color: #6c757d;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 1;
  margin-left: 0.5rem;
}
.remember-hint .btn-hide-hint:hover {
  background: #e9ecef;
  color: #343a40;
}

/* =========================================
     REGLAS GENERALES PARA MODO EDICIÓN
     (aplica a cualquier formulario)
     ========================================= */

/* Oculta el recuadro "Usando última fecha" cuando el form está editando */
form.modo-editar .remember-hint {
  display: none !important;
}

/* Anula el pulso/estilo de "fecha recordada" en edición */
form.modo-editar [data-remember].remembered-highlight,
form.modo-editar input[type="date"].remembered-highlight {
  animation: none !important;
  box-shadow: none !important;
  border-color: #ced4da !important; /* borde normal Bootstrap */
}

/* ============ Upload reutilizable ============ */

/* Resalta cualquier zona con clase .file-upload-area cuando hay drag */
.file-upload-area.drag-over {
  border-color: #0d6efd;
  background: #eef5ff;
}

/* Botón de seleccionar archivo reutilizable */
.btn-file-chooser {
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(13, 110, 253, 0.2);
}

/* Íconos SIEMPRE blancos dentro del botón, sin importar hover/focus */
.file-upload-area .btn-file-chooser .fa,
.file-upload-area .btn-file-chooser .fas,
.file-upload-area .btn-file-chooser .far {
  color: #fff !important;
}
.file-upload-area .btn-file-chooser:hover .fa,
.file-upload-area .btn-file-chooser:focus .fa,
.file-upload-area .btn-file-chooser:active .fa {
  color: #fff !important;
}

/* Si tienes una regla global tipo ".file-upload-area i { color:... }"
     esto evita que afecte al ícono DENTRO del botón */
.file-upload-area .btn .fa,
.file-upload-area .btn .fas,
.file-upload-area .btn .far {
  color: #fff !important;
}

/*INICIO ESTILO FACTURA PROFORMA*/
.proforma-ui-box {
  background: #f8fbff;
  border: 1px solid #d9e8ff;
  border-left: 4px solid #17a2b8;
  border-radius: 10px;
  padding: 8px 12px;
  min-height: 45px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
}

.proforma-ui-box .badge {
  font-size: 0.85rem;
  border: 1px solid #d6e6f7;
  color: #284563;
}

.proforma-inventario-box {
  background: #fff;
  border-radius: 8px;
  padding: 5px 10px;
  border: 1px dashed #b9d8f5;
}

#tipo-factura-control.proforma-activa button {
  opacity: 0.55;
  cursor: not-allowed;
}

#tipo-factura-control.proforma-activa::after {
  content: "Proforma activa";
  display: inline-block;
  margin-left: 8px;
  padding: 6px 10px;
  border-radius: 20px;
  background: #17a2b8;
  color: #fff;
  font-weight: 600;
  font-size: 0.8rem;
}
/*FIN ESTILO FACTURA PROFORMA*/

/*INICIO ESTILO PREVIEW CAMBIO DE PRECIO*/
.precio-preview-box {
  background: #f1f4f8;
  border: 1px solid #d9dee7;
  border-radius: 8px;
  padding: 10px 12px;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px 12px;
}

.precio-preview-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
  color: #3d4652;
}

.precio-preview-item span {
  font-weight: 600;
}

.precio-preview-item strong {
  font-weight: 700;
  white-space: nowrap;
}

.precio-preview-item.total {
  grid-column: 1 / -1;
  border-top: 1px solid #d3d9e3;
  padding-top: 8px;
  font-size: 1rem;
}
/*FIN ESTILO PREVIEW CAMBIO DE PRECIO*/

/*INICIO ESTILO DETALLE DE GANANCIAS EN CAJA*/

/* MODAL DESGLOSE GANANCIA */
.izzy-modal-desglose-ganancia {
  width: 96vw;
  max-width: 1280px;
  margin: 12px auto;
}

.izzy-modal-desglose-ganancia .modal-content {
  max-height: 96vh;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
}

.izzy-modal-desglose-ganancia .modal-body {
  overflow-y: auto;
  overflow-x: hidden;
}

.izzy-modal-body-compact {
  padding: 14px 16px 16px 16px;
}

.izzy-modal-footer-compact {
  padding: 10px 16px;
  border-top: 1px solid #e5e7eb;
  background: #ffffff;
}

.izzy-modal-header {
  background: #111827;
  color: #ffffff;
  border-bottom: 4px solid #10b981;
  padding: 10px 14px;
}

.izzy-modal-header .modal-title {
  font-size: 18px;
  font-weight: 900;
  line-height: 1.25;
}

.izzy-modal-subtitle {
  opacity: 0.88;
  font-size: 13px;
  font-weight: 500;
}

/* SECCIONES */
.izzy-section-block {
  margin-bottom: 14px;
}

.izzy-section-title {
  font-size: 15.5px;
  font-weight: 900;
  color: #111827;
  margin-bottom: 9px;
  display: flex;
  align-items: center;
  gap: 7px;
  line-height: 1.3;
}

.izzy-section-title i {
  font-size: 14px;
}

/* FILAS KPI */
.izzy-kpi-row-compact {
  margin-left: -6px;
  margin-right: -6px;
}

.izzy-kpi-row-compact > [class*="col-"] {
  padding-left: 6px;
  padding-right: 6px;
}

/* TARJETAS KPI */
.izzy-kpi-card {
  border: 1px solid #eef1f5;
  border-radius: 13px;
  background: #ffffff;
  box-shadow: 0 5px 15px rgba(15, 23, 42, 0.05);
  padding: 12px 13px;
  min-height: 116px;
  height: auto;
  overflow: visible;
}

.izzy-kpi-card-mini {
  min-height: 100px;
  height: auto;
  padding: 11px 12px;
}

.izzy-kpi-card-highlight {
  border-color: #bbf7d0;
  background: #f8fffb;
}

.izzy-kpi-card-neto {
  border-color: #bfdbfe;
  background: #eff6ff;
}

.izzy-kpi-card-reinversion {
  border-color: #fed7aa;
  background: #fff7ed;
}

.izzy-kpi-card-diff {
  border-color: #fde68a;
  background: #fffbeb;
}

/* LABEL KPI */
.izzy-kpi-label {
  color: #6b7280;
  font-size: 11.5px;
  font-weight: 900;
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.25;
  min-height: 29px;
  height: auto;
  overflow: visible;
}

/* VALOR KPI */
.izzy-kpi-value {
  color: #111827;
  font-size: 20px;
  font-weight: 900;
  margin: 0 0 5px 0;
  line-height: 1.15;
  white-space: normal;
  overflow: visible;
  text-overflow: unset;
  word-break: normal;
}

/* HELPERS / DESCRIPCIONES */
.izzy-kpi-card small {
  color: #475569;
  font-size: 11.5px;
  line-height: 1.35;
  display: block;
  overflow: visible;
  white-space: normal;
  word-break: normal;
}

/* COLORES KPI */
.izzy-kpi-success {
  color: #16a34a;
}

.izzy-kpi-warning {
  color: #f59e0b;
}

.izzy-kpi-danger {
  color: #dc2626;
}

.izzy-kpi-primary {
  color: #2563eb;
}

/* NOTAS */
.izzy-note {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a8a;
  border-radius: 11px;
  padding: 9px 12px;
  font-size: 12.5px;
  line-height: 1.42;
}

.izzy-note strong {
  font-weight: 900;
}

.izzy-note small {
  font-size: 11.5px;
  line-height: 1.35;
}

.izzy-note-warning {
  background: #fffbeb;
  border-color: #fde68a;
  color: #92400e;
}

/* TABLA PRINCIPAL DE CAJAS */
#dataTableCajas tbody td,
#dataTableCajas tbody td span {
  font-size: 14px !important;
  line-height: 1.4 !important;
}

#dataTableCajas tbody td span {
  font-weight: 700 !important;
  white-space: nowrap !important;
}

#dataTableCajas tfoot th {
  padding-top: 18px !important;
  padding-bottom: 18px !important;
  background: #f8fafc !important;
  color: #111827 !important;
  font-size: 16px !important;
  font-weight: 900 !important;
  border-top: 2px solid #e5e7eb !important;
}

#dataTableCajas tfoot th span {
  font-size: 17px !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
  color: #0f172a !important;
}

/* TABLA DETALLE GANANCIA */
.izzy-table-responsive-ganancia {
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  overflow-x: auto;
  overflow-y: hidden;
}

#dataTableDetalleGananciaCaja {
  margin-bottom: 0 !important;
}

#dataTableDetalleGananciaCaja thead th {
  background: #ffffff !important;
  color: #111827 !important;
  font-size: 13px !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
  vertical-align: middle !important;
  border-bottom: 2px solid #e5e7eb !important;
  padding: 10px 12px !important;
}

#dataTableDetalleGananciaCaja tbody td,
#dataTableDetalleGananciaCaja tbody td span {
  font-size: 13px !important;
  line-height: 1.35 !important;
}

#dataTableDetalleGananciaCaja tbody td {
  vertical-align: middle !important;
  padding: 10px 12px !important;
}

#dataTableDetalleGananciaCaja tbody td span {
  font-weight: 700 !important;
  white-space: nowrap !important;
}

#dataTableDetalleGananciaCaja tfoot th {
  padding-top: 12px !important;
  padding-bottom: 12px !important;
  background: #f8fafc !important;
  color: #111827 !important;
  font-size: 14px !important;
  font-weight: 900 !important;
  border-top: 2px solid #e5e7eb !important;
}

#dataTableDetalleGananciaCaja tfoot th span {
  font-size: 15px !important;
  font-weight: 900 !important;
  white-space: nowrap !important;
  color: #0f172a !important;
}

/* DATATABLE CONTROLES */
#dataTableDetalleGananciaCaja_wrapper .dataTables_length,
#dataTableDetalleGananciaCaja_wrapper .dataTables_filter {
  margin-bottom: 10px;
}

#dataTableDetalleGananciaCaja_wrapper .dataTables_length label,
#dataTableDetalleGananciaCaja_wrapper .dataTables_filter label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
}

#dataTableDetalleGananciaCaja_wrapper .dataTables_filter input {
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 6px 10px;
  height: 38px;
}

#dataTableDetalleGananciaCaja_wrapper .dataTables_length select {
  border: 1px solid #d1d5db;
  border-radius: 8px;
  padding: 5px 8px;
  height: 38px;
}

#dataTableDetalleGananciaCaja_wrapper .dt-buttons {
  margin-bottom: 10px;
}

#dataTableDetalleGananciaCaja_wrapper .dt-buttons .btn {
  border-radius: 8px;
  font-size: 13px;
  font-weight: 800;
  padding: 7px 14px;
}

/* RESPONSIVE */
@media (max-width: 1400px) {
  .izzy-modal-desglose-ganancia {
    width: 98vw;
    max-width: 1180px;
  }

  .izzy-kpi-value {
    font-size: 18px;
  }

  .izzy-kpi-card {
    padding: 11px 12px;
    min-height: 112px;
  }

  .izzy-kpi-card-mini {
    min-height: 98px;
  }

  .izzy-kpi-label {
    font-size: 11px;
    min-height: 28px;
  }

  .izzy-kpi-card small {
    font-size: 11px;
    line-height: 1.34;
  }
}

@media (max-width: 992px) {
  .izzy-modal-desglose-ganancia {
    width: 98vw;
    margin: 8px auto;
  }

  .izzy-modal-desglose-ganancia .modal-content {
    max-height: 97vh;
  }

  .izzy-modal-body-compact {
    padding: 12px;
  }

  .izzy-modal-header .modal-title {
    font-size: 16px;
  }

  .izzy-kpi-card,
  .izzy-kpi-card-mini {
    min-height: auto;
    height: auto;
  }

  .izzy-kpi-label {
    min-height: auto;
    height: auto;
  }
}

@media (max-width: 768px) {
  .izzy-modal-desglose-ganancia {
    width: 100vw;
    max-width: 100vw;
    margin: 0;
  }

  .izzy-modal-desglose-ganancia .modal-content {
    height: 100vh;
    max-height: 100vh;
    border-radius: 0;
  }

  .izzy-modal-header {
    padding: 10px 12px;
  }

  .izzy-modal-body-compact {
    padding: 10px;
  }

  .izzy-modal-footer-compact {
    padding: 9px 10px;
  }

  .izzy-kpi-card,
  .izzy-kpi-card-mini {
    height: auto;
    min-height: auto;
    padding: 11px 12px;
  }

  .izzy-kpi-label {
    height: auto;
    min-height: auto;
    font-size: 11px;
  }

  .izzy-kpi-value {
    font-size: 18px;
  }

  .izzy-kpi-card small {
    font-size: 11px;
    line-height: 1.35;
  }

  .izzy-section-title {
    font-size: 14px;
  }

  .izzy-note {
    font-size: 12px;
    line-height: 1.4;
  }

  #dataTableDetalleGananciaCaja thead th,
  #dataTableDetalleGananciaCaja tbody td {
    font-size: 12px !important;
    padding: 9px 10px !important;
  }
}

/*FIN ESTILO DETALLE DE GANANCIAS EN CAJA*/

/*INICIO VER DETALLE DE PRODUCTOS*/
.btn-detalle-producto {
  background: #f8fafc !important;
  color: #2563eb !important;
  border: 1px solid #e5e7eb !important;
  border-radius: 8px !important;
  padding: 4px 10px !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
}

.btn-detalle-producto:hover,
.btn-detalle-producto:focus {
  background: #2563eb !important;
  color: #ffffff !important;
  border-color: #2563eb !important;
  text-decoration: none !important;
}
/*FIN VER DETALLE DE PRODUCTOS*/

/*INICIO MOVIMIENTO DE PRODUCTOS*/
.modal-footer-movimiento {
  position: sticky;
  bottom: 0;
  z-index: 20;
  background: #ffffff;
  border-top: 1px solid #dee2e6;
  box-shadow: 0 -6px 18px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  flex-wrap: wrap;
}

.movimiento-operacion-info {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 280px;
  flex: 1;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid transparent;
  transition: all 0.25s ease-in-out;
}

.movimiento-operacion-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.movimiento-operacion-icon i {
  font-size: 20px;
}

.movimiento-operacion-texto {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.movimiento-operacion-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  opacity: 0.85;
}

.movimiento-operacion-texto strong {
  font-size: 16px;
  font-weight: 700;
}

.movimiento-operacion-texto small {
  font-size: 12px;
  margin-top: 2px;
}

.movimiento-operacion-entrada {
  background: #eaf8f0;
  border-color: #bde8cd;
  color: #155724;
}

.movimiento-operacion-entrada .movimiento-operacion-icon {
  background: #28a745;
  color: #ffffff;
}

.movimiento-operacion-salida {
  background: #fff4e5;
  border-color: #ffd89b;
  color: #7a4a00;
}

.movimiento-operacion-salida .movimiento-operacion-icon {
  background: #f39c12;
  color: #ffffff;
}

.movimiento-footer-botones {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 768px) {
  .modal-footer-movimiento {
    align-items: stretch;
  }

  .movimiento-operacion-info {
    width: 100%;
    flex: 100%;
  }

  .movimiento-footer-botones {
    width: 100%;
    justify-content: flex-end;
  }
}

.saldo-producto-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid #d7e3ff;
  background: #f4f8ff;
  box-shadow: 0 4px 14px rgba(0, 123, 255, 0.08);
  transition: all 0.25s ease-in-out;
  margin-top: 4px;
}

.saldo-producto-icon {
  width: 52px;
  height: 52px;
  min-width: 52px;
  border-radius: 50%;
  background: #007bff;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.saldo-producto-icon i {
  font-size: 23px;
}

.saldo-producto-content {
  flex: 1;
  min-width: 0;
}

.saldo-producto-label {
  display: block;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  color: #476282;
  margin-bottom: 3px;
}

.saldo-producto-main {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.saldo-producto-main strong {
  font-size: 21px;
  font-weight: 800;
  color: #16365f;
}

.saldo-producto-content small {
  display: block;
  margin-top: 3px;
  color: #6c757d;
  font-size: 12px;
}

.saldo-producto-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

.saldo-producto-card-empty {
  background: #f8f9fa;
  border-color: #e4e7ea;
  box-shadow: none;
}

.saldo-producto-card-empty .saldo-producto-icon {
  background: #6c757d;
}

.saldo-producto-card-empty .saldo-producto-badge {
  background: #e9ecef;
  color: #495057;
}

.saldo-producto-card-ok {
  background: #eaf8f0;
  border-color: #bde8cd;
}

.saldo-producto-card-ok .saldo-producto-icon {
  background: #28a745;
}

.saldo-producto-card-ok .saldo-producto-badge {
  background: #28a745;
  color: #ffffff;
}

.saldo-producto-card-warning {
  background: #fff8e5;
  border-color: #ffe3a3;
}

.saldo-producto-card-warning .saldo-producto-icon {
  background: #f39c12;
}

.saldo-producto-card-warning .saldo-producto-badge {
  background: #f39c12;
  color: #ffffff;
}

.saldo-producto-card-danger {
  background: #fff1f1;
  border-color: #ffc7c7;
}

.saldo-producto-card-danger .saldo-producto-icon {
  background: #dc3545;
}

.saldo-producto-card-danger .saldo-producto-badge {
  background: #dc3545;
  color: #ffffff;
}

.saldo-producto-card-loading {
  background: #eef5ff;
  border-color: #bdd7ff;
}

.saldo-producto-card-loading .saldo-producto-icon {
  background: #007bff;
}

@media (max-width: 768px) {
  .saldo-producto-card {
    align-items: flex-start;
  }

  .saldo-producto-main strong {
    font-size: 18px;
  }
}
/*FIN MOVIMIENTO DE PRODUCTOS*/

/* =========================================================
   ACCIONES GLOBALES PARA TABLAS
   Reutilizable en productos, clientes, facturas, compras, etc.
========================================================= */

.acciones-dropdown {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
}

/* Botón principal */
.btn-acciones {
  height: 34px;
  min-width: 108px;
  padding: 6px 12px;
  border-radius: 9px;
  border: 1px solid #0d6efd;
  background: #0d6efd;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  box-shadow: 0 4px 10px rgba(13, 110, 253, 0.18);
  transition:
    background 0.16s ease-in-out,
    box-shadow 0.16s ease-in-out;
}

.btn-acciones:hover,
.btn-acciones:focus,
.btn-acciones:active {
  color: #ffffff;
  background: #0b5ed7;
  border-color: #0b5ed7;
  box-shadow: 0 6px 14px rgba(13, 110, 253, 0.24);
}

.btn-acciones > i {
  width: 14px;
  height: 14px;
  font-size: 13px;
  line-height: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
}

.btn-acciones.dropdown-toggle::after {
  margin-left: 2px;
}

/* Menú */
.acciones-menu {
  min-width: 170px;
  border: 1px solid #edf0f4;
  border-radius: 12px;
  padding: 6px;
  margin-top: 6px;
  background: #ffffff;
  box-shadow: 0 12px 26px rgba(15, 23, 42, 0.16);
  overflow: hidden;
  z-index: 2050;
}

/* Item */
.acciones-menu .dropdown-item {
  width: 100%;
  height: 42px;
  padding: 0 10px !important;
  margin: 0 0 4px 0 !important;
  border: 0 !important;
  border-radius: 9px !important;
  background: transparent !important;
  color: #1f2937 !important;
  box-shadow: none !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  cursor: pointer;
  line-height: 1 !important;
}

.acciones-menu .dropdown-item:last-child {
  margin-bottom: 0 !important;
}

/* Contenedor del icono */
.accion-icon {
  width: 30px;
  height: 30px;
  min-width: 30px;
  max-width: 30px;
  border-radius: 8px;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 1 !important;
  text-align: center !important;
  overflow: hidden;
}

/* Icono interno */
.accion-icon > i {
  width: 30px !important;
  height: 30px !important;
  font-size: 13px !important;
  line-height: 30px !important;
  display: block !important;
  text-align: center !important;
  margin: 0 !important;
  padding: 0 !important;
}

/* Ajustes específicos porque FontAwesome no renderiza todos igual */
.accion-icon-editar > i {
  line-height: 30px !important;
  transform: translateY(0);
}

.accion-icon-eliminar > i {
  line-height: 30px !important;
  transform: translateY(0);
}

/* Texto */
.accion-label {
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  text-align: left;
  color: #1f2937;
  white-space: nowrap;
}

/* Editar */
.accion-editar:hover {
  background: #fff7e6 !important;
}

.accion-icon-editar {
  background: #fff0c2;
  color: #b7791f;
}

/* Eliminar */
.accion-eliminar:hover {
  background: #fff0f0 !important;
}

.accion-icon-eliminar {
  background: #ffdede;
  color: #dc3545;
}

/* Ver / Detalle */
.accion-ver:hover,
.accion-detalle:hover {
  background: #eef6ff !important;
}

.accion-icon-ver,
.accion-icon-detalle {
  background: #dbeafe;
  color: #0d6efd;
}

/* Imprimir / PDF */
.accion-imprimir:hover,
.accion-pdf:hover {
  background: #fff0f0 !important;
}

.accion-icon-imprimir,
.accion-icon-pdf {
  background: #ffdede;
  color: #dc3545;
}

/* Enviar */
.accion-enviar:hover {
  background: #f0f2ff !important;
}

.accion-icon-enviar {
  background: #e0e7ff;
  color: #4f46e5;
}

/* Confirmar / Pagar */
.accion-confirmar:hover,
.accion-pagar:hover {
  background: #ecfdf3 !important;
}

.accion-icon-confirmar,
.accion-icon-pagar {
  background: #dcfce7;
  color: #16a34a;
}

/* Cancelar / Anular */
.accion-cancelar:hover,
.accion-anular:hover {
  background: #fff0f0 !important;
}

.accion-icon-cancelar,
.accion-icon-anular {
  background: #fee2e2;
  color: #dc2626;
}

/* DataTables */
table.dataTable .acciones-dropdown {
  white-space: nowrap;
}

table.dataTable td .acciones-menu {
  text-align: left;
}

/* Responsive */
@media (max-width: 768px) {
  .btn-acciones {
    height: 32px;
    min-width: 100px;
    font-size: 12px;
    padding: 6px 10px;
  }

  .btn-acciones > i {
    width: 13px;
    height: 13px;
    font-size: 12px;
    line-height: 13px;
  }

  .acciones-menu {
    min-width: 160px;
  }

  .acciones-menu .dropdown-item {
    height: 40px;
    gap: 9px !important;
  }

  .accion-icon {
    width: 28px;
    height: 28px;
    min-width: 28px;
    max-width: 28px;
  }

  .accion-icon > i {
    width: 28px !important;
    height: 28px !important;
    font-size: 12px !important;
    line-height: 28px !important;
  }

  .accion-label {
    font-size: 12px;
  }
}

/* =========================================================
   MODAL FOOTER GLOBAL - BOTONES UNIFORMES
   Aplica a todos los footers de modales
========================================================= */

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
  padding: 1rem 1.25rem;
}

.modal-footer .btn {
  min-width: 118px;
  height: 38px;
  margin: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-weight: 600;
  white-space: nowrap;
}

/* Pantallas pequeñas: botones parejos */
@media (max-width: 576px) {
  .modal-footer {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
  }

  .modal-footer .btn {
    flex: 1 1 0;
    width: auto !important;
    min-width: 0;
  }
}

/* Si un modal tiene más de 2 botones en móvil, permite salto ordenado */
@media (max-width: 576px) {
  .modal-footer:has(.btn:nth-of-type(3)) {
    flex-wrap: wrap;
  }

  .modal-footer:has(.btn:nth-of-type(3)) .btn {
    flex: 1 1 calc(50% - 8px);
  }
}

/* =========================================================
   COMPLEMENTO SEGURO - GANANCIA / CAJAS
   Tomado del style malo sin tocar layout global
========================================================= */

.izzy-kpi-card small {
  display: block;
  margin-top: 8px;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.35;
}

.izzy-kpi-card-highlight {
  border-color: #bfdbfe;
  background: #f8fbff;
}

.izzy-note {
  line-height: 1.45;
}

.izzy-note-warning {
  background: #fffbeb !important;
  border-color: #fcd34d !important;
  color: #92400e !important;
}

.izzy-note-warning span {
  font-size: 18px;
  font-weight: 900;
  color: #d97706;
}

/* INICIO DROPDOWN GLOBAL DE ACCIONES */
/* =========================================================
   DROPDOWN GLOBAL DE ACCIONES PARA DATATABLES
   USAR SOLO ESTE BLOQUE - PEGAR AL FINAL DEL CSS
   ========================================================= */

/* Se omite el bloque de overflow global para no afectar el responsive original. */

/* Contenedor del botón */
.acciones-dropdown {
  position: relative !important;
  display: inline-block !important;
}

/* Botón azul de acciones */
.btn-acciones {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 7px !important;
  background: #2563eb !important;
  border: 1px solid #2563eb !important;
  color: #ffffff !important;
  border-radius: 10px !important;
  font-weight: 800 !important;
  padding: 7px 12px !important;
  min-width: auto !important;
  height: 34px !important;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.22) !important;
  cursor: pointer !important;
  white-space: nowrap !important;
  line-height: 1 !important;
}

.btn-acciones:hover,
.btn-acciones:focus {
  background: #1d4ed8 !important;
  border-color: #1d4ed8 !important;
  color: #ffffff !important;
  outline: none !important;
}

.btn-acciones i {
  color: #ffffff !important;
  display: inline-block !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 13px !important;
  line-height: 1 !important;
  transform: none !important;
}

/* Menú desplegable */
.acciones-menu {
  display: none !important;
  border: 0 !important;
  border-radius: 14px !important;
  padding: 8px !important;
  min-width: 220px !important;
  background: #ffffff !important;
  box-shadow: 0 18px 40px rgba(15, 23, 42, 0.22) !important;
  z-index: 999999 !important;
  text-align: left !important;
  margin: 0 !important;
}

/* Cuando el JS lo abre */
.acciones-menu.show {
  display: block !important;
}

/* Items del menú */
.acciones-menu .accion-item,
.accion-item {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  width: 100% !important;
  height: auto !important;
  min-height: 42px !important;
  padding: 9px 10px !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #334155 !important;
  font-weight: 700 !important;
  text-align: left !important;
  white-space: nowrap !important;
  min-width: 0 !important;
  line-height: 1 !important;
  cursor: pointer !important;
}

.acciones-menu .accion-item:hover,
.accion-item:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}

.acciones-menu .accion-item:focus,
.accion-item:focus {
  background: #f1f5f9 !important;
  color: #0f172a !important;
  outline: none !important;
}

.acciones-menu .accion-item:disabled,
.accion-item:disabled {
  opacity: 0.65 !important;
  cursor: not-allowed !important;
  background: transparent !important;
}

/* Caja del icono */
.acciones-menu .accion-icon,
.accion-icon {
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  max-width: 30px !important;
  border-radius: 9px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 0 !important;
  margin: 0 !important;
  line-height: 1 !important;
  flex: 0 0 30px !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* Icono FontAwesome */
.acciones-menu .accion-icon i,
.accion-icon i {
  display: inline-block !important;
  width: auto !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  font-size: 13px !important;
  line-height: 1 !important;
  color: inherit !important;
  visibility: visible !important;
  opacity: 1 !important;
  transform: none !important;
}

/* Texto del item */
.acciones-menu .accion-label,
.accion-label {
  display: inline-block !important;
  font-size: 13px !important;
  font-weight: 800 !important;
  line-height: 1 !important;
  text-align: left !important;
  color: #1f2937 !important;
  white-space: nowrap !important;
}

/* Colores de iconos */
.accion-icon-editar {
  background: #fff0c2 !important;
  color: #b7791f !important;
}

.accion-icon-eliminar {
  background: #ffdede !important;
  color: #dc3545 !important;
}

.accion-icon-success {
  background: #dcfce7 !important;
  color: #15803d !important;
}

.accion-icon-warning {
  background: #ffedd5 !important;
  color: #ea580c !important;
}

.accion-icon-primary {
  background: #dbeafe !important;
  color: #2563eb !important;
}

.accion-icon-danger {
  background: #fee2e2 !important;
  color: #dc2626 !important;
}

/* Evita que reglas globales de dropdown maten los iconos */
.dropdown-menu .dropdown-item .accion-icon i,
.acciones-menu .dropdown-item .accion-icon i,
.acciones-menu .accion-item .accion-icon i {
  margin-right: 0 !important;
  width: auto !important;
  text-align: center !important;
  color: inherit !important;
  transform: none !important;
}

/* Evita que reglas de botones tipo table_editar/table_eliminar deformen los items */
.acciones-menu .table_editar,
.acciones-menu .table_eliminar,
.acciones-menu .table_crear,
.acciones-menu .table_reportes,
.acciones-menu .table_ganancia,
.acciones-menu .table_retiro_caja,
.acciones-menu .table_cerrar_caja,
.acciones-menu .table_comprobante_caja {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-start !important;
  gap: 10px !important;
  width: 100% !important;
  height: auto !important;
  min-height: 42px !important;
  padding: 9px 10px !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #334155 !important;
  font-weight: 700 !important;
  text-align: left !important;
  min-width: 0 !important;
}

.acciones-menu .table_editar:hover,
.acciones-menu .table_eliminar:hover,
.acciones-menu .table_crear:hover,
.acciones-menu .table_reportes:hover,
.acciones-menu .table_ganancia:hover,
.acciones-menu .table_retiro_caja:hover,
.acciones-menu .table_cerrar_caja:hover,
.acciones-menu .table_comprobante_caja:hover {
  background: #f1f5f9 !important;
  color: #0f172a !important;
}

/* Cuando el menú se posiciona con JS en fixed */
.acciones-menu[style*="position: fixed"] {
  position: fixed !important;
  z-index: 999999 !important;
}
/* FIN DROPDOWN GLOBAL DE ACCIONES */

/* =========================================================
   RETIRO DE CAJA
   Diseño premium efectivo + transferencia
========================================================= */

.retiro-modal-content {
  border: 0;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.35);
}

.retiro-modal-header {
  background: #111827;
  color: #ffffff;
  border-bottom: 4px solid #10b981;
  padding: 18px 22px;
}

.retiro-modal-header .modal-title {
  font-size: 20px;
  font-weight: 900;
}

.retiro-modal-body {
  padding: 20px 22px 18px 22px;
  background: #ffffff;
}

.retiro-modal-footer {
  padding: 14px 22px;
  background: #f8fafc;
  border-top: 1px solid #e5e7eb;
}

.retiro-alerta-pro {
  display: flex;
  align-items: center;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1e3a8a;
  border-radius: 12px;
  padding: 13px 15px;
  margin-bottom: 16px;
  font-size: 0.95rem;
  line-height: 1.35;
}

.retiro-alerta-pro i {
  margin-right: 10px;
  font-size: 16px;
}

.retiro-resumen-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}

.retiro-resumen-card {
  display: flex;
  align-items: center;
  background: #f8fafc;
  border: 1px solid #dbe3ea;
  border-radius: 18px;
  padding: 18px;
  min-height: 118px;
}

.retiro-resumen-total {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.retiro-medios-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-bottom: 14px;
}

.retiro-medio-card {
  background: #fff7ed;
  border: 1px solid #fb923c;
  border-radius: 18px;
  padding: 18px;
  min-height: 190px;
}

.retiro-medio-transferencia {
  background: #f8fafc;
  border-color: #93c5fd;
}

.retiro-medio-header {
  display: flex;
  align-items: center;
  margin-bottom: 14px;
}

.retiro-medio-header span,
.retiro-resumen-card span,
.retiro-final-card span {
  display: block;
  color: #64748b;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
  margin-bottom: 5px;
  letter-spacing: 0.02em;
}

.retiro-medio-header small,
.retiro-resumen-card small,
.retiro-final-card small {
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.retiro-resumen-card strong,
.retiro-final-card strong {
  display: block;
  color: #0f172a;
  font-size: 26px;
  font-weight: 900;
  line-height: 1.1;
  white-space: nowrap;
}

.retiro-icon {
  width: 50px;
  height: 50px;
  min-width: 50px;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 14px;
  font-size: 20px;
}

.retiro-icon-disponible {
  background: #e0f2fe;
  color: #0369a1;
}

.retiro-icon-transferencia {
  background: #dbeafe;
  color: #1d4ed8;
}

.retiro-icon-retiro {
  background: #ffedd5;
  color: #ea580c;
}

.retiro-icon-final {
  background: #dcfce7;
  color: #15803d;
}

.retiro-icon-total {
  background: #dcfce7;
  color: #15803d;
}

.retiro-input-claro {
  display: flex;
  align-items: center;
  background: #ffffff;
  border: 2px solid #fb923c;
  border-radius: 14px;
  overflow: hidden;
  height: 58px;
}

.retiro-medio-transferencia .retiro-input-claro {
  border-color: #60a5fa;
}

.retiro-input-claro span {
  margin: 0;
  padding: 0 17px;
  height: 100%;
  min-width: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff7ed;
  color: #0f172a;
  font-size: 18px;
  font-weight: 900;
  border-right: 1px solid #fed7aa;
}

.retiro-medio-transferencia .retiro-input-claro span {
  background: #eff6ff;
  border-right-color: #bfdbfe;
}

.retiro-input-claro input {
  width: 100%;
  height: 100%;
  border: 0;
  outline: 0;
  padding: 0 16px;
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  background: #ffffff;
}

.retiro-input-claro input:focus {
  outline: none;
  box-shadow: none;
}

.retiro-input-error {
  border-color: #dc2626 !important;
  box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.13);
}

.retiro-help {
  display: block;
  margin-top: 9px;
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.3;
}

.retiro-final-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.retiro-final-card {
  background: #f8fafc;
  border: 1px solid #dbe3ea;
  border-radius: 16px;
  padding: 15px;
  min-height: 92px;
}

.retiro-final-total {
  background: #f0fdf4;
  border-color: #bbf7d0;
}

#modalRetiroCaja label {
  color: #111827;
  font-weight: 800;
}

#modalRetiroCaja .priority {
  color: #dc2626;
}

#modalRetiroCaja textarea {
  resize: vertical;
  min-height: 90px;
  border-radius: 12px;
}

#modalRetiroCaja .form-control {
  border-radius: 12px;
}

#modalRetiroCaja .bootstrap-select {
  width: 100% !important;
}

#modalRetiroCaja .bootstrap-select > .dropdown-toggle {
  width: 100%;
  min-height: 48px;
  border-radius: 12px;
  border: 1px solid #d1d5db;
  background: #ffffff;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
}

#modalRetiroCaja .bootstrap-select > .dropdown-toggle:focus {
  outline: none !important;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

@media (max-width: 1200px) {
  .retiro-resumen-card strong,
  .retiro-final-card strong {
    font-size: 23px;
  }

  .retiro-input-claro input {
    font-size: 18px;
  }
}

@media (max-width: 992px) {
  .retiro-resumen-grid,
  .retiro-medios-grid,
  .retiro-final-grid {
    grid-template-columns: 1fr;
  }

  .retiro-resumen-card,
  .retiro-medio-card,
  .retiro-final-card {
    min-height: auto;
  }
}

@media (max-width: 576px) {
  .retiro-modal-body {
    padding: 16px;
  }

  .retiro-modal-header {
    padding: 15px 16px;
  }

  .retiro-modal-header .modal-title {
    font-size: 17px;
  }

  .retiro-resumen-card {
    padding: 15px;
  }

  .retiro-medio-card {
    padding: 15px;
  }

  .retiro-resumen-card strong,
  .retiro-final-card strong {
    font-size: 21px;
  }
}

/* FIN RETIRO DE CAJA */

/*INICIO ESTILOS CAJA*/
.acciones-caja-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.badge-estado-caja {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.badge-caja-abierta {
  background: #dcfce7;
  color: #15803d;
  border: 1px solid #86efac;
}

.badge-caja-cerrada {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #cbd5e1;
}

.fila-caja-abierta td {
  background: #ecfdf5 !important;
  border-top: 1px solid #86efac !important;
  border-bottom: 1px solid #86efac !important;
}

.fila-caja-abierta td:first-child {
  border-left: 5px solid #16a34a !important;
}

.fila-caja-cerrada td {
  background: #ffffff !important;
}

.fila-caja-cerrada:hover td {
  background: #f8fafc !important;
}
/*FIN ESTILOS CAJA*/

/*INICIO CORREO GRAPHS*/
.modal-correo-premium {
  max-width: 1180px;
}

#modalConfEmails .modal-content {
  border-radius: 14px;
  overflow: hidden;
  border: 0;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
}

#modalConfEmails .modal-header {
  padding: 18px 22px;
  border-bottom: 4px solid #22c7d5;
}

#modalConfEmails .card {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.06);
}

#modalConfEmails .card-header {
  padding: 14px 18px;
}

#modalConfEmails .form-control,
#modalConfEmails .bootstrap-select > .dropdown-toggle {
  min-height: 48px;
  font-size: 15px;
  border-radius: 8px;
}

#modalConfEmails label {
  font-size: 15px;
  font-weight: 600;
  color: #2e3b4e;
}

#modalConfEmails .form-text {
  font-size: 12.5px;
}

#modalConfEmails .modal-footer {
  padding: 18px 22px;
  background: #f7f9fb;
}

.correo-acciones-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: nowrap;
}

.btn-toggle-detalle-correo {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid #d6e2f1;
  background: #ffffff;
  color: #1f6feb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 8px rgba(31, 111, 235, 0.12);
  transition: all 0.18s ease-in-out;
  cursor: pointer;
}

.btn-toggle-detalle-correo:hover {
  background: #edf5ff;
  border-color: #9dc6ff;
  transform: translateY(-1px);
}

.btn-toggle-detalle-correo.abierto {
  background: #1f6feb;
  color: #ffffff;
  border-color: #1f6feb;
}

.btn-toggle-detalle-correo i {
  font-size: 13px;
}

.correo-detalle-premium {
  background: linear-gradient(135deg, #f8fbff 0%, #eef6ff 100%);
  border-left: 5px solid #1f8efa;
  border-radius: 12px;
  padding: 18px;
  margin: 8px 0 12px 0;
  box-shadow: inset 0 0 0 1px rgba(31, 142, 250, 0.1);
}

.correo-detalle-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.correo-detalle-title {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #1f2937;
}

.correo-detalle-subtitle {
  margin: 3px 0 0 0;
  font-size: 13px;
  color: #6b7280;
}

.correo-detalle-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  gap: 14px;
}

.correo-detalle-item {
  background: #ffffff;
  border: 1px solid #e5edf5;
  border-radius: 10px;
  padding: 12px;
}

.correo-detalle-label {
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 700;
  color: #6b7280;
  margin-bottom: 5px;
  letter-spacing: 0.3px;
}

.correo-detalle-value {
  font-size: 14px;
  color: #17202a;
  word-break: break-word;
  font-weight: 600;
}

.badge-metodo-graph {
  background: #1fa64a;
  color: #fff;
  padding: 6px 10px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13px;
}

.badge-metodo-smtp {
  background: #17a2b8;
  color: #fff;
  padding: 6px 10px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13px;
}

table.dataTable tbody tr.shown {
  background: #f3f8ff !important;
}

table.dataTable tbody tr.shown td {
  border-bottom: 0;
}

/* AYUDA CONFIGURACIÓN CORREO */
.ayuda-correo {
  border-radius: 14px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  border: 1px solid #e5edf5;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.06);
}

.ayuda-correo .ayuda-header {
  padding: 14px 18px;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 10px;
}

.ayuda-correo .ayuda-header h5 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
}

.ayuda-correo .ayuda-body {
  padding: 16px 18px;
  background: #ffffff;
}

.ayuda-correo .ayuda-body p {
  margin-bottom: 10px;
  color: #374151;
  font-size: 14px;
}

.ayuda-correo .ayuda-lista {
  margin: 0;
  padding-left: 18px;
}

.ayuda-correo .ayuda-lista li {
  margin-bottom: 8px;
  color: #374151;
  font-size: 14px;
  line-height: 1.45;
}

.ayuda-correo .ayuda-lista strong {
  color: #111827;
}

.ayuda-correo .ayuda-nota {
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: #f8fafc;
  border-left: 4px solid #94a3b8;
  color: #475569;
  font-size: 13px;
}

.ayuda-correo .ayuda-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  font-weight: 700;
  color: #0f6bff;
  text-decoration: none;
}

.ayuda-correo .ayuda-link:hover {
  text-decoration: underline;
}

.ayuda-graph .ayuda-header {
  background: linear-gradient(135deg, #16803a 0%, #22a447 100%);
}

.ayuda-smtp .ayuda-header {
  background: linear-gradient(135deg, #0f7d95 0%, #17a2b8 100%);
}

.ayuda-pill {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2ff;
  color: #3730a3;
  font-weight: 700;
  font-size: 12px;
}

@media (max-width: 992px) {
  .correo-detalle-grid {
    grid-template-columns: repeat(2, minmax(180px, 1fr));
  }
}

@media (max-width: 576px) {
  .correo-detalle-grid {
    grid-template-columns: 1fr;
  }

  .correo-acciones-wrap {
    flex-direction: column;
  }

  .ayuda-correo .ayuda-body {
    padding: 14px;
  }
}
/*FIN CORREO GRAPHS*/

/* INICIO MODO SEGURO CONFIGURACIÓN CORREO */
.alerta-correo-seguridad {
  border-radius: 12px;
  border: 1px solid #e5edf5;
  padding: 14px 16px;
  margin-bottom: 18px;
  background: #f8fafc;
  color: #334155;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  box-shadow: 0 3px 10px rgba(15, 23, 42, 0.05);
}

.alerta-correo-seguridad .alerta-icono {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e0f2fe;
  color: #0369a1;
  flex: 0 0 36px;
}

.alerta-correo-seguridad .alerta-contenido h6 {
  margin: 0 0 4px 0;
  font-weight: 700;
  color: #0f172a;
}

.alerta-correo-seguridad .alerta-contenido p {
  margin: 0;
  font-size: 13px;
  line-height: 1.45;
}

.alerta-correo-seguridad.modo-lectura {
  background: #fff7ed;
  border-color: #fed7aa;
}

.alerta-correo-seguridad.modo-lectura .alerta-icono {
  background: #ffedd5;
  color: #c2410c;
}

#modalConfEmails .campo-solo-lectura,
#modalConfEmails .campo-solo-lectura[readonly] {
  background-color: #f8fafc !important;
  cursor: not-allowed;
}

#modalConfEmails .bootstrap-select.disabled > .dropdown-toggle,
#modalConfEmails select:disabled + button.dropdown-toggle {
  background-color: #f8fafc !important;
  cursor: not-allowed;
}

.texto-secreto-guardado {
  font-size: 12.5px;
  color: #64748b;
  font-weight: 600;
}
/* FIN MODO SEGURO CONFIGURACIÓN CORREO */

.payment-required {
  color: #dc3545;
  font-weight: 700;
}
.payment-help-text {
  font-size: 12px;
  color: #6c757d;
  margin-top: 6px;
  display: block;
}
.payment-help-text i {
  margin-right: 4px;
}

/*INICIO ESTILO MOVIMIENTOS DE CUENTAS*/
.movimientos-premium-card {
  border: 0;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
  overflow: hidden;
}

.movimientos-premium-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
  padding: 1.15rem 1.25rem;
}

.movimientos-premium-title {
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.movimientos-premium-subtitle {
  font-size: 0.82rem;
  color: #64748b;
  margin-top: 0.25rem;
  margin-bottom: 0;
}

.movimientos-filter-box {
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
}

.movimientos-filter-box .form-control,
.movimientos-filter-box .custom-select,
.movimientos-filter-box select.form-control {
  border-radius: 12px;
  border-color: rgba(148, 163, 184, 0.45);
  min-height: 42px;
}

.movimientos-filter-box .input-group-text {
  border-radius: 12px 0 0 12px;
  background: #f8fafc;
  border-color: rgba(148, 163, 184, 0.45);
  color: #334155;
}

.movimientos-filter-box label {
  font-weight: 700;
  color: #334155;
}

.movimientos-summary-card {
  position: relative;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  padding: 1rem;
  height: 100%;
  overflow: hidden;
}

.movimientos-summary-card:before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 5px;
  height: 100%;
  background: #0f172a;
}

.movimientos-summary-card.summary-income:before {
  background: #16a34a;
}

.movimientos-summary-card.summary-expense:before {
  background: #dc2626;
}

.movimientos-summary-card.summary-balance:before {
  background: #2563eb;
}

.movimientos-summary-card.summary-accounts:before {
  background: #7c3aed;
}

.movimientos-summary-label {
  font-size: 0.78rem;
  font-weight: 800;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.35rem;
}

.movimientos-summary-value {
  font-size: 1.3rem;
  font-weight: 900;
  color: #0f172a;
  margin: 0;
  line-height: 1.15;
}

.movimientos-summary-help {
  font-size: 0.78rem;
  color: #64748b;
  margin-top: 0.35rem;
  margin-bottom: 0;
}

.badge-movimiento {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  font-weight: 800;
  font-size: 0.75rem;
  white-space: nowrap;
}

.badge-movimiento-ingreso {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
  border: 1px solid rgba(22, 163, 74, 0.2);
}

.badge-movimiento-egreso {
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
  border: 1px solid rgba(220, 38, 38, 0.2);
}

.badge-movimiento-neutro {
  background: rgba(100, 116, 139, 0.12);
  color: #475569;
  border: 1px solid rgba(100, 116, 139, 0.2);
}

.badge-cuenta-inversion {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  border-radius: 999px;
  padding: 0.25rem 0.55rem;
  font-weight: 800;
  font-size: 0.72rem;
  background: rgba(124, 58, 237, 0.1);
  color: #6d28d9;
  border: 1px solid rgba(124, 58, 237, 0.2);
  margin-left: 0.35rem;
}

.table-footer-total th {
  background: #f8fafc;
  border-top: 2px solid rgba(15, 23, 42, 0.12) !important;
  font-weight: 900;
  color: #0f172a;
}

.movimientos-empty-helper {
  font-size: 0.82rem;
  color: #64748b;
}

@media (max-width: 767.98px) {
  .movimientos-summary-value {
    font-size: 1.05rem;
  }
}
/*FIN ESTILO MOVIMIENTOS DE CUENTAS*/

/*INICIO DISENO CATEGORIAS DE CUENTAS EN EGRESOS*/
.modal-categorias-premium .modal-content {
  border: 0;
  border-radius: 22px;
  overflow: hidden;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.22);
}

.modal-categorias-premium .modal-header {
  background: #0f172a;
  color: #ffffff;
  border-bottom: 0;
  padding: 1.25rem 1.5rem;
}

.modal-categorias-premium .modal-title {
  font-weight: 800;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.modal-categorias-premium .close {
  color: #ffffff;
  opacity: 0.9;
  text-shadow: none;
}

.categoria-hero {
  background: #f8fafc;
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 18px;
  padding: 1rem 1.15rem;
  margin-bottom: 1rem;
}

.categoria-hero-title {
  font-weight: 900;
  color: #0f172a;
  margin-bottom: 0.2rem;
}

.categoria-hero-text {
  color: #64748b;
  margin-bottom: 0;
  font-size: 0.88rem;
}

.categoria-premium-card {
  border: 1px solid rgba(148, 163, 184, 0.25);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}

.categoria-premium-card .card-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(148, 163, 184, 0.25);
  font-weight: 800;
  color: #0f172a;
  padding: 1rem 1.15rem;
}

.categoria-premium-card .form-control {
  border-radius: 12px;
  min-height: 42px;
  border-color: rgba(148, 163, 184, 0.5);
}

.categoria-invest-box {
  border: 1px solid rgba(124, 58, 237, 0.18);
  background: rgba(124, 58, 237, 0.06);
  border-radius: 16px;
  padding: 0.95rem 1rem;
}

.categoria-invest-title {
  color: #5b21b6;
  font-weight: 900;
  margin-bottom: 0.2rem;
}

.categoria-invest-help {
  color: #64748b;
  font-size: 0.82rem;
  margin-bottom: 0;
}

.categoria-switch {
  position: relative;
  display: inline-block;
  width: 58px;
  height: 32px;
  margin-bottom: 0;
}

.categoria-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.categoria-slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #cbd5e1;
  transition: 0.25s;
  border-radius: 999px;
}

.categoria-slider:before {
  position: absolute;
  content: "";
  height: 24px;
  width: 24px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: 0.25s;
  border-radius: 50%;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.25);
}

.categoria-switch input:checked + .categoria-slider {
  background-color: #7c3aed;
}

.categoria-switch input:checked + .categoria-slider:before {
  transform: translateX(26px);
}

.badge-cat-activa,
.badge-cat-inactiva,
.badge-cat-inversion,
.badge-cat-normal {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  font-weight: 800;
  font-size: 0.76rem;
  white-space: nowrap;
}

.badge-cat-activa {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
  border: 1px solid rgba(22, 163, 74, 0.22);
}

.badge-cat-inactiva {
  background: rgba(220, 38, 38, 0.12);
  color: #b91c1c;
  border: 1px solid rgba(220, 38, 38, 0.22);
}

.badge-cat-inversion {
  background: rgba(124, 58, 237, 0.12);
  color: #6d28d9;
  border: 1px solid rgba(124, 58, 237, 0.22);
}

.badge-cat-normal {
  background: rgba(100, 116, 139, 0.12);
  color: #475569;
  border: 1px solid rgba(100, 116, 139, 0.22);
}

.btn-cat-action {
  border-radius: 999px;
  font-weight: 800;
  padding: 0.35rem 0.75rem;
}

.categoria-table-wrap {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(148, 163, 184, 0.22);
}

.categoria-footer-resumen {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.85rem;
  flex-wrap: wrap;
  padding: 0.65rem 0.75rem;
  background: #f8fafc;
  border-top: 1px solid rgba(148, 163, 184, 0.25);
  color: #334155;
  font-weight: 700;
}

.categoria-footer-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.25);
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}
/*FIN DISENO CATEGORIAS DE CUENTAS EN EGRESOS*/

/* =========================================================
   INICIO DETALLES FACTURACIÓN CLIENTE - DISEÑO PREMIUM
========================================================= */

.facturacion-cliente-page {
  background: #f8fafc;
}

.factura-filter-card,
.factura-table-card {
  background: #ffffff;
  border: 1px solid rgba(148, 163, 184, 0.22);
  border-radius: 18px;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.05);
  overflow: visible;
}

.factura-filter-card .card-header,
.factura-table-card .card-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(148, 163, 184, 0.22);
  padding: 1rem 1.2rem;
  border-radius: 18px 18px 0 0;
}

.factura-card-title {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  color: #0f172a;
  font-weight: 900;
  margin: 0;
}

.factura-card-title i {
  color: #0d6efd;
}

.factura-filter-card .card-body,
.factura-table-card .card-body {
  padding: 1.25rem 1.35rem;
}

.factura-filter-card label {
  color: #334155;
  font-weight: 800;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
}

.factura-filter-card input.form-control {
  min-height: 44px;
  background: #ffffff !important;
  color: #334155 !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  font-weight: 600;
}

.factura-filter-card input.form-control:focus {
  border-color: #0d6efd !important;
  box-shadow: 0 0 0 0.18rem rgba(13, 110, 253, 0.12) !important;
}

.factura-filter-card .bootstrap-select.form-control {
  width: 100% !important;
  height: auto !important;
  min-height: 44px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}

.factura-filter-card .bootstrap-select > .dropdown-toggle {
  width: 100% !important;
  min-height: 44px !important;
  height: 44px !important;
  padding: 0.55rem 0.95rem !important;
  background: #ffffff !important;
  color: #334155 !important;
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  box-shadow: none !important;
  font-weight: 600 !important;
  outline: none !important;
}

.factura-filter-card .bootstrap-select > .dropdown-toggle:hover,
.factura-filter-card .bootstrap-select > .dropdown-toggle:focus,
.factura-filter-card .bootstrap-select.show > .dropdown-toggle {
  border-color: #0d6efd !important;
  box-shadow: 0 0 0 0.18rem rgba(13, 110, 253, 0.12) !important;
}

.factura-filter-card .input-group-text {
  min-height: 44px;
  background: #f8fafc;
  color: #475569;
  border: 1px solid #dbe3ef;
  border-right: 0;
  border-radius: 12px 0 0 12px;
}

.factura-filter-card .input-group .form-control {
  border-radius: 0 12px 12px 0 !important;
}

.factura-toolbar {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.factura-table-responsive {
  overflow: visible;
}

.factura-premium-table {
  margin-bottom: 0 !important;
}

.factura-premium-table thead th {
  white-space: nowrap;
}

.factura-numero {
  color: #0f172a;
  font-weight: 850;
}

.factura-cliente {
  color: #334155;
  font-weight: 700;
}

.factura-total {
  color: #0f172a;
  font-weight: 950;
}

.badge-factura {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 999px;
  padding: 0.42rem 0.75rem;
  font-size: 0.76rem;
  font-weight: 900;
  line-height: 1;
  white-space: nowrap;
  border: 1px solid transparent;
}

.badge-factura-success {
  background: #dcfce7;
  color: #15803d;
  border-color: #bbf7d0;
}

.badge-factura-warning {
  background: #fef3c7;
  color: #b45309;
  border-color: #fde68a;
}

.badge-factura-danger {
  background: #fee2e2;
  color: #dc2626;
  border-color: #fecaca;
}

.badge-factura-info {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.badge-factura-secondary {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

.badge-factura-tipo {
  background: #f1f5f9;
  color: #334155;
  border-color: #e2e8f0;
}

.facturas-footer-resumen {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  padding: 0.45rem;
  background: #f8fafc;
  border-radius: 14px;
}

.facturas-footer-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.55rem 0.85rem;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 999px;
  color: #334155;
  font-weight: 900;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.04);
}

.factura-acciones-dropdown {
  display: inline-flex;
}

.factura-acciones-menu {
  z-index: 10050 !important;
}

.factura-table-card .dataTables_wrapper {
  overflow: visible;
}

.factura-table-card .dataTables_filter input,
.factura-table-card .dataTables_length select {
  border: 1px solid #dbe3ef !important;
  border-radius: 12px !important;
  box-shadow: none !important;
}

.factura-dt-toolbar {
  margin-bottom: 0.75rem;
}

.factura-dt-footer {
  margin-top: 0.75rem;
}

.factura-modal-content {
  border: 0;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 22px 60px rgba(15, 23, 42, 0.32);
}

.factura-modal-content .modal-header {
  background: linear-gradient(135deg, #111827 0%, #1e293b 100%) !important;
  border-bottom: 4px solid #0d6efd;
}

.factura-modal-content .modal-title {
  color: #ffffff;
  font-weight: 900;
}

.factura-modal-content .modal-footer {
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
}

.factura-detalle-resumen {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1rem;
}

.factura-detalle-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  margin-bottom: 0.65rem;
}

.factura-detalle-item span {
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.factura-detalle-item strong {
  color: #0f172a;
  font-weight: 900;
}

.factura-notas-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 1rem;
}

.factura-notas-box h6 {
  color: #0f172a;
  font-weight: 900;
}

.factura-total-row-light {
  background: #f8fafc;
  font-weight: 800;
}

.factura-total-row-final {
  background: #0f172a;
  color: #ffffff;
  font-weight: 900;
}

@media (max-width: 992px) {
  .factura-toolbar {
    justify-content: flex-start;
  }

  .factura-table-card .card-header {
    align-items: flex-start !important;
    flex-direction: column;
    gap: 0.75rem;
  }
}

@media (max-width: 768px) {
  .factura-filter-card .card-body,
  .factura-table-card .card-body {
    padding: 1rem;
  }

  .facturas-footer-resumen {
    justify-content: flex-start;
  }

  .facturas-footer-item {
    width: 100%;
    justify-content: space-between;
  }
}

/* =========================================================
   FIN DETALLES FACTURACIÓN CLIENTE - DISEÑO PREMIUM
========================================================= */

/* =========================================================
   INICIO EMPRESA - DISEÑO PROFESIONAL
   SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
   ========================================================= */

.empresa-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.empresa-label-filter {
  font-weight: 700;
  color: #334155;
  letter-spacing: 0.02em;
}

.empresa-search-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
}

.empresa-search-group .form-control {
  border-color: #dbe3ef;
}

.empresa-search-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.empresa-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.empresa-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.empresa-resumen-activa::before {
  background: #22c55e;
}

.empresa-resumen-contacto::before {
  background: #3498db;
}

.empresa-resumen-web::before {
  background: #8b5cf6;
}

.empresa-resumen-firma::before {
  background: #f59e0b;
}

.empresa-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.empresa-resumen-card h3 {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.empresa-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.82rem;
}

.empresa-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.2rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.empresa-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.empresa-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.empresa-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA EMPRESA
     ========================================================= */

#dataTableEmpresa {
  border-collapse: separate;
  border-spacing: 0;
}

#dataTableEmpresa thead th {
  vertical-align: middle;
  white-space: nowrap;
}

#dataTableEmpresa tbody td {
  vertical-align: middle;
  padding-top: 0.95rem;
  padding-bottom: 0.95rem;
  color: #334155;
}

#dataTableEmpresa tbody tr {
  transition:
    background-color 0.18s ease,
    box-shadow 0.18s ease;
}

#dataTableEmpresa tbody tr:hover {
  background-color: #f8fafc;
}

/* =========================================================
     EMPRESA PRINCIPAL
     ========================================================= */

.empresa-main-box {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  min-width: 320px;
}

.empresa-logo-box {
  flex: 0 0 auto;
}

.empresa-logo-img {
  width: 58px !important;
  height: 58px !important;
  object-fit: contain;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 0.3rem;
  box-shadow: 0 6px 14px rgba(15, 23, 42, 0.08);
}

.empresa-main-info {
  min-width: 0;
}

.empresa-nombre {
  margin: 0;
  color: #0f172a;
  font-weight: 800;
  font-size: 0.94rem;
  letter-spacing: 0.01em;
}

.empresa-razon {
  color: #334155;
  font-size: 0.82rem;
  font-weight: 700;
  margin-top: 0.18rem;
  line-height: 1.35;
}

.empresa-eslogan {
  color: #0f766e;
  font-size: 0.78rem;
  font-weight: 700;
  margin-top: 0.35rem;
  line-height: 1.3;
}

.empresa-extra-info {
  color: #64748b;
  font-size: 0.76rem;
  margin-top: 0.25rem;
  line-height: 1.3;
}

/* =========================================================
     DETALLES
     ========================================================= */

.empresa-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  min-width: 210px;
}

.empresa-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.45rem;
  font-size: 0.8rem;
  line-height: 1.35;
  color: #334155;
  word-break: break-word;
}

.empresa-detail-item strong {
  color: #0f172a;
}

.empresa-detail-icon {
  width: 24px;
  height: 24px;
  min-width: 24px;
  border-radius: 8px;
  background: #eff6ff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
}

.empresa-icon-fiscal {
  background: #f0fdf4;
  color: #16a34a;
}

.empresa-icon-web {
  background: #faf5ff;
  color: #7c3aed;
}

.empresa-email-item span:last-child {
  max-width: 220px;
  overflow-wrap: anywhere;
}

/* =========================================================
     UBICACIÓN
     ========================================================= */

.empresa-location-box {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  min-width: 250px;
  max-width: 360px;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #334155;
}

.empresa-location-icon {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 9px;
  background: #fff7ed;
  color: #ea580c;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* =========================================================
     FIRMA
     ========================================================= */

.empresa-firma-box {
  min-width: 95px;
}

.empresa-firma-img {
  width: 58px;
  height: 42px;
  object-fit: contain;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 0.25rem;
}

.empresa-firma-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 99px;
  padding: 0.3rem 0.65rem;
  font-size: 0.73rem;
  font-weight: 800;
  white-space: nowrap;
}

.empresa-firma-badge.firma-visible {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.empresa-firma-badge.firma-oculta {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* =========================================================
     ESTADO
     ========================================================= */

.empresa-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  border-radius: 99px;
  padding: 0.45rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 800;
  white-space: nowrap;
  min-width: 92px;
}

.empresa-status-active {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.empresa-status-inactive {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* =========================================================
     LINKS
     ========================================================= */

#dataTableEmpresa a {
  color: #2563eb;
  font-weight: 700;
  text-decoration: none;
}

#dataTableEmpresa a:hover {
  color: #1d4ed8;
  text-decoration: underline;
}

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

@media (max-width: 1200px) {
  .empresa-main-box {
    min-width: 280px;
  }

  .empresa-location-box {
    min-width: 230px;
  }
}

@media (max-width: 768px) {
  .empresa-resumen-card {
    min-height: 95px;
  }

  .empresa-main-box {
    min-width: 260px;
  }

  .empresa-logo-img {
    width: 50px !important;
    height: 50px !important;
  }

  .empresa-detail-list {
    min-width: 190px;
  }

  .empresa-location-box {
    min-width: 210px;
  }
}

/* =========================================================
     FIN EMPRESA - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
     INICIO SECUENCIA FACTURACIÓN - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

.secuencia-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.secuencia-label-filter {
  font-weight: 700;
  color: #334155;
  letter-spacing: 0.02em;
}

.secuencia-search-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
}

.secuencia-search-group .form-control {
  border-color: #dbe3ef;
}

.secuencia-search-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.secuencia-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.secuencia-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.secuencia-resumen-activa::before {
  background: #22c55e;
}

.secuencia-resumen-fiscal::before {
  background: #3498db;
}

.secuencia-resumen-disponible::before {
  background: #8b5cf6;
}

.secuencia-resumen-vencer::before {
  background: #f59e0b;
}

.secuencia-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.secuencia-resumen-card h3 {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.secuencia-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.82rem;
}

.secuencia-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.2rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.secuencia-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.secuencia-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.secuencia-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA SECUENCIA
     ========================================================= */

#dataTableSecuencia {
  width: 100% !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

#dataTableSecuencia thead th {
  vertical-align: middle;
  white-space: nowrap;
}

#dataTableSecuencia th,
#dataTableSecuencia td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
}

#dataTableSecuencia th:first-child,
#dataTableSecuencia td:first-child {
  white-space: nowrap !important;
  overflow-wrap: normal;
}

#dataTableSecuencia tbody td {
  vertical-align: middle;
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
  color: #334155;
}

#dataTableSecuencia tbody tr {
  transition:
    background-color 0.18s ease,
    box-shadow 0.18s ease;
}

#dataTableSecuencia tbody tr:hover {
  background-color: #f8fafc;
}

/* =========================================================
     COLUMNA SECUENCIA
     ========================================================= */

.secuencia-main-box {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
  width: 100%;
}

.secuencia-main-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 12px;
  background: #eff6ff;
  color: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  border: 1px solid #dbeafe;
}

.secuencia-main-info {
  min-width: 0;
  width: 100%;
}

.secuencia-title-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
}

.secuencia-empresa {
  margin: 0;
  color: #0f172a;
  font-weight: 800;
  font-size: 0.86rem;
  line-height: 1.2;
  max-width: 100%;
}

.secuencia-documento-row {
  margin-top: 0.35rem;
}

.secuencia-id-text {
  margin-top: 0.25rem;
  color: #64748b;
  font-size: 0.7rem;
  font-weight: 700;
}

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

.secuencia-status-badge,
.secuencia-doc-badge,
.secuencia-vencimiento-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  border-radius: 99px;
  padding: 0.24rem 0.5rem;
  font-size: 0.66rem;
  font-weight: 800;
  white-space: nowrap;
  min-width: auto;
  line-height: 1;
  border: 1px solid transparent;
}

.secuencia-status-active {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.secuencia-status-inactive {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.secuencia-doc-factura {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.secuencia-doc-proforma {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.secuencia-doc-normal {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

.secuencia-vencimiento-ok {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.secuencia-vencimiento-alerta {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.secuencia-vencimiento-vencida {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.secuencia-vencimiento-normal {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

/* =========================================================
     DETALLES
     ========================================================= */

.secuencia-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  min-width: 0;
  width: 100%;
}

.secuencia-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.35rem;
  font-size: 0.73rem;
  line-height: 1.28;
  color: #334155;
  word-break: normal;
  overflow-wrap: anywhere;
}

.secuencia-detail-item strong {
  color: #0f172a;
}

.secuencia-detail-icon {
  width: 20px;
  height: 20px;
  min-width: 20px;
  border-radius: 7px;
  background: #eff6ff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.64rem;
}

.secuencia-icon-cai {
  background: #f0fdf4;
  color: #16a34a;
}

.secuencia-icon-prefijo {
  background: #eff6ff;
  color: #2563eb;
}

.secuencia-icon-date {
  background: #fff7ed;
  color: #ea580c;
}

.secuencia-cai-text {
  font-family: Consolas, Monaco, monospace;
  font-size: 0.7rem;
  color: #334155;
}

.secuencia-mini-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  color: #64748b;
  font-size: 0.68rem;
  font-weight: 700;
}

/* =========================================================
     NUMERACIÓN
     ========================================================= */

.secuencia-number-box {
  min-width: 0;
  width: 100%;
}

.secuencia-next-number {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 0.55rem 0.7rem;
}

.secuencia-next-number span {
  color: #64748b;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
}

.secuencia-next-number strong {
  color: #0f172a;
  font-size: 0.95rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}

.secuencia-range-text {
  margin-top: 0.45rem;
  color: #334155;
  font-size: 0.72rem;
  font-weight: 800;
  font-family: Consolas, Monaco, monospace;
}

.secuencia-progress-box {
  margin-top: 0.55rem;
}

.secuencia-progress-line {
  width: 100%;
  height: 7px;
  border-radius: 99px;
  background: #e2e8f0;
  overflow: hidden;
}

.secuencia-progress-line span {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #3498db, #22c55e);
}

.secuencia-progress-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.35rem;
  color: #64748b;
  font-size: 0.68rem;
  font-weight: 700;
}

.secuencia-progress-meta strong {
  color: #166534;
}

/* =========================================================
     VIGENCIA
     ========================================================= */

.secuencia-vencimiento-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.25rem;
}

.secuencia-vencimiento-row small {
  color: #64748b;
  font-size: 0.68rem;
  font-weight: 700;
}

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

@media (max-width: 1400px) {
  .secuencia-empresa {
    font-size: 0.82rem;
  }

  .secuencia-detail-item {
    font-size: 0.7rem;
  }

  .secuencia-main-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
  }
}

@media (max-width: 768px) {
  .secuencia-resumen-card {
    min-height: 95px;
  }

  .secuencia-main-box {
    align-items: flex-start;
  }

  .secuencia-progress-meta {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* =========================================================
     FIN SECUENCIA FACTURACIÓN - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
   INICIO MOVIMIENTOS PRODUCTOS - DISEÑO PROFESIONAL
   SOLO DISEÑO VISUAL - NO TOCA BOTONES GLOBALES
   ========================================================= */

/* =========================================================
   FILTROS
   ========================================================= */

.movimientos-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.movimientos-filtro-card .card-body {
  padding: 1.25rem 1.35rem;
}

.movimientos-label-filter {
  font-weight: 800;
  color: #334155;
  letter-spacing: 0.02em;
  font-size: 0.84rem;
}

.movimientos-date-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
  min-height: 44px;
}

.movimientos-date-group .form-control {
  border-color: #dbe3ef;
  min-height: 44px;
  font-size: 0.92rem;
  font-weight: 600;
}

.movimientos-date-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

/* Selectpicker filtros */
.movimientos-filtro-card .bootstrap-select.form-control {
  width: 100% !important;
}

.movimientos-filtro-card .bootstrap-select > .dropdown-toggle {
  min-height: 44px;
  border-color: #dbe3ef !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-size: 0.92rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.movimientos-filtro-card .bootstrap-select > .dropdown-toggle:focus,
.movimientos-filtro-card .bootstrap-select.show > .dropdown-toggle {
  border-color: #3498db !important;
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14) !important;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.movimientos-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.movimientos-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.movimientos-resumen-registros::before {
  background: #3498db;
}

.movimientos-resumen-entrada::before {
  background: #22c55e;
}

.movimientos-resumen-salida::before {
  background: #ef4444;
}

.movimientos-resumen-saldo::before {
  background: #8b5cf6;
}

.movimientos-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.movimientos-resumen-card h3 {
  font-size: 1.65rem;
  font-weight: 900;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.movimientos-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 600;
}

.movimientos-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.25rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.movimientos-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.movimientos-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.movimientos-card-header strong {
  font-size: 1.02rem;
  font-weight: 900;
}

.movimientos-card-header small {
  font-size: 0.86rem;
  line-height: 1.35;
}

.movimientos-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA MOVIMIENTOS
     ========================================================= */

#dataTablaMovimientos {
  width: 100% !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

#dataTablaMovimientos thead th {
  vertical-align: middle;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

#dataTablaMovimientos tbody td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  color: #334155;
  font-size: 0.84rem;
}

#dataTablaMovimientos tbody tr {
  transition: background-color 0.18s ease;
}

#dataTablaMovimientos tbody tr:hover {
  background-color: #f8fafc;
}

/* Columnas numéricas compactas */
#dataTablaMovimientos th:nth-child(5),
#dataTablaMovimientos th:nth-child(6),
#dataTablaMovimientos th:nth-child(7),
#dataTablaMovimientos th:nth-child(8),
#dataTablaMovimientos td:nth-child(5),
#dataTablaMovimientos td:nth-child(6),
#dataTablaMovimientos td:nth-child(7),
#dataTablaMovimientos td:nth-child(8) {
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center !important;
}

/* =========================================================
     MOVIMIENTO
     ========================================================= */

.movimientos-main-box,
.movimientos-product-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  width: 100%;
}

.movimientos-main-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 12px;
  background: #eff6ff;
  color: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  border: 1px solid #dbeafe;
}

.movimientos-main-info,
.movimientos-product-info {
  min-width: 0;
  width: 100%;
}

.movimientos-fecha,
.movimientos-product-name {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  font-size: 0.94rem;
  line-height: 1.28;
}

.movimientos-documento {
  color: #334155;
  font-size: 0.8rem;
  font-weight: 800;
  margin-top: 0.28rem;
  line-height: 1.25;
}

.movimientos-comentario {
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 0.28rem;
  line-height: 1.35;
}

.movimientos-product-img-box {
  flex: 0 0 auto;
}

.movimientos-product-img {
  width: 50px !important;
  height: 50px !important;
  object-fit: cover;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 0.15rem;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.08);
}

.movimientos-product-meta {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  color: #64748b;
  font-size: 0.8rem;
  font-weight: 700;
  margin-top: 0.28rem;
  line-height: 1.25;
}

/* =========================================================
     DETALLES
     ========================================================= */

.movimientos-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  min-width: 0;
  width: 100%;
}

.movimientos-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.42rem;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #334155;
  word-break: normal;
  overflow-wrap: anywhere;
}

.movimientos-detail-item strong {
  color: #0f172a;
  font-weight: 900;
}

.movimientos-detail-icon {
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 7px;
  background: #eff6ff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  margin-top: 0.02rem;
}

.movimientos-icon-lote {
  background: #f0fdf4;
  color: #16a34a;
}

.movimientos-icon-doc {
  background: #eff6ff;
  color: #2563eb;
}

.movimientos-icon-cliente {
  background: #faf5ff;
  color: #7c3aed;
}

.movimientos-icon-bodega {
  background: #fff7ed;
  color: #ea580c;
}

/* =========================================================
     LOTE
     ========================================================= */

.movimientos-lote-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 900;
  white-space: nowrap;
  border: 1px solid transparent;
  max-width: 100%;
  line-height: 1;
}

.movimientos-lote-ok {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.movimientos-lote-empty {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

/* =========================================================
     NÚMEROS
     ========================================================= */

.movimientos-number-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0.42rem 0.58rem;
  font-size: 0.82rem;
  font-weight: 900;
  min-width: 58px;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1.1;
}

.movimientos-badge-anterior-ok {
  background: #f1f5f9;
  color: #334155;
  border-color: #cbd5e1;
}

.movimientos-badge-anterior-empty {
  background: #f8fafc;
  color: #94a3b8;
  border-color: #e2e8f0;
}

.movimientos-badge-entrada-ok {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.movimientos-badge-salida-ok {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.movimientos-badge-saldo-ok {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.movimientos-badge-saldo-danger {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.movimientos-badge-neutral {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

/* =========================================================
     FOOTER TABLA
     ========================================================= */

.movimientos-table-footer {
  background: #3498db;
  color: #ffffff;
  font-weight: 900;
}

.movimientos-table-footer td {
  color: #ffffff !important;
  font-size: 0.92rem;
  padding: 0.9rem 0.75rem !important;
  white-space: nowrap !important;
}

.movimientos-footer-label {
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 900;
}

/* =========================================================
     ZOOM IMAGEN
     ========================================================= */

#dataTablaMovimientos .movimientos-zoom-trigger,
#dataTablaMovimientos .movimientos-zoom-trigger img,
#dataTablaMovimientos .iv-trigger,
#dataTablaMovimientos .iv-trigger img {
  cursor: zoom-in !important;
}

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

@media (max-width: 1400px) {
  #dataTablaMovimientos thead th {
    font-size: 0.78rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }

  #dataTablaMovimientos tbody td {
    font-size: 0.8rem;
  }

  .movimientos-fecha,
  .movimientos-product-name {
    font-size: 0.88rem;
  }

  .movimientos-detail-item,
  .movimientos-documento,
  .movimientos-comentario,
  .movimientos-product-meta {
    font-size: 0.76rem;
  }

  .movimientos-number-badge {
    min-width: 54px;
    font-size: 0.76rem;
    padding: 0.36rem 0.48rem;
  }

  .movimientos-lote-badge {
    font-size: 0.72rem;
  }

  .movimientos-product-img {
    width: 44px !important;
    height: 44px !important;
  }

  .movimientos-main-icon {
    width: 42px;
    height: 42px;
    min-width: 42px;
  }

  .movimientos-detail-icon {
    width: 21px;
    height: 21px;
    min-width: 21px;
    font-size: 0.68rem;
  }
}

@media (max-width: 1200px) {
  #dataTablaMovimientos {
    min-width: 980px;
  }

  #dataTablaMovimientos thead th {
    font-size: 0.74rem;
    letter-spacing: 0.01em;
  }

  .movimientos-number-badge {
    min-width: 50px;
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .movimientos-resumen-card {
    min-height: 95px;
  }

  .movimientos-main-box,
  .movimientos-product-box {
    align-items: flex-start;
  }

  #dataTablaMovimientos {
    min-width: 980px;
  }
}

/* =========================================================
     FIN MOVIMIENTOS PRODUCTOS - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTONES GLOBALES
     ========================================================= */

/* =========================================================
     INICIO INVENTARIO TRANSFERENCIA - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
     FILTROS
     ========================================================= */

.inventario-transferencia-page .inventario-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.inventario-transferencia-page .inventario-filtro-card .card-body {
  padding: 1.25rem 1.35rem;
}

.inventario-transferencia-page .inventario-label-filter {
  font-weight: 800;
  color: #334155;
  letter-spacing: 0.02em;
  font-size: 0.84rem;
}

.inventario-transferencia-page .bootstrap-select.form-control {
  width: 100% !important;
}

.inventario-transferencia-page .bootstrap-select > .dropdown-toggle {
  min-height: 44px;
  border-color: #dbe3ef !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-size: 0.92rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.inventario-transferencia-page .bootstrap-select > .dropdown-toggle:focus,
.inventario-transferencia-page .bootstrap-select.show > .dropdown-toggle {
  border-color: #3498db !important;
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14) !important;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.inventario-transferencia-page .inventario-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.inventario-transferencia-page .inventario-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.inventario-transferencia-page .inventario-resumen-registros::before {
  background: #3498db;
}

.inventario-transferencia-page .inventario-resumen-entrada::before {
  background: #22c55e;
}

.inventario-transferencia-page .inventario-resumen-salida::before {
  background: #ef4444;
}

.inventario-transferencia-page .inventario-resumen-saldo::before {
  background: #8b5cf6;
}

.inventario-transferencia-page .inventario-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.inventario-transferencia-page .inventario-resumen-card h3 {
  font-size: 1.65rem;
  font-weight: 900;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.inventario-transferencia-page .inventario-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 600;
}

.inventario-transferencia-page .inventario-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.25rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.inventario-transferencia-page .inventario-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.inventario-transferencia-page .inventario-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.inventario-transferencia-page .inventario-card-header strong {
  font-size: 1.02rem;
  font-weight: 900;
}

.inventario-transferencia-page .inventario-card-header small {
  font-size: 0.86rem;
  line-height: 1.35;
}

.inventario-transferencia-page .inventario-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA
     ========================================================= */

.inventario-transferencia-page #dataTablaMovimientos {
  width: 100% !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

.inventario-transferencia-page #dataTablaMovimientos thead th {
  vertical-align: middle;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.inventario-transferencia-page #dataTablaMovimientos tbody td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  color: #334155;
  font-size: 0.84rem;
}

.inventario-transferencia-page #dataTablaMovimientos tbody tr {
  transition: background-color 0.18s ease;
}

.inventario-transferencia-page #dataTablaMovimientos tbody tr:hover {
  background-color: #f8fafc;
}

/* Columnas numéricas */
.inventario-transferencia-page #dataTablaMovimientos th:nth-child(5),
.inventario-transferencia-page #dataTablaMovimientos th:nth-child(6),
.inventario-transferencia-page #dataTablaMovimientos th:nth-child(7),
.inventario-transferencia-page #dataTablaMovimientos th:nth-child(8),
.inventario-transferencia-page #dataTablaMovimientos td:nth-child(5),
.inventario-transferencia-page #dataTablaMovimientos td:nth-child(6),
.inventario-transferencia-page #dataTablaMovimientos td:nth-child(7),
.inventario-transferencia-page #dataTablaMovimientos td:nth-child(8) {
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center !important;
}

/* =========================================================
     PRODUCTO
     ========================================================= */

.inventario-transferencia-page .inventario-product-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  width: 100%;
}

.inventario-transferencia-page .inventario-product-img-box {
  flex: 0 0 auto;
}

.inventario-transferencia-page .inventario-product-img {
  width: 50px !important;
  height: 50px !important;
  object-fit: cover;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 0.15rem;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.08);
}

.inventario-transferencia-page .inventario-product-info {
  min-width: 0;
  width: 100%;
}

.inventario-transferencia-page .inventario-product-name {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  font-size: 0.94rem;
  line-height: 1.28;
}

.inventario-transferencia-page .inventario-product-meta {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  color: #64748b;
  font-size: 0.8rem;
  font-weight: 700;
  margin-top: 0.28rem;
  line-height: 1.25;
}

.inventario-transferencia-page .inventario-product-type {
  margin-top: 0.35rem;
}

.inventario-transferencia-page .inventario-product-badge {
  display: inline-flex;
  align-items: center;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 900;
  white-space: nowrap;
  border: 1px solid transparent;
  line-height: 1;
}

.inventario-transferencia-page .inventario-product-normal {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

.inventario-transferencia-page .inventario-product-compuesto {
  background: #ede9fe;
  color: #7c3aed;
  border-color: #ddd6fe;
}

/* =========================================================
     DETALLES
     ========================================================= */

.inventario-transferencia-page .inventario-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  min-width: 0;
  width: 100%;
}

.inventario-transferencia-page .inventario-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.42rem;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #334155;
  word-break: normal;
  overflow-wrap: anywhere;
}

.inventario-transferencia-page .inventario-detail-item strong {
  color: #0f172a;
  font-weight: 900;
}

.inventario-transferencia-page .inventario-detail-icon {
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 7px;
  background: #eff6ff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  margin-top: 0.02rem;
}

.inventario-transferencia-page .inventario-icon-lote {
  background: #f0fdf4;
  color: #16a34a;
}

.inventario-transferencia-page .inventario-icon-bodega {
  background: #fff7ed;
  color: #ea580c;
}

.inventario-transferencia-page .inventario-icon-date {
  background: #eff6ff;
  color: #2563eb;
}

.inventario-transferencia-page .inventario-icon-doc {
  background: #f8fafc;
  color: #64748b;
}

/* =========================================================
     LOTE
     ========================================================= */

.inventario-transferencia-page .inventario-lote-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 900;
  white-space: nowrap;
  border: 1px solid transparent;
  max-width: 100%;
  line-height: 1;
}

.inventario-transferencia-page .inventario-lote-ok {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.inventario-transferencia-page .inventario-lote-empty {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

/* =========================================================
     NÚMEROS
     ========================================================= */

.inventario-transferencia-page .inventario-number-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0.42rem 0.58rem;
  font-size: 0.82rem;
  font-weight: 900;
  min-width: 58px;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1.1;
}

.inventario-transferencia-page .inventario-badge-anterior-ok {
  background: #f1f5f9;
  color: #334155;
  border-color: #cbd5e1;
}

.inventario-transferencia-page .inventario-badge-entrada-ok {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.inventario-transferencia-page .inventario-badge-salida-ok {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.inventario-transferencia-page .inventario-badge-saldo-ok {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.inventario-transferencia-page .inventario-badge-saldo-empty {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

.inventario-transferencia-page .inventario-badge-neutral {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

/* =========================================================
     FOOTER TABLA
     ========================================================= */

.inventario-transferencia-page .inventario-table-footer {
  background: #3498db;
  color: #ffffff;
  font-weight: 900;
}

.inventario-transferencia-page .inventario-table-footer td {
  color: #ffffff !important;
  font-size: 0.92rem;
  padding: 0.9rem 0.75rem !important;
  white-space: nowrap !important;
}

.inventario-transferencia-page .inventario-footer-label {
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-weight: 900;
}

/* =========================================================
     ZOOM IMAGEN
     ========================================================= */

.inventario-transferencia-page #dataTablaMovimientos .inventario-zoom-trigger,
.inventario-transferencia-page
  #dataTablaMovimientos
  .inventario-zoom-trigger
  img,
.inventario-transferencia-page #dataTablaMovimientos .iv-trigger,
.inventario-transferencia-page #dataTablaMovimientos .iv-trigger img {
  cursor: zoom-in !important;
}

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

@media (max-width: 1400px) {
  .inventario-transferencia-page #dataTablaMovimientos thead th {
    font-size: 0.78rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }

  .inventario-transferencia-page #dataTablaMovimientos tbody td {
    font-size: 0.8rem;
  }

  .inventario-transferencia-page .inventario-product-name {
    font-size: 0.88rem;
  }

  .inventario-transferencia-page .inventario-detail-item,
  .inventario-transferencia-page .inventario-product-meta {
    font-size: 0.76rem;
  }

  .inventario-transferencia-page .inventario-number-badge {
    min-width: 54px;
    font-size: 0.76rem;
    padding: 0.36rem 0.48rem;
  }

  .inventario-transferencia-page .inventario-lote-badge,
  .inventario-transferencia-page .inventario-product-badge {
    font-size: 0.72rem;
  }

  .inventario-transferencia-page .inventario-product-img {
    width: 44px !important;
    height: 44px !important;
  }

  .inventario-transferencia-page .inventario-detail-icon {
    width: 21px;
    height: 21px;
    min-width: 21px;
    font-size: 0.68rem;
  }
}

@media (max-width: 1200px) {
  .inventario-transferencia-page #dataTablaMovimientos {
    min-width: 980px;
  }

  .inventario-transferencia-page #dataTablaMovimientos thead th {
    font-size: 0.74rem;
    letter-spacing: 0.01em;
  }

  .inventario-transferencia-page .inventario-number-badge {
    min-width: 50px;
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .inventario-transferencia-page .inventario-resumen-card {
    min-height: 95px;
  }

  .inventario-transferencia-page .inventario-product-box {
    align-items: flex-start;
  }

  .inventario-transferencia-page #dataTablaMovimientos {
    min-width: 980px;
  }
}

/* =========================================================
     FIN INVENTARIO TRANSFERENCIA - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
   INICIO PRODUCTOS - DISEÑO PROFESIONAL
   SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
   ========================================================= */

/* =========================================================
   FILTROS
   ========================================================= */

.productos-page .productos-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.productos-page .productos-filtro-card .card-body {
  padding: 1.25rem 1.35rem;
}

.productos-page .productos-label-filter {
  font-weight: 800;
  color: #334155;
  letter-spacing: 0.02em;
  font-size: 0.84rem;
}

.productos-page .productos-search-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
  min-height: 44px;
}

.productos-page .productos-search-group .form-control {
  border-color: #dbe3ef;
  min-height: 44px;
  font-size: 0.92rem;
  font-weight: 600;
}

.productos-page .productos-search-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

.productos-page .productos-filtro-card .bootstrap-select.form-control {
  width: 100% !important;
}

.productos-page .productos-filtro-card .bootstrap-select > .dropdown-toggle {
  min-height: 44px;
  border-color: #dbe3ef !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-size: 0.92rem;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.productos-page
  .productos-filtro-card
  .bootstrap-select
  > .dropdown-toggle:focus,
.productos-page
  .productos-filtro-card
  .bootstrap-select.show
  > .dropdown-toggle {
  border-color: #3498db !important;
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14) !important;
}

/* =========================================================
   CARDS RESUMEN
   ========================================================= */

.productos-page .productos-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.productos-page .productos-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.productos-page .productos-resumen-registros::before {
  background: #3498db;
}

.productos-page .productos-resumen-activos::before {
  background: #22c55e;
}

.productos-page .productos-resumen-isv::before {
  background: #f59e0b;
}

.productos-page .productos-resumen-venta::before {
  background: #8b5cf6;
}

.productos-page .productos-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
}

.productos-page .productos-resumen-card h3 {
  font-size: 1.65rem;
  font-weight: 900;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.productos-page .productos-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 600;
}

.productos-page .productos-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.25rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
   CARD TABLA
   ========================================================= */

.productos-page .productos-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.productos-page .productos-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.productos-page .productos-card-header strong {
  font-size: 1.02rem;
  font-weight: 900;
}

.productos-page .productos-card-header small {
  font-size: 0.86rem;
  line-height: 1.35;
}

.productos-page .productos-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
   TABLA PRODUCTOS
   ========================================================= */

.productos-page #dataTableProductos {
  width: 100% !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

.productos-page #dataTableProductos thead th {
  vertical-align: middle;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0.03em;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.productos-page #dataTableProductos tbody td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  color: #334155;
  font-size: 0.84rem;
}

.productos-page #dataTableProductos tbody tr {
  transition: background-color 0.18s ease;
}

.productos-page #dataTableProductos tbody tr:hover {
  background-color: #f8fafc;
}

/* =========================================================
   PRODUCTO
   ========================================================= */

.productos-page .productos-product-box {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  width: 100%;
}

.productos-page .productos-product-img-box {
  flex: 0 0 auto;
}

.productos-page .productos-product-img {
  width: 54px !important;
  height: 54px !important;
  object-fit: cover;
  border-radius: 10px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  padding: 0.15rem;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.08);
}

.productos-page .productos-product-info {
  min-width: 0;
  width: 100%;
}

.productos-page .productos-product-name {
  margin: 0;
  color: #0f172a;
  font-weight: 900;
  font-size: 0.94rem;
  line-height: 1.28;
}

.productos-page .productos-product-desc {
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 0.28rem;
  line-height: 1.35;
}

.productos-page .productos-product-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 700;
  margin-top: 0.35rem;
  line-height: 1.25;
}

.productos-page .productos-product-meta span {
  display: inline-flex;
  align-items: center;
  border-radius: 99px;
  padding: 0.25rem 0.52rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  white-space: nowrap;
}

.productos-page .productos-detail-btn {
  margin-top: 0.45rem;
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
  font-size: 0.76rem;
  font-weight: 800;
  padding: 0.32rem 0.58rem;
}

.productos-page .productos-detail-btn:hover {
  background: #dbeafe;
  color: #1e40af;
}

/* =========================================================
   DETALLES
   ========================================================= */

.productos-page .productos-detail-list {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  min-width: 0;
  width: 100%;
}

.productos-page .productos-detail-item {
  display: flex;
  align-items: flex-start;
  gap: 0.42rem;
  font-size: 0.82rem;
  line-height: 1.35;
  color: #334155;
  word-break: normal;
  overflow-wrap: anywhere;
}

.productos-page .productos-detail-item strong {
  color: #0f172a;
  font-weight: 900;
}

.productos-page .productos-detail-icon {
  width: 22px;
  height: 22px;
  min-width: 22px;
  border-radius: 7px;
  background: #eff6ff;
  color: #2563eb;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  margin-top: 0.02rem;
}

.productos-page .productos-icon-compra {
  background: #f0fdf4;
  color: #16a34a;
}

.productos-page .productos-icon-venta {
  background: #eff6ff;
  color: #2563eb;
}

.productos-page .productos-icon-ganancia {
  background: #fefce8;
  color: #ca8a04;
}

.productos-page .productos-icon-mayoreo {
  background: #f5f3ff;
  color: #7c3aed;
}

.productos-page .productos-icon-isv {
  background: #fff7ed;
  color: #ea580c;
}

.productos-page .productos-icon-restaurante {
  background: #fdf2f8;
  color: #db2777;
}

.productos-page .productos-icon-stock {
  background: #f8fafc;
  color: #64748b;
}

.productos-page .productos-icon-almacen {
  background: #fff7ed;
  color: #ea580c;
}

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

.productos-page .productos-money-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0.34rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 900;
  min-width: 86px;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1.1;
}

.productos-page .productos-money-compra {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.productos-page .productos-money-venta {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.productos-page .productos-money-ganancia {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.productos-page .productos-money-mayoreo {
  background: #ede9fe;
  color: #7c3aed;
  border-color: #ddd6fe;
}

.productos-page .productos-money-neutral {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

/* =========================================================
   BADGES ISV / CONTROL / ESTADO
   ========================================================= */

.productos-page .productos-isv-badge,
.productos-page .productos-status-badge,
.productos-page .productos-control-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.28rem;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 900;
  white-space: nowrap;
  border: 1px solid transparent;
  max-width: 100%;
  line-height: 1;
}

.productos-page .productos-isv-si {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.productos-page .productos-isv-no {
  background: #f1f5f9;
  color: #475569;
  border-color: #e2e8f0;
}

.productos-page .productos-status-active {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.productos-page .productos-status-inactive {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.productos-page .productos-control-badge {
  background: #f8fafc;
  color: #334155;
  border-color: #e2e8f0;
  min-width: 48px;
}

/* =========================================================
   MODAL DETALLE
   ========================================================= */

.productos-modal-detalle {
  font-size: 0.92rem;
  color: #334155;
}

.productos-modal-detalle strong {
  color: #0f172a;
}

/* =========================================================
   ZOOM IMAGEN
   ========================================================= */

.productos-page #dataTableProductos .productos-zoom-trigger,
.productos-page #dataTableProductos .productos-zoom-trigger img,
.productos-page #dataTableProductos .iv-trigger,
.productos-page #dataTableProductos .iv-trigger img {
  cursor: zoom-in !important;
}

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

@media (max-width: 1400px) {
  .productos-page #dataTableProductos thead th {
    font-size: 0.78rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }

  .productos-page #dataTableProductos tbody td {
    font-size: 0.8rem;
  }

  .productos-page .productos-product-name {
    font-size: 0.88rem;
  }

  .productos-page .productos-detail-item,
  .productos-page .productos-product-desc,
  .productos-page .productos-product-meta {
    font-size: 0.76rem;
  }

  .productos-page .productos-money-badge {
    min-width: 78px;
    font-size: 0.74rem;
    padding: 0.32rem 0.48rem;
  }

  .productos-page .productos-isv-badge,
  .productos-page .productos-status-badge,
  .productos-page .productos-control-badge {
    font-size: 0.72rem;
  }

  .productos-page .productos-product-img {
    width: 48px !important;
    height: 48px !important;
  }

  .productos-page .productos-detail-icon {
    width: 21px;
    height: 21px;
    min-width: 21px;
    font-size: 0.68rem;
  }
}

@media (max-width: 1200px) {
  .productos-page #dataTableProductos {
    min-width: 980px;
  }

  .productos-page #dataTableProductos thead th {
    font-size: 0.74rem;
    letter-spacing: 0.01em;
  }

  .productos-page .productos-money-badge {
    min-width: 72px;
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .productos-page .productos-resumen-card {
    min-height: 95px;
  }

  .productos-page .productos-product-box {
    align-items: flex-start;
  }

  .productos-page #dataTableProductos {
    min-width: 980px;
  }
}

/* =========================================================
   FIN PRODUCTOS - DISEÑO PROFESIONAL
   SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
   ========================================================= */

/* =========================================================
   INICIO INGRESOS CONTABILIDAD - DISEÑO PROFESIONAL
   SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
   NO USA: .acciones-dropdown, .btn-acciones, .acciones-menu
   ========================================================= */

/* =========================================================
   CONTENEDOR GENERAL
   ========================================================= */

.ingresos-page {
  color: #334155;
}

/* =========================================================
     FILTROS
     ========================================================= */

.ingresos-page .ingresos-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.ingresos-page .ingresos-filtro-card .card-body {
  padding: 1.25rem 1.35rem;
}

.ingresos-page .ingresos-label-filter {
  font-weight: 700;
  color: #334155;
  letter-spacing: 0.02em;
  font-size: 0.84rem;
}

.ingresos-page .ingresos-input-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
  min-height: 44px;
}

.ingresos-page .ingresos-input-group .form-control {
  border-color: #dbe3ef;
  min-height: 44px;
  font-size: 0.92rem;
  font-weight: 500;
}

.ingresos-page .ingresos-input-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

.ingresos-page .ingresos-filtro-card .bootstrap-select.form-control {
  width: 100% !important;
}

.ingresos-page .ingresos-filtro-card .bootstrap-select > .dropdown-toggle {
  min-height: 44px;
  border-color: #dbe3ef !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.ingresos-page .ingresos-filtro-card .bootstrap-select > .dropdown-toggle:focus,
.ingresos-page .ingresos-filtro-card .bootstrap-select.show > .dropdown-toggle {
  border-color: #3498db !important;
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14) !important;
}

.ingresos-page .ingresos-filtro-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.ingresos-page .ingresos-btn-filtrar,
.ingresos-page .ingresos-btn-limpiar {
  min-height: 42px;
  border-radius: 9px;
  font-weight: 700;
  padding-left: 1rem;
  padding-right: 1rem;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.ingresos-page .ingresos-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.ingresos-page .ingresos-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.ingresos-page .ingresos-resumen-registros::before {
  background: #3498db;
}

.ingresos-page .ingresos-resumen-subtotal::before {
  background: #22c55e;
}

.ingresos-page .ingresos-resumen-impuesto::before {
  background: #f59e0b;
}

.ingresos-page .ingresos-resumen-total::before {
  background: #8b5cf6;
}

.ingresos-page .ingresos-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.ingresos-page .ingresos-resumen-card h3 {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.ingresos-page .ingresos-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 500;
}

.ingresos-page .ingresos-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.25rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.ingresos-page .ingresos-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.ingresos-page .ingresos-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.ingresos-page .ingresos-card-header strong {
  font-size: 1.02rem;
  font-weight: 700;
}

.ingresos-page .ingresos-card-header small {
  font-size: 0.86rem;
  line-height: 1.35;
}

.ingresos-page .ingresos-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA INGRESOS
     ========================================================= */

.ingresos-page #dataTableIngresosContabilidad {
  width: 100% !important;
  min-width: 1720px !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

.ingresos-page #dataTableIngresosContabilidad thead th {
  vertical-align: middle;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.ingresos-page #dataTableIngresosContabilidad tbody td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  color: #334155;
  font-size: 0.84rem;
  font-weight: 400;
}

.ingresos-page #dataTableIngresosContabilidad tbody tr {
  transition: background-color 0.18s ease;
}

.ingresos-page #dataTableIngresosContabilidad tbody tr:hover {
  background-color: #f8fafc;
}

.ingresos-page #dataTableIngresosContabilidad tfoot td {
  vertical-align: middle;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Anchos reales por columna - INGRESOS */
.ingresos-page #dataTableIngresosContabilidad th:nth-child(1),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(1) {
  width: 125px !important;
  min-width: 125px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(2),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(2) {
  width: 150px !important;
  min-width: 150px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(3),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(3) {
  width: 150px !important;
  min-width: 150px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(4),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(4) {
  width: 100px !important;
  min-width: 100px !important;
  text-align: center;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(5),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(5) {
  width: 145px !important;
  min-width: 145px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(6),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(6) {
  width: 160px !important;
  min-width: 160px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(7),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(7) {
  width: 170px !important;
  min-width: 170px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(8),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(8) {
  width: 140px !important;
  min-width: 140px !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(9),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(9),
.ingresos-page #dataTableIngresosContabilidad th:nth-child(10),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(10),
.ingresos-page #dataTableIngresosContabilidad th:nth-child(11),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(11),
.ingresos-page #dataTableIngresosContabilidad th:nth-child(12),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(12) {
  width: 115px !important;
  min-width: 115px !important;
  text-align: right;
  padding-left: 0.7rem !important;
  padding-right: 0.7rem !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(13),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(13) {
  width: 230px !important;
  min-width: 230px !important;
  padding-left: 1rem !important;
  padding-right: 1rem !important;
}

.ingresos-page #dataTableIngresosContabilidad th:nth-child(14),
.ingresos-page #dataTableIngresosContabilidad td:nth-child(14) {
  width: 120px !important;
  min-width: 120px !important;
  text-align: center;
  padding-left: 0.7rem !important;
  padding-right: 0.7rem !important;
}

/* =========================================================
     CELDAS DE INFORMACIÓN
     ========================================================= */

.ingresos-page .ingresos-info-box {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  min-width: 0;
  width: 100%;
}

.ingresos-page .ingresos-info-main {
  color: #0f172a;
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.ingresos-page .ingresos-info-muted {
  color: #64748b;
  font-size: 0.76rem;
  font-weight: 400;
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.ingresos-page .ingresos-info-chip {
  display: inline-flex;
  align-items: center;
  width: auto;
  max-width: 100%;
  border-radius: 99px;
  padding: 0.24rem 0.55rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 0.76rem;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ingresos-page .ingresos-info-chip i {
  flex: 0 0 auto;
}

.ingresos-page .ingresos-observacion {
  color: #475569;
  font-size: 0.8rem;
  font-weight: 400;
  line-height: 1.35;
  max-width: 100%;
  overflow-wrap: anywhere;
}

/* =========================================================
     BADGES TIPO / ESTADO
     ========================================================= */

.ingresos-page .ingresos-type-badge,
.ingresos-page .ingresos-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.28rem;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 600;
  white-space: nowrap;
  border: 1px solid transparent;
  max-width: 100%;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ingresos-page .ingresos-type-badge i,
.ingresos-page .ingresos-status-badge i {
  flex: 0 0 auto;
}

.ingresos-page .ingresos-type-ventas {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.ingresos-page .ingresos-type-manual {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.ingresos-page .ingresos-type-otro {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

.ingresos-page .ingresos-status-active {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.ingresos-page .ingresos-status-inactive {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

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

.ingresos-page .ingresos-money-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0.34rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 600;
  min-width: 88px;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ingresos-page .ingresos-money-subtotal {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.ingresos-page .ingresos-money-impuesto {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.ingresos-page .ingresos-money-descuento {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.ingresos-page .ingresos-money-total {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.ingresos-page .ingresos-money-neutral {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

/* =========================================================
     FOOTER
     ========================================================= */

.ingresos-page .ingresos-card-footer {
  background: #ffffff;
  border-top: 1px solid rgba(15, 23, 42, 0.07);
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 500;
}

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

@media (max-width: 1400px) {
  .ingresos-page #dataTableIngresosContabilidad {
    min-width: 1720px !important;
  }

  .ingresos-page #dataTableIngresosContabilidad thead th {
    font-size: 0.78rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }

  .ingresos-page #dataTableIngresosContabilidad tbody td {
    font-size: 0.8rem;
  }

  .ingresos-page .ingresos-info-main {
    font-size: 0.86rem;
  }

  .ingresos-page .ingresos-info-muted,
  .ingresos-page .ingresos-info-chip,
  .ingresos-page .ingresos-observacion {
    font-size: 0.74rem;
  }

  .ingresos-page .ingresos-money-badge {
    min-width: 82px;
    font-size: 0.74rem;
    padding: 0.32rem 0.48rem;
  }

  .ingresos-page .ingresos-type-badge,
  .ingresos-page .ingresos-status-badge {
    font-size: 0.72rem;
  }
}

@media (max-width: 1200px) {
  .ingresos-page #dataTableIngresosContabilidad {
    min-width: 1720px !important;
  }

  .ingresos-page #dataTableIngresosContabilidad thead th {
    font-size: 0.74rem;
    letter-spacing: 0.01em;
  }

  .ingresos-page .ingresos-money-badge {
    min-width: 80px;
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .ingresos-page .ingresos-resumen-card {
    min-height: 95px;
  }

  .ingresos-page .ingresos-filtro-actions {
    justify-content: stretch;
  }

  .ingresos-page .ingresos-btn-filtrar,
  .ingresos-page .ingresos-btn-limpiar {
    width: 100%;
  }

  .ingresos-page #dataTableIngresosContabilidad {
    min-width: 1720px !important;
  }
}

/* =========================================================
     FIN INGRESOS CONTABILIDAD - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
     INICIO EGRESOS CONTABILIDAD - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     NO USA: .acciones-dropdown, .btn-acciones, .acciones-menu
     ========================================================= */

.egresos-page {
  color: #334155;
}

/* =========================================================
     FILTROS
     ========================================================= */

.egresos-page .egresos-filtro-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.egresos-page .egresos-filtro-card .card-body {
  padding: 1.25rem 1.35rem;
}

.egresos-page .egresos-label-filter {
  font-weight: 700;
  color: #334155;
  letter-spacing: 0.02em;
  font-size: 0.84rem;
}

.egresos-page .egresos-input-group .input-group-text {
  background: #f8fafc;
  color: #64748b;
  border-color: #dbe3ef;
  min-height: 44px;
}

.egresos-page .egresos-input-group .form-control {
  border-color: #dbe3ef;
  min-height: 44px;
  font-size: 0.92rem;
  font-weight: 500;
}

.egresos-page .egresos-input-group .form-control:focus {
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14);
  border-color: #3498db;
}

.egresos-page .egresos-filtro-card .bootstrap-select.form-control {
  width: 100% !important;
}

.egresos-page .egresos-filtro-card .bootstrap-select > .dropdown-toggle {
  min-height: 44px;
  border-color: #dbe3ef !important;
  background: #ffffff !important;
  color: #334155 !important;
  font-size: 0.92rem;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.03);
}

.egresos-page .egresos-filtro-card .bootstrap-select > .dropdown-toggle:focus,
.egresos-page .egresos-filtro-card .bootstrap-select.show > .dropdown-toggle {
  border-color: #3498db !important;
  box-shadow: 0 0 0 0.15rem rgba(52, 152, 219, 0.14) !important;
}

.egresos-page .egresos-filtro-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 0.65rem;
  flex-wrap: wrap;
}

.egresos-page .egresos-btn-filtrar,
.egresos-page .egresos-btn-limpiar {
  min-height: 42px;
  border-radius: 9px;
  font-weight: 700;
  padding-left: 1rem;
  padding-right: 1rem;
}

/* =========================================================
     CARDS RESUMEN
     ========================================================= */

.egresos-page .egresos-resumen-card {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.06);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.04);
  padding: 1.15rem 1.25rem;
  min-height: 105px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.egresos-page .egresos-resumen-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 4px;
  border-radius: 0 8px 8px 0;
}

.egresos-page .egresos-resumen-registros::before {
  background: #3498db;
}

.egresos-page .egresos-resumen-subtotal::before {
  background: #22c55e;
}

.egresos-page .egresos-resumen-impuesto::before {
  background: #f59e0b;
}

.egresos-page .egresos-resumen-total::before {
  background: #ef4444;
}

.egresos-page .egresos-resumen-label {
  color: #64748b;
  text-transform: uppercase;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.egresos-page .egresos-resumen-card h3 {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 0.35rem 0 0.2rem;
  color: #0f172a;
  line-height: 1;
}

.egresos-page .egresos-resumen-card p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 500;
}

.egresos-page .egresos-resumen-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #334155;
  font-size: 1.25rem;
  border: 1px solid rgba(15, 23, 42, 0.06);
}

/* =========================================================
     CARD TABLA
     ========================================================= */

.egresos-page .egresos-table-card {
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15, 23, 42, 0.04);
}

.egresos-page .egresos-card-header {
  background: #ffffff;
  color: #0f172a;
  border-bottom: 1px solid rgba(15, 23, 42, 0.07);
  padding: 1rem 1.25rem;
}

.egresos-page .egresos-card-header strong {
  font-size: 1.02rem;
  font-weight: 700;
}

.egresos-page .egresos-card-header small {
  font-size: 0.86rem;
  line-height: 1.35;
}

.egresos-page .egresos-table-responsive {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 0.25rem;
}

/* =========================================================
     TABLA EGRESOS
     ========================================================= */

.egresos-page #dataTableGastosContabilidad {
  width: 100% !important;
  min-width: 1900px !important;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
}

.egresos-page #dataTableGastosContabilidad thead th {
  vertical-align: middle;
  white-space: nowrap !important;
  word-break: normal !important;
  overflow-wrap: normal !important;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.03em;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}

.egresos-page #dataTableGastosContabilidad tbody td {
  white-space: normal !important;
  word-break: normal;
  overflow-wrap: anywhere;
  vertical-align: middle;
  padding-top: 0.9rem;
  padding-bottom: 0.9rem;
  color: #334155;
  font-size: 0.84rem;
  font-weight: 400;
}

.egresos-page #dataTableGastosContabilidad tbody tr {
  transition: background-color 0.18s ease;
}

.egresos-page #dataTableGastosContabilidad tbody tr:hover {
  background-color: #f8fafc;
}

.egresos-page #dataTableGastosContabilidad tfoot td {
  vertical-align: middle;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}

/* Anchos reales por columna - EGRESOS */
.egresos-page #dataTableGastosContabilidad th:nth-child(1),
.egresos-page #dataTableGastosContabilidad td:nth-child(1) {
  width: 125px !important;
  min-width: 125px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(2),
.egresos-page #dataTableGastosContabilidad td:nth-child(2) {
  width: 155px !important;
  min-width: 155px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(3),
.egresos-page #dataTableGastosContabilidad td:nth-child(3) {
  width: 105px !important;
  min-width: 105px !important;
  text-align: center;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(4),
.egresos-page #dataTableGastosContabilidad td:nth-child(4) {
  width: 160px !important;
  min-width: 160px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(5),
.egresos-page #dataTableGastosContabilidad td:nth-child(5) {
  width: 145px !important;
  min-width: 145px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(6),
.egresos-page #dataTableGastosContabilidad td:nth-child(6) {
  width: 165px !important;
  min-width: 165px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(7),
.egresos-page #dataTableGastosContabilidad td:nth-child(7) {
  width: 170px !important;
  min-width: 170px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(8),
.egresos-page #dataTableGastosContabilidad td:nth-child(8) {
  width: 145px !important;
  min-width: 145px !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(9),
.egresos-page #dataTableGastosContabilidad td:nth-child(9),
.egresos-page #dataTableGastosContabilidad th:nth-child(10),
.egresos-page #dataTableGastosContabilidad td:nth-child(10),
.egresos-page #dataTableGastosContabilidad th:nth-child(11),
.egresos-page #dataTableGastosContabilidad td:nth-child(11),
.egresos-page #dataTableGastosContabilidad th:nth-child(12),
.egresos-page #dataTableGastosContabilidad td:nth-child(12),
.egresos-page #dataTableGastosContabilidad th:nth-child(13),
.egresos-page #dataTableGastosContabilidad td:nth-child(13) {
  width: 115px !important;
  min-width: 115px !important;
  text-align: right;
  padding-left: 0.7rem !important;
  padding-right: 0.7rem !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(14),
.egresos-page #dataTableGastosContabilidad td:nth-child(14) {
  width: 250px !important;
  min-width: 250px !important;
  padding-left: 1.15rem !important;
  padding-right: 1.15rem !important;
}

.egresos-page #dataTableGastosContabilidad th:nth-child(15),
.egresos-page #dataTableGastosContabilidad td:nth-child(15) {
  width: 125px !important;
  min-width: 125px !important;
  text-align: center;
  padding-left: 0.7rem !important;
  padding-right: 0.7rem !important;
}

/* =========================================================
     CELDAS DE INFORMACIÓN
     ========================================================= */

.egresos-page .egresos-info-box {
  display: flex;
  flex-direction: column;
  gap: 0.22rem;
  min-width: 0;
  width: 100%;
}

.egresos-page .egresos-info-main {
  color: #0f172a;
  font-weight: 600;
  font-size: 0.9rem;
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.egresos-page .egresos-info-muted {
  color: #64748b;
  font-size: 0.76rem;
  font-weight: 400;
  line-height: 1.25;
  max-width: 100%;
  overflow-wrap: anywhere;
}

.egresos-page .egresos-info-chip {
  display: inline-flex;
  align-items: center;
  width: auto;
  max-width: 100%;
  border-radius: 99px;
  padding: 0.24rem 0.55rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
  font-size: 0.76rem;
  font-weight: 500;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.egresos-page .egresos-info-chip i {
  flex: 0 0 auto;
}

.egresos-page .egresos-factura-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.45rem;
  width: 100%;
  min-width: 0;
}

.egresos-page .egresos-factura-box span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.egresos-page .egresos-observacion {
  color: #475569;
  font-size: 0.8rem;
  font-weight: 400;
  line-height: 1.35;
  max-width: 100%;
  overflow-wrap: anywhere;
}

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

.egresos-page .egresos-status-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.28rem;
  border-radius: 99px;
  padding: 0.28rem 0.58rem;
  font-size: 0.76rem;
  font-weight: 600;
  white-space: nowrap;
  border: 1px solid transparent;
  max-width: 100%;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
}

.egresos-page .egresos-status-badge i {
  flex: 0 0 auto;
}

.egresos-page .egresos-status-active {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.egresos-page .egresos-status-inactive {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

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

.egresos-page .egresos-money-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0.34rem 0.55rem;
  font-size: 0.78rem;
  font-weight: 600;
  min-width: 88px;
  max-width: 100%;
  font-variant-numeric: tabular-nums;
  border: 1px solid transparent;
  white-space: nowrap;
  line-height: 1.1;
  overflow: hidden;
  text-overflow: ellipsis;
}

.egresos-page .egresos-money-subtotal {
  background: #dcfce7;
  color: #166534;
  border-color: #bbf7d0;
}

.egresos-page .egresos-money-impuesto {
  background: #fef3c7;
  color: #92400e;
  border-color: #fde68a;
}

.egresos-page .egresos-money-descuento,
.egresos-page .egresos-money-nc {
  background: #fee2e2;
  color: #991b1b;
  border-color: #fecaca;
}

.egresos-page .egresos-money-total {
  background: #dbeafe;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.egresos-page .egresos-money-neutral {
  background: #f8fafc;
  color: #64748b;
  border-color: #e2e8f0;
}

/* =========================================================
     FOOTER
     ========================================================= */

.egresos-page .egresos-card-footer {
  background: #ffffff;
  border-top: 1px solid rgba(15, 23, 42, 0.07);
  color: #64748b;
  font-size: 0.82rem;
  font-weight: 500;
}

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

@media (max-width: 1400px) {
  .egresos-page #dataTableGastosContabilidad {
    min-width: 1900px !important;
  }

  .egresos-page #dataTableGastosContabilidad thead th {
    font-size: 0.78rem;
    padding-left: 0.35rem;
    padding-right: 0.35rem;
  }

  .egresos-page #dataTableGastosContabilidad tbody td {
    font-size: 0.8rem;
  }

  .egresos-page .egresos-info-main {
    font-size: 0.86rem;
  }

  .egresos-page .egresos-info-muted,
  .egresos-page .egresos-info-chip,
  .egresos-page .egresos-observacion {
    font-size: 0.74rem;
  }

  .egresos-page .egresos-money-badge {
    min-width: 82px;
    font-size: 0.74rem;
    padding: 0.32rem 0.48rem;
  }

  .egresos-page .egresos-status-badge {
    font-size: 0.72rem;
  }
}

@media (max-width: 1200px) {
  .egresos-page #dataTableGastosContabilidad {
    min-width: 1900px !important;
  }

  .egresos-page #dataTableGastosContabilidad thead th {
    font-size: 0.74rem;
    letter-spacing: 0.01em;
  }

  .egresos-page .egresos-money-badge {
    min-width: 80px;
    font-size: 0.72rem;
  }
}

@media (max-width: 768px) {
  .egresos-page .egresos-resumen-card {
    min-height: 95px;
  }

  .egresos-page .egresos-filtro-actions {
    justify-content: stretch;
  }

  .egresos-page .egresos-btn-filtrar,
  .egresos-page .egresos-btn-limpiar {
    width: 100%;
  }

  .egresos-page #dataTableGastosContabilidad {
    min-width: 1900px !important;
  }
}

/* =========================================================
     FIN EGRESOS CONTABILIDAD - DISEÑO PROFESIONAL
     SOLO DISEÑO VISUAL - NO TOCA BOTÓN DE ACCIONES
     ========================================================= */

/* =========================================================
   INICIO CUADRE DE CAJA - AJUSTE VISUAL Y LECTURA
   ========================================================= */

#modalCuadreDiaCaja .modal-dialog {
  max-width: 1100px !important;
}

#modalCuadreDiaCaja .modal-content {
  border: none !important;
  border-radius: 14px !important;
  overflow: hidden !important;
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.3) !important;
  max-height: calc(100vh - 32px) !important;
}

#modalCuadreDiaCaja .modal-header {
  background: linear-gradient(135deg, #1f3347 0%, #0f1f2f 100%) !important;
  color: #ffffff !important;
  padding: 1.15rem 1.35rem !important;
  padding-top: 1.15rem !important;
  min-height: auto !important;
  border-bottom: none !important;
  position: relative !important;
  display: flex !important;
  align-items: flex-start !important;
  justify-content: space-between !important;
}

#modalCuadreDiaCaja .modal-header::after {
  content: "" !important;
  position: absolute !important;
  left: 0 !important;
  right: 0 !important;
  bottom: 0 !important;
  height: 4px !important;
  background: linear-gradient(90deg, #2ecc71, #00c2ff, #2ecc71) !important;
  z-index: 1 !important;
}

#modalCuadreDiaCaja .modal-title {
  color: #ffffff !important;
  font-size: 1.35rem !important;
  font-weight: 800 !important;
  line-height: 1.25 !important;
  width: auto !important;
  padding-right: 3rem !important;
  margin: 0 !important;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25) !important;
}

#modalCuadreDiaCaja #cd_contexto_caja {
  color: rgba(255, 255, 255, 0.78) !important;
  font-size: 0.86rem !important;
  font-weight: 600 !important;
  margin-top: 0.35rem !important;
  display: block !important;
}

#modalCuadreDiaCaja .modal-header .close {
  position: absolute !important;
  top: 0.85rem !important;
  right: 1rem !important;
  z-index: 3 !important;
  margin: 0 !important;
  padding: 0.35rem 0.55rem !important;
  color: #ffffff !important;
  opacity: 0.95 !important;
  font-size: 1.7rem !important;
  line-height: 1 !important;
}

#modalCuadreDiaCaja .modal-header .close:hover {
  color: #ffdddd !important;
  opacity: 1 !important;
  transform: rotate(90deg) !important;
}

#modalCuadreDiaCaja .modal-body {
  padding: 1.35rem !important;
  background: #ffffff !important;
}

#modalCuadreDiaCaja .alert-info {
  background: #eef6ff !important;
  color: #12376b !important;
  border: 1px solid #b8d8ff !important;
  border-radius: 10px !important;
  font-size: 0.95rem !important;
}

#modalCuadreDiaCaja .card {
  border: 1px solid #e5e7eb !important;
  border-radius: 10px !important;
  overflow: hidden !important;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.07) !important;
}

#modalCuadreDiaCaja .card-header {
  background: #f8fafc !important;
  color: #111827 !important;
  border-bottom: 1px solid #e5e7eb !important;
  padding: 0.85rem 1rem !important;
  font-size: 1rem !important;
}

#modalCuadreDiaCaja .card-body {
  padding: 1rem !important;
}

#modalCuadreDiaCaja .card-body h4 {
  font-size: 1.45rem !important;
  font-weight: 800 !important;
  margin-top: 0.35rem !important;
}

#modalCuadreDiaCaja .card-body small {
  color: #374151 !important;
  font-size: 0.82rem !important;
  line-height: 1.55 !important;
}

#modalCuadreDiaCaja table th,
#modalCuadreDiaCaja table td {
  vertical-align: middle !important;
  font-size: 0.95rem !important;
}

#modalCuadreDiaCaja table th {
  color: #1f2937 !important;
  font-weight: 800 !important;
}

#modalCuadreDiaCaja table td {
  color: #111827 !important;
}

#modalCuadreDiaCaja #cd_tabla_gastos th,
#modalCuadreDiaCaja #cd_tabla_inversiones th {
  background: #f8fafc !important;
  border-bottom: 2px solid #e5e7eb !important;
}

#modalCuadreDiaCaja #cd_resumen_formula .alert {
  background: #fff7ed !important;
  color: #7c2d12 !important;
  border: 1px solid #fdba74 !important;
  border-radius: 10px !important;
  font-size: 0.95rem !important;
}

#modalCuadreDiaCaja .modal-footer {
  background: #f8fafc !important;
  border-top: 1px solid #e5e7eb !important;
  padding: 1rem 1.25rem !important;
  position: sticky !important;
  bottom: 0 !important;
  z-index: 10 !important;
}

#modalCuadreDiaCaja .modal-footer .btn {
  min-width: 120px !important;
  height: 38px !important;
  font-weight: 700 !important;
}

@media (max-width: 768px) {
  #modalCuadreDiaCaja .modal-dialog {
    margin: 0.5rem !important;
    max-width: calc(100% - 1rem) !important;
  }

  #modalCuadreDiaCaja .modal-header {
    padding: 1rem !important;
    padding-top: 1rem !important;
  }

  #modalCuadreDiaCaja .modal-title {
    font-size: 1.1rem !important;
    padding-right: 2.5rem !important;
  }

  #modalCuadreDiaCaja .modal-body {
    padding: 1rem !important;
  }

  #modalCuadreDiaCaja .card-body h4 {
    font-size: 1.2rem !important;
  }

  #modalCuadreDiaCaja .modal-footer {
    flex-wrap: wrap !important;
    gap: 0.5rem !important;
  }

  #modalCuadreDiaCaja .modal-footer .btn {
    width: 100% !important;
    margin: 0 !important;
  }
}

/* =========================================================
   FIN CUADRE DE CAJA - AJUSTE VISUAL Y LECTURA
   ========================================================= */

/* =========================================================
   INICIO MODAL GLOBAL ÚNICO: VISTA PREVIA DE DOCUMENTOS
   Aislado para no afectar otros modales del sistema
========================================================= */

#modalPreviewDocumento {
  padding-right: 0 !important;
  z-index: 1065;
}

#modalPreviewDocumento .modal-documento-preview-dialog {
  width: calc(100vw - 140px);
  max-width: calc(100vw - 140px);
  height: calc(100vh - 120px);
  max-height: calc(100vh - 120px);
  margin: 60px auto;
  display: flex;
  align-items: center;
  justify-content: center;
}

#modalPreviewDocumento .modal-documento-preview-content {
  width: 100%;
  height: 100%;
  max-height: 100%;
  border: 0;
  border-radius: 14px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
}

#modalPreviewDocumento .modal-documento-preview-header {
  height: 68px;
  min-height: 68px;
  flex: 0 0 68px;
  padding: 0 20px;
  background: #102033;
  color: #ffffff;
  border-bottom: 3px solid #22d3ee;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

#modalPreviewDocumento .modal-documento-preview-title-wrap {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

#modalPreviewDocumento .modal-documento-preview-icon {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
}

#modalPreviewDocumento .modal-documento-preview-icon i {
  font-size: 16px;
  color: #ffffff;
}

#modalPreviewDocumento .modal-documento-preview-title {
  margin: 0;
  padding: 0;
  color: #ffffff;
  font-size: 17px;
  font-weight: 800;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

#modalPreviewDocumento .modal-documento-preview-title i {
  color: #ffffff;
}

#modalPreviewDocumento .modal-documento-preview-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  flex: 0 0 auto;
}

#modalPreviewDocumento .modal-documento-preview-btn {
  height: 38px;
  min-height: 38px;
  padding: 0 14px;
  border: 0;
  border-radius: 10px;
  outline: none !important;
  box-shadow: none !important;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  text-decoration: none !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  white-space: nowrap;
}

#modalPreviewDocumento .modal-documento-preview-btn-print {
  background: #2563eb;
  color: #ffffff !important;
}

#modalPreviewDocumento .modal-documento-preview-btn-print:hover,
#modalPreviewDocumento .modal-documento-preview-btn-print:focus {
  background: #1d4ed8;
  color: #ffffff !important;
}

#modalPreviewDocumento .modal-documento-preview-btn-open {
  background: #0ea5e9;
  color: #ffffff !important;
}

#modalPreviewDocumento .modal-documento-preview-btn-open:hover,
#modalPreviewDocumento .modal-documento-preview-btn-open:focus {
  background: #0284c7;
  color: #ffffff !important;
}

#modalPreviewDocumento .modal-documento-preview-btn-close {
  width: 38px;
  min-width: 38px;
  padding: 0;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff !important;
  font-size: 16px;
}

#modalPreviewDocumento .modal-documento-preview-btn-close:hover,
#modalPreviewDocumento .modal-documento-preview-btn-close:focus {
  background: #ef4444;
  color: #ffffff !important;
}

#modalPreviewDocumento .modal-documento-preview-body {
  position: relative;
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  height: calc(100% - 68px);
  padding: 0;
  margin: 0;
  background: #e5e7eb;
  overflow: hidden;
}

#modalPreviewDocumento .modal-documento-preview-iframe {
  width: 100%;
  height: 100%;
  min-height: 100%;
  border: 0;
  padding: 0;
  margin: 0;
  display: block;
  background: #f3f4f6;
}

/* =========================================================
   LOADING DEL MODAL DOCUMENTO
========================================================= */

#modalPreviewDocumento .modal-documento-preview-loading {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 10;
  background: rgba(229, 231, 235, 0.72);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#modalPreviewDocumento .modal-documento-preview-loading.is-active {
  display: flex;
}

#modalPreviewDocumento .modal-documento-preview-loading-card {
  width: 280px;
  max-width: 100%;
  padding: 26px 22px;
  border-radius: 16px;
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.18);
  text-align: center;
}

#modalPreviewDocumento .modal-documento-preview-spinner {
  width: 46px;
  height: 46px;
  margin: 0 auto 14px auto;
  border-radius: 50%;
  border: 4px solid #dbeafe;
  border-top-color: #2563eb;
  animation: modalDocumentoPreviewSpin 0.8s linear infinite;
}

#modalPreviewDocumento .modal-documento-preview-loading-title {
  color: #102033;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 5px;
}

#modalPreviewDocumento .modal-documento-preview-loading-text {
  color: #64748b;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
}

@keyframes modalDocumentoPreviewSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

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

@media (max-width: 1200px) {
  #modalPreviewDocumento .modal-documento-preview-dialog {
    width: calc(100vw - 90px);
    max-width: calc(100vw - 90px);
    height: calc(100vh - 100px);
    max-height: calc(100vh - 100px);
    margin: 50px auto;
  }
}

@media (max-width: 768px) {
  #modalPreviewDocumento .modal-documento-preview-dialog {
    width: calc(100vw - 24px);
    max-width: calc(100vw - 24px);
    height: calc(100vh - 40px);
    max-height: calc(100vh - 40px);
    margin: 20px auto;
  }

  #modalPreviewDocumento .modal-documento-preview-header {
    height: auto;
    min-height: 100px;
    flex: 0 0 auto;
    padding: 12px;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }

  #modalPreviewDocumento .modal-documento-preview-title-wrap {
    width: 100%;
  }

  #modalPreviewDocumento .modal-documento-preview-title {
    font-size: 16px;
    max-width: 100%;
  }

  #modalPreviewDocumento .modal-documento-preview-actions {
    width: 100%;
    justify-content: flex-end;
    gap: 8px;
  }

  #modalPreviewDocumento .modal-documento-preview-btn {
    height: 36px;
    min-height: 36px;
    padding: 0 12px;
    font-size: 12px;
  }

  #modalPreviewDocumento .modal-documento-preview-btn-close {
    width: 36px;
    min-width: 36px;
    padding: 0;
  }

  #modalPreviewDocumento .modal-documento-preview-body {
    height: auto;
  }

  #modalPreviewDocumento .modal-documento-preview-loading-card {
    width: 250px;
    padding: 22px 18px;
  }
}

/* =========================================================
   FIN MODAL GLOBAL ÚNICO: VISTA PREVIA DE DOCUMENTOS
========================================================= */

/* =========================================================
   RESUMEN PREMIUM EN FOOTER DE MODALES
   Reutilizable para ingresos, egresos y otros formularios
   ========================================================= */

.modal-footer {
  flex-wrap: wrap;
  gap: 12px;
}

.modal-footer-context {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 13px 16px;
  margin-bottom: 10px;
  border-radius: 16px;
  border: 1px solid rgba(59, 130, 246, 0.2);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.98),
    rgba(248, 251, 255, 0.96)
  );
  box-shadow:
    0 12px 28px rgba(15, 23, 42, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
  position: relative;
  overflow: hidden;
}

.modal-footer-context::before {
  content: "";
  position: absolute;
  top: 0;
  left: 16px;
  right: 16px;
  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(59, 130, 246, 0),
    rgba(59, 130, 246, 0.45),
    rgba(59, 130, 246, 0)
  );
}

.modal-footer-context-left {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 13px;
  position: relative;
  z-index: 1;
}

.modal-footer-context-icon {
  width: 44px;
  height: 44px;
  min-width: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  background: linear-gradient(
    135deg,
    rgba(59, 130, 246, 0.16),
    rgba(37, 99, 235, 0.08)
  );
  border: 1px solid rgba(37, 99, 235, 0.2);
  box-shadow:
    0 8px 18px rgba(37, 99, 235, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
  font-size: 18px;
}

.modal-footer-context-info {
  min-width: 0;
}

.modal-footer-context-label {
  display: block;
  margin-bottom: 3px;
  font-size: 10.5px;
  font-weight: 900;
  letter-spacing: 0.65px;
  color: #64748b;
  text-transform: uppercase;
  line-height: 1.2;
}

.modal-footer-context-value {
  display: block;
  max-width: 100%;
  font-size: 15px;
  font-weight: 900;
  color: #0f172a;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.modal-footer-context-right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: 135px;
  position: relative;
  z-index: 1;
}

.modal-footer-context-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 13px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  color: #2563eb;
  background: rgba(37, 99, 235, 0.09);
  border: 1px solid rgba(37, 99, 235, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
  white-space: nowrap;
}

.modal-footer-context.is-empty {
  border-color: rgba(148, 163, 184, 0.24);
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.98),
    rgba(248, 250, 252, 0.96)
  );
}

.modal-footer-context.is-empty::before {
  background: linear-gradient(
    90deg,
    rgba(148, 163, 184, 0),
    rgba(148, 163, 184, 0.35),
    rgba(148, 163, 184, 0)
  );
}

.modal-footer-context.is-empty .modal-footer-context-icon {
  color: #64748b;
  background: linear-gradient(
    135deg,
    rgba(148, 163, 184, 0.16),
    rgba(100, 116, 139, 0.07)
  );
  border-color: rgba(100, 116, 139, 0.18);
  box-shadow:
    0 8px 18px rgba(100, 116, 139, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.modal-footer-context.is-empty .modal-footer-context-value {
  color: #64748b;
  font-weight: 800;
}

.modal-footer-context.is-empty .modal-footer-context-badge {
  color: #64748b;
  background: rgba(100, 116, 139, 0.08);
  border-color: rgba(100, 116, 139, 0.16);
}

.modal-footer-actions {
  width: 100%;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

/* Variante para egresos si querés diferenciarlo levemente */
.modal-footer-context.context-egreso .modal-footer-context-icon {
  color: #dc2626;
  background: linear-gradient(
    135deg,
    rgba(220, 38, 38, 0.14),
    rgba(248, 113, 113, 0.07)
  );
  border-color: rgba(220, 38, 38, 0.18);
  box-shadow:
    0 8px 18px rgba(220, 38, 38, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.modal-footer-context.context-egreso .modal-footer-context-badge {
  color: #dc2626;
  background: rgba(220, 38, 38, 0.08);
  border-color: rgba(220, 38, 38, 0.16);
}

.modal-footer-context.context-egreso::before {
  background: linear-gradient(
    90deg,
    rgba(220, 38, 38, 0),
    rgba(220, 38, 38, 0.38),
    rgba(220, 38, 38, 0)
  );
}

/* Responsive */
@media (max-width: 767.98px) {
  .modal-footer-context {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px;
  }

  .modal-footer-context-right {
    width: 100%;
    justify-content: flex-start;
  }

  .modal-footer-context-value {
    white-space: normal;
  }

  .modal-footer-actions {
    justify-content: stretch;
  }

  .modal-footer-actions .btn {
    width: 100%;
  }
}
