/* =============================================
   Task Manager - Custom Styles
   ============================================= */

:root {
    --sidebar-width: 260px;
    --header-height: 64px;
    --brand-primary: #2563eb;
    --brand-primary-dark: #1e40af;
    --brand-admin: #7c3aed;
    --sidebar-bg: #1e293b;
    --sidebar-hover: #334155;
    --content-bg: #f8fafc;
    --border-color: #e2e8f0;
    --text-muted: #64748b;
}

* {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--content-bg);
    color: #1e293b;
}

/* =============================================
   Auth Layout (Login)
   ============================================= */
.auth-body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 1rem;
}

.auth-container {
    width: 100%;
    max-width: 420px;
}

.auth-card {
    background: white;
    border-radius: 12px;
    padding: 2.5rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.auth-brand {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-brand-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-dark));
    color: white;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    font-size: 1.75rem;
}

.auth-brand-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: #1e293b;
}

.auth-brand-subtitle {
    color: var(--text-muted);
    margin: 0.25rem 0 0;
    font-size: 0.875rem;
}

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

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: var(--sidebar-bg);
    color: #e2e8f0;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    overflow-y: auto;
    transition: transform 0.3s ease;
    z-index: 100;
}

.sidebar-brand {
    padding: 1.5rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1.125rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: white;
}

.sidebar-brand i {
    font-size: 1.5rem;
    color: var(--brand-primary);
}

.sidebar-admin .sidebar-brand i {
    color: #a78bfa;
}

.sidebar-nav {
    flex: 1;
    padding: 1rem 0.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.nav-item {
    padding: 0.625rem 0.875rem;
    color: #cbd5e1;
    text-decoration: none;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.9375rem;
    transition: all 0.15s ease;
}

.nav-item:hover {
    background: var(--sidebar-hover);
    color: white;
}

.nav-item.active {
    background: var(--brand-primary);
    color: white;
}

.sidebar-admin .nav-item.active {
    background: var(--brand-admin);
}

.nav-item i {
    font-size: 1.125rem;
    width: 20px;
}

.nav-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 0.5rem 0;
}

.sidebar-user {
    padding: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.5rem;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--brand-primary), var(--brand-primary-dark));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
}

.user-avatar-admin {
    background: linear-gradient(135deg, var(--brand-admin), #5b21b6);
}

.user-name {
    font-weight: 500;
    color: white;
    font-size: 0.875rem;
    line-height: 1.2;
}

.user-dept {
    font-size: 0.75rem;
    color: #94a3b8;
    line-height: 1.2;
    margin-top: 0.125rem;
}

/* Main content */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.content-header {
    background: white;
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: var(--header-height);
}

.content-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0;
}

.content-body {
    padding: 1.5rem;
    flex: 1;
}

/* Mobile */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    body.sidebar-open .sidebar {
        transform: translateX(0);
    }
    .main-content {
        margin-left: 0;
    }
}

/* =============================================
   Cards & Stats
   ============================================= */
.stat-card {
    background: white;
    border-radius: 8px;
    padding: 1.25rem;
    border: 1px solid var(--border-color);
    height: 100%;
}

.stat-card-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin: 0 0 0.25rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.stat-card-value {
    font-size: 1.875rem;
    font-weight: 700;
    margin: 0;
    line-height: 1.2;
}

.stat-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    color: white;
    margin-bottom: 0.75rem;
}

.stat-card-icon-primary { background: var(--brand-primary); }
.stat-card-icon-success { background: #10b981; }
.stat-card-icon-warning { background: #f59e0b; }
.stat-card-icon-info { background: #06b6d4; }
.stat-card-icon-admin { background: var(--brand-admin); }

/* Section cards */
.section-card {
    background: white;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    margin-bottom: 1.5rem;
    overflow: hidden;
}

.section-card-header {
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.section-card-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

.section-card-body {
    padding: 1.25rem;
}

/* =============================================
   Tables
   ============================================= */
.table-app {
    width: 100%;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
}

.table-app th {
    background: #f8fafc;
    font-weight: 600;
    font-size: 0.8125rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
}

.table-app td {
    padding: 0.875rem 1rem;
    border-bottom: 1px solid var(--border-color);
    vertical-align: middle;
    font-size: 0.9375rem;
}

.table-app tr:last-child td {
    border-bottom: none;
}

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

/* =============================================
   Forms
   ============================================= */
.form-label {
    font-weight: 500;
    font-size: 0.875rem;
    margin-bottom: 0.375rem;
}

.form-control, .form-select {
    border-color: var(--border-color);
    font-size: 0.9375rem;
    padding: 0.5rem 0.75rem;
}

.form-control:focus, .form-select:focus {
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.btn-primary {
    background: var(--brand-primary);
    border-color: var(--brand-primary);
}

.btn-primary:hover {
    background: var(--brand-primary-dark);
    border-color: var(--brand-primary-dark);
}

/* =============================================
   Empty states
   ============================================= */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    color: var(--text-muted);
}

.empty-state i {
    font-size: 3rem;
    color: #cbd5e1;
    margin-bottom: 1rem;
    display: block;
}

.empty-state-title {
    font-weight: 600;
    color: #334155;
    margin: 0 0 0.5rem;
}

/* Utility classes */
.text-muted-sm {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.text-mono {
    font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
    font-size: 0.875em;
}

.badge-dept {
    background: #e0e7ff;
    color: #4338ca;
    font-weight: 500;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
}
.header-logo{
    width:10%;
}