/* ============================================
   电商PS设计学堂 - 全局样式
   主题：青春亮色系 · 活力渐变 · 清新电商感
============================================ */

:root {
  /* 主色：青春紫蓝渐变 */
  --primary: #6C63FF;
  --secondary: #FF6B9D;
  --gradient: linear-gradient(135deg, #6C63FF 0%, #FF6B9D 100%);
  --gradient-soft: linear-gradient(135deg, rgba(108,99,255,0.08) 0%, rgba(255,107,157,0.08) 100%);
  --gradient-blue: linear-gradient(135deg, #667EEA 0%, #764BA2 100%);

  /* 辅助亮色 */
  --teal: #00C9A7;
  --sky: #4FC3F7;
  --yellow: #FFD166;
  --coral: #FF6B6B;

  /* 亮色背景 */
  --bg: #F8F9FF;
  --bg2: #EEF0FB;
  --card: #FFFFFF;
  --card2: #F3F4FD;
  --border: #E2E5F5;
  --border-accent: rgba(108,99,255,0.3);

  /* 文字 */
  --text: #1A1A3E;
  --text2: #5A5A8A;
  --text3: #A0A0C8;

  /* 语义色 */
  --success: #06D6A0;
  --warning: #FFB703;
  --info: #4361EE;
  --red: #FF4757;
  --orange: #FF6B35;

  /* 字体 */
  --font-display: 'Bebas Neue', 'Noto Sans SC', sans-serif;
  --font-body: 'Noto Sans SC', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* 圆角 */
  --radius: 14px;
  --radius-sm: 10px;
  --radius-lg: 22px;

  /* 阴影 */
  --shadow: 0 4px 24px rgba(108,99,255,0.1);
  --shadow-primary: 0 6px 28px rgba(108,99,255,0.25);
  --shadow-card: 0 2px 16px rgba(108,99,255,0.07);

  /* 其他 */
  --nav-h: 64px;
  --sidebar-w: 280px;
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--bg); color: var(--text);
  min-height: 100vh; line-height: 1.6; overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button { cursor: pointer; font-family: var(--font-body); }
input, textarea, select { font-family: var(--font-body); }
img { max-width: 100%; display: block; }

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg2); }
::-webkit-scrollbar-thumb { background: #C5CAF0; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--primary); }

/* ============================================ 页面加载器 */
.page-loader {
  position: fixed; inset: 0;
  background: linear-gradient(135deg, #F8F9FF 0%, #EEF0FB 100%);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999; transition: opacity 0.4s ease, visibility 0.4s ease;
}
.page-loader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-inner { text-align: center; }
.loader-logo {
  font-family: var(--font-display); font-size: 72px;
  background: var(--gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  letter-spacing: 4px; margin-bottom: 16px;
  animation: pulse 1.5s ease-in-out infinite;
}
.loader-text { font-size: 14px; color: var(--text2); margin-top: 12px; letter-spacing: 2px; }
.loader-bar { width: 200px; height: 4px; background: var(--bg2); border-radius: 2px; overflow: hidden; margin: 0 auto; }
.loader-fill { height: 100%; background: var(--gradient); border-radius: 2px; animation: loading 1.8s ease-in-out infinite; }
@keyframes loading { 0%{width:0%;margin-left:0} 50%{width:80%;margin-left:0} 100%{width:0%;margin-left:100%} }
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.7} }

/* ============================================ 顶部导航 */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; height: var(--nav-h);
  background: rgba(255,255,255,0.92); backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 28px;
  z-index: 100; gap: 16px;
  box-shadow: 0 2px 20px rgba(108,99,255,0.08);
}
.navbar-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 18px; cursor: pointer; }
.navbar-brand .brand-ps {
  font-family: var(--font-display); font-size: 30px;
  background: var(--gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  letter-spacing: 1px;
}
.navbar-brand .brand-name { color: var(--text); font-size: 15px; font-weight: 600; }
.navbar-spacer { flex: 1; }
.navbar-nav { display: flex; align-items: center; gap: 4px; }
.nav-link {
  padding: 7px 16px; border-radius: 30px;
  font-size: 13px; color: var(--text2); transition: var(--transition); cursor: pointer; font-weight: 500;
}
.nav-link:hover { color: var(--primary); background: rgba(108,99,255,0.08); }
.nav-link.active { color: var(--primary); background: rgba(108,99,255,0.1); font-weight: 600; }
.navbar-user {
  display: flex; align-items: center; gap: 10px; padding: 6px 16px;
  border-radius: 30px; background: var(--bg2); border: 1px solid var(--border);
  font-size: 13px; color: var(--text2); cursor: pointer; transition: var(--transition);
}
.navbar-user:hover { border-color: var(--primary); color: var(--primary); }
.navbar-user .avatar {
  width: 28px; height: 28px; border-radius: 50%; background: var(--gradient);
  display: flex; align-items: center; justify-content: center; font-size: 12px; color: #fff; font-weight: 700;
}
.navbar-btn {
  padding: 7px 18px; border-radius: 30px; font-size: 13px; font-weight: 600; border: none; transition: var(--transition);
}
.navbar-btn.outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.navbar-btn.outline:hover { background: rgba(108,99,255,0.08); }
.navbar-btn.primary { background: var(--gradient); color: #fff; }
.navbar-btn.primary:hover { opacity: 0.9; transform: translateY(-1px); box-shadow: var(--shadow-primary); }
.navbar-dropdown { position: relative; }
.navbar-dropdown-menu {
  position: absolute; top: calc(100% + 10px); right: 0; min-width: 160px;
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); display: none; z-index: 200;
}
.navbar-dropdown-menu.open { display: block; }
.dropdown-item {
  padding: 11px 18px; font-size: 13px; color: var(--text2);
  cursor: pointer; transition: var(--transition); display: flex; align-items: center; gap: 8px;
}
.dropdown-item:hover { background: var(--bg2); color: var(--text); }
.dropdown-item.danger:hover { color: var(--red); background: rgba(255,71,87,0.06); }

/* ============================================ 布局 */
.page-wrap { margin-top: var(--nav-h); min-height: calc(100vh - var(--nav-h)); }
.layout-with-sidebar { display: flex; }
.layout-sidebar {
  position: fixed; top: var(--nav-h); left: 0;
  width: var(--sidebar-w); height: calc(100vh - var(--nav-h));
  overflow-y: auto; background: var(--card); border-right: 1px solid var(--border);
  padding: 16px 0;
}
.layout-content { margin-left: var(--sidebar-w); flex: 1; padding: 36px 52px; max-width: 960px; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 28px; }
.container-narrow { max-width: 720px; margin: 0 auto; padding: 0 28px; }

/* ============================================ 卡片 */
.card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; transition: var(--transition); box-shadow: var(--shadow-card); }
.card:hover { border-color: rgba(108,99,255,0.25); box-shadow: var(--shadow); }
.card-sm { padding: 16px; border-radius: var(--radius-sm); }

/* ============================================ 按钮 */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 22px; border-radius: 30px; border: none;
  font-size: 14px; font-weight: 600; transition: var(--transition); cursor: pointer; white-space: nowrap;
}
.btn-primary { background: var(--gradient); color: #fff; }
.btn-primary:hover { opacity: 0.9; transform: translateY(-1px); box-shadow: var(--shadow-primary); }
.btn-primary:active { transform: translateY(0); }
.btn-outline { background: transparent; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: rgba(108,99,255,0.08); }
.btn-ghost { background: transparent; color: var(--text2); }
.btn-ghost:hover { background: var(--bg2); color: var(--text); }
.btn-success { background: linear-gradient(135deg, #06D6A0 0%, #00C9A7 100%); color: #fff; }
.btn-success:hover { opacity: 0.9; box-shadow: 0 4px 16px rgba(6,214,160,0.3); }
.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { opacity: 0.9; }
.btn-sm { padding: 6px 16px; font-size: 13px; }
.btn-lg { padding: 14px 36px; font-size: 16px; }
.btn-block { width: 100%; border-radius: var(--radius-sm); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none !important; }

/* ============================================ 表单 */
.form-group { margin-bottom: 20px; }
.form-label { display: block; margin-bottom: 8px; font-size: 13px; color: var(--text2); font-weight: 600; }
.form-input {
  width: 100%; padding: 12px 16px; background: var(--bg);
  color: var(--text); border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 14px; transition: var(--transition); outline: none;
}
.form-input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(108,99,255,0.12); background: #fff; }
.form-input::placeholder { color: var(--text3); }
.form-select {
  width: 100%; padding: 12px 16px; background: var(--bg); color: var(--text);
  border: 1.5px solid var(--border); border-radius: var(--radius-sm);
  font-size: 14px; cursor: pointer; outline: none; transition: var(--transition);
  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='%23A0A0C8' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 16px center; padding-right: 40px;
}
.form-select:focus { border-color: var(--primary); }
.form-hint { margin-top: 6px; font-size: 12px; color: var(--text3); }
.form-error { margin-top: 6px; font-size: 12px; color: var(--red); }

/* ============================================ 徽章 */
.badge { display: inline-flex; align-items: center; padding: 3px 12px; border-radius: 20px; font-size: 11px; font-weight: 700; letter-spacing: 0.5px; }
.badge-red { background: rgba(255,71,87,0.1); color: var(--red); border: 1px solid rgba(255,71,87,0.2); }
.badge-orange { background: rgba(255,107,53,0.1); color: var(--orange); border: 1px solid rgba(255,107,53,0.2); }
.badge-green { background: rgba(6,214,160,0.12); color: #059669; border: 1px solid rgba(6,214,160,0.25); }
.badge-blue { background: rgba(67,97,238,0.1); color: var(--info); border: 1px solid rgba(67,97,238,0.2); }
.badge-gray { background: var(--bg2); color: var(--text3); border: 1px solid var(--border); }

/* ============================================ 进度条 */
.progress-bar { height: 7px; background: var(--bg2); border-radius: 4px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--gradient); border-radius: 4px; transition: width 0.6s cubic-bezier(0.4,0,0.2,1); }
.progress-bar.sm { height: 4px; }
.progress-bar.lg { height: 10px; }
.progress-label { display: flex; justify-content: space-between; margin-bottom: 6px; font-size: 12px; color: var(--text2); font-weight: 500; }

/* ============================================ 分割线 */
.divider { height: 1px; background: var(--border); margin: 24px 0; }
.divider-text { display: flex; align-items: center; gap: 12px; color: var(--text3); font-size: 13px; margin: 24px 0; }
.divider-text::before, .divider-text::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ============================================ Toast */
#toast-root { position: fixed; top: 80px; right: 20px; z-index: 9998; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 12px 18px; border-radius: var(--radius-sm); font-size: 13px; font-weight: 600;
  display: flex; align-items: center; gap: 10px; min-width: 240px;
  animation: toastIn 0.3s cubic-bezier(0.4,0,0.2,1); border-left: 4px solid transparent;
  box-shadow: 0 4px 20px rgba(0,0,0,0.12);
}
.toast.success { background: #ECFDF5; border-color: var(--success); color: #065F46; }
.toast.error { background: #FFF1F2; border-color: var(--red); color: #BE123C; }
.toast.info { background: #EEF2FF; border-color: var(--info); color: #3730A3; }
.toast.warning { background: #FFFBEB; border-color: var(--warning); color: #92400E; }
@keyframes toastIn { from{opacity:0;transform:translateX(20px)} to{opacity:1;transform:translateX(0)} }

/* ============================================ 登录/注册页 */
.auth-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #F0F1FF 0%, #FDF0F8 50%, #F0FBF8 100%);
  position: relative; overflow: hidden; padding: 40px 20px;
}
.auth-bg-decor { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.auth-bg-decor .decor-circle { position: absolute; border-radius: 50%; opacity: 0.18; filter: blur(50px); }
.auth-bg-decor .decor-circle:nth-child(1) { width: 500px; height: 500px; top: -150px; right: -100px; background: radial-gradient(circle, #6C63FF, #FF6B9D); }
.auth-bg-decor .decor-circle:nth-child(2) { width: 400px; height: 400px; bottom: -100px; left: -80px; background: radial-gradient(circle, #00C9A7, #4FC3F7); }
.auth-box {
  position: relative; width: 100%; max-width: 420px;
  background: rgba(255,255,255,0.9); border: 1px solid rgba(255,255,255,0.8);
  border-radius: var(--radius-lg); padding: 44px;
  box-shadow: 0 8px 48px rgba(108,99,255,0.15), 0 2px 8px rgba(108,99,255,0.06);
  backdrop-filter: blur(20px);
}
.auth-logo { text-align: center; margin-bottom: 32px; }
.auth-logo .logo-ps {
  font-family: var(--font-display); font-size: 60px; line-height: 1;
  background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.auth-logo .logo-name { font-size: 15px; color: var(--text2); margin-top: 4px; font-weight: 500; }
.auth-title { font-size: 22px; font-weight: 800; margin-bottom: 24px; text-align: center; color: var(--text); }
.auth-footer { text-align: center; margin-top: 20px; font-size: 13px; color: var(--text2); }
.auth-footer a { color: var(--primary); cursor: pointer; font-weight: 600; }
.auth-footer a:hover { text-decoration: underline; }

/* ============================================ 首页 */
.home-hero {
  padding: 80px 0 60px; text-align: center; position: relative; overflow: hidden;
}
.home-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse at 30% 0%, rgba(108,99,255,0.07) 0%, transparent 60%),
              radial-gradient(ellipse at 80% 100%, rgba(255,107,157,0.06) 0%, transparent 50%);
  pointer-events: none;
}
.home-hero .hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(108,99,255,0.08); border: 1.5px solid rgba(108,99,255,0.2);
  border-radius: 30px; padding: 5px 16px;
  font-size: 12px; color: var(--primary); font-weight: 700; letter-spacing: 1.5px; margin-bottom: 20px;
}
.home-hero .hero-title { font-size: clamp(36px,5vw,64px); font-weight: 900; line-height: 1.1; margin-bottom: 16px; color: var(--text); }
.home-hero .hero-title span { background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.home-hero .hero-sub { font-size: 16px; color: var(--text2); margin-bottom: 36px; max-width: 500px; margin-inline: auto; line-height: 1.8; }
.home-hero .hero-stats { display: flex; justify-content: center; gap: 48px; margin-bottom: 48px; }
.hero-stat { text-align: center; }
.hero-stat .stat-num {
  font-family: var(--font-display); font-size: 38px;
  background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; line-height: 1;
}
.hero-stat .stat-label { font-size: 12px; color: var(--text2); margin-top: 4px; font-weight: 500; }

.chapter-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; margin-top: 40px; }
.chapter-card {
  background: var(--card); border: 1.5px solid var(--border);
  border-radius: var(--radius); padding: 24px;
  cursor: pointer; transition: var(--transition); position: relative; overflow: hidden;
  box-shadow: var(--shadow-card);
}
.chapter-card::after { content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 3px; background: var(--gradient); opacity: 0; transition: var(--transition); }
.chapter-card:hover { transform: translateY(-5px); border-color: rgba(108,99,255,0.3); box-shadow: var(--shadow); }
.chapter-card:hover::after { opacity: 1; }
.chapter-card.locked { opacity: 0.55; cursor: not-allowed; }
.chapter-card.locked:hover { transform: none; box-shadow: var(--shadow-card); border-color: var(--border); }
.chapter-card .chapter-num {
  font-family: var(--font-display); font-size: 52px; line-height: 1;
  background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
  opacity: 0.15; position: absolute; right: 18px; top: 14px;
}
.chapter-card .chapter-tag { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 12px; }
.chapter-card .chapter-title { font-size: 17px; font-weight: 800; margin-bottom: 8px; color: var(--text); }
.chapter-card .chapter-desc { font-size: 13px; color: var(--text2); line-height: 1.65; margin-bottom: 16px; }
.chapter-card .chapter-meta { display: flex; align-items: center; gap: 16px; font-size: 12px; color: var(--text3); font-weight: 500; }

.camp-banner {
  background: linear-gradient(135deg, #EEF0FB 0%, #FDF0F8 100%);
  border: 1.5px solid rgba(108,99,255,0.2); border-radius: var(--radius-lg); padding: 40px;
  display: flex; align-items: center; gap: 40px;
  margin-top: 24px; cursor: pointer; transition: var(--transition); position: relative; overflow: hidden;
}
.camp-banner::before {
  content: ''; position: absolute; right: -60px; top: -60px;
  width: 220px; height: 220px; border-radius: 50%;
  background: var(--gradient); opacity: 0.07; filter: blur(30px);
}
.camp-banner:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(108,99,255,0.18); }
.camp-banner .camp-icon { font-size: 64px; line-height: 1; flex-shrink: 0; }
.camp-banner .camp-body { flex: 1; }
.camp-banner .camp-label { font-size: 11px; color: var(--primary); font-weight: 800; letter-spacing: 2.5px; margin-bottom: 8px; }
.camp-banner .camp-title { font-size: 28px; font-weight: 900; margin-bottom: 8px; color: var(--text); }
.camp-banner .camp-desc { font-size: 14px; color: var(--text2); }
.camp-banner .camp-arrow { font-size: 32px; color: var(--primary); flex-shrink: 0; }

.progress-overview { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 24px; margin-bottom: 32px; box-shadow: var(--shadow-card); }
.progress-overview .overview-title { font-size: 14px; color: var(--text2); margin-bottom: 16px; font-weight: 600; }
.progress-overview .overview-num { font-size: 40px; font-weight: 900; margin-bottom: 4px; background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.progress-overview .overview-sub { font-size: 12px; color: var(--text3); margin-bottom: 16px; }

/* ============================================ 侧边栏 */
.sidebar-chapter { margin-bottom: 2px; }
.sidebar-chapter-header {
  display: flex; align-items: center; gap: 10px; padding: 10px 20px;
  cursor: pointer; transition: var(--transition); color: var(--text2); font-size: 13px; font-weight: 600;
}
.sidebar-chapter-header:hover { color: var(--text); background: var(--bg2); }
.sidebar-chapter-header.active { color: var(--primary); }
.sidebar-chapter-header .ch-num {
  width: 22px; height: 22px; border-radius: 50%; background: var(--bg2);
  display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; flex-shrink: 0;
  border: 1.5px solid var(--border); color: var(--text3);
}
.sidebar-chapter-header.active .ch-num { background: var(--gradient); color: #fff; border-color: transparent; }
.sidebar-chapter-header .ch-arrow { margin-left: auto; transition: transform 0.2s; font-size: 10px; }
.sidebar-chapter-header.open .ch-arrow { transform: rotate(90deg); }
.sidebar-lessons { overflow: hidden; }
.sidebar-lesson {
  display: flex; align-items: center; gap: 10px; padding: 8px 20px 8px 52px;
  font-size: 13px; color: var(--text3); cursor: pointer; transition: var(--transition); position: relative;
}
.sidebar-lesson:hover { color: var(--text); background: var(--bg2); }
.sidebar-lesson.active { color: var(--primary); background: rgba(108,99,255,0.07); font-weight: 600; }
.sidebar-lesson.active::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; background: var(--gradient); border-radius: 0 2px 2px 0; }
.sidebar-lesson .lesson-check { font-size: 12px; margin-left: auto; }
.sidebar-lesson.locked { opacity: 0.4; cursor: not-allowed; }
.sidebar-progress-wrap { padding: 16px 20px; border-bottom: 1px solid var(--border); margin-bottom: 8px; }
.sidebar-progress-wrap .sp-title { font-size: 11px; color: var(--text3); margin-bottom: 8px; font-weight: 700; letter-spacing: 1px; }

/* ============================================ 课时页 */
.lesson-header { border-bottom: 1.5px solid var(--border); padding-bottom: 24px; margin-bottom: 32px; }
.lesson-breadcrumb { font-size: 12px; color: var(--text3); margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.lesson-breadcrumb span { cursor: pointer; font-weight: 500; }
.lesson-breadcrumb span:hover { color: var(--primary); }
.lesson-title { font-size: 28px; font-weight: 900; margin-bottom: 12px; color: var(--text); }
.lesson-meta { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.lesson-objectives {
  background: linear-gradient(135deg, rgba(108,99,255,0.06) 0%, rgba(255,107,157,0.06) 100%);
  border: 1.5px solid rgba(108,99,255,0.2);
  border-radius: var(--radius); padding: 20px; margin-bottom: 32px;
}
.lesson-objectives .obj-title { font-size: 13px; font-weight: 800; color: var(--primary); margin-bottom: 12px; display: flex; align-items: center; gap: 6px; }
.lesson-objectives ul { padding-left: 0; list-style: none; }
.lesson-objectives li { font-size: 14px; color: var(--text2); padding: 5px 0; display: flex; align-items: flex-start; gap: 8px; }
.lesson-objectives li::before { content: '→'; color: var(--primary); flex-shrink: 0; margin-top: 1px; font-weight: 700; }

.content-section { margin-bottom: 36px; }
.section-title { font-size: 18px; font-weight: 800; margin-bottom: 16px; display: flex; align-items: center; gap: 10px; color: var(--text); }
.section-title .section-icon { width: 30px; height: 30px; border-radius: 10px; background: var(--gradient); display: flex; align-items: center; justify-content: center; font-size: 15px; flex-shrink: 0; }

.step-block { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 20px; margin-bottom: 12px; display: flex; gap: 16px; box-shadow: var(--shadow-card); transition: var(--transition); }
.step-block:hover { border-color: rgba(108,99,255,0.2); box-shadow: var(--shadow); }
.step-block .step-num { width: 34px; height: 34px; border-radius: 50%; background: var(--gradient); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; flex-shrink: 0; margin-top: 2px; }
.step-block .step-body { flex: 1; }
.step-block .step-title { font-size: 15px; font-weight: 700; margin-bottom: 6px; color: var(--text); }
.step-block .step-desc { font-size: 14px; color: var(--text2); line-height: 1.75; }
.step-block .step-img { margin-top: 14px; border-radius: var(--radius-sm); border: 1.5px solid var(--border); overflow: hidden; background: var(--bg2); }
.step-block .step-img img { width: 100%; }
.step-block .step-img .img-placeholder { height: 200px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--text3); font-size: 13px; }
.step-block .step-img .img-icon { font-size: 36px; opacity: 0.5; }

.key-tip {
  background: linear-gradient(135deg, rgba(0,201,167,0.07) 0%, rgba(79,195,247,0.07) 100%);
  border: 1.5px solid rgba(0,201,167,0.25); border-left: 4px solid var(--teal);
  border-radius: var(--radius-sm); padding: 14px 16px; margin: 14px 0; font-size: 14px; color: var(--text);
  display: flex; gap: 10px; align-items: flex-start;
}
.key-tip .tip-icon { flex-shrink: 0; margin-top: 1px; }
.kbd { display: inline-block; background: var(--bg2); border: 1.5px solid var(--border); border-radius: 6px; padding: 2px 10px; font-family: var(--font-mono); font-size: 12px; color: var(--primary); font-weight: 700; }

.practice-section {
  background: linear-gradient(135deg, rgba(108,99,255,0.04) 0%, rgba(255,107,157,0.04) 100%);
  border: 1.5px solid rgba(108,99,255,0.2); border-radius: var(--radius-lg); padding: 28px; margin-top: 40px;
}
.practice-section .practice-header { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.practice-section .practice-title { font-size: 18px; font-weight: 800; color: var(--text); }
.practice-section .practice-badge { background: var(--gradient); color: #fff; padding: 4px 14px; border-radius: 20px; font-size: 11px; font-weight: 800; letter-spacing: 1px; }
.practice-tabs { display: flex; gap: 4px; margin-bottom: 20px; border-bottom: 1.5px solid var(--border); }
.practice-tab { padding: 9px 18px; font-size: 13px; color: var(--text3); cursor: pointer; border-bottom: 2.5px solid transparent; transition: var(--transition); margin-bottom: -2px; font-weight: 600; }
.practice-tab:hover { color: var(--primary); }
.practice-tab.active { color: var(--primary); border-bottom-color: var(--primary); }
.practice-content { display: none; }
.practice-content.active { display: block; }
.practice-img-wrap { border-radius: var(--radius); overflow: hidden; background: var(--bg2); border: 1.5px solid var(--border); }
.practice-img-wrap .img-placeholder { height: 280px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; color: var(--text3); font-size: 13px; }
.hint-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.hint-item { display: flex; gap: 10px; align-items: flex-start; background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius-sm); padding: 13px 16px; font-size: 14px; color: var(--text2); }
.hint-item .hint-num { width: 24px; height: 24px; background: var(--gradient); color: #fff; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; flex-shrink: 0; }
.material-list { display: flex; flex-direction: column; gap: 8px; }
.material-item { display: flex; align-items: center; gap: 12px; background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius-sm); padding: 13px 18px; }
.material-item .mat-icon { font-size: 22px; }
.material-item .mat-name { flex: 1; font-size: 14px; color: var(--text); font-weight: 500; }
.material-item .mat-note { font-size: 12px; color: var(--text3); }

.complete-btn-wrap { margin-top: 52px; text-align: center; }
.complete-btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 18px 56px;
  border-radius: 50px; font-size: 17px; font-weight: 800; border: none; cursor: pointer;
  background: var(--gradient); color: #fff; transition: var(--transition);
  box-shadow: 0 8px 32px rgba(108,99,255,0.3);
  letter-spacing: 0.5px;
}
.complete-btn:hover { transform: translateY(-3px); box-shadow: 0 12px 40px rgba(108,99,255,0.4); }
.complete-btn.done {
  background: linear-gradient(135deg, #06D6A0 0%, #00C9A7 100%);
  box-shadow: 0 8px 28px rgba(6,214,160,0.3); cursor: default;
}
.complete-btn.done:hover { transform: none; }
.lesson-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 48px; padding-top: 24px; border-top: 1.5px solid var(--border); }

/* ============================================ 测验页 */
.quiz-page { max-width: 700px; margin: 0 auto; padding: 44px 24px; }
.quiz-header { margin-bottom: 36px; }
.quiz-title { font-size: 26px; font-weight: 900; margin-bottom: 8px; color: var(--text); }
.quiz-sub { font-size: 14px; color: var(--text2); }
.quiz-progress-wrap { margin-bottom: 32px; }
.quiz-question { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 30px; margin-bottom: 16px; box-shadow: var(--shadow-card); }
.quiz-q-num { font-size: 12px; color: var(--text3); margin-bottom: 8px; font-family: var(--font-mono); font-weight: 600; }
.quiz-q-text { font-size: 17px; font-weight: 700; line-height: 1.65; margin-bottom: 24px; color: var(--text); }
.quiz-options { display: flex; flex-direction: column; gap: 10px; }
.quiz-option { display: flex; align-items: center; gap: 14px; padding: 14px 18px; border-radius: var(--radius-sm); border: 1.5px solid var(--border); cursor: pointer; transition: var(--transition); font-size: 14px; color: var(--text2); background: var(--bg); font-weight: 500; }
.quiz-option:hover { border-color: rgba(108,99,255,0.3); color: var(--text); background: rgba(108,99,255,0.04); }
.quiz-option.selected { border-color: var(--primary); color: var(--primary); background: rgba(108,99,255,0.07); }
.quiz-option.correct { border-color: var(--success); color: #059669; background: rgba(6,214,160,0.07); }
.quiz-option.wrong { border-color: var(--red); color: var(--red); background: rgba(255,71,87,0.06); }
.quiz-option .opt-label { width: 26px; height: 26px; border-radius: 50%; border: 1.5px solid currentColor; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 800; flex-shrink: 0; }
.quiz-actions { display: flex; justify-content: flex-end; gap: 12px; margin-top: 20px; }
.quiz-explain { background: #FFFBEB; border: 1.5px solid rgba(255,183,3,0.3); border-radius: var(--radius-sm); padding: 14px 16px; margin-top: 12px; font-size: 13px; color: var(--text2); display: none; }
.quiz-explain.show { display: block; }
.quiz-explain .explain-label { font-weight: 800; color: var(--warning); margin-bottom: 4px; }
.quiz-result { text-align: center; padding: 52px 24px; }
.quiz-result .result-icon { font-size: 64px; margin-bottom: 16px; }
.quiz-result .result-score { font-size: 80px; font-weight: 900; line-height: 1; background: var(--gradient); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; margin-bottom: 12px; }
.quiz-result .result-msg { font-size: 22px; font-weight: 800; margin-bottom: 8px; color: var(--text); }
.quiz-result .result-sub { font-size: 14px; color: var(--text2); margin-bottom: 36px; }

/* ============================================ 竞赛训练营 */
.camp-page { padding: 60px 0; }
.camp-hero { text-align: center; padding: 80px 24px; background: linear-gradient(180deg, rgba(108,99,255,0.05) 0%, transparent 100%); border-bottom: 1.5px solid var(--border); margin-bottom: 60px; }
.camp-hero .camp-badge { display: inline-block; background: var(--gradient); color: #fff; padding: 5px 18px; border-radius: 30px; font-size: 12px; font-weight: 800; letter-spacing: 2px; margin-bottom: 20px; }
.camp-hero h1 { font-size: 52px; font-weight: 900; margin-bottom: 16px; color: var(--text); }
.camp-hero p { font-size: 16px; color: var(--text2); max-width: 480px; margin: 0 auto 32px; }
.camp-coming { display: inline-flex; align-items: center; gap: 10px; background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 18px 36px; font-size: 15px; color: var(--text2); box-shadow: var(--shadow-card); font-weight: 500; }

/* ============================================ 管理员 */
.admin-layout { display: flex; min-height: calc(100vh - var(--nav-h)); }
.admin-sidebar { width: 220px; flex-shrink: 0; background: var(--card); border-right: 1px solid var(--border); padding: 24px 0; }
.admin-sidebar .admin-title { padding: 0 20px 16px; font-size: 11px; font-weight: 800; color: var(--text3); letter-spacing: 2px; text-transform: uppercase; }
.admin-nav-item { display: flex; align-items: center; gap: 10px; padding: 11px 20px; cursor: pointer; font-size: 14px; color: var(--text2); transition: var(--transition); font-weight: 500; }
.admin-nav-item:hover { color: var(--text); background: var(--bg2); }
.admin-nav-item.active { color: var(--primary); background: rgba(108,99,255,0.08); border-left: 3px solid var(--primary); font-weight: 700; }
.admin-nav-item .admin-nav-icon { font-size: 16px; }
.admin-main { flex: 1; padding: 36px 44px; overflow-y: auto; background: var(--bg); }
.admin-section-title { font-size: 24px; font-weight: 900; margin-bottom: 8px; color: var(--text); }
.admin-section-desc { font-size: 14px; color: var(--text2); margin-bottom: 28px; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; margin-bottom: 32px; }
.stat-card { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow-card); }
.stat-card .stat-label { font-size: 12px; color: var(--text3); margin-bottom: 10px; font-weight: 600; letter-spacing: 0.5px; }
.stat-card .stat-value { font-size: 34px; font-weight: 900; line-height: 1; color: var(--text); }
.stat-card .stat-value.red { color: var(--red); } .stat-card .stat-value.green { color: var(--success); } .stat-card .stat-value.orange { color: var(--orange); }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th { text-align: left; padding: 12px 16px; font-size: 12px; color: var(--text3); font-weight: 700; border-bottom: 1.5px solid var(--border); white-space: nowrap; background: var(--bg2); letter-spacing: 0.5px; }
.data-table td { padding: 13px 16px; font-size: 13px; border-bottom: 1px solid var(--border); color: var(--text2); }
.data-table tr:hover td { background: rgba(108,99,255,0.03); color: var(--text); }
.table-wrap { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius); overflow: hidden; overflow-x: auto; box-shadow: var(--shadow-card); }
.toggle { position: relative; width: 46px; height: 26px; cursor: pointer; display: inline-block; }
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; inset: 0; background: var(--bg2); border-radius: 13px; transition: var(--transition); border: 1.5px solid var(--border); }
.toggle-slider::before { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; left: 4px; top: 4px; background: #C5CAF0; transition: var(--transition); }
.toggle input:checked + .toggle-slider { background: var(--gradient); border-color: transparent; }
.toggle input:checked + .toggle-slider::before { transform: translateX(20px); background: #fff; }
.admin-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.admin-search { flex: 1; min-width: 200px; }

/* ============================================ 空状态 / 加载 */
.empty-state { text-align: center; padding: 60px 24px; color: var(--text3); }
.empty-state .empty-icon { font-size: 52px; margin-bottom: 16px; opacity: 0.4; }
.empty-state .empty-title { font-size: 16px; font-weight: 700; margin-bottom: 8px; color: var(--text2); }
.empty-state .empty-desc { font-size: 13px; }
.spinner { width: 26px; height: 26px; border-radius: 50%; border: 3px solid var(--bg2); border-top-color: var(--primary); animation: spin 0.8s linear infinite; margin: 0 auto; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-wrap { display: flex; align-items: center; justify-content: center; padding: 60px; }

/* ============================================ 模态框 */
.modal-overlay { position: fixed; inset: 0; background: rgba(26,26,62,0.35); z-index: 1000; display: flex; align-items: center; justify-content: center; padding: 20px; backdrop-filter: blur(4px); }
.modal-box { background: var(--card); border: 1.5px solid var(--border); border-radius: var(--radius-lg); padding: 36px; max-width: 500px; width: 100%; box-shadow: 0 12px 60px rgba(108,99,255,0.2); }
.modal-title { font-size: 20px; font-weight: 800; margin-bottom: 16px; color: var(--text); }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }

/* ============================================ 章节颜色 */
.tag-ch1 { background: rgba(6,214,160,0.12); color: #059669; border: 1.5px solid rgba(6,214,160,0.25); }
.tag-ch2 { background: rgba(255,107,53,0.1); color: var(--orange); border: 1.5px solid rgba(255,107,53,0.2); }
.tag-ch3 { background: rgba(67,97,238,0.1); color: var(--info); border: 1.5px solid rgba(67,97,238,0.2); }
.tag-ch4 { background: rgba(255,71,87,0.1); color: var(--red); border: 1.5px solid rgba(255,71,87,0.2); }
.tag-ch5 { background: rgba(108,99,255,0.1); color: var(--primary); border: 1.5px solid rgba(108,99,255,0.2); }

/* ============================================ 响应式 */
@media (max-width: 768px) {
  .layout-sidebar { display: none; }
  .layout-content { margin-left: 0; padding: 20px 16px; }
  .chapter-grid { grid-template-columns: 1fr; }
  .home-hero .hero-stats { gap: 24px; }
  .camp-banner { flex-direction: column; gap: 20px; }
  .admin-sidebar { display: none; }
  .admin-main { padding: 20px 16px; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .auth-box { padding: 28px 20px; }
  .lesson-nav { flex-direction: column; gap: 12px; }
}
@media (max-width: 480px) {
  .navbar-brand .brand-name { display: none; }
  .home-hero .hero-title { font-size: 28px; }
  .stat-grid { grid-template-columns: 1fr 1fr; }
  .camp-hero h1 { font-size: 32px; }
}
