:root {
  --sdcc-navy: #101D3A;
  --sdcc-royal: #233F73;
  --sdcc-gold: #D9A441;
  --sdcc-bg: #F5F7FC;
  --sdcc-white: #FFFFFF;
  --sdcc-text-muted: #7C879E;
}

body {
  background: var(--sdcc-bg);
  font-family: 'Inter', 'Segoe UI', Roboto, Arial, sans-serif;
  color: var(--sdcc-navy);
}

/* ---------- Login ---------- */
.auth-screen {
  min-height: 100vh;
  width: 100%;
  background-image: url("../img/login_banner.png");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 40px 6vw;
}

.auth-screen::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(16, 29, 58, 0.15) 0%, rgba(16, 29, 58, 0.55) 100%);
}

.auth-form-panel {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(6px);
  border-radius: 20px;
  padding: 44px 40px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
}

.auth-form-card {
  width: 100%;
  max-width: 380px;
}

.auth-form-card h2 {
  font-weight: 800;
  color: var(--sdcc-navy);
  margin-bottom: 4px;
}

.auth-form-card p.lead-text {
  color: var(--sdcc-text-muted);
  font-size: 14px;
  margin-bottom: 28px;
}

.auth-form-card .form-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--sdcc-text-muted);
}

.auth-form-card .input-group-text {
  background: var(--sdcc-bg);
  border-right: none;
  color: var(--sdcc-royal);
}

.auth-form-card .form-control {
  border-left: none;
  padding: 11px 14px;
  background: var(--sdcc-bg);
}

.auth-form-card .form-control:focus {
  box-shadow: 0 0 0 3px rgba(217, 164, 65, 0.25);
  border-color: var(--sdcc-gold);
}

.auth-form-card .input-group:focus-within .input-group-text {
  border-color: var(--sdcc-gold);
}

.btn-sdcc-primary {
  background: var(--sdcc-navy);
  border: none;
  color: var(--sdcc-white);
  font-weight: 700;
  padding: 12px;
  border-radius: 10px;
  width: 100%;
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn-sdcc-primary:hover {
  background: var(--sdcc-royal);
  color: var(--sdcc-white);
  transform: translateY(-1px);
}

.auth-footer-note {
  text-align: center;
  font-size: 12.5px;
  color: var(--sdcc-text-muted);
  margin-top: 28px;
}

.auth-footer-note a {
  color: var(--sdcc-royal);
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 860px) {
  .auth-screen {
    justify-content: center;
    padding: 24px;
  }
  .auth-form-panel {
    padding: 32px 24px;
  }
}

/* ---------- App shell (dashboard) ---------- */
.app-shell {
  display: flex;
  min-height: 100vh;
}

.app-sidebar {
  width: 260px;
  flex-shrink: 0;
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  overflow-y: auto;
  z-index: 100;
}

.app-sidebar .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(217, 164, 65, 0.2);
  font-weight: 800;
}

.app-sidebar .brand-logo {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--sdcc-white);
  border: 2px solid var(--sdcc-gold);
  flex-shrink: 0;
}

.app-sidebar .brand span.gold {
  color: var(--sdcc-gold);
}

.app-sidebar nav {
  flex: 1;
  padding: 14px 10px;
}

.app-sidebar nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 14px;
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.65);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.app-sidebar nav a:hover {
  background: rgba(217, 164, 65, 0.12);
  color: var(--sdcc-white);
}

.app-sidebar nav a.active {
  background: var(--sdcc-gold);
  color: var(--sdcc-navy);
}

.app-main {
  flex: 1;
  min-width: 0;
  margin-left: 260px;
}

.app-topbar {
  background: var(--sdcc-white);
  padding: 18px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #E8ECF5;
}

.topbar-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--sdcc-gold);
  flex-shrink: 0;
}

.topbar-avatar-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
  font-weight: 800;
  font-size: 16px;
}

.app-content {
  padding: 28px 32px;
}

/* Mobile bottom navigation — shown instead of the sidebar below 768px */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 767px) {
  .app-sidebar {
    display: none;
  }
  .app-main {
    margin-left: 0;
  }
  .app-content {
    padding: 16px;
    padding-bottom: 76px; /* keep content clear of the fixed bottom nav */
  }
  .app-topbar {
    padding: 14px 16px;
  }
  .mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 64px;
    background: var(--sdcc-navy);
    z-index: 1000;
    box-shadow: 0 -4px 16px rgba(16, 29, 58, 0.18);
  }
  .mobile-bottom-nav a {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
  }
  .mobile-bottom-nav a i {
    font-size: 18px;
  }
  .mobile-bottom-nav a.active {
    color: var(--sdcc-gold);
  }
}

.stat-card {
  background: var(--sdcc-white);
  border-radius: 14px;
  padding: 22px;
  box-shadow: 0 8px 20px rgba(16, 29, 58, 0.06);
  display: flex;
  align-items: center;
  gap: 16px;
  height: 100%;
}

.stat-card .ic {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: rgba(217, 164, 65, 0.15);
  color: #B9821F;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.stat-card .num {
  font-size: 24px;
  font-weight: 800;
  color: var(--sdcc-navy);
}

.stat-card .label {
  font-size: 13px;
  color: var(--sdcc-text-muted);
}

.panel-card {
  background: var(--sdcc-white);
  border-radius: 14px;
  box-shadow: 0 8px 20px rgba(13, 42, 92, 0.06);
  overflow: hidden;
}

.panel-card .panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 22px;
  border-bottom: 1px solid #eef1f8;
}

.panel-card .panel-head h3 {
  font-size: 15px;
  font-weight: 700;
  color: var(--sdcc-navy);
  margin: 0;
}

/* ---------- Student Dashboard ---------- */
.welcome-banner {
  background: linear-gradient(120deg, var(--sdcc-navy) 0%, var(--sdcc-royal) 100%);
  border-radius: 16px;
  padding: 28px 32px;
  color: var(--sdcc-white);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 20px;
}

.welcome-banner h2 {
  font-weight: 800;
  margin-bottom: 4px;
}

.welcome-banner p {
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 14px;
}

.welcome-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 12px;
  font-weight: 600;
  margin-right: 8px;
}

.stat-card.stat-blue .ic { background: rgba(35, 63, 115, 0.12); color: var(--sdcc-royal); }
.stat-card.stat-green .ic { background: rgba(46, 125, 50, 0.12); color: #2E7D32; }
.stat-card.stat-gold .ic { background: rgba(217, 164, 65, 0.18); color: #B9821F; }
.stat-card.stat-navy .ic { background: rgba(16, 29, 58, 0.1); color: var(--sdcc-navy); }

.live-now-card {
  background: linear-gradient(120deg, #FDEDEC 0%, #FFF 100%);
  border: 1px solid #F5C6C6;
  border-radius: 14px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.live-badge {
  background: #E53935;
  color: #fff;
  font-weight: 700;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 20px;
  letter-spacing: 0.04em;
}

.timetable-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #eef1f8;
  font-size: 13px;
}

.timetable-row:last-child { border-bottom: none; }

.pill {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
}

.pill-completed { background: rgba(46, 125, 50, 0.12); color: #2E7D32; }
.pill-live { background: rgba(229, 57, 53, 0.12); color: #E53935; }
.pill-upcoming { background: rgba(217, 164, 65, 0.15); color: #B9821F; }

.subject-progress-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 13px;
}

.subject-progress-row .bar-track {
  flex: 1;
  height: 8px;
  border-radius: 6px;
  background: #eef1f8;
  overflow: hidden;
}

.subject-progress-row .bar-fill {
  height: 100%;
  border-radius: 6px;
  background: var(--sdcc-royal);
}

.btn-link-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: rgba(35, 63, 115, 0.08);
  color: var(--sdcc-royal);
  border: none;
  border-radius: 20px;
  padding: 5px 14px;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.btn-link-pill:hover {
  background: var(--sdcc-royal);
  color: var(--sdcc-white);
}

.resource-chip {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--sdcc-bg);
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 13px;
}

.form-section {
  background: var(--sdcc-bg);
  border: 1px solid #e8ecf5;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 20px;
}

.form-section-gold {
  border-color: rgba(217, 164, 65, 0.4);
  background: rgba(217, 164, 65, 0.06);
}

.form-section-title {
  color: var(--sdcc-royal);
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 16px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(35, 63, 115, 0.15);
}

/* ---------- Numbered registration sections ---------- */
.reg-card {
  background: var(--sdcc-white);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 20px;
  border: 1px solid #e8ecf5;
}

.reg-card-head {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
  padding: 12px 18px;
  font-weight: 700;
  font-size: 15px;
}

.reg-card-head .reg-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--sdcc-gold);
  color: var(--sdcc-navy);
  font-size: 13px;
  font-weight: 800;
}

.reg-card-body {
  padding: 20px;
}

.reg-summary-card {
  background: var(--sdcc-navy);
  border-radius: 12px;
  overflow: hidden;
  position: sticky;
  top: 16px;
}

.reg-summary-head {
  background: rgba(255, 255, 255, 0.06);
  color: var(--sdcc-white);
  font-weight: 700;
  padding: 14px 18px;
  font-size: 15px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.reg-summary-body {
  padding: 16px 18px;
}

.reg-summary-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed rgba(255, 255, 255, 0.12);
  font-size: 13px;
}

.reg-summary-row:last-child { border-bottom: none; }

.reg-summary-row .label { color: rgba(255, 255, 255, 0.6); }
.reg-summary-row .value { color: var(--sdcc-white); font-weight: 600; text-align: right; }

/* Learning Centre */
.lc-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  background: var(--sdcc-white);
  border-radius: 12px;
  padding: 6px;
  box-shadow: 0 8px 20px rgba(13, 42, 92, 0.06);
}

.lc-tab {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--sdcc-text-muted);
  text-decoration: none;
}

.lc-tab.active {
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
}

.lc-tab.disabled {
  opacity: 0.45;
  pointer-events: none;
}

.lc-badge-live {
  background: #e53935;
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: 5px;
  margin-right: 8px;
  letter-spacing: 0.03em;
}

.lc-player iframe {
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

.lc-chat-panel {
  display: flex;
  flex-direction: column;
  height: 420px;
  border: 1px solid #e8ecf5;
  border-radius: 10px;
  overflow: hidden;
}

.lc-messages {
  flex: 1;
  overflow-y: auto;
  padding: 10px 12px;
  background: var(--sdcc-bg);
}

.lc-message {
  font-size: 13px;
  margin-bottom: 10px;
  line-height: 1.4;
}

.lc-chat-form {
  display: flex;
  gap: 8px;
  padding: 10px;
  border-top: 1px solid #e8ecf5;
  background: var(--sdcc-white);
}

.lc-resource-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid #e8ecf5;
  border-radius: 10px;
  text-decoration: none;
  color: var(--sdcc-navy);
  font-size: 13px;
  font-weight: 600;
}

.lc-resource-ext {
  background: var(--sdcc-gold);
  color: var(--sdcc-navy);
  font-size: 10px;
  font-weight: 800;
  padding: 3px 7px;
  border-radius: 5px;
}

.btn-add {
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
  border: none;
  padding: 9px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.btn-add:hover {
  background: var(--sdcc-royal);
  color: var(--sdcc-white);
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
}

table.data-table th,
table.data-table td {
  text-align: left;
  padding: 12px 22px;
  font-size: 13.5px;
  border-bottom: 1px solid #f1f3f9;
  color: #3a4357;
  vertical-align: middle;
}

table.data-table th {
  color: var(--sdcc-text-muted);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.4px;
}

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

.badge-status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
}

.badge-live { background: rgba(40, 167, 69, 0.15); color: #1e7e34; }
.badge-upcoming { background: rgba(217, 164, 65, 0.18); color: #B9821F; }
.badge-cancelled { background: rgba(220, 53, 69, 0.15); color: #c0293c; }
.badge-draft { background: rgba(124, 135, 158, 0.15); color: #5c6a85; }

.empty-state {
  padding: 48px 22px;
  text-align: center;
  color: var(--sdcc-text-muted);
}

.avatar-sm {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--sdcc-gold);
}

.avatar-sm-fallback {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--sdcc-navy);
  color: var(--sdcc-white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
}

.dash-welcome h4 {
  color: var(--sdcc-navy);
}

.demo-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  background: rgba(124, 135, 158, 0.15);
  color: var(--sdcc-text-muted);
  padding: 2px 8px;
  border-radius: 999px;
  margin-left: 6px;
  vertical-align: middle;
}

.quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 10px;
  border-radius: 10px;
  background: var(--sdcc-bg);
  color: var(--sdcc-navy);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 700;
  text-align: center;
  border: 1px solid #eef1f8;
  transition: background 0.15s ease, transform 0.15s ease;
}

.quick-action i {
  font-size: 18px;
  color: var(--sdcc-royal);
}

.quick-action:hover {
  background: rgba(217, 164, 65, 0.12);
  color: var(--sdcc-navy);
  transform: translateY(-2px);
}

.my-teaching-row {
  background: var(--sdcc-bg);
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 13.5px;
}
