:root {
    --primary: #2563eb;
    --primary-dark: #1e3a8a;
    --sidebar-bg: #111827;
    --sidebar-text: #9ca3af;
    --bg-color: #f3f4f6;
    --card-bg: #ffffff;
    --text-color: #374151;
    --success: #10b981;
    --danger: #ef4444;
    --purple: #8b5cf6;
}

* { box-sizing: border-box; }
body { margin: 0; font-family: 'Segoe UI', system-ui, sans-serif; background-color: var(--bg-color); color: var(--text-color); height: 100vh; overflow: hidden; }

/* Login */
.auth-container { display: flex; justify-content: center; align-items: center; height: 100vh; background: linear-gradient(135deg, var(--primary), var(--primary-dark)); }
.login-card { background: white; padding: 2rem; border-radius: 12px; width: 100%; max-width: 400px; text-align: center; box-shadow: 0 10px 25px rgba(0,0,0,0.2); }
.logo-area { margin-bottom: 2rem; color: var(--primary); }
.logo-area i { font-size: 3rem; margin-bottom: 0.5rem; }

/* Layout */
.app-layout { display: flex; height: 100vh; }
.hidden { display: none !important; }

/* Sidebar */
.sidebar { width: 260px; background-color: var(--sidebar-bg); color: var(--sidebar-text); display: flex; flex-direction: column; flex-shrink: 0; }
.sidebar .brand { padding: 1.5rem; font-size: 1.4rem; font-weight: bold; color: white; border-bottom: 1px solid #374151; }
.user-profile { padding: 1.5rem; display: flex; flex-direction: column; align-items: center; border-bottom: 1px solid #374151; }
.user-profile .avatar { width: 50px; height: 50px; background: #374151; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: white; margin-bottom: 0.5rem; }
.menu-title { padding: 1rem 1.5rem 0.5rem; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: #6b7280; }
.sidebar button { background: none; border: none; width: 100%; text-align: left; padding: 0.8rem 1.5rem; color: var(--sidebar-text); cursor: pointer; font-size: 0.95rem; transition: 0.2s; display: flex; align-items: center; gap: 10px; }
.sidebar button:hover, .sidebar button.active { background-color: #1f2937; color: white; border-right: 4px solid var(--primary); }
.logout-area { margin-top: auto; padding: 1rem; }

/* Content */
.content { flex: 1; padding: 2rem; overflow-y: auto; }
.card { background: white; padding: 1.5rem; border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); margin-bottom: 1.5rem; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.5rem; }
.full-width { width: 100%; }
.mt-2 { margin-top: 1rem; }

/* KPIs */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.5rem; margin-bottom: 2rem; }
.kpi-card { background: white; padding: 1.5rem; border-radius: 8px; box-shadow: 0 1px 3px rgba(0,0,0,0.1); border-left: 5px solid var(--primary); }
.kpi-value { display: block; font-size: 2rem; font-weight: bold; margin-top: 0.5rem; }

/* Forms */
input, select, textarea { width: 100%; padding: 0.8rem; margin-bottom: 1rem; border: 1px solid #d1d5db; border-radius: 6px; background: #f9fafb; }
button.btn-primary { background: var(--primary); color: white; padding: 0.8rem; border: none; border-radius: 6px; cursor: pointer; font-weight: 600; width: 100%; }
button.purple-btn { background: var(--purple); }
button.btn-secondary { background: #4b5563; color: white; padding: 0.8rem; border: none; border-radius: 6px; cursor: pointer; width: 100%; }
button.btn-small { background: var(--success); color: white; padding: 0.5rem 1rem; border: none; border-radius: 4px; cursor: pointer; }
button.btn-text { background: none; border: none; color: #6b7280; text-decoration: underline; cursor: pointer; }
.highlight-border { border-top: 4px solid var(--purple); }

/* Tables */
.table-responsive { overflow-x: auto; }
.data-table { width: 100%; border-collapse: collapse; min-width: 600px; }
.data-table th, .data-table td { padding: 1rem; text-align: left; border-bottom: 1px solid #e5e7eb; }
.data-table th { background-color: #f9fafb; font-weight: 600; }
.status-badge { padding: 4px 8px; border-radius: 12px; font-size: 0.8rem; font-weight: 600; }
.status-pass { background: #d1fae5; color: #065f46; }
.status-fail { background: #fee2e2; color: #991b1b; }

/* Exam Builder */
.options-grid { margin-bottom: 1rem; }
.opt-row { display: flex; align-items: center; gap: 10px; margin-bottom: 5px; }
.opt-row input[type="radio"] { width: auto; margin: 0; }
