:root {
    --bg: #F4F7FE;
    --sidebar: #FFFFFF;
    --surface: #FFFFFF;
    --surface2: #F1F5F9;
    --border: #E2E8F0;
    --text: #1E293B;
    --muted: #64748B;
    --teal: #0D9488;
    --teal2: #14B8A6;
    --blue: #4F46E5;
    --purple: #8B5CF6;
    --amber: #F59E0B;
    --red: #F43F5E;
    --green: #10B981;
    --teal-rgb: 13, 148, 136;
    --blue-rgb: 79, 70, 229;
    --purple-rgb: 139, 92, 246;
    --amber-rgb: 245, 158, 11;
    --red-rgb: 244, 63, 94;
    --green-rgb: 16, 185, 129;
}

/* /* .sidebar{width:220px;min-width:220px;background:var(--sidebar);border-right:1px solid var(--border);display:flex;flex-direction:column} */

.logo { padding: 20px 18px; border-bottom: 1px solid var(--border); }
.logo-text { font-family: 'Syne', sans-serif; font-size: 13px; font-weight: 800; line-height: 1.2; color: var(--teal); }
.logo-text span { color: var(--text); }

.nav { flex: 1; padding: 12px 0; overflow-y: auto; }
.nav-section { padding: 8px 18px 4px; font-size: 10px; font-weight: 600; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; }
.nav-item { display: flex; align-items: center; gap: 10px; padding: 9px 18px; color: var(--muted); cursor: pointer; border-left: 3px solid transparent; transition: all .2s; }
.nav-item:hover, .nav-item.active { color: var(--text); background: rgba(var(--teal-rgb), 0.08); border-left-color: var(--teal); }
.nav-item svg { width: 16px; height: 16px; opacity: .7; }
.nav-item.active svg { opacity: 1; }
.nav-item span { font-size: 13px; }
.nav-badge { margin-left: auto; background: var(--amber); color: #fff; border-radius: 10px; padding: 1px 7px; font-size: 10px; font-weight: 700; }

.user-area { padding: 14px 18px; border-top: 1px solid var(--border); display: flex; align-items: center; gap: 10px; }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--purple)); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; color: #fff; }
.user-name { font-size: 12px; font-weight: 600; color: var(--text); }
.user-role { font-size: 10px; color: var(--muted); }

.main { flex: 1; display: flex; flex-direction: column; overflow: hidden; }
.topbar { height: 54px; background: var(--surface); border-bottom: 1px solid var(--border); display: flex; align-items: center; padding: 0 24px; gap: 12px; }
.topbar h1 { font-family: 'Syne', sans-serif; font-size: 16px; font-weight: 700; color: var(--text); }
.topbar-sub { font-size: 12px; color: var(--muted); }

.tabs { display: flex; gap: 2px; margin-left: 16px; }
.tab { padding: 6px 14px; border-radius: 6px; font-size: 12px; font-weight: 500; color: var(--muted); cursor: pointer; transition: all .2s; }
.tab.active { background: var(--blue); color: #fff; font-weight: 600; }
.tab:not(.active):hover { background: var(--surface2); color: var(--text); }

.topbar-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.btn-outline { border: 1px solid var(--border); background: var(--surface); color: var(--text); border-radius: 6px; padding: 6px 14px; font-size: 12px; cursor: pointer; transition: all 0.2s; }
.btn-outline:hover { background: var(--surface2); }
.btn-primary { background: var(--teal); color: #fff; border: none; border-radius: 6px; padding: 6px 14px; font-size: 12px; font-weight: 600; cursor: pointer; }

/* /* .content { flex: 1; overflow-y: auto; padding: 20px 24px; display: flex; flex-direction: column; gap: 16px; } */

.welcome-banner { background: linear-gradient(135deg, rgba(var(--blue-rgb), 0.08), rgba(var(--purple-rgb), 0.08)); border: 1px solid rgba(var(--blue-rgb), 0.15); border-radius: 14px; padding: 18px 22px; display: flex; align-items: center; gap: 20px; }
.welcome-text h2 { font-family: 'Syne', sans-serif; font-size: 18px; font-weight: 700; color: var(--text); }
.welcome-text p { font-size: 13px; color: var(--muted); margin-top: 4px; }
.welcome-stats { display: flex; gap: 24px; margin-left: auto; }
.w-stat { text-align: center; }
.w-stat-val { font-family: 'Syne', sans-serif; font-size: 22px; font-weight: 800; color: var(--blue); }
.w-stat-label { font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }

.grid-main { display: grid; grid-template-columns: 1fr 320px; gap: 16px; }
.grid-full { width: 100%; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; overflow: hidden; box-shadow: 0 1px 3px rgba(0,0,0,0.02); }
.card-header { padding: 14px 18px; border-bottom: 1px solid var(--border); display: flex; align-items: center; gap: 10px; }
.card-title { font-family: 'Syne', sans-serif; font-size: 13px; font-weight: 700; color: var(--text); flex: 1; }
.card-body { padding: 16px 18px; }
.card-meta { font-size: 11px; color: var(--muted); }

.class-list { display: flex; flex-direction: column; gap: 10px; }
.class-card { background: var(--surface2); border: 1px solid transparent; border-radius: 10px; padding: 14px 16px; display: grid; grid-template-columns: 1fr auto; gap: 12px; cursor: pointer; transition: all .2s; position: relative; }
.class-card:hover { border-color: rgba(var(--teal-rgb), 0.3); transform: translateX(2px); background: var(--surface); box-shadow: 0 4px 6px rgba(0,0,0,0.02); }
.class-card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; border-radius: 10px 0 0 10px; }
.class-card.active-class::before { background: var(--teal); }
.class-card.at-risk::before { background: var(--red); }
.class-card.warning::before { background: var(--amber); }
.class-card.good::before { background: var(--green); }
.class-name { font-size: 13px; font-weight: 600; margin-bottom: 3px; color: var(--text); }
.class-prog { font-size: 11px; color: var(--muted); margin-bottom: 8px; }
.class-meta { display: flex; gap: 14px; }
.class-meta-item { font-size: 11px; color: var(--muted); display: flex; align-items: center; gap: 4px; }
.class-meta-item strong { color: var(--text); font-weight: 600; }
.class-badges { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }

.role-badge { font-size: 10px; font-weight: 600; padding: 2px 8px; border-radius: 4px; border: 1px solid; }
.role-badge.assessor { border-color: rgba(var(--blue-rgb), 0.2); color: var(--blue); background: rgba(var(--blue-rgb), 0.08); }
.role-badge.facilitator { border-color: rgba(var(--teal-rgb), 0.2); color: var(--teal); background: rgba(var(--teal-rgb), 0.08); }
.role-badge.moderator { border-color: rgba(var(--purple-rgb), 0.2); color: var(--purple); background: rgba(var(--purple-rgb), 0.08); }

.status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 4px; }
.sd-green { background: var(--green); }
.sd-amber { background: var(--amber); }
.sd-red { background: var(--red); }

.prog-bar-wrap { margin-bottom: 10px; }
.prog-bar-label { display: flex; justify-content: space-between; margin-bottom: 4px; font-size: 11px; }
.prog-bar-label span:first-child { color: var(--muted); }
.prog-bar-label span:last-child { font-weight: 600; color: var(--text); }
.prog-bar-track { height: 6px; background: var(--surface2); border-radius: 3px; overflow: hidden; }
.prog-bar-fill { height: 100%; border-radius: 3px; }

.task-item { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); }
.task-item:last-child { border-bottom: none; }
.task-check { width: 18px; height: 18px; border-radius: 4px; border: 2px solid var(--border); flex-shrink: 0; margin-top: 1px; cursor: pointer; transition: all .2s; display: flex; align-items: center; justify-content: center; }
.task-check.done { background: var(--teal); border-color: var(--teal); }
.task-title { font-size: 12px; font-weight: 500; margin-bottom: 2px; color: var(--text); }
.task-meta { font-size: 11px; color: var(--muted); }
.task-due { margin-left: auto; font-size: 11px; font-weight: 600; white-space: nowrap; }
.task-due.urgent { color: var(--red); }
.task-due.soon { color: var(--amber); }
.task-due.ok { color: var(--green); }

.learner-table { width: 100%; border-collapse: collapse; }
.learner-table th { font-size: 10px; color: var(--muted); font-weight: 600; padding: 8px 10px; text-align: left; letter-spacing: .05em; text-transform: uppercase; border-bottom: 1px solid var(--border); }
.learner-table td { padding: 12px 10px; border-bottom: 1px solid var(--border); font-size: 12px; color: var(--text); }
.learner-table tr:last-child td { border-bottom: none; }
.learner-table tr:hover td { background: rgba(var(--surface2-rgb), 0.5); }
.learner-avatar { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 10px; font-weight: 700; color: #fff; margin-right: 6px; vertical-align: middle; }

.status-pill { display: inline-flex; align-items: center; padding: 3px 8px; border-radius: 4px; font-size: 10px; font-weight: 600; }
.sp-c { background: rgba(var(--green-rgb), 0.12); color: var(--green); }
.sp-p { background: rgba(var(--blue-rgb), 0.12); color: var(--blue); }
.sp-nyc { background: rgba(var(--red-rgb), 0.12); color: var(--red); }
.sp-ns { background: rgba(var(--muted-rgb), 0.12); color: var(--muted); }

.alert-box { border-radius: 8px; padding: 10px 12px; margin-bottom: 8px; display: flex; align-items: flex-start; gap: 8px; font-size: 12px; }
.alert-box.red { background: rgba(var(--red-rgb), 0.08); border: 1px solid rgba(var(--red-rgb), 0.2); }
.alert-box.amber { background: rgba(var(--amber-rgb), 0.08); border: 1px solid rgba(var(--amber-rgb), 0.2); }
.alert-icon { font-size: 14px; flex-shrink: 0; }
.alert-body { flex: 1; line-height: 1.5; color: var(--text); }
.alert-action { color: var(--blue); font-weight: 600; cursor: pointer; font-size: 11px; white-space: nowrap; flex-shrink: 0; }

.content::-webkit-scrollbar { width: 4px; }
.content::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }
.section-label { font-size: 10px; font-weight: 600; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 10px; }

.chip { background: var(--surface); border: 1px solid var(--border); border-radius: 6px; padding: 3px 10px; font-size: 11px; color: var(--muted); cursor: pointer; transition: all 0.2s; }
.chip.active { background: rgba(var(--blue-rgb), 0.08); border-color: var(--blue); color: var(--blue); }
.chip:hover:not(.active) { background: var(--surface2); }

.badge { display: inline-flex; align-items: center; justify-content: center; border-radius: 6px; padding: 3px 8px; font-size: 11px; font-weight: 600; }
.badge.green { background: rgba(var(--green-rgb), 0.12); color: var(--green); }
.badge.amber { background: rgba(var(--amber-rgb), 0.12); color: var(--amber); }
.badge.red { background: rgba(var(--red-rgb), 0.12); color: var(--red); }

.panel {display: none;}
.panel.active {display: block;}


.tab-strip {
	background: var(--surface);
	border-bottom: 1px solid var(--border);
	padding: 0 24px;
	display: flex;
	gap: 0;
	position: sticky;
	top: 56px;
	z-index: 90;
	box-shadow: 0 1px 0 var(--border);
}

.tab-btn {
	padding: 0 20px;
	height: 44px;
	font-size: 13px;
	border: none;
	background: transparent;
	cursor: pointer;
	border-bottom: 2px solid transparent;
	color: var(--text2);
	font-weight: 400;
	transition: color .15s;
	white-space: nowrap;
}

.tab-btn:hover {
	color: var(--text);
}

.tab-btn.active {
	color: var(--teal-dark);
	border-bottom-color: var(--teal);
	font-weight: 500;
}

.tab-badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--red);
	color: #fff;
	font-size: 10px;
	font-weight: 600;
	border-radius: 8px;
	padding: 1px 5px;
	margin-left: 5px;
	vertical-align: middle;
}

/* ==========================================================================
   FIX: Allow Dropdown Menus to escape Accordion Cards in Upzet Theme
   ========================================================================== */

/* 1. Force the main accordion container to allow overflow */
#accordion {
	overflow: visible !important;
}

/* 2. Force every card inside the accordion to allow overflow */
#accordion .card {
	overflow: visible !important;
}

/* 3. Force the collapse areas (when open) to allow overflow */
#accordion .collapse.show {
	overflow: visible !important;
}

/* 4. Force the card-body inside the collapse to allow overflow */
#accordion .card-body {
	overflow: visible !important;
}

/* 5. Ensure the table responsive wrapper doesn't clip the menus */
.table-responsive {
	overflow: visible !important;
}

/* 6. Give the dropdown highest z-index priority */
.dropdown-menu {
	z-index: 1050 !important; /* Bootstrap's standard high z-index */
}



