/* ===== 全局重置 & 基础 ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
  font-size: 16px;
}
body {
  font-family: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  background: #f8f9fa;
  color: #1a1a2e;
  transition: background 0.3s, color 0.3s;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
body.dark {
  background: #0f0f1a;
  color: #e0e0e0;
}
a {
  color: inherit;
  text-decoration: none;
}
ul {
  list-style: none;
}
img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== 滚动条 ===== */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(135deg, #667eea, #764ba2);
  border-radius: 10px;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-block;
  padding: 14px 36px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  border: none;
  text-align: center;
}
.btn-primary {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  box-shadow: 0 8px 30px rgba(102, 126, 234, 0.4);
}
.btn-primary:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 12px 40px rgba(102, 126, 234, 0.5);
}
.btn-primary:active {
  transform: translateY(0) scale(0.98);
}
.btn-outline {
  background: transparent;
  border: 2px solid rgba(255, 255, 255, 0.3);
  color: #fff;
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #667eea;
  transform: translateY(-3px);
}

/* ===== 徽章 ===== */
.badge {
  display: inline-block;
  padding: 4px 14px;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 500;
  background: rgba(102, 126, 234, 0.15);
  color: #667eea;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

/* ===== 渐变文字 ===== */
.text-gradient,
.section-title,
.number,
.logo {
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ===== 头部 ===== */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  transition: background 0.3s, box-shadow 0.3s, border-color 0.3s;
}
body.dark header {
  background: rgba(15, 15, 26, 0.85);
  border-bottom-color: rgba(255, 255, 255, 0.05);
}
header.scrolled {
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}
body.dark header.scrolled {
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 70px;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 24px;
  font-weight: 700;
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.logo svg {
  width: 36px;
  height: 36px;
  filter: drop-shadow(0 2px 8px rgba(102, 126, 234, 0.3));
}

/* ===== 导航 ===== */
nav {
  display: flex;
  align-items: center;
  gap: 8px;
}
nav a {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 500;
  transition: all 0.3s ease;
  position: relative;
}
nav a::after {
  content: '';
  position: absolute;
  bottom: 4px;
  left: 50%;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, #667eea, #764ba2);
  transition: all 0.3s ease;
  transform: translateX(-50%);
  border-radius: 2px;
}
nav a:hover::after,
nav a.active::after {
  width: 60%;
}
nav a:hover,
nav a.active {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
}
nav a:hover::after,
nav a.active::after {
  background: #fff;
}
.dark-toggle {
  background: none;
  border: 2px solid #667eea;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 20px;
  transition: all 0.3s ease;
  color: #667eea;
  margin-left: 4px;
}
.dark-toggle:hover {
  background: #667eea;
  color: #fff;
  transform: rotate(15deg);
}

/* ===== 汉堡菜单 ===== */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 8px;
  background: none;
  border: none;
}
.menu-toggle span {
  width: 28px;
  height: 3px;
  background: #1a1a2e;
  border-radius: 3px;
  transition: all 0.3s ease;
}
body.dark .menu-toggle span {
  background: #e0e0e0;
}

/* ===== Hero 区域 ===== */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 120px 20px 80px;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: 
    radial-gradient(circle at 30% 50%, rgba(102, 126, 234, 0.15), transparent 60%),
    radial-gradient(circle at 70% 50%, rgba(118, 75, 162, 0.15), transparent 60%);
  animation: heroGlow 10s ease-in-out infinite alternate;
}
@keyframes heroGlow {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(5%, 5%) scale(1.05); }
}
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 800px;
}
.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 800;
  color: #fff;
  line-height: 1.1;
  margin-bottom: 20px;
  letter-spacing: -1px;
}
.hero h1 span {
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero p {
  font-size: clamp(1rem, 2vw, 1.3rem);
  color: rgba(255, 255, 255, 0.7);
  margin-bottom: 40px;
  line-height: 1.8;
}
.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ===== 通用区域 ===== */
section {
  padding: 80px 0;
}
.section-title {
  text-align: center;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  margin-bottom: 10px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  letter-spacing: -0.5px;
}
.section-subtitle {
  text-align: center;
  color: #666;
  margin-bottom: 50px;
  font-size: 1.1rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}
body.dark .section-subtitle {
  color: #aaa;
}

/* ===== 毛玻璃卡片 ===== */
.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 30px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
body.dark .glass-card {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}
.glass-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.1);
}
body.dark .glass-card:hover {
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.3);
}

/* ===== 网格 ===== */
.grid {
  display: grid;
  gap: 30px;
}
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ===== FAQ ===== */
.faq-item {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: 20px 0;
  cursor: pointer;
  transition: background 0.3s;
}
body.dark .faq-item {
  border-color: rgba(255, 255, 255, 0.1);
}
.faq-item:hover {
  background: rgba(102, 126, 234, 0.03);
  border-radius: 8px;
  padding-left: 12px;
  padding-right: 12px;
}
.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.1rem;
  font-weight: 600;
  gap: 16px;
}
.faq-question span {
  font-size: 1.5rem;
  transition: transform 0.3s ease;
  flex-shrink: 0;
  line-height: 1;
}
.faq-item.open .faq-question span {
  transform: rotate(45deg);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.3s, opacity 0.3s;
  padding-top: 0;
  color: #666;
  opacity: 0;
}
body.dark .faq-answer {
  color: #aaa;
}
.faq-item.open .faq-answer {
  max-height: 500px;
  padding-top: 15px;
  opacity: 1;
}

/* ===== 面包屑 ===== */
.breadcrumb {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.9rem;
  color: #666;
  padding: 20px 0;
}
body.dark .breadcrumb {
  color: #aaa;
}
.breadcrumb a:hover {
  color: #667eea;
}

/* ===== 搜索框 ===== */
.search-box {
  display: flex;
  max-width: 400px;
  margin: 20px auto;
  border-radius: 50px;
  overflow: hidden;
  border: 2px solid #667eea;
  transition: box-shadow 0.3s;
}
.search-box:focus-within {
  box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.2);
}
.search-box input {
  flex: 1;
  padding: 12px 20px;
  border: none;
  outline: none;
  background: transparent;
  font-size: 1rem;
}
body.dark .search-box input {
  color: #fff;
}
.search-box button {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  border: none;
  padding: 12px 24px;
  cursor: pointer;
  font-weight: 600;
  transition: opacity 0.3s;
}
.search-box button:hover {
  opacity: 0.9;
}

/* ===== 数字动画 ===== */
.number {
  font-size: 2.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, #667eea, #764ba2);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: inline-block;
}

/* ===== Banner 轮播 ===== */
.banner-wrapper {
  position: relative;
  overflow: hidden;
  border-radius: 24px;
  height: 400px;
}
.banner-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.8s ease, transform 0.8s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  text-align: center;
  padding: 40px;
  color: #fff;
  transform: scale(0.95);
}
.banner-slide.active {
  opacity: 1;
  transform: scale(1);
}
.banner-slide h2 {
  font-size: 2.5rem;
  margin-bottom: 16px;
}
.banner-slide p {
  font-size: 1.2rem;
  max-width: 600px;
  opacity: 0.9;
}
.banner-dots {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
}
.banner-dots span {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all 0.3s ease;
}
.banner-dots span.active {
  background: #fff;
  transform: scale(1.3);
}

/* ===== 页脚 ===== */
footer {
  background: #1a1a2e;
  color: rgba(255, 255, 255, 0.7);
  padding: 60px 20px 30px;
}
footer .grid {
  color: inherit;
}
footer h3 {
  color: #fff;
  margin-bottom: 20px;
  font-size: 1.1rem;
  position: relative;
  display: inline-block;
}
footer h3::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 30px;
  height: 2px;
  background: linear-gradient(90deg, #667eea, #764ba2);
  border-radius: 2px;
}
footer a {
  color: rgba(255, 255, 255, 0.6);
  transition: color 0.3s, padding-left 0.3s;
  display: inline-block;
}
footer a:hover {
  color: #667eea;
  padding-left: 4px;
}
footer ul li {
  margin-bottom: 8px;
}
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding-top: 20px;
  margin-top: 40px;
  text-align: center;
  font-size: 0.9rem;
}
.footer-bottom p {
  opacity: 0.8;
}

/* ===== 返回顶部 ===== */
.back-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 999;
  border: none;
  box-shadow: 0 8px 30px rgba(102, 126, 234, 0.4);
}
.back-top.visible {
  opacity: 1;
  visibility: visible;
}
.back-top:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 12px 40px rgba(102, 126, 234, 0.5);
}

/* ===== 滚动动画 ===== */
.fade-up {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-up.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== 工具类 ===== */
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
.text-center { text-align: center; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-16 { gap: 16px; }
.rounded-full { border-radius: 50%; }
.w-full { width: 100%; }
ol, ul { padding-left: 0; }
ol li, ul li { margin-bottom: 4px; }

/* ===== 响应式 ===== */
@media (max-width: 1024px) and (min-width: 769px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .banner-wrapper { height: 320px; }
  .banner-slide h2 { font-size: 2rem; }
}

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  
  nav {
    display: none;
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    padding: 20px;
    gap: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  }
  body.dark nav {
    background: rgba(15, 15, 26, 0.98);
    border-bottom-color: rgba(255, 255, 255, 0.05);
  }
  nav.open { display: flex; }
  .menu-toggle { display: flex; }
  
  .hero { padding: 100px 20px 60px; }
  .hero h1 { font-size: 2.2rem; }
  .hero p { font-size: 1rem; }
  
  section { padding: 60px 0; }
  
  .glass-card { padding: 24px; }
  
  .banner-wrapper { height: 280px; }
  .banner-slide h2 { font-size: 1.6rem; }
  .banner-slide p { font-size: 1rem; }
  
  footer { padding: 40px 20px 20px; }
  footer .grid { gap: 24px; }
  
  .back-top {
    width: 44px;
    height: 44px;
    font-size: 20px;
    bottom: 20px;
    right: 20px;
  }
  
  .faq-question { font-size: 1rem; }
}

/* ===== 暗色模式额外优化 ===== */
body.dark .glass-card h3,
body.dark .glass-card strong {
  color: #e0e0e0;
}
body.dark .glass-card p {
  color: #bbb;
}
body.dark .badge {
  background: rgba(102, 126, 234, 0.25);
}

/* ===== 打印样式 ===== */
@media print {
  header, .back-top, .menu-toggle, .dark-toggle { display: none; }
  .hero { min-height: auto; padding: 40px 0; }
  .glass-card { box-shadow: none; border: 1px solid #ddd; }
}