/* ===== 全局重置与基础 ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
  line-height: 1.6;
  color: #333;
  background: #f8f9fa;
  transition: background 0.3s ease, color 0.3s ease;
}

a {
  color: #0066cc;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ===== 渐变Banner (Hero) ===== */
.hero {
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
  color: #fff;
  padding: 80px 0;
  text-align: center;
  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(233, 69, 96, 0.15) 0%, transparent 60%),
              radial-gradient(circle at 70% 30%, rgba(0, 102, 204, 0.1) 0%, transparent 50%);
  animation: heroGlow 8s ease-in-out infinite alternate;
}

@keyframes heroGlow {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-10%, -5%) scale(1.1); }
}

.hero h1 {
  font-size: 3rem;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}

.hero p {
  font-size: 1.2rem;
  max-width: 700px;
  margin: 0 auto 30px;
  opacity: 0.9;
  position: relative;
  z-index: 1;
}

/* ===== 按钮 ===== */
.btn {
  display: inline-block;
  background: #e94560;
  color: #fff;
  padding: 12px 30px;
  border-radius: 30px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(233, 69, 96, 0.3);
  position: relative;
  z-index: 1;
}

.btn:hover {
  background: #c23152;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(233, 69, 96, 0.4);
  text-decoration: none;
}

/* ===== 标题 ===== */
.section {
  padding: 60px 0;
}

.section h2 {
  font-size: 2rem;
  margin-bottom: 30px;
  text-align: center;
  color: #1a1a2e;
}

.section h3 {
  font-size: 1.5rem;
  margin: 20px 0 10px;
  color: #16213e;
}

.section h4 {
  font-size: 1.2rem;
  margin: 15px 0 8px;
  color: #333;
}

/* ===== 圆角卡片 + 毛玻璃效果 ===== */
.card {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 30px;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
  will-change: transform, box-shadow;
}

.card:hover {
  transform: translateY(-6px) scale(1.02);
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.12);
  border-color: rgba(233, 69, 96, 0.2);
}

.card svg {
  margin-bottom: 15px;
  transition: transform 0.3s ease;
}

.card:hover svg {
  transform: scale(1.1) rotate(-2deg);
}

/* ===== 网格布局 ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

/* ===== 头部 ===== */
header {
  background: #1a1a2e;
  color: #fff;
  padding: 20px 0;
  border-bottom: 3px solid #e94560;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  font-size: 2rem;
  font-weight: 700;
  color: #e94560;
}

.logo span {
  color: #fff;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
}

nav a {
  color: #ddd;
  font-size: 1rem;
  transition: color 0.3s ease;
}

nav a:hover {
  color: #e94560;
}

/* ===== 粘性头部 ===== */
.sticky {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #1a1a2e;
}

/* ===== 面包屑 ===== */
.breadcrumb {
  background: #eee;
  padding: 10px 0;
  font-size: 0.9rem;
}

.breadcrumb a {
  color: #555;
}

.breadcrumb span {
  color: #999;
}

/* ===== FAQ ===== */
.faq-item {
  margin-bottom: 15px;
}

.faq-question {
  font-weight: 600;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 15px;
  border-radius: 12px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
}

.faq-question:hover {
  background: rgba(233, 69, 96, 0.05);
  border-color: rgba(233, 69, 96, 0.2);
}

.faq-answer {
  display: none;
  padding: 15px;
  background: rgba(248, 249, 250, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 0 0 12px 12px;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-top: none;
}

/* ===== 文章列表 ===== */
.article-list {
  display: grid;
  gap: 20px;
}

.article-item {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 20px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
}

.article-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.article-item h3 {
  margin-bottom: 5px;
}

.article-item .meta {
  font-size: 0.9rem;
  color: #666;
}

/* ===== HowTo步骤 ===== */
.howto-step {
  margin-bottom: 20px;
  padding: 15px;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  transition: all 0.3s ease;
}

.howto-step:hover {
  background: rgba(255, 255, 255, 0.9);
  transform: translateX(5px);
}

.howto-step h4 {
  margin-bottom: 5px;
}

/* ===== 页脚 ===== */
.footer {
  background: #1a1a2e;
  color: #ddd;
  padding: 40px 0;
}

.footer a {
  color: #aaa;
  transition: color 0.3s ease;
}

.footer a:hover {
  color: #e94560;
}

.footer .grid {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

/* ===== 回到顶部 ===== */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: #e94560;
  color: #fff;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 999;
  font-size: 1.5rem;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(233, 69, 96, 0.3);
}

.back-to-top:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 6px 20px rgba(233, 69, 96, 0.4);
}

/* ===== 暗色模式 ===== */
.dark-mode {
  background: #222;
  color: #eee;
}

.dark-mode .card {
  background: rgba(51, 51, 51, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #eee;
  border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .section h2 {
  color: #eee;
}

.dark-mode .faq-question {
  background: rgba(51, 51, 51, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-color: rgba(255, 255, 255, 0.1);
  color: #eee;
}

.dark-mode .faq-answer {
  background: rgba(42, 42, 42, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-color: rgba(255, 255, 255, 0.1);
  color: #ddd;
}

.dark-mode .article-item {
  background: rgba(51, 51, 51, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #eee;
  border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .howto-step {
  background: rgba(51, 51, 51, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #eee;
  border-color: rgba(255, 255, 255, 0.1);
}

.dark-mode .breadcrumb {
  background: #2a2a2a;
}

.dark-mode .breadcrumb a {
  color: #aaa;
}

.dark-mode .breadcrumb span {
  color: #888;
}

/* ===== 滚动动画 ===== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section {
  animation: fadeInUp 0.6s ease-out both;
}

.section:nth-child(2) { animation-delay: 0.1s; }
.section:nth-child(3) { animation-delay: 0.2s; }
.section:nth-child(4) { animation-delay: 0.3s; }
.section:nth-child(5) { animation-delay: 0.4s; }
.section:nth-child(6) { animation-delay: 0.5s; }
.section:nth-child(7) { animation-delay: 0.6s; }
.section:nth-child(8) { animation-delay: 0.7s; }
.section:nth-child(9) { animation-delay: 0.8s; }
.section:nth-child(10) { animation-delay: 0.9s; }
.section:nth-child(11) { animation-delay: 1.0s; }

/* ===== 响应式布局 ===== */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem;
  }

  header .container {
    flex-direction: column;
    gap: 10px;
  }

  nav ul {
    justify-content: center;
  }

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

  .section h2 {
    font-size: 1.6rem;
  }

  .card {
    padding: 20px;
  }

  .hero {
    padding: 60px 0;
  }

  .hero p {
    font-size: 1rem;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 15px;
  }

  .logo {
    font-size: 1.5rem;
  }

  nav a {
    font-size: 0.9rem;
  }

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