/* 浩然学习中心 - 活泼版样式 */
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", "PingFang SC", sans-serif;
  background: linear-gradient(135deg, #fef3c7 0%, #dbeafe 50%, #fce7f3 100%);
  background-attachment: fixed;
  color: #1f2937;
  line-height: 1.7;
  font-size: 15px;
}
a { color: #2563eb; text-decoration: none; }
a:hover { text-decoration: underline; }

/* 顶部导航 */
.navbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 2px solid #fcd34d;
  padding: 0 24px;
  height: 64px;
  display: flex;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}
.nav-brand {
  font-size: 18px;
  font-weight: 700;
  color: #db2777;
  margin-right: 24px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-brand::before { content: "🌈"; font-size: 22px; }
.nav-links {
  display: flex;
  gap: 6px;
  flex: 1;
  align-items: center;
  flex-wrap: wrap;
}
.nav-link {
  padding: 8px 16px;
  border-radius: 20px;
  color: #4b5563;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.2s;
  cursor: pointer;
}
.nav-link:hover { background: #fef3c7; color: #db2777; text-decoration: none; transform: scale(1.05); }
.nav-link.active { background: linear-gradient(135deg, #fbbf24, #f59e0b); color: white; }
.nav-link.home { background: #f3e8ff; }
.nav-link.home:hover { background: #e9d5ff; }

/* 主内容 */
.container { max-width: 1100px; margin: 0 auto; padding: 24px; }

/* 学科头 */
.subject-header {
  background: white;
  border-radius: 20px;
  padding: 28px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
  display: flex;
  align-items: center;
  gap: 20px;
}
.subject-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 40px;
  font-weight: bold;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.subject-icon.yuwen { background: linear-gradient(135deg, #f87171, #ec4899); }
.subject-icon.shuxue { background: linear-gradient(135deg, #60a5fa, #3b82f6); }
.subject-icon.yingyu { background: linear-gradient(135deg, #34d399, #10b981); }

.subject-info { flex: 1; }
.subject-title { font-size: 26px; font-weight: 700; color: #1e3a8a; margin-bottom: 6px; }
.subject-subtitle { color: #6b7280; font-size: 14px; }
.subject-stats { display: flex; gap: 20px; margin-top: 12px; flex-wrap: wrap; }
.stat-item { display: flex; flex-direction: column; }
.stat-value { font-size: 22px; font-weight: 700; color: #db2777; }
.stat-label { font-size: 12px; color: #6b7280; }

/* 单元卡片 */
.chapter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin-top: 16px;
}
.chapter-card {
  background: white;
  border-radius: 16px;
  padding: 20px;
  border-left: 4px solid;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  transition: all 0.2s;
  cursor: pointer;
}
.chapter-card:hover { transform: translateY(-2px); box-shadow: 0 6px 16px rgba(0,0,0,0.08); }
.chapter-card.yuwen { border-color: #f87171; }
.chapter-card.shuxue { border-color: #60a5fa; }
.chapter-card.yingyu { border-color: #34d399; }

.chapter-num {
  display: inline-block;
  background: #fef3c7;
  color: #d97706;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 12px;
  margin-bottom: 8px;
}
.chapter-title { font-size: 17px; font-weight: 700; color: #1f2937; margin-bottom: 6px; }
.chapter-desc { font-size: 13px; color: #6b7280; margin-bottom: 12px; }
.chapter-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.chapter-tag {
  background: #f3f4f6;
  color: #4b5563;
  padding: 2px 10px;
  border-radius: 10px;
  font-size: 11px;
}

/* 知识点详情 */
.section-block {
  background: white;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}
.section-title {
  font-size: 19px;
  font-weight: 700;
  color: #1e3a8a;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 2px dashed #fcd34d;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title::before { content: "⭐"; }
.section-subtitle {
  font-size: 16px;
  font-weight: 600;
  color: #db2777;
  margin: 14px 0 8px;
}
.section-list { padding-left: 24px; }
.section-list li { margin-bottom: 6px; }
.highlight-box {
  background: linear-gradient(135deg, #fef3c7, #fed7aa);
  border-radius: 12px;
  padding: 14px 18px;
  margin: 12px 0;
  border-left: 4px solid #f59e0b;
}
.highlight-box strong { color: #d97706; }
.formula {
  background: #1f2937;
  color: #fbbf24;
  padding: 12px 18px;
  border-radius: 10px;
  font-family: "Courier New", monospace;
  font-size: 16px;
  text-align: center;
  margin: 10px 0;
}
.tip-box {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  border-radius: 12px;
  padding: 14px 18px;
  margin: 12px 0;
  border-left: 4px solid #3b82f6;
}
.tip-box strong { color: #1e40af; }

/* 首页 hero */
.hero {
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 50%, #ec4899 100%);
  border-radius: 24px;
  padding: 40px 32px;
  color: white;
  text-align: center;
  margin-bottom: 24px;
  box-shadow: 0 8px 24px rgba(245, 158, 11, 0.3);
}
.hero h1 { font-size: 36px; margin-bottom: 12px; text-shadow: 0 2px 4px rgba(0,0,0,0.1); }
.hero p { font-size: 16px; opacity: 0.95; max-width: 600px; margin: 0 auto; }
.hero .emoji-row { font-size: 28px; margin-top: 12px; letter-spacing: 8px; }

/* 学科入口卡片 */
.subject-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}
.subject-card {
  background: white;
  border-radius: 20px;
  padding: 28px;
  text-align: center;
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
  transition: all 0.3s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
  display: block;
}
.subject-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(0,0,0,0.12); text-decoration: none; }
.subject-card .big-icon {
  width: 100px;
  height: 100px;
  border-radius: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 50px;
  color: white;
  margin: 0 auto 16px;
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
}
.subject-card h2 { font-size: 22px; font-weight: 700; margin-bottom: 8px; }
.subject-card .meta { color: #6b7280; font-size: 13px; margin-bottom: 12px; }
.subject-card .tag-row {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  margin-top: 12px;
}
.subject-card .tag {
  background: #fef3c7;
  color: #d97706;
  padding: 4px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
}

/* 鼓励卡片 */
.encourage-card {
  background: linear-gradient(135deg, #fce7f3, #fbcfe8);
  border-radius: 20px;
  padding: 24px;
  margin-bottom: 24px;
  text-align: center;
  border: 2px dashed #ec4899;
}
.encourage-card h3 { color: #be185d; margin-bottom: 8px; font-size: 20px; }
.encourage-card p { color: #831843; font-size: 15px; }

/* 倒计时 */
.countdown {
  background: white;
  border-radius: 16px;
  padding: 20px;
  margin-bottom: 24px;
  text-align: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.countdown-num {
  font-size: 48px;
  font-weight: 800;
  background: linear-gradient(135deg, #fbbf24, #ec4899);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.countdown-label { color: #6b7280; font-size: 14px; margin-top: 4px; }

/* 学习路径 */
.path-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 16px;
}
.path-step {
  background: white;
  border-radius: 12px;
  padding: 14px;
  text-align: center;
  position: relative;
}
.path-step-num {
  display: inline-block;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: white;
  border-radius: 50%;
  font-weight: 700;
  line-height: 32px;
  margin-bottom: 8px;
}
.path-step h4 { font-size: 14px; color: #1e3a8a; margin-bottom: 4px; }
.path-step p { font-size: 12px; color: #6b7280; }

/* 页脚 */
.footer {
  text-align: center;
  padding: 32px 0;
  color: #6b7280;
  font-size: 13px;
}
.footer .signature { color: #db2777; font-weight: 600; }

/* 响应式 */
@media (max-width: 640px) {
  .nav-brand { font-size: 16px; }
  .nav-link { padding: 6px 12px; font-size: 13px; }
  .hero h1 { font-size: 28px; }
  .subject-header { flex-direction: column; text-align: center; }
  .chapter-grid { grid-template-columns: 1fr; }
}

/* 思维导图占位 */
.mindmap {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-radius: 16px;
  padding: 20px;
  margin: 16px 0;
  text-align: center;
}
.mindmap-root {
  display: inline-block;
  background: linear-gradient(135deg, #fbbf24, #f59e0b);
  color: white;
  padding: 8px 24px;
  border-radius: 20px;
  font-weight: 700;
  margin-bottom: 16px;
}
.mindmap-branches {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.mindmap-branch {
  background: white;
  padding: 8px 16px;
  border-radius: 12px;
  font-size: 13px;
  color: #1e3a8a;
  border: 2px solid #93c5fd;
  font-weight: 600;
}