/* ============================================
   Blue English Centre — Design System
   Colors: Blue (#1565C0, #1E88E5) + White
   Font: Inter (Google Fonts)
   ============================================ */

/* Google Fonts loaded via HTML <link> tag to avoid CSP issues */

/* ---- CSS Variables ---- */
:root {
  /* Primary palette */
  --primary: #1565C0;
  --primary-light: #1E88E5;
  --primary-dark: #0D47A1;
  --primary-50: #E3F2FD;
  --primary-100: #BBDEFB;
  --primary-200: #90CAF9;
  --primary-gradient: linear-gradient(135deg, #1565C0 0%, #1E88E5 50%, #42A5F5 100%);
  --primary-gradient-hover: linear-gradient(135deg, #0D47A1 0%, #1565C0 50%, #1E88E5 100%);

  /* Neutrals */
  --white: #FFFFFF;
  --bg-light: #F5F7FA;
  --bg-card: #FFFFFF;
  --text-primary: #1A1A2E;
  --text-secondary: #4A5568;
  --text-muted: #718096;
  --border: #E2E8F0;
  --border-light: #EDF2F7;

  /* Accent */
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  --info: #3B82F6;

  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(21, 101, 192, 0.08);
  --shadow-md: 0 4px 14px rgba(21, 101, 192, 0.1);
  --shadow-lg: 0 10px 40px rgba(21, 101, 192, 0.12);
  --shadow-xl: 0 20px 60px rgba(21, 101, 192, 0.15);
  --shadow-glow: 0 0 30px rgba(30, 136, 229, 0.3);

  /* Glass */
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.2);

  /* Typography */
  --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Spacing */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 50%;

  /* Transitions */
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: all 0.15s ease;
}

/* ---- Reset ---- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font);
  background: var(--bg-light);
  color: var(--text-primary);
  line-height: 1.7;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

img {
  max-width: 100%;
  display: block;
}

ul, ol { list-style: none; }

input, textarea, select, button {
  font-family: var(--font);
  font-size: 1rem;
  border: none;
  outline: none;
}

/* ---- Navbar ---- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-light);
  transition: var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
}

.navbar-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--primary);
}

.navbar-brand .logo-icon {
  width: 42px;
  height: 42px;
  background: var(--primary-gradient);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: 900;
  font-size: 1.1rem;
  box-shadow: var(--shadow-md);
}

.navbar-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-link {
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-secondary);
  transition: var(--transition);
  position: relative;
}

.nav-link:hover {
  color: var(--primary);
  background: var(--primary-50);
}

.nav-link.active {
  color: var(--primary);
  font-weight: 600;
}

.nav-btn {
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: var(--transition);
}

.nav-btn-outline {
  border: 2px solid var(--primary);
  color: var(--primary);
  background: transparent;
}

.nav-btn-outline:hover {
  background: var(--primary);
  color: white;
}

.nav-btn-primary {
  background: var(--primary-gradient);
  color: white;
  border: none;
  box-shadow: var(--shadow-sm);
}

.nav-btn-primary:hover {
  box-shadow: var(--shadow-glow);
  transform: translateY(-1px);
}

.navbar-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  color: var(--text-primary);
}

.navbar-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: currentColor;
  margin: 5px 0;
  transition: var(--transition);
  border-radius: 2px;
}

/* ---- Hero Section ---- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, #0D47A1 0%, #1565C0 30%, #1E88E5 60%, #42A5F5 100%);
  position: relative;
  overflow: hidden;
  padding-top: 72px;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 800px;
  height: 800px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  animation: float 8s ease-in-out infinite;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -10%;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  animation: float 10s ease-in-out infinite reverse;
}

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-30px) rotate(5deg); }
}

.hero-content {
  max-width: 1280px;
  margin: 0 auto;
  padding: 40px 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-text h1 {
  font-size: 3.8rem;
  font-weight: 900;
  color: white;
  line-height: 1.1;
  margin-bottom: 24px;
}

.hero-text h1 span {
  display: block;
  background: linear-gradient(90deg, #90CAF9, #E3F2FD);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-text p {
  font-size: 1.2rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.8;
  margin-bottom: 40px;
  max-width: 500px;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 32px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  position: relative;
  overflow: hidden;
}

.btn-white {
  background: white;
  color: var(--primary);
  box-shadow: var(--shadow-lg);
}

.btn-white:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-xl);
}

.btn-outline-white {
  background: transparent;
  color: white;
  border: 2px solid rgba(255, 255, 255, 0.5);
}

.btn-outline-white:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: white;
}

.btn-primary {
  background: var(--primary-gradient);
  color: white;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  box-shadow: var(--shadow-glow);
  transform: translateY(-2px);
}

.btn-lg {
  padding: 16px 40px;
  font-size: 1.1rem;
}

.btn-sm {
  padding: 8px 20px;
  font-size: 0.875rem;
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.btn-danger:hover {
  background: #DC2626;
}

.btn-success {
  background: var(--success);
  color: white;
}

.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-card {
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-xl);
  padding: 48px;
  text-align: center;
  color: white;
  animation: slideUp 0.8s ease-out;
  width: 100%;
  max-width: 420px;
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero-card .stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 32px;
}

.stat-item {
  padding: 16px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.1);
}

.stat-item .number {
  font-size: 2.2rem;
  font-weight: 900;
  display: block;
}

.stat-item .label {
  font-size: 0.85rem;
  opacity: 0.8;
  margin-top: 4px;
}

/* ---- Section styles ---- */
.section {
  padding: 100px 24px;
}

.section-dark {
  background: linear-gradient(135deg, #0D47A1 0%, #1565C0 100%);
  color: white;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
}

.section-header {
  text-align: center;
  margin-bottom: 60px;
}

.section-header .badge {
  display: inline-block;
  padding: 6px 16px;
  background: var(--primary-50);
  color: var(--primary);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 16px;
}

.section-dark .section-header .badge {
  background: rgba(255, 255, 255, 0.15);
  color: white;
}

.section-header h2 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.section-dark .section-header h2 {
  color: white;
}

.section-header p {
  font-size: 1.1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto;
}

.section-dark .section-header p {
  color: rgba(255, 255, 255, 0.8);
}

/* ---- Course Cards ---- */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.course-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--border-light);
}

.course-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

.course-card-image {
  height: 200px;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.course-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.course-card-image .level-badge {
  position: absolute;
  top: 16px;
  right: 16px;
  padding: 4px 12px;
  background: rgba(255, 255, 255, 0.95);
  color: var(--primary);
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 700;
}

.course-card-body {
  padding: 24px;
}

.course-card-body h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.course-card-body p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.course-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
}

.course-price {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary);
}

.course-price small {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

.course-info {
  display: flex;
  gap: 16px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---- Features ---- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 28px;
}

.feature-card {
  padding: 36px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  transition: var(--transition);
  text-align: center;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-200);
}

.feature-icon {
  width: 64px;
  height: 64px;
  border-radius: var(--radius-md);
  background: var(--primary-50);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 1.8rem;
}

.feature-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---- Forms ---- */
.form-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-light);
  padding: 100px 24px;
}

.form-card {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 48px;
  width: 100%;
  max-width: 480px;
  border: 1px solid var(--border-light);
}

.form-card h1 {
  font-size: 1.8rem;
  font-weight: 800;
  text-align: center;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.form-card .form-subtitle {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 32px;
  font-size: 0.95rem;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 8px;
  color: var(--text-primary);
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  transition: var(--transition);
  background: var(--bg-light);
}

.form-control:focus {
  border-color: var(--primary-light);
  background: white;
  box-shadow: 0 0 0 4px rgba(30, 136, 229, 0.1);
}

.form-control::placeholder {
  color: var(--text-muted);
}

select.form-control {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%234A5568' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

.form-footer {
  text-align: center;
  margin-top: 24px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.form-footer a {
  color: var(--primary);
  font-weight: 600;
}

.form-footer a:hover {
  text-decoration: underline;
}

/* ---- Alerts / Toast ---- */
.alert {
  padding: 14px 20px;
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 10px;
}

.alert-error {
  background: #FEF2F2;
  color: #991B1B;
  border: 1px solid #FECACA;
}

.alert-success {
  background: #F0FDF4;
  color: #166534;
  border: 1px solid #BBF7D0;
}

.alert-info {
  background: var(--primary-50);
  color: var(--primary-dark);
  border: 1px solid var(--primary-100);
}

.toast {
  position: fixed;
  top: 90px;
  right: 24px;
  padding: 16px 24px;
  border-radius: var(--radius-md);
  color: white;
  font-weight: 600;
  z-index: 10000;
  animation: slideInRight 0.3s ease-out;
  box-shadow: var(--shadow-lg);
}

.toast-success { background: var(--success); }
.toast-error { background: var(--danger); }
.toast-info { background: var(--primary); }

@keyframes slideInRight {
  from { opacity: 0; transform: translateX(100px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ---- Dashboard ---- */
.dashboard {
  padding-top: 100px;
  padding-bottom: 60px;
  min-height: 100vh;
}

.dashboard-header {
  margin-bottom: 40px;
}

.dashboard-header h1 {
  font-size: 2rem;
  font-weight: 800;
}

.dashboard-header p {
  color: var(--text-muted);
  margin-top: 8px;
}

.stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.stat-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.stat-card .stat-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 8px;
}

.stat-card .stat-value {
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary);
}

/* ---- Tables ---- */
.table-container {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.table-container table {
  width: 100%;
  border-collapse: collapse;
}

.table-container th {
  background: var(--primary-50);
  padding: 14px 20px;
  text-align: left;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--primary-dark);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.table-container td {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.9rem;
}

.table-container tr:last-child td {
  border-bottom: none;
}

.table-container tr:hover td {
  background: var(--bg-light);
}

/* ---- Status badges ---- */
.status-badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
}

.status-completed { background: #D1FAE5; color: #065F46; }
.status-pending { background: #FEF3C7; color: #92400E; }
.status-failed { background: #FEE2E2; color: #991B1B; }
.status-published { background: #D1FAE5; color: #065F46; }
.status-draft { background: #E5E7EB; color: #374151; }

/* ---- Announcements ---- */
.announcement-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.announcement-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.announcement-card:hover {
  box-shadow: var(--shadow-md);
}

.announcement-card.pinned {
  border-left: 4px solid var(--primary);
  background: var(--primary-50);
}

.announcement-card h3 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.announcement-card .announcement-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 12px;
  display: flex;
  gap: 16px;
}

.announcement-card p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* ---- Admin Panel ---- */
.admin-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
  padding-top: 72px;
}

.admin-sidebar {
  background: white;
  border-right: 1px solid var(--border-light);
  padding: 24px;
}

.admin-sidebar .sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-sidebar .sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-weight: 500;
  color: var(--text-secondary);
  transition: var(--transition);
  cursor: pointer;
}

.admin-sidebar .sidebar-link:hover {
  background: var(--primary-50);
  color: var(--primary);
}

.admin-sidebar .sidebar-link.active {
  background: var(--primary);
  color: white;
}

.admin-content {
  padding: 32px;
  overflow-y: auto;
}

.admin-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 24px;
}

/* ---- Modal ---- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.modal {
  background: white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
  animation: scaleIn 0.3s ease;
}

@keyframes scaleIn {
  from { transform: scale(0.95); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal-header {
  padding: 24px 28px;
  border-bottom: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-header h3 {
  font-size: 1.2rem;
  font-weight: 700;
}

.modal-close {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-light);
  cursor: pointer;
  transition: var(--transition);
  border: none;
  font-size: 1.2rem;
}

.modal-close:hover {
  background: var(--danger);
  color: white;
}

.modal-body {
  padding: 28px;
}

.modal-footer {
  padding: 20px 28px;
  border-top: 1px solid var(--border-light);
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

/* ---- Footer ---- */
.footer {
  background: var(--text-primary);
  color: rgba(255, 255, 255, 0.7);
  padding: 60px 24px 30px;
}

.footer-grid {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand {
  font-size: 1.3rem;
  font-weight: 800;
  color: white;
  margin-bottom: 16px;
}

.footer-brand span {
  color: var(--primary-200);
}

.footer h4 {
  color: white;
  font-weight: 700;
  margin-bottom: 16px;
  font-size: 1rem;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  transition: var(--transition);
}

.footer-links a:hover {
  color: white;
  padding-left: 4px;
}

.footer-bottom {
  max-width: 1280px;
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  font-size: 0.85rem;
}

/* ---- Course Detail ---- */
.course-detail {
  padding-top: 100px;
  padding-bottom: 60px;
}

.course-detail-header {
  background: var(--primary-gradient);
  padding: 60px 24px;
  color: white;
  border-radius: var(--radius-xl);
  margin-bottom: 40px;
}

.course-detail-header h1 {
  font-size: 2.2rem;
  font-weight: 800;
  margin-bottom: 16px;
}

.course-detail-grid {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 32px;
}

.course-detail-content {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 32px;
  border: 1px solid var(--border-light);
}

.course-detail-sidebar {
  position: sticky;
  top: 100px;
  align-self: start;
}

.course-purchase-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
  text-align: center;
}

.course-purchase-card .big-price {
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--primary);
  margin-bottom: 20px;
}

.course-purchase-card .btn {
  width: 100%;
  margin-bottom: 12px;
}

/* ---- Page Header ---- */
.page-header {
  background: var(--primary-gradient);
  padding: 120px 24px 60px;
  text-align: center;
  color: white;
}

.page-header h1 {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.page-header p {
  font-size: 1.1rem;
  opacity: 0.85;
}

/* ---- Filter Bar ---- */
.filter-bar {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  padding: 24px 0;
}

.filter-bar select,
.filter-bar input {
  padding: 10px 16px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  font-size: 0.9rem;
  transition: var(--transition);
}

.filter-bar select:focus,
.filter-bar input:focus {
  border-color: var(--primary-light);
}

/* ---- Tabs ---- */
.tabs {
  display: flex;
  gap: 4px;
  border-bottom: 2px solid var(--border-light);
  margin-bottom: 24px;
}

.tab {
  padding: 12px 20px;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-muted);
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: var(--transition);
  background: none;
  border-top: none;
  border-left: none;
  border-right: none;
}

.tab:hover {
  color: var(--primary);
}

.tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
}

/* ---- Loading ---- */
.loader {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px;
}

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ---- Empty State ---- */
.empty-state {
  text-align: center;
  padding: 60px 24px;
  color: var(--text-muted);
}

.empty-state .empty-icon {
  font-size: 3rem;
  margin-bottom: 16px;
  opacity: 0.5;
}

.empty-state h3 {
  font-size: 1.3rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* ---- Responsive ---- */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-text p {
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .hero-buttons {
    justify-content: center;
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .admin-layout {
    grid-template-columns: 1fr;
  }

  .admin-sidebar {
    border-right: none;
    border-bottom: 1px solid var(--border-light);
  }

  .admin-sidebar .sidebar-nav {
    flex-direction: row;
    overflow-x: auto;
  }

  .course-detail-grid {
    grid-template-columns: 1fr;
  }

  .course-detail-sidebar {
    position: static;
  }
}

@media (max-width: 768px) {
  .hero-text h1 {
    font-size: 2.4rem;
  }

  .section-header h2 {
    font-size: 1.8rem;
  }

  .navbar-nav {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    padding: 20px;
    box-shadow: var(--shadow-lg);
    border-top: 1px solid var(--border-light);
  }

  .navbar-nav.open {
    display: flex;
  }

  .navbar-toggle {
    display: block;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .form-card {
    padding: 32px 24px;
  }

  .stats-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .hero-text h1 {
    font-size: 1.9rem;
  }

  .hero-buttons {
    flex-direction: column;
  }

  .stats-row {
    grid-template-columns: 1fr;
  }

  .courses-grid {
    grid-template-columns: 1fr;
  }
}
