:root {
    --background: #050505;
    --foreground: #ffffff;
    --card: #111113;
    --card-border: rgba(255, 255, 255, 0.12);
    --primary: #a855f7;
    --primary-glow: rgba(168, 85, 247, 0.35);
    --primary-hover: #9333ea;
    --secondary: #1e293b;
    --accent: #0ea5e9;
    --muted: #94a3b8;
    --glass: rgba(15, 15, 18, 0.9);
    --glass-border: rgba(255, 255, 255, 0.15);
    --gradient-deep: linear-gradient(135deg, #050505 0%, #111113 100%);
    --gradient-accent: linear-gradient(135deg, #a855f7 0%, #3b82f6 100%);
    --radius: 12px;
    --radius-lg: 18px;
    --shadow-lg: 0 10px 30px -5px rgba(0, 0, 0, 0.5), 0 8px 15px -6px rgba(0, 0, 0, 0.5);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Light Mode Overrides */
.light-mode {
    --background: #f8fafc;
    --foreground: #0f172a;
    --card: #ffffff;
    --card-border: #e2e8f0;
    --primary: #7c3aed;
    --primary-glow: rgba(124, 58, 237, 0.1);
    --primary-hover: #6d28d9;
    --secondary: #f1f5f9;
    --accent: #0284c7;
    --muted: #64748b;
    --glass: rgba(255, 255, 255, 0.95);
    --glass-border: #cbd5e1;
    --gradient-deep: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
}

.light-mode .main-content {
    background-image: radial-gradient(rgba(0, 0, 0, 0.05) 1px, transparent 0);
}

.light-mode .glass-input {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #0f172a;
}

.light-mode .search-bar input {
    color: #0f172a;
}

.light-mode .notif-badge {
    border-color: #f8fafc;
}

.light-mode .data-table th {
    background: #f8fafc;
}

.light-mode .nav-item:hover {
    background: #f1f5f9;
}

* {
    box-sizing: border-box;
    padding: 0;
    margin: 0;
}

body {
    color: var(--foreground);
    background: var(--background);
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    overflow: hidden;
}

h1,
h2,
h3,
h4 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* Layout */
.dashboard-layout {
    display: flex;
    height: 100vh;
    width: 100vw;
}

.sidebar {
    width: 70px;
    background: var(--card);
    border-right: 1px solid var(--card-border);
    padding: 1.5rem 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 10;
}

.main-content {
    flex: 1;
    padding: 1.5rem;
    overflow-y: auto;
    background-image: radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 0);
    background-size: 32px 32px;
}

/* UI Elements */
.logo {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 2rem;
    letter-spacing: -1px;
}

.nav-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 0.85rem;
    border-radius: var(--radius);
    color: var(--muted);
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

.nav-item i {
    width: 20px;
    height: 20px;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--foreground);
}

.nav-item.active {
    background: var(--primary-glow);
    color: var(--primary);
    font-weight: 600;
}

.glass-card {
    background: var(--glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    transition: var(--transition);
}

.glass-card:hover {
    border-color: var(--primary);
    box-shadow: 0 0 20px -5px var(--primary-glow);
    transform: translateY(-4px);
}

.btn-primary {
    background: var(--gradient-accent);
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.4);
}

.search-bar {
    background: var(--secondary);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 0.6rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: var(--transition);
}

.search-bar:focus-within {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

.search-bar input {
    background: transparent;
    border: none;
    color: white;
    outline: none;
    width: 100%;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Grid Utilities */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.stat-label {
    color: var(--muted);
    font-size: 0.875rem;
    font-weight: 500;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 800;
    margin-top: 0.2rem;
}

/* Table Styles */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.data-table th {
    text-align: left;
    padding: 1rem;
    color: var(--muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid var(--card-border);
}

.data-table td {
    padding: 0.85rem 1rem;
    border-bottom: 1px solid var(--card-border);
    font-size: 0.875rem;
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
}

.badge-success { background: rgba(16, 185, 129, 0.1); color: #10b981; border: 1px solid rgba(16, 185, 129, 0.2); }
.badge-warning { background: rgba(245, 158, 11, 0.1); color: #f59e0b; border: 1px solid rgba(245, 158, 11, 0.2); }
.badge-danger { background: rgba(239, 68, 68, 0.1); color: #ef4444; border: 1px solid rgba(239, 68, 68, 0.2); }
.badge-primary { background: rgba(168, 85, 247, 0.1); color: var(--primary); border: 1px solid var(--primary-glow); }
.badge-info { background: rgba(59, 130, 246, 0.1); color: #3b82f6; border: 1px solid rgba(59, 130, 246, 0.2); }
.badge-neutral { background: rgba(255, 255, 255, 0.05); color: var(--muted); border: 1px solid var(--glass-border); }

.bg-success { background: #10b981 !important; color: white !important; }
.bg-danger { background: #ef4444 !important; color: white !important; }
.bg-primary { background: var(--primary) !important; color: white !important; }

.text-success { color: #10b981 !important; }
.text-warning { color: #f59e0b !important; }
.text-danger { color: #ef4444 !important; }
.text-info { color: #3b82f6 !important; }
.text-muted { color: var(--muted) !important; }

/* Modals & Overlays */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 100;
    display: none;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.animate-scale-in {
    animation: scaleIn 0.3s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Form Elements */
.glass-input {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    padding: 0.6rem 1rem;
    color: white;
    font-family: inherit;
    transition: var(--transition);
}

.glass-input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.btn-ghost {
    background: transparent;
    border: none;
    color: var(--muted);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--foreground);
}

/* Notifications */
.top-header {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 0.5rem 1rem 0;
    margin-bottom: 1rem;
}

.notification-wrapper {
    position: relative;
}

.notif-btn {
    background: var(--secondary);
    border: 1px solid var(--card-border);
    color: var(--muted);
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
}

.notif-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
    background: var(--primary-glow);
}

.notif-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    font-weight: 700;
    min-width: 18px;
    height: 18px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    border: 2px solid var(--background);
}

.notif-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 320px;
    background: var(--card);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    z-index: 100;
    display: none;
    overflow: hidden;
    transform-origin: top right;
}

.notif-dropdown.active {
    display: block;
    animation: fadeIn 0.2s ease-out;
}

.notif-header {
    padding: 1rem;
    font-weight: 700;
    font-size: 0.9rem;
    border-bottom: 1px solid var(--card-border);
    background: rgba(255,255,255,0.02);
}

.notif-body {
    max-height: 400px;
    overflow-y: auto;
}

.notif-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    border-bottom: 1px solid var(--card-border);
    transition: var(--transition);
    cursor: pointer;
}

.notif-item:hover {
    background: rgba(255,255,255,0.03);
}

.notif-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
