/* BECADIS Custom Styles - Couleurs basées sur le logo */

:root {
    /* Couleurs principales BECADIS */
    --becadis-primary: #1e3a8a; /* Bleu foncé */
    --becadis-secondary: #f59e0b; /* Orange/Ambre */
    --becadis-accent: #059669; /* Vert */
    --becadis-dark: #1f2937; /* Gris foncé */
    --becadis-light: #f8fafc; /* Gris très clair */

    /* Couleurs de statut */
    --becadis-success: #10b981; /* Vert succès */
    --becadis-warning: #f59e0b; /* Orange attention */
    --becadis-danger: #ef4444; /* Rouge danger */
    --becadis-info: #3b82f6; /* Bleu info */

    /* Variables Volt */
    --volt-gradient: linear-gradient(
        87deg,
        var(--becadis-primary) 0,
        #3b82f6 100%
    );
    --volt-box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    --volt-transition: all 0.15s ease;
}

/* Logo dans la sidebar */
.sidebar-brand-logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
    margin-right: 10px;
}

/* Logo dans la topbar */
.topbar-brand-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    margin-right: 8px;
}

/* Couleurs principales */
.bg-primary {
    background-color: var(--becadis-primary) !important;
}

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

.btn-primary {
    background-color: var(--becadis-primary);
    border-color: var(--becadis-primary);
}

.btn-primary:hover {
    background-color: #1e40af;
    border-color: #1e40af;
}

/* Couleurs secondaires */
.bg-secondary {
    background-color: var(--becadis-secondary) !important;
}

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

.btn-secondary {
    background-color: var(--becadis-secondary);
    border-color: var(--becadis-secondary);
    color: white;
}

.btn-secondary:hover {
    background-color: #d97706;
    border-color: #d97706;
}

/* Couleurs d'accent */
.bg-accent {
    background-color: var(--becadis-accent) !important;
}

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

/* Sidebar personnalisée - Design Compact */
.sidebar {
    background: #ffffff;
    border-right: 1px solid #e8eaed;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    width: 280px; /* Réduit de 240px à 220px pour éviter le scroll horizontal */
    max-width: 320px; /* Empêche l'élargissement */
    overflow-x: hidden; /* Empêche le scroll horizontal */
    display: flex;
    flex-direction: column;
    height: 100vh;
}

/* Section Profil Fixe */
.sidebar-header {
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border-bottom: 1px solid #e8eaed;
    padding: 24px 20px;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* Section Menu Scrollable */
.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px 0;
    scrollbar-width: thin;
    scrollbar-color: #c1c1c1 #f1f1f1;
}

/* Scroll personnalisé pour Webkit */
.sidebar-content::-webkit-scrollbar {
    width: 6px;
}

.sidebar-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.sidebar-content::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

.sidebar-inner {
    padding: 16px 0;
    height: 100vh;
    overflow-y: auto;
}

.sidebar-brand-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: all 0.3s ease;
}

.sidebar-brand-link:hover {
    text-decoration: none;
    color: inherit;
    transform: translateY(-1px);
}

.sidebar-brand {
    display: flex;
    align-items: center;
    margin-bottom: 0; /* Supprimé car dans le header fixe */
    padding: 16px 20px;
    border-radius: 14px;
    background: linear-gradient(135deg, #ffffff 0%, #f8f9fa 100%);
    border: 1px solid #e8eaed;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.sidebar-brand:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.sidebar-brand-logo {
    width: 48px;
    height: 48px;
    margin-right: 16px;
    border-radius: 10px;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.sidebar-brand-text {
    color: #1a1a1a;
    font-weight: 700;
    font-size: 1.1rem;
    letter-spacing: -0.025em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

/* Styles pour éviter les styles inline - Sécurité */
/* Les styles sidebar-brand sont maintenant définis ci-dessus */

.sidebar-icon {
    width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 12px;
    font-size: 14px;
    color: #5f6368;
}

.sidebar-text {
    color: #3c4043;
    font-weight: 400;
    font-size: 1rem; /* 16px - Augmenté pour meilleure lisibilité */
    letter-spacing: 0.025em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.sidebar-chevron {
    margin-left: auto;
    font-size: 12px;
    color: #5f6368;
    transition: transform 0.2s ease;
    flex-shrink: 0;
}

.nav-link {
    display: flex;
    align-items: center;
    padding: 10px 12px; /* Réduit de 16px à 12px pour éviter le scroll horizontal */
    color: #3c4043;
    text-decoration: none;
    border-radius: 0;
    transition: all 0.2s ease;
    border: none;
    background: transparent;
    width: 100%;
    position: relative;
    min-height: 40px; /* Augmenté de 36px à 40px pour la lisibilité */
}

.nav-link:hover {
    color: var(--becadis-primary);
    background-color: #f8f9fa;
    text-decoration: none;
}

.nav-link:focus {
    color: var(--becadis-primary);
    background-color: #e8f0fe;
    text-decoration: none;
    outline: 2px solid var(--becadis-primary);
    outline-offset: -2px;
    box-shadow: 0 0 0 2px rgba(94, 114, 228, 0.2);
}

.nav-link:hover .sidebar-icon {
    color: var(--becadis-primary);
}

.nav-link:hover .sidebar-text {
    color: var(--becadis-primary);
}

.nav-link:focus .sidebar-icon {
    color: var(--becadis-primary);
}

.nav-link:focus .sidebar-text {
    color: var(--becadis-primary);
}

.nav-link.active {
    color: var(--becadis-primary);
    background-color: #e8f0fe;
    font-weight: 500;
}

.nav-link.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--becadis-primary);
    border-radius: 0 2px 2px 0;
}

.nav-link.active .sidebar-text {
    color: var(--becadis-primary);
    font-weight: 500;
}

.nav-link.active .sidebar-icon {
    color: var(--becadis-primary);
}

.sidebar-heading {
    font-size: 0.875rem; /* 14px - Augmenté pour meilleure lisibilité */
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--becadis-primary); /* Couleur principale BECADIS */
    margin: 16px 0 6px 0;
    padding: 0 12px; /* Réduit de 16px à 12px */
}

.sidebar-divider {
    height: 1px;
    background-color: #e8eaed;
    margin: 12px 12px; /* Réduit de 16px à 12px */
    border: none;
}

/* Drawer pour menu principal - Design Compact */
.collapse .nav-link {
    padding: 10px 12px 10px 24px; /* Augmenté pour meilleure lisibilité */
    margin: 0;
    font-size: 0.9375rem; /* 15px - Augmenté pour meilleure lisibilité */
    min-height: 36px; /* Augmenté pour meilleure lisibilité */
}

.collapse .nav-link .sidebar-text {
    font-size: 0.9375rem; /* 15px - Augmenté pour meilleure lisibilité */
    color: #5f6368;
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.collapse .nav-link .sidebar-icon {
    width: 14px;
    height: 14px;
    margin-right: 8px;
    font-size: 12px;
    color: #5f6368;
    flex-shrink: 0;
}

.collapse .nav-link:hover {
    background-color: #f8f9fa;
}

.collapse .nav-link:hover .sidebar-text {
    color: var(--becadis-primary);
}

.collapse .nav-link:hover .sidebar-icon {
    color: var(--becadis-primary);
}

.collapse .nav-link:focus {
    background-color: #e8f0fe;
    outline: 2px solid var(--becadis-primary);
    outline-offset: -2px;
    box-shadow: 0 0 0 2px rgba(94, 114, 228, 0.2);
}

.collapse .nav-link:focus .sidebar-text {
    color: var(--becadis-primary);
}

.collapse .nav-link:focus .sidebar-icon {
    color: var(--becadis-primary);
}

.collapse .nav-link.active {
    background-color: #e8f0fe;
    color: var(--becadis-primary);
}

.collapse .nav-link.active .sidebar-text {
    color: var(--becadis-primary);
    font-weight: 500;
}

.collapse .nav-link.active .sidebar-icon {
    color: var(--becadis-primary);
}

/* Animation des chevrons */
[data-bs-toggle="collapse"] .sidebar-chevron {
    transition: transform 0.2s ease;
}

[data-bs-toggle="collapse"][aria-expanded="true"] .sidebar-chevron {
    transform: rotate(180deg);
}

/* Style des sous-menus */
.collapse .nav {
    margin: 0;
    border: none;
    padding: 0;
    background-color: #fafbfc;
}

.collapse .nav .nav-item:last-child .nav-link {
    margin-bottom: 4px;
}

/* Topbar personnalisée - Design Compact */
.topbar {
    background: #ffffff;
    border-bottom: 1px solid #e8eaed;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    padding: 12px 12px; /* Réduit de 16px à 12px pour cohérence */
    height: 56px;
    display: flex;
    align-items: center;
}

.topbar-brand-logo {
    width: 28px;
    height: 28px;
    margin-right: 8px;
    border-radius: 4px;
}

.topbar h4 {
    color: #1a1a1a;
    font-weight: 500;
    font-size: 1.125rem;
    margin: 0;
    letter-spacing: -0.025em;
}

.topbar .fw-bold {
    color: var(--becadis-primary);
    font-weight: 600;
    font-size: 1rem;
}

/* Cartes avec couleurs BECADIS */
.card {
    border: 1px solid #e5e7eb;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Badges personnalisés */
.badge {
    font-weight: 500;
}

.bg-primary {
    background-color: var(--becadis-primary) !important;
}

.bg-success {
    background-color: var(--becadis-success) !important;
}

.bg-warning {
    background-color: var(--becadis-warning) !important;
}

.bg-danger {
    background-color: var(--becadis-danger) !important;
}

.bg-info {
    background-color: var(--becadis-info) !important;
}

/* Boutons personnalisés */
.btn-outline-primary {
    color: var(--becadis-primary);
    border-color: var(--becadis-primary);
}

.btn-outline-primary:hover {
    background-color: var(--becadis-primary);
    border-color: var(--becadis-primary);
}

/* Progress bars */
.progress-bar {
    background-color: var(--becadis-primary);
}

/* Tableaux - Professional Table (Dernières Tâches Style) */
.table thead th {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    color: #475569; /* slate-600 */
    letter-spacing: 0.05em;
    background-color: #f8fafc;
    border-top: none;
    border-bottom: none;
    padding: 1rem;
}

.table td {
    padding: 1.25rem 1rem;
    color: #1e293b; /* slate-800 */
    font-size: 0.9rem;
}

/* Formulaires */
.form-control:focus {
    border-color: var(--becadis-primary);
    box-shadow: 0 0 0 0.2rem rgba(30, 58, 138, 0.25);
}

.form-select:focus {
    border-color: var(--becadis-primary);
    box-shadow: 0 0 0 0.2rem rgba(30, 58, 138, 0.25);
}

/* Alertes personnalisées */
.alert-primary {
    background-color: rgba(30, 58, 138, 0.1);
    border-color: var(--becadis-primary);
    color: var(--becadis-primary);
}

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

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

.alert-danger {
    background-color: rgba(239, 68, 68, 0.1);
    border-color: var(--becadis-danger);
    color: var(--becadis-danger);
}

/* Dashboard spécifique BECADIS */
.becadis-stats-card {
    border-left: 4px solid var(--becadis-primary);
    transition: transform 0.2s ease;
}

.becadis-stats-card:hover {
    transform: translateY(-2px);
}

/* Icônes et espacement - Design Compact */
.sidebar-nav .nav-link i {
    font-size: 14px;
    margin-right: 0;
}

.sidebar-nav .submenu .nav-link i {
    font-size: 12px;
    margin-right: 0;
}

/* Amélioration de la typographie */
.sidebar-text {
    line-height: 1.3;
    flex: 1;
}

.nav-link {
    line-height: 1.3;
}

/* Espacement des sections */
.sidebar-heading:first-of-type {
    margin-top: 0;
}

/* Optimisation pour une ligne */
.nav-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
}

.sidebar-text {
    flex: 1;
    min-width: 0;
}

.sidebar-chevron {
    flex-shrink: 0;
    margin-left: 8px;
}

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

.sidebar-inner::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.sidebar-inner::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 2px;
}

.sidebar-inner::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Ajustement du contenu principal - Responsive */
.main-content {
    margin-left: 0 !important; /* Force le reset sur mobile */
    width: 100% !important; /* Assure la pleine largeur */
    transition: margin-left 0.3s ease;
    background-color: #f8f9fe;
    min-height: 100vh;
    padding: 24px 0 !important; /* Padding horizontal supprimé sur mobile */
}

@media (min-width: 992px) {
    .main-content {
        margin-left: 280px !important; /* Sidebar width sur desktop */
        width: calc(100% - 280px) !important; /* Largeur calculée */
        padding: 24px 32px;
    }
}

/* Styles pour éviter les styles inline - Sécurité */
.card {
    border: none;
    box-shadow: 0 0.15rem 1.75rem 0 rgba(58, 59, 69, 0.15);
    margin-bottom: 24px;
    border-radius: 12px;
}

/* Espacement des sections principales */
.section-spacing {
    margin-bottom: 32px;
}

.section-spacing:last-child {
    margin-bottom: 0;
}

.btn {
    border-radius: 0.35rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05rem;
    font-size: 0.75rem;
}

.form-control {
    border-radius: 0.35rem;
    border: 1px solid #e3e6f0;
}

.form-control:focus {
    border-color: #5e72e4;
    box-shadow: 0 0 0 0.2rem rgba(94, 114, 228, 0.25);
}

/* Layout d'authentification sans sidebar - Style Google Professionnel */
.auth-body {
    background: #f8f9fa;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: "Google Sans", "Open Sans", sans-serif;
    padding: 20px 0;
}

.auth-container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    padding: 20px;
}

.auth-header {
    text-align: center;
    margin-bottom: 16px;
}

.auth-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    padding: 16px 24px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #e8eaed;
    transition: all 0.3s ease;
}

.auth-brand:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.auth-logo {
    width: 40px;
    height: 40px;
    margin-right: 12px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.auth-brand-text {
    color: #1a1a1a;
    font-weight: 500;
    font-size: 1.25rem;
    letter-spacing: -0.025em;
    font-family: "Google Sans", sans-serif;
}

.auth-content {
    margin-bottom: 16px;
}

.auth-card {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border: 1px solid #e8eaed;
    overflow: hidden;
}

.auth-card-header {
    padding: 24px 32px;
}

.auth-footer {
    text-align: center;
    color: #5f6368;
    font-size: 0.9rem;
    margin-top: 20px;
}

/* Styles pour les formulaires d'authentification - Style Google */
.auth-card .form-control {
    border-radius: 6px;
    border: 1px solid #dadce0;
    padding: 12px 16px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    background: #ffffff;
    height: 44px;
    font-family: "Google Sans", sans-serif;
}

.auth-card .form-control:focus {
    border-color: var(--becadis-primary);
    box-shadow: 0 0 0 2px rgba(94, 114, 228, 0.2);
    background: #ffffff;
    outline: none;
}

.auth-card .form-control::placeholder {
    color: #5f6368;
    font-size: 0.9rem;
}

.auth-card .form-label {
    font-weight: 500;
    font-size: 0.8rem;
    color: #3c4043;
    margin-bottom: 6px;
    font-family: "Google Sans", sans-serif;
}

.auth-card .btn {
    border-radius: 6px;
    padding: 12px 20px;
    font-weight: 500;
    font-size: 0.9rem;
    text-transform: none;
    letter-spacing: 0.025em;
    transition: all 0.2s ease;
    height: 44px;
    font-family: "Google Sans", sans-serif;
}

.auth-card .btn-primary {
    background: var(--becadis-primary);
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.auth-card .btn-primary:hover {
    background: #4c63d2;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.auth-card .btn-link {
    color: var(--becadis-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
}

.auth-card .btn-link:hover {
    color: #4c63d2;
    text-decoration: underline;
}

/* Styles pour les titres */
.auth-card h2 {
    font-size: 1.25rem;
    font-weight: 400;
    color: #202124;
    margin-bottom: 4px;
    font-family: "Google Sans", sans-serif;
}

.auth-card p {
    color: #5f6368;
    font-size: 0.8rem;
    margin-bottom: 16px;
}

/* Styles pour les groupes d'input */
.auth-card .input-group {
    margin-bottom: 16px;
}

.auth-card .input-group-text {
    background: #f8f9fa;
    border: 1px solid #dadce0;
    border-right: none;
    color: #5f6368;
    padding: 12px;
    border-radius: 6px 0 0 6px;
}

.auth-card .input-group .form-control {
    border-left: none;
    border-radius: 0 6px 6px 0;
}

/* Styles pour les checkboxes */
.auth-card .form-check {
    margin-bottom: 16px;
}

.auth-card .form-check-input {
    margin-top: 0.25rem;
}

.auth-card .form-check-label {
    font-size: 0.875rem;
    color: #3c4043;
    font-family: "Google Sans", sans-serif;
}

/* Correction du décalage pour les liens */
.auth-card .text-center p {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0;
    line-height: 1.4;
}

.auth-card .text-center p .btn-link {
    margin-left: 4px;
    vertical-align: baseline;
}

/* Styles pour les messages d'erreur */
.auth-card .invalid-feedback {
    display: block !important;
    color: #d93025;
    font-size: 0.8rem;
    margin-top: 4px;
    font-weight: 400;
}

.auth-card .is-invalid {
    border-color: #d93025 !important;
    box-shadow: 0 0 0 2px rgba(217, 48, 37, 0.1) !important;
}

.auth-card .is-invalid:focus {
    border-color: #d93025 !important;
    box-shadow: 0 0 0 2px rgba(217, 48, 37, 0.2) !important;
}

/* Messages d'erreur généraux */
.auth-card .alert {
    border-radius: 6px;
    border: none;
    font-size: 0.875rem;
    margin-bottom: 16px;
}

.auth-card .alert-danger {
    background-color: #fce8e6;
    color: #d93025;
    border-left: 4px solid #d93025;
}

.auth-card .alert-success {
    background-color: #e6f4ea;
    color: #137333;
    border-left: 4px solid #137333;
}

/* Styles pour les boutons d'affichage/masquage du mot de passe */
.auth-card .input-group .btn-outline-secondary {
    border-left: none;
    border-radius: 0 6px 6px 0;
    background: #f8f9fa;
    border-color: #dadce0;
    color: #5f6368;
    padding: 8px 12px;
    transition: all 0.2s ease;
}

/* Styles pour le menu horizontal (topbar) fixe qui s'adapte au sidebar */
.topbar {
    position: fixed;
    top: 0;
    left: 280px; /* Commence après le sidebar */
    right: 0;
    z-index: 1030;
    background: #ffffff;
    border-bottom: 1px solid #e8eaed;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    height: 60px;
    width: calc(100% - 280px); /* Largeur totale moins la largeur du sidebar */
}

.topbar .container-fluid {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    max-width: 100%;
}

/* Titre de page dans le topbar */
.topbar h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #202124;
    margin: 0;
    font-family: "Google Sans", sans-serif;
}

/* Ajustement du contenu principal pour le topbar fixe */
.main-content {
    margin-top: 60px;
    margin-left: 280px;
    min-height: calc(100vh - 60px);
    padding: 32px;
    background: #f8f9fa;
}

/* Responsive pour le topbar et sidebar */
@media (max-width: 768px) {
    .topbar {
        left: 0;
        width: 100%;
    }

    .topbar .container-fluid {
        padding: 0 16px;
    }

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

    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

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

.auth-card .input-group .btn-outline-secondary:hover {
    background: #e8eaed;
    border-color: #dadce0;
    color: #3c4043;
}

.auth-card .input-group .btn-outline-secondary:focus {
    box-shadow: 0 0 0 2px rgba(66, 133, 244, 0.2);
    border-color: #4285f4;
    outline: none;
}

.auth-card .input-group .btn-outline-secondary i {
    font-size: 0.875rem;
}

/* Classes utilitaires pour l'authentification */
.mb-5 {
    margin-bottom: 3rem !important;
}

.mb-6 {
    margin-bottom: 2rem !important;
}

/* Responsive pour l'authentification */
@media (max-width: 768px) {
    .auth-container {
        max-width: 400px;
        padding: 20px 15px;
    }

    .auth-card-header {
        padding: 32px 24px;
    }

    .auth-brand {
        padding: 20px 24px;
    }

    .auth-logo {
        width: 48px;
        height: 48px;
        margin-right: 16px;
    }

    .auth-brand-text {
        font-size: 1.5rem;
    }

    .auth-card .form-control {
        height: 48px;
        padding: 12px 16px;
    }

    .auth-card .btn {
        height: 48px;
        padding: 12px 20px;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .sidebar {
        width: 240px; /* Ajusté pour mobile */
        max-width: 240px;
    }

    .main-content {
        margin-left: 240px; /* Ajusté pour mobile */
        padding: 16px 20px; /* Padding réduit sur mobile */
    }

    .sidebar-brand-logo {
        width: 28px;
        height: 28px;
    }

    .topbar-brand-logo {
        width: 24px;
        height: 24px;
    }

    .nav-link {
        padding: 8px 10px; /* Encore plus compact sur mobile */
    }

    .collapse .nav-link {
        padding: 6px 10px 6px 20px; /* Encore plus compact sur mobile */
    }
}

/* ===== OPTIMISATIONS POUR ÉLIMINER LES REDONDANCES ===== */

/* Cartes optimisées et cohérentes */
.card {
    margin-bottom: 24px;
    border-radius: 12px;
    border: 1px solid #e8eaed;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    background: #ffffff;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
    transform: translateY(-1px);
}

.card-header {
    background: #ffffff;
    border-bottom: 1px solid #e8eaed;
    padding: 20px 24px;
    border-radius: 12px 12px 0 0;
}

.card-body {
    padding: 24px;
}

/* Titres de section cohérents */
.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #202124;
    margin-bottom: 20px;
    font-family: "Google Sans", sans-serif;
}

/* Boutons cohérents */
.btn {
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.btn-primary {
    background: var(--becadis-primary);
    border-color: var(--becadis-primary);
}

.btn-primary:hover {
    background: #4c63d2;
    border-color: #4c63d2;
    transform: translateY(-1px);
}

/* Formulaires cohérents */
.form-control {
    border-radius: 8px;
    border: 1px solid #dadce0;
    padding: 12px 16px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.form-control:focus {
    border-color: var(--becadis-primary);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.1);
}

/* Espacement uniforme et cohérent */
.mb-section {
    margin-bottom: 32px;
}

.mb-card {
    margin-bottom: 24px;
}

.mb-element {
    margin-bottom: 16px;
}

/* Suppression des redondances visuelles */
.text-muted {
    color: #5f6368 !important;
}

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

/* Alignement cohérent */
.d-flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.d-flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
}
