/* 慧文慧理成长中心 - 学而思/新东方成熟风格 */
:root {
  --primary: #0A6E63;        /* 主品牌深青绿 */
  --primary-dark: #095D54;
  --primary-light: #0D8A7D;
  --accent: #F5A623;          /* 橙 CTA */
  --accent-dark: #E89400;
  --deep: #123B34;            /* 墨绿深色区 */
  --bg: #F7F9FB;             /* 浅灰蓝背景 */
  --card: #FFFFFF;
  --line: #E5EBF0;
  --text: #1F2A37;
  --text-sub: #64748B;
  --muted: #94A3B8;
  --green-bg: #E8F5F2;        /* 浅绿标签底 */
  --green-text: #0A6E63;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
a { color: inherit; }
img { max-width: 100%; display: block; }

/* ===== 顶部导航 ===== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img.logo { width: 44px; height: 44px; border-radius: 10px; object-fit: cover; }
.brand-name { font-size: 20px; font-weight: 800; color: var(--deep); letter-spacing: 1px; }
.brand-sub { font-size: 11px; color: var(--muted); display: block; letter-spacing: 2px; margin-top: 1px; }
.nav-links { display: flex; align-items: center; gap: 34px; list-style: none; }
.nav-links a { text-decoration: none; color: var(--text-sub); font-size: 15.5px; font-weight: 500; transition: color .15s; position: relative; padding: 6px 0; }
.nav-links a:hover, .nav-links a.active { color: var(--primary); }
.nav-links a.active::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0;
  height: 2.5px; border-radius: 2px; background: var(--accent);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 12px 26px; border-radius: 12px; border: none; cursor: pointer;
  font-size: 15.5px; font-weight: 600; text-decoration: none;
  transition: all .2s;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 6px 18px rgba(245,166,35,.32); }
.btn-primary:hover { background: var(--accent-dark); transform: translateY(-1px); }
.btn-dark { background: var(--primary); color: #fff; box-shadow: 0 6px 18px rgba(10,110,99,.28); }
.btn-dark:hover { background: var(--primary-dark); transform: translateY(-1px); }
.btn-outline { background: #fff; color: var(--primary); border: 1.5px solid var(--primary); }
.btn-outline:hover { background: var(--green-bg); }
.btn-white { background: #fff; color: var(--primary); box-shadow: 0 6px 18px rgba(0,0,0,.14); }
.btn-white:hover { transform: translateY(-1px); }
.btn-sm { padding: 9px 18px; font-size: 14px; border-radius: 10px; }

/* ===== Banner 主视觉 ===== */
.hero {
  background:
    linear-gradient(100deg, rgba(18,59,52,.94) 0%, rgba(10,110,99,.88) 55%, rgba(13,138,125,.78) 100%),
    url('../img/hero-cover.jpg') center/cover;
  color: #fff;
  padding: 110px 0 120px;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: ''; position: absolute; right: -120px; top: -120px;
  width: 420px; height: 420px; border-radius: 50%;
  background: radial-gradient(circle, rgba(245,166,35,.22), transparent 70%);
}
.hero .container { position: relative; z-index: 1; }
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 600; letter-spacing: 2px;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.25);
  border-radius: 999px; padding: 7px 20px; margin-bottom: 24px; color: #fff;
}
.hero-eyebrow::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.hero h1 { font-size: 50px; font-weight: 900; letter-spacing: 1px; line-height: 1.32; }
.hero h1 .hl { color: var(--accent); }
.hero p.sub { font-size: 17.5px; color: rgba(255,255,255,.82); margin: 20px 0 38px; max-width: 560px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-phone { margin-top: 32px; font-size: 13.5px; color: rgba(255,255,255,.66); }
.hero-phone .tel { color: #fff; font-size: 26px; font-weight: 800; letter-spacing: 1px; margin-left: 12px; display: inline-flex; align-items: center; gap: 8px; }
.hero-phone .tel::before { content: ''; width: 1.5px; height: 22px; background: rgba(255,255,255,.3); }

/* ===== 数据带 ===== */
.stats-band { background: #fff; border-bottom: 1px solid var(--line); padding: 46px 0; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat-num { font-size: 40px; font-weight: 900; color: var(--primary); letter-spacing: -1px; }
.stat-label { font-size: 13.5px; color: var(--text-sub); margin-top: 4px; }
.stats-band .stat-num { color: var(--primary); }

/* ===== 通用区段 ===== */
.section { padding: 88px 0; }
.section-gray { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { text-align: center; max-width: 680px; margin: 0 auto 56px; }
.section-head .kicker {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12.5px; font-weight: 700; color: var(--primary); letter-spacing: 4px; margin-bottom: 12px;
}
.section-head .kicker::before, .section-head .kicker::after { content: ''; width: 20px; height: 1.5px; background: var(--accent); }
.section-head h2 { font-size: 34px; font-weight: 900; color: var(--deep); letter-spacing: 1px; }
.section-head p { color: var(--text-sub); margin-top: 14px; font-size: 15.5px; }

/* ===== 课程卡片 ===== */
.card-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.card-grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.course-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 18px;
  padding: 34px 28px; transition: all .25s;
  display: flex; flex-direction: column; position: relative; overflow: hidden;
}
.course-card::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  opacity: 0; transition: opacity .25s;
}
.course-card:hover::before { opacity: 1; }
.course-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 18px 44px rgba(18,59,52,.12);
  border-color: transparent;
}
.course-icon {
  width: 56px; height: 56px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin-bottom: 20px;
  background: linear-gradient(135deg, var(--green-bg), #F0FAF8);
}
.course-card h3 { font-size: 20px; font-weight: 800; color: var(--deep); margin-bottom: 4px; }
.course-tag {
  display: inline-flex; align-items: center; font-size: 12px; font-weight: 700;
  color: var(--primary); background: var(--green-bg);
  border-radius: 999px; padding: 4px 12px; margin: 10px 0 14px; align-self: flex-start;
}
.course-card p { font-size: 14.5px; color: var(--text-sub); flex: 1; }
.course-card ul { font-size: 13.5px; color: var(--text-sub); margin: 14px 0 0 18px; flex: 1; }
.course-card ul li { margin-bottom: 6px; }
.course-card .link {
  margin-top: 20px; font-size: 14.5px; font-weight: 700;
  color: var(--primary); text-decoration: none; display: inline-flex; align-items: center; gap: 4px;
}
.course-card .link:hover { color: var(--accent-dark); }

/* ===== 特色卡片 ===== */
.feature-card {
  text-align: center; padding: 44px 30px;
  background: var(--card); border-radius: 20px;
  border: 1px solid var(--line); transition: all .25s;
}
.feature-card:hover { box-shadow: 0 18px 44px rgba(18,59,52,.09); transform: translateY(-4px); border-color: var(--primary-light); }
.feature-icon {
  width: 70px; height: 70px; margin: 0 auto 22px; border-radius: 50%;
  background: linear-gradient(135deg, var(--green-bg), #F0FAF8);
  display: flex; align-items: center; justify-content: center; font-size: 30px;
}
.feature-card h3 { font-size: 19px; font-weight: 800; margin-bottom: 12px; color: var(--deep); }
.feature-card p { font-size: 14.5px; color: var(--text-sub); }

/* ===== 口碑 ===== */
.quote-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 18px; padding: 32px; position: relative;
}
.quote-card::before { content: '“'; position: absolute; top: 12px; right: 24px; font-size: 72px; color: var(--green-bg); font-weight: 900; line-height: 1; }
.quote-card .stars { color: var(--accent); font-size: 16px; letter-spacing: 4px; margin-bottom: 14px; }
.quote-card p { font-size: 15px; color: var(--text-sub); position: relative; }
.quote-card .who { margin-top: 18px; font-size: 13px; color: var(--muted); }
.quote-card .who strong { color: var(--deep); font-size: 14px; display: block; margin-bottom: 2px; }

/* ===== 走廊/地图 ===== */
.gallery-grid { display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: repeat(2, 200px); gap: 14px; }
.gallery-item {
  border-radius: 16px; overflow: hidden; position: relative;
  background: #fff; border: 1px solid var(--line);
}
.gallery-item:first-child { grid-column: span 2; grid-row: span 2; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery-item:hover img { transform: scale(1.05); }
.gallery-item .cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 30px 16px 12px;
  background: linear-gradient(transparent, rgba(18,59,52,.8));
  color: #fff; font-size: 14px; font-weight: 600;
}
.gallery-grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); grid-template-rows: 260px; gap: 14px; }
.gallery-grid-4 .gallery-item:first-child { grid-column: auto; grid-row: auto; }
.img-placeholder {
  width: 100%; height: 100%;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  color: var(--muted); font-size: 14px;
  background: linear-gradient(135deg, #F0FAF8, #E4F2EF);
}
.img-placeholder .ico { font-size: 34px; }

/* ===== 页面横幅（内页） ===== */
.page-hero {
  background:
    linear-gradient(110deg, rgba(18,59,52,.95), rgba(10,110,99,.88)),
    url('../img/hero-cover.jpg') center/cover;
  color: #fff; padding: 76px 0; text-align: center; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; left: -80px; bottom: -140px;
  width: 340px; height: 340px; border-radius: 50%;
  background: radial-gradient(circle, rgba(245,166,35,.16), transparent 70%);
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1 { font-size: 38px; font-weight: 900; letter-spacing: 2px; }
.page-hero p { color: rgba(255,255,255,.8); margin-top: 14px; font-size: 16px; }
.page-hero .crumb { margin-top: 16px; font-size: 13px; color: rgba(255,255,255,.55); }
.page-hero .crumb a { color: rgba(255,255,255,.75); text-decoration: none; }
.page-hero .crumb a:hover { color: #fff; }

/* ===== 表单 ===== */
.form-card {
  background: var(--card); border: 1px solid var(--line);
  border-radius: 22px; padding: 44px;
  box-shadow: 0 16px 52px rgba(18,59,52,.08);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 14.5px; font-weight: 600; color: var(--deep); margin-bottom: 8px; }
.form-group label .req { color: #E4283D; }
.form-control {
  width: 100%; padding: 12px 16px;
  border: 1.5px solid var(--line); border-radius: 12px;
  font-size: 15px; font-family: inherit;
  transition: all .15s; background: #FAFBFC;
}
.form-control:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(10,110,99,.12); background: #fff;
}
.form-success { display: none; text-align: center; padding: 36px 0; }
.form-success.show { display: block; }
.form-success .ok-icon {
  width: 70px; height: 70px; border-radius: 50%;
  background: var(--green-bg); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 34px; margin: 0 auto 18px;
}

/* ===== FAQ ===== */
.faq-item { background: var(--card); border: 1px solid var(--line); border-radius: 14px; margin-bottom: 14px; overflow: hidden; transition: border-color .2s; }
.faq-item.open { border-color: var(--primary); }
.faq-q { padding: 20px 24px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; font-weight: 700; font-size: 15.5px; color: var(--deep); user-select: none; }
.faq-q .arrow { transition: transform .2s; color: var(--muted); font-size: 12px; }
.faq-item.open .faq-q .arrow { transform: rotate(180deg); color: var(--accent); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .25s ease; }
.faq-a-inner { padding: 0 24px 18px; font-size: 14.5px; color: var(--text-sub); }

/* ===== CTA 横幅 ===== */
.cta-band {
  background:
    linear-gradient(110deg, rgba(18,59,52,.96), rgba(10,110,99,.9)),
    url('../img/hero-cover.jpg') center/cover;
  color: #fff; text-align: center; padding: 72px 0; position: relative; overflow: hidden;
}
.cta-band::after { content: ''; position: absolute; right: -100px; top: -100px; width: 380px; height: 380px; border-radius: 50%; background: radial-gradient(circle, rgba(245,166,35,.2), transparent 70%); }
.cta-band .container { position: relative; z-index: 1; }
.cta-band h2 { font-size: 30px; font-weight: 900; margin-bottom: 12px; }
.cta-band p { color: rgba(255,255,255,.85); margin-bottom: 30px; }

/* ===== 底部 ===== */
.site-footer { background: var(--deep); color: rgba(255,255,255,.62); padding: 64px 0 0; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1.4fr; gap: 40px; padding-bottom: 48px; }
.site-footer h4 { color: #fff; font-size: 15.5px; margin-bottom: 18px; font-weight: 700; }
.site-footer a { color: rgba(255,255,255,.62); text-decoration: none; font-size: 14px; display: block; margin-bottom: 11px; }
.site-footer a:hover { color: var(--accent); }
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img.logo { width: 46px; height: 46px; border-radius: 10px; }
.footer-brand-name { color: #fff; font-size: 20px; font-weight: 800; }
.footer-about { font-size: 13.5px; line-height: 1.9; margin-top: 14px; color: rgba(255,255,255,.5); }
.footer-contact .tel { color: var(--accent); font-size: 24px; font-weight: 800; }
.site-footer .footer-contact p { font-size: 14px; margin-bottom: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.09);
  padding: 20px 0; font-size: 12.5px;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px;
}
.footer-bottom a { color: rgba(255,255,255,.45); display: inline; margin: 0; }
.footer-bottom a:hover { color: var(--accent); }
.admin-entry { opacity: .3; }
.admin-entry:hover { opacity: .7; }

/* ===== 教师卡片 ===== */
.teacher-card { background: var(--card); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; transition: all .25s; }
.teacher-card:hover { box-shadow: 0 18px 44px rgba(18,59,52,.11); transform: translateY(-4px); }
.teacher-photo { height: 260px; position: relative; }
.teacher-photo img { width: 100%; height: 100%; object-fit: cover; }
.teacher-photo .fallback { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--green-bg), #F0FAF8); color: var(--primary); font-size: 22px; font-weight: 800; }
.teacher-info { padding: 22px 24px; }
.teacher-info h3 { font-size: 18px; font-weight: 800; color: var(--deep); }
.teacher-info .meta { font-size: 12.5px; color: var(--accent-dark); margin: 5px 0 12px; font-weight: 700; }
.teacher-info p { font-size: 14px; color: var(--text-sub); }

/* ===== 学科卡片 ===== */
.subject-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 26px; display: flex; gap: 18px; align-items: flex-start; transition: all .2s; }
.subject-card:hover { border-color: var(--primary); box-shadow: 0 12px 32px rgba(18,59,52,.08); transform: translateY(-2px); }
.subject-badge { width: 52px; height: 52px; border-radius: 14px; flex-shrink: 0; background: linear-gradient(135deg, var(--green-bg), #F0FAF8); color: var(--primary); display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 800; }
.subject-card h3 { font-size: 17px; font-weight: 800; color: var(--deep); margin-bottom: 6px; }
.subject-card p { font-size: 14px; color: var(--text-sub); }

/* ===== 视频区 ===== */
.video-wrap { border-radius: 20px; overflow: hidden; box-shadow: 0 18px 44px rgba(18,59,52,.14); border: 1px solid var(--line); }
.video-wrap video { width: 100%; display: block; background: #000; }
.video-caption { background: #fff; padding: 20px 24px; font-size: 14px; color: var(--text-sub); border-top: 1px solid var(--line); }

/* ===== 吉祥物 ===== */
.mascot-float { display: inline-flex; align-items: center; gap: 16px; }
.mascot-float img { width: 72px; height: 72px; border-radius: 16px; object-fit: cover; box-shadow: 0 8px 24px rgba(18,59,52,.18); }
.mascot-float .text { text-align: left; }
.mascot-float .text strong { display: block; color: #fff; font-size: 15px; }

/* ===== 响应式 ===== */
@media (max-width: 960px) {
  .nav-links { display: none; }
  .card-grid, .card-grid-3 { grid-template-columns: 1fr 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 30px; }
  .gallery-grid { grid-template-columns: 1fr 1fr; grid-template-rows: auto; }
  .gallery-item:first-child { grid-column: span 2; }
  .gallery-grid-4 { grid-template-columns: 1fr 1fr; grid-template-rows: repeat(2, 220px); }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .hero h1 { font-size: 36px; }
}
@media (max-width: 600px) {
  .card-grid, .card-grid-3 { grid-template-columns: 1fr; }
  .hero { padding: 80px 0 90px; }
  .hero h1 { font-size: 29px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .hero-actions .btn { width: 100%; }
  .section { padding: 64px 0; }
  .section-head h2 { font-size: 27px; }
  .gallery-grid-4 { grid-template-columns: 1fr; grid-template-rows: auto; }
  .gallery-grid-4 .gallery-item { height: 260px; }
}

/* ===== logo 尺寸修正 ===== */
.brand img.logo,
.nav-wrap img.logo {
  width: 46px !important;
  height: 46px !important;
  max-width: none;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}
.footer-brand img.logo {
  width: 48px !important;
  height: 48px !important;
  max-width: none;
  border-radius: 10px;
  object-fit: cover;
  flex-shrink: 0;
}
