/* Bright Horizons Academy - Main Stylesheet */

/* ========================================
   CSS Variables (Design Tokens)
   ======================================== */
:root {
  /* Colors */
  --primary: #1E3A5F;
  --secondary: #4A90A4;
  --accent: #F5A623;
  --success: #27AE60;
  --warning: #E67E22;
  --error: #E74C3C;
  --bg-primary: #FAFBFC;
  --bg-secondary: #F0F4F8;
  --text-primary: #2C3E50;
  --text-secondary: #7F8C8D;
  --card-bg: #FFFFFF;
  --border-color: #E1E8ED;
  
  /* Typography */
  --font-heading: 'Playfair Display', serif;
  --font-body: 'Source Sans Pro', sans-serif;
  --font-accent: 'Caveat', cursive;
  
  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.1);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07), 0 1px 3px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.1), 0 6px 10px rgba(0,0,0,0.08);
  --shadow-xl: 0 20px 40px rgba(0,0,0,0.15);
  
  /* Transitions */
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;
  
  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 20px;
  --radius-full: 50%;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-md);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin-bottom: var(--space-md);
}

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

a:hover {
  color: var(--primary);
}

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

/* ========================================
   Utility Classes
   ======================================== */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--space-lg);
}

.container-sm {
  max-width: 800px;
}

.container-narrow {
  max-width: 600px;
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-accent { color: var(--accent); }
.text-success { color: var(--success); }
.text-warning { color: var(--warning); }
.text-error { color: var(--error); }
.text-muted { color: var(--text-secondary); }

.bg-primary { background-color: var(--primary); color: white; }
.bg-secondary { background-color: var(--bg-secondary); }
.bg-gradient {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
}

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }
.mt-xl { margin-top: var(--space-xl); }
.mt-2xl { margin-top: var(--space-2xl); }

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }
.mb-xl { margin-bottom: var(--space-xl); }
.mb-2xl { margin-bottom: var(--space-2xl); }

.d-none { display: none !important; }
.d-block { display: block !important; }
.d-flex { display: flex !important; }
.d-grid { display: grid !important; }

.flex-column { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.align-center { align-items: center; }
.align-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-sm { gap: var(--space-sm); }
.gap-md { gap: var(--space-md); }
.gap-lg { gap: var(--space-lg); }

.w-100 { width: 100%; }

/* ========================================
   Navigation
   ======================================== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.navbar.scrolled {
  box-shadow: var(--shadow-md);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-accent);
  font-size: 1.75rem;
  color: var(--primary);
  font-weight: 700;
}

.nav-logo svg {
  width: 40px;
  height: 40px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: var(--space-xl);
  list-style: none;
}

.nav-link {
  position: relative;
  color: var(--text-primary);
  font-weight: 600;
  padding: var(--space-sm) 0;
  transition: var(--transition);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: var(--space-sm);
}

.nav-toggle span {
  display: block;
  width: 25px;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
}

/* Mobile Navigation */
@media (max-width: 768px) {
  .nav-toggle {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    background: white;
    flex-direction: column;
    padding: var(--space-lg);
    gap: var(--space-md);
    box-shadow: var(--shadow-lg);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
  }
  
  .nav-menu.active {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }
}

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: 12px 24px;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background: var(--primary);
  color: white;
}

.btn-primary:hover:not(:disabled) {
  background: #163049;
  box-shadow: var(--shadow-md);
}

.btn-secondary {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-secondary:hover:not(:disabled) {
  background: var(--primary);
  color: white;
}

.btn-accent {
  background: var(--accent);
  color: white;
}

.btn-accent:hover:not(:disabled) {
  background: #d4920f;
  box-shadow: var(--shadow-md);
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-success:hover:not(:disabled) {
  background: #1e8e4d;
}

.btn-outline {
  background: transparent;
  border-color: var(--border-color);
  color: var(--text-primary);
}

.btn-outline:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 16px 32px;
  font-size: 1.125rem;
}

.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-full);
}

.btn-icon.btn-sm {
  width: 32px;
  height: 32px;
}

/* ========================================
   Cards
   ======================================== */
.card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: var(--space-lg);
  transition: var(--transition);
}

.card:hover {
  box-shadow: var(--shadow-lg);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--border-color);
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 0;
}

.card-body {
  padding: 0;
}

.card-footer {
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
  border-top: 1px solid var(--border-color);
}

.card-accent {
  border-top: 4px solid var(--accent);
}

.card-success {
  border-top: 4px solid var(--success);
}

.card-primary {
  border-top: 4px solid var(--primary);
}

.card-interactive {
  cursor: pointer;
}

.card-interactive:hover {
  transform: translateY(-4px);
}

/* ========================================
   Forms
   ======================================== */
.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  display: block;
  font-weight: 600;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.form-label.required::after {
  content: '*';
  color: var(--error);
  margin-left: 4px;
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--text-primary);
  background: var(--card-bg);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(74, 144, 164, 0.15);
}

.form-control:disabled {
  background: var(--bg-secondary);
  cursor: not-allowed;
}

.form-control.error {
  border-color: var(--error);
}

.form-control.success {
  border-color: var(--success);
}

.form-control::placeholder {
  color: var(--text-secondary);
}

textarea.form-control {
  min-height: 120px;
  resize: vertical;
}

select.form-control {
  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='%237F8C8D' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

.form-hint {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: var(--space-xs);
}

.form-error {
  font-size: 0.875rem;
  color: var(--error);
  margin-top: var(--space-xs);
}

.form-checkbox,
.form-radio {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  cursor: pointer;
}

.form-checkbox input,
.form-radio input {
  width: 20px;
  height: 20px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* Floating Label */
.form-floating {
  position: relative;
}

.form-floating .form-control {
  padding-top: 20px;
}

.form-floating label {
  position: absolute;
  top: 50%;
  left: 16px;
  transform: translateY(-50%);
  color: var(--text-secondary);
  pointer-events: none;
  transition: var(--transition);
}

.form-floating .form-control:focus ~ label,
.form-floating .form-control:not(:placeholder-shown) ~ label {
  top: 8px;
  font-size: 0.75rem;
  color: var(--secondary);
}

/* Form Row */
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-lg);
}

/* ========================================
   File Upload
   ======================================== */
.file-upload {
  position: relative;
}

.file-upload-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-2xl);
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--bg-secondary);
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.file-upload-zone:hover,
.file-upload-zone.dragover {
  border-color: var(--secondary);
  background: rgba(74, 144, 164, 0.05);
}

.file-upload-zone svg {
  width: 48px;
  height: 48px;
  color: var(--text-secondary);
  margin-bottom: var(--space-md);
}

.file-upload-zone p {
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.file-upload-zone small {
  color: var(--text-secondary);
}

.file-upload input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.file-list {
  margin-top: var(--space-md);
}

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-sm) var(--space-md);
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-sm);
}

.file-item-info {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.file-item-icon {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary);
  color: white;
  border-radius: var(--radius-sm);
}

.file-item-name {
  font-weight: 600;
}

.file-item-size {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.file-item-remove {
  background: none;
  border: none;
  color: var(--error);
  cursor: pointer;
  padding: var(--space-xs);
}

/* ========================================
   Progress Indicators
   ======================================== */
.progress {
  height: 8px;
  background: var(--bg-secondary);
  border-radius: 10px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--secondary) 0%, var(--success) 100%);
  border-radius: 10px;
  transition: width 0.5s ease;
}

.progress-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-xs);
  font-size: 0.875rem;
}

.progress-circle {
  position: relative;
  width: 80px;
  height: 80px;
}

.progress-circle svg {
  transform: rotate(-90deg);
}

.progress-circle-bg {
  fill: none;
  stroke: var(--bg-secondary);
  stroke-width: 8;
}

.progress-circle-fill {
  fill: none;
  stroke: var(--success);
  stroke-width: 8;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.5s ease;
}

.progress-circle-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-weight: 700;
  font-size: 1.125rem;
}

/* ========================================
   Badges
   ======================================== */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.badge-primary {
  background: rgba(30, 58, 95, 0.1);
  color: var(--primary);
}

.badge-success {
  background: rgba(39, 174, 96, 0.1);
  color: var(--success);
}

.badge-warning {
  background: rgba(230, 126, 34, 0.1);
  color: var(--warning);
}

.badge-error {
  background: rgba(231, 76, 60, 0.1);
  color: var(--error);
}

.badge-accent {
  background: rgba(245, 166, 35, 0.1);
  color: var(--accent);
}

/* ========================================
   Tables
   ======================================== */
.table-responsive {
  overflow-x: auto;
}

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

.table th,
.table td {
  padding: var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.table th {
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg-secondary);
}

.table tbody tr:hover {
  background: var(--bg-secondary);
}

.table-striped tbody tr:nth-child(even) {
  background: var(--bg-secondary);
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: 70px;
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-size: 3.5rem;
  line-height: 1.1;
  margin-bottom: var(--space-lg);
}

.hero-title span {
  color: var(--secondary);
}

.hero-subtitle {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-xl);
  max-width: 600px;
}

.hero-buttons {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.hero-image {
  position: relative;
}

.hero-image img {
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
}

.hero-shapes {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.hero-shapes::before {
  content: '';
  position: absolute;
  top: 10%;
  right: -10%;
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, rgba(74, 144, 164, 0.15) 0%, transparent 70%);
  border-radius: var(--radius-full);
}

.hero-shapes::after {
  content: '';
  position: absolute;
  bottom: 10%;
  left: -5%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(245, 166, 35, 0.1) 0%, transparent 70%);
  border-radius: var(--radius-full);
}

@media (max-width: 992px) {
  .hero {
    text-align: center;
    padding-top: 120px;
  }
  
  .hero-title {
    font-size: 2.5rem;
  }
  
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
  
  .hero-buttons {
    justify-content: center;
  }
  
  .hero-image {
    margin-top: var(--space-2xl);
  }
}

/* ========================================
   Features Section
   ======================================== */
.features {
  padding: var(--space-3xl) 0;
  background: var(--bg-secondary);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
}

.feature-card {
  text-align: center;
  padding: var(--space-xl);
}

.feature-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--space-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  border-radius: var(--radius-full);
  color: white;
}

.feature-icon svg {
  width: 36px;
  height: 36px;
}

.feature-title {
  margin-bottom: var(--space-md);
}

/* ========================================
   Auth Pages
   ======================================== */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-2xl) var(--space-lg);
  background: linear-gradient(135deg, var(--bg-secondary) 0%, var(--bg-primary) 100%);
}

.auth-container {
  width: 100%;
  max-width: 450px;
}

.auth-card {
  background: var(--card-bg);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: var(--space-2xl);
}

.auth-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.auth-logo {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-accent);
  font-size: 1.75rem;
  color: var(--primary);
  margin-bottom: var(--space-lg);
}

.auth-title {
  margin-bottom: var(--space-sm);
}

.auth-subtitle {
  color: var(--text-secondary);
  margin-bottom: 0;
}

.auth-form .form-group {
  margin-bottom: var(--space-lg);
}

.auth-footer {
  text-align: center;
  margin-top: var(--space-lg);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-color);
}

.auth-footer p {
  margin-bottom: 0;
  color: var(--text-secondary);
}

.password-toggle {
  position: relative;
}

.password-toggle .toggle-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--text-secondary);
  cursor: pointer;
  padding: var(--space-xs);
}

.password-toggle .form-control {
  padding-right: 48px;
}

/* ========================================
   Dashboard
   ======================================== */
.dashboard {
  min-height: 100vh;
  padding-top: 70px;
  background: var(--bg-secondary);
}

.dashboard-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: calc(100vh - 70px);
}

.dashboard-sidebar {
  background: white;
  padding: var(--space-lg);
  border-right: 1px solid var(--border-color);
  position: sticky;
  top: 70px;
  height: calc(100vh - 70px);
  overflow-y: auto;
}

.sidebar-user {
  text-align: center;
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--border-color);
  margin-bottom: var(--space-lg);
}

.sidebar-avatar {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 2rem;
  font-weight: 700;
  margin: 0 auto var(--space-md);
}

.sidebar-name {
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.sidebar-role {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.sidebar-menu {
  list-style: none;
}

.sidebar-menu-item {
  margin-bottom: var(--space-xs);
}

.sidebar-menu-link {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  transition: var(--transition);
}

.sidebar-menu-link:hover,
.sidebar-menu-link.active {
  background: var(--bg-secondary);
  color: var(--primary);
}

.sidebar-menu-link.active {
  border-left: 3px solid var(--accent);
}

.sidebar-menu-link svg {
  width: 20px;
  height: 20px;
}

.dashboard-content {
  padding: var(--space-xl);
}

.dashboard-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
  gap: var(--space-md);
}

.dashboard-title {
  margin-bottom: 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.stat-card {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.stat-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
}

.stat-icon svg {
  width: 24px;
  height: 24px;
}

.stat-icon.primary {
  background: rgba(30, 58, 95, 0.1);
  color: var(--primary);
}

.stat-icon.success {
  background: rgba(39, 174, 96, 0.1);
  color: var(--success);
}

.stat-icon.accent {
  background: rgba(245, 166, 35, 0.1);
  color: var(--accent);
}

.stat-icon.secondary {
  background: rgba(74, 144, 164, 0.1);
  color: var(--secondary);
}

.stat-value {
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1;
  margin-bottom: var(--space-xs);
}

.stat-label {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: var(--space-xl);
}

.activity-list {
  list-style: none;
}

.activity-item {
  display: flex;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--border-color);
}

.activity-item:last-child {
  border-bottom: none;
}

.activity-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.activity-content {
  flex: 1;
}

.activity-title {
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.activity-time {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

@media (max-width: 992px) {
  .dashboard-layout {
    grid-template-columns: 1fr;
  }
  
  .dashboard-sidebar {
    position: fixed;
    left: -280px;
    width: 280px;
    z-index: 100;
    transition: var(--transition);
  }
  
  .dashboard-sidebar.active {
    left: 0;
  }
  
  .dashboard-content {
    padding: var(--space-lg);
  }
  
  .dashboard-grid {
    grid-template-columns: 1fr;
  }
}

/* ========================================
   Learning Portal
   ======================================== */
.portal {
  min-height: 100vh;
  padding-top: 70px;
  background: var(--bg-secondary);
}

.portal-header {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  padding: var(--space-2xl) 0;
  color: white;
}

.portal-title {
  color: white;
  margin-bottom: var(--space-md);
}

.portal-subtitle {
  opacity: 0.9;
  margin-bottom: var(--space-xl);
}

.grade-selector {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.grade-btn {
  padding: var(--space-sm) var(--space-lg);
  background: rgba(255, 255, 255, 0.2);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.grade-btn:hover,
.grade-btn.active {
  background: white;
  color: var(--primary);
}

.portal-content {
  padding: var(--space-xl) 0;
}

.subjects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
}

.subject-card {
  position: relative;
  overflow: hidden;
}

.subject-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
}

.subject-card.math::before { background: #E74C3C; }
.subject-card.english::before { background: #3498DB; }
.subject-card.science::before { background: #27AE60; }
.subject-card.history::before { background: #9B59B6; }
.subject-card.art::before { background: #F39C12; }
.subject-card.pe::before { background: #1ABC9C; }

.subject-icon {
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-md);
  font-size: 1.75rem;
}

.subject-card.math .subject-icon { background: rgba(231, 76, 60, 0.1); }
.subject-card.english .subject-icon { background: rgba(52, 152, 219, 0.1); }
.subject-card.science .subject-icon { background: rgba(39, 174, 96, 0.1); }
.subject-card.history .subject-icon { background: rgba(155, 89, 182, 0.1); }
.subject-card.art .subject-icon { background: rgba(243, 156, 18, 0.1); }
.subject-card.pe .subject-icon { background: rgba(26, 188, 156, 0.1); }

.subject-title {
  margin-bottom: var(--space-sm);
}

.subject-description {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: var(--space-md);
}

.subject-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

/* ========================================
   Lessons
   ======================================== */
.lesson-container {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: var(--space-xl);
  padding: var(--space-xl) 0;
}

.lesson-main {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-md);
}

.lesson-sidebar {
  position: sticky;
  top: 90px;
  height: fit-content;
}

.lesson-content {
  margin-bottom: var(--space-xl);
}

.lesson-content h2 {
  margin-top: var(--space-xl);
}

.lesson-content h2:first-child {
  margin-top: 0;
}

.lesson-video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--text-primary);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  margin-bottom: var(--space-lg);
}

.lesson-video svg {
  width: 64px;
  height: 64px;
}

.lesson-nav {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-md);
}

.lesson-nav-title {
  font-size: 1rem;
  margin-bottom: var(--space-md);
}

.lesson-list {
  list-style: none;
}

.lesson-item {
  padding: var(--space-sm) 0;
}

.lesson-item-link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-sm);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  transition: var(--transition);
}

.lesson-item-link:hover,
.lesson-item-link.active {
  background: var(--bg-secondary);
  color: var(--primary);
}

.lesson-item-link.active {
  border-left: 3px solid var(--accent);
}

.lesson-item-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
}

.lesson-item-icon.completed {
  color: var(--success);
}

.lesson-item-title {
  flex: 1;
  font-size: 0.9rem;
}

.lesson-item-duration {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

@media (max-width: 992px) {
  .lesson-container {
    grid-template-columns: 1fr;
  }
  
  .lesson-sidebar {
    position: static;
  }
}

/* ========================================
   Quiz
   ======================================== */
.quiz-container {
  max-width: 800px;
  margin: 0 auto;
  padding: var(--space-xl) 0;
}

.quiz-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.quiz-progress {
  margin-bottom: var(--space-lg);
}

.quiz-progress-text {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-sm);
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.quiz-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-md);
}

.quiz-question {
  font-size: 1.25rem;
  margin-bottom: var(--space-xl);
}

.quiz-options {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.quiz-option:hover {
  border-color: var(--secondary);
  background: rgba(74, 144, 164, 0.05);
}

.quiz-option.selected {
  border-color: var(--primary);
  background: rgba(30, 58, 95, 0.05);
}

.quiz-option.correct {
  border-color: var(--success);
  background: rgba(39, 174, 96, 0.1);
}

.quiz-option.incorrect {
  border-color: var(--error);
  background: rgba(231, 76, 60, 0.1);
}

.quiz-option-marker {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--bg-secondary);
  font-weight: 600;
  flex-shrink: 0;
}

.quiz-option.correct .quiz-option-marker {
  background: var(--success);
  color: white;
}

.quiz-option.incorrect .quiz-option-marker {
  background: var(--error);
  color: white;
}

.quiz-footer {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-xl);
}

.quiz-result {
  text-align: center;
  padding: var(--space-2xl);
}

.quiz-score {
  font-size: 4rem;
  font-weight: 700;
  margin-bottom: var(--space-md);
}

.quiz-score.success {
  color: var(--success);
}

.quiz-score.warning {
  color: var(--warning);
}

.quiz-score.error {
  color: var(--error);
}

.quiz-result-message {
  font-size: 1.25rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-xl);
}

/* ========================================
   Registration Form
   ======================================== */
.registration-page {
  min-height: 100vh;
  padding-top: 70px;
  background: var(--bg-secondary);
}

.registration-container {
  max-width: 900px;
  margin: 0 auto;
  padding: var(--space-xl) var(--space-lg);
}

.registration-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.registration-steps {
  display: flex;
  justify-content: center;
  gap: var(--space-xl);
  margin-bottom: var(--space-2xl);
}

.registration-step {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.registration-step-number {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: var(--border-color);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 0.875rem;
}

.registration-step.active .registration-step-number,
.registration-step.completed .registration-step-number {
  background: var(--primary);
  color: white;
}

.registration-step.completed .registration-step-number {
  background: var(--success);
}

.registration-step-label {
  font-weight: 600;
  color: var(--text-secondary);
}

.registration-step.active .registration-step-label,
.registration-step.completed .registration-step-label {
  color: var(--text-primary);
}

.registration-form {
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  box-shadow: var(--shadow-md);
}

.form-section {
  margin-bottom: var(--space-2xl);
}

.form-section:last-child {
  margin-bottom: 0;
}

.form-section-title {
  font-size: 1.25rem;
  margin-bottom: var(--space-lg);
  padding-bottom: var(--space-md);
  border-bottom: 2px solid var(--bg-secondary);
}

.form-section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--space-lg);
}

.registration-form-footer {
  display: flex;
  justify-content: space-between;
  margin-top: var(--space-xl);
  padding-top: var(--space-lg);
  border-top: 1px solid var(--border-color);
}

/* ========================================
   Messages
   ======================================== */
.messages-container {
  display: grid;
  grid-template-columns: 300px 1fr;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  height: 500px;
}

.messages-sidebar {
  border-right: 1px solid var(--border-color);
  overflow-y: auto;
}

.messages-list {
  list-style: none;
}

.messages-item {
  padding: var(--space-md);
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
  transition: var(--transition);
}

.messages-item:hover,
.messages-item.active {
  background: var(--bg-secondary);
}

.messages-item.unread {
  background: rgba(74, 144, 164, 0.05);
}

.messages-item-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-xs);
}

.messages-item-name {
  font-weight: 600;
}

.messages-item-time {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.messages-item-preview {
  font-size: 0.875rem;
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.messages-main {
  display: flex;
  flex-direction: column;
}

.messages-header {
  padding: var(--space-md) var(--space-lg);
  border-bottom: 1px solid var(--border-color);
}

.messages-content {
  flex: 1;
  padding: var(--space-lg);
  overflow-y: auto;
}

.message-bubble {
  max-width: 70%;
  padding: var(--space-md);
  border-radius: var(--radius-lg);
  margin-bottom: var(--space-md);
}

.message-bubble.received {
  background: var(--bg-secondary);
  border-bottom-left-radius: var(--radius-sm);
}

.message-bubble.sent {
  background: var(--primary);
  color: white;
  margin-left: auto;
  border-bottom-right-radius: var(--radius-sm);
}

.message-time {
  font-size: 0.75rem;
  margin-top: var(--space-xs);
  opacity: 0.7;
}

.messages-compose {
  padding: var(--space-md) var(--space-lg);
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: var(--space-md);
}

.messages-compose input {
  flex: 1;
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: var(--primary);
  color: white;
  padding: var(--space-3xl) 0 var(--space-xl);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-2xl);
  margin-bottom: var(--space-2xl);
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-family: var(--font-accent);
  font-size: 1.5rem;
  margin-bottom: var(--space-md);
}

.footer-description {
  opacity: 0.8;
  font-size: 0.9rem;
}

.footer-title {
  color: white;
  font-size: 1rem;
  margin-bottom: var(--space-lg);
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: var(--space-sm);
}

.footer-links a {
  color: rgba(255, 255, 255, 0.8);
  transition: var(--transition);
}

.footer-links a:hover {
  color: white;
}

.footer-contact li {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  color: rgba(255, 255, 255, 0.8);
}

.footer-bottom {
  padding-top: var(--space-xl);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.footer-copyright {
  opacity: 0.8;
  font-size: 0.875rem;
}

.footer-social {
  display: flex;
  gap: var(--space-md);
}

.footer-social a {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.1);
  color: white;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--accent);
}

/* ========================================
   Modal
   ======================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-lg);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}

.modal.active {
  opacity: 1;
  visibility: visible;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.modal-content {
  position: relative;
  background: white;
  border-radius: var(--radius-lg);
  padding: var(--space-xl);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  transform: scale(0.9);
  transition: var(--transition);
}

.modal.active .modal-content {
  transform: scale(1);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: var(--space-lg);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: var(--transition);
}

.modal-close:hover {
  color: var(--text-primary);
}

/* ========================================
   Alerts & Notifications
   ======================================== */
.alert {
  padding: var(--space-md) var(--space-lg);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-lg);
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.alert-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.alert-success {
  background: rgba(39, 174, 96, 0.1);
  border-left: 4px solid var(--success);
}

.alert-warning {
  background: rgba(230, 126, 34, 0.1);
  border-left: 4px solid var(--warning);
}

.alert-error {
  background: rgba(231, 76, 60, 0.1);
  border-left: 4px solid var(--error);
}

.alert-info {
  background: rgba(74, 144, 164, 0.1);
  border-left: 4px solid var(--secondary);
}

/* ========================================
   Tabs
   ======================================== */
.tabs {
  margin-bottom: var(--space-lg);
}

.tab-list {
  display: flex;
  border-bottom: 2px solid var(--border-color);
  list-style: none;
}

.tab-item {
  padding: var(--space-md) var(--space-lg);
  cursor: pointer;
  color: var(--text-secondary);
  font-weight: 600;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: var(--transition);
}

.tab-item:hover,
.tab-item.active {
  color: var(--primary);
}

.tab-item.active {
  border-bottom-color: var(--primary);
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

/* ========================================
   Cookies Banner
   ======================================== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  padding: var(--space-lg);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--space-lg);
  z-index: 1500;
  transform: translateY(100%);
  transition: var(--transition);
}

.cookie-banner.active {
  transform: translateY(0);
}

.cookie-text {
  flex: 1;
}

.cookie-buttons {
  display: flex;
  gap: var(--space-md);
}

/* ========================================
   Animations
   ======================================== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.animate-fade-in {
  animation: fadeIn 0.5s ease;
}

.animate-slide-up {
  animation: slideUp 0.5s ease;
}

.animate-slide-down {
  animation: slideDown 0.5s ease;
}

.animate-scale-in {
  animation: scaleIn 0.5s ease;
}

/* Staggered animations */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }

/* Loading spinner */
.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid var(--border-color);
  border-top-color: var(--primary);
  border-radius: var(--radius-full);
  animation: spin 0.8s linear infinite;
}

.spinner-lg {
  width: 48px;
  height: 48px;
  border-width: 4px;
}

/* ========================================
   Responsive Utilities
   ======================================== */
@media (max-width: 576px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
  h3 { font-size: 1.25rem; }
  
  .container {
    padding: 0 var(--space-md);
  }
  
  .btn {
    padding: 10px 20px;
  }
  
  .auth-card {
    padding: var(--space-lg);
  }
  
  .registration-steps {
    flex-direction: column;
    align-items: center;
    gap: var(--space-md);
  }
  
  .registration-step-label {
    display: none;
  }
}
