/* ==========================================================================
   src/css/admin.css (VERSION FINALISÉE & STRICTE)
   ========================================================================== */

/* --- 0. VARIABLES --- */
:root {
    --wp-admin-bar: #1d2327;
    --wp-sidebar: #23282d;
    --wp-sidebar-hover: #191e23;
    --wp-blue: #2271b1;
    --wp-blue-hover: #135e96;
    --wp-red: #d63638;
    --wp-green: #46b450;
    --wp-gray-bg: #f0f0f1;
    --wp-border-color: #c3c4c7;
    --wp-text-main: #3c434a;
}

/* --- 1. RESET & STRUCTURE --- */
* {
    box-sizing: border-box;
}

/* Important pour les calculs de taille */

body {
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--wp-gray-bg);
    color: var(--wp-text-main);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Liens génériques */
a {
    text-decoration: none;
    color: var(--wp-blue);
}

a:hover {
    color: var(--wp-blue-hover);
}


/* --- 2. HEADER (ADMIN BAR) --- */
#wp-admin-bar {
    height: 46px;
    background-color: var(--wp-admin-bar);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    flex-shrink: 0;
    z-index: 9999;
}

.ab-left a {
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

/* Zone Droite : On utilise GAP pour éviter les chevauchements */
.ab-right {
    display: flex;
    align-items: center;
    gap: 20px;
    height: 100%;
}

/* --- 3. NOTIFICATIONS (CORRECTION BADGE ROND) --- */
.notification-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    /* Icône blanche */
    width: 24px;
    height: 24px;
}

.notification-icon:hover {
    opacity: 0.8;
}

.badge-count {
    position: absolute;
    top: -4px;
    right: -6px;
    background-color: var(--wp-red);
    color: white;
    font-size: 10px;
    font-weight: bold;

    /* On force un cercle parfait */
    width: 16px;
    height: 16px;
    border-radius: 50%;

    /* Centrage du chiffre */
    display: flex;
    align-items: center;
    justify-content: center;

    border: 2px solid var(--wp-admin-bar);
    /* Bordure couleur fond pour détacher */
    padding: 0;
    /* Pas de padding pour éviter l'ovale */
    z-index: 10;
}


/* --- 4. PROFIL & LOGOUT --- */
.user-profile {
    display: flex;
    align-items: center;
    gap: 10px;
    /* Espace Avatar <-> Nom */
    color: #f0f0f1;
    font-size: 13px;
}

.user-avatar {
    width: 30px;
    height: 30px;
    background-color: #50575e;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    border: 2px solid #3c434a;
    flex-shrink: 0;
}

.logout-link {
    color: #f86e74 !important;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
}


/* --- 5. LAYOUT PRINCIPAL --- */
#admin-wrapper {
    display: flex;
    flex: 1;
    overflow: hidden;
}

#admin-sidebar {
    width: 200px;
    background: var(--wp-sidebar);
    color: #fff;
    overflow-y: auto;
    flex-shrink: 0;
    padding-top: 10px;
}

#admin-sidebar ul {
    padding: 0;
    margin: 0;
    list-style: none;
}

#admin-sidebar li a {
    display: block;
    padding: 10px 15px;
    color: #eee;
    border: none;
    font-size: 14px;
}

#admin-sidebar li a:hover {
    background: var(--wp-sidebar-hover);
    color: #72aee6;
}

#admin-content {
    flex-grow: 1;
    padding: 20px 40px;
    overflow-y: auto;
    background: var(--wp-gray-bg);
}

.wp-container {
    width: 100%;
    margin: 0;
}

.wp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.wp-heading-inline {
    font-size: 23px;
    font-weight: 400;
    color: #1d2327;
    margin: 0;
}


/* --- 6. FORMULAIRES & BOUTONS (ALIGNEMENT STRICT) --- */

/* On force tous les éléments interactifs à 36px de hauteur */
.wp-container input[type="text"],
.wp-container input[type="date"],
.wp-container select,
.btn-primary,
.btn-secondary,
.btn-danger-outline,
.file-upload-wrapper {
    height: 36px;
    line-height: normal;
    /* Important pour centrage vertical */
    padding: 0 10px;
    font-size: 13px;
    border-radius: 4px;
    vertical-align: middle;
    box-sizing: border-box;
    display: inline-flex;
    align-items: center;
    margin: 0;
    font-family: inherit;
}

/* Inputs spécifiques */
.wp-container input,
.wp-container select {
    border: 1px solid #8c8f94;
    background: #fff;
    color: #2c3338;
}

.wp-container input:focus,
select:focus {
    border-color: var(--wp-blue);
    box-shadow: 0 0 0 1px var(--wp-blue);
    outline: none;
}

/* Boutons Pillules (Quiz Actions) */
.btn-pill-green {
    background: #fff;
    color: #10b981;
    border: 1px solid #10b981;
    border-radius: 50px;
    padding: 2px 12px 2px 4px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    height: 30px;
}

.btn-pill-green:hover {
    background: #f0fdf4;
}

.btn-pill-green .icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border: 1px solid #10b981;
    border-radius: 50%;
}

.btn-pill-green .icon-circle svg {
    width: 10px !important;
    height: 10px !important;
    margin: 0 !important;
}

.btn-pill-red {
    background: #fff;
    color: #ef4444;
    border: 1px solid #ef4444;
    border-radius: 50px;
    padding: 2px 12px 2px 4px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    height: 30px;
}

.btn-pill-red:hover {
    background: #fef2f2;
}

.btn-pill-red .icon-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border: 1px solid #ef4444;
    border-radius: 50%;
}

.btn-pill-red .icon-circle svg {
    width: 10px !important;
    height: 10px !important;
    margin: 0 !important;
}

/* Boutons */
.btn-primary {
    background: var(--wp-blue);
    border: 1px solid var(--wp-blue);
    color: #fff;
    cursor: pointer;
}

.btn-primary:hover {
    background: var(--wp-blue-hover);
    color: #fff;
}

.btn-secondary {
    background: #f6f7f7;
    border: 1px solid #2271b1;
    color: #2271b1;
    cursor: pointer;
}

.btn-secondary:hover {
    background: #f0f0f1;
    color: #135e96;
}

.btn-danger-outline {
    background: transparent;
    border: 1px solid var(--wp-red);
    color: var(--wp-red);
    cursor: pointer;
}

.btn-danger-outline:hover {
    background: var(--wp-red);
    color: #fff;
}

/* Upload Wrapper Spécial */
.file-upload-wrapper {
    padding: 0;
    /* Pas de padding sur le wrapper, le bouton dedans s'en charge */
    border: none;
    overflow: hidden;
    position: relative;
    width: auto;
}

.file-upload-wrapper button {
    height: 100%;
    /* Le bouton prend toute la hauteur */
    border-radius: 4px 0 0 4px;
    /* Coin carré à droite pour coller au texte */
}

.file-upload-wrapper input[type=file] {
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

#file-chosen {
    margin-left: 10px;
    font-size: 13px;
    color: #666;
    line-height: 36px;
    /* Pour aligner le texte */
}


/* --- 7. CARTES & LAYOUT OUTILS --- */
.wp-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .04);
}

.search-box-card {
    background: #f9f9f9;
    padding: 10px 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 4px;
    border: 1px solid #dcdcde;
    margin-bottom: 20px;
}

.role-badge-prof {
    background: #e5f5fa;
    color: #2271b1;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
}

.role-badge-student {
    background: #f0f0f1;
    color: #3c434a;
    padding: 2px 6px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: bold;
}

.badge-log {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.75em;
    font-weight: bold;
    text-transform: uppercase;
}

.type-CONNEXION {
    background: #dcfce7;
    color: #166534;
}

.type-CHAT {
    background: #e0f2fe;
    color: #075985;
}

.type-POSTIT_ADD {
    background: #fef9c3;
    color: #854d0e;
}

.type-QUIZ_RESULT {
    background: #fee2e2;
    color: #991b1b;
}

.profile-section-title {
    margin-top: 0;
    border-bottom: 1px solid #eee;
    padding-bottom: 10px;
    color: #23282d;
}

.profile-security-box {
    background: #f9f9f9;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.notif-list {
    background: white;
    padding: 0;
    list-style: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin: 0;
}

.notif-item {
    padding: 15px;
    border-bottom: 1px solid #eee;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.notif-item:last-child {
    border-bottom: none;
}

.notif-unread {
    background: #eaf4fc;
    border-left: 4px solid #2271b1;
}

.notif-read {
    background: #fff;
    opacity: 0.6;
    border-left: 4px solid transparent;
}

.card-stat {
    padding: 20px;
    border-radius: 4px;
    min-width: 150px;
    text-align: center;
}

.dot-online {
    display: inline-block;
    width: 10px;
    height: 10px;
    background: #46b450;
    border-radius: 50%;
    box-shadow: 0 0 5px #46b450;
    animation: blink 2s infinite;
}

@keyframes blink {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 1;
    }
}

.badge-act {
    background: #f0f0f1;
    padding: 2px 8px;
    border-radius: 10px;
    font-weight: bold;
    color: #555;
}

.badge-high {
    background: #dbeafe;
    color: #1e40af;
}

.actions-row,
.search-box {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
    /* Espacement propre entre les groupes */
}

/* On s'assure que les formulaires internes sont alignés */
.actions-row form,
.search-box form {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* --- 13. DASHBOARD (Accueil Admin) --- */

.dashboard-welcome {
    background: #fff;
    padding: 20px 30px;
    border-left: 4px solid var(--wp-blue);
    margin-bottom: 30px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border-radius: 4px;
}

.dashboard-welcome h2 {
    margin-top: 0;
    color: #1d2327;
}

.dashboard-welcome p {
    color: #50575e;
    margin-bottom: 0;
    font-size: 14px;
}

/* --- 2. LAYOUT PRINCIPAL DES PAGES ADMIN --- */

.nav-tab-wrapper {
    margin: 20px 0;
    padding-bottom: 10px;
    border-bottom: 1px solid #c3c4c7;
    font-size: 16px;
    font-weight: 500;
}

/* Grille Dashboard Tools (KPIs en haut) */
.dashboard-tools-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-tool-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 6px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: transform 0.2s, box-shadow 0.2s;
    flex: 1 1 200px;
    /* S'étire pour occuper 100% de la largeur dispo */
    min-width: 150px;
}

.dashboard-tool-icon {
    font-size: 38px;
    line-height: 1;
    margin-bottom: 15px;
    display: block;
    text-align: center;
}

.dashboard-tool-card:hover {
    transform: translateY(-2px);
    color: #666;
    display: block;
    margin-top: 5px;
}

.dashboard-tool-card .btn-primary {
    width: auto;
    justify-content: center;
    padding: 0 20px;
    text-decoration: none;
    height: auto;
    /* override global button height for this specific block button */
}

/* GridStack prend désormais le relais pour la position / redimsensionnement */
.grid-stack-item-content {
    background: #fff;
    border: 1px solid #8c8f94;
    /* Bordure mieux marquée */
    border-radius: 6px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.grid-stack-item.widget-hidden {
    display: none !important;
}

/* Entête du widget (Glissable) */
.widget-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #f0f0f1;
    /* Entête bien distinct du contenu */
    border-bottom: 1px solid #c3c4c7;
    padding: 12px 15px;
    margin-bottom: 0;
}

/* Contenu du widget */
.widget-body {
    padding: 15px;
    flex-grow: 1;
    overflow-y: auto;
}

/* Style des listes déroulantes (select) standard d'admin */
.admin-select {
    padding: 6px 30px 6px 12px;
    font-size: 13px;
    font-family: inherit;
    color: #1d2327;
    background-color: #fff;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%206l5%205%205-5%202%201-7%207-7-7%202-1z%22%20fill%3D%22%23555%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 6px center;
    background-size: 16px;
    cursor: pointer;
    line-height: 1.5;
    outline: none;
    transition: 0.1s;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.admin-select:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}

/* Poignée de redimensionnement GridStack personnalisée et très visible */
.grid-stack-item .ui-resizable-se {
    width: 25px !important;
    height: 25px !important;
    right: 0 !important;
    bottom: 0 !important;
    background-image: none !important;
    cursor: nwse-resize !important;
    opacity: 1 !important;
}

.grid-stack-item .ui-resizable-se::after {
    content: "◢";
    position: absolute;
    bottom: 2px;
    right: 4px;
    color: #2271b1;
    /* Couleur bleue bien visible */
    font-size: 18px;
}

.grid-stack-item:hover .ui-resizable-se::after {
    color: #135e96;
}

.widget-title {
    margin: 0;
    font-size: 15px;
    color: #1d2327;
    font-weight: 600;
    cursor: grab;
    /* C'est lui qu'on attrape */
    user-select: none;
    /* Empeche la sélection du texte */
    flex-grow: 1;
    /* Pousse les boutons à droite */
}

.widget-title:active {
    cursor: grabbing;
}

.widget-controls {
    display: flex;
    gap: 8px;
}

.widget-controls button {
    background: none;
    border: none;
    color: #8c8f94;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
    transition: background 0.2s, color 0.2s;
}

.widget-controls button:hover {
    background: #f0f0f1;
    color: var(--wp-blue);
}

.widget-controls .btn-close:hover {
    color: #d63638;
}

/* Overlay lors du glissement (Sortable) */
.sortable-ghost {
    opacity: 0.4;
    background-color: #f0f0f1;
    border: 1px dashed #c3c4c7;
}

/* Conteneur pour ajouter des widgets */
#widget-adder-container {
    margin-top: 20px;
    text-align: right;
}

/* --- 8. TABLEAUX & ICÔNES (CORRECTION GÉANTS) --- */
table.wp-list-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    border: 1px solid #c3c4c7;
    margin-top: 15px;
}

table.wp-list-table th {
    text-align: left;
    padding: 10px;
    border-bottom: 1px solid #c3c4c7;
    background: #fcfcfc;
    font-weight: 600;
    font-size: 14px;
}

table.wp-list-table td {
    padding: 10px;
    border-bottom: 1px solid #f0f0f1;
    vertical-align: middle;
    color: #50575e;
    font-size: 13px;
}

/* === CORRECTION MAJEURE : TAILLE DES ICÔNES === */
/* On force toutes les SVG dans le tableau à une taille fixe */
table.wp-list-table svg,
.icon-action {
    width: 20px !important;
    height: 20px !important;
    vertical-align: middle;
    fill: currentColor;
    display: inline-block;
}

/* Petites icônes dans les boutons */
.btn-primary svg,
.btn-secondary svg {
    width: 16px !important;
    height: 16px !important;
    margin-right: 5px;
}

/* Checkbox */
input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
}

/* --- 9. LOGIN & DIVERS --- */
body.login-page {
    background: #f0f2f5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-box {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    width: 400px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.login-box input {
    width: 100%;
    margin-bottom: 15px;
}

.login-box button {
    width: 100%;
    background: var(--wp-blue);
    color: #fff;
    border: none;
}

.notice {
    background: #fff;
    border-left: 4px solid #fff;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .1);
    padding: 10px 12px;
    margin-bottom: 20px;
}

.notice-success {
    border-left-color: var(--wp-green);
}

.notice-error {
    border-left-color: var(--wp-red);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    border-radius: 22px;
    background: var(--wp-red);
    transition: 0.3s;
    vertical-align: middle;
}

.toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
}

.toggle-switch.active {
    background: var(--wp-green);
}

.toggle-switch.active::after {
    left: 20px;
}

/* ==========================================================================
   AJOUTS : PAGE DE CONNEXION & MOT DE PASSE OUBLIÉ
   ========================================================================== */

/* Structure de la page pleine page (centrée) */
body.login-page {
    background-color: #f0f2f5;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    width: 100%;
    margin: 0;
}

/* La carte blanche centrée */
.login-card {
    background: #fff;
    width: 100%;
    max-width: 400px;
    padding: 30px 40px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    text-align: center;
    border: 1px solid #c3c4c7;
}

.login-card h1 {
    margin-top: 0;
    margin-bottom: 25px;
    font-size: 24px;
    color: #333;
    font-weight: 500;
}

.login-card form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    /* Espace entre les champs */
}

/* Champs spécifiques au Login (plus hauts que l'admin classique) */
.login-card input[type="text"],
.login-card input[type="password"],
.login-card input[type="email"] {
    width: 100%;
    height: 45px;
    /* Hauteur confortable */
    padding: 0 15px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    font-size: 16px;
    background: #fff;
    box-sizing: border-box;
}

.login-card input:focus {
    border-color: var(--wp-blue);
    box-shadow: 0 0 0 1px var(--wp-blue);
    outline: none;
}

/* Bouton de connexion large */
.btn-login {
    width: 100%;
    height: 45px;
    background-color: var(--wp-blue);
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-login:hover {
    background-color: var(--wp-blue-hover);
}

/* Liens en bas de carte */
.login-footer {
    margin-top: 20px;
    font-size: 14px;
    color: #666;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.login-footer a {
    color: #555;
    text-decoration: none;
}

.login-footer a:hover {
    color: var(--wp-blue);
    text-decoration: underline;
}

/* --- MISE À JOUR SIDEBAR AVEC ICÔNES --- */

#admin-sidebar li a {
    display: flex;
    /* Active le mode flexible */
    align-items: center;
    /* Centre verticalement l'icône et le texte */
    gap: 12px;
    /* Espace entre l'icône et le texte */
    padding: 12px 15px;
    /* Un peu plus d'espace pour respirer */
    color: #eee;
    text-decoration: none;
    font-size: 14px;
    border-bottom: none;
    transition: all 0.1s;
}

#admin-sidebar li a:hover {
    background-color: var(--wp-sidebar-hover);
    color: #72aee6;
    /* Bleu WP au survol */
}

/* Style des icônes SVG dans le menu */
#admin-sidebar li a svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
    /* L'icône prend la couleur du texte (blanc puis bleu au survol) */
    opacity: 0.8;
    /* Légèrement transparent par défaut */
    flex-shrink: 0;
    /* Empêche l'icône de s'écraser */
}

#admin-sidebar li a:hover svg {
    opacity: 1;
    /* Pleine opacité au survol */
}

/* ==========================================================================
   --- 10. PAGE PROFIL & FORMULAIRES ---
   ========================================================================== */

/* Conteneur spécifique pour le profil (centré) */
.profile-card {
    max-width: 600px;
    margin: 0;
    /* Aligne la carte à gauche */
}

/* Titres de section (ex: Informations Générales, Sécurité) */
.wp-card h3 {
    margin-top: 0;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
    color: #23282d;
    font-size: 18px;
    font-weight: 500;
}

/* Groupes de champs (Label + Input) */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--wp-text-main);
}

/* Force les champs à prendre toute la largeur dans les formulaires */
.wp-card input[type="text"],
.wp-card input[type="email"],
.wp-card input[type="password"] {
    width: 100%;
    /* La hauteur et les bordures sont déjà gérées par le CSS global (section 6) */
}

/* Textes d'aide (petits textes gris sous les champs) */
.form-helper {
    font-size: 13px;
    color: #646970;
    margin-top: 6px;
    margin-bottom: 0;
}

/* Zone Sécurité (Fond gris) */
.security-box {
    background: #f9f9f9;
    padding: 20px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    margin-top: 20px;
}

.security-box p {
    margin-top: 0;
    margin-bottom: 15px;
    color: #50575e;
    font-size: 13px;
}

/* Zone des boutons (alignés à droite avec bordure) */
.form-actions {
    margin-top: 25px;
    padding-top: 15px;
    border-top: 1px solid #f0f0f1;
    text-align: right;
}

/* ==========================================================================
   CORRECTION HAUTEUR UNIFORME (PAGE PROFIL)
   ========================================================================== */

/* On cible précisément tous les types de champs dans la carte de profil */
.profile-card input[type="text"],
.profile-card input[type="email"],
.profile-card input[type="password"] {
    height: 40px !important;
    /* Force la hauteur identique (Prioritaire) */
    min-height: 40px;
    /* Sécurité pour empêcher le rétrécissement */
    line-height: normal;
    /* Centre le texte verticalement */
    padding: 0 12px;
    /* Espace interne confortable */
    box-sizing: border-box;
    /* Inclut le padding dans le calcul de la hauteur */
    width: 100%;
    /* Prend toute la largeur disponible */
    font-size: 14px;
    /* Taille de texte homogène */
    margin: 0;
    /* Enlève les marges par défaut */
}

/* ==========================================================================
   --- 11. GESTION DES SALLES ---
   ========================================================================== */

/* Zone "Ajouter une salle" (Formulaire en ligne) */
.room-form-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    padding: 20px;
    border-radius: 4px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .04);
    margin-bottom: 20px;
}

.room-form {
    display: flex;
    align-items: flex-end;
    /* Aligne les champs et le bouton en bas */
    gap: 15px;
    /* Espace entre les éléments */
}

.room-form-group {
    flex-grow: 1;
    /* Les champs prennent toute la place disponible */
}

.room-form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    color: var(--wp-text-main);
    font-size: 13px;
}

.room-form-group input {
    width: 100%;
    /* La hauteur est déjà gérée par vos règles globales (40px) */
}

/* Style des Badges pour les Codes d'Accès */
.code-badge {
    display: inline-block;
    background-color: var(--wp-blue);
    color: #fff;
    padding: 4px 10px;
    border-radius: 4px;
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.5px;
    border: 1px solid var(--wp-blue-hover);
}

/* Bouton d'action Supprimer (Icone seule) */
.action-delete-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #d63638;
    /* Rouge WP */
    background: transparent;
    border: 1px solid transparent;
    width: 32px;
    height: 32px;
    border-radius: 4px;
    transition: all 0.2s;
    cursor: pointer;
}

.action-delete-btn:hover {
    background-color: #fbeaea;
    border-color: #d63638;
}

.action-delete-btn svg {
    width: 18px !important;
    height: 18px !important;
    fill: currentColor;
}

/* ==========================================================================
   --- 12. GESTION DES QUIZ ---
   ========================================================================== */

/* Alignement des boutons d'actions dans le tableau */
.table-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    align-items: center;
}

/* Style générique des petites icônes d'action */
.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #646970;
    /* Gris par défaut */
    transition: all 0.2s;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 4px;
}

.icon-btn svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

/* Couleurs spécifiques au survol */
.icon-btn.edit:hover {
    color: var(--wp-blue);
    background: #f0f6fc;
}

.icon-btn.view:hover {
    color: var(--wp-green);
    background: #edfaef;
}

.icon-btn.delete:hover {
    color: var(--wp-red);
    background: #fbeaea;
}

.icon-btn.enter:hover {
    color: var(--wp-blue);
    background: #f0f6fc;
}

.icon-btn.settings:hover {
    color: #444;
    background: #e5e5e5;
}

.icon-btn.monitor:hover {
    color: #d63638;
    background: #fbeaea;
}

/* Bouton "Ajouter" à côté du titre (Style WP) */
.page-title-action {
    display: inline-block;
    position: relative;
    top: -4px;
    margin-left: 10px;
    padding: 4px 10px;
    font-size: 13px;
    line-height: 1.5;
    font-weight: 400;
    background: #f6f7f7;
    color: var(--wp-blue);
    border: 1px solid var(--wp-blue);
    border-radius: 4px;
    text-decoration: none;
}

.page-title-action:hover {
    background: #f0f0f1;
    border-color: var(--wp-blue-hover);
    color: var(--wp-blue-hover);
}

/* ==========================================================================
   --- 12. GESTION DES QUIZ (CORRIGÉ & ALIGNÉ) ---
   ========================================================================== */

/* Conteneur principal de l'en-tête (Flexbox pour écarter Titre et Recherche) */
.wp-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    /* Titre à gauche, Recherche à droite */
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 20px;
}

/* Groupe Gauche : Titre + Bouton Ajouter */
.wp-header-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
    /* Espace propre entre "Mes Quiz" et "Ajouter" */
}

/* On force le titre à ne pas avoir de marge pour s'aligner avec le bouton */
.wp-heading-inline {
    margin: 0 !important;
    /* Force le reset des marges */
    padding: 0;
    line-height: 1.2;
    font-size: 23px;
    font-weight: 400;
    color: #1d2327;
}

/* Le bouton "Ajouter" aligné verticalement */
.page-title-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 13px;
    height: 30px;
    /* Hauteur fixe pour alignement */
    padding: 0 12px;
    color: #2271b1;
    /* Variable CSS si dispo, sinon code couleur */
    background: #f6f7f7;
    border: 1px solid #2271b1;
    border-radius: 4px;
    font-weight: 500;
    position: relative;
    top: 0;
    /* On annule les décalages précédents */
    transition: all 0.2s;
}

.page-title-action:hover {
    background: #f0f0f1;
    color: #135e96;
    border-color: #135e96;
}

/* Zone de Recherche à droite */
.search-box-header {
    display: flex;
    gap: 5px;
}

.search-box-header input {
    width: 200px;
    height: 30px !important;
    /* Même hauteur que le bouton Ajouter */
    font-size: 13px;
}

.search-box-header .btn-secondary {
    height: 30px !important;
}

/* Reste du tableau (inchangé mais rappelé pour cohérence) */
.table-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.icon-btn {
    padding: 5px;
    border: none;
    background: transparent;
    cursor: pointer;
    color: #646970;
}

.icon-btn svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.icon-btn:hover {
    color: #2271b1;
    background: #f0f6fc;
    border-radius: 4px;
}

.icon-btn.delete:hover {
    color: #d63638;
    background: #fbeaea;
}

/* ==========================================================================
   --- 13. GESTION DES QUESTIONS ---
   ========================================================================== */

/* Bouton "Retour" spécifique pour l'en-tête (aligné avec "Ajouter") */
.btn-header-back {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    font-size: 13px;
    height: 30px;
    /* Même hauteur que .page-title-action */
    padding: 0 12px;
    color: #646970;
    background: #fff;
    border: 1px solid #c3c4c7;
    border-radius: 4px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn-header-back:hover {
    background: #f0f0f1;
    color: #1d2327;
    border-color: #8c8f94;
}

/* ==========================================================================
   --- 14. ÉDITEURS (QUIZ & QUESTIONS) ---
   ========================================================================== */

/* Carte principale pour les formulaires d'édition */
.editor-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    padding: 30px;
    border-radius: 4px;
    box-shadow: 0 1px 1px rgba(0, 0, 0, .04);
    max-width: 800px;
    margin: 0 auto;
    /* Centré */
}

/* Zone de titre (Énoncé de la question) */
.editor-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    font-size: 14px;
    color: #1d2327;
}

.editor-textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
}

/* Zone Média (Image actuelle + Upload) */
.media-box {
    background: #f9f9f9;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    margin-bottom: 20px;
}

.current-media {
    margin-bottom: 10px;
    font-size: 13px;
    color: #2271b1;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* LISTE DES RÉPONSES (Alignement Checkbox + Input + Croix) */
.answers-container {
    background: #fff;
    border: 1px solid #ddd;
    padding: 20px;
    border-radius: 4px;
    margin-top: 10px;
}

.reponse-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

/* Case à cocher (Bonne réponse) */
.reponse-check {
    width: 20px !important;
    height: 20px !important;
    cursor: pointer;
    margin: 0 !important;
}

/* Champ texte réponse */
.reponse-input {
    flex-grow: 1;
    /* Prend toute la largeur restante */
    height: 36px;
    padding: 0 10px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
}

/* Bouton Supprimer (X) */
.btn-remove-answer {
    background: transparent;
    border: 1px solid #d63638;
    color: #d63638;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    line-height: 1;
}

.btn-remove-answer:hover {
    background: #d63638;
    color: white;
}

/* Bouton "Ajouter une réponse" */
.btn-add-answer {
    display: inline-block;
    margin-top: 10px;
    font-size: 13px;
    color: #2271b1;
    border: 1px dashed #2271b1;
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
    background: #f6f7f7;
    cursor: pointer;
}

.btn-add-answer:hover {
    background: #f0f0f1;
    border-style: solid;
}

/* --- 14. ÉDITEURS (QUIZ & QUESTIONS) --- */
.editor-card {
    background: #fff;
    border: 1px solid #c3c4c7;
    padding: 30px;
    border-radius: 4px;
    max-width: 800px;
    margin: 0 auto;
}

.editor-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1d2327;
}

.editor-textarea {
    width: 100%;
    min-height: 80px;
    padding: 10px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
    font-family: inherit;
    resize: vertical;
}

.media-box {
    background: #f9f9f9;
    padding: 15px;
    border: 1px solid #ddd;
    margin-bottom: 20px;
}

.current-media {
    margin-bottom: 10px;
    color: #2271b1;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Liste des réponses */
.answers-container {
    background: #fff;
    border: 1px solid #ddd;
    padding: 20px;
    border-radius: 4px;
    margin-top: 10px;
}

.reponse-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.reponse-check {
    width: 20px !important;
    height: 20px !important;
    margin: 0 !important;
    cursor: pointer;
}

.reponse-input {
    flex-grow: 1;
    height: 36px;
    padding: 0 10px;
    border: 1px solid #8c8f94;
    border-radius: 4px;
}

.btn-remove-answer {
    background: transparent;
    border: 1px solid #d63638;
    color: #d63638;
    width: 30px;
    height: 30px;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
}

.btn-remove-answer:hover {
    background: #d63638;
    color: white;
}

.btn-add-answer {
    display: inline-block;
    margin-top: 10px;
    color: #2271b1;
    border: 1px dashed #2271b1;
    padding: 8px 15px;
    border-radius: 4px;
    background: #f6f7f7;
    cursor: pointer;
}

/* --- GESTION ÉLÈVES & MAIL --- */
.admin-container {
    max-width: 1200px;
    margin: 30px auto;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    font-family: system-ui, sans-serif;
}

/* Onglets de navigation */
.tabs {
    display: flex;
    gap: 10px;
    border-bottom: 2px solid #eee;
    margin-bottom: 20px;
}

.tab-btn {
    padding: 10px 20px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    color: #64748b;
    font-weight: 600;
}

.tab-btn.active {
    color: #2563eb;
    border-bottom: 2px solid #2563eb;
    margin-bottom: -2px;
}

/* Tableaux */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.data-table th,
.data-table td {
    text-align: left;
    padding: 12px;
    border-bottom: 1px solid #e2e8f0;
}

.data-table th {
    background: #f8fafc;
    color: #475569;
}

.tag-group {
    background: #eff6ff;
    color: #2563eb;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    margin-right: 5px;
}

/* Formulaires Admin */
.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-col {
    flex: 1;
}

.form-label {
    display: block;
    margin-bottom: 5px;
    color: #475569;
    font-weight: 500;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 8px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    box-sizing: border-box;
}

.form-textarea {
    height: 120px;
    resize: vertical;
}

.btn-primary {
    background: #2563eb;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
}

.btn-primary:hover {
    background: #1d4ed8;
}

.btn-danger {
    background: #ef4444;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 0.85em;
}

/* Toggle Switch pour Privé/Public */
.switch-label {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    margin-bottom: 20px;
}

/* --- Boutons Configuration Salles --- */
.tag-code {
    background: #e2e8f0;
    padding: 4px 8px;
    border-radius: 4px;
    font-family: monospace;
    font-weight: bold;
    color: #334155;
}

.btn-action {
    padding: 8px 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 600;
    transition: all 0.2s;
}

/* Bouton pour rendre Privé (Vert) */
.btn-private {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.btn-private:hover {
    background-color: #bbf7d0;
}

/* Bouton pour rendre Public (Gris) */
.btn-public {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
}

.btn-public:hover {
    background-color: #e2e8f0;
    color: #1e293b;
}

/* =============================================
   STYLE HARMONISÉ - GESTION ÉLÈVES & SALLES
   ============================================= */

/* 1. Le Conteneur Principal (Carte Blanche) */
.admin-container {
    background-color: #ffffff;
    border-radius: 12px;
    /* Coins arrondis comme sur l'accueil */
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 30px;
    margin: 30px auto;
    max-width: 1100px;
    /* Largeur max pour la lisibilité */
    font-family: system-ui, -apple-system, sans-serif;
    color: #334155;
    /* Gris texte standard */
}

.admin-container h1 {
    font-size: 1.8rem;
    color: #1e293b;
    /* Titre sombre */
    margin-top: 0;
    margin-bottom: 25px;
    border-bottom: 2px solid #f1f5f9;
    padding-bottom: 15px;
}

/* 2. Les Onglets (Tabs) modernes */
.tabs {
    display: flex;
    gap: 15px;
    border-bottom: 1px solid #e2e8f0;
    margin-bottom: 30px;
    padding-bottom: 0;
}

.tab-btn {
    background: none;
    border: none;
    padding: 12px 20px;
    font-size: 1rem;
    font-weight: 500;
    color: #64748b;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    /* Prépare l'animation */
    transition: all 0.2s ease;
    border-radius: 6px 6px 0 0;
}

.tab-btn:hover {
    color: #2563eb;
    background-color: #f8fafc;
}

.tab-btn.active {
    color: #2563eb;
    /* Bleu EduTools */
    border-bottom-color: #2563eb;
    /* Ligne bleue sous l'onglet actif */
    font-weight: 600;
}

/* 3. Les Tableaux de données (Liste Élèves / Salles) */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    /* Pour garder les coins arrondis */
    border: 1px solid #e2e8f0;
}

.data-table thead {
    background-color: #f8fafc;
    /* Fond gris très clair pour l'en-tête */
}

.data-table th {
    text-align: left;
    padding: 15px;
    font-weight: 600;
    color: #475569;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    border-bottom: 1px solid #e2e8f0;
}

.data-table td {
    padding: 15px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    vertical-align: middle;
}

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

.data-table tr:hover {
    background-color: #f8fafc;
    /* Effet survol ligne */
}

/* Tags (Groupes, Codes) */
.tag-group,
.tag-code {
    display: inline-block;
    background-color: #eff6ff;
    color: #2563eb;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid #dbeafe;
}

/* 4. Les Formulaires (Ajout Élève, Mail) */
.form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.form-col {
    flex: 1;
    /* Les colonnes prennent la même largeur */
}

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.form-input,
.form-select,
.form-textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 0.95rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    background-color: #fff;
    box-sizing: border-box;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

/* 5. Boutons Actions */
.btn-primary {
    background-color: #2563eb;
    color: white;
    font-weight: 600;
    padding: 10px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

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

/* Lien supprimer (rouge discret) */
.btn-danger {
    color: #ef4444;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    padding: 4px 8px;
    border-radius: 4px;
    transition: background 0.2s;
}

.btn-danger:hover {
    background-color: #fef2f2;
}

/* Responsive pour mobile */
@media (max-width: 768px) {
    .form-row {
        flex-direction: column;
        gap: 15px;
    }

    .tabs {
        flex-wrap: wrap;
        /* Les onglets passent à la ligne si besoin */
    }

    .admin-container {
        padding: 15px;
        margin: 15px;
    }
}

/* --- SÉLECTEUR DE GROUPES (Config Salles) --- */
.group-selector {
    background: white;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 10px;
    margin-top: 10px;
    max-height: 150px;
    overflow-y: auto;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.group-checkbox {
    display: flex;
    align-items: center;
    gap: 5px;
    background: #f1f5f9;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.9rem;
    cursor: pointer;
    border: 1px solid #e2e8f0;
}

.group-checkbox:hover {
    background: #e2e8f0;
}

.group-checkbox input {
    accent-color: #2563eb;
    transform: scale(1.1);
}

/* --- SWITCH POUR FORMULAIRES (Correction) --- */
.form-switch-group {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    background: #f8fafc;
    padding: 12px 15px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.switch-label {
    cursor: pointer;
    display: flex;
    /* Aligne le switch et le texte sur la même ligne */
    align-items: center;
    /* Centre verticalement */
    gap: 15px;
    /* Espace entre le bouton et le texte */
    font-weight: 500;
    color: #334155;
    user-select: none;
    width: 100%;
}

/* L'input checkbox caché */
.switch-input {
    display: none;
}

/* Le design du slider (La barre grise) */
.switch-slider {
    display: inline-block;
    /* IMPORTANT : Permet de prendre la largeur */
    position: relative;
    width: 50px;
    /* Largeur fixe */
    min-width: 50px;
    /* Empêche le rétrécissement si le texte est long */
    height: 28px;
    background-color: #cbd5e1;
    border-radius: 30px;
    transition: all 0.3s ease;
    flex-shrink: 0;
    /* Sécurité supplémentaire anti-écrasement */
}

/* La petite boule blanche */
.switch-slider::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 22px;
    height: 22px;
    background-color: white;
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

/* État Coché (Activé) -> Vert */
.switch-input:checked+.switch-slider {
    background-color: #2563eb;
    /* Bleu EduTools */
}

.switch-input:checked+.switch-slider::after {
    transform: translateX(22px);
    /* Déplace la boule vers la droite */
}

/* --- SWITCH POUR TABLEAUX (Compact) --- */
.status-form {
    display: inline-block;
    margin: 0;
    vertical-align: middle;
}

.btn-switch-table {
    position: relative;
    display: inline-flex;
    align-items: center;
    width: 40px;
    /* Plus petit que le formulaire */
    height: 22px;
    border-radius: 20px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s ease;
    padding: 0;
    outline: none;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.btn-switch-table::after {
    content: "";
    position: absolute;
    top: 2px;
    width: 18px;
    height: 18px;
    background-color: white;
    border-radius: 50%;
    transition: transform 0.3s cubic-bezier(0.4, 0.0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* ACTIF (Vert) */
.btn-switch-table.active {
    background-color: #22c55e;
}

.btn-switch-table.active::after {
    transform: translateX(20px);
    left: 0;
}

/* INACTIF (Gris/Rouge) */
.btn-switch-table.inactive {
    background-color: #cbd5e1;
}

/* Gris neutre pour inactif */
.btn-switch-table.inactive::after {
    transform: translateX(2px);
    left: 0;
}