/*
 * ═══════════════════════════════════════════════════════════════
 *  LIQUID GLASS DESIGN SYSTEM
 *  Chatbot Informasi Akademik — Universitas Sembilanbelas November Kolaka
 *  Version 2.0 | Modern • Elegant • Academic • Professional
 * ═══════════════════════════════════════════════════════════════
 */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ═══════════════════════════════════════
   1. DESIGN TOKENS (CSS Custom Properties)
   ═══════════════════════════════════════ */
:root {
    /* ── Primary Palette ── */
    --primary-dark: #130C22;
    --primary-purple: #24204F;
    --secondary-purple: #494677;
    --bg-light: #E7E2D6;
    --accent: #780814;
    --accent-hover: #9A1A28;
    --accent-light: rgba(120, 8, 20, 0.08);
    --accent-glow: rgba(120, 8, 20, 0.25);

    /* ── Neutral Palette ── */
    --white: #FFFFFF;
    --gray-50: #F8F7F4;
    --gray-100: #F0EDE6;
    --gray-200: #E2DDD2;
    --gray-300: #D1CABF;
    --gray-400: #A9A29A;
    --gray-500: #7A7470;
    --gray-600: #5C5856;
    --gray-700: #3D3A38;
    --gray-800: #2A2725;
    --gray-900: #1A1816;

    /* ── Semantic Colors ── */
    --success: #2D9F6F;
    --success-light: rgba(45, 159, 111, 0.1);
    --warning: #D4A832;
    --warning-light: rgba(212, 168, 50, 0.1);
    --danger: #780814;
    --danger-light: rgba(120, 8, 20, 0.08);
    --info: #3B82F6;
    --info-light: rgba(59, 130, 246, 0.1);

    /* ── Text Colors ── */
    --text-primary: #130C22;
    --text-secondary: #494677;
    --text-muted: #7A7470;
    --text-light: #A9A29A;
    --text-on-dark: #FFFFFF;
    --text-on-dark-muted: rgba(255, 255, 255, 0.7);
    --text-on-accent: #FFFFFF;

    /* ── Glass Effect ── */
    --glass-bg: rgba(255, 255, 255, 0.65);
    --glass-bg-strong: rgba(255, 255, 255, 0.82);
    --glass-bg-subtle: rgba(255, 255, 255, 0.45);
    --glass-border: rgba(255, 255, 255, 0.18);
    --glass-border-strong: rgba(255, 255, 255, 0.35);
    --glass-blur: 20px;
    --glass-blur-strong: 30px;

    /* ── Sidebar Glass ── */
    --sidebar-bg: #130C22;
    --sidebar-glass: rgba(36, 32, 79, 0.4);
    --sidebar-border: rgba(255, 255, 255, 0.06);
    --sidebar-active-bg: rgba(120, 8, 20, 0.2);
    --sidebar-hover-bg: rgba(255, 255, 255, 0.06);

    /* ── Typography ── */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-size-xs: 11px;
    --font-size-sm: 12px;
    --font-size-base: 14px;
    --font-size-md: 15px;
    --font-size-lg: 18px;
    --font-size-xl: 20px;
    --font-size-2xl: 24px;
    --font-size-3xl: 32px;
    --font-size-4xl: 40px;

    --font-weight-light: 300;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --font-weight-extrabold: 800;

    --line-height-tight: 1.2;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.7;

    /* ── Spacing (8-point grid) ── */
    --space-1: 4px;
    --space-2: 8px;
    --space-3: 12px;
    --space-4: 16px;
    --space-5: 20px;
    --space-6: 24px;
    --space-7: 28px;
    --space-8: 32px;
    --space-10: 40px;
    --space-12: 48px;
    --space-16: 64px;

    /* ── Border Radius ── */
    --radius-xs: 4px;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 20px;
    --radius-2xl: 24px;
    --radius-pill: 9999px;

    /* ── Shadows ── */
    --shadow-xs: 0 1px 2px rgba(19, 12, 34, 0.04);
    --shadow-sm: 0 2px 8px rgba(19, 12, 34, 0.05);
    --shadow-md: 0 4px 16px rgba(19, 12, 34, 0.08);
    --shadow-lg: 0 8px 32px rgba(19, 12, 34, 0.10);
    --shadow-xl: 0 16px 48px rgba(19, 12, 34, 0.14);
    --shadow-glass: 0 8px 32px rgba(19, 12, 34, 0.06);
    --shadow-glass-hover: 0 12px 40px rgba(19, 12, 34, 0.10);
    --shadow-accent: 0 4px 16px rgba(120, 8, 20, 0.25);
    --shadow-inner: inset 0 2px 4px rgba(19, 12, 34, 0.06);

    /* ── Transitions ── */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 300ms cubic-bezier(0.25, 0.8, 0.25, 1);
    --transition-spring: 400ms cubic-bezier(0.34, 1.56, 0.64, 1);

    /* ── Z-Index Layers ── */
    --z-base: 1;
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-overlay: 500;
    --z-sidebar: 600;
    --z-modal: 1000;
    --z-toast: 1100;
    --z-tooltip: 1200;
}


/* ═══════════════════════════════════════
   2. RESET & BASE
   ═══════════════════════════════════════ */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 100%;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-regular);
    line-height: var(--line-height-normal);
    color: var(--text-primary);
    background-color: var(--bg-light);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color var(--transition-fast);
}
a:hover {
    color: var(--accent-hover);
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ── Focus Accessibility ── */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: var(--radius-xs);
}

::selection {
    background-color: var(--accent-light);
    color: var(--accent);
}


/* ═══════════════════════════════════════
   3. TYPOGRAPHY
   ═══════════════════════════════════════ */
h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
    color: var(--text-primary);
    letter-spacing: -0.02em;
}
h1 { font-size: var(--font-size-3xl); }
h2 { font-size: var(--font-size-2xl); }
h3 { font-size: var(--font-size-xl); }
h4 { font-size: var(--font-size-lg); }
h5 { font-size: var(--font-size-md); }
h6 { font-size: var(--font-size-base); }

.text-xs { font-size: var(--font-size-xs); }
.text-sm { font-size: var(--font-size-sm); }
.text-base { font-size: var(--font-size-base); }
.text-md { font-size: var(--font-size-md); }
.text-lg { font-size: var(--font-size-lg); }
.text-xl { font-size: var(--font-size-xl); }
.text-2xl { font-size: var(--font-size-2xl); }
.text-3xl { font-size: var(--font-size-3xl); }

.text-primary { color: var(--text-primary) !important; }
.text-secondary { color: var(--text-secondary) !important; }
.text-muted { color: var(--text-muted) !important; }
.text-accent { color: var(--accent) !important; }
.text-success { color: var(--success) !important; }
.text-warning { color: var(--warning) !important; }
.text-danger { color: var(--danger) !important; }
.text-white { color: var(--white) !important; }

.font-light { font-weight: var(--font-weight-light); }
.font-regular { font-weight: var(--font-weight-regular); }
.font-medium { font-weight: var(--font-weight-medium); }
.font-semibold { font-weight: var(--font-weight-semibold); }
.font-bold { font-weight: var(--font-weight-bold); }


/* ═══════════════════════════════════════
   4. LIQUID GLASS COMPONENTS
   ═══════════════════════════════════════ */

/* ── Glass Card ── */
.glass-card {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-glass);
    padding: var(--space-6);
    transition: box-shadow var(--transition-smooth), transform var(--transition-smooth);
    position: relative;
    overflow: hidden;
}
.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
    pointer-events: none;
}
.glass-card:hover {
    box-shadow: var(--shadow-glass-hover);
    transform: translateY(-2px);
}
.glass-card.no-hover:hover {
    transform: none;
    box-shadow: var(--shadow-glass);
}

/* ── Glass Panel (Auth cards) ── */
.glass-panel {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur-strong));
    -webkit-backdrop-filter: blur(var(--glass-blur-strong));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-2xl);
    box-shadow: var(--shadow-xl);
    position: relative;
    overflow: hidden;
}
.glass-panel::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.6), transparent);
    pointer-events: none;
}

/* ── Glass Navbar ── */
.glass-navbar {
    background: rgba(36, 32, 79, 0.85);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 4px 20px rgba(19, 12, 34, 0.15);
}

/* ── Glass Topbar ── */
.glass-topbar {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    padding: var(--space-4) var(--space-6);
}

/* ── Glass Modal ── */
.glass-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(19, 12, 34, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: var(--z-modal);
    display: none;
    align-items: center;
    justify-content: center;
    padding: var(--space-4);
    animation: fadeIn 200ms ease;
}
.glass-modal-overlay.active {
    display: flex;
}
.glass-modal {
    background: var(--white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    max-width: 480px;
    width: 100%;
    overflow: hidden;
    animation: slideUp 300ms var(--transition-smooth);
}
.glass-modal-header {
    background: var(--primary-purple);
    color: var(--text-on-dark);
    padding: var(--space-5) var(--space-6);
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.glass-modal-header h4,
.glass-modal-header h5 {
    margin: 0;
    color: var(--text-on-dark);
    font-size: var(--font-size-md);
    font-weight: var(--font-weight-semibold);
}
.glass-modal-header .modal-close {
    background: none;
    border: none;
    color: var(--text-on-dark-muted);
    font-size: 22px;
    cursor: pointer;
    padding: var(--space-1);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    line-height: 1;
}
.glass-modal-header .modal-close:hover {
    color: var(--white);
    background: rgba(255,255,255,0.1);
}
.glass-modal-body {
    padding: var(--space-6);
}
.glass-modal-footer {
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--gray-200);
    display: flex;
    gap: var(--space-3);
    justify-content: flex-end;
}

/* ── Wide Modal ── */
.glass-modal.wide {
    max-width: 1000px;
    max-height: 85vh;
    display: flex;
    flex-direction: column;
}

/* ── Glass Sidebar ── */
.glass-sidebar {
    background: var(--sidebar-bg);
    position: relative;
    overflow: hidden;
}
.glass-sidebar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, rgba(120, 8, 20, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(36, 32, 79, 0.15) 0%, transparent 50%);
    pointer-events: none;
}


/* ═══════════════════════════════════════
   5. BUTTONS
   ═══════════════════════════════════════ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding: 10px 20px;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-medium);
    line-height: 1.4;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    white-space: nowrap;
    text-decoration: none;
    position: relative;
    overflow: hidden;
    min-height: 44px;
}
.btn:active {
    transform: scale(0.97);
}
.btn:disabled, .btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* ── Ripple Effect ── */
.btn .ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: scale(0);
    animation: rippleAnim 600ms linear;
    pointer-events: none;
}

/* Primary Button */
.btn-primary {
    background: var(--accent);
    color: var(--text-on-accent);
    border-color: var(--accent);
    box-shadow: var(--shadow-accent);
}
.btn-primary:hover {
    background: var(--accent-hover);
    border-color: var(--accent-hover);
    box-shadow: 0 6px 20px rgba(120, 8, 20, 0.35);
    transform: translateY(-1px);
    color: var(--text-on-accent);
}

/* Secondary Button */
.btn-secondary {
    background: var(--primary-purple);
    color: var(--text-on-dark);
    border-color: var(--primary-purple);
}
.btn-secondary:hover {
    background: var(--secondary-purple);
    border-color: var(--secondary-purple);
    transform: translateY(-1px);
    color: var(--text-on-dark);
}

/* Outline Button */
.btn-outline {
    background: transparent;
    color: var(--text-secondary);
    border-color: var(--gray-300);
}
.btn-outline:hover {
    background: var(--gray-100);
    border-color: var(--gray-400);
    color: var(--text-primary);
}

/* Ghost Button */
.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
    border-color: transparent;
}
.btn-ghost:hover {
    background: rgba(19, 12, 34, 0.05);
    color: var(--text-primary);
}

/* Danger Button */
.btn-danger {
    background: var(--danger);
    color: var(--white);
    border-color: var(--danger);
}
.btn-danger:hover {
    background: #8f0a18;
    transform: translateY(-1px);
    color: var(--white);
}

/* Success Button */
.btn-success {
    background: var(--success);
    color: var(--white);
    border-color: var(--success);
}
.btn-success:hover {
    background: #238c5c;
    transform: translateY(-1px);
    color: var(--white);
}

/* Warning Button */
.btn-warning {
    background: var(--warning);
    color: var(--text-primary);
    border-color: var(--warning);
}
.btn-warning:hover {
    background: #c59a28;
    transform: translateY(-1px);
}

/* Button Sizes */
.btn-sm {
    padding: 6px 14px;
    font-size: var(--font-size-sm);
    min-height: 36px;
    border-radius: var(--radius-sm);
}
.btn-lg {
    padding: 14px 28px;
    font-size: var(--font-size-md);
    min-height: 52px;
    border-radius: var(--radius-lg);
}

/* Pill Button */
.btn-pill {
    border-radius: var(--radius-pill);
}

/* Icon-only Button */
.btn-icon {
    padding: 10px;
    min-width: 44px;
    min-height: 44px;
}
.btn-icon.btn-sm {
    padding: 6px;
    min-width: 36px;
    min-height: 36px;
}

/* Button Loading State */
.btn.loading {
    pointer-events: none;
    opacity: 0.8;
}
.btn.loading .btn-text {
    visibility: hidden;
}
.btn.loading::after {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: var(--white);
    border-radius: 50%;
    animation: spin 600ms linear infinite;
}

/* Legacy compat */
.btn-premium {
    background: var(--accent);
    color: var(--text-on-accent);
    border: none;
    border-radius: var(--radius-md);
    padding: 10px 24px;
    font-family: var(--font-family);
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-base);
    cursor: pointer;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-accent);
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    min-height: 44px;
}
.btn-premium:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(120, 8, 20, 0.35);
    color: var(--white);
}
.btn-outline-premium {
    background: transparent;
    color: var(--text-secondary);
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-md);
    padding: 10px 24px;
    font-family: var(--font-family);
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-base);
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    gap: var(--space-2);
    min-height: 44px;
}
.btn-outline-premium:hover {
    background: var(--gray-100);
    border-color: var(--gray-400);
    color: var(--text-primary);
}

/* Action Buttons (table actions) */
.btn-action {
    padding: 7px 14px;
    border-radius: var(--radius-sm);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    color: var(--white);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 36px;
}
.btn-action.edit {
    background: var(--warning);
    color: var(--text-primary);
}
.btn-action.delete {
    background: var(--danger);
}
.btn-action.add, .btn-action.preview {
    background: var(--primary-purple);
}
.btn-action:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}


/* ═══════════════════════════════════════
   6. FORM ELEMENTS
   ═══════════════════════════════════════ */

/* ── Form Field Container ── */
.form-field {
    margin-bottom: var(--space-5);
}
.form-field label,
.form-label {
    display: block;
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-semibold);
    color: var(--text-secondary);
    margin-bottom: var(--space-2);
    letter-spacing: 0.01em;
}

/* ── Input ── */
.form-input,
.form-control-premium {
    width: 100%;
    padding: 12px 16px;
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    color: var(--text-primary);
    background: var(--white);
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    box-sizing: border-box;
    min-height: 44px;
}
.form-input:hover,
.form-control-premium:hover {
    border-color: var(--gray-400);
}
.form-input:focus,
.form-control-premium:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-light);
    background: var(--white);
    color: var(--text-primary);
}
.form-input::placeholder,
.form-control-premium::placeholder {
    color: var(--text-light);
}

/* ── Select ── */
.form-select {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23494677' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

/* ── Textarea ── */
.form-textarea {
    resize: vertical;
    min-height: 100px;
}

/* ── Validation States ── */
.form-input.is-invalid {
    border-color: var(--danger);
    box-shadow: 0 0 0 3px var(--danger-light);
}
.form-input.is-valid {
    border-color: var(--success);
    box-shadow: 0 0 0 3px var(--success-light);
}

/* ── Helper Text ── */
.form-helper {
    font-size: var(--font-size-xs);
    color: var(--text-muted);
    margin-top: var(--space-1);
}
.form-helper.error {
    color: var(--danger);
}

/* ── Input Group (with icon) ── */
.input-group-modern {
    position: relative;
}
.input-group-modern .form-input {
    padding-left: 44px;
}
.input-group-modern .input-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 18px;
    transition: color var(--transition-fast);
    pointer-events: none;
}
.input-group-modern .form-input:focus ~ .input-icon,
.input-group-modern .form-input:focus + .input-icon {
    color: var(--accent);
}


/* ═══════════════════════════════════════
   7. TABLE SYSTEM
   ═══════════════════════════════════════ */
.table-container {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-glass);
    overflow: hidden;
}
.table-header {
    padding: var(--space-6);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--space-4);
}
.table-header h3 {
    margin: 0;
    color: var(--text-primary);
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-semibold);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}

/* DataTables Override */
table.dataTable {
    border-collapse: collapse !important;
    width: 100% !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}
table.dataTable thead th {
    background: var(--primary-purple);
    color: var(--text-on-dark);
    padding: var(--space-4) var(--space-5) !important;
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-sm);
    text-transform: uppercase;
    letter-spacing: 0.04em;
    border-bottom: none !important;
    white-space: nowrap;
}
table.dataTable thead th:first-child {
    border-top-left-radius: 0;
}
table.dataTable thead th:last-child {
    border-top-right-radius: 0;
}
table.dataTable tbody td {
    padding: var(--space-4) var(--space-5) !important;
    vertical-align: middle;
    border-bottom: 1px solid var(--gray-200) !important;
    font-size: var(--font-size-base);
    color: var(--text-primary);
}
table.dataTable tbody tr {
    transition: background var(--transition-fast);
}
table.dataTable tbody tr:hover {
    background-color: var(--accent-light) !important;
}
table.dataTable tbody tr:last-child td {
    border-bottom: none !important;
}

/* DataTables controls */
.dataTables_wrapper {
    padding: 0 var(--space-5) var(--space-5);
}
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter {
    margin-bottom: var(--space-4);
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}
.dataTables_wrapper .dataTables_filter input {
    padding: 8px 14px;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius-sm);
    font-family: var(--font-family);
    font-size: var(--font-size-sm);
    transition: border-color var(--transition-fast);
    outline: none;
}
.dataTables_wrapper .dataTables_filter input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-light);
}
.dataTables_wrapper .dataTables_paginate {
    margin-top: var(--space-4);
}
.dataTables_wrapper .dataTables_paginate .paginate_button {
    padding: 6px 12px !important;
    border-radius: var(--radius-sm) !important;
    border: 1px solid var(--gray-200) !important;
    margin: 0 2px !important;
    font-size: var(--font-size-sm) !important;
    color: var(--text-secondary) !important;
    background: var(--white) !important;
    transition: all var(--transition-fast) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
    background: var(--gray-100) !important;
    border-color: var(--gray-300) !important;
    color: var(--text-primary) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current {
    background: var(--accent) !important;
    color: var(--white) !important;
    border-color: var(--accent) !important;
    font-weight: var(--font-weight-semibold) !important;
}
.dataTables_wrapper .dataTables_info {
    font-size: var(--font-size-sm);
    color: var(--text-muted);
    padding-top: var(--space-3);
}


/* ═══════════════════════════════════════
   8. TOGGLE SWITCH
   ═══════════════════════════════════════ */
.status-switch {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    background: var(--gray-50);
    padding: 5px 12px;
    border-radius: var(--radius-pill);
}
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    margin: 0;
}
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}
.slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: var(--gray-300);
    transition: var(--transition-base);
    border-radius: var(--radius-pill);
}
.slider::before {
    position: absolute;
    content: '';
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: var(--white);
    transition: var(--transition-base);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.15);
}
input:checked + .slider {
    background: linear-gradient(135deg, var(--accent), var(--accent-hover));
}
input:focus-visible + .slider {
    box-shadow: 0 0 0 3px var(--accent-light);
}
input:checked + .slider::before {
    transform: translateX(20px);
}
.status-text.on { color: var(--accent); font-weight: var(--font-weight-semibold); }
.status-text.off { color: var(--text-muted); }


/* ═══════════════════════════════════════
   9. BADGES & CHIPS
   ═══════════════════════════════════════ */
.badge-modern {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    font-size: var(--font-size-xs);
    font-weight: var(--font-weight-semibold);
    border-radius: var(--radius-pill);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.badge-accent {
    background: var(--accent-light);
    color: var(--accent);
}
.badge-success {
    background: var(--success-light);
    color: var(--success);
}
.badge-warning {
    background: var(--warning-light);
    color: #8B7020;
}
.badge-danger {
    background: var(--danger-light);
    color: var(--danger);
}
.badge-info {
    background: var(--info-light);
    color: var(--info);
}
.badge-neutral {
    background: var(--gray-100);
    color: var(--text-secondary);
}
.badge-code {
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
    background: var(--gray-100);
    padding: 4px 10px;
    border-radius: var(--radius-xs);
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-xs);
    color: var(--text-secondary);
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 14px;
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    background: var(--gray-100);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-pill);
    color: var(--text-secondary);
    transition: all var(--transition-fast);
}
.chip:hover {
    background: var(--accent-light);
    border-color: var(--accent);
    color: var(--accent);
}


/* ═══════════════════════════════════════
   10. SIDEBAR LAYOUT
   ═══════════════════════════════════════ */
.admin-sidebar {
    width: 260px;
    background: var(--sidebar-bg);
    color: var(--text-on-dark);
    position: fixed;
    height: 100vh;
    left: 0;
    top: 0;
    box-shadow: 4px 0 24px rgba(19, 12, 34, 0.15);
    transition: all var(--transition-smooth);
    z-index: var(--z-sidebar);
    overflow-y: auto;
    overflow-x: hidden;
}
.admin-sidebar::after {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: 
        radial-gradient(ellipse at 20% 0%, rgba(120, 8, 20, 0.10) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 100%, rgba(36, 32, 79, 0.2) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

.sidebar-brand {
    padding: var(--space-8) var(--space-5) var(--space-6);
    text-align: center;
    border-bottom: 1px solid var(--sidebar-border);
    margin-bottom: var(--space-4);
    position: relative;
    z-index: 1;
}
.sidebar-brand img {
    width: 56px;
    height: 56px;
    object-fit: contain;
    margin: 0 auto var(--space-3);
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
    border-radius: var(--radius-md);
}
.sidebar-brand h2 {
    font-size: var(--font-size-md);
    font-weight: var(--font-weight-bold);
    color: var(--text-on-dark);
    margin: 0 0 var(--space-1);
    letter-spacing: 0.02em;
}
.sidebar-brand p {
    font-size: var(--font-size-xs);
    color: var(--text-on-dark-muted);
    margin: 0;
}

.sidebar-nav {
    padding: var(--space-2) var(--space-3);
    position: relative;
    z-index: 1;
}
.sidebar-section-label {
    font-size: 10px;
    font-weight: var(--font-weight-bold);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-on-dark-muted);
    padding: var(--space-4) var(--space-4) var(--space-2);
    opacity: 0.5;
}

.nav-item {
    display: flex;
    align-items: center;
    padding: 11px 16px;
    color: var(--text-on-dark-muted);
    text-decoration: none;
    margin-bottom: 4px;
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    font-weight: var(--font-weight-medium);
    font-size: var(--font-size-base);
    position: relative;
}
.nav-item i {
    font-size: 18px;
    margin-right: 12px;
    width: 22px;
    text-align: center;
    flex-shrink: 0;
}
.nav-item:hover {
    background: var(--sidebar-hover-bg);
    color: var(--text-on-dark);
    transform: translateX(2px);
}
.nav-item.active {
    background: var(--sidebar-active-bg);
    color: var(--white);
    font-weight: var(--font-weight-semibold);
    border-left: 3px solid var(--accent);
    box-shadow: inset 0 0 20px rgba(120, 8, 20, 0.08);
}
.nav-item.active::after {
    content: '';
    position: absolute;
    left: -3px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 60%;
    background: var(--accent);
    border-radius: 0 2px 2px 0;
    box-shadow: 0 0 8px rgba(120, 8, 20, 0.4);
}

.nav-logout {
    margin-top: var(--space-8);
    background: rgba(120, 8, 20, 0.1) !important;
    color: rgba(255, 150, 150, 0.9) !important;
}
.nav-logout:hover {
    background: var(--accent) !important;
    color: var(--white) !important;
}


/* ═══════════════════════════════════════
   11. MAIN CONTENT LAYOUT
   ═══════════════════════════════════════ */
.main-content {
    margin-left: 260px;
    padding: var(--space-8);
    flex: 1;
    min-height: 100vh;
    min-width: 0;
    width: calc(100% - 260px);
    box-sizing: border-box;
    background: var(--bg-light);
    transition: margin-left var(--transition-smooth), width var(--transition-smooth);
}

/* ── Topbar ── */
.admin-topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    padding: var(--space-4) var(--space-6);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--space-8);
}
.admin-topbar h3 {
    margin: 0;
    font-size: var(--font-size-lg);
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

/* ── Profile Avatar ── */
.admin-profile {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}
.profile-avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary-purple), var(--secondary-purple));
    color: var(--white);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 18px;
    box-shadow: var(--shadow-sm);
}
.profile-info span {
    display: block;
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-semibold);
    color: var(--text-primary);
}
.profile-info small {
    color: var(--text-muted);
    font-size: var(--font-size-xs);
}


/* ═══════════════════════════════════════
   12. MOBILE RESPONSIVE
   ═══════════════════════════════════════ */
.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    font-size: 22px;
    color: var(--text-primary);
    cursor: pointer;
    padding: var(--space-1);
    border-radius: var(--radius-sm);
    min-width: 44px;
    min-height: 44px;
    align-items: center;
    justify-content: center;
}

.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%;
    height: 100%;
    background: rgba(19, 12, 34, 0.5);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: calc(var(--z-sidebar) - 1);
    opacity: 0;
    transition: opacity var(--transition-smooth);
}
.sidebar-overlay.active {
    display: block;
    opacity: 1;
}

@media (max-width: 768px) {
    .admin-sidebar {
        left: -260px;
        box-shadow: none;
    }
    .admin-sidebar.active {
        left: 0;
        box-shadow: 4px 0 24px rgba(19, 12, 34, 0.2);
    }
    .main-content {
        margin-left: 0 !important;
        padding: var(--space-4) !important;
        width: 100% !important;
    }
    .admin-topbar {
        padding: var(--space-3) var(--space-4);
    }
    .admin-topbar h3 {
        font-size: var(--font-size-md);
    }
    .mobile-menu-toggle {
        display: flex;
    }
    .profile-info {
        display: none;
    }
    table.dataTable {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }
    .table-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .glass-modal {
        max-width: 95vw;
        margin: var(--space-2);
    }
    .glass-modal.wide {
        max-height: 95vh;
    }
    .row { margin-left: 0; margin-right: 0; }
}

@media (max-width: 480px) {
    .main-content {
        padding: var(--space-3) !important;
    }
    .admin-topbar {
        padding: var(--space-3);
    }
    .glass-card {
        padding: var(--space-4);
        border-radius: var(--radius-lg);
    }
    h1 { font-size: var(--font-size-2xl); }
    h2 { font-size: var(--font-size-xl); }
}


/* ═══════════════════════════════════════
   13. MODAL OVERRIDES (Bootstrap compat)
   ═══════════════════════════════════════ */
.modal-content {
    border: none;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
}
.modal-header {
    background: var(--primary-purple);
    color: var(--text-on-dark);
    border-top-left-radius: var(--radius-xl);
    border-top-right-radius: var(--radius-xl);
    border-bottom: none;
    padding: var(--space-5) var(--space-6);
}
.modal-header .modal-title {
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-md);
}
.modal-header .close {
    color: var(--text-on-dark-muted);
    opacity: 0.8;
    text-shadow: none;
    font-size: 24px;
}
.modal-header .close:hover {
    color: var(--white);
    opacity: 1;
}
.modal-body {
    padding: var(--space-6);
}
.modal-footer {
    padding: var(--space-4) var(--space-6);
    border-top: 1px solid var(--gray-200);
}


/* ═══════════════════════════════════════
   14. ANIMATIONS
   ═══════════════════════════════════════ */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes slideUp {
    from { opacity: 0; transform: translateY(24px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-16px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}
@keyframes spin {
    to { transform: rotate(360deg); }
}
@keyframes rippleAnim {
    to { transform: scale(4); opacity: 0; }
}
@keyframes pulse-glow {
    0% { box-shadow: 0 0 0 0 rgba(120, 8, 20, 0.4); }
    70% { box-shadow: 0 0 0 12px rgba(120, 8, 20, 0); }
    100% { box-shadow: 0 0 0 0 rgba(120, 8, 20, 0); }
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}
@keyframes bounce {
    0%, 80%, 100% { transform: scale(0); }
    40% { transform: scale(1); }
}

.animate-fade-in {
    animation: fadeInUp 400ms ease forwards;
}
.animate-scale-in {
    animation: scaleIn 300ms ease forwards;
}


/* ═══════════════════════════════════════
   15. SKELETON LOADING
   ═══════════════════════════════════════ */
.skeleton {
    background: linear-gradient(90deg, var(--gray-200) 25%, var(--gray-100) 50%, var(--gray-200) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}
.skeleton-text {
    height: 14px;
    margin-bottom: var(--space-2);
    width: 100%;
}
.skeleton-heading {
    height: 24px;
    width: 60%;
    margin-bottom: var(--space-4);
}
.skeleton-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
}


/* ═══════════════════════════════════════
   16. SCROLLBAR
   ═══════════════════════════════════════ */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: var(--gray-300);
    border-radius: var(--radius-pill);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--gray-400);
}
/* Sidebar scrollbar */
.admin-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.15);
}
.admin-sidebar::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.25);
}
.admin-sidebar::-webkit-scrollbar-track {
    background: transparent;
}


/* ═══════════════════════════════════════
   17. UTILITY CLASSES
   ═══════════════════════════════════════ */
.d-flex { display: flex; }
.d-none { display: none; }
.d-block { display: block; }
.d-inline-flex { display: inline-flex; }
.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-between { justify-content: space-between; }
.justify-center { justify-content: center; }
.justify-end { justify-content: flex-end; }
.gap-1 { gap: var(--space-1); }
.gap-2 { gap: var(--space-2); }
.gap-3 { gap: var(--space-3); }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }

.w-full { width: 100%; }
.h-full { height: 100%; }
.min-h-screen { min-height: 100vh; }

.mt-0 { margin-top: 0; }
.mt-2 { margin-top: var(--space-2); }
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mb-0 { margin-bottom: 0; }
.mb-2 { margin-bottom: var(--space-2); }
.mb-3 { margin-bottom: var(--space-3); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }

.p-4 { padding: var(--space-4); }
.p-5 { padding: var(--space-5); }
.p-6 { padding: var(--space-6); }
.p-8 { padding: var(--space-8); }

.rounded-md { border-radius: var(--radius-md); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-pill { border-radius: var(--radius-pill); }

.text-center { text-align: center; }
.text-right { text-align: right; }
.text-left { text-align: left; }

.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}


/* ═══════════════════════════════════════
   18. ABSTRACT BACKGROUND
   ═══════════════════════════════════════ */
.abstract-bg {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -2;
    background:
        radial-gradient(ellipse at 15% 25%, rgba(120, 8, 20, 0.04) 0%, transparent 50%),
        radial-gradient(ellipse at 85% 75%, rgba(36, 32, 79, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(73, 70, 119, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

/* Auth page animated bg blobs */
.auth-bg {
    position: fixed;
    top: 0; left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
    background: var(--bg-light);
}
.auth-bg .blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.5;
    animation: float 8s ease-in-out infinite;
}
.auth-bg .blob-1 {
    width: 400px;
    height: 400px;
    background: rgba(120, 8, 20, 0.08);
    top: -10%;
    right: -5%;
    animation-duration: 10s;
}
.auth-bg .blob-2 {
    width: 350px;
    height: 350px;
    background: rgba(36, 32, 79, 0.08);
    bottom: -10%;
    left: -5%;
    animation-duration: 12s;
    animation-delay: -4s;
}
.auth-bg .blob-3 {
    width: 250px;
    height: 250px;
    background: rgba(73, 70, 119, 0.06);
    top: 40%;
    left: 30%;
    animation-duration: 14s;
    animation-delay: -2s;
}


/* ═══════════════════════════════════════
   19. STAT CARDS
   ═══════════════════════════════════════ */
.stat-card {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-xl);
    padding: var(--space-6);
    position: relative;
    overflow: hidden;
    transition: all var(--transition-smooth);
    box-shadow: var(--shadow-glass);
}
.stat-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent), var(--primary-purple));
    opacity: 0;
    transition: opacity var(--transition-base);
}
.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-glass-hover);
}
.stat-card:hover::before {
    opacity: 1;
}
.stat-icon {
    width: 52px;
    height: 52px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    margin-bottom: var(--space-4);
    color: var(--white);
}
.stat-title {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    color: var(--text-secondary);
    margin-bottom: var(--space-2);
}
.stat-value {
    font-size: var(--font-size-3xl);
    font-weight: var(--font-weight-extrabold);
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1;
    margin: 0;
}


/* ═══════════════════════════════════════
   20. WELCOME/HERO CARD
   ═══════════════════════════════════════ */
.welcome-card {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-purple));
    border-radius: var(--radius-xl);
    padding: var(--space-8) var(--space-8);
    color: var(--text-on-dark);
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: var(--shadow-lg);
    margin-bottom: var(--space-8);
    position: relative;
    overflow: hidden;
}
.welcome-card::after {
    content: '';
    position: absolute;
    top: -50%; right: -20%;
    width: 60%;
    height: 200%;
    background: radial-gradient(circle, rgba(120, 8, 20, 0.12) 0%, transparent 60%);
    pointer-events: none;
}
.welcome-card h2 {
    color: var(--text-on-dark);
    margin-top: 0;
    font-weight: var(--font-weight-bold);
}


/* ═══════════════════════════════════════
   21. MENU GRID (Dashboard)
   ═══════════════════════════════════════ */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: var(--space-5);
    margin-bottom: var(--space-8);
}
.menu-card {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-xl);
    padding: var(--space-6);
    text-decoration: none;
    color: var(--text-primary);
    display: block;
    transition: all var(--transition-smooth);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}
.menu-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.5), transparent);
    pointer-events: none;
}
.menu-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(120, 8, 20, 0.15);
    color: var(--text-primary);
    text-decoration: none;
}
.menu-card h5 {
    font-weight: var(--font-weight-semibold);
    margin-bottom: var(--space-2);
}
.menu-card p {
    color: var(--text-muted);
    font-size: var(--font-size-sm);
    margin-bottom: 0;
}


/* ═══════════════════════════════════════
   22. CHART PANEL
   ═══════════════════════════════════════ */
.chart-panel {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(var(--glass-blur));
    -webkit-backdrop-filter: blur(var(--glass-blur));
    border: 1px solid var(--glass-border-strong);
    border-radius: var(--radius-xl);
    padding: var(--space-6);
    box-shadow: var(--shadow-glass);
}
.chart-panel h4 {
    margin-top: 0;
    margin-bottom: var(--space-5);
    color: var(--text-primary);
    font-weight: var(--font-weight-semibold);
    font-size: var(--font-size-md);
    display: flex;
    align-items: center;
    gap: var(--space-2);
}


/* ═══════════════════════════════════════
   23. DASHBOARD GRID
   ═══════════════════════════════════════ */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--space-6);
    margin-bottom: var(--space-8);
}

@media (max-width: 768px) {
    .dashboard-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-4);
    }
    .menu-grid {
        grid-template-columns: 1fr;
    }
    .welcome-card {
        flex-direction: column;
        text-align: center;
        padding: var(--space-6);
    }
}
@media (max-width: 480px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
}


/* ═══════════════════════════════════════
   24. FILTER/TOOLS AREA
   ═══════════════════════════════════════ */
.tools-area {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-4);
    margin-bottom: var(--space-6);
    background: var(--gray-50);
    padding: var(--space-4);
    border-radius: var(--radius-lg);
    align-items: center;
    border: 1px solid var(--gray-200);
}
.tool-group {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}
.filter-input {
    background: var(--white);
    border: 1.5px solid var(--gray-300);
    padding: 10px 15px;
    border-radius: var(--radius-sm);
    font-family: var(--font-family);
    color: var(--text-primary);
    font-size: var(--font-size-sm);
    outline: none;
    transition: all var(--transition-fast);
    min-height: 44px;
}
.filter-input:focus {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-light);
}

@media (max-width: 768px) {
    .tools-area {
        flex-direction: column;
        align-items: stretch;
    }
    .tool-group {
        flex-wrap: wrap;
    }
}


/* ═══════════════════════════════════════
   25. FOOTER
   ═══════════════════════════════════════ */
.admin-footer {
    padding: var(--space-6) 0 var(--space-4);
    text-align: center;
    color: var(--text-muted);
    font-size: var(--font-size-xs);
}
.admin-footer a {
    color: var(--accent);
}


/* ═══════════════════════════════════════
   26. SWEETALERT2 THEME OVERRIDE
   ═══════════════════════════════════════ */
.swal2-popup {
    font-family: var(--font-family) !important;
    border-radius: var(--radius-xl) !important;
}
.swal2-styled.swal2-confirm {
    background-color: var(--accent) !important;
    border-radius: var(--radius-md) !important;
    font-weight: var(--font-weight-medium) !important;
    padding: 10px 28px !important;
    font-family: var(--font-family) !important;
}
.swal2-styled.swal2-cancel {
    border-radius: var(--radius-md) !important;
    font-weight: var(--font-weight-medium) !important;
    font-family: var(--font-family) !important;
}
.swal2-toast {
    border-radius: var(--radius-lg) !important;
    box-shadow: var(--shadow-lg) !important;
}


/* ═══════════════════════════════════════
   27. VENDOR OVERRIDES
   ═══════════════════════════════════════ */

/* ── Summernote ── */
.note-editor.note-frame {
    border: 1.5px solid var(--gray-300) !important;
    border-radius: var(--radius-md) !important;
    overflow: hidden;
}
.note-editor .note-toolbar {
    background: var(--gray-50) !important;
    border-bottom: 1px solid var(--gray-200) !important;
}
.note-editor .note-editing-area .note-editable {
    font-family: var(--font-family) !important;
    font-size: var(--font-size-base) !important;
    color: var(--text-primary) !important;
    background: var(--white) !important;
}

/* ── Tagify ── */
.tagify {
    border: 1.5px solid var(--gray-300) !important;
    border-radius: var(--radius-md) !important;
    min-height: 44px;
}
.tagify:focus-within {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 3px var(--accent-light) !important;
}
.tagify__tag {
    background: var(--accent-light) !important;
    border-radius: var(--radius-sm) !important;
}
.tagify__tag > div {
    color: var(--accent) !important;
}

/* ── Dropzone ── */
.dropzone {
    border: 2px dashed var(--gray-300) !important;
    border-radius: var(--radius-xl) !important;
    background: var(--gray-50) !important;
    min-height: 200px !important;
    transition: all var(--transition-base) !important;
}
.dropzone:hover {
    border-color: var(--accent) !important;
    background: var(--accent-light) !important;
}
.dropzone .dz-message {
    color: var(--text-secondary) !important;
    font-family: var(--font-family) !important;
}
