/* ===== RUNEM Staff App - Dark Theme ===== */

:root {
  --bg-primary: #1a1a1a;
  --bg-secondary: #2d2d2d;
  --bg-card: #3a3a3a;
  --bg-card-hover: #454545;
  --text-primary: #ffffff;
  --text-secondary: #cccccc;
  --text-muted: #999999;
  --accent-green: #4ade80;
  --accent-red: #ef4444;
  --accent-coral: #ff6b6b;
  --accent-cyan: #06b6d4;
  --accent-yellow: #fbbf24;
  --border-color: #555555;
  --border-radius: 12px;
  --border-radius-sm: 8px;
  --box-shadow: 0 4px 20px rgba(0,0,0,0.3);
  --box-shadow-hover: 0 8px 32px rgba(0,0,0,0.4);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  margin: 0;
  padding: 0;
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

.app-container {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== HEADER GLOBAL ===== */
.app-header {
  background: var(--bg-secondary);
  color: var(--text-primary);
  padding: 1rem 1.5rem;
  box-shadow: 0 2px 10px rgba(0,0,0,0.5);
  position: sticky;
  top: 0;
  z-index: 1030;
  border-bottom: 1px solid var(--border-color);
}

.app-header .navbar-brand {
  color: var(--text-primary) !important;
  font-weight: 600;
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.app-header .navbar-brand img {
  height: 36px;
  filter: brightness(1.2);
}

/* ===== MAIN CONTENT ===== */
.main-content {
  flex: 1;
  padding: 1.5rem;
  padding-bottom: 140px; /* Espacio para menú inferior y footer */
  background: var(--bg-primary);
  min-height: calc(100vh - 140px);
}

/* ===== TARJETAS REUTILIZABLES ===== */
.card-custom {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  border: 1px solid var(--border-color);
  margin-bottom: 1.5rem;
  transition: none; /* evitar cambios bruscos en light/dark al alternar */
  overflow: hidden;
}

.card-custom:hover {
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-hover);
  border-color: var(--accent-cyan);
}

.card-header-custom {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-radius: 0;
  padding: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  font-weight: 600;
  font-size: 1.1rem;
}

.card-body-custom {
  padding: 1.5rem;
  background: var(--bg-card);
}

/* ===== BADGES Y INDICADORES ===== */
.badge-status {
  padding: 0.5rem 1.25rem;
  border-radius: 25px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  border: none;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.badge-abierta {
  background: linear-gradient(135deg, var(--accent-green) 0%, #22c55e 100%);
  color: var(--bg-primary);
}

.badge-cerrada {
  background: linear-gradient(135deg, var(--accent-red) 0%, #dc2626 100%);
  color: var(--text-primary);
}

.badge-pagado {
  background: linear-gradient(135deg, var(--accent-green) 0%, #16a34a 100%);
  color: var(--bg-primary);
}

.badge-pendiente {
  background: linear-gradient(135deg, var(--accent-yellow) 0%, #f59e0b 100%);
  color: var(--bg-primary);
}

/* ===== BOTONES PERSONALIZADOS ===== */
.btn-coral {
  background: linear-gradient(135deg, var(--accent-coral) 0%, #be123c 100%);
  border: none;
  color: var(--text-primary);
  padding: 1rem 2rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-coral:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
  color: var(--text-primary);
  background: linear-gradient(135deg, #ff5757 0%, #dc1f47 100%);
}

.btn-cyan {
  background: linear-gradient(135deg, var(--accent-cyan) 0%, #0369a1 100%);
  border: none;
  color: var(--text-primary);
  padding: 1rem 2rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(6, 182, 212, 0.3);
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-cyan:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4);
  color: var(--text-primary);
  background: linear-gradient(135deg, #0284c7 0%, #075985 100%);
}

.btn-green {
  background: linear-gradient(135deg, var(--accent-green) 0%, #15803d 100%);
  border: none;
  color: var(--bg-primary);
  padding: 1rem 2rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  font-size: 0.95rem;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 15px rgba(74, 222, 128, 0.3);
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-green:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(74, 222, 128, 0.4);
  color: var(--bg-primary);
  background: linear-gradient(135deg, #22c55e 0%, #15803d 100%);
}

/* ===== FORMULARIOS ===== */
.form-control-custom {
  border: 2px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem 1.25rem;
  font-size: 1rem;
  transition: var(--transition);
  background: var(--bg-card);
  color: var(--text-primary);
}

.form-control-custom:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
  background: var(--bg-card);
  color: var(--text-primary);
}

.form-control-custom::placeholder {
  color: var(--text-muted);
}

.form-label-custom {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
  font-size: 0.95rem;
}

/* ===== MENÚ INFERIOR ===== */
.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--bg-secondary);
  padding: 0.75rem 0;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.5);
  z-index: 1020;
  border-top: 1px solid var(--border-color);
}

/* Navegación responsive */
@media (max-width: 768px) {
  .bottom-nav {
    padding: 0.5rem 0;
    height: 70px; /* Altura fija para cálculos */
  }
  
  .bottom-nav .nav-item {
    padding: 0.5rem 0.25rem;
  }
  
  .bottom-nav .nav-item i {
    font-size: 1.1rem;
  }
  
  .bottom-nav .nav-item span {
    font-size: 0.7rem;
    margin-top: 0.25rem;
  }
}

.bottom-nav .nav-container {
  display: flex;
  justify-content: space-around;
  align-items: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 0 1rem;
}

.bottom-nav .nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  transition: none;
  padding: 0.75rem 0.5rem;
  border-radius: var(--border-radius-sm);
  min-width: 70px;
}

.bottom-nav .nav-item:hover,
.bottom-nav .nav-item.active {
  background-color: var(--bg-card);
  color: var(--accent-cyan);
  text-decoration: none;
  transform: none;
  box-shadow: none;
}

.bottom-nav .nav-item i {
  font-size: 1.5rem;
  margin-bottom: 0.25rem;
}

/* ===== INDICADORES DE ESTADO ===== */
.status-indicator {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 0.5rem;
}

.status-online {
  background-color: var(--success-color);
  animation: pulse 2s infinite;
}

.status-offline {
  background-color: var(--danger-color);
}

.status-syncing {
  background-color: var(--warning-color);
  animation: pulse 1s infinite;
}

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

/* ===== PANTALLA DE CARGA ===== */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(255,255,255,0.9);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #e3e3e3;
  border-top: 4px solid var(--secondary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* ===== ALERTAS PERSONALIZADAS ===== */
.alert-custom {
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  padding: 1.25rem 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--box-shadow);
  background: var(--bg-card);
}

.alert-success-custom {
  background: rgba(34, 197, 94, 0.95);
  color: white;
  border-left: 4px solid var(--accent-green);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.alert-error-custom {
  background: rgba(220, 38, 38, 0.95);
  color: white;
  border-left: 4px solid var(--accent-red);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.alert-warning-custom {
  background: rgba(245, 158, 11, 0.95);
  color: white;
  border-left: 4px solid var(--accent-yellow);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.alert-info-custom {
  background: rgba(8, 145, 178, 0.95);
  color: white;
  border-left: 4px solid var(--accent-cyan);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

/* ===== COMPONENTES DE DASHBOARD ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

/* Espaciado mejorado para las filas de estadísticas */
.row {
  margin-bottom: 1.5rem;
}

.row .col-6 {
  padding: 0 0.75rem;
}

.stat-card {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  padding: 2rem 1.5rem;
  box-shadow: var(--box-shadow);
  text-align: center;
  transition: var(--transition);
  border: 1px solid var(--border-color);
  position: relative;
  overflow: hidden;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-hover);
  border-color: var(--accent-cyan);
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-coral) 0%, var(--accent-cyan) 100%);
}

.stat-icon {
  font-size: 3rem;
  color: var(--accent-cyan);
  margin-bottom: 1rem;
  opacity: 0.8;
}

.stat-value {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.stat-value.accent {
  color: var(--accent-coral);
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ===== TOGGLE SWITCHES ===== */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 60px;
  height: 34px;
}

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

.toggle-slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 34px;
}

.toggle-slider:before {
  position: absolute;
  content: "";
  height: 26px;
  width: 26px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

input:checked + .toggle-slider {
  background-color: var(--secondary-color);
}

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

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
  .main-content {
    padding: 0.75rem;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .card-body-custom {
    padding: 1rem;
  }
  
  .btn-custom-primary,
  .btn-custom-secondary {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .app-header {
    padding: 0.75rem;
  }
  
  .main-content {
    padding: 0.5rem;
  }
  
  .bottom-nav .nav-item {
    font-size: 0.7rem;
    min-width: 50px;
  }
  
  .bottom-nav .nav-item i {
    font-size: 1rem;
  }
}

/* ===== ANIMACIONES Y EFECTOS ===== */
.fade-in {
  /* Animación desactivada para cambio directo de vista */
  /* animation: fadeIn 0.5s ease-in; */
}

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

.slide-up {
  animation: slideUp 0.3s ease-out;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* ===== ESTILOS ESPECÍFICOS DASHBOARD ===== */

/* Saldo destacado */
.saldo-destacado {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent-coral);
  text-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
  margin: 1rem 0;
}
/* ===== LIGHT THEME (para camareros, alto contraste y colores agradables) ===== */
body.theme-light {
  /* Superficies */
  --bg-primary: #f7f8fb;
  --bg-secondary: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5f9;

  /* Texto */
  --text-primary: #0f172a;   /* slate-900 */
  --text-secondary: #334155; /* slate-700 */
  --text-muted: #64748b;     /* slate-500 */

  /* Accentos (más vivos pero amables) */
  --accent-green: #16a34a;   /* green-600 */
  --accent-red: #dc2626;     /* red-600 */
  --accent-coral: #e11d48;   /* rose-600 */
  --accent-cyan: #0891b2;    /* cyan-700 */
  --accent-yellow: #d97706;  /* amber-600 */

  /* Bordes y sombras suaves para uso intensivo */
  --border-color: #cbd5e1;   /* slate-300: bordes más visibles */
  --box-shadow: 0 6px 24px rgba(2, 6, 23, 0.06);
  --box-shadow-hover: 0 10px 36px rgba(2, 6, 23, 0.10);
}

/* Botón outline claro sobre fondo claro: adaptar colores */
body.theme-light .btn-outline-light {
  background: #e2e8f0 !important; /* slate-200 */
  color: #0f172a !important; /* slate-900 */
  border-color: #cbd5e1 !important;
}
body.theme-light .btn-outline-light:hover,
body.theme-light .btn-outline-light:focus {
  background: #cbd5e1 !important; /* slate-300 */
}

/* Ajustes varios para mayor legibilidad en light */
body.theme-light .app-header {
  box-shadow: 0 2px 12px rgba(2, 6, 23, 0.06);
}
body.theme-light .card-custom:hover {
  border-color: var(--accent-cyan);
}
body.theme-light .bottom-nav {
  box-shadow: 0 -6px 16px rgba(2, 6, 23, 0.06);
}

/* Formularios legibles en light */
body.theme-light .form-control,
body.theme-light .form-select,
body.theme-light .form-control-custom {
  background: #ffffff;
  color: var(--text-primary);
  border-color: #94a3b8; /* slate-400: más contraste */
}
body.theme-light .form-control:focus,
body.theme-light .form-select:focus,
body.theme-light .form-control-custom:focus {
  border-color: #2563eb; /* blue-600 */
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.25);
}
body.theme-light .input-group-text {
  background: #f1f5f9; /* slate-100 */
  color: #334155; /* slate-700 */
  border-color: #94a3b8;
}

/* Modales y tarjetas en light */
body.theme-light .modal-content {
  background: #ffffff;
  color: var(--text-primary);
  border: 1.25px solid var(--border-color);
}
body.theme-light .modal-header {
  background: #f8fafc; /* suave para separar */
}
body.theme-light .modal-footer {
  background: #f8fafc;
}
body.theme-light .card-header-custom {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

/* Mejor contraste en alertas personalizadas usadas como resúmenes */
body.theme-light .alert-dark {
  background: #f8fafc; /* slate-50 */
  color: var(--text-primary);
  border: 1.25px solid #cbd5e1; /* slate-300 */
}
body.theme-light .text-coral { color: #b91c1c !important; }    /* rojo legible */
body.theme-light .text-warning { color: #b45309 !important; }  /* amber-700 */
body.theme-light .text-primary-custom { color: #0ea5e9 !important; } /* sky-500 para totales */
body.theme-light .border-secondary { border-color: #cbd5e1 !important; }
body.theme-light .text-light { color: var(--text-primary) !important; }

/* Badges con texto blanco en light para contraste */
body.theme-light .badge-abierta,
body.theme-light .badge-cerrada,
body.theme-light .badge-pagado,
body.theme-light .badge-pendiente {
  color: #ffffff !important;
}

/* Botones de acento: texto blanco en light */
body.theme-light .btn-cyan,
body.theme-light .btn-green,
body.theme-light .btn-coral {
  color: #ffffff !important;
}

/* Navegación inferior: activo legible en light */
body.theme-light .bottom-nav .nav-item:hover,
body.theme-light .bottom-nav .nav-item.active {
  background-color: #eef2f7; /* más visible que blanco */
  color: var(--accent-cyan);
}

/* Forzar fondos claros si vienen con clases oscuras heredadas */
body.theme-light .bg-dark { background-color: #ffffff !important; }
body.theme-light .text-light { color: var(--text-primary) !important; }
body.theme-light .border-primary { border-color: #94a3b8 !important; }

/* Inputs creados con clases oscuras (normal en la app) */
body.theme-light .form-control.bg-dark,
body.theme-light .form-select.bg-dark,
body.theme-light textarea.bg-dark {
  background-color: #ffffff !important;
  color: var(--text-primary) !important;
}
body.theme-light .form-control.bg-dark::placeholder,
body.theme-light textarea.bg-dark::placeholder {
  color: #64748b !important;
}
body.theme-light .border-secondary { border-color: #94a3b8 !important; }

/* Cabeceras/footers de modal con borde secondary en light */
body.theme-light .modal-header.border-secondary,
body.theme-light .modal-footer.border-secondary {
  border-color: #cbd5e1 !important;
}

/* Textos muted deben seguir siendo legibles en claro */
body.theme-light .text-muted { color: #64748b !important; }

/* Secciones y contenedores: bordes más presentes */
body.theme-light .card-custom,
body.theme-light .jornada-info,
body.theme-light .productos-destacados,
body.theme-light .productos-actions,
body.theme-light .payment-summary {
  border-color: var(--border-color) !important;
    border-width: 1.25px !important;
}

/* ===== Tablas del detalle de pedido/ticket (table-dark en modo claro) ===== */
body.theme-light table.table-dark,
body.theme-light .table-dark,
body.theme-light table[class*="table-dark"],
body.theme-light .table[class*="dark"] {
  background-color: #ffffff !important;
  color: #0f172a !important;
  border-color: #94a3b8 !important; /* slate-400 más visible */
}

body.theme-light .table-dark thead th,
body.theme-light table.table-dark thead th,
body.theme-light .table-dark th,
body.theme-light table.table-dark th {
  background-color: #e2e8f0 !important; /* slate-200 para cabecera destacada */
  color: #0f172a !important;
  border-color: #94a3b8 !important;
  font-weight: 600;
}

body.theme-light .table-dark tbody tr,
body.theme-light table.table-dark tbody tr,
body.theme-light .table-dark tr,
body.theme-light table.table-dark tr {
  background-color: #ffffff !important;
  color: #0f172a !important;
  border-color: #cbd5e1 !important; /* slate-300 */
}

body.theme-light .table-dark tbody td,
body.theme-light table.table-dark tbody td,
body.theme-light .table-dark td,
body.theme-light table.table-dark td {
  background-color: #ffffff !important;
  color: #0f172a !important;
  border-color: #cbd5e1 !important;
}

/* ELIMINAR COMPLETAMENTE EL RAYADO EN MODO CLARO - REGLAS ULTRA ESPECÍFICAS */
body.theme-light .table-striped,
body.theme-light table.table-striped,
body.theme-light .table-dark.table-striped,
body.theme-light table.table-dark.table-striped {
  --bs-table-striped-bg: #ffffff !important; /* Variable Bootstrap para rayado */
}

/* FORZAR TODAS LAS FILAS IMPARES A BLANCO */
body.theme-light .table-striped > tbody > tr:nth-of-type(odd) > td,
body.theme-light .table-striped > tbody > tr:nth-of-type(odd) > th,
body.theme-light .table-striped > tbody > tr:nth-of-type(odd),
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(odd) > td,
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(odd) > th,
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(odd),
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(odd) > td,
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(odd) > th,
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(odd) {
  background-color: #ffffff !important;
  background-image: none !important;
  background: #ffffff !important;
  color: #0f172a !important;
}

/* FORZAR TODAS LAS FILAS PARES A BLANCO TAMBIÉN */
body.theme-light .table-striped > tbody > tr:nth-of-type(even) > td,
body.theme-light .table-striped > tbody > tr:nth-of-type(even) > th,
body.theme-light .table-striped > tbody > tr:nth-of-type(even),
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(even) > td,
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(even) > th,
body.theme-light .table-dark.table-striped > tbody > tr:nth-of-type(even),
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(even) > td,
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(even) > th,
body.theme-light table.table-dark.table-striped > tbody > tr:nth-of-type(even) {
  background-color: #ffffff !important;
  background-image: none !important;
  background: #ffffff !important;
  color: #0f172a !important;
}

/* REGLA UNIVERSAL PARA CUALQUIER TR DENTRO DE TABLA RAYADA */
body.theme-light .table-striped tbody tr,
body.theme-light .table-dark.table-striped tbody tr,
body.theme-light table.table-dark.table-striped tbody tr {
  background-color: #ffffff !important;
  background-image: none !important;
  background: #ffffff !important;
  color: #0f172a !important;
}

/* REGLA UNIVERSAL PARA CUALQUIER TD DENTRO DE TABLA RAYADA */
body.theme-light .table-striped tbody tr td,
body.theme-light .table-dark.table-striped tbody tr td,
body.theme-light table.table-dark.table-striped tbody tr td {
  background-color: #ffffff !important;
  background-image: none !important;
  background: #ffffff !important;
  color: #0f172a !important;
}

/* Celdas con bordes visibles */
body.theme-light table.table-dark td,
body.theme-light table.table-dark th,
body.theme-light .table-dark td,
body.theme-light .table-dark th {
  border-color: #cbd5e1 !important;
  border-width: 1px !important;
  background-color: inherit !important;
}

/* Forzar elementos oscuros heredados dentro de la tabla */
body.theme-light table.table-dark .bg-dark,
body.theme-light .table-dark .bg-dark,
body.theme-light table .bg-dark,
body.theme-light .table .bg-dark { 
  background-color: #ffffff !important; 
  color: #0f172a !important; 
}

/* ===== Cuadro de totales del ticket (totales-detail) ===== */
body.theme-light .totales-detail,
body.theme-light #totales-detail,
body.theme-light div[class*="totales"],
body.theme-light .totales {
  background: #ffffff !important; /* fondo blanco limpio */
  color: #0f172a !important;
  border: 2px solid #94a3b8 !important; /* slate-400 borde bien visible */
  border-radius: 12px !important;
  padding: 1rem !important;
}

body.theme-light .totales-detail *,
body.theme-light #totales-detail *,
body.theme-light div[class*="totales"] *,
body.theme-light .totales * {
  background-color: transparent !important;
  color: #0f172a !important;
}

body.theme-light .totales-detail .label,
body.theme-light #totales-detail .label,
body.theme-light .totales .label { 
  color: #475569 !important; /* slate-600 para etiquetas */
  font-weight: 500 !important;
}

body.theme-light .totales-detail .valor,
body.theme-light #totales-detail .valor,
body.theme-light .totales .valor { 
  color: #0f172a !important; /* slate-900 para valores */
  font-weight: 700 !important; 
}

body.theme-light .totales-detail .total,
body.theme-light #totales-detail .total,
body.theme-light .totales .total { 
  color: #0284c7 !important; /* sky-600 más intenso para totales */
  font-weight: 800 !important;
}

/* Forzar elementos oscuros heredados dentro de totales - más específico */
body.theme-light .totales-detail .bg-dark,
body.theme-light #totales-detail .bg-dark,
body.theme-light .totales .bg-dark,
body.theme-light div[class*="totales"] .bg-dark { 
  background-color: #ffffff !important; 
  color: #0f172a !important; 
}

body.theme-light .totales-detail .text-light,
body.theme-light #totales-detail .text-light,
body.theme-light .totales .text-light,
body.theme-light div[class*="totales"] .text-light { 
  color: #0f172a !important; 
}

/* Elementos específicos que pueden estar oscuros */
body.theme-light .bg-secondary,
body.theme-light .bg-dark {
  background-color: #ffffff !important;
  color: #0f172a !important;
}

body.theme-light .text-secondary,
body.theme-light .text-muted {
  color: #64748b !important;
}

/* ===== TABLA RESPONSIVE PARA MÓVILES ===== */
.table-responsive-custom {
  display: block;
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table-responsive-custom > .table {
  margin-bottom: 0;
}

/* Mejorar scroll en móviles */
@media (max-width: 768px) {
  .table-responsive-custom {
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-bottom: 1rem;
  }
  
  .table-responsive-custom::-webkit-scrollbar {
    height: 8px;
  }
  
  .table-responsive-custom::-webkit-scrollbar-track {
    background: var(--bg-secondary);
    border-radius: 4px;
  }
  
  .table-responsive-custom::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
  }
  
  .table-responsive-custom::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
  }
  
  /* Asegurar que la tabla mantenga su ancho mínimo */
  .table-responsive-custom > .table {
    min-width: 600px; /* Ancho mínimo para que se vean todas las columnas */
  }
  
  /* Indicador visual de scroll disponible */
  .table-responsive-custom::after {
    content: "⟷ Desliza para ver más";
    display: block;
    text-align: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    padding: 0.25rem;
    border-top: 1px solid var(--border-color);
    background: var(--bg-secondary);
  }
}

/* ===== BOTÓN DE CAMBIO DE TEMA RESPONSIVE ===== */
#btnToggleTheme {
  transition: all 0.3s ease;
  white-space: nowrap;
  min-width: 40px; /* Ancho mínimo para el icono */
}

/* En tablets y escritorio: mostrar texto completo */
@media (min-width: 768px) {
  #btnToggleTheme {
    min-width: 100px; /* Espacio suficiente para icono + texto */
  }
  
  #labelToggleTheme {
    font-size: 0.875rem;
    font-weight: 500;
  }
}

/* En escritorio grande: más espacio y mejor legibilidad */
@media (min-width: 1200px) {
  #btnToggleTheme {
    min-width: 120px;
    padding: 0.5rem 1rem;
  }
  
  #labelToggleTheme {
    font-size: 0.9rem;
  }
}

/* Hover y focus states mejorados */
#btnToggleTheme:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

#btnToggleTheme:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* Iconos del tema con mejor spacing */
#iconToggleTheme {
  font-size: 1rem;
}

/* Ajustes específicos para tema claro */
body.theme-light #btnToggleTheme.btn-outline-dark {
  border-color: #374151;
  color: #374151;
}

body.theme-light #btnToggleTheme.btn-outline-dark:hover {
  background-color: #374151;
  color: #ffffff;
}
  
/* Grid de botones de acción */
.action-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin: 2rem 0;
}

.action-button {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1.5rem 1rem;
  text-align: center;
  color: var(--text-primary);
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
  min-height: 100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.action-button:hover {
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-hover);
  color: var(--text-primary);
  text-decoration: none;
  border-color: var(--accent-cyan);
}

.action-button i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  opacity: 0.8;
}

.action-button span {
  font-weight: 600;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Información de jornada */
.jornada-info {
  background: var(--bg-card);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  margin-bottom: 1.5rem;
}

.jornada-info .tiempo-transcurrido {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--accent-cyan);
  margin-bottom: 0.5rem;
}

.jornada-info .progreso-barra {
  height: 8px;
  background: var(--bg-secondary);
  border-radius: 10px;
  overflow: hidden;
  margin: 1rem 0;
}

.jornada-info .progreso-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-green) 0%, var(--accent-cyan) 100%);
  border-radius: 10px;
  transition: width 0.3s ease;
}

/* Modales dark theme */
.modal-content {
  background: var(--bg-card) !important;
  border: 1px solid var(--border-color) !important;
  border-radius: var(--border-radius) !important;
}

.modal-header {
  background: var(--bg-secondary) !important;
  border-bottom: 1px solid var(--border-color) !important;
  color: var(--text-primary) !important;
}

.modal-body {
  background: var(--bg-card) !important;
  color: var(--text-primary) !important;
}

.modal-footer {
  background: var(--bg-card) !important;
  border-top: 1px solid var(--border-color) !important;
}

.btn-close-white {
  filter: invert(1) grayscale(100%) brightness(200%);
}

/* Ventanas de login */
.login-container {
  background: var(--bg-primary);
  min-height: 100vh;
}

.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
}

.login-header {
  background: var(--bg-secondary);
  color: var(--text-primary);
  padding: 2rem;
  text-align: center;
  border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.login-body {
  padding: 2rem;
  background: var(--bg-card);
}

/* Login input group styles */
.login-body .input-group {
  border-radius: var(--border-radius-sm);
  overflow: hidden;
}

.login-body .input-group .form-control-custom {
  border-right: none;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.login-body .input-group .password-toggle {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-left: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  border-color: var(--border-color);
}

.login-body .input-group .password-toggle:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--accent-cyan);
}

.login-body .input-group .password-toggle:focus {
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
  border-color: var(--accent-cyan);
}

/* Bootstrap overrides */
.btn-outline-light {
  background-color: var(--bg-secondary) !important;
  border-color: var(--border-color) !important;
  color: var(--text-primary) !important;
}

.btn-outline-light:hover,
.btn-outline-light:focus {
  background-color: var(--bg-card) !important;
  border-color: var(--accent-cyan) !important;
  color: var(--text-primary) !important;
}

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

.btn-secondary:hover {
  background-color: var(--bg-card) !important;
  border-color: var(--accent-cyan) !important;
}

.text-muted {
  color: var(--text-muted) !important;
}

/* ===== UTILIDADES ===== */
.text-primary-custom { color: var(--accent-cyan) !important; }
.text-secondary-custom { color: var(--accent-coral) !important; }
.text-success-custom { color: var(--accent-green) !important; }
.text-warning-custom { color: var(--accent-yellow) !important; }
.text-danger-custom { color: var(--accent-red) !important; }

.bg-primary-custom { background-color: var(--bg-primary) !important; }
.bg-secondary-custom { background-color: var(--bg-secondary) !important; }
.bg-card-custom { background-color: var(--bg-card) !important; }

.shadow-custom { box-shadow: var(--box-shadow) !important; }
.rounded-custom { border-radius: var(--border-radius) !important; }

.hidden { display: none !important; }
.visible { display: block !important; }

/* ===== ANIMACIONES DE ACTUALIZACIÓN ===== */
.updating {
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0% { opacity: 1; }
  50% { opacity: 0.6; }
  100% { opacity: 1; }
}

.stat-value, .saldo-destacado, .tiempo-transcurrido {
  transition: all 0.3s ease;
}

.updated {
  animation: highlight 0.8s ease-out;
}

@keyframes highlight {
  0% { 
    transform: scale(1);
    box-shadow: 0 0 0 0 var(--accent-cyan);
  }
  30% { 
    transform: scale(1.05);
    box-shadow: 0 0 0 10px rgba(6, 182, 212, 0.3);
  }
  100% { 
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(6, 182, 212, 0);
  }
}

/* Indicador de actualización */
.update-indicator {
  position: fixed;
  top: 80px;
  right: 20px;
  background: var(--accent-cyan);
  color: var(--bg-primary);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: var(--box-shadow);
  z-index: 1000;
  opacity: 0;
  transform: translateX(100%);
  transition: all 0.3s ease;
}

.update-indicator.show {
  opacity: 1;
  transform: translateX(0);
}

/* Modal de advertencia para finalizar jornada */
.modal-content .list-unstyled li {
  background: rgba(239, 68, 68, 0.1);
  padding: 0.75rem;
  border-radius: var(--border-radius-sm);
  border-left: 3px solid var(--accent-red);
  margin-bottom: 0.5rem;
}

.modal-content .list-unstyled li i {
  color: var(--accent-red);
}

.text-warning-custom {
  color: var(--accent-yellow) !important;
}

.text-danger-custom {
  color: var(--accent-red) !important;
}

/* Botón específico para ir a caja */
.btn-cyan.modal-action {
  background: linear-gradient(135deg, var(--accent-cyan) 0%, #0891b2 100%);
  border: none;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: var(--transition);
}

.btn-cyan.modal-action:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.4);
}

/* ===== FOOTER ===== */
.app-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 1rem;
  position: fixed;
  bottom: 80px; /* Encima del menú inferior */
  left: 0;
  right: 0;
  z-index: 100;
}

/* Footer responsive */
@media (max-width: 768px) {
  .app-footer {
    padding: 0.75rem 1rem;
    bottom: 70px; /* Ajuste para menú móvil más pequeño */
  }
  
  .app-footer small {
    font-size: 0.75rem;
  }
}

/* Fix general para espaciado inferior en móvil */
@media (max-width: 768px) {
  .main-content {
    padding-bottom: 160px !important; /* Espacio para menú (70px) + footer (40px) + margen (50px) */
  }
}

@media (max-width: 480px) {
  .main-content {
    padding-bottom: 180px !important; /* Más espacio en pantallas muy pequeñas */
  }
  
  /* Margen adicional en contenido de páginas */
  #pageContent .fade-in {
    margin-bottom: 2rem;
  }
}

/* ===== GESTIÓN DE CAJA ===== */

/* Saldos destacados */
.saldos-destacados {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #1e3a8a, #059669);
  border-radius: var(--border-radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  border: 1px solid rgba(255,255,255,0.1);
}

.saldos-destacados.cerrada {
  background: linear-gradient(135deg, #374151, #6b7280);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.saldo-destacado-item {
  text-align: center;
  flex: 1;
}

.saldo-destacado-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: #ffffff;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.5rem;
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.saldos-destacados.cerrada .saldo-destacado-label {
  color: #e5e7eb;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.saldo-destacado-valor {
  font-size: 1.8rem;
  font-weight: 700;
  font-family: monospace;
  color: #ffffff;
  text-shadow: 0 2px 6px rgba(0,0,0,0.5);
}

.saldo-destacado-valor.inicial {
  color: #f0f9ff;
}

.saldo-destacado-valor.inicial.editable {
  cursor: pointer;
  transition: all 0.2s ease;
  border-radius: 8px;
  padding: 0.25rem 0.5rem;
}

.saldo-destacado-valor.inicial.editable:hover {
  background: rgba(108, 198, 255, 0.1);
  transform: scale(1.02);
}

.saldo-destacado-valor.inicial.editable i {
  opacity: 0.6;
  font-size: 0.8rem;
}

.saldo-destacado-valor.actual {
  color: #ffffff;
  font-weight: 800;
}

.saldos-destacados.cerrada .saldo-destacado-valor {
  color: #f3f4f6;
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.saldo-destacado-separador {
  padding: 0 1rem;
  font-size: 1.2rem;
  color: #ffffff;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  text-shadow: 0 1px 3px rgba(0,0,0,0.4);
}

.saldos-destacados.cerrada .saldo-destacado-separador {
  color: #e5e7eb;
}

.diferencia-saldo {
  font-weight: 700;
  font-size: 0.75rem;
  background: rgba(0,0,0,0.3);
  padding: 0.25rem 0.6rem;
  border-radius: 12px;
  white-space: nowrap;
  color: #ffffff !important;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
  border: 1px solid rgba(255,255,255,0.2);
}

.saldos-destacados.cerrada .diferencia-saldo {
  background: rgba(0,0,0,0.4);
  color: #f3f4f6 !important;
  border: 1px solid rgba(255,255,255,0.1);
}

/* Pedidos pendientes en estado caja */
.pedidos-pendientes-importe {
  background: rgba(255, 193, 7, 0.1);
  border: 1px solid rgba(255, 193, 7, 0.3);
  border-radius: 4px;
  padding: 0.25rem 0.5rem;
  margin-top: 0.25rem;
  color: #ffc107;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

/* Lista de movimientos */
.movimientos-list {
  max-height: 400px;
  overflow-y: auto;
}

.movimiento-item {
  display: flex;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.movimiento-item:last-child {
  border-bottom: none;
}

.movimiento-item:hover {
  background: var(--bg-card-hover);
}

.movimiento-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  flex-shrink: 0;
}

.movimiento-icon i {
  font-size: 1.2rem;
}

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

.movimiento-concepto {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.movimiento-info {
  font-size: 0.8rem;
  color: var(--text-muted);
}

.movimiento-monto {
  font-weight: 700;
  font-size: 1.1rem;
  text-align: right;
  flex-shrink: 0;
}

/* Estilos específicos para action-grid en caja */
.action-grid .action-button {
  min-height: 80px;
  flex-direction: column;
  justify-content: center;
  gap: 0.5rem;
  border: 2px solid var(--border-color);
}

.action-grid .action-button:hover {
  border-color: var(--accent-cyan);
  transform: translateY(-2px);
}

.action-grid .action-button.btn-coral {
  background: linear-gradient(135deg, var(--accent-coral) 0%, #e11d48 100%);
  color: var(--text-primary);
  border-color: var(--accent-coral);
}

.action-grid .action-button.btn-coral:hover {
  border-color: #ff5757;
  box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
}

.action-grid .action-button.btn-cyan {
  background: linear-gradient(135deg, var(--accent-cyan) 0%, #0891b2 100%);
  color: var(--text-primary);
  border-color: var(--accent-cyan);
}

.action-grid .action-button.btn-cyan:hover {
  border-color: #0284c7;
  box-shadow: 0 8px 25px rgba(6, 182, 212, 0.4);
}

/* Form text para inputs */
.form-text {
  color: var(--text-muted) !important;
  font-size: 0.8rem;
  margin-top: 0.25rem;
}

/* ===== ESTADO DE CAJA ===== */

/* Grid para estado actual de caja */
.estado-caja-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.estado-item {
  padding: 0.75rem;
  background: var(--bg-secondary);
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  transition: var(--transition);
}

.estado-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-cyan);
}

.estado-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

.estado-value {
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 600;
}

/* ===== OPERACIONES DE CAJA ===== */

/* Lista de operaciones */
.operaciones-list {
  max-height: 500px;
  overflow-y: auto;
}

.operacion-item {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.operacion-item:last-child {
  border-bottom: none;
}

.operacion-item:hover {
  background: var(--bg-card-hover);
}

/* Header de operación */
.operacion-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.operacion-tipo {
  display: flex;
  align-items: center;
}

.operacion-titulo {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

.operacion-fecha {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Detalle de operación */
.operacion-detalle {
  background: var(--bg-secondary);
  padding: 0.75rem;
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
}

.saldo-info {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.saldo-item {
  text-align: center;
}

.saldo-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.saldo-valor {
  font-size: 0.9rem;
  color: var(--text-primary);
}

.movimiento-info {
  text-align: center;
  padding: 0.5rem;
  background: var(--bg-primary);
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
}

.movimiento-tipo {
  font-weight: 700;
  font-size: 1rem;
}

/* Extras de operación */
.operacion-extras {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.extra-info {
  font-size: 0.75rem;
  color: var(--text-muted);
  background: var(--bg-primary);
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  border: 1px solid var(--border-color);
}

.extra-info.text-warning-custom {
  color: var(--accent-coral) !important;
  border-color: var(--accent-coral);
  background: rgba(255, 107, 107, 0.1);
}

/* Acciones de caja en estado actual */
.caja-acciones {
  border-top: 1px solid var(--border-color);
  padding-top: 1rem;
}

.caja-acciones .btn {
  font-size: 0.9rem;
  padding: 0.75rem;
  border-radius: var(--border-radius);
  transition: var(--transition);
}

.caja-acciones .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Estilos para modal de descuadre */
.descuadre-detalle {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin: 1rem 0;
}

.descuadre-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
}

.descuadre-item:not(:last-child) {
  border-bottom: 1px solid var(--border-color);
}

.descuadre-label {
  font-weight: 500;
  color: var(--text-primary);
}

.descuadre-valor {
  font-weight: 600;
  font-family: monospace;
}

/* Estilos para modal de pedidos pendientes */
.pedidos-pendientes-lista {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin: 1rem 0;
}

.pedidos-pendientes-lista h6 {
  margin-bottom: 0.75rem;
  color: var(--text-primary);
  font-weight: 600;
}

.pedidos-pendientes-lista ul {
  margin-bottom: 0;
  padding-left: 1.25rem;
}

.pedidos-pendientes-lista li {
  margin-bottom: 0.25rem;
  color: var(--text-primary);
  font-family: monospace;
}

/* Estilos para pedidos pendientes en caja */
.pedidos-pendientes-detalle {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin: 1rem 0;
}

.pedidos-lista {
  max-height: 200px;
  overflow-y: auto;
}

.pedido-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
}

.pedido-info {
  flex: 1;
}

.pedido-monto {
  font-weight: 600;
  font-family: monospace;
  color: var(--accent-coral);
}

/* ===== HISTORIAL DE CAJAS ===== */

/* Lista del historial */
.historial-cajas-lista {
  max-height: 600px;
  overflow-y: auto;
}

/* Item del historial de caja */
.historial-caja-item {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.historial-caja-item:hover {
  background: var(--bg-primary);
  border-color: var(--accent-cyan);
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.historial-caja-item:last-child {
  margin-bottom: 0;
}

/* Header del item */
.historial-caja-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.historial-caja-info {
  flex: 1;
}

.historial-caja-fecha {
  margin-bottom: 0.5rem;
}

.historial-caja-fecha strong {
  color: var(--text-primary);
  font-size: 1.1rem;
}

.historial-caja-estado {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.historial-caja-tiempo {
  text-align: right;
  flex-shrink: 0;
}

.tiempo-info {
  font-size: 0.85rem;
}

/* Resumen financiero del item */
.historial-caja-resumen {
  margin-bottom: 0.5rem;
}

.resumen-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.resumen-item {
  text-align: center;
}

.resumen-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.resumen-valor {
  display: block;
  font-weight: 600;
  font-family: monospace;
  color: var(--text-primary);
}

/* Acciones del item */
.historial-caja-acciones {
  text-align: center;
  padding-top: 0.5rem;
}

/* Paginación del historial */
.historial-paginacion {
  border-top: 1px solid var(--border-color);
  background: var(--bg-primary);
}

.paginacion-info {
  color: var(--text-muted);
}

.paginacion-controles .btn {
  width: 36px;
  height: 36px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Modal de detalle de caja */
.detalle-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.detalle-item:last-child {
  border-bottom: none;
}

.detalle-label {
  font-weight: 500;
  color: var(--text-muted);
  flex-shrink: 0;
  margin-right: 1rem;
}

/* Resumen financiero en modal */
.detalle-financiero {
  text-align: center;
  padding: 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
}

.detalle-monto {
  font-size: 1.25rem;
  font-weight: 700;
  font-family: monospace;
  margin-bottom: 0.5rem;
}

.detalle-concepto {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Estadísticas simples */
.stat-simple {
  text-align: center;
  padding: 1rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
}

.stat-numero {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-cyan);
  margin-bottom: 0.25rem;
}

.stat-descripcion {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ===== RESPONSIVE PARA CAJA (MÓVIL) ===== */

/* Mejoras para móvil en gestión de caja */
@media (max-width: 768px) {
  /* Ajuste específico para página de caja */
  .page-content {
    padding-bottom: 20px;
  }
  
  /* Estado de caja responsive */
  .estado-caja-grid {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }
  
  .estado-item {
    padding: 0.5rem;
  }
  
  .estado-label {
    font-size: 0.75rem;
    margin-bottom: 0.25rem;
  }
  
  .estado-value {
    font-size: 0.9rem;
  }
  
  /* Operaciones responsive */
  .operacion-item {
    padding: 0.75rem;
  }
  
  .operacion-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }
  
  .operacion-titulo {
    font-size: 0.9rem;
  }
  
  .operacion-detalle {
    padding: 0.5rem;
  }
  
  .saldo-info {
    grid-template-columns: 1fr;
    gap: 0.5rem;
    text-align: center;
  }
  
  .movimiento-info {
    order: -1;
    margin-bottom: 0.5rem;
  }
  
  .saldo-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }
  
  .saldo-label {
    margin-bottom: 0;
    text-align: left;
  }
  
  .operacion-extras {
    gap: 0.25rem;
    margin-top: 0.5rem;
    padding-top: 0.5rem;
  }
  
  .extra-info {
    font-size: 0.7rem;
    padding: 0.2rem 0.4rem;
  }
  
  /* Acciones de caja responsive */
  .caja-acciones .btn {
    font-size: 0.85rem;
    padding: 0.6rem;
  }
  
  /* Saldos destacados responsive */
  .saldos-destacados {
    padding: 1rem;
    margin-bottom: 1rem;
  }
  
  .saldo-destacado-valor {
    font-size: 1.4rem;
  }
  
  .saldo-destacado-label {
    font-size: 0.75rem;
  }
  
  .saldo-destacado-separador {
    padding: 0 0.5rem;
    font-size: 1rem;
  }
  
  .diferencia-saldo {
    font-size: 0.65rem;
    padding: 0.15rem 0.4rem;
  }
  
  /* Pedidos pendientes responsive */
  .pedido-item {
    padding: 0.5rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .pedido-info {
    width: 100%;
  }
  
  .pedido-monto {
    align-self: flex-end;
    font-size: 1.1rem;
  }
  
  /* Historial de cajas responsive */
  .historial-caja-item {
    padding: 0.75rem;
  }
  
  .historial-caja-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .historial-caja-tiempo {
    text-align: left;
    width: 100%;
  }
  
  .resumen-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
  }
  
  .resumen-label {
    font-size: 0.7rem;
  }
  
  .resumen-valor {
    font-size: 0.9rem;
  }
  
  /* Modal de detalle responsive */
  .detalle-financiero {
    padding: 0.75rem;
  }
  
  .detalle-monto {
    font-size: 1rem;
  }
  
  .stat-simple {
    padding: 0.75rem;
  }
  
  .stat-numero {
    font-size: 1.25rem;
  }
  
  /* Resumen de movimientos en móvil - 2 arriba, 1 abajo */
  .caja-resumen-mobile {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1rem;
  }
  
  .caja-resumen-mobile .stat-card:last-child {
    grid-column: 1 / -1;
    max-width: 280px;
    margin: 0 auto;
  }
  
  /* Action grid para móvil - 2x2 */
  .action-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
  }
  
  .action-grid .action-button {
    min-height: 70px;
    font-size: 0.9rem;
    padding: 0.75rem;
  }
  
  .action-grid .action-button i {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
  }
  
  .action-grid .action-button span {
    font-size: 0.85rem;
  }
  
  /* Lista de movimientos más compacta */
  .movimiento-item {
    padding: 0.75rem;
  }
  
  .movimiento-icon {
    width: 35px;
    height: 35px;
    margin-right: 0.75rem;
  }
  
  .movimiento-icon i {
    font-size: 1rem;
  }
  
  .movimiento-concepto {
    font-size: 0.9rem;
    margin-bottom: 0.2rem;
  }
  
  .movimiento-info {
    font-size: 0.75rem;
  }
  
  .movimiento-monto {
    font-size: 1rem;
  }
  
  /* Estado de caja más compacto */
  .caja-estado-mobile {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
  }
  
  /* Stat cards más pequeñas en móvil */
  .stat-card {
    padding: 1rem;
  }
  
  .stat-icon {
    width: 35px;
    height: 35px;
    margin-bottom: 0.5rem;
  }
  
  .stat-icon i {
    font-size: 1.2rem;
  }
  
  .stat-value {
    font-size: 1.2rem;
    margin-bottom: 0.25rem;
  }
  
  .stat-label {
    font-size: 0.8rem;
  }
  
  /* Headers más compactos */
  .page-header-mobile h2 {
    font-size: 1.4rem;
  }
  
  .badge.fs-6 {
    font-size: 0.75rem !important;
    padding: 0.25rem 0.5rem;
  }
  
  /* Modales más centrados */
  .modal-dialog {
    margin: 1rem;
  }
  
  .modal-content {
    border-radius: var(--border-radius);
  }
  
  /* Cards personalizadas en móvil */
  .card-custom {
    margin-bottom: 1rem;
  }
  
  .card-header-custom {
    padding: 0.75rem 1rem;
    font-size: 0.9rem;
  }
  
  .card-body-custom {
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  /* Margen adicional en contenido para caja */
  .caja-resumen-mobile .fade-in {
    margin-bottom: 1.5rem;
  }
  
  /* Extra pequeño - todo en columna */
  .caja-resumen-mobile {
    grid-template-columns: 1fr;
  }
  
  .caja-resumen-mobile .stat-card:last-child {
    grid-column: 1;
  }
  
  .caja-estado-mobile {
    grid-template-columns: 1fr;
  }
  
  .action-grid {
    grid-template-columns: 1fr;
  }
  
  .action-grid .action-button {
    min-height: 60px;
  }
  
  /* Texto más pequeño en pantallas muy pequeñas */
  .stat-value {
    font-size: 1.1rem;
  }
  
  .movimiento-concepto {
    font-size: 0.85rem;
  }
  
  .movimiento-monto {
    font-size: 0.95rem;
  }
}

/* ===== PWA ESPECÍFICO ===== */
.pwa-install-prompt {
  position: fixed;
  bottom: 100px;
  left: 1rem;
  right: 1rem;
  background: var(--white);
  border-radius: var(--border-radius);
  padding: 1rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  z-index: 1010;
  display: none;
}

.offline-indicator {
  position: fixed;
  top: 70px;
  left: 1rem;
  right: 1rem;
  background: var(--warning-color);
  color: var(--dark-color);
  padding: 0.75rem;
  border-radius: var(--border-radius);
  text-align: center;
  font-weight: 600;
  z-index: 1025;
  display: none;
}

/* === PEDIDOS BARRA === */

/* Header de secciones */
.section-header {
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.section-header h5 {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Grid de productos */
.productos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}

@media (max-width: 768px) {
  .productos-grid {
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
    gap: 0.6rem;
  }
}

@media (max-width: 480px) {
  .productos-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
    gap: 0.5rem;
  }
}

@media (max-width: 360px) {
  .productos-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.4rem;
  }
}

/* Items de producto - Diseño simplificado similar a stat-card */
.producto-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem 0.75rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  min-height: 80px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
  box-shadow: var(--box-shadow);
}

.producto-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-coral) 0%, var(--accent-cyan) 100%);
}

.producto-item.disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.producto-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius);
  color: var(--warning-color);
  font-size: 1.2rem;
}

.producto-item:hover:not(.disabled) {
  transform: translateY(-2px);
  box-shadow: var(--box-shadow-hover);
  border-color: var(--accent-cyan);
}

.producto-item:active:not(.disabled) {
  transform: translateY(0);
}

.producto-name {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  line-height: 1.2;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.producto-price {
  color: var(--accent-coral);
  font-weight: 700;
  font-size: 1rem;
  margin: 0;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

@media (max-width: 768px) {
  .producto-item {
    padding: 0.75rem 0.5rem;
    min-height: 70px;
  }
  
  .producto-name {
    font-size: 0.8rem;
    margin-bottom: 0.4rem;
  }
  
  .producto-price {
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .producto-item {
    padding: 0.6rem 0.4rem;
    min-height: 60px;
  }
  
  .producto-name {
    font-size: 0.75rem;
    margin-bottom: 0.3rem;
  }
  
  .producto-price {
    font-size: 0.85rem;
  }
}

/* Botones de acciones de productos */
.productos-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}

.productos-actions .btn {
  min-width: 140px;
  font-weight: 600;
  border-radius: var(--border-radius);
  padding: 0.75rem 1.5rem;
  transition: var(--transition);
}

@media (max-width: 768px) {
  .productos-actions {
    gap: 0.5rem;
  }
  
  .productos-actions .btn {
    min-width: 120px;
    padding: 0.6rem 1rem;
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .productos-actions {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .productos-actions .btn {
    min-width: auto;
    width: 100%;
  }
}

/* Modal de edición de líneas */
#modalEditarLinea .producto-info {
  border-left: 3px solid var(--accent-cyan);
}

#modalEditarLinea .producto-nombre {
  color: var(--text-primary);
  font-size: 1.1rem;
}

#modalEditarLinea .producto-precio {
  color: var(--accent-coral);
  font-weight: 600;
}

#modalEditarLinea .input-group .btn {
  border-color: var(--border-color);
}

#modalEditarLinea .input-group .btn:hover {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

#modalEditarLinea .form-control {
  border-color: var(--border-color);
}

#modalEditarLinea .form-control:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 0.2rem rgba(var(--accent-cyan-rgb), 0.25);
}

#modalEditarLinea textarea.form-control {
  resize: vertical;
  min-height: 80px;
}

#modalEditarLinea .alert {
  border: none;
  font-weight: 600;
}

@media (max-width: 768px) {
  #modalEditarLinea .modal-dialog {
    margin: 0.5rem;
    max-width: calc(100% - 1rem);
  }
  
  #modalEditarLinea .input-group .btn {
    padding: 0.5rem;
    font-size: 0.9rem;
  }
  
  #modalEditarLinea .form-control {
    font-size: 0.9rem;
  }
}

/* === MODAL BÚSQUEDA DE PRODUCTOS === */

/* Filtros de búsqueda */
.busqueda-filtros .input-group-text {
  border-right: none;
}

.busqueda-filtros .form-control {
  border-left: none;
  border-right: none;
}

.busqueda-filtros .form-control:focus {
  border-color: var(--accent-cyan);
  box-shadow: none;
}

.busqueda-filtros .btn-outline-danger {
  border-left: none;
  border-color: var(--border-color);
}

.busqueda-filtros .btn-outline-danger:hover {
  background-color: var(--danger-color);
  border-color: var(--danger-color);
}

/* Header de resultados */
.resultados-header {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.75rem;
}

.view-toggle .btn-group .btn {
  border-color: var(--border-color);
  color: var(--text-secondary);
}

.view-toggle .btn-group .btn.active {
  background-color: var(--accent-cyan);
  border-color: var(--accent-cyan);
  color: var(--dark-color);
}

.view-toggle .btn-group .btn:hover:not(.active) {
  background-color: var(--bg-card);
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
}

/* Vista Grid de productos */
.productos-busqueda-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 1rem;
  max-height: 400px;
  overflow-y: auto;
  padding: 0.5rem;
}

.producto-busqueda-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  text-align: center;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.producto-busqueda-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-coral) 0%, var(--accent-cyan) 100%);
}

.producto-busqueda-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--box-shadow-hover);
  border-color: var(--accent-cyan);
}

.producto-busqueda-nombre {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
  line-height: 1.3;
}

.producto-busqueda-precio {
  color: var(--accent-coral);
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.producto-busqueda-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
  line-height: 1.2;
  opacity: 0.8;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Vista Lista de productos */
.productos-busqueda-lista {
  max-height: 400px;
  overflow-y: auto;
  padding: 0.5rem;
}

.producto-busqueda-fila {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  transition: var(--transition);
  border-left: 3px solid var(--accent-cyan);
}

.producto-busqueda-fila:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--accent-cyan);
  transform: translateX(4px);
}

.producto-busqueda-fila:last-child {
  margin-bottom: 0;
}

.producto-busqueda-fila .producto-busqueda-nombre {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.producto-busqueda-fila .producto-busqueda-precio {
  color: var(--accent-coral);
  font-weight: 700;
  font-size: 1.1rem;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
}

.producto-busqueda-fila .producto-busqueda-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
  opacity: 0.8;
}

/* Scrollbars personalizados */
.productos-busqueda-grid::-webkit-scrollbar,
.productos-busqueda-lista::-webkit-scrollbar {
  width: 6px;
}

.productos-busqueda-grid::-webkit-scrollbar-track,
.productos-busqueda-lista::-webkit-scrollbar-track {
  background: var(--bg-secondary);
  border-radius: 3px;
}

.productos-busqueda-grid::-webkit-scrollbar-thumb,
.productos-busqueda-lista::-webkit-scrollbar-thumb {
  background: var(--accent-cyan);
  border-radius: 3px;
}

.productos-busqueda-grid::-webkit-scrollbar-thumb:hover,
.productos-busqueda-lista::-webkit-scrollbar-thumb:hover {
  background: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
  .productos-busqueda-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 0.75rem;
    max-height: 350px;
  }
  
  .producto-busqueda-item {
    padding: 0.75rem;
  }
  
  .producto-busqueda-nombre {
    font-size: 0.9rem;
  }
  
  .producto-busqueda-precio {
    font-size: 1rem;
  }
  
  .busqueda-filtros .row > div {
    margin-bottom: 0.5rem;
  }
  
  .resultados-header .d-flex {
    flex-direction: column;
    gap: 0.5rem;
    align-items: flex-start !important;
  }
  
  .view-toggle {
    align-self: flex-end;
  }
}

@media (max-width: 480px) {
  .productos-busqueda-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
    max-height: 300px;
  }
  
  .producto-busqueda-item {
    padding: 0.6rem;
  }
  
  .producto-busqueda-nombre {
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
  }
  
  .producto-busqueda-precio {
    font-size: 0.95rem;
    margin-bottom: 0.4rem;
  }
  
  .producto-busqueda-desc {
    font-size: 0.75rem;
    margin-bottom: 0.5rem;
  }
  
  .producto-busqueda-fila {
    padding: 0.75rem;
  }
  
  .producto-busqueda-fila .row {
    --bs-gutter-x: 0.5rem;
  }
  
  #modalBuscarProductos .modal-dialog {
    margin: 0.25rem;
    max-width: calc(100% - 0.5rem);
  }
  
  .busqueda-filtros .col-md-8,
  .busqueda-filtros .col-md-4 {
    width: 100%;
  }
}

/* Pedido actual */
.pedido-vacio {
  padding: 3rem 1rem;
}

.pedido-vacio i {
  opacity: 0.3;
}

/* Líneas de pedido */
.lineas-pedido {
  margin-bottom: 1.5rem;
}

.linea-pedido-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
}

.linea-info {
  flex: 1;
  cursor: pointer;
  min-width: 0;
}

.linea-info:hover {
  opacity: 0.8;
}

.linea-titulo {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: 0.25rem;
  color: var(--light-color);
}

.linea-calculo {
  font-size: 0.9rem;
  color: var(--secondary-text);
  margin-bottom: 0.25rem;
}

.linea-obs {
  font-size: 0.85rem;
  color: var(--accent-color);
  font-style: italic;
  padding: 0.25rem 0.5rem;
  background: rgba(255, 193, 7, 0.1);
  border-radius: var(--border-radius-sm);
  margin-top: 0.5rem;
}

/* Controles de línea */
.linea-controles {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-shrink: 0;
  flex-wrap: wrap;
}

.linea-controles .btn {
  min-width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  border-width: 1px;
}

@media (max-width: 768px) {
  .linea-controles {
    gap: 0.2rem;
  }
  
  .linea-controles .btn {
    min-width: 28px;
    height: 28px;
    font-size: 0.8rem;
  }
  
  .cantidad-display {
    font-size: 1rem;
    min-width: 25px;
    margin: 0 0.2rem;
  }
}

@media (max-width: 480px) {
  .linea-controles {
    justify-content: center;
    width: 100%;
    margin-top: 0.5rem;
  }
  
  .linea-pedido-item {
    flex-direction: column;
  }
  
  .linea-info {
    width: 100%;
    margin-bottom: 0.5rem;
  }
}

.cantidad-display {
  font-weight: 700;
  font-size: 1.1rem;
  min-width: 30px;
  text-align: center;
  color: var(--primary-color);
  margin: 0 0.25rem;
}

/* Totales del pedido */
.pedido-total {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1.25rem;
}

.total-linea {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.total-linea:last-child {
  margin-bottom: 0;
}

.total-final {
  border-top: 1px solid var(--border-color);
  padding-top: 0.75rem;
  margin-top: 0.75rem;
  font-size: 1.1rem;
}

.total-final span {
  font-weight: 700 !important;
}

/* Historial de pedidos */
.historial-pedido-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  transition: all 0.2s ease;
}

.historial-pedido-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--primary-color);
}

.pedido-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.pedido-info {
  flex: 1;
}

.pedido-info strong {
  color: var(--light-color);
}

.pedido-total {
  text-align: right;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--success-color);
}

.pedido-fecha {
  font-size: 0.85rem;
  color: var(--secondary-text);
}

/* Responsive para móvil */
@media (max-width: 768px) {
  .linea-pedido-item {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .linea-controles {
    justify-content: center;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border-color);
  }
  
  .productos-actions {
    justify-content: center;
  }
  
  .productos-actions .btn {
    flex: 1;
    min-width: 100px;
  }
  
  .pedido-header {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .pedido-total {
    text-align: left;
  }
}

/* Estados de botones */
.btn-outline-danger:not(:disabled):hover,
.btn-outline-danger:not(:disabled):focus {
  background-color: var(--danger-color) !important;
  border-color: var(--danger-color) !important;
  color: white !important;
}

.btn-outline-success:not(:disabled):hover,
.btn-outline-success:not(:disabled):focus {
  background-color: var(--success-color) !important;
  border-color: var(--success-color) !important;
  color: white !important;
}

/* Animaciones */
.linea-pedido-item {
  animation: slideIn 0.3s ease-out;
}

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

.producto-item {
  animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Mejoras visuales */
.card .card-header {
  position: relative;
}

.card .card-header .btn {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.productos-destacados h6 {
  color: var(--primary-color);
  font-weight: 600;
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
  display: inline-block;
}

/* ===== MODAL DE PAGO ===== */
.payment-summary {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
}

.summary-item {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.summary-item.total {
  border-top: 1px solid var(--border-color);
  padding-top: 0.5rem;
  margin-top: 0.5rem;
  font-size: 1.1rem;
}

.payment-method-card {
  border: 2px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.05);
}

.payment-method-card:hover {
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.1);
  transform: translateY(-2px);
  box-shadow: var(--box-shadow);
}

.payment-method-card.selected {
  border-color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.2);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.payment-method-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  color: var(--accent-cyan);
}

.payment-method-name {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.payment-details {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
}

#cambio-display.positive {
  color: var(--accent-green) !important;
  font-weight: bold;
}

#cambio-display.negative {
  color: var(--accent-red) !important;
  font-weight: bold;
}

/* Responsive modal de pago */
@media (max-width: 768px) {
  .payment-methods .col-md-4 {
    flex: 0 0 100%;
    max-width: 100%;
  }
  
  .payment-method-card {
    margin-bottom: 0.5rem;
  }
  
  .modal-xl {
    max-width: 95%;
  }
}

/* ===== PEDIDOS DE MESA ===== */
.pedido-activo-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: var(--transition);
}

.pedido-activo-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent-cyan);
}

.pedido-activo-item.selected {
  background: rgba(var(--primary-rgb), 0.2);
  border-color: var(--primary-color);
  box-shadow: 0 0 10px rgba(var(--primary-rgb), 0.3);
}

.pedido-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.pedido-info {
  flex: 1;
}

.pedido-tiempo {
  flex-shrink: 0;
}

.reserva-info {
  margin-top: 0.25rem;
}

.pedido-observaciones {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.pedido-vacio {
  padding: 3rem 1rem;
  color: var(--text-muted);
}

.pedido-seleccionado {
  max-height: 70vh;
  overflow-y: auto;
}

/* Líneas de pedido mesa */
.linea-pedido-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 0.75rem;
  margin-bottom: 0.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.linea-titulo {
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.linea-calculo {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.linea-obs {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-style: italic;
}

.linea-controles {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex-shrink: 0;
}

.cantidad-display {
  font-weight: bold;
  min-width: 30px;
  text-align: center;
  color: var(--primary-color);
  margin: 0 0.25rem;
}

/* Totales de pedido mesa */
.pedido-total {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-top: 1rem;
}

.total-linea {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
}

.total-linea.total-final {
  border-top: 1px solid var(--border-color);
  padding-top: 0.5rem;
  margin-top: 0.5rem;
  font-size: 1rem;
}

/* Productos grid para mesa */
.producto-item.disabled {
  opacity: 0.4;
  cursor: not-allowed;
  position: relative;
}

.producto-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: var(--border-radius);
  color: var(--text-muted);
  font-size: 0.8rem;
}

.producto-overlay i {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
}

/* Responsive para pedidos mesa */
@media (max-width: 768px) {
  .linea-pedido-item {
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
  }
  
  .linea-controles {
    justify-content: center;
    border-top: 1px solid var(--border-color);
    padding-top: 0.5rem;
  }
  
  .pedido-header {
    flex-direction: column;
    gap: 0.25rem;
  }
}

/* ===== HISTORIAL DE PEDIDOS ===== */
.historial-pedido-item {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 0.75rem;
  transition: var(--transition);
}

.historial-pedido-item:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--accent-cyan);
}

.pedido-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

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

.pedido-acciones {
  flex-shrink: 0;
  margin-left: 1rem;
}

.pago-info {
  opacity: 0.8;
}

.pedido-fecha {
  border-top: 1px solid var(--border-color);
  padding-top: 0.5rem;
  opacity: 0.7;
}

.badge {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

.badge.bg-success {
  background-color: var(--accent-green) !important;
  color: #000 !important;
}

/* Responsive historial */
@media (max-width: 768px) {
  .pedido-header {
    flex-direction: column;
    align-items: stretch;
  }
  
  .pedido-acciones {
    margin-left: 0;
    margin-top: 0.5rem;
    justify-content: space-between;
    padding-top: 0.5rem;
    border-top: 1px solid var(--border-color);
  }
  
  .historial-pedido-item {
    padding: 0.75rem;
  }
}

/* ===== ESTILOS PARA EL PERFIL DE USUARIO ===== */
.user-profile-link {
  transition: var(--transition);
  border-radius: var(--border-radius-sm);
  padding: 0.25rem 0.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.user-profile-link:hover {
  background-color: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

.user-profile-link:active {
  transform: translateY(0);
}

.user-profile-link small {
  font-weight: 500;
  letter-spacing: 0.5px;
}

.user-profile-link i {
  font-size: 0.9em;
  opacity: 0.8;
}

/* Estilos para el modal de edición de perfil */
#editProfileModal .modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
}

#editProfileModal .modal-header {
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
  border-radius: var(--border-radius) var(--border-radius) 0 0;
}

#editProfileModal .modal-title {
  color: var(--text-primary);
  font-weight: 600;
}

#editProfileModal .modal-body {
  background: var(--bg-card);
  color: var(--text-primary);
}

#editProfileModal .modal-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  border-radius: 0 0 var(--border-radius) var(--border-radius);
}

#editProfileModal .form-label {
  color: var(--text-primary);
  font-weight: 500;
  margin-bottom: 0.5rem;
}

#editProfileModal .form-control {
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  border-radius: var(--border-radius-sm);
  transition: var(--transition);
}

#editProfileModal .form-control:focus {
  background: var(--bg-primary);
  border-color: var(--accent-cyan);
  color: var(--text-primary);
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
}

#editProfileModal .form-control::placeholder {
  color: var(--text-muted);
}

#editProfileModal .form-text {
  color: var(--text-muted);
  font-size: 0.875rem;
}

#editProfileModal hr {
  border-color: var(--border-color);
  opacity: 0.5;
}

#editProfileModal .btn {
  border-radius: var(--border-radius-sm);
  font-weight: 500;
  transition: var(--transition);
}

#editProfileModal .btn-primary {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
}

#editProfileModal .btn-primary:hover {
  background: #0891b2;
  border-color: #0891b2;
  transform: translateY(-1px);
}

#editProfileModal .btn-secondary {
  background: var(--bg-secondary);
  border-color: var(--border-color);
  color: var(--text-secondary);
}

#editProfileModal .btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--accent-cyan);
  color: var(--text-primary);
}

/* Responsive para el modal de perfil */
@media (max-width: 768px) {
  #editProfileModal .modal-dialog {
    margin: 1rem;
    max-width: calc(100% - 2rem);
  }
  
  .user-profile-link {
    padding: 0.5rem;
  }
  
  .user-profile-link small {
    font-size: 0.875rem;
  }
}

@media (max-width: 480px) {
  .user-profile-link {
    padding: 0.25rem;
  }
  
  .user-profile-link small {
    font-size: 0.8rem;
  }
  
  #editProfileModal .modal-dialog {
    margin: 0.5rem;
    max-width: calc(100% - 1rem);
  }
}

/* ===== ESTILOS PARA TOGGLE DE CONTRASEÑAS ===== */
.password-toggle {
  border-left: 1px solid var(--border-color);
  background: var(--bg-secondary);
  color: var(--text-secondary);
  transition: var(--transition);
  min-width: 45px;
}

.password-toggle:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--accent-cyan);
}

.password-toggle:focus {
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
  border-color: var(--accent-cyan);
}

.password-toggle i {
  font-size: 0.875rem;
  transition: var(--transition);
}

.password-toggle:hover i {
  color: var(--accent-cyan);
}

/* Estilos para input-group con toggle */
#editProfileModal .input-group {
  border-radius: var(--border-radius-sm);
  overflow: hidden;
}

#editProfileModal .input-group .form-control {
  border-right: none;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

#editProfileModal .input-group .password-toggle {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-left: 1px solid var(--border-color);
}

/* Responsive para toggle de contraseñas */
@media (max-width: 768px) {
  .password-toggle {
    min-width: 40px;
    padding: 0.375rem 0.5rem;
  }
  
  .password-toggle i {
    font-size: 0.8rem;
  }
}

@media (max-width: 480px) {
  .password-toggle {
    min-width: 35px;
    padding: 0.25rem 0.375rem;
  }
  
  .password-toggle i {
    font-size: 0.75rem;
  }
}

/* ===== ESTILOS PARA ESTADÍSTICAS CLICKEABLES ===== */
.clickable-stat {
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.clickable-stat:hover {
  transform: translateY(-4px);
  box-shadow: var(--box-shadow-hover);
  border-color: var(--accent-cyan);
}

.clickable-stat:active {
  transform: translateY(-2px);
}

.clickable-stat::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(6, 182, 212, 0.1), transparent);
  transition: left 0.5s;
}

.clickable-stat:hover::before {
  left: 100%;
}

.stat-hint {
  margin-top: 0.5rem;
  opacity: 0.7;
  transition: var(--transition);
}

.clickable-stat:hover .stat-hint {
  opacity: 1;
  color: var(--accent-cyan);
}

.clickable-stat:hover .stat-hint i {
  transform: translateX(2px);
}

.clickable-stat .stat-hint i {
  transition: var(--transition);
  margin-left: 0.25rem;
}

/* Responsive para estadísticas clickeables */
@media (max-width: 768px) {
  .clickable-stat:hover {
    transform: translateY(-2px);
  }
  
  .stat-hint {
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .clickable-stat:hover {
    transform: translateY(-1px);
  }
  
  .stat-hint {
    font-size: 0.7rem;
  }
}

/* ===== ESTILOS PARA SALDO CLICKEABLE ===== */
.clickable-saldo {
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.clickable-saldo:hover {
  transform: scale(1.05);
  text-shadow: 0 0 10px rgba(6, 182, 212, 0.5);
  color: var(--accent-cyan);
}

.clickable-saldo:active {
  transform: scale(1.02);
}

.clickable-saldo::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(6, 182, 212, 0.2), transparent);
  transition: left 0.6s;
}

.clickable-saldo:hover::before {
  left: 100%;
}

/* Responsive para saldo clickeable */
@media (max-width: 768px) {
  .clickable-saldo:hover {
    transform: scale(1.03);
  }
}

@media (max-width: 480px) {
  .clickable-saldo:hover {
    transform: scale(1.02);
  }
}

/* ===== NOTIFICACIÓN DE NUEVA VERSIÓN ===== */
#newVersionNotification {
  animation: slideDown 0.5s ease-out;
  border-left: 4px solid var(--accent-cyan) !important;
}

#newVersionNotification .btn-light {
  background: rgba(255, 255, 255, 0.9) !important;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  color: var(--bg-primary) !important;
  font-weight: 500 !important;
  transition: all 0.3s ease !important;
}

#newVersionNotification .btn-light:hover {
  background: rgba(255, 255, 255, 1) !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
}

#newVersionNotification .btn-light i {
  margin-right: 4px;
  animation: spin 1s linear infinite;
}

@keyframes slideDown {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

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

/* Responsive para notificación de nueva versión */
@media (max-width: 768px) {
  #newVersionNotification {
    left: 10px !important;
    right: 10px !important;
    top: 10px !important;
  }
  
  #newVersionNotification .d-flex {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  #newVersionNotification .ms-3 {
    margin-left: 0 !important;
    margin-top: 0.5rem;
  }
  
  #newVersionNotification .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
  }
}

@media (max-width: 480px) {
  #newVersionNotification {
    font-size: 0.875rem;
  }
  
  #newVersionNotification strong {
    font-size: 1rem;
  }
  
  #newVersionNotification small {
    font-size: 0.75rem;
  }
  
  #newVersionNotification .btn-sm {
    padding: 0.2rem 0.4rem;
    font-size: 0.8rem;
  }
}

/* ===== ESTILOS PARA BOTONES DE HISTORIAL DE PEDIDOS ===== */
.pedido-acciones .btn-group {
  gap: 0.25rem;
}

.pedido-acciones .btn-group .btn {
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  border-radius: 0.375rem;
}

.pedido-acciones .btn-group .btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* Estilos para el modal de detalle del pedido */
.pedido-info-detail {
  background: var(--bg-secondary);
  border-radius: var(--border-radius);
  padding: 1rem;
  margin-bottom: 1.5rem;
}

.pedido-info-detail h6 {
  color: var(--accent-cyan);
  margin-bottom: 1rem;
}

.lineas-pedido-detail .table {
  margin-bottom: 0;
}

.lineas-pedido-detail .table th {
  background: var(--bg-secondary);
  border-color: var(--border-color);
  color: var(--text-primary);
  font-weight: 600;
}

.lineas-pedido-detail .table td {
  border-color: var(--border-color);
  color: var(--text-primary);
  vertical-align: middle;
}

.lineas-pedido-detail .table tbody tr:hover {
  background: var(--bg-card-hover);
}

.totales-detail .card {
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
}

.totales-detail .card-body {
  padding: 1rem;
}

.totales-detail hr {
  border-color: var(--border-color);
  margin: 0.5rem 0;
}

/* Responsive para botones de historial */
@media (max-width: 768px) {
  .pedido-acciones .btn-group {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .pedido-acciones .btn-group .btn {
    width: 100%;
    justify-content: center;
  }
  
  .pedido-acciones .pedido-total {
    margin-right: 0.5rem !important;
  }
}

@media (max-width: 480px) {
  .pedido-acciones .btn-group .btn {
    padding: 0.2rem 0.4rem;
    font-size: 0.8rem;
  }
  
  .pedido-acciones .pedido-total {
    font-size: 0.875rem;
  }
  
  .pedido-info-detail {
    padding: 0.75rem;
  }
  
  .lineas-pedido-detail .table {
    font-size: 0.875rem;
  }
  
  .lineas-pedido-detail .table th,
  .lineas-pedido-detail .table td {
    padding: 0.5rem 0.25rem;
  }
}

/* ===== SISTEMA DE NOTIFICACIONES ===== */

.notifications-widget {
  position: relative;
  display: inline-block;
}

.notifications-button {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  border-radius: 8px;
  width: 40px;
  height: 40px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
}

.notifications-button:hover {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(6, 182, 212, 0.3);
}

.notifications-button:hover i {
  color: var(--bg-primary);
}

.notifications-button i {
  font-size: 1.1rem;
  color: var(--text-primary);
}

.notification-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #ef4444;
  color: white;
  border-radius: 50%;
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  min-width: 18px;
  border: 2px solid var(--bg-card);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  z-index: 10;
  opacity: 1;
  visibility: visible;
  pointer-events: none;
}

.notification-badge.hidden {
  opacity: 0;
  visibility: hidden;
  display: none !important;
}

.notifications-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  width: 320px;
  max-width: 90vw;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow-hover);
  z-index: 1050;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: var(--transition);
  margin-top: 0.5rem;
}

.notifications-dropdown.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.notifications-header {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notifications-header h6 {
  margin: 0;
  color: var(--text-primary);
  font-weight: 600;
}

.notifications-header .btn {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

.notifications-list {
  max-height: 400px;
  overflow-y: auto;
}

.notification-item {
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
  transition: var(--transition);
  cursor: pointer;
}

.notification-item:hover {
  background: var(--bg-card-hover);
}

.notification-item:last-child {
  border-bottom: none;
}

.notification-item.unread {
  background: rgba(6, 182, 212, 0.1);
  border-left: 3px solid var(--accent-cyan);
}

.notification-item.unread:hover {
  background: rgba(6, 182, 212, 0.15);
}

.notification-icon {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
}

.notification-icon.info {
  background: rgba(6, 182, 212, 0.2);
  color: var(--accent-cyan);
}

.notification-icon.warning {
  background: rgba(251, 191, 36, 0.2);
  color: var(--accent-yellow);
}

.notification-icon.error {
  background: rgba(239, 68, 68, 0.2);
  color: var(--accent-red);
}

.notification-icon.success {
  background: rgba(74, 222, 128, 0.2);
  color: var(--accent-green);
}

.notification-icon.system {
  background: rgba(255, 107, 107, 0.2);
  color: var(--accent-coral);
}

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

.notification-title {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
  font-size: 0.875rem;
  line-height: 1.3;
}

.notification-message {
  color: var(--text-secondary);
  font-size: 0.8rem;
  line-height: 1.4;
  margin-bottom: 0.5rem;
}

.notification-time {
  color: var(--text-muted);
  font-size: 0.75rem;
}

.notification-actions {
  display: flex;
  gap: 0.25rem;
}

.notification-actions .btn {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
  min-width: auto;
}

.notifications-empty {
  padding: 2rem 1rem;
  text-align: center;
  color: var(--text-muted);
}

.notifications-empty i {
  font-size: 2rem;
  margin-bottom: 0.5rem;
  opacity: 0.5;
}

.notifications-loading {
  padding: 1rem;
  text-align: center;
  color: var(--text-muted);
}

.notifications-loading i {
  animation: spin 1s linear infinite;
}

.notifications-footer {
  padding: 0.75rem 1rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notifications-footer .btn {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

/* Notificaciones en el header */
.app-header .notifications-widget {
  margin-left: auto;
  margin-right: 1rem;
}

/* Botones del header - mismo tamaño y estilo */
.app-header .btn-outline-light.btn-sm {
  width: 40px;
  height: 40px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 1.1rem;
  transition: var(--transition);
}

.app-header .btn-outline-light.btn-sm:hover {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(6, 182, 212, 0.3);
}

.app-header .btn-outline-light.btn-sm i {
  font-size: 1.1rem;
  color: var(--text-primary);
}

.app-header .btn-outline-light.btn-sm:hover i {
  color: var(--bg-primary);
}

/* Responsive para notificaciones */
@media (max-width: 768px) {
  .notifications-dropdown {
    width: 280px;
    right: -50px;
  }
  
  .notification-item {
    padding: 0.75rem;
  }
  
  .notification-content {
    font-size: 0.875rem;
  }
  
  .notification-title {
    font-size: 0.8rem;
  }
  
  .notification-message {
    font-size: 0.75rem;
  }
  
  /* Botones del header en tablet */
  .app-header .btn-outline-light.btn-sm {
    width: 36px;
    height: 36px;
    font-size: 1rem;
  }
  
  .app-header .btn-outline-light.btn-sm i {
    font-size: 1rem;
  }
  
  .notifications-button {
    width: 36px;
    height: 36px;
  }
  
  .notifications-button i {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .notifications-dropdown {
    width: 260px;
    right: -70px;
  }
  
  .notification-item {
    padding: 0.5rem;
  }
  
  .notification-icon {
    width: 28px;
    height: 28px;
    font-size: 0.8rem;
  }
  
  .notification-title {
    font-size: 0.75rem;
  }
  
  .notification-message {
    font-size: 0.7rem;
  }
  
  .notifications-header h6 {
    font-size: 0.875rem;
  }
  
  .notifications-header .btn {
    font-size: 0.7rem;
    padding: 0.2rem 0.4rem;
  }
  
  /* Botones del header en mobile */
  .app-header .btn-outline-light.btn-sm {
    width: 32px;
    height: 32px;
    font-size: 0.9rem;
  }
  
  .app-header .btn-outline-light.btn-sm i {
    font-size: 0.9rem;
  }
  
  .notifications-button {
    width: 32px;
    height: 32px;
  }
  
  .notifications-button i {
    font-size: 0.9rem;
  }
  
  .notification-badge {
    width: 16px;
    height: 16px;
    font-size: 0.65rem;
    min-width: 16px;
  }
}

/* ===== SISTEMA DE TOAST NOTIFICATIONS ===== */

#toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast-notification {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1rem;
  min-width: 300px;
  max-width: 400px;
  box-shadow: var(--box-shadow-hover);
  transform: translateX(100%);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: auto;
}

.toast-notification.show {
  transform: translateX(0);
  opacity: 1;
}

.toast-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.toast-icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.toast-message {
  flex: 1;
  color: var(--text-primary);
  font-size: 0.9rem;
  line-height: 1.4;
}

.toast-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 4px;
  transition: var(--transition);
  flex-shrink: 0;
}

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

/* Tipos de toast */
.toast-info {
  border-left: 4px solid var(--accent-cyan);
}

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

.toast-success {
  border-left: 4px solid var(--accent-green);
}

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

.toast-warning {
  border-left: 4px solid var(--accent-yellow);
}

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

.toast-error {
  border-left: 4px solid var(--accent-red);
}

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

/* Responsive para toasts */
@media (max-width: 768px) {
  #toast-container {
    top: 10px;
    right: 10px;
    left: 10px;
  }
  
  .toast-notification {
    min-width: auto;
    max-width: none;
  }
  
  .toast-message {
    font-size: 0.85rem;
  }
}

@media (max-width: 480px) {
  #toast-container {
    top: 5px;
    right: 5px;
    left: 5px;
  }
  
  .toast-notification {
    padding: 0.75rem;
  }
  
  .toast-message {
    font-size: 0.8rem;
  }
  
  .toast-icon {
    font-size: 1rem;
  }
}

/* ===== SECCIONES COLAPSABLES ===== */
.collapsible-header {
  cursor: pointer;
  user-select: none;
  transition: var(--transition);
}

.collapsible-header:hover {
  background: var(--bg-card-hover);
}

.collapsible-header .header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.collapsible-header .toggle-icon {
  transition: var(--transition);
  color: var(--text-muted);
}

.collapsible-header:hover .toggle-icon {
  color: var(--text-primary);
}

.collapsible-content {
  max-height: 1000px;
  overflow: hidden;
  transition: max-height 0.3s ease-in-out;
}

.collapsible-content.collapsed {
  max-height: 0;
}

.collapsible-content.collapsed .card-body-custom {
  padding: 0;
  margin: 0;
}

/* Responsive para secciones colapsables */
@media (max-width: 768px) {
  .collapsible-header .header-actions {
    gap: 0.25rem;
  }
  
  .collapsible-header .btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  .collapsible-header h5 {
    font-size: 1rem;
  }
  
  .collapsible-header .badge {
    font-size: 0.7rem;
  }
}

/* ===== RESERVAS MOBILE ===== */
.reserva-mobile-header {
  padding: 0.5rem 0;
}

.reserva-mobile-info h6 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.reserva-mobile-details {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.reserva-mobile-date {
  text-align: right;
  min-width: 60px;
}

.reserva-mobile-date .fw-bold {
  font-size: 1.1rem;
}

.reserva-mobile-contact {
  padding: 0.5rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.reserva-mobile-actions {
  padding-top: 0.75rem;
}

.reserva-mobile-actions .btn-group {
  gap: 0.25rem;
}

.reserva-mobile-actions .btn {
  font-size: 0.75rem;
  padding: 0.375rem 0.5rem;
  white-space: nowrap;
}

.reserva-mobile-actions .btn i {
  font-size: 0.7rem;
}

/* Responsive para reservas móviles */
@media (max-width: 480px) {
  .reserva-mobile-info h6 {
    font-size: 0.9rem;
  }
  
  .reserva-mobile-details {
    gap: 0.25rem;
  }
  
  .reserva-mobile-date {
    min-width: 50px;
  }
  
  .reserva-mobile-date .fw-bold {
    font-size: 1rem;
  }
  
  .reserva-mobile-actions .btn {
    font-size: 0.7rem;
    padding: 0.25rem 0.375rem;
  }
  
  .reserva-mobile-actions .btn i {
    font-size: 0.65rem;
  }
}

@media (max-width: 360px) {
  .reserva-mobile-actions .btn {
    font-size: 0.65rem;
    padding: 0.25rem 0.25rem;
  }
  
  .reserva-mobile-actions .btn i {
    font-size: 0.6rem;
  }
}

/* ===== MESAS MOBILE ===== */
.mesa-mobile-header {
  padding: 0.5rem 0;
}

.mesa-mobile-info h6 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.mesa-mobile-details {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.mesa-mobile-actions {
  padding-top: 0.75rem;
}

.mesa-mobile-actions .btn-group {
  gap: 0.25rem;
}

.mesa-mobile-actions .btn {
  font-size: 0.75rem;
  padding: 0.375rem 0.5rem;
  white-space: nowrap;
}

.mesa-mobile-estado .status {
  font-size: 0.75rem;
  padding: 0.25rem 0.5rem;
}

@media (max-width: 576px) {
  .mesa-mobile-details {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .mesa-mobile-actions .btn {
    font-size: 0.7rem;
    padding: 0.25rem 0.375rem;
  }
}

/* ===== PEDIDOS MOBILE ===== */
.pedido-mobile-header {
  padding: 0.5rem 0;
}

.pedido-mobile-info h6 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.pedido-mobile-total {
  text-align: right;
  min-width: 80px;
}

.pedido-mobile-total .fw-bold {
  font-size: 1.1rem;
  color: var(--accent-coral);
}

.pedido-mobile-details {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem 0;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.pedido-mobile-actions {
  padding-top: 0.75rem;
}

.pedido-mobile-actions .btn-group {
  gap: 0.25rem;
}

.pedido-mobile-actions .btn {
  font-size: 0.75rem;
  padding: 0.375rem 0.5rem;
  white-space: nowrap;
}

@media (max-width: 576px) {
  .pedido-mobile-details {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
  }

  .pedido-mobile-actions .btn {
    font-size: 0.7rem;
    padding: 0.25rem 0.375rem;
  }
}

/* ===== GESTIÓN DE PRODUCTOS ===== */

.tabs-container {
  margin-top: 1rem;
}

.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.tab-btn {
  background: var(--bg-card);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.tab-btn:hover {
  background: var(--bg-card-hover);
  color: var(--text-primary);
  border-color: var(--accent-cyan);
}

.tab-btn.active {
  background: var(--accent-cyan);
  color: var(--bg-primary);
  border-color: var(--accent-cyan);
}

.tab-btn.active i {
  color: var(--bg-primary);
}

.tab-contents {
  position: relative;
}

.tab-content {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.tab-content.active {
  display: block;
}

/* Estilos para la tabla de productos */
.table-responsive {
  border-radius: var(--border-radius-sm);
  overflow: hidden;
}

.table-dark {
  background: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.table-dark thead th {
  background: var(--bg-secondary);
  color: var(--text-primary);
  border-bottom: 2px solid var(--border-color);
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.75rem;
}

.table-dark tbody td {
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem;
  vertical-align: middle;
}

.table-dark tbody tr:hover {
  background: var(--bg-card-hover);
}

/* Estilos para badges de estado */
.badge.bg-success {
  background: var(--accent-green) !important;
  color: var(--bg-primary) !important;
}

.badge.bg-secondary {
  background: var(--text-muted) !important;
  color: var(--text-primary) !important;
}

/* Estilos para botones de acción */
.btn-group-sm .btn {
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
}

.btn-outline-primary {
  background: var(--accent-cyan);
  border-color: var(--accent-cyan);
  color: var(--bg-primary);
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  filter: brightness(0.95);
}

.btn-outline-danger {
  background: var(--accent-red);
  border-color: var(--accent-red);
  color: var(--bg-primary);
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
  filter: brightness(0.95);
}

/* Otros estilos outline pasan a opacos por defecto */
.btn-outline-success {
  background: var(--accent-green);
  border-color: var(--accent-green);
  color: var(--bg-primary);
}
.btn-outline-success:hover,
.btn-outline-success:focus { filter: brightness(0.95); }

.btn-outline-warning {
  background: var(--accent-yellow);
  border-color: var(--accent-yellow);
  color: var(--bg-primary);
}
.btn-outline-warning:hover,
.btn-outline-warning:focus { filter: brightness(0.95); }

.btn-outline-secondary {
  background: var(--bg-secondary);
  border-color: var(--border-color);
  color: var(--text-primary);
}
.btn-outline-secondary:hover,
.btn-outline-secondary:focus { background: var(--bg-card); }

/* Estilos para formularios de modales */
.modal-content .form-control,
.modal-content .form-select {
  background: var(--bg-dark);
  border-color: var(--border-color);
  color: var(--text-primary);
}

.modal-content .form-control:focus,
.modal-content .form-select:focus {
  background: var(--bg-dark);
  border-color: var(--accent-cyan);
  color: var(--text-primary);
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
}

.modal-content .form-check-input {
  background-color: var(--bg-dark);
  border-color: var(--border-color);
}

.modal-content .form-check-input:checked {
  background-color: var(--accent-cyan);
  border-color: var(--accent-cyan);
}

.modal-content .form-check-input:focus {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 0.2rem rgba(6, 182, 212, 0.25);
}

/* Responsive para tabs */
@media (max-width: 768px) {
  .tabs {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .tab-btn {
    justify-content: flex-start;
    padding: 0.75rem 1rem;
  }
  
  .table-responsive {
    font-size: 0.875rem;
  }
  
  .table-dark thead th,
  .table-dark tbody td {
    padding: 0.5rem;
  }
}

@media (max-width: 480px) {
  .tabs {
    margin-bottom: 1rem;
  }
  
  .tab-btn {
    font-size: 0.8rem;
    padding: 0.5rem 0.75rem;
  }
  
  .table-responsive {
    font-size: 0.8rem;
  }
  
  .btn-group-sm .btn {
    padding: 0.2rem 0.4rem;
    font-size: 0.7rem;
  }
}

/* ===== ESTILOS PARA MESAS OCUPADAS ===== */
.mesa-ocupacion-info {
  background: rgba(255, 193, 7, 0.1) !important;
  border-color: #ffc107 !important;
}

.mesa-ocupacion-info .text-warning {
  color: #ffc107 !important;
}

.mesa-reserva-info {
  background: rgba(13, 202, 240, 0.1) !important;
  border-color: #0dcaf0 !important;
}

.mesa-reserva-info .text-info {
  color: #0dcaf0 !important;
}

.mesa-item .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.mesa-item .btn:disabled:hover {
  transform: none;
  box-shadow: none;
}

/* ===== ESTADOS DE MESAS ===== */
.status {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.5rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.025em;
}

.status-success {
  background-color: rgba(74, 222, 128, 0.2);
  color: #4ade80;
  border: 1px solid rgba(74, 222, 128, 0.3);
}

.status-danger {
  background-color: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-warning {
  background-color: rgba(251, 191, 36, 0.2);
  color: #fbbf24;
  border: 1px solid rgba(251, 191, 36, 0.3);
}

.status-secondary {
  background-color: rgba(156, 163, 175, 0.2);
  color: #9ca3af;
  border: 1px solid rgba(156, 163, 175, 0.3);
}

/* ===== RESPONSIVE PARA MESAS ===== */
@media (max-width: 768px) {
  .mesa-ocupacion-info,
  .mesa-reserva-info {
    margin-top: 0.5rem;
  }
  
  .mesa-ocupacion-info .row,
  .mesa-reserva-info .row {
    margin: 0;
  }
  
  .mesa-ocupacion-info .col-md-6,
  .mesa-reserva-info .col-md-6 {
    padding: 0.25rem;
  }
}

@media (max-width: 480px) {
  .mesa-ocupacion-info,
  .mesa-reserva-info {
    padding: 0.5rem !important;
  }
  
  .mesa-ocupacion-info .row,
  .mesa-reserva-info .row {
    flex-direction: column;
  }
  
  .mesa-ocupacion-info .col-md-6,
  .mesa-reserva-info .col-md-6 {
    margin-bottom: 0.25rem;
  }
}

/* ===== ESTILOS PARA CAMPOS DESHABILITADOS ===== */
.form-control:disabled,
.form-select:disabled {
  background-color: rgba(156, 163, 175, 0.2) !important;
  color: #9ca3af !important;
  cursor: not-allowed;
  opacity: 0.6;
}

.form-control:disabled:focus,
.form-select:disabled:focus {
  box-shadow: none !important;
  border-color: var(--border-color) !important;
}

.form-control:disabled::placeholder {
  color: #6b7280 !important;
}