/* ==========================================================
   Goodwill Learning Centre — Institutional Dashboard Redesign
   Professional, polished look for Admin & Student dashboards.
   Purely presentational: all IDs, data, links & JS untouched.
   ========================================================== */

:root {
  --gw-navy: #0F2747;
  --gw-navy-2: #0B1E38;
  --gw-navy-3: #16335C;
  --gw-teal: #0EA5A9;
  --gw-teal-soft: rgba(14, 165, 169, 0.12);
  --gw-bg: #F4F7FB;
  --gw-border: #E6ECF3;
  --gw-card-shadow: 0 1px 2px rgba(15, 39, 71, 0.04), 0 8px 24px -12px rgba(15, 39, 71, 0.18);
  --gw-card-shadow-hover: 0 4px 8px rgba(15, 39, 71, 0.06), 0 18px 40px -16px rgba(15, 39, 71, 0.28);
}

/* ---- Cooler institutional page background ---- */
body {
  background-color: var(--gw-bg);
  background-image:
    radial-gradient(1100px 480px at 100% -10%, rgba(37, 99, 235, 0.06), transparent 60%),
    radial-gradient(900px 420px at -10% 0%, rgba(14, 165, 169, 0.05), transparent 55%);
  background-attachment: fixed;
}

/* =========================================================
   1. SIDEBAR — refined institutional chrome
   ========================================================= */
.sidebar {
  background: linear-gradient(180deg, var(--gw-navy) 0%, var(--gw-navy-2) 100%);
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  padding: 1.25rem 0.875rem;
}

.sidebar::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle at 20% 0%, rgba(37, 99, 235, 0.20), transparent 45%),
                    radial-gradient(circle at 90% 100%, rgba(14, 165, 169, 0.16), transparent 40%);
  pointer-events: none;
  opacity: 0.9;
}

.sidebar > * { position: relative; z-index: 1; }

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0 0.5rem 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.sidebar-brand-logo {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 12px;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.35);
  background: #fff;
}

.sidebar-brand-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.sidebar-brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  overflow: hidden;
}

.sidebar-brand-name {
  font-size: 1.0625rem;
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.sidebar-brand-sub {
  font-size: 0.6875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: rgba(159, 195, 232, 0.85);
}

.sidebar-section {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: rgba(148, 178, 214, 0.65);
  padding: 1.1rem 0.75rem 0.4rem;
  margin-top: 0;
}

.sidebar-section::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.15), transparent);
}

.sidebar-link {
  position: relative;
  padding: 0.625rem 0.75rem;
  font-weight: 500;
  border-radius: 10px;
  opacity: 0.82;
  margin: 0.125rem 0;
}

.sidebar-link::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%) scaleY(0);
  width: 3px;
  height: 60%;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, var(--primary), var(--gw-teal));
  transition: transform 0.2s ease;
}

.sidebar-link:hover {
  background-color: rgba(255, 255, 255, 0.06);
  opacity: 1;
}

.sidebar-link.active {
  background: linear-gradient(90deg, rgba(37, 99, 235, 0.22), rgba(14, 165, 169, 0.10));
  color: #fff;
  opacity: 1;
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.sidebar-link.active::before { transform: translateY(-50%) scaleY(1); }

.sidebar-link-icon { color: inherit; opacity: 0.9; }

.sidebar-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  margin-top: auto;
  padding: 1rem 0.25rem 0;
}

.sidebar-footer .btn-ghost {
  width: 100%;
  justify-content: flex-start;
  border-radius: 10px;
  padding: 0.625rem 0.75rem;
  color: rgba(226, 236, 247, 0.85) !important;
  font-weight: 500;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.sidebar-footer .btn-ghost:hover {
  background-color: rgba(239, 68, 68, 0.16);
  color: #ffd9d9 !important;
}

/* Slim, branded sidebar scrollbar */
.sidebar-nav::-webkit-scrollbar { width: 6px; }
.sidebar-nav::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.14);
  border-radius: 999px;
}
.sidebar-nav::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.26); }

/* =========================================================
   2. TOP PAGE HEADER — polished institutional band
   ========================================================= */
.dashboard-header { margin-bottom: 1.75rem; }

.dashboard-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.25rem;
  padding: 1.5rem 1.75rem;
  border-radius: 16px;
  background: linear-gradient(120deg, #ffffff 0%, #f3f7fe 100%);
  border: 1px solid var(--gw-border);
  box-shadow: var(--gw-card-shadow);
}

.dashboard-header-left { gap: 1.1rem; }

.dashboard-header-icon {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--gw-teal) 100%);
  font-size: 1.35rem;
  box-shadow: 0 8px 20px -6px rgba(37, 99, 235, 0.5);
}

.dashboard-header-title {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--gw-navy);
  line-height: 1.15;
}

.dashboard-header-subtitle {
  font-size: 0.875rem;
  color: var(--muted-foreground);
  margin-top: 0.2rem;
  font-weight: 500;
}

.dashboard-header-date {
  padding: 0.625rem 1.1rem;
  background: #fff;
  border: 1px solid var(--gw-border);
  border-radius: 12px;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--gw-navy);
  box-shadow: var(--shadow-sm);
}
.dashboard-header-date i { color: var(--gw-teal); }

/* =========================================================
   3. ADMIN STAT CARDS — premium KPI tiles
   ========================================================= */
.stats-grid { margin-top: 1.25rem; }

.stat-card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  padding: 1.5rem 1.5rem 1.4rem;
  background: #fff;
  box-shadow: var(--gw-card-shadow);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}

.stat-card::before {
  height: 4px;
  border-radius: 16px 16px 0 0;
}

.stat-card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.35);
}

.stat-card-inner { align-items: center; gap: 1.1rem; }

.stat-card-icon-wrap {
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 12px;
  font-size: 1.25rem;
  background: rgba(37, 99, 235, 0.1);
  box-shadow: inset 0 0 0 1px rgba(37, 99, 235, 0.08);
}

.stat-card-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

.stat-card-value {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* =========================================================
   4. SECTION HEADERS + QUICK ACTIONS
   ========================================================= */
.section-header-with-line {
  margin-top: 2.5rem;
  margin-bottom: 1.1rem;
}
.section-header-with-line h2 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--gw-navy);
  letter-spacing: -0.01em;
}
.section-header-line {
  height: 1px;
  background: linear-gradient(90deg, var(--gw-border), transparent);
}

.quick-action-card {
  border: 1px solid var(--gw-border);
  border-radius: 14px;
  padding: 1.1rem 1.25rem;
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
.quick-action-card::after { width: 4px; border-radius: 14px 0 0 14px; }
.quick-action-card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-3px);
}
.quick-action-icon {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 11px;
  font-size: 1.05rem;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.6);
}
.quick-action-label { font-size: 0.9rem; font-weight: 600; }

/* =========================================================
   5. ADMIN HERO HEADER — gradient band used on all admin pages
   ========================================================= */
.admin-hero {
  position: sticky;
  top: 0;
  z-index: 25;
  padding: 1.25rem 1.5rem;
  margin: 0 0 1.5rem;
  background: var(--card, #ffffff);
  border: 1px solid var(--border, #e2e8f0);
  border-top: none;
  border-radius: 0 0 1.25rem 1.25rem;
  box-shadow: 0 4px 16px rgba(15, 23, 42, 0.06);
  overflow: hidden;
}
.admin-hero-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
}
.admin-hero > * { position: relative; z-index: 1; }
.admin-hero .sidebar-toggle {
  background: var(--accent, #f1f5f9);
  border: none;
  color: var(--foreground, #0f172a);
  border-radius: 10px;
  width: 2.25rem;
  height: 2.25rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: background 0.2s ease;
}
.admin-hero .sidebar-toggle:hover { background: var(--border, #e2e8f0); }
.admin-hero h1 {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--foreground, #0f172a);
  letter-spacing: -0.02em;
  line-height: 1.15;
}
.admin-hero h1 i { margin-right: 0.5rem; color: var(--primary, #2563eb); }
.admin-hero p {
  color: var(--muted-foreground, #64748b);
  font-size: 0.9rem;
  margin-top: 0.35rem;
}
.admin-hero .hero-right {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.admin-hero .hero-date {
  padding: 0.5rem 1rem;
  background: var(--accent, #f1f5f9);
  border: 1px solid var(--border, #e2e8f0);
  border-radius: 10px;
  color: var(--muted-foreground, #64748b);
  font-size: 0.8rem;
  font-weight: 500;
  white-space: nowrap;
}
.admin-hero .hero-date i { margin-right: 0.35rem; color: var(--primary, #2563eb); }

@keyframes heroFade {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}
.admin-hero { animation: heroFade 0.4s ease both; }

/* =========================================================
   6. ENROLLMENTS TABLE — polished data card
   ========================================================= */
.enrollments-card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  box-shadow: var(--gw-card-shadow);
}
.enrollments-header {
  padding: 1.1rem 1.5rem;
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.05), rgba(14, 165, 169, 0.04));
  border-bottom: 1px solid var(--gw-border);
}
.enrollments-header-icon {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--gw-teal));
  color: #fff;
  font-size: 0.9rem;
}
.enrollments-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--gw-navy);
}
.enrollments-table thead th {
  background: #f7fafd;
  border-bottom: 1px solid var(--gw-border);
  color: var(--muted-foreground);
}
.enrollments-table tbody td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #eef2f7;
}
.enrollments-table tbody tr:nth-child(even) { background: #fafcfe; }
.enrollments-table tbody tr:hover { background: rgba(37, 99, 235, 0.045); }
.enrollments-table tbody tr:nth-child(even):hover { background: rgba(37, 99, 235, 0.05); }
.enrollment-status {
  padding: 0.3rem 0.8rem;
  border-radius: 999px;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,0.02);
}
.enrollment-student { color: var(--gw-navy); }

/* =========================================================
   6. STUDENT GREETING BAND + STAT TILES
   ========================================================= */
.student-greeting {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.75rem;
  padding: 1.5rem 1.75rem;
  border-radius: 16px;
  background: linear-gradient(120deg, var(--gw-navy) 0%, #16335C 55%, #1B6E72 100%);
  color: #fff;
  box-shadow: 0 16px 36px -18px rgba(15, 39, 71, 0.7);
  position: relative;
  overflow: hidden;
}
.student-greeting::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(14, 165, 169, 0.35), transparent 70%);
  pointer-events: none;
}
.student-greeting > * { position: relative; z-index: 1; }

.student-greeting .sidebar-toggle {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.25);
  color: #fff;
}
.student-greeting h1 {
  color: #fff;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}
.student-greeting p {
  color: rgba(214, 230, 245, 0.85);
  margin-top: 0.2rem;
  font-size: 0.9rem;
}
.student-greeting-avatar {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  background: rgba(255, 255, 255, 0.16);
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-size: 1.25rem;
  color: #fff;
  flex-shrink: 0;
}

/* Student stat tiles */
#studentStats {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(3, 1fr) !important; /* 3 KPI tiles always in one row */
}
@media (min-width: 1024px) {
  #studentStats.cols-4 { grid-template-columns: repeat(4, 1fr); }
}

#studentStats .card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--gw-card-shadow);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
#studentStats .card::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--gw-teal));
}
#studentStats .card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.35);
}
#studentStats .card-content {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.5rem;
}
#studentStats .card-content .text-sm.text-muted-foreground {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.07em;
}
#studentStats .stat-card-value {
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--gw-navy);
  margin-top: 0.35rem;
}
#studentStats .card-content::after {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  flex-shrink: 0;
  border-radius: 12px;
  background: rgba(37, 99, 235, 0.1);
  color: var(--primary);
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 1.2rem;
  content: "\f03d"; /* video */
}
#studentStats .card:nth-child(1) .card-content::after { content: "\f03d"; background: rgba(37,99,235,0.12); color:#2563EB; }
#studentStats .card:nth-child(2) .card-content::after { content: "\f144"; background: rgba(14,165,169,0.12); color:#0EA5A9; }
#studentStats .card:nth-child(3) .card-content::after { content: "\f15c"; background: rgba(124,58,237,0.12); color:#7C3AED; }
#studentStats .card:nth-child(4) .card-content::after { content: "\f02d"; background: rgba(234,88,12,0.12); color:#EA580C; }

/* =========================================================
   7. STUDENT — PROGRESS, QUICK CARDS, CONTINUE, UPDATES
   ========================================================= */
#progressSection .card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  background: linear-gradient(120deg, #ffffff, #f4f9ff);
  box-shadow: var(--gw-card-shadow);
  overflow: hidden;
}
#progressSection .card-content { padding: 1.5rem; }
#progressSection .font-medium {
  font-weight: 700;
  color: var(--gw-navy);
  font-size: 1.05rem;
}
.progress {
  height: 0.625rem;
  background: #e9eef5;
  border-radius: 999px;
  box-shadow: inset 0 1px 2px rgba(15,39,71,0.08);
}
.progress-bar {
  background: linear-gradient(90deg, var(--primary), var(--gw-teal));
  border-radius: 999px;
}

/* Quick feature cards */
.grid.md\:grid-cols-4 > .card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--gw-card-shadow);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
.grid.md\:grid-cols-4 > .card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.35);
}
.grid.md\:grid-cols-4 .card-content { padding: 1.5rem; }
.quick-card-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(37,99,235,0.12), rgba(14,165,169,0.12));
  color: var(--primary);
  box-shadow: inset 0 0 0 1px rgba(37,99,235,0.06);
}
.quick-card-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--gw-navy);
  margin-top: 1rem;
}
.quick-card-desc { font-size: 0.8125rem; margin-top: 0.2rem; }

/* Section titles (used across all pages) */
.dashboard-main > h2,
.mt-10 > h2 {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--gw-navy);
  letter-spacing: -0.01em;
  margin-top: 2rem;
  margin-bottom: 1rem;
}
.dashboard-main > h2::before,
.mt-10 > h2::before {
  content: "";
  width: 0.35rem;
  height: 1.1rem;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--primary), var(--gw-teal));
  flex-shrink: 0;
}
#continueWatching,
#announcementsList { position: relative; }

/* Continue watching cards */
#continueWatching .card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--gw-card-shadow);
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
#continueWatching .card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.35);
}
#continueWatching .card-content { padding: 1.5rem; }
#continueWatching .font-medium {
  font-size: 1rem;
  font-weight: 700;
  color: var(--gw-navy);
}
#continueWatching a[style*="var(--primary)"] {
  color: var(--primary) !important;
  font-weight: 700;
}

/* Recent updates / announcements */
#announcementsList .card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}
#announcementsList .card:hover {
  box-shadow: var(--gw-card-shadow);
  border-color: rgba(37, 99, 235, 0.25);
}
#announcementsList .card-content { padding: 1.25rem 1.4rem; }
#announcementsList .font-medium {
  font-size: 1rem;
  font-weight: 700;
  color: var(--gw-navy);
}
#announcementsList .text-xs.text-muted-foreground { color: var(--gw-teal); font-weight: 600; }

/* =========================================================
   8. SHARED POLISH
   ========================================================= */
/* nicer mobile sidebar toggle */
.sidebar-toggle {
  background: #fff;
  border: 1px solid var(--gw-border);
  box-shadow: var(--shadow-sm);
  color: var(--gw-navy);
}
.sidebar-toggle:hover { border-color: var(--primary); color: var(--primary); }

/* keep entrance animation but soften */
@keyframes gwFadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.dashboard-header-inner { animation: gwFadeUp 0.45s ease both; }
.student-greeting { animation: gwFadeUp 0.45s ease both; }
.stats-grid > .stat-card,
#studentStats > .card { animation: gwFadeUp 0.45s ease both; }
.stats-grid > .stat-card:nth-child(1), #studentStats > .card:nth-child(1) { animation-delay: 0.04s; }
.stats-grid > .stat-card:nth-child(2), #studentStats > .card:nth-child(2) { animation-delay: 0.08s; }
.stats-grid > .stat-card:nth-child(3), #studentStats > .card:nth-child(3) { animation-delay: 0.12s; }
.stats-grid > .stat-card:nth-child(4), #studentStats > .card:nth-child(4) { animation-delay: 0.16s; }
.stats-grid > .stat-card:nth-child(5) { animation-delay: 0.20s; }

/* =========================================================
   9. GLOBAL — applied to EVERY admin & student page
   (shared chrome: page-header band, cards, tables, buttons)
   ========================================================= */

/* Page header band (the shared inline-styled header used on
   every non-dashboard admin & student page) */
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] {
  gap: 1rem;
  margin-bottom: 1.75rem !important;
  padding: 1.25rem 1.5rem;
  border-radius: 16px;
  background: linear-gradient(120deg, #ffffff 0%, #f3f7fe 100%);
  border: 1px solid var(--gw-border);
  box-shadow: var(--gw-card-shadow);
  animation: gwFadeUp 0.45s ease both;
}
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] h1 {
  color: var(--gw-navy);
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] p {
  color: var(--muted-foreground);
  font-size: 0.9rem;
  margin-top: 0.2rem;
}
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] .sidebar-toggle {
  background: #fff;
  border: 1px solid var(--gw-border);
  box-shadow: var(--shadow-sm);
  color: var(--gw-navy);
}

/* Refined card surface everywhere */
.card {
  border: 1px solid var(--gw-border);
  border-radius: 16px;
  box-shadow: var(--gw-card-shadow);
}

/* Hover lift for cards rendered inside grids (content tiles) */
.grid .card {
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
.grid .card:hover {
  box-shadow: var(--gw-card-shadow-hover);
  transform: translateY(-4px);
  border-color: rgba(37, 99, 235, 0.35);
}

/* Polished data tables */
.data-table thead th {
  background: #f7fafd;
  color: var(--muted-foreground);
  border-bottom: 1px solid var(--gw-border);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  font-size: 0.75rem;
}
.data-table td { border-top: 1px solid #eef2f7; }
.data-table tbody tr:hover { background-color: rgba(37, 99, 235, 0.04); }
.table-wrapper { border-radius: 16px; overflow: hidden; }

/* Button polish */
.btn-primary { box-shadow: 0 4px 12px -4px rgba(37, 99, 235, 0.5); }
.btn-primary:hover:not(:disabled) { box-shadow: 0 6px 16px -4px rgba(37, 99, 235, 0.55); }
.alert { border-radius: 12px; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* =========================================================
   10. DASHBOARD SHELL — fixed sidebar + sticky top bar,
   content scrolls within the viewport (app-shell layout)
   ========================================================= */
.dashboard-body {
  height: 100vh;
}

.dashboard-main {
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: smooth;
  padding: 0 1.5rem 2rem;
}

@media (min-width: 768px) {
  .dashboard-main {
    margin-left: 16rem;
    padding: 0 2rem 2.5rem;
  }
}

/* Polished scrollbar for the content area */
.dashboard-main::-webkit-scrollbar { width: 10px; }
.dashboard-main::-webkit-scrollbar-track { background: transparent; }
.dashboard-main::-webkit-scrollbar-thumb {
  background: rgba(15, 39, 71, 0.18);
  border-radius: 999px;
  border: 3px solid transparent;
  background-clip: content-box;
}
.dashboard-main::-webkit-scrollbar-thumb:hover {
  background: rgba(15, 39, 71, 0.32);
  background-clip: content-box;
}

/* Sticky top page header / navigation bar — stays put while
   the rest of the content scrolls */
main.dashboard-main > .dashboard-header,
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"],
main.dashboard-main > .student-greeting {
  position: sticky;
  top: 0;
  z-index: 25;
  margin-bottom: 1.5rem !important;
  border-bottom: 1px solid var(--gw-border);
}

/* =========================================================
   11. POLISH & REFINEMENTS
   ========================================================= */

/* Premium gradient page titles (kept legible on light bands) */
.dashboard-header-title,
main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] h1 {
  color: var(--gw-navy);
}
@supports (-webkit-background-clip: text) or (background-clip: text) {
  .dashboard-header-title,
  main.dashboard-main > div[style*="display:flex;align-items:center;margin-bottom:2rem"] h1 {
    background: linear-gradient(120deg, var(--gw-navy) 0%, #1D4ED8 55%, var(--gw-teal) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}

/* Refined empty / zero-data states */
.enrollments-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  padding: 3.5rem 1.5rem;
  color: var(--muted-foreground);
}
.enrollments-empty i {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.08);
  color: var(--primary);
  font-size: 1.25rem;
  opacity: 1;
  margin: 0;
}
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
}
.empty-icon {
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: rgba(37, 99, 235, 0.08);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  opacity: 1;
}

/* Quick-action cards: subtle gradient wash on hover */
.quick-action-card:hover {
  background: linear-gradient(120deg, #ffffff 0%, #f2f7ff 100%);
}
.quick-action-card:hover .quick-action-label {
  color: var(--primary);
}

/* Content tiles: top accent reveal + stable positioning */
.grid .card {
  position: relative;
}
.grid .card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 1.5rem;
  right: 1.5rem;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--primary), var(--gw-teal));
  opacity: 0;
  transition: opacity 0.25s ease;
  pointer-events: none;
}
.grid .card:hover::after {
  opacity: 1;
}

/* Status / badge pills: softer, more refined */
.enrollment-status {
  gap: 0.45rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.badge {
  box-shadow: inset 0 0 0 1px rgba(15, 39, 71, 0.04);
}

/* Accessibility: visible focus ring on interactive elements */
.btn:focus-visible,
.form-input:focus-visible,
.form-select:focus-visible,
.form-textarea:focus-visible,
a:focus-visible {
  outline: 2px solid var(--ring, #2563EB);
  outline-offset: 2px;
}

/* Smooth, consistent transitions for cards everywhere */
.card,
.stat-card {
  transition: box-shadow 0.25s ease, transform 0.25s ease, border-color 0.25s ease;
}
