:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #e0e7ff;
    --secondary: #64748b;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --sidebar-bg: #0f172a;
    --sidebar-text: #94a3b8;
    --sidebar-active: #ffffff;
    --sidebar-active-bg: #1e293b;
    --body-bg: #f8fafc;
    --card-bg: #ffffff;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--body-bg);
    color: #1e293b;
    min-height: 100vh;
}

/* Sidebar Styling */
.sidebar {
    background-color: var(--sidebar-bg);
    min-height: 100vh;
    width: 260px;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.sidebar .brand {
    padding: 24px 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar .brand-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, #6366f1, #4f46e5);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.sidebar .nav-item {
    margin: 4px 12px;
}

.sidebar .nav-link {
    color: var(--sidebar-text);
    padding: 12px 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.925rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.sidebar .nav-link:hover {
    color: var(--sidebar-active);
    background-color: rgba(255, 255, 255, 0.05);
}

.sidebar .nav-link.active {
    color: var(--sidebar-active);
    background-color: var(--primary);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.35);
}

.sidebar .nav-link i {
    font-size: 1.1rem;
    width: 22px;
    text-align: center;
}

/* Main Content Area */
.main-wrapper {
    margin-left: 260px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.top-navbar {
    background: #ffffff;
    height: 70px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 32px;
    position: sticky;
    top: 0;
    z-index: 99;
}

.page-content {
    padding: 32px;
    flex: 1;
}

/* Modern Card Styling */
.stat-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02), 0 4px 12px rgba(0, 0, 0, 0.03);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
}

.form-card {
    background: #ffffff;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.form-card .card-header {
    background: transparent;
    border-bottom: 1px solid #e2e8f0;
    padding: 20px 24px;
}

.form-card .card-body {
    padding: 24px;
}

/* Switches & Controls */
.form-check-input:checked {
    background-color: var(--primary);
    border-color: var(--primary);
}

.btn-primary {
    background-color: var(--primary);
    border-color: var(--primary);
    font-weight: 500;
    padding: 10px 20px;
    border-radius: 8px;
}

.btn-primary:hover, .btn-primary:focus {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

/* Code Snippet Box */
.code-box {
    background: #0f172a;
    color: #38bdf8;
    border-radius: 8px;
    padding: 16px;
    font-family: 'Fira Code', monospace;
    font-size: 0.875rem;
    position: relative;
    overflow-x: auto;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .sidebar {
        margin-left: -260px;
    }
    .sidebar.open {
        margin-left: 0;
    }
    .main-wrapper {
        margin-left: 0;
    }
}
