/* ==================== Variables ==================== */
:root {
  --primary: #6366f1;
  --primary-light: #818cf8;
  --primary-dark: #4f46e5;
  --secondary: #10b981;
  --secondary-light: #34d399;
  --accent: #f59e0b;
  --accent-light: #fbbf24;
  
  --bg: #0f172a;
  --surface: #1e293b;
  --surface-light: #334155;
  --surface-lighter: #475569;
  
  --text: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  
  --error: #ef4444;
  --error-light: #fca5a5;
  
  --border: #334155;
  
  --radius-sm: 6px;
  --radius: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-2xl: 24px;
  
  --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -2px rgba(0, 0, 0, 0.3);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 0 10px 10px -5px rgba(0, 0, 0, 0.3);
  
  --transition: 200ms ease-out;
  --transition-slow: 300ms ease-out;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

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

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

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

input {
  font-family: inherit;
  font-size: 1rem;
}

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

/* ==================== Utilities ==================== */
.hidden {
  display: none !important;
}

/* ==================== Auth Screen ==================== */
.auth-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
  position: relative;
  overflow: hidden;
}

.auth-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 48px;
  max-width: 480px;
  margin: 0 auto;
  width: 100%;
}

.auth-header {
  margin-bottom: 40px;
  text-align: center;
}

.auth-header .logo {
  justify-content: center;
  margin-bottom: 24px;
}

.auth-header h1 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 8px;
  background: linear-gradient(135deg, var(--text), var(--text-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-header p {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary-light), var(--primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-group input {
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 1rem;
  transition: all var(--transition);
}

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

.form-group input::placeholder {
  color: var(--text-muted);
}

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

.error-message {
  font-size: 0.8rem;
  color: var(--error);
  min-height: 1.2em;
}

.auth-switch {
  text-align: center;
  color: var(--text-secondary);
  margin-top: 8px;
}

/* ==================== Verification Screen ==================== */
.verify-status {
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid var(--primary);
  border-radius: var(--radius-lg);
  padding: 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 0.9rem;
  line-height: 1.5;
}

.verify-status-icon {
  font-size: 1.3rem;
  flex-shrink: 0;
}

.verify-status-text {
  color: var(--text);
}

.verify-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.verify-actions .btn {
  font-size: 0.875rem;
}

/* ==================== Buttons ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 500;
  border-radius: var(--radius-lg);
  transition: all var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.4);
}

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

.btn-primary:active {
  transform: scale(0.98);
}

.btn-secondary {
  background: var(--surface-light);
  color: var(--text);
}

.btn-secondary:hover {
  background: var(--surface-lighter);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--surface);
  color: var(--text);
}

.btn-success {
  background: linear-gradient(135deg, var(--secondary), #059669);
  color: white;
}

.btn-full {
  width: 100%;
}

.btn-icon {
  width: 18px;
  height: 18px;
}

.btn-logout {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.btn-logout:hover {
  color: var(--error);
  background: rgba(239, 68, 68, 0.1);
}

/* ==================== Auth Decoration ==================== */
.auth-decoration {
  background: linear-gradient(135deg, var(--surface) 0%, var(--bg) 100%);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px;
  gap: 24px;
}

.deco-circle {
  position: absolute;
  border-radius: 50%;
  opacity: 0.5;
}

.deco-1 {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.3) 0%, transparent 70%);
  top: -100px;
  right: -100px;
}

.deco-2 {
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(16, 185, 129, 0.2) 0%, transparent 70%);
  bottom: -50px;
  left: -50px;
}

.deco-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 28px;
  display: flex;
  align-items: center;
  gap: 16px;
  z-index: 1;
  animation: float 3s ease-in-out infinite;
}

.deco-card:nth-child(3) {
  animation-delay: 0.5s;
}

.deco-card:nth-child(4) {
  animation-delay: 1s;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.deco-icon {
  font-size: 2rem;
}

.deco-text {
  font-weight: 600;
  font-size: 1.1rem;
}

/* ==================== Main App Layout ==================== */
.main-app {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

/* ==================== Sidebar ==================== */
.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: sticky;
  top: 0;
  height: 100vh;
}

.sidebar-header {
  padding: 24px;
  border-bottom: 1px solid var(--border);
}

.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius);
  color: var(--text-secondary);
  font-weight: 500;
  transition: all var(--transition);
  position: relative;
}

.nav-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 0;
  background: var(--primary);
  border-radius: 0 2px 2px 0;
  transition: height var(--transition);
}

.nav-item:hover {
  background: var(--surface-light);
  color: var(--text);
}

.nav-item.active {
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
}

.nav-item.active::before {
  height: 24px;
}

.nav-item svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--border);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  margin-bottom: 12px;
}

.user-avatar {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 1rem;
  color: white;
  flex-shrink: 0;
}

.user-details {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.user-name {
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.user-email {
  font-size: 0.8rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==================== Content Area ==================== */
.content {
  padding: 32px 40px;
  max-width: 1400px;
  overflow-y: auto;
}

.page {
  display: none;
  animation: fadeIn 0.3s ease-out;
}

.page.active {
  display: block;
}

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

/* ==================== Page Header ==================== */
.page-header {
  margin-bottom: 32px;
}

.header-content h1 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.header-content p {
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.filters {
  display: flex;
  gap: 8px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.filter-btn {
  padding: 8px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition);
}

.filter-btn:hover {
  border-color: var(--primary);
  color: var(--text);
}

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

/* ==================== Dashboard Stats ==================== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 40px;
}

.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all var(--transition);
}

.stat-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

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

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

.stat-icon.enrolled {
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
}

.stat-icon.lessons {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent);
}

.stat-icon.completed {
  background: rgba(16, 185, 129, 0.15);
  color: var(--secondary);
}

.stat-info {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 1.8rem;
  font-weight: 700;
  line-height: 1;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ==================== Dashboard Sections ==================== */
.dashboard-section {
  margin-bottom: 40px;
}

.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.section-header h2 {
  font-size: 1.3rem;
  font-weight: 600;
}

/* ==================== Courses Grid ==================== */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.course-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all var(--transition);
  cursor: pointer;
}

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

.course-image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  position: relative;
}

.course-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

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

.course-badge {
  position: absolute;
  top: 12px;
  right: 12px;
  padding: 6px 12px;
  background: var(--primary);
  color: white;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius);
  text-transform: uppercase;
}

.course-badge.enrolled {
  background: var(--secondary);
}

.course-content {
  padding: 20px;
}

.course-category {
  display: inline-block;
  padding: 4px 10px;
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
}

.course-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 8px;
  line-height: 1.3;
}

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

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

.course-instructor {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.course-instructor::before {
  content: '';
  width: 24px;
  height: 24px;
  background: var(--surface-light);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'/%3E%3Ccircle cx='12' cy='7' r='4'/%3E%3C/svg%3E");
  background-size: 14px;
  background-position: center;
  background-repeat: no-repeat;
}

.course-duration {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.course-progress {
  margin-top: 12px;
}

.progress-bar {
  height: 6px;
  background: var(--surface-light);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 3px;
  transition: width 0.5s ease-out;
}

.progress-text {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 6px;
}

/* ==================== Empty State ==================== */
.empty-state {
  text-align: center;
  padding: 48px;
  background: var(--surface);
  border: 1px dashed var(--border);
  border-radius: var(--radius-lg);
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 16px;
}

.empty-state h3 {
  font-size: 1.2rem;
  margin-bottom: 8px;
}

.empty-state p {
  color: var(--text-secondary);
  margin-bottom: 20px;
}

/* ==================== Lessons List ==================== */
.lessons-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lesson-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  transition: all var(--transition);
}

.lesson-item:hover {
  border-color: var(--primary);
  background: var(--surface-light);
}

.lesson-date {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 8px 12px;
  background: rgba(99, 102, 241, 0.1);
  border-radius: var(--radius);
  min-width: 60px;
}

.lesson-date-day {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary-light);
  line-height: 1;
}

.lesson-date-month {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
}

.lesson-info {
  flex: 1;
}

.lesson-title {
  font-weight: 600;
  margin-bottom: 4px;
}

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

.lesson-time {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.9rem;
  color: var(--accent);
  font-weight: 500;
}

/* ==================== Schedule Page ==================== */
.schedule-nav {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
}

.week-label {
  font-weight: 600;
  font-size: 1.1rem;
  min-width: 140px;
  text-align: center;
}

.nav-btn {
  padding: 8px;
  border-radius: var(--radius);
}

.schedule-container {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.weekdays-header {
  display: grid;
  grid-template-columns: 60px repeat(7, 1fr);
  border-bottom: 1px solid var(--border);
  background: var(--surface-light);
}

.time-col {
  padding: 16px;
}

.day-header {
  padding: 16px;
  text-align: center;
  font-weight: 600;
  border-left: 1px solid var(--border);
}

.day-header.today {
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
}

.schedule-grid {
  display: grid;
  grid-template-columns: 60px repeat(7, 1fr);
  min-height: 600px;
}

.time-slot {
  padding: 8px 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: right;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.day-column {
  border-right: 1px solid var(--border);
  position: relative;
}

.schedule-event {
  position: absolute;
  left: 4px;
  right: 4px;
  background: var(--primary);
  border-radius: var(--radius-sm);
  padding: 8px;
  font-size: 0.8rem;
  cursor: pointer;
  overflow: hidden;
  transition: all var(--transition);
  z-index: 1;
}

.schedule-event:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow);
  z-index: 2;
}

.schedule-event-title {
  font-weight: 600;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.schedule-event-course {
  font-size: 0.7rem;
  opacity: 0.8;
}

.schedule-event-time {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.7rem;
  opacity: 0.7;
  margin-top: 4px;
}

/* ==================== Course Detail ==================== */
.course-detail-container {
  max-width: 900px;
}

.back-btn {
  margin-bottom: 24px;
  gap: 8px;
}

.course-detail-hero {
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 32px;
  position: relative;
}

.course-detail-hero img {
  width: 100%;
  height: 300px;
  object-fit: cover;
}

.course-detail-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 40px;
  background: linear-gradient(transparent, rgba(15, 23, 42, 0.95));
}

.course-detail-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.course-detail-meta {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.meta-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.meta-item svg {
  width: 18px;
  height: 18px;
  color: var(--primary-light);
}

.course-detail-body {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
}

.course-info h3 {
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.course-info p {
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.8;
}

.lessons-section h3 {
  font-size: 1.2rem;
  margin-bottom: 16px;
}

.lessons-section ul {
  list-style: none;
}

.lessons-section li {
  padding: 12px 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.lesson-number {
  width: 28px;
  height: 28px;
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  flex-shrink: 0;
}

.course-sidebar {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  height: fit-content;
  position: sticky;
  top: 24px;
}

.enroll-card h3 {
  font-size: 1.3rem;
  margin-bottom: 16px;
}

.enroll-card .btn {
  width: 100%;
  margin-top: 16px;
}

.schedule-preview {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.schedule-preview h4 {
  font-size: 0.95rem;
  margin-bottom: 12px;
  color: var(--text-secondary);
}

.schedule-item {
  display: flex;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
}

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

.schedule-item-day {
  color: var(--text-secondary);
}

.schedule-item-time {
  font-family: 'JetBrains Mono', monospace;
  color: var(--accent);
}

/* ==================== Profile Page ==================== */
.profile-container {
  max-width: 800px;
}

.profile-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 32px;
}

.profile-avatar-large {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 2rem;
  color: white;
  flex-shrink: 0;
}

.profile-info h2 {
  font-size: 1.5rem;
  margin-bottom: 4px;
}

.profile-info p {
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.profile-badge {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(99, 102, 241, 0.15);
  color: var(--primary-light);
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: var(--radius);
}

.profile-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-bottom: 24px;
}

.profile-section h3 {
  font-size: 1.1rem;
  margin-bottom: 20px;
}

.profile-courses-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.profile-course-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  background: var(--surface-light);
  border-radius: var(--radius);
  cursor: pointer;
  transition: all var(--transition);
}

.profile-course-item:hover {
  background: var(--surface-lighter);
}

.profile-course-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius);
  object-fit: cover;
}

.profile-course-info {
  flex: 1;
}

.profile-course-title {
  font-weight: 600;
  margin-bottom: 4px;
}

.profile-course-progress {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.stats-mini {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.stat-mini {
  text-align: center;
  padding: 20px;
  background: var(--surface-light);
  border-radius: var(--radius);
}

.stat-mini-value {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--primary-light);
}

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

/* ==================== Modal ==================== */
.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 24px;
}

.modal.hidden {
  display: none;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
}

.modal-content {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 32px;
  max-width: 480px;
  width: 100%;
  animation: modalIn 0.3s ease-out;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  border-radius: var(--radius);
  transition: all var(--transition);
}

.modal-close:hover {
  background: var(--surface-light);
  color: var(--text);
}

.modal-close svg {
  width: 20px;
  height: 20px;
}

.modal-body h3 {
  font-size: 1.3rem;
  margin-bottom: 16px;
}

.modal-body p {
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.modal-actions {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

/* ==================== Toast ==================== */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow-xl);
  animation: toastIn 0.3s ease-out;
  z-index: 1100;
}

.toast.hidden {
  display: none;
}

.toast.success {
  border-color: var(--secondary);
}

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

.toast-close {
  color: var(--text-muted);
  padding: 4px;
  border-radius: var(--radius-sm);
}

.toast-close:hover {
  background: var(--surface-light);
  color: var(--text);
}

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

/* ==================== Responsive ==================== */
@media (max-width: 1024px) {
  .main-app {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    position: fixed;
    left: -280px;
    top: 0;
    height: 100vh;
    width: 260px;
    z-index: 100;
    transition: left var(--transition-slow);
  }
  
  .sidebar.open {
    left: 0;
  }
  
  .content {
    padding: 24px;
  }
  
  .course-detail-body {
    grid-template-columns: 1fr;
  }
  
  .course-sidebar {
    position: static;
  }
}

@media (max-width: 768px) {
  .auth-screen {
    grid-template-columns: 1fr;
  }
  
  .auth-decoration {
    display: none;
  }
  
  .auth-container {
    padding: 32px 24px;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .courses-grid {
    grid-template-columns: 1fr;
  }
  
  .schedule-grid,
  .weekdays-header {
    grid-template-columns: 50px repeat(7, 1fr);
    font-size: 0.75rem;
  }
  
  .time-slot {
    font-size: 0.65rem;
    padding: 4px;
  }
  
  .schedule-event {
    padding: 4px;
    font-size: 0.6rem;
  }
  
  .profile-card {
    flex-direction: column;
    text-align: center;
  }
  
  .stats-mini {
    grid-template-columns: 1fr;
  }
}
