/* ==========================================================================
   STEAMVR DASHBOARD - TEMA PROFESIONAL DEFINITIVO
   Combina estilo gaming con elegancia profesional
   ========================================================================== */

:root {
    /* =====================
       PALETA PROFESIONAL
       ===================== */
    
    /* FONDOS - GRISES OSCUROS ELEGANTES */
    --bg-primary: #0f172a;
    --bg-secondary: #1e293b;
    --bg-tertiary: #2d3748;
    --bg-card: #1e293b;
    --bg-surface: rgba(255, 255, 255, 0.05);
    
    /* COLORES PRIMARIOS - AZULES PROFESIONALES */
    --primary-main: #3b82f6;
    --primary-dark: #2563eb;
    --primary-light: #60a5fa;
    --primary-gradient: linear-gradient(135deg, #3b82f6, #2563eb);
    
    /* COLORES SECUNDARIOS - TOQUES GAMING */
    --secondary-main: #8b5cf6;
    --secondary-dark: #7c3aed;
    --secondary-light: #a78bfa;
    --secondary-gradient: linear-gradient(135deg, #8b5cf6, #7c3aed);
    
    /* COLORES DE ÉXITO */
    --success-main: #10b981;
    --success-dark: #059669;
    --success-light: #34d399;
    --success-gradient: linear-gradient(135deg, #10b981, #059669);
    
    /* COLORES DE ADVERTENCIA */
    --warning-main: #f59e0b;
    --warning-dark: #d97706;
    --warning-light: #fbbf24;
    --warning-gradient: linear-gradient(135deg, #f59e0b, #d97706);
    
    /* COLORES DE ERROR */
    --error-main: #ef4444;
    --error-dark: #dc2626;
    --error-light: #f87171;
    --error-gradient: linear-gradient(135deg, #ef4444, #dc2626);
    
    /* COLORES DE INFORMACIÓN */
    --info-main: #06b6d4;
    --info-dark: #0891b2;
    --info-light: #22d3ee;
    --info-gradient: linear-gradient(135deg, #06b6d4, #0891b2);
    
    /* ACENTOS GAMING */
    --gaming-blue: #00c6ff;
    --gaming-purple: #9d4edd;
    --gaming-green: #00ff88;
    --gaming-pink: #ff0080;
    --gaming-orange: #ff6b00;
    
    /* =====================
       TEXTOS - CONTRASTE PERFECTO
       ===================== */
    --text-primary: #ffffff;
    --text-secondary: #e2e8f0;
    --text-tertiary: #cbd5e1;
    --text-muted: #94a3b8;
    --text-disabled: #64748b;
    
    /* =====================
       BORDES Y SOMBRAS
       ===================== */
    --border-light: #334155;
    --border-medium: #475569;
    --border-dark: #64748b;
    --border-glow: rgba(59, 130, 246, 0.5);
    
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.7), 0 10px 10px -5px rgba(0, 0, 0, 0.1);
    
    /* Sombras con color para efectos especiales */
    --shadow-primary: 0 4px 20px rgba(59, 130, 246, 0.3);
    --shadow-success: 0 4px 20px rgba(16, 185, 129, 0.3);
    --shadow-warning: 0 4px 20px rgba(245, 158, 11, 0.3);
    --shadow-danger: 0 4px 20px rgba(239, 68, 68, 0.3);
    --shadow-purple: 0 4px 20px rgba(139, 92, 246, 0.3);
    
    /* =====================
       ESPACIADO Y BORDES
       ===================== */
    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;
    
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 20px;
    --radius-full: 9999px;
    
    /* =====================
       TRANSICIONES
       ===================== */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
    
    /* =====================
       ANIMACIONES
       ===================== */
    --animation-float: float 3s ease-in-out infinite;
    --animation-pulse: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    --animation-spin: spin 1s linear infinite;
    --animation-slide-in: slideIn 0.3s ease-out;
    --animation-fade-in: fadeIn 0.3s ease-out;
}

/* ==========================================================================
   RESET Y ESTILOS BASE
   ========================================================================== */

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    height: 100%;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Segoe UI Emoji', 'Segoe UI Symbol', 
                 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ==========================================================================
   TIPOGRAFÍA - SOBREESCRIBIENDO BOOTSTRAP
   ========================================================================== */

/* Asegurar que TODOS los textos sean visibles */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    color: var(--text-primary) !important;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--space-4);
}

h1, .h1 {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(90deg, var(--primary-main), var(--secondary-main));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.025em;
}

h2, .h2 {
    font-size: 2rem;
    position: relative;
    padding-bottom: var(--space-3);
}

h2::after, .h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--primary-gradient);
    border-radius: var(--radius-full);
}

h3, .h3 {
    font-size: 1.5rem;
}

h4, .h4 {
    font-size: 1.25rem;
    color: var(--text-secondary) !important;
}

h5, .h5 {
    font-size: 1.125rem;
    color: var(--text-secondary) !important;
}

h6, .h6 {
    font-size: 1rem;
    color: var(--text-tertiary) !important;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Textos especiales */
.text-primary {
    color: var(--primary-main) !important;
}

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

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

.text-danger {
    color: var(--error-main) !important;
}

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

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

.text-white {
    color: #ffffff !important;
}

.text-dark {
    color: var(--text-primary) !important; /* En fondo oscuro, "dark" es blanco */
}

p {
    color: var(--text-secondary) !important;
    margin-bottom: var(--space-4);
    line-height: 1.6;
}

small, .small {
    color: var(--text-tertiary) !important;
    font-size: 0.875rem;
}

/* ==========================================================================
   SIDEBAR ELEGANTE
   ========================================================================== */

.sidebar {
    width: 280px;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border-light);
    box-shadow: var(--shadow-lg);
    z-index: 1050;
    display: flex;
    flex-direction: column;
    padding: var(--space-6);
    overflow-y: auto;
    transition: all var(--transition-normal);
}

/* Brand */
.sidebar-brand {
    padding-bottom: var(--space-6);
    margin-bottom: var(--space-6);
    border-bottom: 1px solid var(--border-light);
    text-align: center;
}

.sidebar-brand h4 {
    font-size: 1.5rem;
    margin-bottom: var(--space-2);
    color: var(--primary-main) !important;
    font-weight: 700;
}

.sidebar-brand .text-muted {
    color: var(--text-muted) !important;
    font-size: 0.875rem;
}

/* User info */
.sidebar .px-3.mb-4 {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    padding: var(--space-4) !important;
    margin: 0 0 var(--space-6) 0 !important;
    border: 1px solid var(--border-light);
}

.sidebar .flex-shrink-0 .bg-primary {
    background: var(--primary-gradient) !important;
}

.sidebar .flex-shrink-0 .text-dark {
    color: white !important;
}

.sidebar .text-truncate.text-primary {
    color: var(--text-primary) !important;
    font-weight: 600;
    font-size: 0.95rem;
}

/* Navigation */
.nav.flex-column {
    gap: var(--space-1);
}

.nav-item {
    margin: 0;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: var(--space-3) var(--space-4) !important;
    color: var(--text-tertiary) !important;
    text-decoration: none;
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
    font-weight: 500;
    border: none;
    background: transparent;
}

.nav-link:hover {
    background: linear-gradient(90deg, 
        rgba(59, 130, 246, 0.1), 
        rgba(139, 92, 246, 0.1));
    color: var(--text-primary) !important;
    transform: translateX(8px);
    border-left: 3px solid var(--primary-main);
}

.nav-link.active {
    background: linear-gradient(90deg, 
        rgba(59, 130, 246, 0.2), 
        rgba(139, 92, 246, 0.2)) !important;
    color: var(--text-primary) !important;
    font-weight: 600;
    border-left: 3px solid var(--primary-main);
}

.nav-link i {
    font-size: 1.25rem;
    margin-right: var(--space-3);
    width: 24px;
    text-align: center;
}

/* Logout button */
.nav-link.text-warning {
    color: var(--warning-main) !important;
}

.nav-link.text-warning:hover {
    background: rgba(245, 158, 11, 0.1) !important;
    color: var(--warning-light) !important;
}

/* ==========================================================================
   CONTENIDO PRINCIPAL
   ========================================================================== */

.main-content {
    margin-left: 280px;
    min-height: 100vh;
    padding: var(--space-8);
    background: var(--bg-primary);
    transition: all var(--transition-normal);
}

/* Header del contenido */
.border-bottom.border-secondary {
    border-bottom-color: var(--border-light) !important;
    padding-bottom: var(--space-4);
    margin-bottom: var(--space-8);
}

/* ==========================================================================
   COMPONENTES ESPECÍFICOS DEL DASHBOARD
   ========================================================================== */

/* User Info Card - FIXED */
.user-info-card {
    background: var(--bg-secondary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    margin-bottom: var(--space-8);
    box-shadow: var(--shadow-md);
}

.user-info-card .card-body {
    padding: 0 !important;
}

.user-info-card .bg-primary.bg-opacity-25 {
    background: rgba(59, 130, 246, 0.2) !important;
    border-radius: var(--radius-full);
}

.user-info-card .text-primary {
    color: var(--primary-main) !important;
}

.user-info-card .badge-success {
    background: var(--success-gradient) !important;
    color: white !important;
    border: none;
}

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

/* Stats Cards */
.stats-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    height: 100%;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.stats-card:hover {
    transform: translateY(-4px);
    border-color: var(--border-glow);
    box-shadow: var(--shadow-lg);
}

.stats-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}

.stats-card-primary::before {
    background: var(--primary-gradient);
}

.stats-card-success::before {
    background: var(--success-gradient);
}

.stats-card-warning::before {
    background: var(--warning-gradient);
}

.stats-card-info::before {
    background: var(--info-gradient);
}

.stats-card .card-title {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: var(--space-2);
    color: var(--text-primary) !important;
}

.stats-card .text-muted {
    color: var(--text-tertiary) !important;
    font-size: 0.875rem;
    margin-bottom: var(--space-3);
}

/* Widget icons */
.widget-icon {
    font-size: 2.5rem;
    opacity: 0.2;
    color: currentColor;
}

/* ==========================================================================
   BOTONES PROFESIONALES - FIXED
   ========================================================================== */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    line-height: 1.5;
    text-align: center;
    text-decoration: none;
    vertical-align: middle;
    cursor: pointer;
    user-select: none;
    border: none;
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
    gap: var(--space-2);
    letter-spacing: 0.025em;
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.5);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.btn:focus:not(:active)::after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    20% {
        transform: scale(25, 25);
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: scale(40, 40);
    }
}

.btn-primary {
    background: var(--primary-gradient) !important;
    color: white !important;
    border: none !important;
    box-shadow: var(--shadow-primary);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.4);
}

.btn-outline-primary {
    background: transparent !important;
    color: var(--primary-main) !important;
    border: 2px solid var(--primary-main) !important;
}

.btn-outline-primary:hover {
    background: rgba(59, 130, 246, 0.1) !important;
    color: var(--primary-light) !important;
    border-color: var(--primary-light) !important;
    transform: translateY(-2px);
}

.btn-success {
    background: var(--success-gradient) !important;
    color: white !important;
    border: none !important;
    box-shadow: var(--shadow-success);
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.4);
}

.btn-warning {
    background: var(--warning-gradient) !important;
    color: white !important;
    border: none !important;
    box-shadow: var(--shadow-warning);
}

.btn-warning:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(245, 158, 11, 0.4);
}

.btn-danger {
    background: var(--error-gradient) !important;
    color: white !important;
    border: none !important;
    box-shadow: var(--shadow-danger);
}

.btn-danger:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
}

.btn-info {
    background: var(--info-gradient) !important;
    color: white !important;
    border: none !important;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
}

.btn-group .btn {
    border-radius: 0;
}

.btn-group .btn:first-child {
    border-top-left-radius: var(--radius-md);
    border-bottom-left-radius: var(--radius-md);
}

.btn-group .btn:last-child {
    border-top-right-radius: var(--radius-md);
    border-bottom-right-radius: var(--radius-md);
}

/* ==========================================================================
   TARJETAS GENERALES
   ========================================================================== */

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    overflow: hidden;
    height: 100%;
}

.card:hover {
    box-shadow: var(--shadow-lg);
    border-color: var(--border-medium);
    transform: translateY(-2px);
}

.card-header {
    background: var(--bg-tertiary) !important;
    border-bottom: 1px solid var(--border-light) !important;
    padding: var(--space-6) var(--space-6) 0 var(--space-6) !important;
}

.card-title {
    font-size: 1.25rem;
    color: var(--text-primary) !important;
    margin-bottom: var(--space-4);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-weight: 600;
}

.card-title i {
    color: var(--primary-main);
    font-size: 1.5rem;
}

.card-body {
    padding: var(--space-6) !important;
    color: var(--text-secondary) !important;
}

.card-footer {
    background: var(--bg-tertiary) !important;
    border-top: 1px solid var(--border-light) !important;
    padding: var(--space-6) !important;
}

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

.table {
    width: 100%;
    color: var(--text-secondary) !important;
    border-collapse: separate;
    border-spacing: 0;
    margin-bottom: 0;
}

.table thead {
    background: var(--bg-tertiary);
}

.table thead th {
    padding: var(--space-4);
    font-weight: 600;
    color: var(--text-primary) !important;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    border-bottom: 2px solid var(--border-light);
    white-space: nowrap;
}

.table tbody tr {
    transition: all var(--transition-fast);
    border-bottom: 1px solid var(--border-light);
    background: var(--bg-card);
}

.table tbody tr:last-child {
    border-bottom: none;
}

.table tbody tr:hover {
    background: linear-gradient(90deg, 
        rgba(59, 130, 246, 0.05), 
        rgba(139, 92, 246, 0.05));
}

.table tbody td {
    padding: var(--space-4);
    vertical-align: middle;
    color: var(--text-secondary) !important;
    font-weight: 500;
}

/* Estados de filas */
.table tbody tr.status-active {
    background: linear-gradient(90deg, 
        rgba(16, 185, 129, 0.1), 
        rgba(5, 150, 105, 0.1));
    border-left: 4px solid var(--success-main);
}

.table tbody tr.status-warning {
    background: linear-gradient(90deg, 
        rgba(245, 158, 11, 0.1), 
        rgba(217, 119, 6, 0.1));
    border-left: 4px solid var(--warning-main);
}

.table tbody tr.status-error {
    background: linear-gradient(90deg, 
        rgba(239, 68, 68, 0.1), 
        rgba(220, 38, 38, 0.1));
    border-left: 4px solid var(--error-main);
}

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

.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border: none;
}

.badge-primary {
    background: linear-gradient(135deg, 
        rgba(59, 130, 246, 0.2), 
        rgba(37, 99, 235, 0.2)) !important;
    color: var(--primary-main) !important;
    border: 1px solid rgba(59, 130, 246, 0.3) !important;
}

.badge-success {
    background: linear-gradient(135deg, 
        rgba(16, 185, 129, 0.2), 
        rgba(5, 150, 105, 0.2)) !important;
    color: var(--success-main) !important;
    border: 1px solid rgba(16, 185, 129, 0.3) !important;
}

.badge-warning {
    background: linear-gradient(135deg, 
        rgba(245, 158, 11, 0.2), 
        rgba(217, 119, 6, 0.2)) !important;
    color: var(--warning-main) !important;
    border: 1px solid rgba(245, 158, 11, 0.3) !important;
}

.badge-danger {
    background: linear-gradient(135deg, 
        rgba(239, 68, 68, 0.2), 
        rgba(220, 38, 38, 0.2)) !important;
    color: var(--error-main) !important;
    border: 1px solid rgba(239, 68, 68, 0.3) !important;
}

.badge-dark {
    background: var(--bg-tertiary) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-light) !important;
}

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

.form-label {
    display: block;
    margin-bottom: var(--space-2);
    color: var(--text-secondary) !important;
    font-weight: 500;
    font-size: 0.875rem;
}

.form-control {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-primary) !important;
    background-color: var(--bg-tertiary) !important;
    background-clip: padding-box;
    border: 1px solid var(--border-light) !important;
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
}

.form-control:focus {
    color: var(--text-primary) !important;
    background-color: var(--bg-tertiary) !important;
    border-color: var(--primary-main) !important;
    outline: 0;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15) !important;
}

.form-select {
    display: block;
    width: 100%;
    padding: 0.75rem 2.25rem 0.75rem 1rem;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 1.5;
    color: var(--text-primary) !important;
    background-color: var(--bg-tertiary) !important;
    border: 1px solid var(--border-light) !important;
    border-radius: var(--radius-md);
    transition: all var(--transition-normal);
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='%23cbd5e1' stroke='none' d='M2 5l6 6 6-6'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 16px 12px;
}

.form-select:focus {
    border-color: var(--primary-main) !important;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15) !important;
}

.form-text {
    color: var(--text-muted) !important;
    font-size: 0.75rem;
}

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

.modal-content {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
}

.modal-header {
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-light);
    padding: var(--space-6);
}

.modal-title {
    font-size: 1.25rem;
    color: var(--text-primary) !important;
    margin-bottom: 0;
}

.modal-body {
    padding: var(--space-6);
    color: var(--text-secondary) !important;
}

.modal-footer {
    background: var(--bg-tertiary);
    border-top: 1px solid var(--border-light);
    padding: var(--space-6);
}

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

/* ==========================================================================
   PROGRESS BARS
   ========================================================================== */

.progress {
    background-color: var(--bg-tertiary) !important;
    border-radius: var(--radius-full);
    height: 8px;
    overflow: hidden;
}

.progress-bar {
    background: var(--primary-gradient);
    border-radius: var(--radius-full);
    transition: width 0.6s ease;
}

.progress-bar.bg-success {
    background: var(--success-gradient) !important;
}

.progress-bar.bg-warning {
    background: var(--warning-gradient) !important;
}

.progress-bar.bg-info {
    background: var(--info-gradient) !important;
}

.progress-bar.bg-danger {
    background: var(--error-gradient) !important;
}

/* ==========================================================================
   ESPECIALES DASHBOARD
   ========================================================================== */

/* Filtros section */
.filter-section {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: var(--space-6);
    margin-bottom: var(--space-6);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: var(--space-12) var(--space-6);
    color: var(--text-tertiary);
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: var(--space-4);
    color: var(--border-medium);
}

.empty-state h4, .empty-state h5 {
    color: var(--text-secondary) !important;
    margin-bottom: var(--space-2);
}

/* Spinner */
.spinner-primary {
    width: 2rem;
    height: 2rem;
    border: 2px solid var(--border-light);
    border-top-color: var(--primary-main);
    border-radius: var(--radius-full);
    animation: var(--animation-spin);
    margin: 0 auto;
}

/* Alertas */
.alert {
    padding: var(--space-4);
    border-radius: var(--radius-md);
    margin-bottom: var(--space-4);
    border: 1px solid;
    background: var(--bg-tertiary);
}

.alert-success {
    background: rgba(16, 185, 129, 0.1) !important;
    border-color: var(--success-main) !important;
    color: var(--success-light) !important;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1) !important;
    border-color: var(--warning-main) !important;
    color: var(--warning-light) !important;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1) !important;
    border-color: var(--error-main) !important;
    color: var(--error-light) !important;
}

.alert-info {
    background: rgba(6, 182, 212, 0.1) !important;
    border-color: var(--info-main) !important;
    color: var(--info-light) !important;
}

/* ==========================================================================
   ANIMACIONES
   ========================================================================== */

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

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

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

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

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

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

/* Espaciado */
.mt-1 { margin-top: var(--space-1) !important; }
.mt-2 { margin-top: var(--space-2) !important; }
.mt-3 { margin-top: var(--space-3) !important; }
.mt-4 { margin-top: var(--space-4) !important; }
.mt-6 { margin-top: var(--space-6) !important; }
.mt-8 { margin-top: var(--space-8) !important; }

.mb-1 { margin-bottom: var(--space-1) !important; }
.mb-2 { margin-bottom: var(--space-2) !important; }
.mb-3 { margin-bottom: var(--space-3) !important; }
.mb-4 { margin-bottom: var(--space-4) !important; }
.mb-6 { margin-bottom: var(--space-6) !important; }
.mb-8 { margin-bottom: var(--space-8) !important; }

.p-3 { padding: var(--space-3) !important; }
.p-4 { padding: var(--space-4) !important; }
.p-6 { padding: var(--space-6) !important; }

/* Display */
.d-flex { display: flex !important; }
.d-none { display: none !important; }
.flex-column { flex-direction: column !important; }
.justify-content-between { justify-content: space-between !important; }
.align-items-center { align-items: center !important; }
.flex-grow-1 { flex-grow: 1 !important; }
.flex-shrink-0 { flex-shrink: 0 !important; }

/* Texto */
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fw-bold { font-weight: 600 !important; }
.fw-bolder { font-weight: 700 !important; }

/* Fondo */
.bg-primary { background: var(--primary-gradient) !important; }
.bg-success { background: var(--success-gradient) !important; }
.bg-warning { background: var(--warning-gradient) !important; }
.bg-danger { background: var(--error-gradient) !important; }
.bg-info { background: var(--info-gradient) !important; }
.bg-secondary { background: var(--bg-secondary) !important; }

.bg-opacity-25 { opacity: 0.25 !important; }

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

@media (max-width: 1200px) {
    .sidebar {
        width: 240px;
    }
    
    .main-content {
        margin-left: 240px;
        padding: var(--space-6);
    }
}

@media (max-width: 992px) {
    .sidebar {
        width: 80px;
        padding: var(--space-4);
    }
    
    .sidebar-brand h3 span,
    .sidebar-brand p,
    .nav-link span,
    .text-truncate.text-primary,
    .logout-btn span {
        display: none !important;
    }
    
    .sidebar-brand h3 {
        font-size: 1.25rem;
    }
    
    .nav-link {
        justify-content: center;
        padding: var(--space-3) !important;
    }
    
    .nav-link i {
        margin-right: 0 !important;
        font-size: 1.5rem;
    }
    
    .main-content {
        margin-left: 80px;
        padding: var(--space-4);
    }
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }
    
    .main-content {
        margin-left: 0;
        padding: var(--space-4);
    }
    
    .card-header,
    .card-body,
    .card-footer {
        padding: var(--space-4) !important;
    }
    
    .user-info-card {
        margin-bottom: var(--space-4);
    }
}

@media (max-width: 576px) {
    :root {
        --space-6: 1rem;
        --space-8: 1.5rem;
    }
    
    h1, .h1 {
        font-size: 2rem;
    }
    
    h2, .h2 {
        font-size: 1.5rem;
    }
    
    .stats-card .card-title {
        font-size: 2rem;
    }
}

/* ==========================================================================
   CLASES DE EMERGENCIA PARA CONFLICTOS
   ========================================================================== */

/* Fuerza colores correctos */
.force-text-primary {
    color: var(--text-primary) !important;
}

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

.force-bg-dark {
    background-color: var(--bg-secondary) !important;
}

/* FIX para elementos específicos */
.dashboard-widget .card-title {
    color: var(--text-primary) !important;
    font-size: 2.5rem !important;
}

.user-info-card h5 {
    color: var(--primary-main) !important;
}

/* Asegurar que las estadísticas en línea sean visibles */
.p-2 h4 {
    color: var(--text-primary) !important;
}

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

/* ==========================================================================
   PAGINACIÓN
   ========================================================================== */

.pagination {
    gap: var(--space-1);
}

.page-link {
    background: var(--bg-tertiary) !important;
    border: 1px solid var(--border-light) !important;
    color: var(--text-secondary) !important;
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-md) !important;
    transition: all var(--transition-fast);
}

.page-link:hover {
    background: var(--bg-surface) !important;
    color: var(--primary-main) !important;
    border-color: var(--primary-main) !important;
}

.page-item.active .page-link {
    background: var(--primary-gradient) !important;
    color: white !important;
    border-color: transparent !important;
    box-shadow: var(--shadow-primary);
}

/* ==========================================================================
   SCROLLBAR PERSONALIZADO
   ========================================================================== */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-light);
    border-radius: var(--radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-medium);
}

/* ==========================================================================
   EFECTOS ESPECIALES
   ========================================================================== */

.glow {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.5);
}

.pulse {
    animation: var(--animation-pulse);
}

.float {
    animation: var(--animation-float);
}

.fade-in {
    animation: var(--animation-fade-in);
}

.slide-in {
    animation: var(--animation-slide-in);
}

/* Hover effects */
.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-main);
}

/* ==========================================================================
   LOGIN PAGE (si la necesitas)
   ========================================================================== */

.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
    padding: var(--space-6);
}

.login-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    width: 100%;
    max-width: 420px;
    padding: var(--space-10);
    border: 1px solid var(--border-light);
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-gradient);
}

.login-header h1 {
    font-size: 2rem;
    margin-bottom: var(--space-2);
}

.login-header p {
    color: var(--text-muted) !important;
    margin-bottom: 0;
}

.login-form .form-group {
    margin-bottom: var(--space-6);
}

.login-btn {
    width: 100%;
    padding: 1rem;
    font-size: 1rem;
    margin-top: var(--space-4);
}

.login-footer {
    margin-top: var(--space-8);
    text-align: center;
    color: var(--text-muted) !important;
    font-size: 0.875rem;
}