/* ===== 设计系统变量 ===== */
:root {
  --primary: #2563EB;
  --primary-dark: #1d4ed8;
  --primary-light: #dbeafe;
  --accent-yellow: #FBBF24;
  --accent-green: #10B981;
  --neutral-bg: #F3F4F6;
  --neutral-text: #6B7280;
  --white: #FFFFFF;
  --dark: #111827;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-md: 0 4px 14px rgba(0,0,0,0.08);
  --radius-8: 8px;
  --radius-10: 10px;
  --transition: 0.3s ease;
}

/* ===== 全局重置 ===== */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "微软雅黑", "Microsoft YaHei", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--dark);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

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

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

ul { list-style: none; }

/* ===== 版心 ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== 区块间距 ===== */
.section { padding: 70px 0; }
.section--alt { background: var(--neutral-bg); }

.section-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--dark);
  text-align: center;
  margin-bottom: 12px;
}

.section-subtitle {
  font-size: 16px;
  color: var(--neutral-text);
  text-align: center;
  margin-bottom: 40px;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-block;
  padding: 12px 32px;
  border-radius: var(--radius-8);
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  text-align: center;
  transition: background var(--transition), opacity var(--transition);
}

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

.btn--outline {
  background: var(--white);
  color: var(--primary);
  border: 2px solid var(--primary);
}
.btn--outline:hover {
  background: var(--primary);
  color: var(--white);
}

/* ===== 卡片 ===== */
.card {
  background: var(--white);
  border-radius: var(--radius-10);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  transition: transform var(--transition), box-shadow var(--transition);
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

/* ===== 顶部导航 ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--white);
  box-shadow: var(--shadow-sm);
  height: 70px;
  display: flex;
  align-items: center;
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.navbar-brand {
  font-size: 22px;
  font-weight: 700;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 10px;
}

.navbar-brand .brand-icon {
  width: 36px;
  height: 36px;
  background: var(--primary);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 18px;
  font-weight: 700;
}

.navbar-links {
  display: flex;
  gap: 28px;
}

.navbar-links a {
  font-size: 15px;
  color: var(--dark);
  font-weight: 500;
  position: relative;
  padding-bottom: 4px;
}

.navbar-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width var(--transition);
}

.navbar-links a:hover {
  color: var(--primary);
}
.navbar-links a:hover::after {
  width: 100%;
}

.navbar-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.navbar-toggle svg {
  width: 24px;
  height: 24px;
  stroke: var(--dark);
  stroke-width: 2;
  fill: none;
}

/* ===== 首页轮播 ===== */
.hero {
  margin-top: 70px;
  position: relative;
  overflow: hidden;
  background: var(--primary);
  color: var(--white);
  height: 500px;
}

.hero-slider {
  position: relative;
  height: 100%;
}

.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.hero-slide.active {
  opacity: 1;
}

.hero-slide .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.hero-content {
  flex: 1;
  max-width: 560px;
}

.hero-content h1 {
  font-size: 44px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 16px;
}

.hero-content p {
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 28px;
  opacity: 0.9;
}

.hero-visual {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-icon-block {
  width: 260px;
  height: 260px;
  background: rgba(255,255,255,0.12);
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 80px;
}

.hero-dots {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  cursor: pointer;
  transition: background var(--transition), width var(--transition);
}

.hero-dot.active {
  background: var(--accent-yellow);
  width: 28px;
  border-radius: 5px;
}

/* ===== 辅导科目 ===== */
.subjects-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.subject-card {
  text-align: center;
  padding: 28px 20px;
}

.subject-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto 16px;
  background: var(--primary-light);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--primary);
  transition: background var(--transition);
}

.subject-card:hover .subject-icon {
  background: var(--primary);
  color: var(--white);
}

.subject-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
}

.subject-card p {
  font-size: 14px;
  color: var(--neutral-text);
  line-height: 1.5;
}

/* ===== 优秀师资 ===== */
.teachers-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.teacher-card {
  text-align: center;
  padding: 28px 16px;
}

.teacher-avatar {
  width: 80px;
  height: 80px;
  margin: 0 auto 14px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--primary);
  font-weight: 700;
}

.teacher-card h3 {
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 4px;
}

.teacher-tag {
  display: inline-block;
  font-size: 12px;
  background: var(--primary-light);
  color: var(--primary);
  padding: 2px 10px;
  border-radius: 4px;
  margin-bottom: 8px;
}

.teacher-card p {
  font-size: 14px;
  color: var(--neutral-text);
  line-height: 1.5;
}

/* ===== 教学优势 ===== */
.advantages-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.advantage-card {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 24px;
}

.advantage-icon {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  background: var(--accent-green);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 22px;
}

.advantage-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 6px;
}

.advantage-card p {
  font-size: 14px;
  color: var(--neutral-text);
  line-height: 1.5;
}

/* ===== 收费标准 ===== */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.pricing-card {
  text-align: center;
  padding: 32px 24px;
  position: relative;
  overflow: hidden;
}

.pricing-card.featured {
  border: 2px solid var(--primary);
}

.pricing-badge {
  position: absolute;
  top: 0;
  right: 0;
  background: var(--accent-yellow);
  color: var(--dark);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 0 0 8px 0;
}

.pricing-card h3 {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 8px;
}

.pricing-desc {
  font-size: 14px;
  color: var(--neutral-text);
  margin-bottom: 20px;
}

.pricing-price {
  font-size: 36px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.pricing-unit {
  font-size: 14px;
  color: var(--neutral-text);
  margin-bottom: 20px;
}

.pricing-features {
  margin-bottom: 24px;
}

.pricing-features li {
  font-size: 14px;
  color: var(--dark);
  padding: 6px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.pricing-features li .check {
  color: var(--accent-green);
  font-weight: 700;
}

/* ===== 预约报名 ===== */
.signup-section {
  background: var(--primary);
  color: var(--white);
  padding: 80px 0;
}

.signup-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.signup-info h2 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 16px;
}

.signup-info p {
  font-size: 16px;
  line-height: 1.7;
  opacity: 0.9;
  margin-bottom: 24px;
}

.signup-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.signup-highlights .highlight {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
}

.highlight-icon {
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.2);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.signup-form {
  background: var(--white);
  border-radius: var(--radius-10);
  padding: 32px;
  color: var(--dark);
}

.signup-form h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--primary);
}

.form-group {
  margin-bottom: 16px;
}

.form-group label {
  display: block;
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--dark);
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #d1d5db;
  border-radius: var(--radius-8);
  font-size: 15px;
  font-family: inherit;
  background: var(--white);
  transition: border-color var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
}

.form-group textarea {
  resize: vertical;
  min-height: 80px;
}

/* ===== 关于我们 ===== */
.about-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.about-image {
  width: 100%;
  height: 320px;
  background: var(--primary-light);
  border-radius: var(--radius-10);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 60px;
  color: var(--primary);
}

.about-content h2 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 16px;
}

.about-content p {
  font-size: 16px;
  color: var(--neutral-text);
  line-height: 1.7;
  margin-bottom: 16px;
}

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

.stat-item {
  text-align: center;
  padding: 16px;
  background: var(--neutral-bg);
  border-radius: var(--radius-8);
}

.stat-number {
  font-size: 28px;
  font-weight: 700;
  color: var(--primary);
}

.stat-label {
  font-size: 13px;
  color: var(--neutral-text);
  margin-top: 4px;
}

/* ===== 联系我们 ===== */
.contact-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.contact-item-icon {
  width: 44px;
  height: 44px;
  background: var(--primary-light);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  color: var(--primary);
  flex-shrink: 0;
}

.contact-item h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 4px;
}

.contact-item p {
  font-size: 14px;
  color: var(--neutral-text);
}

.contact-map {
  width: 100%;
  height: 360px;
  background: var(--neutral-bg);
  border-radius: var(--radius-10);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--neutral-text);
  font-size: 14px;
}

/* ===== 页面头（子页面顶部 Banner） ===== */
.page-banner {
  margin-top: 70px;
  background: var(--primary);
  color: var(--white);
  padding: 60px 0 40px;
  text-align: center;
}

.page-banner h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 12px;
}

.page-banner p {
  font-size: 16px;
  opacity: 0.85;
}

@media (max-width: 768px) {
  .page-banner { padding: 40px 0 30px; }
  .page-banner h1 { font-size: 26px; }
}

@media (max-width: 360px) {
  .page-banner { padding: 32px 0 24px; }
  .page-banner h1 { font-size: 22px; }
}

/* ===== 页脚 ===== */
.footer {
  background: var(--dark);
  color: var(--white);
  padding: 48px 0 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 32px;
}

.footer-brand {
  font-size: 20px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 12px;
}

.footer-desc {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  line-height: 1.6;
}

.footer h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 12px;
}

.footer-links a {
  display: block;
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  padding: 4px 0;
}
.footer-links a:hover {
  color: var(--white);
}

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 20px;
  text-align: center;
  font-size: 13px;
  color: rgba(255,255,255,0.4);
}

/* ===== 响应式 - 768px ===== */
@media (max-width: 768px) {
  .navbar-links { display: none; }
  .navbar-toggle { display: block; }

  .navbar-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 16px 20px;
    box-shadow: var(--shadow-md);
    gap: 12px;
  }

  .hero { height: 420px; }
  .hero-slide .container { flex-direction: column; text-align: center; }
  .hero-content h1 { font-size: 30px; }
  .hero-content p { font-size: 16px; }
  .hero-visual { display: none; }

  .section-title { font-size: 26px; }

  .subjects-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .teachers-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .advantages-list { grid-template-columns: 1fr; gap: 20px; }
  .pricing-grid { grid-template-columns: 1fr; gap: 20px; }

  .signup-wrap { grid-template-columns: 1fr; }
  .about-wrap { grid-template-columns: 1fr; }
  .about-image { height: 220px; }
  .contact-wrap { grid-template-columns: 1fr; }

  .footer-grid { grid-template-columns: 1fr 1fr; gap: 24px; }
}

/* ===== 响应式 - 360px ===== */
@media (max-width: 360px) {
  .hero { height: 360px; }
  .hero-content h1 { font-size: 24px; }

  .section { padding: 50px 0; }
  .section-title { font-size: 22px; }

  .subjects-grid { grid-template-columns: 1fr; }
  .teachers-grid { grid-template-columns: 1fr; }
  .pricing-grid { grid-template-columns: 1fr; }

  .btn { padding: 10px 24px; font-size: 14px; }

  .footer-grid { grid-template-columns: 1fr; }
}

/* ===== 子页面组件 ===== */

/* 科目详情卡片 */
.subject-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.subject-detail-card {
  padding: 28px 24px;
}

.subject-detail-card h3 {
  font-size: 18px;
  font-weight: 600;
  margin: 12px 0 12px;
}

.subject-detail-body p {
  font-size: 14px;
  color: var(--neutral-text);
  margin-bottom: 12px;
}

.subject-detail-body ul {
  padding-left: 0;
  list-style: none;
}

.subject-detail-body li {
  font-size: 14px;
  color: var(--dark);
  padding: 5px 0;
  position: relative;
  padding-left: 16px;
}

.subject-detail-body li::before {
  content: '•';
  color: var(--primary);
  position: absolute;
  left: 0;
  font-weight: 700;
}

/* 优势详情页 */
.advantage-detail-wrap {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 32px;
  align-items: start;
}

.advantage-detail-icon {
  width: 80px;
  height: 80px;
  background: var(--primary-light);
  border-radius: var(--radius-10);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 36px;
  color: var(--primary);
  text-align: center;
}

.advantage-detail-content h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 12px;
}

.advantage-detail-content > p {
  font-size: 16px;
  color: var(--neutral-text);
  line-height: 1.7;
  margin-bottom: 24px;
}

.advantage-steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.advantage-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.step-num {
  width: 32px;
  height: 32px;
  background: var(--primary);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  flex-shrink: 0;
}

.advantage-step h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
}

.advantage-step p {
  font-size: 14px;
  color: var(--neutral-text);
}

.advantage-features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.advantage-features-grid .card {
  padding: 20px;
}

.advantage-features-grid .card h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
}

.advantage-features-grid .card p {
  font-size: 14px;
  color: var(--neutral-text);
}

/* 价格表格 */
.pricing-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius-10);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.pricing-table th {
  background: var(--primary);
  color: var(--white);
  padding: 14px 16px;
  font-size: 14px;
  font-weight: 600;
  text-align: left;
}

.pricing-table td {
  padding: 12px 16px;
  font-size: 14px;
  border-bottom: 1px solid var(--neutral-bg);
}

.pricing-table tr:hover td {
  background: var(--primary-light);
}

/* FAQ */
.faq-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  max-width: 900px;
  margin: 0 auto;
}

.faq-item {
  padding: 20px;
}

.faq-item h4 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--primary);
}

.faq-item p {
  font-size: 14px;
  color: var(--neutral-text);
  line-height: 1.5;
}

/* 发展历程时间线 */
.timeline {
  max-width: 700px;
  margin: 0 auto;
  position: relative;
  padding-left: 32px;
}

.timeline::before {
  content: '';
  position: absolute;
  left: 14px;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--primary-light);
}

.timeline-item {
  position: relative;
  padding-bottom: 28px;
  padding-left: 24px;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: -18px;
  top: 4px;
  width: 10px;
  height: 10px;
  background: var(--primary);
  border-radius: 50%;
}

.timeline-year {
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
  margin-bottom: 4px;
}

.timeline-content h4 {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 4px;
}

.timeline-content p {
  font-size: 14px;
  color: var(--neutral-text);
}

/* 家长好评 */
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.review-card {
  padding: 24px;
}

.review-header {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}

.review-avatar {
  width: 40px;
  height: 40px;
  background: var(--primary-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: 700;
  color: var(--primary);
  flex-shrink: 0;
}

.review-card p {
  font-size: 14px;
  color: var(--neutral-text);
  line-height: 1.6;
}

/* ===== 子页面响应式 ===== */
@media (max-width: 768px) {
  .subject-detail-grid { grid-template-columns: 1fr; }
  .advantage-detail-wrap { grid-template-columns: 1fr; }
  .advantage-detail-icon { width: 60px; height: 60px; font-size: 28px; margin-bottom: 16px; }
  .advantage-features-grid { grid-template-columns: 1fr; }
  .faq-list { grid-template-columns: 1fr; }
  .reviews-grid { grid-template-columns: 1fr; }
  .pricing-table th, .pricing-table td { padding: 10px 12px; font-size: 13px; }
}

@media (max-width: 360px) {
  .subject-detail-grid { grid-template-columns: 1fr; }
  .advantage-detail-wrap { grid-template-columns: 1fr; }
  .advantage-features-grid { grid-template-columns: 1fr; }
  .faq-list { grid-template-columns: 1fr; }
  .reviews-grid { grid-template-columns: 1fr; }
}