/* ============================================
   SERVICAM - ADMIN DASHBOARD CSS
   ============================================ */

:root {
    --primary: #4F46E5;
    --primary-dark: #004494;
    --success: #25D366;
    --warning: #FF9800;
    --danger: #F44336;
    --gray-50: #f1f3f5;
    --gray-100: #f8f9fa;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-500: #adb5bd;
    --gray-700: #495057;
    --gray-800: #343a40;
    --gray-900: #212529;
    --white: #fff;
    --sidebar-width: 260px;
    --header-height: 70px;
    --bg-body: var(--gray-100);
    --bg-card: var(--white);
    --bg-input: var(--white);
    --bg-sidebar: var(--gray-900);
    --bg-header: var(--white);
    --bg-hover: var(--gray-100);
    --text-primary: var(--gray-900);
    --text-secondary: var(--gray-700);
    --text-muted: var(--gray-500);
    --border-color: var(--gray-200);
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* ============================================
   DARK THEME
   ============================================ */
[data-theme="dark"] {
    --gray-50: #1e1e2e;
    --gray-100: #181825;
    --gray-200: #2a2a3c;
    --gray-300: #3a3a4c;
    --gray-500: #7f849c;
    --gray-700: #bac2de;
    --gray-800: #1e1e2e;
    --gray-900: #cdd6f4;
    --white: #1e1e2e;
    --bg-body: #11111b;
    --bg-card: #1e1e2e;
    --bg-input: #181825;
    --bg-sidebar: #11111b;
    --bg-header: #1e1e2e;
    --bg-hover: #2a2a3c;
    --text-primary: #cdd6f4;
    --text-secondary: #bac2de;
    --text-muted: #7f849c;
    --border-color: #313244;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 15px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] body,
[data-theme="dark"] {
    color-scheme: dark;
}

[data-theme="dark"] .login-card {
    background: var(--bg-card);
}

[data-theme="dark"] .doughnut-center {
    background: var(--bg-card);
}

[data-theme="dark"] .legend-value {
    background: var(--bg-body);
}

[data-theme="dark"] .data-table th {
    background: #181825;
}

[data-theme="dark"] .data-table tr:hover td {
    background: var(--bg-hover);
}

[data-theme="dark"] .modal-content {
    background: var(--bg-card);
}

[data-theme="dark"] .confirm-modal .modal-confirm {
    background: var(--bg-card);
}

[data-theme="dark"] .pending-card-actions {
    background: var(--bg-body);
}

[data-theme="dark"] .btn-reject {
    background: var(--gray-300);
    color: var(--text-primary);
}

[data-theme="dark"] .welcome-banner {
    background: linear-gradient(135deg, #312e81 0%, #1e1b4b 100%);
    color: #fff;
}

[data-theme="dark"] .stat-card.blue .stat-icon { background: rgba(79, 70, 229, 0.2); }
[data-theme="dark"] .stat-card.green .stat-icon { background: rgba(37, 211, 102, 0.2); }
[data-theme="dark"] .stat-card.orange .stat-icon { background: rgba(255, 152, 0, 0.2); }
[data-theme="dark"] .stat-card.red .stat-icon { background: rgba(244, 67, 54, 0.2); }

[data-theme="dark"] .toast {
    background: #313244;
    color: #cdd6f4;
}

[data-theme="dark"] .delete-loading-content {
    background: var(--bg-card);
}

[data-theme="dark"] .code-modify-modal {
    background: var(--bg-card);
}

[data-theme="dark"] .notify-modal {
    background: var(--bg-card);
}

[data-theme="dark"] .notify-modal-header {
    background: linear-gradient(135deg, #1a2e1a 0%, #1e2e1e 100%);
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .notify-modal-header h3 {
    color: var(--text-primary);
}

[data-theme="dark"] .notify-modal-header p {
    color: var(--text-muted);
}

[data-theme="dark"] .notify-subtitle {
    color: var(--text-muted);
}

[data-theme="dark"] .notify-no-social {
    background: var(--bg-body);
    color: var(--text-muted);
    border-top-color: var(--border-color);
}

[data-theme="dark"] .lightbox-content {
    background: rgba(0, 0, 0, 0.9);
}

[data-theme="dark"] img {
    opacity: 0.92;
}

[data-theme="dark"] input,
[data-theme="dark"] select,
[data-theme="dark"] textarea {
    background: var(--bg-input);
    color: var(--text-primary);
    border-color: var(--border-color);
}

[data-theme="dark"] input::placeholder,
[data-theme="dark"] textarea::placeholder {
    color: var(--text-muted);
}

[data-theme="dark"] .settings-card {
    background: var(--bg-card);
    border-color: var(--border-color);
}

[data-theme="dark"] .form-divider {
    border-color: var(--border-color);
}

[data-theme="dark"] .input-readonly {
    background: var(--bg-body);
}

/* Theme Toggle Button */
/* Sélecteur de langue admin */
.admin-lang-toggle {
    display: flex;
    background: var(--gray-100);
    border: 2px solid var(--gray-200);
    border-radius: 50px;
    overflow: hidden;
    gap: 0;
}

.admin-lang-btn {
    border: none;
    background: transparent;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-500);
    cursor: pointer;
    transition: all 0.25s ease;
    letter-spacing: 0.5px;
}

.admin-lang-btn.active {
    background: var(--primary);
    color: #fff;
    border-radius: 50px;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.25);
}

.admin-lang-btn:not(.active):hover {
    color: var(--primary);
}

[data-theme="dark"] .admin-lang-toggle {
    border-color: var(--gray-300);
    background: var(--gray-200);
}

[data-theme="dark"] .admin-lang-btn {
    color: #aaa;
}

[data-theme="dark"] .admin-lang-btn.active {
    background: var(--primary);
    color: #fff;
}

/* Masquer TOUT Google Translate UI dans admin */
.goog-te-banner-frame,
.goog-te-balloon-frame,
#goog-gt-tt,
.goog-te-ftab-link,
.goog-tooltip,
.goog-tooltip:hover,
.goog-te-menu-value,
.goog-te-gadget,
.goog-te-gadget-simple,
.goog-te-gadget-icon,
.goog-te-spinner-pos,
.goog-te-menu-frame,
.goog-te-menu2,
#goog-gt-vt,
[id^="goog-gt-"],
[class*="goog-te-"],
iframe[name="votebox"],
iframe[src*="translate.google"] {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    width: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    z-index: -1 !important;
}

.skiptranslate:not(#google_translate_element_admin) {
    display: none !important;
    height: 0 !important;
    width: 0 !important;
    overflow: hidden !important;
    position: absolute !important;
    left: -9999px !important;
}

body > .skiptranslate:not(#google_translate_element_admin) {
    display: none !important;
    height: 0 !important;
}

.skiptranslate iframe,
iframe.goog-te-banner-frame,
iframe[name="votebox"],
iframe[src*="translate.google"] {
    display: none !important;
    height: 0 !important;
    width: 0 !important;
    border: none !important;
    visibility: hidden !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
}

#google_translate_element_admin {
    display: block !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

html.translated-ltr,
html.translated-rtl {
    margin-top: 0 !important;
}

body {
    top: 0 !important;
    position: static !important;
    margin-top: 0 !important;
}

.goog-text-highlight {
    background: none !important;
    box-shadow: none !important;
}

font[style], font {
    font-family: inherit !important;
    vertical-align: inherit !important;
}

/* Masquer TOUS les iframes enfants directs de body (Google Translate) */
body > iframe {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    width: 0 !important;
    position: absolute !important;
    left: -9999px !important;
    top: -9999px !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Protéger la date/heure contre les modifications de Google Translate */
.notranslate font,
.notranslate font[style],
#currentDate font,
#currentTime font,
#welcomeMessage font {
    font-family: inherit !important;
    vertical-align: inherit !important;
    display: contents !important;
    font-size: inherit !important;
    color: inherit !important;
    line-height: inherit !important;
}

#currentDate,
#currentTime {
    font: inherit;
}

/* Empêcher Google Translate de modifier la zone date/heure */
#currentDate *,
#currentTime * {
    font-family: inherit !important;
    font-size: inherit !important;
    color: inherit !important;
    vertical-align: inherit !important;
    display: contents !important;
}

.theme-toggle {
    width: 40px;
    height: 40px;
    border: 2px solid var(--gray-200);
    border-radius: 50%;
    background: var(--gray-100);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: var(--gray-700);
    position: relative;
}

.theme-toggle:hover {
    border-color: var(--primary);
    background: rgba(79, 70, 229, 0.08);
    color: var(--primary);
    transform: rotate(15deg);
}

.theme-toggle .icon-moon {
    display: none;
}

.theme-toggle .icon-sun {
    display: block;
}

[data-theme="dark"] .theme-toggle {
    border-color: var(--gray-300);
    background: var(--gray-200);
    color: #f9e44c;
}

[data-theme="dark"] .theme-toggle:hover {
    border-color: #f9e44c;
    background: rgba(249, 228, 76, 0.12);
}

[data-theme="dark"] .theme-toggle .icon-moon {
    display: block;
}

[data-theme="dark"] .theme-toggle .icon-sun {
    display: none;
}

.theme-toggle svg {
    width: 18px;
    height: 18px;
}

[data-theme="dark"] .sidebar {
    background: var(--bg-sidebar);
    border-right: 1px solid var(--border-color);
    color: #cdd6f4;
}

[data-theme="dark"] .sidebar-header {
    border-bottom-color: var(--border-color);
}

[data-theme="dark"] .sidebar-header h2 {
    color: #cdd6f4;
}

[data-theme="dark"] .nav-item {
    color: #7f849c;
}

[data-theme="dark"] .nav-item:hover {
    color: #cdd6f4;
}

[data-theme="dark"] .nav-item.active {
    color: #cdd6f4;
}

[data-theme="dark"] .btn-logout {
    color: #7f849c;
    border-color: #7f849c;
}

[data-theme="dark"] .btn-logout:hover {
    color: #fff;
}

[data-theme="dark"] .sidebar-footer {
    border-top-color: var(--border-color);
}

[data-theme="dark"] .admin-avatar {
    color: #fff;
}

[data-theme="dark"] .dashboard-header {
    background: var(--bg-header);
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid var(--border-color);
}

[data-theme="dark"] .card,
[data-theme="dark"] .stat-card,
[data-theme="dark"] .filters-bar,
[data-theme="dark"] .table-container,
[data-theme="dark"] .pending-card {
    box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .kpi-card {
    background: var(--bg-card);
    border-color: var(--border-color);
}

[data-theme="dark"] .stats-chart-card {
    background: var(--bg-card);
    border-color: var(--border-color);
}

[data-theme="dark"] .detailed-card {
    background: var(--bg-card);
    border-color: var(--border-color);
}

[data-theme="dark"] .chart-bar-bg {
    background: var(--gray-200);
}

[data-theme="dark"] .detail-stat {
    background: var(--bg-card);
}

[data-theme="dark"] .reject-modal {
    background: var(--bg-card);
}

[data-theme="dark"] .reject-header {
    background: linear-gradient(135deg, #2e1515 0%, #2e1e1e 100%);
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-body);
    color: var(--text-primary);
    transition: background 0.3s ease, color 0.3s ease;
}

/* ============================================
   LOGIN SCREEN
   ============================================ */
.login-screen {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    padding: 20px;
}

.login-card {
    background: var(--white);
    padding: 50px 40px;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 400px;
}

.login-logo {
    text-align: center;
    margin-bottom: 32px;
}

.login-logo img {
    width: 80px;
    margin-bottom: 16px;
}

.login-logo h1 {
    color: var(--primary);
    font-size: 24px;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--gray-700);
}

.login-form input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s;
}

.login-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.btn-login {
    width: 100%;
    padding: 16px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-login:hover {
    background: var(--primary-dark);
}

.login-hint {
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: var(--gray-500);
}

/* ============================================
   DASHBOARD LAYOUT
   ============================================ */
.dashboard-screen {
    display: flex;
    min-height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--gray-900);
    color: var(--white);
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 100;
    transition: width 0.3s ease, transform 0.3s ease;
    overflow-x: hidden;
}

/* Sidebar Collapsed */
.sidebar.collapsed {
    width: 70px;
}

.sidebar.collapsed .sidebar-header {
    padding: 16px 10px;
}

.sidebar.collapsed .sidebar-logo {
    width: 40px;
    margin-bottom: 0;
}

.sidebar.collapsed .sidebar-title,
.sidebar.collapsed .admin-badge {
    display: none;
}

.sidebar.collapsed .nav-item {
    padding: 14px 0;
    justify-content: center;
    gap: 0;
}

.sidebar.collapsed .nav-item .nav-text {
    display: none;
}

.sidebar.collapsed .nav-item .badge {
    position: absolute;
    top: 5px;
    right: 10px;
    font-size: 10px;
    padding: 2px 5px;
    margin-left: 0;
}

.sidebar.collapsed .nav-icon {
    margin: 0;
}

.sidebar.collapsed .sidebar-footer {
    padding: 10px;
}

.sidebar.collapsed .btn-logout {
    padding: 12px 8px;
    justify-content: center;
}

.sidebar.collapsed .btn-logout svg {
    margin: 0;
}

.sidebar.collapsed .btn-logout span,
.sidebar.collapsed .logout-text {
    display: none;
}

/* Sidebar Toggle Button */
.sidebar-toggle {
    position: absolute;
    bottom: 80px;
    right: -16px;
    width: 32px;
    height: 32px;
    background: var(--primary);
    border: 3px solid var(--gray-900);
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 101;
    padding: 0;
}

.sidebar-toggle:hover {
    background: var(--primary-dark);
    transform: scale(1.15);
}

.sidebar-toggle .icon-expand {
    display: none;
}

.sidebar-toggle .icon-collapse {
    display: block;
}

.sidebar.collapsed .sidebar-toggle .icon-expand {
    display: block;
}

.sidebar.collapsed .sidebar-toggle .icon-collapse {
    display: none;
}

.sidebar-toggle svg {
    width: 18px;
    height: 18px;
}

/* Adjust main content when sidebar is collapsed */
.dashboard-screen.sidebar-collapsed .main-content {
    margin-left: 70px;
}

/* Tooltips pour sidebar collapsed */
.sidebar.collapsed .nav-item {
    position: relative;
}

.sidebar.collapsed .nav-item::after {
    content: attr(data-tooltip);
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    background: var(--gray-800);
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 13px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    margin-left: 10px;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.sidebar.collapsed .nav-item:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Tooltip flèche */
.sidebar.collapsed .nav-item::before {
    content: '';
    position: absolute;
    left: 100%;
    top: 50%;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-right-color: var(--gray-800);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    margin-left: -2px;
}

.sidebar.collapsed .nav-item:hover::before {
    opacity: 1;
    visibility: visible;
}

.sidebar-header {
    padding: 24px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-logo {
    width: 60px;
    margin-bottom: 12px;
}

.sidebar-header h2 {
    font-size: 20px;
    margin-bottom: 8px;
}

.admin-badge {
    background: var(--primary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
}

.sidebar-nav {
    flex: 1;
    padding: 20px 0;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 24px;
    color: var(--gray-500);
    text-decoration: none;
    transition: all 0.3s;
    border-left: 3px solid transparent;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--white);
}

.nav-item.active {
    background: rgba(79, 70, 229, 0.2);
    color: var(--white);
    border-left-color: var(--primary);
}

.nav-icon {
    font-size: 18px;
}

.nav-item .badge {
    margin-left: auto;
    background: var(--danger);
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 12px;
}

.sidebar-footer {
    padding: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-logout {
    width: 100%;
    padding: 12px;
    background: transparent;
    border: 1px solid var(--gray-500);
    color: var(--gray-500);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-logout:hover {
    background: var(--danger);
    border-color: var(--danger);
    color: var(--white);
}

/* Main Content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

/* Header */
.dashboard-header {
    background: var(--white);
    padding: 0 30px;
    height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 50;
}

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

.menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
}

.header-left h1 {
    font-size: 22px;
    color: var(--gray-900);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.admin-name {
    font-weight: 500;
    color: var(--gray-700);
}

.admin-avatar {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

/* Views */
.view {
    display: none;
    padding: 30px;
}

.view.active {
    display: block;
}

/* ============================================
   DASHBOARD VIEW
   ============================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: var(--white);
    padding: 24px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.stat-card .stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
}

.stat-card.blue .stat-icon { background: rgba(79, 70, 229, 0.1); }
.stat-card.green .stat-icon { background: rgba(37, 211, 102, 0.1); }
.stat-card.orange .stat-icon { background: rgba(255, 152, 0, 0.1); }
.stat-card.red .stat-icon { background: rgba(244, 67, 54, 0.1); }

.stat-info {
    display: flex;
    flex-direction: column;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
}

.stat-label {
    font-size: 14px;
    color: var(--gray-500);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background: var(--white);
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.card h3 {
    margin-bottom: 20px;
    font-size: 16px;
    color: var(--gray-700);
}

.chart-container {
    min-height: 200px;
}

/* Doughnut Chart Styles */
.doughnut-chart-container {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 16px 0;
}

.doughnut-chart {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.doughnut-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80px;
    height: 80px;
    background: var(--bg-card);
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.05);
}

.doughnut-total {
    font-size: 24px;
    font-weight: 700;
    color: var(--gray-900);
    line-height: 1;
}

.doughnut-label {
    font-size: 11px;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.chart-legend {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chart-legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 10px;
    background: var(--gray-50);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.chart-legend-item:hover {
    background: var(--gray-100);
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    flex-shrink: 0;
}

.legend-label {
    flex: 1;
    font-size: 13px;
    color: var(--gray-700);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.legend-value {
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-900);
    background: var(--bg-body);
    padding: 2px 8px;
    border-radius: 10px;
    min-width: 28px;
    text-align: center;
}

/* Legacy bar chart styles (kept for compatibility) */
.chart-bar {
    display: flex;
    align-items: center;
    margin-bottom: 12px;
}

.chart-label {
    width: 120px;
    font-size: 13px;
    color: var(--gray-700);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chart-bar-bg {
    flex: 1;
    height: 24px;
    background: var(--gray-200);
    border-radius: 4px;
    overflow: hidden;
    margin: 0 10px;
}

.chart-bar-fill {
    height: 100%;
    background: var(--primary);
    border-radius: 4px;
    transition: width 0.5s ease;
}

.chart-value {
    width: 30px;
    text-align: right;
    font-weight: 600;
    font-size: 14px;
}

/* Responsive doughnut charts */
@media (max-width: 576px) {
    .doughnut-chart-container {
        flex-direction: column;
        align-items: center;
    }
    
    .doughnut-chart {
        width: 120px;
        height: 120px;
    }
    
    .doughnut-center {
        width: 65px;
        height: 65px;
    }
    
    .doughnut-total {
        font-size: 20px;
    }
    
    .chart-legend {
        width: 100%;
    }
}

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

.recent-item {
    display: flex;
    align-items: center;
    padding: 12px;
    background: var(--gray-100);
    border-radius: 8px;
    gap: 12px;
}

.recent-avatar {
    width: 40px;
    height: 40px;
    background: var(--primary);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.recent-info {
    flex: 1;
}

.recent-name {
    font-weight: 600;
    color: var(--gray-900);
}

.recent-metier {
    font-size: 13px;
    color: var(--gray-500);
}

.recent-date {
    font-size: 12px;
    color: var(--gray-500);
}

/* ============================================
   PROFESSIONNELS VIEW
   ============================================ */
.filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 20px;
    background: var(--white);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.search-box {
    position: relative;
    flex: 1;
    min-width: 250px;
}

.search-box input {
    width: 100%;
    padding: 12px 16px 12px 40px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
}

.search-box input:focus {
    outline: none;
    border-color: var(--primary);
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
}

.filters-bar select {
    padding: 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    background: var(--white);
    font-size: 14px;
    cursor: pointer;
    min-width: 150px;
}

.filters-bar select:focus {
    outline: none;
    border-color: var(--primary);
}

.results-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    padding: 0 4px;
}

#resultsCount {
    font-weight: 500;
    color: var(--gray-700);
}

.sort-options {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sort-options label {
    font-size: 14px;
    color: var(--gray-500);
}

.sort-options select {
    padding: 8px 12px;
    border: 1px solid var(--gray-300);
    border-radius: 6px;
    background: var(--white);
    font-size: 14px;
}

.table-container {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th,
.data-table td {
    padding: 16px;
    text-align: left;
    border-bottom: 1px solid var(--gray-200);
}

.data-table th {
    background: var(--gray-100);
    font-weight: 600;
    color: var(--gray-700);
    font-size: 13px;
    text-transform: uppercase;
}

.data-table tr:hover {
    background: var(--gray-100);
}

.status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-badge.actif {
    background: rgba(37, 211, 102, 0.1);
    color: var(--success);
}

.status-badge.en_attente {
    background: rgba(255, 152, 0, 0.1);
    color: var(--warning);
}

.status-badge.desactive {
    background: rgba(244, 67, 54, 0.1);
    color: var(--danger);
}

.actions-cell {
    display: flex;
    gap: 8px;
}

.btn-action {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-600);
    padding: 0;
}

.btn-action svg {
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    transition: transform 0.2s ease;
    display: block;
}

.btn-action:hover svg {
    transform: scale(1.15);
}

/* Voir le profil */
.btn-view { 
    background: rgba(79, 70, 229, 0.1); 
    color: var(--primary);
}
.btn-view:hover { 
    background: var(--primary); 
    color: var(--white); 
}

/* Modifier */
.btn-edit { 
    background: rgba(255, 152, 0, 0.1); 
    color: #FF9800;
}
.btn-edit:hover { 
    background: #FF9800; 
    color: var(--white); 
}

/* Activer (toggle on) */
.btn-toggle-on { 
    background: rgba(37, 211, 102, 0.15); 
    color: #25D366;
}
.btn-toggle-on:hover { 
    background: #25D366; 
    color: var(--white); 
}

/* Désactiver (toggle off) */
.btn-toggle-off { 
    background: rgba(156, 39, 176, 0.1); 
    color: #9C27B0;
}
.btn-toggle-off:hover { 
    background: #9C27B0; 
    color: var(--white); 
}

/* Legacy toggle class */
.btn-toggle { 
    background: rgba(37, 211, 102, 0.1); 
    color: #25D366;
}
.btn-toggle:hover { 
    background: var(--success); 
    color: var(--white); 
}

/* Supprimer définitivement */
.btn-delete { 
    background: rgba(244, 67, 54, 0.1); 
    color: #F44336;
}
.btn-delete:hover { 
    background: #F44336; 
    color: var(--white); 
}

/* ============================================
   EN ATTENTE VIEW
   ============================================ */
.pending-header {
    margin-bottom: 24px;
}

.pending-header h2 {
    color: var(--gray-900);
    margin-bottom: 8px;
}

.pending-header p {
    color: var(--gray-500);
}

.pending-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

.pending-card {
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.pending-card-header {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    border-bottom: 1px solid var(--gray-200);
}

.pending-avatar {
    width: 60px;
    height: 60px;
    background: var(--gray-200);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    overflow: hidden;
}

.pending-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pending-avatar .avatar-initiales {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #4F46E5 0%, #004494 100%);
    color: white;
    font-size: 22px;
    font-weight: 700;
    text-transform: uppercase;
}

.pending-info h4 {
    font-size: 16px;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.pending-info p {
    font-size: 14px;
    color: var(--primary);
    font-weight: 500;
}

.pending-info span {
    font-size: 12px;
    color: var(--gray-500);
}

.pending-card-body {
    padding: 20px;
}

.pending-detail {
    display: flex;
    margin-bottom: 10px;
    font-size: 14px;
}

.pending-detail strong {
    min-width: 100px;
    color: var(--gray-500);
}

.pending-card-actions {
    padding: 16px 20px;
    background: var(--gray-100);
    display: flex;
    gap: 12px;
}

.btn-view-profile,
.btn-approve,
.btn-reject {
    flex: 1;
    padding: 12px 16px;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-view-profile svg,
.btn-approve svg,
.btn-reject svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.btn-view-profile {
    background: var(--primary);
    color: white;
}

.btn-view-profile:hover {
    background: var(--primary-dark);
    color: white;
}

.btn-approve {
    background: var(--success);
    color: var(--white);
}

.btn-approve:hover {
    background: #20b85a;
    transform: translateY(-1px);
}

.btn-reject {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-reject:hover {
    background: var(--danger);
    color: var(--white);
    transform: translateY(-1px);
}

/* Icons in pending details */
.pending-detail strong {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pending-detail strong svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    opacity: 0.7;
}

/* ============================================
   MODALS
   ============================================ */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--white);
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalSlide 0.3s ease;
}

.modal-large {
    max-width: 700px;
}

/* Modal de Confirmation Personnalisé */
/* ── MODAL DE CONFIRMATION REDESIGNÉ ── */
.confirm-modal .modal-confirm {
    max-width: 480px;
    padding: 0;
    text-align: left;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 24px 64px rgba(0,0,0,0.18);
}



/* Zone icone + titre */
.confirm-header-zone {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 28px 28px 0;
}

.confirm-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.confirm-icon svg { width: 26px; height: 26px; }

.confirm-icon.danger  { background: #fef2f2; color: #ef4444; }
.confirm-icon.warning { background: #fffbeb; color: #f59e0b; }
.confirm-icon.success { background: #f0fdf4; color: #22c55e; }
.confirm-icon.info    { background: #eff6ff; color: #3b82f6; }

.confirm-modal h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--gray-900);
    margin: 0;
    line-height: 1.3;
}

/* Corps du message */
.confirm-body-zone {
    padding: 16px 28px 0;
}

.confirm-modal p {
    font-size: 14.5px;
    color: var(--gray-600);
    line-height: 1.65;
    margin: 0;
}

.confirm-details {
    background: var(--gray-50);
    border-radius: 10px;
    padding: 14px 16px;
    margin-top: 14px;
    font-size: 13.5px;
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
    line-height: 1.6;
}

.confirm-details:empty { display: none; }
.confirm-details ul { margin: 0; padding-left: 18px; }
.confirm-details li { margin-bottom: 5px; }
.confirm-details li:last-child { margin-bottom: 0; }

/* Zone boutons */
.confirm-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    padding: 24px 28px 28px;
    margin-top: 24px;
}

.btn-confirm-cancel,
.btn-confirm-ok {
    padding: 11px 22px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.18s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 110px;
}

.btn-confirm-cancel {
    background: var(--gray-100);
    color: var(--gray-700);
    border: 1px solid var(--gray-200);
}
.btn-confirm-cancel:hover { background: var(--gray-200); }

.btn-confirm-ok {
    background: var(--primary);
    color: #fff;
    box-shadow: 0 2px 8px rgba(37,99,235,0.25);
}
.btn-confirm-ok:hover { filter: brightness(1.08); transform: translateY(-1px); }

.btn-confirm-ok.danger  { background: #ef4444; box-shadow: 0 2px 8px rgba(239,68,68,0.3); }
.btn-confirm-ok.danger:hover { background: #dc2626; }
.btn-confirm-ok.success { background: #22c55e; box-shadow: 0 2px 8px rgba(34,197,94,0.3); }
.btn-confirm-ok.success:hover { background: #16a34a; }

.btn-confirm-ok svg,
.btn-confirm-cancel svg { width: 16px; height: 16px; }

@keyframes iconPop {
    0% { transform: scale(0.8); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

/* ============================================
   LIGHTBOX POUR IMAGES
   ============================================ */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.lightbox.active {
    display: flex;
}

.lightbox-content {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    animation: lightboxZoom 0.3s ease;
}

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

.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: absolute;
    top: -50px;
    right: 0;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.lightbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

.lightbox-caption {
    text-align: center;
    color: white;
    padding: 16px 0;
    font-size: 14px;
    opacity: 0.9;
}

/* Avatar cliquable */
.profile-avatar.clickable {
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.profile-avatar.clickable:hover img {
    transform: scale(1.05);
}

.profile-avatar.clickable img {
    transition: transform 0.3s ease;
}

.avatar-zoom-icon {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 28px;
    height: 28px;
    background: rgba(0, 0, 0, 0.6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.profile-avatar.clickable:hover .avatar-zoom-icon {
    opacity: 1;
}

/* Réalisations cliquables */
.realisation-item {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    border-radius: 8px;
}

.realisation-item img {
    transition: transform 0.3s ease;
}

.realisation-item:hover img {
    transform: scale(1.05);
}

.realisation-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    color: white;
}

.realisation-item:hover .realisation-overlay {
    opacity: 1;
}

@keyframes modalSlide {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--gray-200);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 18px;
    color: var(--gray-900);
}

.modal-close {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--gray-100);
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s;
}

.modal-close:hover {
    background: var(--danger);
    color: var(--white);
}

.modal-body {
    padding: 24px;
}

.modal-body .form-group {
    margin-bottom: 16px;
}

.modal-body label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
    color: var(--gray-700);
}

.modal-body input,
.modal-body select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
}

.modal-body input:focus,
.modal-body select:focus {
    outline: none;
    border-color: var(--primary);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 24px;
}

.btn-cancel,
.btn-save {
    flex: 1;
    padding: 14px;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.btn-cancel {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-save {
    background: var(--primary);
    color: var(--white);
}

/* View Modal */
.profile-header {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--gray-200);
    margin-bottom: 20px;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    background: var(--gray-200);
    border-radius: 50%;
    overflow: hidden;
}

.profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-avatar.initiales-avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, #3730A3 100%);
}

.avatar-initiales-large {
    font-size: 28px;
    font-weight: 700;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

.profile-info h3 {
    font-size: 20px;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.profile-info p {
    color: var(--primary);
    font-weight: 500;
}

.profile-section {
    margin-bottom: 20px;
}

.profile-section h4 {
    font-size: 14px;
    color: var(--gray-500);
    text-transform: uppercase;
    margin-bottom: 12px;
}

.profile-row {
    display: flex;
    padding: 8px 0;
    border-bottom: 1px solid var(--gray-100);
}

.profile-row strong {
    min-width: 150px;
    color: var(--gray-500);
    font-weight: 500;
}

.profile-row span {
    color: var(--gray-900);
}

/* Social Links Grid */
.social-links-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 8px 0;
}

.social-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.social-link-btn svg {
    flex-shrink: 0;
}

.social-link-btn.facebook {
    background: #e7f3ff;
    color: #1877f2;
}

.social-link-btn.facebook:hover {
    background: #1877f2;
    color: white;
}

.social-link-btn.instagram {
    background: linear-gradient(135deg, #fdf2f8 0%, #fce7f3 100%);
    color: #e4405f;
}

.social-link-btn.instagram:hover {
    background: linear-gradient(135deg, #f56040, #e4405f, #833ab4);
    color: white;
}

.social-link-btn.linkedin {
    background: #e8f4f8;
    color: #0077b5;
}

.social-link-btn.linkedin:hover {
    background: #0077b5;
    color: white;
}

/* Réalisations Grid */
.realisations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 12px;
    margin-top: 12px;
}

.realisation-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    background: var(--gray-200);
}

.realisation-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.realisation-item:hover img {
    transform: scale(1.05);
}

.realisation-desc {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    font-size: 11px;
    padding: 20px 8px 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Toast */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    padding: 16px 24px;
    background: var(--gray-900);
    color: var(--white);
    border-radius: 8px;
    z-index: 99999;
    transform: translateX(150%);
    transition: transform 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    font-weight: 500;
    max-width: 400px;
}

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

.toast.success { 
    background: var(--success); 
}

.toast.error { 
    background: var(--danger);
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* ============================================
   NOTIFY PRO MODAL
   ============================================ */
.notify-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.notify-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.notify-modal {
    background: var(--bg-card);
    border-radius: 16px;
    width: 90%;
    max-width: 360px;
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.notify-modal-overlay.active .notify-modal {
    transform: scale(1) translateY(0);
}

.notify-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 30px;
    height: 30px;
    border: none;
    background: #f1f3f4;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5f6368;
    transition: all 0.2s ease;
    z-index: 1;
}

.notify-modal-close:hover {
    background: #e8eaed;
    color: #202124;
}

.notify-modal-header {
    text-align: center;
    padding: 20px 18px 16px;
    background: linear-gradient(135deg, #f8fff8 0%, #e8f5e9 100%);
    border-bottom: 1px solid #e8f5e9;
}

.notify-modal-header svg {
    margin-bottom: 10px;
    width: 40px;
    height: 40px;
}

.notify-modal-header h3 {
    font-size: 17px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.notify-modal-header p {
    color: #5f6368;
    font-size: 13px;
}

.notify-modal-header strong {
    color: #1a1a1a;
}

.notify-modal-body {
    padding: 16px 18px;
}

.notify-subtitle {
    font-size: 12px;
    color: #5f6368;
    margin-bottom: 10px;
    text-align: center;
}

.notify-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.notify-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 10px;
    text-decoration: none;
    transition: all 0.2s ease;
    border: 2px solid transparent;
}

.notify-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.12);
}

.notify-btn svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.notify-btn-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.notify-btn-label {
    font-weight: 600;
    font-size: 13px;
}

.notify-btn-number {
    font-size: 11px;
    opacity: 0.8;
}

/* WhatsApp */
.notify-whatsapp {
    background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
    color: white;
}

.notify-whatsapp:hover {
    background: linear-gradient(135deg, #22c55e 0%, #0f766e 100%);
}

/* Call */
.notify-call {
    background: linear-gradient(135deg, #4F46E5 0%, #3730A3 100%);
    color: white;
}

.notify-call:hover {
    background: linear-gradient(135deg, #0066cc 0%, #004d99 100%);
}

/* Email */
.notify-email {
    background: linear-gradient(135deg, #EA4335 0%, #c5221f 100%);
    color: white;
}

.notify-email:hover {
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
}

.notify-modal-footer {
    padding: 0 18px 16px;
    text-align: center;
}

.notify-skip-btn {
    background: none;
    border: none;
    color: #5f6368;
    font-size: 12px;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.notify-skip-btn:hover {
    background: #f1f3f4;
    color: #202124;
}

/* Section réseaux sociaux */
.notify-section-title {
    font-size: 12px;
    color: #5f6368;
    margin: 12px 0 8px;
    text-align: center;
    padding-top: 12px;
    border-top: 1px solid #e8eaed;
}

.notify-social-grid {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.notify-social-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 7px 12px;
    border-radius: 8px;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
    color: white;
}

.notify-social-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.notify-facebook {
    background: linear-gradient(135deg, #1877F2 0%, #0d5fc7 100%);
}

.notify-instagram {
    background: linear-gradient(135deg, #E4405F 0%, #C13584 50%, #833AB4 100%);
}

.notify-linkedin {
    background: linear-gradient(135deg, #0A66C2 0%, #004182 100%);
}

.notify-no-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    margin-top: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    color: #6c757d;
    font-size: 12px;
    border-top: 1px solid #e8eaed;
}

.notify-no-social svg {
    opacity: 0.6;
}

/* ============================================
   DELETE LOADING MODAL
   ============================================ */
.delete-loading-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 100000;
    justify-content: center;
    align-items: center;
}

.delete-loading-modal.active {
    display: flex;
}

.delete-loading-content {
    background: var(--bg-card);
    border-radius: 20px;
    padding: 40px 50px;
    text-align: center;
    max-width: 420px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: deleteModalSlideIn 0.3s ease;
}

@keyframes deleteModalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.delete-loading-spinner {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
}

.delete-spinner-svg {
    width: 100%;
    height: 100%;
    animation: deleteSpinnerRotate 1.5s linear infinite;
}

.delete-spinner-svg circle {
    stroke: var(--danger);
    stroke-linecap: round;
    stroke-dasharray: 90, 150;
    stroke-dashoffset: 0;
    animation: deleteSpinnerDash 1.5s ease-in-out infinite;
}

@keyframes deleteSpinnerRotate {
    100% {
        transform: rotate(360deg);
    }
}

@keyframes deleteSpinnerDash {
    0% {
        stroke-dasharray: 1, 150;
        stroke-dashoffset: 0;
    }
    50% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -35;
    }
    100% {
        stroke-dasharray: 90, 150;
        stroke-dashoffset: -124;
    }
}

.delete-loading-content h3 {
    font-size: 22px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.delete-loading-content p {
    color: var(--gray-600);
    font-size: 15px;
    margin-bottom: 24px;
}

.delete-loading-steps {
    display: flex;
    flex-direction: column;
    gap: 12px;
    text-align: left;
}

.delete-loading-step {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--gray-100);
    border-radius: 10px;
    color: var(--gray-500);
    font-size: 14px;
    transition: all 0.3s ease;
}

.delete-loading-step.active {
    background: #fff3f3;
    color: var(--danger);
}

.delete-loading-step.completed {
    background: #f0fff4;
    color: var(--success);
}

.delete-step-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--gray-300);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.delete-step-icon svg {
    opacity: 0;
    transform: scale(0);
    transition: all 0.3s ease;
}

.delete-loading-step.active .delete-step-icon {
    background: var(--danger);
    animation: deletePulse 1s infinite;
}

.delete-loading-step.completed .delete-step-icon {
    background: var(--success);
}

.delete-loading-step.completed .delete-step-icon svg {
    opacity: 1;
    transform: scale(1);
    stroke: white;
}

@keyframes deletePulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(244, 67, 54, 0.4);
    }
    50% {
        box-shadow: 0 0 0 10px rgba(244, 67, 54, 0);
    }
}

/* ============================================
   REJECT NOTIFY MODAL
   ============================================ */
.reject-modal {
    max-width: 480px;
}

.reject-header {
    background: linear-gradient(135deg, #fff5f5 0%, #fee2e2 100%);
    border-bottom: 1px solid #fecaca;
}

.reject-motif-section {
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid #e8eaed;
}

.reject-motif-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 10px;
}

.reject-motif-textarea {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 80px;
    transition: all 0.2s ease;
    background: #f9fafb;
}

.reject-motif-textarea:focus {
    outline: none;
    border-color: #dc3545;
    background: var(--bg-card);
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.1);
}

.reject-motif-suggestions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 12px;
}

.motif-suggestion {
    padding: 6px 12px;
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    font-size: 12px;
    color: #4b5563;
    cursor: pointer;
    transition: all 0.2s ease;
}

.motif-suggestion:hover {
    background: #fee2e2;
    border-color: #fca5a5;
    color: #dc2626;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 992px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.open {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .menu-btn {
        display: block;
    }
}

@media (max-width: 768px) {
    .filters-bar {
        flex-direction: column;
    }
    
    .filters-bar select {
        width: 100%;
    }
    
    .data-table {
        font-size: 13px;
    }
    
    .data-table th,
    .data-table td {
        padding: 12px 8px;
    }
    
    .pending-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .view {
        padding: 20px 15px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-header {
        padding: 0 15px;
    }
    
    .header-left h1 {
        font-size: 18px;
    }
    
    .supabase-status {
        display: none;
    }
}


/* Textarea dans modal */
.modal-body textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 60px;
}

.modal-body textarea:focus {
    outline: none;
    border-color: var(--primary);
}

/* Amélioration boutons d'action */
.btn-save:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* ============================================
   WELCOME BANNER
   ============================================ */
.welcome-banner {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 16px;
    padding: 28px 32px;
    margin-bottom: 24px;
    color: var(--white);
}

.welcome-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 40px;
}

.welcome-text {
    flex: 1;
}

.welcome-text h2 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 6px;
    color: #fff;
}

.welcome-text p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
}

.welcome-date {
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex-shrink: 0;
    min-width: 200px;
}

.welcome-date span:first-child {
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.welcome-date span:last-child {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
}

/* ============================================
   DETAILED STATS
   ============================================ */
.detailed-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.detail-stat {
    background: var(--white);
    padding: 16px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 14px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.detail-stat-icon {
    width: 44px;
    height: 44px;
    background: rgba(79, 70, 229, 0.08);
    color: var(--primary);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.detail-stat-info {
    display: flex;
    flex-direction: column;
}

.detail-stat-number {
    font-size: 20px;
    font-weight: 700;
    color: var(--gray-900);
}

.detail-stat-label {
    font-size: 12px;
    color: var(--gray-500);
}

/* ============================================
   CHARTS GRID
   ============================================ */
.charts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 24px;
}

.chart-card {
    min-height: 320px;
}

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

.card-header h3 {
    margin: 0;
}

.chart-badge {
    background: var(--gray-100);
    color: var(--gray-600);
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.view-all-link {
    color: var(--primary);
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
}

.view-all-link:hover {
    text-decoration: underline;
}

/* ============================================
   DASHBOARD BOTTOM
   ============================================ */
.dashboard-bottom {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 24px;
}

.recent-card,
.regions-card {
    min-height: 300px;
}

/* ============================================
   SETTINGS VIEW
   ============================================ */
.settings-wrapper {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
}

.settings-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.settings-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.settings-card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.settings-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: var(--gray-100);
    border-bottom: 1px solid var(--gray-200);
}

.settings-card-icon {
    width: 48px;
    height: 48px;
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.settings-card-icon.warning {
    background: rgba(255, 152, 0, 0.1);
    color: var(--warning);
}

.settings-card-icon.info {
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary);
}

.settings-card-header h3 {
    font-size: 16px;
    color: var(--gray-900);
    margin-bottom: 4px;
}

.settings-card-header p {
    font-size: 13px;
    color: var(--gray-500);
}

.settings-card-header.compact {
    padding: 16px 20px;
}

.settings-card-header.compact .settings-card-icon {
    width: 40px;
    height: 40px;
}

.settings-card-icon.success {
    background: rgba(37, 211, 102, 0.1);
    color: var(--success);
}

.settings-form {
    padding: 24px;
}

.settings-form .form-group {
    margin-bottom: 16px;
}

.settings-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    font-size: 14px;
    color: var(--gray-700);
}

.settings-form input {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid var(--gray-200);
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s;
}

.settings-form input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.settings-form input.input-readonly {
    background: var(--gray-100);
    color: var(--gray-500);
    cursor: not-allowed;
}

.form-divider {
    height: 1px;
    background: var(--gray-200);
    margin: 20px 0;
}

.form-actions {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--gray-100);
}

.btn-primary,
.btn-warning {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

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

.btn-primary:hover {
    background: var(--primary-dark);
}

.btn-warning {
    background: var(--warning);
    color: var(--white);
}

.btn-warning:hover {
    background: #e68900;
}

.btn-primary:disabled,
.btn-warning:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Session info */
.session-info {
    padding: 20px 24px;
}

.session-row {
    display: flex;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid var(--gray-100);
}

.session-row:last-child {
    border-bottom: none;
}

.session-label {
    font-size: 14px;
    color: var(--gray-500);
}

.session-value {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-900);
}

/* Spin animation */
@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.spin {
    animation: spin 1s linear infinite;
}

/* Form section title */
.form-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 20px 0 15px 0;
    color: var(--primary);
    font-size: 14px;
    font-weight: 600;
}

.form-section-title:first-child {
    margin-top: 0;
}

.form-section-title svg {
    flex-shrink: 0;
}

/* Card title with icon */
.card h3 {
    display: flex;
    align-items: center;
    gap: 10px;
}

.card h3 svg {
    color: var(--primary);
}

/* Sidebar nav icon SVG */
.nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
}

.nav-icon svg {
    width: 20px;
    height: 20px;
}

/* Logout button with icon */
.btn-logout {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-logout svg {
    width: 18px;
    height: 18px;
}

/* Menu button */
.menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--gray-700);
}

.menu-btn svg {
    width: 24px;
    height: 24px;
}

/* Stat icon with SVG */
.stat-card .stat-icon svg {
    stroke: currentColor;
}

.stat-card.blue .stat-icon svg { color: var(--primary); }
.stat-card.green .stat-icon svg { color: var(--success); }
.stat-card.orange .stat-icon svg { color: var(--warning); }
.stat-card.red .stat-icon svg { color: var(--danger); }

/* Search icon */
.search-icon {
    display: flex;
    align-items: center;
    color: var(--gray-500);
}

/* Admin avatar */
.admin-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    background: var(--white);
    border: 2px solid var(--gray-200);
}

.admin-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    padding: 4px;
}

.admin-avatar svg {
    width: 20px;
    height: 20px;
}

/* Button save with icon */
.btn-save {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-save svg {
    width: 16px;
    height: 16px;
}

@media (max-width: 992px) {
    .menu-btn {
        display: flex;
    }
}

/* ============================================
   NOTIFICATIONS SETTINGS
   ============================================ */
.notifications-settings {
    padding: 8px 20px 20px;
}

.notification-option {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-bottom: 1px solid var(--gray-100);
}

.notification-option:last-child {
    border-bottom: none;
}

.notification-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.notification-title {
    font-size: 14px;
    font-weight: 500;
    color: var(--gray-900);
}

.notification-desc {
    font-size: 12px;
    color: var(--gray-500);
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--gray-300);
    transition: 0.3s;
    border-radius: 26px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-switch input:checked + .toggle-slider {
    background-color: var(--primary);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(22px);
}

/* Toggle Large */
.toggle-switch.toggle-large {
    width: 56px;
    height: 30px;
}

.toggle-switch.toggle-large .toggle-slider:before {
    height: 24px;
    width: 24px;
}

.toggle-switch.toggle-large input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

/* Inscription Status */
.inscription-toggle {
    padding-bottom: 12px !important;
}

.inscription-status {
    padding: 0 0 16px 0;
    text-align: center;
}

.status-badge-large {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
}

.status-badge-large.open {
    background: rgba(37, 211, 102, 0.15);
    color: var(--success);
}

.status-badge-large.closed {
    background: rgba(244, 67, 54, 0.15);
    color: var(--danger);
}

.settings-card-icon.closed {
    background: rgba(244, 67, 54, 0.1);
    color: var(--danger);
}

/* Code d'accès contact */
.settings-card-icon.security {
    background: rgba(102, 126, 234, 0.1);
    color: #667eea;
}

.code-acces-settings {
    padding: 16px 0;
}

.code-acces-form {
    padding: 0 16px;
}

.code-acces-input-group {
    margin-bottom: 12px;
}

.code-acces-input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
}

.code-acces-row {
    display: flex;
    gap: 12px;
    align-items: center;
}

.code-input-wrapper {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
}

.code-input-wrapper input {
    width: 100%;
    padding: 12px 48px 12px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    letter-spacing: 2px;
    text-align: center;
    transition: all 0.2s ease;
}

.code-input-wrapper input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.btn-toggle-visibility {
    position: absolute;
    right: 8px;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-500);
    border-radius: 8px;
    transition: all 0.2s ease;
}

.btn-toggle-visibility:hover {
    background: var(--gray-100);
    color: var(--gray-700);
}

/* Password Prompt Modal */
.password-prompt-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    backdrop-filter: blur(4px);
}

.password-prompt-overlay.active {
    opacity: 1;
    visibility: visible;
}

.password-prompt-modal {
    background: var(--bg-card);
    border-radius: 16px;
    width: 90%;
    max-width: 400px;
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

.password-prompt-overlay.active .password-prompt-modal {
    transform: scale(1) translateY(0);
}

.password-prompt-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border: none;
    background: #f1f3f4;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #5f6368;
    transition: all 0.2s ease;
    z-index: 1;
}

.password-prompt-close:hover {
    background: #e8eaed;
    color: #202124;
}

.password-prompt-header {
    text-align: center;
    padding: 32px 24px 20px;
    background: linear-gradient(135deg, #f8f9ff 0%, #eef1ff 100%);
}

.password-prompt-header svg {
    margin-bottom: 12px;
}

.password-prompt-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 8px;
}

.password-prompt-header p {
    color: #5f6368;
    font-size: 14px;
    line-height: 1.5;
}

.password-prompt-body {
    padding: 24px;
}

.password-prompt-input-group {
    margin-bottom: 0;
}

.password-prompt-input-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
}

.password-prompt-input-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.2s ease;
}

.password-prompt-input-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.password-error {
    color: #F44336;
    font-size: 13px;
    margin-top: 8px;
    margin-bottom: 0;
}

.password-prompt-footer {
    display: flex;
    gap: 12px;
    padding: 0 24px 24px;
    justify-content: flex-end;
}

.btn-cancel-prompt,
.btn-verify-prompt {
    padding: 12px 24px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.btn-cancel-prompt {
    background: var(--gray-100);
    color: var(--gray-700);
}

.btn-cancel-prompt:hover {
    background: var(--gray-200);
}

.btn-verify-prompt {
    background: var(--primary);
    color: white;
}

.btn-verify-prompt:hover {
    background: var(--primary-dark);
}

.btn-verify-prompt.save-mode {
    background: var(--success);
}

.btn-verify-prompt.save-mode:hover {
    background: #1e9e52;
}

.password-prompt-header.save-mode {
    background: linear-gradient(135deg, #f0fff4 0%, #dcfce7 100%);
}

.btn-save-code {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn-save-code:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-save-code svg {
    flex-shrink: 0;
}

.code-acces-hint {
    font-size: 12px;
    color: var(--gray-500);
    margin: 0;
    padding: 0 4px;
}

/* Code Accès Display */
.code-acces-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 16px 20px;
    background: var(--gray-50);
    border-radius: 12px;
    margin-bottom: 12px;
}

.code-current {
    display: flex;
    align-items: center;
    gap: 12px;
}

.code-label {
    font-size: 14px;
    color: var(--gray-600);
    font-weight: 500;
}

.code-value {
    font-size: 18px;
    font-weight: 700;
    color: var(--gray-800);
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
}

.btn-modify-code {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-modify-code:hover {
    background: var(--primary-dark);
}

.btn-modify-code svg {
    flex-shrink: 0;
}

/* Modal Modifier Code */
.code-modify-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.code-modify-overlay.active {
    opacity: 1;
    visibility: visible;
}

.code-modify-modal {
    background: var(--bg-card);
    border-radius: 16px;
    width: 90%;
    max-width: 420px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: all 0.3s ease;
}

.code-modify-overlay.active .code-modify-modal {
    transform: scale(1) translateY(0);
}

.code-modify-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-500);
    transition: all 0.2s ease;
}

.code-modify-close:hover {
    background: var(--gray-100);
    color: var(--gray-700);
}

.code-modify-header {
    text-align: center;
    padding: 32px 24px 20px;
    background: linear-gradient(135deg, #f0f7ff 0%, #e0eeff 100%);
    border-radius: 16px 16px 0 0;
}

.code-modify-header svg {
    margin-bottom: 12px;
}

.code-modify-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
}

.code-modify-body {
    padding: 24px;
}

.code-modify-group {
    margin-bottom: 20px;
}

.code-modify-group:last-child {
    margin-bottom: 0;
}

.code-modify-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 8px;
}

.code-modify-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid var(--gray-200);
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.2s ease;
}

.code-modify-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.code-modify-error {
    color: #dc3545;
    font-size: 13px;
    margin-top: 8px;
    margin-bottom: 0;
}

.code-modify-footer {
    display: flex;
    gap: 12px;
    padding: 0 24px 24px;
}

.btn-cancel-modify {
    flex: 1;
    padding: 14px;
    border: 2px solid var(--gray-200);
    background: var(--bg-card);
    color: var(--gray-700);
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-cancel-modify:hover {
    background: var(--gray-100);
}

.btn-confirm-modify {
    flex: 1;
    padding: 14px;
    border: none;
    background: var(--primary);
    color: white;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-confirm-modify:hover {
    background: var(--primary-dark);
}

.btn-confirm-modify:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Quick Stats */
.quick-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 16px 20px;
}

.quick-stat {
    text-align: center;
    padding: 12px 8px;
    background: var(--gray-100);
    border-radius: 10px;
}

.quick-stat-value {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: var(--primary);
}

.quick-stat-label {
    display: block;
    font-size: 11px;
    color: var(--gray-500);
    margin-top: 2px;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1200px) {
    .settings-wrapper {
        grid-template-columns: 1fr;
    }
    
    .settings-sidebar {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 992px) {
    .detailed-stats {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .charts-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-bottom {
        grid-template-columns: 1fr;
    }
    
    .welcome-content {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
    
    .welcome-date {
        text-align: center;
    }
}

@media (max-width: 768px) {
    .settings-wrapper {
        grid-template-columns: 1fr;
    }
    
    .settings-sidebar {
        grid-template-columns: 1fr;
    }
    
    .settings-card-header {
        flex-direction: column;
        text-align: center;
    }
    
    .session-row {
        flex-direction: column;
        gap: 4px;
    }
    
    .detailed-stats {
        grid-template-columns: 1fr 1fr;
    }
    
    .welcome-banner {
        padding: 20px;
    }
    
    .welcome-text h2 {
        font-size: 20px;
    }
    
    .quick-stats {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 480px) {
    .detailed-stats {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   STATISTIQUES PAGE
   ============================================ */
.stats-page-header {
    margin-bottom: 32px;
}

.stats-page-header h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 28px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 8px;
}

.stats-page-header h2 svg {
    color: var(--primary);
}

.stats-page-header p {
    color: var(--gray-500);
    font-size: 15px;
}

/* KPI Cards */
.stats-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 32px;
}

.kpi-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    position: relative;
    overflow: hidden;
}

.kpi-icon {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.kpi-icon.blue { background: rgba(79, 70, 229, 0.1); color: var(--primary); }
.kpi-icon.green { background: rgba(37, 211, 102, 0.1); color: #25D366; }
.kpi-icon.orange { background: rgba(255, 152, 0, 0.1); color: #FF9800; }
.kpi-icon.purple { background: rgba(156, 39, 176, 0.1); color: #9C27B0; }

.kpi-content {
    flex: 1;
}

.kpi-value {
    display: block;
    font-size: 32px;
    font-weight: 700;
    color: var(--gray-900);
    line-height: 1;
    margin-bottom: 6px;
}

.kpi-label {
    font-size: 13px;
    color: var(--gray-500);
}

.kpi-trend {
    position: absolute;
    top: 16px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 20px;
}

.kpi-trend.up {
    background: rgba(37, 211, 102, 0.1);
    color: #25D366;
}

.kpi-trend.down {
    background: rgba(244, 67, 54, 0.1);
    color: #F44336;
}

.kpi-percent {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 14px;
    font-weight: 700;
    color: #25D366;
}

.kpi-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    font-size: 11px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 20px;
}

.kpi-badge.warning {
    background: rgba(255, 152, 0, 0.1);
    color: #FF9800;
}

/* Charts Row */
.stats-charts-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 24px;
}

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

.stats-chart-card.half {
    min-height: 320px;
}

.stats-chart-card {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.stats-chart-card.large {
    grid-column: span 1;
}

.chart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--gray-200);
}

.chart-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-900);
}

.chart-header h3 svg {
    color: var(--gray-500);
}

.chart-period {
    display: flex;
    gap: 4px;
    background: var(--gray-100);
    padding: 4px;
    border-radius: 8px;
}

.period-btn {
    padding: 6px 12px;
    border: none;
    background: transparent;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    color: var(--gray-500);
    cursor: pointer;
    transition: all 0.2s;
}

.period-btn:hover {
    color: var(--gray-700);
}

.period-btn.active {
    background: var(--bg-card);
    color: var(--primary);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.chart-body {
    min-height: 200px;
}

/* Bar Chart */
.bar-chart-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.bar-chart-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.bar-label {
    width: 100px;
    font-size: 13px;
    color: var(--gray-700);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex-shrink: 0;
}

.bar-track {
    flex: 1;
    height: 28px;
    background: var(--gray-100);
    border-radius: 6px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    border-radius: 6px;
    transition: width 0.5s ease;
}

.bar-value {
    width: 36px;
    text-align: right;
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-900);
}

/* SVG Line Chart */
.svg-chart-container {
    position: relative;
    width: 100%;
}

.chart-summary-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    color: white;
    padding: 10px 16px;
    border-radius: 10px;
    text-align: center;
    z-index: 10;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.badge-value {
    display: block;
    font-size: 24px;
    font-weight: 700;
    line-height: 1;
}

.badge-label {
    font-size: 11px;
    opacity: 0.9;
}

.line-chart-svg {
    width: 100%;
    height: auto;
    min-height: 220px;
}

.chart-point {
    cursor: pointer;
    transition: transform 0.2s;
}

.chart-point:hover circle:first-child {
    r: 8;
    fill: var(--primary-dark);
}

.chart-point .point-hitbox {
    cursor: pointer;
}

.chart-tooltip {
    position: absolute;
    background: var(--gray-900);
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    pointer-events: none;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
}

.chart-tooltip .tooltip-date {
    display: block;
    font-weight: 600;
    margin-bottom: 2px;
    color: var(--gray-300);
}

.chart-tooltip .tooltip-value {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: white;
}

/* SVG Bar Chart */
.bar-chart-svg {
    width: 100%;
    height: auto;
    min-height: 220px;
}

.status-bar rect {
    transition: opacity 0.2s;
}

.status-bar:hover rect {
    opacity: 0.85;
}

.status-badge {
    background: linear-gradient(135deg, #495057 0%, #343a40 100%);
}

/* Ajustements des graphiques pleine largeur */
.chart-body {
    min-height: 250px;
}

.stats-chart-card.half .chart-body {
    min-height: 280px;
}

.stats-chart-card.half .svg-chart-container {
    height: 100%;
}

.stats-chart-card.half .line-chart-svg,
.stats-chart-card.half .bar-chart-svg {
    min-height: 250px;
}

.bar-date {
    margin-top: 8px;
    font-size: 11px;
    color: var(--gray-500);
    white-space: nowrap;
}

/* Detailed Section */
.stats-detailed-section {
    background: var(--bg-card);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.detailed-header {
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--gray-200);
}

.detailed-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 600;
    color: var(--gray-900);
}

.detailed-header h3 svg {
    color: var(--gray-500);
}

.detailed-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.detailed-card {
    padding: 20px;
    background: var(--gray-50);
    border-radius: 12px;
}

.detailed-card h4 {
    font-size: 14px;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--gray-200);
}

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

/* Type List */
.type-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--bg-body);
    border-radius: 8px;
}

.type-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    color: var(--gray-700);
}

.type-stats {
    display: flex;
    align-items: center;
    gap: 12px;
}

.type-count {
    font-size: 18px;
    font-weight: 700;
    color: var(--gray-900);
}

.type-percent {
    font-size: 12px;
    color: var(--gray-500);
    background: var(--gray-100);
    padding: 2px 8px;
    border-radius: 10px;
}

/* Recent List */
.recent-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    background: var(--bg-body);
    border-radius: 8px;
}

.recent-info strong {
    display: block;
    font-size: 13px;
    color: var(--gray-900);
    margin-bottom: 2px;
}

.recent-info span {
    font-size: 12px;
    color: var(--gray-500);
}

.recent-time {
    font-size: 11px;
    color: var(--gray-500);
    background: var(--gray-100);
    padding: 4px 8px;
    border-radius: 6px;
}

/* Indicator List */
.indicator-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: var(--bg-body);
    border-radius: 8px;
}

.indicator-label {
    font-size: 13px;
    color: var(--gray-600);
}

.indicator-value {
    font-size: 16px;
    font-weight: 700;
    color: var(--gray-900);
}

.indicator-value.good { color: #25D366; }
.indicator-value.warning { color: #FF9800; }
.indicator-value.danger { color: #F44336; }

.no-data {
    text-align: center;
    color: var(--gray-500);
    padding: 40px 20px;
    font-size: 14px;
}

/* Responsive Stats */
@media (max-width: 1200px) {
    .stats-kpi-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-charts-row {
        grid-template-columns: 1fr;
    }
    
    .stats-charts-row.dual-charts {
        grid-template-columns: 1fr;
    }
    
    .detailed-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .stats-kpi-grid {
        grid-template-columns: 1fr;
    }
    
    .kpi-card {
        padding: 20px;
    }
    
    .kpi-value {
        font-size: 28px;
    }
    
    .line-chart-bars {
        height: 100px;
    }
}
