/**
 * SIMPLEX - Tema Profesional
 * Sistema de Buró de Crédito Empresarial
 */

/* ===== VARIABLES DE MARCA ===== */
:root {
    /* Colores Corporativos Simplex */
    --simplex-primary: #1e3a8a;      /* Azul corporativo profundo */
    --simplex-secondary: #1e40af;     /* Azul corporativo */
    --simplex-accent: #3b82f6;       /* Azul brillante */
    --simplex-success: #059669;      /* Verde éxito */
    --simplex-warning: #d97706;      /* Naranja advertencia */
    --simplex-danger: #dc2626;       /* Rojo peligro */
    --simplex-info: #0ea5e9;         /* Azul información */
    
    /* Grises Profesionales */
    --simplex-gray-50: #f8fafc;
    --simplex-gray-100: #f1f5f9;
    --simplex-gray-200: #e2e8f0;
    --simplex-gray-300: #cbd5e1;
    --simplex-gray-400: #94a3b8;
    --simplex-gray-500: #64748b;
    --simplex-gray-600: #475569;
    --simplex-gray-700: #334155;
    --simplex-gray-800: #1e293b;
    --simplex-gray-900: #0f172a;
    
    /* Tipografía */
    --simplex-font-primary: 'Inter', 'Segoe UI', system-ui, sans-serif;
    --simplex-font-secondary: 'Source Sans Pro', 'Helvetica Neue', sans-serif;
    
    /* Espaciado */
    --simplex-spacing-xs: 0.25rem;
    --simplex-spacing-sm: 0.5rem;
    --simplex-spacing-md: 1rem;
    --simplex-spacing-lg: 1.5rem;
    --simplex-spacing-xl: 2rem;
    --simplex-spacing-2xl: 3rem;
    
    /* Sombras */
    --simplex-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --simplex-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --simplex-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --simplex-shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Bordes */
    --simplex-border-radius: 0.5rem;
    --simplex-border-radius-lg: 0.75rem;
    --simplex-border-radius-xl: 1rem;
}

/* ===== IMPORTAR FUENTES GOOGLE ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=Source+Sans+Pro:wght@300;400;600;700&display=swap');

/* ===== RESET Y BASE ===== */
* {
    box-sizing: border-box;
}

body {
    font-family: var(--simplex-font-primary);
    font-weight: 400;
    line-height: 1.6;
    color: var(--simplex-gray-700);
    background-color: var(--simplex-gray-50);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== HEADER PROFESIONAL ===== */
.simplex-header {
    background: linear-gradient(135deg, var(--simplex-primary) 0%, var(--simplex-secondary) 100%);
    box-shadow: var(--simplex-shadow-lg);
    border: none;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.simplex-brand {
    font-family: var(--simplex-font-primary);
    font-weight: 800;
    font-size: 1.5rem;
    color: white !important;
    text-decoration: none;
    letter-spacing: -0.025em;
}

.simplex-brand:hover {
    color: var(--simplex-gray-100) !important;
    text-decoration: none;
}

.simplex-brand .brand-accent {
    color: #60a5fa;
    font-weight: 300;
}

/* ===== SIDEBAR PROFESIONAL ===== */
.simplex-sidebar {
    background: white;
    border-right: 1px solid var(--simplex-gray-200);
    box-shadow: var(--simplex-shadow-sm);
    min-height: calc(100vh - 76px);
}

.simplex-sidebar .nav-link {
    color: var(--simplex-gray-600);
    font-weight: 500;
    padding: var(--simplex-spacing-md) var(--simplex-spacing-lg);
    margin: var(--simplex-spacing-xs) var(--simplex-spacing-md);
    border-radius: var(--simplex-border-radius);
    transition: all 0.2s ease;
    position: relative;
}

.simplex-sidebar .nav-link:hover {
    background-color: var(--simplex-gray-100);
    color: var(--simplex-primary);
    transform: translateX(2px);
}

.simplex-sidebar .nav-link.active {
    background: linear-gradient(135deg, var(--simplex-primary), var(--simplex-accent));
    color: white;
    box-shadow: var(--simplex-shadow-md);
}

.simplex-sidebar .nav-link i {
    width: 20px;
    margin-right: var(--simplex-spacing-md);
}

/* ===== NOTIFICACIONES PROFESIONALES ===== */
.notification-indicator {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--simplex-danger);
    animation: pulse-professional 2s infinite;
}

@keyframes pulse-professional {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.2); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}

/* ===== TARJETAS PROFESIONALES ===== */
.simplex-card {
    background: white;
    border: 1px solid var(--simplex-gray-200);
    border-radius: var(--simplex-border-radius-lg);
    box-shadow: var(--simplex-shadow-sm);
    transition: all 0.3s ease;
    overflow: hidden;
}

.simplex-card:hover {
    box-shadow: var(--simplex-shadow-lg);
    transform: translateY(-2px);
}

.simplex-card-header {
    background: linear-gradient(135deg, var(--simplex-gray-50) 0%, white 100%);
    border-bottom: 1px solid var(--simplex-gray-200);
    padding: var(--simplex-spacing-lg) var(--simplex-spacing-xl);
    font-weight: 600;
}

.simplex-card-body {
    padding: var(--simplex-spacing-xl);
}

/* ===== BOTONES PROFESIONALES ===== */
.btn-simplex-primary {
    background: linear-gradient(135deg, var(--simplex-primary), var(--simplex-accent));
    border: none;
    color: white;
    font-weight: 600;
    padding: var(--simplex-spacing-md) var(--simplex-spacing-xl);
    border-radius: var(--simplex-border-radius);
    box-shadow: var(--simplex-shadow-md);
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    font-size: 0.875rem;
}

.btn-simplex-primary:hover {
    background: linear-gradient(135deg, var(--simplex-secondary), var(--simplex-primary));
    box-shadow: var(--simplex-shadow-lg);
    transform: translateY(-1px);
    color: white;
}

.btn-simplex-secondary {
    background: white;
    border: 2px solid var(--simplex-primary);
    color: var(--simplex-primary);
    font-weight: 600;
    padding: calc(var(--simplex-spacing-md) - 2px) calc(var(--simplex-spacing-xl) - 2px);
    border-radius: var(--simplex-border-radius);
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 0.025em;
    font-size: 0.875rem;
}

.btn-simplex-secondary:hover {
    background: var(--simplex-primary);
    color: white;
    transform: translateY(-1px);
    box-shadow: var(--simplex-shadow-md);
}

/* ===== FORMULARIOS PROFESIONALES ===== */
.simplex-form-control {
    border: 2px solid var(--simplex-gray-200);
    border-radius: var(--simplex-border-radius);
    padding: var(--simplex-spacing-md) var(--simplex-spacing-lg);
    font-size: 1rem;
    transition: all 0.2s ease;
    background-color: white;
}

.simplex-form-control:focus {
    border-color: var(--simplex-accent);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    outline: none;
}

.simplex-form-label {
    font-weight: 600;
    color: var(--simplex-gray-700);
    margin-bottom: var(--simplex-spacing-sm);
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

/* ===== BADGES PROFESIONALES ===== */
.badge-simplex-success {
    background: linear-gradient(135deg, var(--simplex-success), #10b981);
    color: white;
    font-weight: 600;
    padding: var(--simplex-spacing-sm) var(--simplex-spacing-md);
    border-radius: 9999px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-simplex-warning {
    background: linear-gradient(135deg, var(--simplex-warning), #f59e0b);
    color: white;
    font-weight: 600;
    padding: var(--simplex-spacing-sm) var(--simplex-spacing-md);
    border-radius: 9999px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-simplex-danger {
    background: linear-gradient(135deg, var(--simplex-danger), #ef4444);
    color: white;
    font-weight: 600;
    padding: var(--simplex-spacing-sm) var(--simplex-spacing-md);
    border-radius: 9999px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    animation: pulse-danger 2s infinite;
}

@keyframes pulse-danger {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* ===== ESTADÍSTICAS PROFESIONALES ===== */
.simplex-stat-card {
    background: white;
    border-radius: var(--simplex-border-radius-lg);
    padding: var(--simplex-spacing-xl);
    box-shadow: var(--simplex-shadow-md);
    border-left: 4px solid var(--simplex-accent);
    transition: all 0.3s ease;
}

.simplex-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--simplex-shadow-xl);
}

.simplex-stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--simplex-primary);
    line-height: 1;
    margin-bottom: var(--simplex-spacing-sm);
}

.simplex-stat-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--simplex-gray-600);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ===== ALERTAS PROFESIONALES ===== */
.simplex-alert {
    border: none;
    border-radius: var(--simplex-border-radius-lg);
    padding: var(--simplex-spacing-lg) var(--simplex-spacing-xl);
    margin-bottom: var(--simplex-spacing-lg);
    border-left: 4px solid;
    background: white;
    box-shadow: var(--simplex-shadow-sm);
}

.simplex-alert-danger {
    border-left-color: var(--simplex-danger);
    background: linear-gradient(135deg, #fef2f2, white);
}

.simplex-alert-warning {
    border-left-color: var(--simplex-warning);
    background: linear-gradient(135deg, #fffbeb, white);
}

.simplex-alert-info {
    border-left-color: var(--simplex-info);
    background: linear-gradient(135deg, #f0f9ff, white);
}

/* ===== TABLAS PROFESIONALES ===== */
.simplex-table {
    background: white;
    border-radius: var(--simplex-border-radius-lg);
    overflow: hidden;
    box-shadow: var(--simplex-shadow-sm);
}

.simplex-table th {
    background: linear-gradient(135deg, var(--simplex-gray-50), var(--simplex-gray-100));
    font-weight: 700;
    color: var(--simplex-gray-700);
    text-transform: uppercase;
    letter-spacing: 0.025em;
    font-size: 0.75rem;
    padding: var(--simplex-spacing-lg);
    border: none;
}

.simplex-table td {
    padding: var(--simplex-spacing-lg);
    border-top: 1px solid var(--simplex-gray-100);
    vertical-align: middle;
}

.simplex-table tbody tr:hover {
    background-color: var(--simplex-gray-50);
}

/* ===== TOAST NOTIFICATIONS PROFESIONALES ===== */
.toast {
    border: none;
    border-radius: var(--simplex-border-radius-lg);
    box-shadow: var(--simplex-shadow-xl);
    overflow: hidden;
}

.toast-header {
    background: white;
    border-bottom: 1px solid var(--simplex-gray-200);
    font-weight: 600;
}

/* ===== DASHBOARD PROFESIONAL ===== */
.simplex-dashboard-header {
    background: linear-gradient(135deg, var(--simplex-primary) 0%, var(--simplex-secondary) 100%);
    color: white;
    padding: var(--simplex-spacing-2xl) 0;
    margin-bottom: var(--simplex-spacing-xl);
    border-radius: 0 0 var(--simplex-border-radius-xl) var(--simplex-border-radius-xl);
}

.simplex-dashboard-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: var(--simplex-spacing-sm);
    letter-spacing: -0.025em;
}

.simplex-dashboard-subtitle {
    font-size: 1.125rem;
    opacity: 0.9;
    font-weight: 400;
}

/* ===== SISTEMA DE ESTADO ===== */
.simplex-status-indicator {
    display: inline-flex;
    align-items: center;
    padding: var(--simplex-spacing-sm) var(--simplex-spacing-md);
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.simplex-status-active {
    background: linear-gradient(135deg, var(--simplex-success), #10b981);
    color: white;
}

.simplex-status-warning {
    background: linear-gradient(135deg, var(--simplex-warning), #f59e0b);
    color: white;
}

.simplex-status-error {
    background: linear-gradient(135deg, var(--simplex-danger), #ef4444);
    color: white;
}

/* ===== ANIMACIONES PROFESIONALES ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.simplex-fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* ===== RESPONSIVO ===== */
@media (max-width: 768px) {
    .simplex-dashboard-title {
        font-size: 2rem;
    }
    
    .simplex-stat-number {
        font-size: 2rem;
    }
    
    .simplex-card-body {
        padding: var(--simplex-spacing-lg);
    }
}

/* ===== OVERRIDES DE BOOTSTRAP ===== */
.container-fluid {
    padding-left: 0;
    padding-right: 0;
}

.row {
    margin-left: 0;
    margin-right: 0;
}

/* ===== EFECTOS ESPECIALES ===== */
.simplex-gradient-text {
    background: linear-gradient(135deg, var(--simplex-primary), var(--simplex-accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
}

.simplex-glass-effect {
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.18);
}
