:root {
            --primary-color: #1e1b4b;
            --secondary-color: #8392ab;
            --success-color: #2dce89;
            --danger-color: #f5365c;
            --warning-color: #fb6340;
            --info-color: #11cdef;
            --dark-color: #1e1b4b;
            --light-color: #f8f9fa;
            --sidebar-width: 280px;
        }

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

        body {
            font-family: 'Open Sans', sans-serif;
            background-color: #f8f9fa;
            overflow-x: hidden;
        }

        /* Sidebar */
        .sidenav {
            position: fixed;
            top: 20px;
            left: 20px;
            width: var(--sidebar-width);
            height: calc(100vh - 40px);
            background: white;
            border-radius: 15px;
            box-shadow: 0 4px 25px rgba(0, 0, 0, 0.1);
            z-index: 1000;
            overflow-y: auto;
            transition: all 0.3s ease;
        }

        .sidenav-header {
            padding: 20px;
            border-bottom: 1px solid #e9ecef;
        }

        .navbar-brand {
            display: flex;
            align-items: center;
            text-decoration: none;
            font-weight: 700;
            font-size: 18px;
        }

        .navbar-brand img {
            margin-right: 10px;
        }

        .navbar-nav {
            padding: 20px 0;
        }

        .nav-item {
            margin: 5px 15px;
        }

        .nav-link {
            display: flex;
            align-items: center;
            padding: 12px 15px;
            color: var(--secondary-color);
            text-decoration: none;
            border-radius: 10px;
            transition: all 0.3s ease;
            font-weight: 500;
        }

        .nav-link:hover, .nav-link.active {
            background: var(--primary-color);
            color: white;
            transform: translateX(5px);
            box-shadow: 0 4px 15px rgba(94, 114, 228, 0.3);
        }

        .nav-link .icon {
            width: 35px;
            height: 35px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 8px;
            margin-right: 12px;
            background: rgba(94, 114, 228, 0.1);
            transition: all 0.3s ease;
        }

        .nav-link:hover .icon, .nav-link.active .icon {
            background: rgba(255, 255, 255, 0.2);
        }

        .sidenav-footer {
            padding: 20px;
            border-top: 1px solid #e9ecef;
            margin-top: auto;
        }

        .sidenav-footer .card {
            background: var(--primary-color);
            border: none;
            border-radius: 15px;
            color: white;
            text-align: center;
            padding: 20px;
            margin-bottom: 15px;
        }

        .btn-dark {
            background: var(--dark-color);
            border: none;
            border-radius: 10px;
            padding: 10px 20px;
            font-weight: 600;
            transition: all 0.3s ease;
        }

        .btn-dark:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
        }

        /* Main Content */
        .main-content {
            margin-left: calc(var(--sidebar-width) + 40px);
            padding: 20px;
            min-height: 100vh;
        }

        /* Navbar */
        .navbar-main {
            background: var(--primary-color);
            padding: 15px 30px;
            margin-bottom: 30px;
        }

        .navbar-main h6 {
            color: white;
            font-size: 24px;
            font-weight: 700;
            margin: 0;
        }

        .input-group {
            max-width: 300px;
        }

        .form-control {
            border: none;
            border-radius: 10px;
            padding: 10px 15px;
            background: rgba(255, 255, 255, 0.9);
            backdrop-filter: blur(10px);
        }

        .input-group-text {
            border: none;
            background: rgba(255, 255, 255, 0.9);
            border-radius: 10px 0 0 10px;
        }

        /* Cards statistiques */
        .card {
            border: none;
            border-radius: 15px;
            box-shadow: 0 4px 25px rgba(0, 0, 0, 0.1);
            transition: all 0.3s ease;
            background: white;
        }

        .card:hover {
            transform: translateY(-5px);
            box-shadow: 0 8px 35px rgba(0, 0, 0, 0.15);
        }

        .card-body {
            padding: 25px;
        }

        .numbers p {
            color: var(--secondary-color);
            font-size: 12px;
            font-weight: 600;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            margin-bottom: 8px;
        }

        .numbers h5 {
            font-size: 18px;
            font-weight: 700;
            color: var(--dark-color);
            margin-bottom: 8px;
        }

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

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

        .icon-shape {
            width: 60px;
            height: 60px;
            display: flex;
            align-items: center;
            justify-content: center;
            border-radius: 15px;
            font-size: 24px;
        }


        /* Table */
        .table-responsive {
            border-radius: 10px;
            overflow: hidden;
        }

        .table {
            margin-bottom: 0;
        }

        .table thead th {
            border: none;
            background: var(--light-color);
            color: var(--dark-color);
            font-weight: 600;
            padding: 15px;
        }

        .table tbody td {
            border: none;
            padding: 15px;
            vertical-align: middle;
        }

        .table tbody tr:hover {
            background: rgba(94, 114, 228, 0.05);
        }


        /* Responsive */
        @media (max-width: 1200px) {
            .sidenav {
                transform: translateX(-100%);
            }

            .main-content {
                margin-left: 20px;
            }

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

        @media (max-width: 768px) {
            .main-content {
                margin-left: 10px;
                padding: 10px;
            }

            .navbar-main {
                padding: 15px;
            }

            .card-body {
                padding: 20px;
            }

            .numbers h5 {
                font-size: 24px;
            }

            .col-xl-3 {
                margin-bottom: 20px;
            }
        }

        /* Animations */
        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .card {
            animation: fadeInUp 0.6s ease-out;
        }

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

        /* Scrollbar personnalisé */
        .sidenav::-webkit-scrollbar {
            width: 4px;
        }

        .sidenav::-webkit-scrollbar-track {
            background: transparent;
        }

        .sidenav::-webkit-scrollbar-thumb {
            background: rgba(94, 114, 228, 0.3);
            border-radius: 2px;
        }

        .sidenav::-webkit-scrollbar-thumb:hover {
            background: rgba(94, 114, 228, 0.5);
        }
        /* Bouton menu mobile */
.mobile-menu-btn {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    z-index: 1100;
    background: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 10px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

/* Overlay pour le menu mobile */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.menu-overlay.show {
    opacity: 1;
    visibility: visible;
}

/* Bouton fermer dans la sidebar */
.close-btn {
    display: none;
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--secondary-color);
    cursor: pointer;
}

@media (max-width: 1200px) {
    .mobile-menu-btn {
        display: block;
    }
    
    .close-btn {
        display: block;
    }
    
    .sidenav {
        transform: translateX(-100%);
        top: 0;
        left: 0;
        height: 100vh;
        border-radius: 0;
        transition: transform 0.3s ease;
    }
    
    .sidenav.show {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        padding: 20px 15px;
    }
    
    .navbar-main {
        padding-left: 70px;
    }
}
/* Empêcher le défilement quand le menu est ouvert */
body.no-scroll {
    overflow: hidden;
}

/* Ajustements pour le menu mobile */
@media (max-width: 1200px) {
    .sidenav {
        transform: translateX(-100%);
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 280px;
        z-index: 1000;
        transition: transform 0.3s ease;
    }
    
    .sidenav.show {
        transform: translateX(0);
    }
    
    .menu-overlay {
        display: block;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        z-index: 999;
    }
    
    .menu-overlay.show {
        opacity: 1;
        visibility: visible;
    }
    
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        position: fixed;
        top: 20px;
        left: 20px;
        width: 40px;
        height: 40px;
        background: white;
        border: none;
        border-radius: 10px;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
        z-index: 1001;
        cursor: pointer;
    }
    
    .close-btn {
        display: block;
        position: absolute;
        top: 15px;
        right: 15px;
        background: transparent;
        border: none;
        color: #8392ab;
        font-size: 1.5rem;
        cursor: pointer;
        z-index: 1002;
    }
}
/* Cacher le bouton menu quand la sidebar est ouverte */
.sidenav.show ~ .mobile-menu-btn {
    display: none;
}

/* Bouton fermer */
.close-btn {
    display: none; /* Caché par défaut */
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    color: var(--secondary-color);
    cursor: pointer;
    z-index: 1002;
}

@media (max-width: 1200px) {
    .close-btn {
        display: block; /* Visible seulement sur mobile */
    }
}

/* Afficher le bouton menu seulement sur mobile */
@media (min-width: 1201px) {
    .mobile-menu-btn {
        display: none !important;
    }
}
/* Styles pour le tableau */
.table {
    width: 100%;
    margin-bottom: 1rem;
    color: #212529;
    border-collapse: collapse;
}

.table th,
.table td {
    padding: 0.75rem;
    vertical-align: top;
    border-top: 1px solid #dee2e6;
}

.table thead th {
    vertical-align: bottom;
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: rgba(0, 0, 0, 0.02);
}

.table-hover tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.075);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.35em 0.65em;
    font-size: 0.75em;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    text-align: center;
    white-space: nowrap;
    vertical-align: baseline;
    border-radius: 0.25rem;
}

.badge.bg-warning {
    color: #000 !important;
}

/* Boutons */
.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.875rem;
    line-height: 1.5;
    border-radius: 0.2rem;
}

/* Responsive table */
.table-responsive {
    display: block;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.bg-custom-primary {
    background-color: #1e1b4b !important;
}
.navbar-brand span {
    color: black !important;
}
/* Ajoutez ces styles à votre fichier CSS */
.card-header.bg-custom-primary {
    background-color: #4e73df;
}

.table-header-custom {
    background-color: #f8f9fc;
}

.table-header-custom th {
    font-weight: 600;
    color: #4e73df;
}

.badge {
    font-size: 0.85em;
    font-weight: 600;
    padding: 0.35em 0.65em;
}