/* Analyse Armatis - Design Moderne Inspiré de taap.it */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');
/* Police iOS/macOS - SF Pro via système */

:root {
    /* Palette de couleurs iOS/macOS */
    --primary: #007AFF;
    --primary-dark: #0051D5;
    --primary-light: #5AC8FA;
    --secondary: #5856D6;
    --accent: #FF2D55;
    --success: #34C759;
    --warning: #FF9500;
    --danger: #FF3B30;
    --info: #007AFF;
    
    /* Couleurs de fond iOS/macOS (Dark Mode) */
    --bg-primary: #000000;
    --bg-secondary: #1C1C1E;
    --bg-tertiary: #2C2C2E;
    --bg-card: #1C1C1E;
    --bg-hover: #2C2C2E;
    --bg-glass: rgba(28, 28, 30, 0.8);
    
    /* Couleurs de texte iOS/macOS */
    --text-primary: #FFFFFF;
    --text-secondary: #EBEBF5;
    --text-tertiary: #8E8E93;
    --text-muted: #636366;
    
    /* Ombres et effets */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    --shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);
    
    /* Rayons */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-2xl: 24px;
    --radius-full: 9999px;
    
    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 600ms cubic-bezier(0.68, -0.55, 0.265, 1.55);
    
    /* Blur */
    --blur-sm: blur(4px);
    --blur-md: blur(8px);
    --blur-lg: blur(16px);
    --blur-xl: blur(24px);
}

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

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', 'Inter', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.5;
    font-size: 17px;
    overflow-x: hidden;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(99, 102, 241, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* Navbar Moderne iOS/macOS */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(28, 28, 30, 0.8);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 0.5px solid rgba(255, 255, 255, 0.1);
    padding: 12px 24px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.3px;
    transition: all var(--transition-fast);
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', sans-serif;
}

.nav-brand:hover {
    opacity: 0.8;
}

/* Logo animé style iOS/macOS */
.nav-brand .logo-animated {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border-radius: 8px;
    color: white;
    font-size: 18px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-brand .logo-animated::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.2), transparent);
    opacity: 0;
    transition: opacity 0.2s;
}

.nav-brand .logo-animated:hover::before {
    opacity: 1;
}

.nav-brand .logo-animated:active {
    transform: scale(0.95);
}

/* Animation pulse pour le logo */
@keyframes logo-pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(0, 122, 255, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 8px rgba(0, 122, 255, 0);
    }
}

.nav-brand .logo-animated {
    animation: logo-pulse 3s ease-in-out infinite;
}

.nav-brand:hover .logo-animated {
    animation: none;
    transform: scale(1.1);
}

/* Icône dans le logo */
.nav-brand .logo-animated i {
    position: relative;
    z-index: 1;
    font-weight: 300;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 400;
    font-size: 15px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.nav-link i {
    font-weight: 300;
    font-size: 16px;
    width: 20px;
    text-align: center;
}

.nav-link::after {
    display: none;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.1);
}

.nav-link.active {
    color: var(--primary);
    background: rgba(0, 122, 255, 0.15);
}

.nav-link:hover::after {
    width: calc(100% - 32px);
}

.nav-link.active {
    color: var(--primary);
    background: rgba(99, 102, 241, 0.15);
}

.nav-link.active::after {
    width: calc(100% - 32px);
}

.nav-user {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 16px;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.nav-user i {
    font-size: 20px;
    color: var(--text-secondary);
}

.logout-btn {
    color: var(--text-secondary);
    text-decoration: none;
    padding: 6px;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
}

.logout-btn:hover {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    transform: scale(1.1);
}

/* Main Content */
.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px;
    position: relative;
    z-index: 1;
}

/* Système de Notifications Style macOS - VERSION RENFORCÉE */
.notifications-container {
    position: fixed;
    top: 90px;
    right: 24px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 380px;
    width: 100%;
    pointer-events: none;
}

.notification {
    position: relative;
    background: rgba(28, 28, 30, 0.95) !important;
    backdrop-filter: blur(50px) saturate(200%) !important;
    -webkit-backdrop-filter: blur(50px) saturate(200%) !important;
    border-radius: 18px !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.15),
        inset 0 1px 2px rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    overflow: hidden;
    opacity: 0;
    transform: translateX(400px) scale(0.95);
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: auto;
    min-width: 320px;
    max-width: 380px;
}

/* FORCER le style macOS pour toutes les notifications - écraser tout style vert */
.notification-success,
.notification-error,
.notification-warning,
.notification-info,
.notification-loading {
    background: rgba(28, 28, 30, 0.95) !important;
    backdrop-filter: blur(50px) saturate(200%) !important;
    -webkit-backdrop-filter: blur(50px) saturate(200%) !important;
    border-radius: 18px !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(255, 255, 255, 0.15),
        inset 0 1px 2px rgba(255, 255, 255, 0.2),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

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

.notification.hide {
    opacity: 0;
    transform: translateX(400px) scale(0.95);
    transition: all 0.25s cubic-bezier(0.4, 0, 1, 1);
}

.notification-content {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    position: relative;
    z-index: 2;
}

.notification-icon {
    width: 40px !important;
    height: 40px !important;
    border-radius: 12px !important;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px !important;
    flex-shrink: 0;
    color: white !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
}

.notification-success .notification-icon {
    background: linear-gradient(135deg, #34C759, #30D158) !important;
}

.notification-error .notification-icon {
    background: linear-gradient(135deg, #FF3B30, #FF453A);
}

.notification-warning .notification-icon {
    background: linear-gradient(135deg, #FF9500, #FF9F0A);
}

.notification-info .notification-icon {
    background: linear-gradient(135deg, #007AFF, #0A84FF);
}

.notification-loading .notification-icon {
    background: linear-gradient(135deg, #007AFF, #5856D6);
}

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

.notification-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 3px;
    letter-spacing: -0.2px;
    line-height: 1.3;
}

.notification-message {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.4;
    word-wrap: break-word;
}

.notification-close {
    background: rgba(255, 255, 255, 0.08);
    border: none;
    border-radius: 6px;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-tertiary);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    font-size: 12px;
    padding: 0;
}

.notification-close:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    transform: scale(1.1);
}

.notification-close:active {
    transform: scale(0.95);
}

.notification-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.2);
    width: 100%;
    transform-origin: left;
    transform: scaleX(1);
}

.notification-success .notification-progress {
    background: linear-gradient(90deg, var(--success), #059669);
}

.notification-error .notification-progress {
    background: linear-gradient(90deg, var(--danger), #DC2626);
}

.notification-warning .notification-progress {
    background: linear-gradient(90deg, var(--warning), #D97706);
}

.notification-info .notification-progress {
    background: linear-gradient(90deg, var(--info), #2563EB);
}

.notification-loading .notification-progress {
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    animation: progress-indeterminate 2s linear infinite;
}

@keyframes progress {
    from {
        transform: scaleX(1);
    }
    to {
        transform: scaleX(0);
    }
}

@keyframes progress-indeterminate {
    0% {
        transform: translateX(-100%) scaleX(0.3);
    }
    50% {
        transform: translateX(0%) scaleX(0.7);
    }
    100% {
        transform: translateX(100%) scaleX(0.3);
    }
}

/* Flash Messages (ancien système - gardé pour compatibilité) */
.flash-messages {
    position: fixed;
    top: 80px;
    right: 32px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 400px;
}

.flash-message {
    display: none; /* Désactivé au profit des notifications */
}

/* Login Page */
.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: #000000;
    position: relative;
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'SF Pro Text', 'Helvetica Neue', sans-serif;
}

.login-page::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(0, 122, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(52, 199, 89, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

.login-container {
    width: 100%;
    max-width: 420px;
    padding: 24px;
    position: relative;
    z-index: 1;
}

.login-card {
    background: rgba(28, 28, 30, 0.8);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border-radius: 20px;
    padding: 48px 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    animation: cardAppear 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes cardAppear {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
    background: #007AFF;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    box-shadow: 0 4px 16px rgba(0, 122, 255, 0.3);
}

.login-header h1 {
    font-size: 28px;
    font-weight: 600;
    color: #FFFFFF;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
}

.login-header p {
    font-size: 15px;
    color: #8E8E93;
    font-weight: 400;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 15px;
}

.form-group input,
.form-group select,
.select-input,
.form-control {
    padding: 12px 16px;
    border: 0.5px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    font-size: 17px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(28, 28, 30, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    color: #FFFFFF;
    width: 100%;
}

.form-group input::placeholder {
    color: #8E8E93;
}

.form-group input:focus,
.form-group select:focus,
.select-input:focus,
.form-control:focus {
    outline: none;
    border-color: #007AFF;
    background: rgba(28, 28, 30, 0.9);
    box-shadow: 0 0 0 4px rgba(0, 122, 255, 0.15);
}

/* Buttons */
.btn {
    padding: 14px 24px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: inherit;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::before {
    width: 300px;
    height: 300px;
}

.btn-primary {
    background: var(--primary);
    color: white;
    font-weight: 500;
    border: none;
}

.btn-primary:hover {
    background: #0051D5;
    opacity: 0.9;
}

.btn-primary:active {
    transform: scale(0.97);
    opacity: 0.8;
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-secondary:hover {
    background: var(--bg-hover);
    border-color: rgba(255, 255, 255, 0.2);
}

.btn-block {
    width: 100%;
}

/* Dashboard */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 16px;
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.date-range-selector {
    display: flex;
    align-items: center;
}

.date-range-selector .btn.active {
    background: var(--primary);
    color: white;
    font-weight: 500;
}

.agent-filter-selector {
    display: flex;
    align-items: center;
}

.agent-filter-selector .select-input {
    min-width: 200px;
    padding: 10px 16px;
    background: rgba(28, 28, 30, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 400;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.agent-filter-selector .select-input:hover {
    border-color: var(--primary);
    background: rgba(28, 28, 30, 0.8);
}

.agent-filter-selector .select-input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(28, 28, 30, 0.9);
}

.dashboard-header h1 {
    font-size: 48px;
    font-weight: 900;
    letter-spacing: -2px;
    background: linear-gradient(135deg, var(--text-primary), var(--text-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.period-selector {
    display: flex;
    gap: 4px;
    background: rgba(28, 28, 30, 0.6);
    padding: 4px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.period-btn {
    padding: 8px 16px;
    border: none;
    background: transparent;
    border-radius: 8px;
    font-weight: 400;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    color: var(--text-secondary);
}

.period-btn:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.08);
}

.period-btn.active {
    background: var(--primary);
    color: white;
    font-weight: 500;
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.stat-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-normal);
}

.stat-card:hover::before {
    transform: scaleX(1);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: rgba(99, 102, 241, 0.3);
}

.stat-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.stat-icon:hover {
    transform: scale(1.05);
}

.stat-icon.blue {
    background: rgba(0, 122, 255, 0.2);
    color: #007AFF;
    border: 1px solid rgba(0, 122, 255, 0.3);
    box-shadow: none;
}

.stat-icon.green {
    background: rgba(52, 199, 89, 0.2);
    color: #34C759;
    border: 1px solid rgba(52, 199, 89, 0.3);
    box-shadow: none;
}

.stat-icon.purple {
    background: rgba(88, 86, 214, 0.2);
    color: #5856D6;
    border: 1px solid rgba(88, 86, 214, 0.3);
    box-shadow: none;
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 36px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 4px;
    letter-spacing: -1px;
    line-height: 1;
}

.stat-label {
    font-size: 15px;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Cards */
.card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 24px;
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 24px;
    transition: all var(--transition-normal);
}

.card:hover {
    box-shadow: var(--shadow-xl);
    transform: translateY(-2px);
    border-color: rgba(99, 102, 241, 0.2);
}

.card h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--text-primary);
    letter-spacing: -0.5px;
}

.charts-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

.chart-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    border: 0.5px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
}

.chart-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    transform: translateY(-4px);
    border-color: rgba(255, 255, 255, 0.15);
}

.chart-card h2 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 24px;
    color: var(--text-primary);
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
    letter-spacing: -0.3px;
}

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

/* Agents List */
.agent-selector {
    margin-bottom: 20px;
}

.agents-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.agent-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all var(--transition-fast);
    cursor: pointer;
}

.agent-item:hover {
    background: rgba(99, 102, 241, 0.1);
    transform: translateX(4px);
    border-color: rgba(99, 102, 241, 0.3);
}

.agent-info {
    flex: 1;
}

.agent-name {
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-primary);
    font-size: 17px;
}

.agent-stats {
    font-size: 15px;
    color: var(--text-secondary);
}

.agent-rate {
    font-size: 24px;
    font-weight: 700;
    color: var(--success);
    letter-spacing: -0.5px;
}

/* Weaknesses List - Cartes Mémoire */
.weaknesses-list {
    width: 100%;
    margin: 0;
    padding: 0;
    display: block;
    overflow-x: auto;
}

.weakness-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 48px 24px;
    background: rgba(16, 185, 129, 0.1);
    border: 2px dashed rgba(16, 185, 129, 0.3);
    border-radius: var(--radius-xl);
    color: var(--success);
    font-size: 18px;
    font-weight: 600;
}

.weakness-card {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(239, 68, 68, 0.05));
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-xl);
    padding: 20px;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    min-height: 180px;
    box-shadow: var(--shadow-md);
}

.weakness-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--danger), #F87171);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-normal);
}

.weakness-card:hover {
    transform: translateY(-6px) scale(1.02);
    box-shadow: var(--shadow-xl);
    border-color: rgba(239, 68, 68, 0.4);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(239, 68, 68, 0.08));
}

.weakness-card:hover::before {
    transform: scaleX(1);
}

.weakness-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.weakness-emoji {
    font-size: 32px;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-lg);
    backdrop-filter: var(--blur-sm);
    box-shadow: var(--shadow-sm);
}

.weakness-badge {
    background: linear-gradient(135deg, var(--danger), #DC2626);
    color: white;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 700;
    box-shadow: var(--shadow-md);
    min-width: 40px;
    text-align: center;
}

.weakness-card-body {
    flex: 1;
    margin-bottom: 12px;
}

.weakness-point {
    font-size: 15px;
    line-height: 1.6;
    color: var(--text-primary);
    font-weight: 500;
    margin: 0;
}

.weakness-card-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.weakness-label {
    font-size: 12px;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
}

.weakness-label::before {
    content: '💡';
    font-size: 14px;
}

/* Animation pour les cartes */
@keyframes cardFlip {
    0% {
        transform: rotateY(0deg);
    }
    50% {
        transform: rotateY(90deg);
    }
    100% {
        transform: rotateY(0deg);
    }
}

.weakness-card:active {
    animation: cardFlip 0.6s ease-in-out;
}

/* Tables */
.appels-table-container,
.users-table-container {
    overflow-x: auto;
    border-radius: var(--radius-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.appels-table,
.users-table {
    width: 100%;
    border-collapse: collapse;
    background: var(--bg-card);
}

.appels-table thead,
.users-table thead {
    background: rgba(255, 255, 255, 0.05);
}

.appels-table th,
.users-table th {
    padding: 16px;
    text-align: left;
    font-weight: 600;
    font-size: 13px;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.appels-table td,
.users-table td {
    padding: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    font-size: 15px;
}

.appels-table tbody tr:last-child td,
.users-table tbody tr:last-child td {
    border-bottom: none;
}

.appels-table tbody tr:hover,
.users-table tbody tr:hover {
    background: rgba(99, 102, 241, 0.05);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 6px 12px;
    border-radius: var(--radius-full);
    font-size: 13px;
    font-weight: 600;
}

.badge-success {
    background: rgba(52, 199, 89, 0.2);
    color: #34C759;
    border: 1px solid rgba(52, 199, 89, 0.3);
}

.badge-danger {
    background: rgba(255, 59, 48, 0.2);
    color: #FF3B30;
    border: 1px solid rgba(255, 59, 48, 0.3);
}

.badge-warning {
    background: rgba(255, 149, 0, 0.2);
    color: #FF9500;
    border: 1px solid rgba(255, 149, 0, 0.3);
}

.badge-secondary {
    background: rgba(148, 163, 184, 0.2);
    color: var(--text-secondary);
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 24px;
}

.pagination-btn {
    padding: 10px 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: var(--bg-card);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
    color: var(--text-primary);
    font-size: 15px;
    font-weight: 500;
}

.pagination-btn:hover:not(:disabled) {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

.pagination-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.pagination-info {
    padding: 10px 16px;
    color: var(--text-secondary);
    font-size: 15px;
}

/* Modal */
/* Modals Style macOS - VERSION RENFORCÉE */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5) !important;
    backdrop-filter: blur(30px) saturate(200%) !important;
    -webkit-backdrop-filter: blur(30px) saturate(200%) !important;
    z-index: 3000;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal.active {
    display: flex !important;
    opacity: 1 !important;
}

.modal-content {
    background: rgba(28, 28, 30, 0.95) !important;
    backdrop-filter: blur(60px) saturate(200%) !important;
    -webkit-backdrop-filter: blur(60px) saturate(200%) !important;
    border-radius: 24px !important;
    width: 90%;
    max-width: 560px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 
        0 30px 80px rgba(0, 0, 0, 0.7),
        0 0 0 1px rgba(255, 255, 255, 0.2),
        inset 0 2px 4px rgba(255, 255, 255, 0.25),
        inset 0 -2px 0 rgba(0, 0, 0, 0.4) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    animation: modalSlideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

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

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12) !important;
    background: rgba(0, 0, 0, 0.3) !important;
    flex-shrink: 0;
}

.modal-header h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: -0.3px;
    margin: 0;
}

.modal-close {
    background: rgba(255, 255, 255, 0.08);
    border: none;
    font-size: 16px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    transform: scale(1.05);
}

.modal-close:active {
    transform: scale(0.95);
}

.modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-body::-webkit-scrollbar-track {
    background: transparent;
}

.modal-body::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

.modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.form-actions .btn {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    border-radius: 8px;
    min-width: 80px;
}

.form-actions .btn-primary {
    background: #007AFF;
    color: white;
}

.form-actions .btn-primary:hover {
    background: #0051D5;
}

.form-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.form-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.15);
}

.help-text {
    font-size: 13px;
    color: var(--text-tertiary);
}

/* Loading */
.loading {
    text-align: center;
    padding: 48px;
    color: var(--text-secondary);
    font-size: 15px;
    position: relative;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 24px;
    height: 24px;
    margin: -12px 0 0 -12px;
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 0%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 100%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s ease-in-out infinite;
    border-radius: var(--radius-md);
}

@keyframes skeleton-loading {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Amélioration des cartes avec hover effects */
.stat-card,
.card,
.chart-card {
    position: relative;
    overflow: hidden;
}

.stat-card::after,
.card::after,
.chart-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.05),
        transparent
    );
    transition: left 0.5s;
}

.stat-card:hover::after,
.card:hover::after,
.chart-card:hover::after {
    left: 100%;
}

/* Amélioration des boutons */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::after {
    width: 300px;
    height: 300px;
}

/* Amélioration des graphiques */
.chart-card canvas {
    border-radius: 12px;
    max-height: 400px;
}

/* Admin Page */
.admin-page {
    max-width: 1200px;
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    flex-wrap: wrap;
    gap: 16px;
}

.page-header h1 {
    font-size: 48px;
    font-weight: 900;
    letter-spacing: -2px;
}

/* Appel Details */
.appel-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.detail-section {
    padding: 18px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.detail-section:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.1);
}

.detail-section h3 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 14px;
    color: var(--text-primary);
    letter-spacing: -0.2px;
}

.detail-section p {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    margin: 8px 0;
}

.detail-section p strong {
    color: var(--text-primary);
    font-weight: 600;
}

.detail-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.detail-section ul li {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
}

.detail-section ul li:last-child {
    border-bottom: none;
}

.kpi-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 14px;
    margin-bottom: 8px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.kpi-item:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
    transform: translateX(2px);
}

.kpi-name {
    font-weight: 500;
    color: var(--text-primary);
}

.kpi-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Responsive */
@media (max-width: 768px) {
    .main-content {
        padding: 20px 16px;
    }

    .dashboard-header {
        flex-direction: column;
        align-items: flex-start;
    }

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

    .charts-section,
    .grid-2 {
        grid-template-columns: 1fr;
    }

    .nav-links {
        gap: 4px;
    }

    .nav-link span {
        display: none;
    }

    .notifications-container {
        right: 12px;
        left: 12px;
        max-width: none;
    }

    .notification {
        min-width: auto;
        max-width: none;
    }
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

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

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Selection */
::selection {
    background: rgba(99, 102, 241, 0.3);
    color: var(--text-primary);
}

/* Améliorations visuelles supplémentaires */
.stat-card,
.card,
.chart-card {
    transition: all var(--transition-normal);
}

.stat-card:hover {
    transform: translateY(-6px) scale(1.02);
}

.card:hover {
    transform: translateY(-4px);
}

.chart-card:hover {
    transform: translateY(-4px);
}

/* Animation des valeurs statistiques */
.stat-value {
    transition: all var(--transition-fast);
}

.stat-value.updating {
    animation: pulse 0.5s ease-in-out;
}

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

/* Amélioration des graphiques Chart.js */
.chart-card canvas {
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

/* Effet de brillance sur les cartes */
.stat-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    opacity: 0;
    transition: opacity var(--transition-slow);
    pointer-events: none;
}

.stat-card:hover::before {
    opacity: 1;
}

/* ============================================
   PREMIUM UI/UX IMPROVEMENTS - ENTERPRISE STYLE
   ============================================ */

/* 1. KPI CARDS - Premium Enhancement */
.stat-card {
    background: linear-gradient(135deg, rgba(28, 28, 30, 0.95), rgba(44, 44, 46, 0.95)) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    padding: 28px !important;
    position: relative;
    overflow: hidden;
}

.stat-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 122, 255, 0.03) 0%, 
        transparent 50%,
        rgba(88, 86, 214, 0.03) 100%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.stat-card:hover::after {
    opacity: 1;
}

.stat-icon {
    width: 52px !important;
    height: 52px !important;
    font-size: 22px !important;
    border-radius: 14px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

.stat-value {
    font-size: 42px !important;
    font-weight: 900 !important;
    line-height: 1.1 !important;
    margin-bottom: 6px !important;
    letter-spacing: -1.5px !important;
    background: linear-gradient(135deg, #FFFFFF, #EBEBF5);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 14px !important;
    font-weight: 500 !important;
    color: var(--text-tertiary) !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.stat-content::after {
    content: attr(data-description);
    display: block;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
    font-weight: 400;
}

/* 2. FILTERS - Premium Enhancement */
.period-selector {
    background: rgba(28, 28, 30, 0.7) !important;
    backdrop-filter: blur(24px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    padding: 6px !important;
    border-radius: 12px !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

.period-btn {
    padding: 10px 18px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    border-radius: 8px !important;
    min-height: 36px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative;
}

.period-btn:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: var(--text-primary) !important;
    transform: translateY(-1px);
}

.period-btn.active {
    background: linear-gradient(135deg, #007AFF, #0051D5) !important;
    color: white !important;
    font-weight: 600 !important;
    box-shadow: 
        0 4px 12px rgba(0, 122, 255, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
    transform: translateY(-1px);
}

.date-range-selector .btn,
.agent-filter-selector .select-input {
    min-height: 36px !important;
    border-radius: 10px !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    background: rgba(28, 28, 30, 0.7) !important;
    backdrop-filter: blur(24px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(24px) saturate(180%) !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.date-range-selector .btn:hover,
.agent-filter-selector .select-input:hover {
    background: rgba(28, 28, 30, 0.9) !important;
    border-color: rgba(0, 122, 255, 0.4) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.2) !important;
}

/* 3. HEADER - Premium Enhancement */
.navbar {
    background: rgba(28, 28, 30, 0.85) !important;
    backdrop-filter: blur(30px) saturate(180%) !important;
    -webkit-backdrop-filter: blur(30px) saturate(180%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
    padding: 14px 32px !important;
}

.nav-brand {
    font-size: 18px !important;
    font-weight: 700 !important;
    letter-spacing: -0.4px !important;
}

.nav-brand .logo-animated {
    width: 36px !important;
    height: 36px !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3) !important;
}

.nav-user {
    padding: 6px 12px !important;
    border-radius: 10px !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    transition: all 0.2s ease !important;
}

.nav-user:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    border-color: rgba(255, 255, 255, 0.12) !important;
}

/* 4. DASHBOARD HEADER - Premium Enhancement */
.dashboard-header {
    padding: 24px 0 !important;
    margin-bottom: 40px !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
}

.dashboard-header h1 {
    font-size: 40px !important;
    font-weight: 800 !important;
    letter-spacing: -1.5px !important;
    margin: 0 !important;
}

.header-controls {
    gap: 12px !important;
    align-items: center !important;
}

/* 5. CHART CARDS - Premium Enhancement */
.chart-card {
    background: linear-gradient(135deg, rgba(28, 28, 30, 0.95), rgba(44, 44, 46, 0.95)) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    padding: 28px !important;
    border-radius: 18px !important;
}

.chart-card h2 {
    font-size: 20px !important;
    font-weight: 700 !important;
    margin-bottom: 28px !important;
    letter-spacing: -0.4px !important;
    color: var(--text-primary) !important;
}

/* 6. AGENT ITEMS - Premium Enhancement */
.agent-item {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02)) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 14px !important;
    padding: 20px !important;
    margin-bottom: 12px !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
    position: relative;
    overflow: hidden;
}

.agent-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: linear-gradient(180deg, var(--primary), var(--secondary));
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.3s ease;
}

.agent-item:hover::before {
    transform: scaleY(1);
}

.agent-item:hover {
    background: linear-gradient(135deg, rgba(0, 122, 255, 0.08), rgba(88, 86, 214, 0.05)) !important;
    border-color: rgba(0, 122, 255, 0.3) !important;
    transform: translateX(6px) translateY(-2px) !important;
    box-shadow: 0 8px 24px rgba(0, 122, 255, 0.15) !important;
}

.agent-name {
    font-size: 18px !important;
    font-weight: 700 !important;
    margin-bottom: 8px !important;
    letter-spacing: -0.3px !important;
}

.agent-stats {
    font-size: 13px !important;
    color: var(--text-tertiary) !important;
    font-weight: 400 !important;
}

.agent-rate {
    font-size: 28px !important;
    font-weight: 800 !important;
    letter-spacing: -1px !important;
    background: linear-gradient(135deg, #34C759, #30D158);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* 7. WEAKNESSES TABLE - Premium Enhancement */
.weaknesses-table {
    width: 100% !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    margin-top: 16px !important;
}

.weaknesses-table thead {
    background: rgba(255, 255, 255, 0.03) !important;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1) !important;
}

.weaknesses-table th {
    padding: 16px 20px !important;
    text-align: left !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    color: var(--text-tertiary) !important;
    border-bottom: 2px solid rgba(255, 255, 255, 0.1) !important;
}

.weaknesses-table td {
    padding: 18px 20px !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    transition: all 0.2s ease !important;
}

.weaknesses-table tbody tr {
    background: transparent !important;
    transition: all 0.2s ease !important;
    cursor: pointer !important;
}

.weaknesses-table tbody tr:hover {
    background: rgba(0, 122, 255, 0.05) !important;
    transform: translateX(4px) !important;
}

.weaknesses-table tbody tr:hover td {
    border-bottom-color: rgba(0, 122, 255, 0.2) !important;
}

.weaknesses-table tbody tr:last-child td {
    border-bottom: none !important;
}

/* Badge pour occurrences */
.occurrence-badge {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 6px 12px !important;
    border-radius: 12px !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    background: linear-gradient(135deg, #FF9500, #FF9F0A) !important;
    color: white !important;
    box-shadow: 0 2px 8px rgba(255, 149, 0, 0.3) !important;
    min-width: 48px !important;
}

/* 8. CARDS - Premium Enhancement */
.card {
    background: linear-gradient(135deg, rgba(28, 28, 30, 0.95), rgba(44, 44, 46, 0.95)) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    padding: 28px !important;
    border-radius: 18px !important;
}

.card h2 {
    font-size: 22px !important;
    font-weight: 700 !important;
    margin-bottom: 24px !important;
    letter-spacing: -0.4px !important;
    color: var(--text-primary) !important;
}

/* 9. RESPONSIVE - Premium Enhancement */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
    
    .charts-section {
        grid-template-columns: 1fr !important;
    }
    
    .grid-2 {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: 1fr !important;
    }
    
    .dashboard-header {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 20px !important;
    }
    
    .header-controls {
        width: 100% !important;
        flex-wrap: wrap !important;
    }
    
    .period-selector {
        width: 100% !important;
        justify-content: space-between !important;
    }
    
    .period-btn {
        flex: 1 !important;
        min-width: 0 !important;
    }
}

/* 10. MICRO-ANIMATIONS - Premium Enhancement */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stat-card,
.chart-card,
.card {
    animation: fadeInUp 0.5s ease-out backwards;
}

.stat-card:nth-child(1) { animation-delay: 0.1s; }
.stat-card:nth-child(2) { animation-delay: 0.2s; }
.stat-card:nth-child(3) { animation-delay: 0.3s; }

@keyframes countUp {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.stat-value.updating {
    animation: countUp 0.4s ease-out;
}

/* 11. CHART IMPROVEMENTS - Applied via JavaScript config */
/* Les améliorations de graphiques seront appliquées dans dashboard.js */
