:root {
    --primary: #4e73df;
    --secondary: #858796;
    --success: #1cc88a;
    --info: #36b9cc;
    --warning: #f6c23e;
    --danger: #e74a3b;
    --dark: #5a5c69;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f8f9fc;
    min-height: 100vh;
}
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    width: 250px;
    background: linear-gradient(180deg, var(--primary) 0%, #224abe 100%);
    color: #fff;
    padding-top: 1rem;
    z-index: 1000;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
}
.sidebar-brand {
    padding: 1rem 1.5rem;
    font-size: 1.2rem;
    font-weight: 700;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-shrink: 0;
}
.sidebar-brand i { font-size: 1.5rem; }
.sidebar-menu {
    padding: 0.5rem 0;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}
.sidebar-menu a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: rgba(255,255,255,0.7);
    text-decoration: none;
    transition: all 0.2s;
    font-size: 0.9rem;
}
.sidebar-menu a:hover, .sidebar-menu a.active {
    color: #fff;
    background: rgba(255,255,255,0.1);
}
.sidebar-menu a i { width: 20px; text-align: center; }
.main-content {
    margin-left: 250px;
    padding: 1.5rem;
    min-height: 100vh;
}
.topbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e3e6f0;
}
.topbar h1 { font-size: 1.5rem; color: var(--dark); font-weight: 600; }
.topbar .user-info { display: flex; align-items: center; gap: 0.75rem; }
.card {
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 0.15rem 1.75rem rgba(0,0,0,0.05);
    margin-bottom: 1.5rem;
}
.card-header {
    background: #fff;
    border-bottom: 1px solid #e3e6f0;
    padding: 1rem 1.25rem;
    font-weight: 600;
}
.card-body { padding: 1.25rem; }
.stat-card {
    border-left: 4px solid var(--primary);
    padding: 1.25rem;
}
.stat-card .stat-label { font-size: 0.8rem; color: var(--secondary); text-transform: uppercase; }
.stat-card .stat-value { font-size: 1.75rem; font-weight: 700; color: var(--dark); }
.stat-card.primary { border-left-color: var(--primary); }
.stat-card.success { border-left-color: var(--success); }
.stat-card.info { border-left-color: var(--info); }
.stat-card.warning { border-left-color: var(--warning); }
.table th { background: #f8f9fc; font-weight: 600; font-size: 0.85rem; }
.btn { border-radius: 0.35rem; font-size: 0.85rem; }
.btn-sm { font-size: 0.8rem; }
.form-label { font-weight: 600; font-size: 0.85rem; color: var(--dark); }
.form-control, .form-select { border-radius: 0.35rem; font-size: 0.9rem; }
.login-page {
    background: linear-gradient(180deg, var(--primary) 0%, #224abe 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
.login-card {
    background: #fff;
    border-radius: 0.5rem;
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 0.5rem 2rem rgba(0,0,0,0.2);
}
.login-card h3 {
    text-align: center;
    margin-bottom: 1.5rem;
    color: var(--dark);
}
.login-card .login-icon {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

/* Sidebar group */
.sidebar-group { margin: 0; }
.sidebar-group-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.2s;
    user-select: none;
}
.sidebar-group-title:hover { color: #fff; background: rgba(255,255,255,0.1); }
.sidebar-group-title i:first-child { width: 20px; text-align: center; }
.sidebar-group-title .group-arrow { margin-left: auto; font-size: 0.75rem; transition: transform 0.2s; }
.sidebar-group-title.collapsed .group-arrow { transform: rotate(-90deg); }
.sidebar-submenu { overflow: hidden; transition: max-height 0.3s ease; max-height: 0; }
.sidebar-submenu.collapsed { max-height: 0 !important; }
.sidebar-submenu a {
    padding-left: 3.5rem !important;
    font-size: 0.85rem !important;
}
