/* ============================================================
   知校汇 zhixiaohui.com.cn — 全局样式
   品牌色: #0052CC 深蓝 | 辅助: #4C9AFF 浅蓝
   字体: 思源黑体(中文) + Inter(英文)
   版本: v1.0
   ============================================================ */

/* ---------- 字体导入 ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Noto+Sans+SC:wght@400;500;700&display=swap');

/* ---------- 全局基础 ---------- */
:root {
  --primary: #0052CC;
  --primary-light: #4C9AFF;
  --primary-dark: #003D99;
  --white: #FFFFFF;
  --dark: #222222;
  --gray-50: #F8FAFC;
  --gray-100: #F1F5F9;
  --gray-200: #E2E8F0;
  --gray-300: #CBD5E1;
  --gray-400: #94A3B8;
  --gray-500: #64748B;
  --gray-600: #475569;
  --gray-700: #334155;
  --gray-800: #1E293B;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.07);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.08);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  font-family: 'Inter', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--dark);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ---------- 全局动效 ---------- */
/* 页面淡入 */
.page-fade-in {
  animation: fadeInUp 0.5s ease-out;
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Hover 上浮 */
.hover-lift {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.hover-lift:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* ---------- 导航栏 ---------- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--gray-200);
  transition: box-shadow 0.3s;
}
.navbar.scrolled { box-shadow: var(--shadow-md); }
.nav-link {
  position: relative;
  color: var(--gray-600);
  font-weight: 500;
  font-size: 0.95rem;
  transition: color 0.2s;
  text-decoration: none;
  padding: 0.5rem 0;
}
.nav-link:hover,
.nav-link.active { color: var(--primary); }
.nav-link::after {
  content: '';
  position: absolute; bottom: -2px; left: 0; right: 0;
  height: 2px; background: var(--primary);
  transform: scaleX(0); transition: transform 0.25s;
}
.nav-link:hover::after,
.nav-link.active::after { transform: scaleX(1); }

/* 汉堡菜单按钮 */
.hamburger { display: none; background: none; border: none; cursor: pointer; padding: 8px; }
.hamburger span {
  display: block; width: 24px; height: 2px;
  background: var(--dark); margin: 5px 0;
  transition: all 0.3s;
}
.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px,-5px); }

/* 移动端导航 */
@media (max-width: 768px) {
  .hamburger { display: block; }
  .nav-links {
    display: none; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--white); border-top: 1px solid var(--gray-200);
    padding: 1rem; box-shadow: var(--shadow-lg);
  }
  .nav-links.open { display: flex; }
}

/* ---------- 按钮系统 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 0.75rem 2rem;
  border-radius: 6px; border: none; cursor: pointer;
  font-weight: 600; font-size: 1rem;
  text-decoration: none; line-height: 1.5;
  transition: all 0.2s;
}
.btn-primary {
  background: var(--primary); color: var(--white);
}
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); }
.btn-outline {
  background: transparent; color: var(--primary);
  border: 2px solid var(--primary);
}
.btn-outline:hover { background: var(--primary); color: var(--white); }
.btn-lg  { padding: 0.9rem 2.5rem; font-size: 1.05rem; }
.btn-sm  { padding: 0.5rem 1.25rem; font-size: 0.875rem; }

/* ---------- 板块标题 ---------- */
.section-title {
  font-size: 2rem; font-weight: 700; color: var(--dark);
  text-align: center; margin-bottom: 0.5rem;
}
.section-subtitle {
  font-size: 1.05rem; color: var(--gray-500);
  text-align: center; margin-bottom: 2.5rem;
}
.section-divider {
  width: 60px; height: 3px; background: var(--primary);
  margin: 0 auto 2rem;
}

/* ---------- 卡片 ---------- */
.card {
  background: var(--white); border: 1px solid var(--gray-200);
  border-radius: 10px; padding: 2rem;
  transition: all 0.25s;
}
.card:hover {
  border-color: var(--primary-light);
  box-shadow: var(--shadow-lg);
}

/* ---------- Hero Banner ---------- */
.hero-section {
  background: linear-gradient(135deg, #F0F4FF 0%, #E8F0FE 50%, #F5F7FA 100%);
  padding: 8rem 0 5rem;
  text-align: center;
}
.hero-title {
  font-size: 2.5rem; font-weight: 700;
  color: var(--dark); line-height: 1.3;
  margin-bottom: 1rem;
}
.hero-title span { color: var(--primary); }
.hero-desc {
  font-size: 1.15rem; color: var(--gray-600);
  max-width: 600px; margin: 0 auto 2.5rem;
}

/* ---------- 业务板块 ---------- */
.biz-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}
@media (max-width: 1024px) { .biz-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .biz-grid { grid-template-columns: 1fr; } }

.biz-card {
  text-align: center; padding: 2.5rem 1.5rem;
  border-radius: 10px; border: 1px solid var(--gray-200);
  background: var(--white); transition: all 0.25s;
}
.biz-card:hover { border-color: var(--primary-light); transform: translateY(-4px); }
.biz-icon {
  width: 56px; height: 56px; margin: 0 auto 1rem;
  background: #EEF2FF; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; color: var(--primary);
}

/* ---------- 优势区 ---------- */
.advantage-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2rem;
}
@media (max-width: 1024px) { .advantage-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .advantage-grid { grid-template-columns: 1fr; } }

.advantage-item { text-align: center; }
.advantage-num {
  font-size: 2.5rem; font-weight: 700; color: var(--primary);
  line-height: 1;
}
.advantage-label { color: var(--gray-500); margin-top: 0.5rem; font-size: 0.95rem; }

/* ---------- 案例轮播 ---------- */
.carousel-container {
  position: relative; overflow: hidden;
  margin: 0 auto; max-width: 900px;
}
.carousel-track {
  display: flex; transition: transform 0.5s ease;
}
.carousel-card {
  flex: 0 0 100%; padding: 2rem;
  background: var(--gray-50); border-radius: 10px;
  border: 1px solid var(--gray-200);
}
.carousel-dots {
  display: flex; justify-content: center; gap: 8px; margin-top: 1.5rem;
}
.carousel-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--gray-300); border: none; cursor: pointer;
  transition: background 0.3s;
}
.carousel-dot.active { background: var(--primary); }

/* ---------- 弹窗 ---------- */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 2000;
  background: rgba(0,0,0,0.5); align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal-box {
  background: var(--white); border-radius: 12px;
  padding: 2.5rem; max-width: 480px; width: 90%;
  position: relative; animation: fadeInUp 0.3s ease;
}
.modal-close {
  position: absolute; top: 1rem; right: 1.25rem;
  background: none; border: none; font-size: 1.5rem;
  cursor: pointer; color: var(--gray-400);
}
.modal-close:hover { color: var(--dark); }

/* ---------- 表单 ---------- */
.form-group { margin-bottom: 1.25rem; }
.form-label {
  display: block; font-weight: 500; color: var(--gray-700);
  margin-bottom: 0.4rem; font-size: 0.9rem;
}
.form-input, .form-select, .form-textarea {
  width: 100%; padding: 0.7rem 0.9rem;
  border: 1px solid var(--gray-300); border-radius: 6px;
  font-size: 0.95rem; font-family: inherit;
  transition: border-color 0.2s;
  background: var(--white);
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none; border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(0,82,204,0.1);
}
.form-textarea { resize: vertical; min-height: 90px; }

/* 提交成功提示 */
.toast {
  display: none; position: fixed; top: 24px; left: 50%;
  transform: translateX(-50%); z-index: 3000;
  background: #10B981; color: white;
  padding: 0.8rem 1.5rem; border-radius: 8px;
  font-weight: 500; box-shadow: var(--shadow-lg);
  animation: fadeInUp 0.3s ease;
}
.toast.show { display: block; }

/* ---------- 页脚 ---------- */
.site-footer {
  background: var(--gray-800); color: var(--gray-300);
  padding: 3rem 0 1.5rem; font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 2rem; margin-bottom: 2rem;
}
@media (max-width: 768px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-title {
  color: var(--white); font-weight: 600;
  margin-bottom: 1rem; font-size: 1rem;
}
.footer-link {
  color: var(--gray-400); text-decoration: none;
  display: block; margin-bottom: 0.5rem; transition: color 0.2s;
}
.footer-link:hover { color: var(--white); }
.footer-bottom {
  border-top: 1px solid var(--gray-700);
  padding-top: 1.5rem; text-align: center;
  font-size: 0.8rem; color: var(--gray-500);
}

/* ---------- 图片占位 ---------- */
.img-placeholder {
  background: var(--gray-100); border: 2px dashed var(--gray-300);
  border-radius: 8px; display: flex; align-items: center;
  justify-content: center; color: var(--gray-400);
  font-size: 0.85rem; min-height: 160px;
}

/* ---------- SEO 友好 ---------- */
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}

/* ---------- 套餐价格表 ---------- */
.price-table {
  width: 100%; border-collapse: collapse;
  background: var(--white); border-radius: 10px;
  overflow: hidden; border: 1px solid var(--gray-200);
}
.price-table th {
  background: var(--primary); color: var(--white);
  padding: 1rem; text-align: left; font-weight: 600;
}
.price-table td {
  padding: 1rem; border-bottom: 1px solid var(--gray-100);
  color: var(--gray-700);
}
.price-table tr:last-child td { border-bottom: none; }
.price-table tr:hover td { background: var(--gray-50); }

/* ---------- 资讯列表 ---------- */
.news-item {
  padding: 1.5rem 0; border-bottom: 1px solid var(--gray-200);
  transition: all 0.2s;
}
.news-item:hover { padding-left: 0.5rem; }
.news-tag {
  display: inline-block; padding: 2px 10px;
  border-radius: 4px; font-size: 0.75rem; font-weight: 600;
  margin-right: 0.5rem;
}
.tag-policy  { background: #EEF2FF; color: var(--primary); }
.tag-art     { background: #FEF3C7; color: #92400E; }
.tag-tips    { background: #D1FAE5; color: #065F46; }

/* ---------- 合作层级 ---------- */
.tier-card {
  border: 1px solid var(--gray-200); border-radius: 10px;
  padding: 2rem; text-align: center; transition: all 0.25s;
}
.tier-card.featured {
  border-color: var(--primary); border-width: 2px;
  box-shadow: 0 0 0 4px rgba(0,82,204,0.08);
}
.tier-name { font-size: 1.25rem; font-weight: 700; color: var(--dark); }
.tier-badge {
  display: inline-block; padding: 4px 14px;
  border-radius: 20px; font-size: 0.8rem; font-weight: 600;
  background: #EEF2FF; color: var(--primary); margin: 0.75rem 0;
}

/* ---------- 预约落地页 ---------- */
.reserve-hero {
  background: linear-gradient(135deg, #0052CC 0%, #003D99 100%);
  color: var(--white); padding: 6rem 0 4rem; text-align: center;
}

/* 懒加载 */
img[loading="lazy"] { opacity: 0; transition: opacity 0.4s; }
img[loading="lazy"].loaded { opacity: 1; }
