/* NerdyLMS Modern Design System */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800;900&display=swap');

:root {
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Inter', sans-serif;

  /* Color Palette - Vibrant Deep Indigo & Tech Cyan */
  --bg-main: #0b0f19;
  --bg-surface: #111827;
  --bg-surface-elevated: #1f2937;
  --bg-card: rgba(17, 24, 39, 0.75);
  --border-glass: rgba(255, 255, 255, 0.08);
  --border-glass-hover: rgba(99, 102, 241, 0.4);

  --text-primary: #f9fafb;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --accent-primary: #6366f1;
  --accent-primary-hover: #4f46e5;
  --accent-secondary: #06b6d4;
  --accent-pink: #ec4899;
  --accent-emerald: #10b981;
  --accent-amber: #f59e0b;
  --accent-rose: #f43f5e;

  --gradient-primary: linear-gradient(135deg, #6366f1 0%, #a855f7 50%, #ec4899 100%);
  --gradient-surface: linear-gradient(180deg, rgba(31, 41, 55, 0.6) 0%, rgba(17, 24, 39, 0.8) 100%);
  --gradient-cyan: linear-gradient(135deg, #06b6d4 0%, #3b82f6 100%);
  --gradient-telegram: linear-gradient(135deg, #229ed9 0%, #0088cc 100%);

  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
  --shadow-glow: 0 0 30px rgba(99, 102, 241, 0.25);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;

  --transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Base Styles */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-main);
  color: var(--text-primary);
  font-family: var(--font-body);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: clip;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: #ffffff;
  font-weight: 700;
  line-height: 1.25;
}

a {
  color: var(--accent-secondary);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: #38bdf8;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Utility Containers */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-fluid {
  width: 100%;
  padding: 0 1.5rem;
}

/* Navbar */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-glass);
  padding: 0.9rem 0;
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.5rem;
  color: #fff;
  letter-spacing: -0.02em;
}

.brand-badge {
  background: var(--gradient-primary);
  color: #fff;
  font-size: 0.7rem;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-link {
  color: var(--text-secondary);
  font-weight: 500;
  font-size: 0.95rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.nav-link:hover, .nav-link.active {
  color: #fff;
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.65rem 1.35rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--gradient-primary);
  color: #fff;
  box-shadow: 0 4px 15px rgba(99, 102, 241, 0.35);
}

.btn-primary:hover {
  opacity: 0.92;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
  color: #fff;
}

.btn-secondary {
  background: var(--bg-surface-elevated);
  border-color: var(--border-glass);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.btn:active,
.btn-secondary:active {
  transform: translateY(1px);
  filter: brightness(1.15);
}

/* Nav CTA Buttons Distinct Active vs Inactive State */
.nav-cta .btn {
  transition: all 0.18s ease-in-out;
}

.nav-cta .btn.btn-primary.active,
.nav-cta .btn.active {
  background: var(--gradient-primary) !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  box-shadow: 0 4px 18px rgba(99, 102, 241, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.3) inset !important;
  border: 1px solid rgba(165, 180, 252, 0.6) !important;
  transform: translateY(-1px);
}

.nav-cta .btn.btn-primary.active i,
.nav-cta .btn.active i {
  color: #ffffff !important;
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.5));
}

.nav-cta .btn.btn-secondary {
  background: rgba(15, 23, 42, 0.6) !important;
  border: 1px solid rgba(255, 255, 255, 0.1) !important;
  color: var(--text-secondary) !important;
}

.nav-cta .btn.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
  border-color: rgba(255, 255, 255, 0.25) !important;
}

.btn-telegram {
  background: var(--gradient-telegram);
  color: #fff;
  box-shadow: 0 4px 12px rgba(34, 158, 217, 0.35);
}

.btn-telegram:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(34, 158, 217, 0.5);
  color: #fff;
}

.btn-success {
  background: var(--accent-emerald);
  color: #fff;
}

.btn-sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.85rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 0.85rem 2rem;
  font-size: 1.1rem;
}

/* Glassmorphism Cards */
.card-glass {
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.card-glass:hover {
  border-color: var(--border-glass-hover);
  box-shadow: var(--shadow-glow);
  transform: translateY(-3px);
}

/* Course Card Grid */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.75rem;
  margin-top: 2rem;
}

.course-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.course-card:hover {
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-glow);
  transform: translateY(-4px);
}

.course-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #1e293b;
}

.course-thumb-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.course-card:hover .course-thumb-wrap img {
  transform: scale(1.05);
}

.course-badge-level {
  position: absolute;
  top: 12px;
  left: 12px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(8px);
  color: #38bdf8;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.course-badge-free {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(16, 185, 129, 0.9);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
}

.course-content {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.course-cat {
  font-size: 0.8rem;
  color: var(--accent-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

.course-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-title a {
  color: #fff;
}

.course-title a:hover {
  color: var(--accent-secondary);
}

.course-desc {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 1rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 1rem;
  border-top: 1px solid var(--border-glass);
}

.instructor-brief {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.instructor-avatar-xs {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}

.instructor-name {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.course-price-tag {
  text-align: right;
}

.price-current {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.2rem;
  color: #fff;
}

.price-original {
  font-size: 0.85rem;
  text-decoration: line-through;
  color: var(--text-muted);
  margin-left: 0.35rem;
}

/* Hero Section */
.hero {
  padding: 4.5rem 0 3.5rem;
  position: relative;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 600px;
  height: 400px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.25) 0%, rgba(236, 72, 153, 0.15) 50%, transparent 70%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 840px;
  margin: 0 auto;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(99, 102, 241, 0.15);
  border: 1px solid rgba(99, 102, 241, 0.3);
  padding: 0.35rem 1rem;
  border-radius: var(--radius-full);
  color: #a5b4fc;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: 3.25rem;
  letter-spacing: -0.03em;
  margin-bottom: 1.25rem;
}

.hero-title-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.18rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2rem;
}

/* Search Bar */
.search-filter-box {
  display: flex;
  background: rgba(17, 24, 39, 0.85);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-full);
  padding: 0.4rem 0.5rem 0.4rem 1.25rem;
  box-shadow: var(--shadow-md);
  max-width: 600px;
  margin: 0 auto 2rem;
}

.search-filter-box input {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 1rem;
  width: 100%;
  outline: none;
  font-family: var(--font-body);
}

.search-filter-box input::placeholder {
  color: var(--text-muted);
}

/* Alert Messages / Toasts */
.messages-container {
  position: fixed;
  top: 80px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 400px;
}

.alert-toast {
  background: var(--bg-surface-elevated);
  border-left: 4px solid var(--accent-primary);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  color: #fff;
  box-shadow: var(--shadow-md);
  animation: slideInRight 0.3s ease;
}

.alert-toast.success { border-left-color: var(--accent-emerald); }
.alert-toast.error { border-left-color: var(--accent-rose); }
.alert-toast.warning { border-left-color: var(--accent-amber); }
.alert-toast.info { border-left-color: var(--accent-secondary); }

@keyframes slideInRight {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Form Styles */
.form-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-glass);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  max-width: 520px;
  margin: 3rem auto;
  box-shadow: var(--shadow-md);
}

.form-group {
  margin-bottom: 1.25rem;
}

.form-label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: #d1d5db;
  margin-bottom: 0.45rem;
}

.form-control {
  width: 100%;
  background: #1f2937;
  border: 1px solid #374151;
  border-radius: var(--radius-md);
  padding: 0.75rem 1rem;
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
}

.btn-google {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  background: #ffffff;
  color: #1f2937;
  border: 1px solid #e5e7eb;
  border-radius: var(--radius-md);
  padding: 0.75rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
  transition: all 0.2s ease;
}

.btn-google:hover {
  background: #f9fafb;
  color: #111827;
  border-color: #d1d5db;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
  transform: translateY(-1px);
}

/* Classroom / LMS Learning Layout */
body:has(.classroom-container) {
  overflow: hidden;
  height: 100vh;
}

body:has(.classroom-container) {
  height: 100vh !important;
  max-height: 100vh !important;
  overflow: hidden !important;
}

body:has(.classroom-container) .footer {
  display: none !important;
}

body:has(.classroom-container) main {
  flex: 1 1 0% !important;
  min-height: 0 !important;
  height: 100% !important;
  max-height: 100% !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
}

.classroom-container {
  display: flex;
  flex-direction: row;
  flex: 1 1 0%;
  min-height: 0;
  height: 100%;
  max-height: 100%;
  width: 100%;
  overflow: hidden;
  background: #080c14;
}

.classroom-main {
  flex: 1 1 0%;
  min-width: 0;
  min-height: 0;
  height: 100%;
  max-height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1.5rem 2.5rem 5rem;
  scroll-behavior: smooth;
  position: relative;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
}

.classroom-sidebar {
  width: 380px;
  min-width: 380px;
  max-width: 380px;
  flex-shrink: 0;
  min-height: 0;
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border-left: 1px solid var(--border-glass);
}

.classroom-sidebar-scroll {
  flex: 1 1 0%;
  min-height: 0;
  padding: 1rem;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior-y: contain;
}

.video-container {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.6);
  margin-bottom: 1.5rem;
}

.video-container iframe, .video-container video {
  width: 100%;
  height: 100%;
  border: none;
}

/* Classroom In-Page Tab Navigation & Discussion Q&A */
.classroom-tabs-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-glass);
  padding-bottom: 0.85rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.classroom-tab-btn {
  background: transparent;
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.55rem 1rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: var(--transition);
}

.classroom-tab-btn:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.05);
}

.classroom-tab-btn.active {
  color: #fff;
  background: rgba(99, 102, 241, 0.16);
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 0 15px rgba(99, 102, 241, 0.2);
}

.tab-badge {
  background: rgba(99, 102, 241, 0.3);
  color: #c7d2fe;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-full);
}

.btn-tab-action {
  font-size: 0.84rem;
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-glass);
  background: rgba(255, 255, 255, 0.02);
  transition: var(--transition);
  text-decoration: none;
}

.btn-tab-action:hover {
  color: #fff;
  border-color: rgba(99, 102, 241, 0.4);
  background: rgba(99, 102, 241, 0.1);
}

.filter-pill {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.9rem;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.filter-pill:hover {
  color: #fff;
  border-color: rgba(99, 102, 241, 0.4);
}

.filter-pill.active {
  background: rgba(99, 102, 241, 0.2);
  border-color: var(--accent-primary);
  color: #fff;
}

.catalog-sector-bar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding-top: 1.1rem;
  border-top: 1px solid var(--border-glass);
}

.sector-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 1rem;
  font-size: 0.82rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
  cursor: pointer;
  line-height: 1.3;
}

.sector-pill-btn.active {
  background: var(--gradient-primary);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 4px 18px rgba(99, 102, 241, 0.45);
}

.sector-pill-btn:not(.active) {
  background: rgba(31, 41, 55, 0.85);
  color: #e5e7eb;
  border: 1px solid var(--border-glass);
}

.sector-pill-btn:not(.active):hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-color: rgba(99, 102, 241, 0.4);
  transform: translateY(-1px);
}

.sector-pill-badge {
  opacity: 0.85;
  font-size: 0.8em;
  margin-left: 0.15rem;
}

.trade-sub-bar {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  flex-wrap: wrap;
  margin-top: 0.85rem;
  padding: 0.75rem 1rem;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: var(--radius-md);
}

.trade-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.32rem 0.85rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: var(--transition);
  white-space: nowrap;
  cursor: pointer;
  line-height: 1.3;
}

.trade-pill-btn.active {
  background: rgba(99, 102, 241, 0.3);
  border: 1px solid var(--accent-primary);
  color: #ffffff;
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.35);
}

.trade-pill-btn:not(.active) {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-glass);
  color: var(--text-secondary);
}

.trade-pill-btn:not(.active):hover {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
  border-color: rgba(99, 102, 241, 0.4);
}

.qa-thread-card {
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.qa-thread-card:hover {
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: 0 4px 20px rgba(0,0,0,0.3);
}

.qa-thread-highlight {
  animation: threadFlashHighlight 2.5s ease-out;
}

@keyframes threadFlashHighlight {
  0% { box-shadow: 0 0 0 4px var(--accent-primary); border-color: var(--accent-primary); }
  100% { box-shadow: none; border-color: rgba(255,255,255,0.08); }
}

/* Telegram Live Box Component */
.telegram-live-box {
  background: linear-gradient(135deg, rgba(34, 158, 217, 0.15) 0%, rgba(15, 23, 42, 0.9) 100%);
  border: 1px solid rgba(34, 158, 217, 0.35);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  text-align: center;
  margin-bottom: 2rem;
}

.live-pulse-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(244, 63, 94, 0.2);
  border: 1px solid var(--accent-rose);
  color: var(--accent-rose);
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.live-pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-rose);
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 10px rgba(244, 63, 94, 0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(244, 63, 94, 0); }
}

/* Progress bar */
.progress-bar-container {
  background: #374151;
  border-radius: var(--radius-full);
  height: 8px;
  overflow: hidden;
  margin: 0.5rem 0;
}

.progress-bar-fill {
  background: var(--gradient-primary);
  height: 100%;
  transition: width 0.4s ease;
}

/* Footer */
.footer {
  margin-top: auto;
  background: #090d16;
  border-top: 1px solid var(--border-glass);
  padding: 3.5rem 0 2rem;
  color: var(--text-secondary);
}

.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

/* Responsive adjustments */
@media (max-width: 992px) {
  body:has(.classroom-container) {
    overflow: auto;
    height: auto;
  }
  body:has(.classroom-container) .footer {
    display: block !important;
  }
  .classroom-container {
    grid-template-columns: 1fr;
    height: auto;
    max-height: none;
    overflow: visible;
  }
  .classroom-main {
    height: auto;
    overflow-y: visible;
    padding: 1rem;
  }
  .classroom-sidebar {
    height: auto;
    overflow-y: visible;
    border-left: none;
    border-top: 1px solid var(--border-glass);
  }
  .video-container {
    position: sticky;
    top: 58px;
    z-index: 50;
  }
  .hero-title {
    font-size: 2.4rem;
  }
  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
  }
  .footer-inner {
    grid-template-columns: 1fr;
  }
  .hero-title {
    font-size: 2rem;
  }
}

/* ==========================================================================
   Markdown Body & Tech Documentation Typography
   ========================================================================== */

.markdown-body {
  color: #e2e8f0;
  font-size: 1.05rem;
  line-height: 1.85;
  word-break: break-word;
}

.markdown-body h1,
.markdown-body h2,
.markdown-body h3,
.markdown-body h4,
.markdown-body h5,
.markdown-body h6 {
  color: #ffffff;
  font-family: var(--font-heading);
  font-weight: 700;
  margin-top: 2.2rem;
  margin-bottom: 0.9rem;
  line-height: 1.35;
}

.markdown-body h1:first-child,
.markdown-body h2:first-child,
.markdown-body h3:first-child {
  margin-top: 0;
}

.markdown-body h1 {
  font-size: 2.2rem;
  letter-spacing: -0.025em;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid var(--border-glass);
}

.markdown-body h2 {
  font-size: 1.65rem;
  letter-spacing: -0.02em;
  color: #f1f5f9;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.markdown-body h2::before {
  content: "";
  display: inline-block;
  width: 4px;
  height: 1.35rem;
  background: var(--accent-primary);
  border-radius: 2px;
}

.markdown-body h3 {
  font-size: 1.3rem;
  color: #c7d2fe;
}

.markdown-body h4 {
  font-size: 1.1rem;
  color: #94a3b8;
}

.markdown-body p {
  margin-bottom: 1.35rem;
}

.markdown-body strong {
  font-weight: 700;
  color: #ffffff;
}

.markdown-body em {
  font-style: italic;
  color: #cbd5e1;
}

.markdown-body a {
  color: #818cf8;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.15s ease;
}

.markdown-body a:hover {
  color: #a5b4fc;
}

/* Inline Code */
.markdown-body code:not(pre code) {
  background: rgba(99, 102, 241, 0.15);
  color: #c7d2fe;
  padding: 0.2rem 0.45rem;
  border-radius: 5px;
  font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
  font-size: 0.88em;
  border: 1px solid rgba(99, 102, 241, 0.25);
}

/* Code Blocks & Wrappers */
.code-block-wrapper {
  margin: 1.75rem 0;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: #0b1120;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}

.code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.55rem 1rem;
  background: #111827;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.code-header .code-lang {
  font-family: var(--font-heading);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.btn-copy-code {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
}

.btn-copy-code:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

.btn-copy-code.copied {
  border-color: rgba(52, 211, 153, 0.5);
  color: #34d399;
}

.markdown-body pre {
  margin: 0 !important;
  padding: 1.25rem 1.4rem !important;
  background: #0b1120 !important;
  overflow-x: auto;
  font-size: 0.92rem;
  line-height: 1.65;
}

.markdown-body pre code {
  font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
  background: transparent !important;
  padding: 0 !important;
}

/* Tables */
.markdown-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.75rem 0;
  font-size: 0.93rem;
  background: rgba(15, 23, 42, 0.65);
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid var(--border-glass);
}

.markdown-body table th {
  padding: 0.85rem 1.15rem;
  background: rgba(99, 102, 241, 0.16);
  color: #c7d2fe;
  font-weight: 700;
  text-align: left;
  border-bottom: 1px solid var(--border-glass);
}

.markdown-body table td {
  padding: 0.85rem 1.15rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  color: #e2e8f0;
}

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

.markdown-body table tr:hover td {
  background: rgba(255, 255, 255, 0.025);
}

/* Lists */
.markdown-body ul,
.markdown-body ol {
  margin: 1.25rem 0;
  padding-left: 1.6rem;
}

.markdown-body li {
  margin-bottom: 0.55rem;
}

.markdown-body ul li {
  list-style-type: disc;
}

.markdown-body ol li {
  list-style-type: decimal;
}

/* Task Lists */
.markdown-body ul:has(.task-checkbox-wrap) {
  list-style-type: none;
  padding-left: 0.2rem;
}

.markdown-body li:has(.task-checkbox-wrap) {
  list-style-type: none;
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
}

.task-checkbox-wrap {
  display: inline-flex;
  align-items: center;
  margin-top: 0.35rem;
}

.task-checkbox {
  width: 17px;
  height: 17px;
  border-radius: 4px;
  accent-color: #6366f1;
  cursor: default;
}

/* Blockquotes & Callouts */
.markdown-body blockquote {
  border-left: 4px solid var(--accent-primary);
  background: rgba(99, 102, 241, 0.08);
  padding: 1rem 1.35rem;
  border-radius: 0 8px 8px 0;
  margin: 1.75rem 0;
  color: #cbd5e1;
}

.markdown-body hr {
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
  margin: 2.5rem 0;
}

.markdown-body img {
  max-width: 100%;
  border-radius: 8px;
  border: 1px solid var(--border-glass);
  margin: 1.5rem 0;
}

/* Markdown Authoring Suite for Instructors */
.md-editor-container textarea.form-control {
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
}

.btn-md-tab {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.3rem 0.75rem;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: all 0.15s ease;
}

.btn-md-tab:hover {
  color: #fff;
}

.btn-md-tab.active {
  background: var(--accent-primary);
  color: #fff;
}

.btn-md-tool {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  font-size: 0.78rem;
  padding: 0.25rem 0.55rem;
  border-radius: 4px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: all 0.15s ease;
  user-select: none;
}

.btn-md-tool:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.2);
}

.toolbar-sep {
  width: 1px;
  height: 18px;
  background: rgba(255, 255, 255, 0.12);
  margin: 0 0.25rem;
  align-self: center;
}

/* Course Detail Unified Layout */
.course-detail-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "header sidebar"
    "main   sidebar";
  column-gap: 3rem;
  row-gap: 2.25rem;
  align-items: start;
}

.course-header-area {
  grid-area: header;
}

.course-main-area {
  grid-area: main;
  display: flex;
  flex-direction: column;
  gap: 2.25rem;
  min-width: 0;
}

.course-sidebar-area {
  grid-area: sidebar;
  position: -webkit-sticky;
  position: sticky;
  top: 90px;
  z-index: 25;
}

@media (max-width: 992px) {
  .course-detail-layout {
    grid-template-columns: 1fr;
    grid-template-areas:
      "header"
      "sidebar"
      "main";
    row-gap: 1.75rem;
  }

  .course-sidebar-area {
    position: static;
  }
}




