:root {
    --bg: #f8fafc;
    --card-bg: #ffffff;
    --border: #e2e8f0;
    --border-focus: #2563eb;
    --text: #0f172a;
    --dim: #64748b;
    --accent: #2563eb;
    --accent-glow: rgba(37, 99, 235, 0.08);
    --accent-green: #10b981;
    --accent-red: #ef4444;
    --glass: #ffffff;
    --sidebar-width: 260px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', sans-serif;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.1) transparent;
}

body {
    background-color: var(--bg);
    color: var(--text);
    overflow-x: hidden;
    min-height: 100vh;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.4s ease forwards;
}

/* Scrollbar Customization */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.2);
}

/* Layout */
.dashboard-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar - Clean High-Contrast Dark or Elegant White. Let's make it a very clean white sidebar with a border */
.sidebar {
    width: var(--sidebar-width);
    background: #ffffff;
    border-right: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    height: 100vh;
    z-index: 1000;
    overflow-y: auto !important;
    overflow-x: hidden;
    transition: var(--transition);
    box-shadow: 2px 0 15px rgba(0,0,0,0.02);
}

.sidebar-logo {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.logo-text {
    font-weight: 800;
    font-size: 1.25rem;
    color: #0f172a;
    letter-spacing: -0.5px;
}

.logo-text span {
    color: var(--accent);
}

.sidebar-menu {
    padding: 10px 8px;
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1 1 auto;
    min-height: 0 !important;
    overflow-y: auto !important;
    overflow-x: hidden;
}

/* Visible Sleek Scrollbar */
.sidebar-menu::-webkit-scrollbar {
    width: 6px;
}
.sidebar-menu::-webkit-scrollbar-track {
    background: #f1f5f9;
}
.sidebar-menu::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}
.sidebar-menu:hover::-webkit-scrollbar-thumb {
    background: #94a3b8;
}

.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    color: var(--dim);
    text-decoration: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.85rem;
    transition: var(--transition);
    white-space: nowrap;
}

.sidebar-menu a i {
    font-size: 1.05rem;
    width: 20px;
    text-align: center;
}

.sidebar-menu a:hover {
    background: #f1f5f9;
    color: var(--text);
}

.sidebar-menu li.active a {
    background: var(--accent-glow);
    color: var(--accent);
}

.sidebar-footer {
    padding: 14px 18px;
    border-top: 1px solid var(--border);
    flex-shrink: 0;
    background: #ffffff;
}

.user-profile-small {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-profile-small i {
    font-size: 1.5rem;
    color: var(--accent);
}

/* Main Content Area */
.main-content {
    flex-grow: 1;
    margin-left: var(--sidebar-width);
    padding: 40px;
    min-height: 100vh;
    background: #f8fafc;
}

/* Topbar */
.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 35px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--border);
}

.page-title {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: #0f172a;
}

/* Cards & Stats */
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 26px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02), 0 10px 20px -5px rgba(0, 0, 0, 0.03);
    transition: var(--transition);
}

.stat-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.08);
}

/* Forms & Inputs */
.premium-input {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #0f172a;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.9rem;
    outline: none;
    transition: var(--transition);
}

.premium-input:focus {
    border-color: var(--border-focus);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

.premium-select {
    background: #ffffff;
    border: 1px solid #cbd5e1;
    color: #0f172a;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 0.9rem;
    outline: none;
    cursor: pointer;
    transition: var(--transition);
}

.premium-select:focus {
    border-color: var(--border-focus);
}

/* Buttons */
.btn-premium {
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.btn-premium:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(37, 99, 235, 0.25);
}

.btn-premium:active {
    transform: translateY(0);
}

/* Tables */
.premium-table-container {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02), 0 10px 20px -5px rgba(0, 0, 0, 0.03);
}

.premium-table th {
    padding: 16px 20px;
    font-weight: 700;
    color: var(--dim);
    font-size: 0.75rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    background: #f1f5f9;
}

.premium-table td {
    padding: 18px 20px;
    font-size: 0.9rem;
    border-top: 1px solid var(--border);
    color: #334155;
}

.premium-table tr:hover {
    background: #f8fafc;
}

/* Toast Notifications */
.nn-toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 12px;
    color: #fff;
    font-weight: 600;
    font-size: 0.85rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    z-index: 2000;
    animation: fadeIn 0.3s ease forwards;
}

.nn-toast.success {
    background: var(--accent-green);
    border: 1px solid rgba(16, 185, 129, 0.2);
}
