/* ===== 老湿影院 全站样式表 ===== */
/* ===== 全局重置与变量 ===== */
:root {
  --bg-primary: #ffffff;
  --bg-secondary: #f3f6fc;
  --bg-footer: #0b1a2a;
  --text-primary: #1F2937;
  --text-secondary: #334155;
  --text-heading: #111827;
  --text-link: #1e40af;
  --text-button: #ffffff;
  --accent: #2563eb;
  --accent-dark: #1e3a8a;
  --border-light: #d1d5db;
  --card-bg: #ffffff;
  --nav-bg: rgba(255,255,255,0.9);
  --faq-question: #1F2937;
  --faq-answer: #334155;
  --placeholder: #4b5563;
  --shadow: 0 4px 12px rgba(0,0,0,0.08);
  --shadow-hover: 0 12px 28px rgba(0,0,0,0.15);
  --gradient-banner: linear-gradient(145deg, #e8f0fe, #f8fafc);
  --gradient-accent: linear-gradient(90deg, #2563eb, #1e3a8a);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --font-sans: system-ui, -apple-system, 'Segoe UI', Roboto, 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

html[data-theme="dark"] {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-footer: #020617;
  --text-primary: #E2E8F0;
  --text-secondary: #CBD5E1;
  --text-heading: #FFFFFF;
  --text-link: #93c5fd;
  --text-button: #0f172a;
  --accent: #3b82f6;
  --accent-dark: #2563eb;
  --border-light: #334155;
  --card-bg: #1e293b;
  --nav-bg: rgba(15,23,42,0.85);
  --faq-question: #F8FAFC;
  --faq-answer: #E2E8F0;
  --placeholder: #94a3b8;
  --shadow: 0 4px 12px rgba(0,0,0,0.3);
  --shadow-hover: 0 12px 28px rgba(0,0,0,0.5);
  --gradient-banner: linear-gradient(145deg, #1e293b, #0f172a);
  --gradient-accent: linear-gradient(90deg, #3b82f6, #2563eb);
}

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

html {
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

h1, h2, h3, h4, h5, h6 {
  color: var(--text-heading);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

p {
  color: var(--text-primary);
  line-height: 1.75;
}

a {
  color: var(--text-link);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  text-decoration: none;
  color: var(--accent);
}

img, svg {
  max-width: 100%;
  height: auto;
  display: block;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

input {
  font-family: inherit;
}

/* ===== 滚动条美化 ===== */
::-webkit-scrollbar {
  width: 10px;
  height: 6px;
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
  background: var(--accent);
  border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--accent-dark);
}

/* ===== 通用容器 ===== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== 导航栏 ===== */
.navbar {
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 72px;
  gap: 16px;
}

.logo {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--text-heading);
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.logo svg {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

.logo span {
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.nav-links {
  display: flex;
  gap: 2.2rem;
  align-items: center;
  list-style: none;
}

.nav-links a {
  font-weight: 600;
  color: var(--text-primary);
  position: relative;
  padding: 4px 0;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  transition: color 0.2s;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
  border-radius: 2px;
}

.nav-links a:hover::after {
  width: 100%;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.search-box {
  display: flex;
  align-items: center;
  background: var(--bg-secondary);
  border-radius: 40px;
  padding: 4px 4px 4px 18px;
  border: 1px solid var(--border-light);
  transition: border-color 0.3s, box-shadow 0.3s;
  max-width: 240px;
}

.search-box:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.search-box input {
  border: none;
  background: transparent;
  color: var(--text-primary);
  outline: none;
  font-size: 0.9rem;
  width: 100%;
  min-width: 100px;
  padding: 6px 0;
}

.search-box input::placeholder {
  color: var(--placeholder);
}

.search-box button {
  background: var(--gradient-accent);
  border-radius: 40px;
  padding: 7px 18px;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: opacity 0.2s, transform 0.2s;
  border: none;
}

.search-box button:hover {
  opacity: 0.9;
  transform: scale(1.02);
}

.theme-toggle {
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: 40px;
  padding: 8px 14px;
  font-size: 1.1rem;
  cursor: pointer;
  color: var(--text-primary);
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.theme-toggle:hover {
  border-color: var(--accent);
  background: var(--accent);
  color: white;
  transform: rotate(15deg);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.8rem;
  cursor: pointer;
  color: var(--text-primary);
  margin-left: 4px;
  padding: 4px;
  line-height: 1;
}

/* ===== Banner 区域 ===== */
.banner {
  background: var(--gradient-banner);
  border-radius: 28px;
  padding: 3rem 3rem 3.5rem;
  margin: 2.5rem 0;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-light);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.banner::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 60%;
  height: 200%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.1) 0%, transparent 70%);
  pointer-events: none;
}

.banner-content {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  position: relative;
  z-index: 1;
}

.banner-text {
  flex: 2 1 300px;
  min-width: 280px;
}

.banner-text h1 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 0.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: var(--gradient-accent);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.banner-text p {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  max-width: 600px;
  line-height: 1.8;
}

.btn-group {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.btn-primary,
.btn-secondary {
  padding: 12px 28px;
  border-radius: 50px;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  letter-spacing: 0.02em;
}

.btn-primary {
  background: var(--gradient-accent);
  color: white;
  border: none;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.4);
  color: white;
}

.btn-secondary {
  background: transparent;
  border: 2px solid var(--accent);
  color: var(--accent);
}

.btn-secondary:hover {
  background: var(--accent);
  color: white;
  transform: translateY(-2px);
}

.banner-art {
  flex: 1 1 220px;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 200px;
}

.banner-art svg {
  width: 280px;
  max-width: 100%;
  filter: drop-shadow(0 10px 20px rgba(37, 99, 235, 0.2));
  animation: float 6s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}

.stats {
  display: flex;
  gap: 3rem;
  flex-wrap: wrap;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-light);
  position: relative;
  z-index: 1;
}

.stat-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.stat {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--accent);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* ===== 区块标题 ===== */
.section-title {
  margin: 3.5rem 0 2rem;
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  position: relative;
  padding-bottom: 0.6rem;
  display: inline-block;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60%;
  height: 3px;
  background: var(--gradient-accent);
  border-radius: 3px;
}

/* ===== 卡片网格 ===== */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.8rem;
  margin-bottom: 1rem;
}

.card {
  background: var(--card-bg);
  padding: 2rem 1.8rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s;
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--gradient-accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
  border-color: var(--accent);
}

.card:hover::before {
  transform: scaleX(1);
}

.card h3 {
  font-size: 1.35rem;
  margin-bottom: 0.75rem;
  font-weight: 700;
}

.card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.card p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.card p + p {
  margin-top: 0.5rem;
}

.card .card-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--gradient-accent);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  font-size: 1.4rem;
  color: white;
}

/* ===== 文章列表 ===== */
.article-list {
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

.article-item {
  background: var(--card-bg);
  padding: 1.4rem 1.8rem;
  border-radius: 14px;
  border-left: 5px solid var(--accent);
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.article-item:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-hover);
  border-left-width: 8px;
}

.article-item h4 {
  font-size: 1.15rem;
  margin-bottom: 0.4rem;
  font-weight: 700;
}

.article-item .meta {
  font-size: 0.85rem;
  color: var(--text-secondary);
  display: flex;
  gap: 18px;
  margin-bottom: 0.4rem;
  flex-wrap: wrap;
}

.article-item .meta span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.article-item .meta span::before {
  content: '·';
  color: var(--accent);
  font-weight: bold;
}

.article-item p:not(.meta) {
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}

.article-item a {
  font-weight: 600;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: gap 0.2s;
}

.article-item a:hover {
  gap: 8px;
}

/* ===== FAQ 样式 ===== */
.faq-item {
  background: var(--card-bg);
  border-radius: 14px;
  margin-bottom: 1rem;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-hover);
}

.faq-item.active {
  border-color: var(--accent);
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.12);
}

.faq-question {
  padding: 1.1rem 1.5rem;
  font-weight: 600;
  color: var(--faq-question);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  font-size: 1rem;
  transition: background 0.2s;
  user-select: none;
}

.faq-question:hover {
  background: var(--bg-secondary);
}

.faq-question .faq-icon {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: all 0.3s ease;
  color: var(--accent);
  border: 1px solid var(--border-light);
}

.faq-item.active .faq-icon {
  background: var(--accent);
  color: white;
  transform: rotate(45deg);
}

.faq-answer {
  padding: 0 1.5rem 1.3rem;
  color: var(--faq-answer);
  display: none;
  line-height: 1.7;
  font-size: 0.95rem;
}

.faq-item.active .faq-answer {
  display: block;
  animation: fadeInDown 0.3s ease;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===== HowTo 样式 ===== */
.howto-steps {
  background: var(--bg-secondary);
  padding: 2.5rem;
  border-radius: 20px;
  color: var(--text-primary);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow);
}

.step {
  display: flex;
  gap: 1.2rem;
  margin-bottom: 1.2rem;
  align-items: flex-start;
  padding: 0.4rem 0;
}

.step:last-child {
  margin-bottom: 0;
}

.step-num {
  background: var(--gradient-accent);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3);
}

.step p {
  line-height: 1.7;
  padding-top: 4px;
}

.step strong {
  color: var(--text-heading);
}

/* ===== 联系信息 ===== */
address {
  font-style: normal;
  line-height: 1.8;
  color: var(--text-primary);
}

/* ===== 友情链接 ===== */
.friend-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin: 2.5rem 0;
  padding: 1.5rem;
  background: var(--bg-secondary);
  border-radius: 14px;
  border: 1px solid var(--border-light);
  align-items: center;
}

.friend-links strong {
  color: var(--text-heading);
}

.friend-links a {
  color: var(--text-secondary);
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.2s;
}

.friend-links a:hover {
  color: var(--accent);
  background: var(--bg-primary);
}

/* ===== Footer 样式 ===== */
.footer {
  background: var(--bg-footer);
  color: #CBD5E1;
  padding: 3.5rem 0 2rem;
  margin-top: 4rem;
  border-radius: 28px 28px 0 0;
  border-top: 1px solid rgba(255,255,255,0.1);
}

.footer a {
  color: #9db2d0;
  transition: color 0.2s;
}

.footer a:hover {
  color: white;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2.5rem;
}

.footer h4 {
  color: white;
  font-size: 1.1rem;
  margin-bottom: 0.8rem;
  font-weight: 700;
}

.footer p {
  color: #cbd5e1;
  font-size: 0.9rem;
  line-height: 1.7;
}

.footer .footer-bottom {
  text-align: center;
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255,255,255,0.1);
  color: #9ca3af;
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

/* ===== 返回顶部按钮 ===== */
.go-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--gradient-accent);
  color: white;
  border: none;
  border-radius: 50px;
  padding: 12px 18px;
  cursor: pointer;
  font-size: 1.2rem;
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
  z-index: 999;
  transition: all 0.3s ease;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
}

.go-top.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.go-top:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(37, 99, 235, 0.4);
}

/* ===== 通用工具类 ===== */
.text-muted {
  color: var(--text-secondary);
}

.bg-card {
  background: var(--card-bg);
}

.text-accent {
  color: var(--accent);
}

.mb-2 { margin-bottom: 0.5rem; }
.mb-3 { margin-bottom: 1rem; }
.mb-4 { margin-bottom: 1.5rem; }
.mb-5 { margin-bottom: 2rem; }

/* ===== 滚动入场动画 ===== */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== 响应式 ===== */
@media (max-width: 1024px) {
  .navbar .container {
    flex-wrap: wrap;
    height: auto;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .nav-links {
    order: 3;
    width: 100%;
    justify-content: center;
    gap: 1.5rem;
    padding-top: 8px;
  }

  .search-box {
    max-width: 200px;
  }

  .banner {
    padding: 2rem;
  }
}

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

  .navbar .container {
    flex-wrap: nowrap;
    height: 64px;
    padding-top: 0;
    padding-bottom: 0;
  }

  .logo {
    font-size: 1.4rem;
  }

  .logo svg {
    width: 32px;
    height: 32px;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    width: 100%;
    background: var(--nav-bg);
    flex-direction: column;
    padding: 1rem 0;
    gap: 0.8rem;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-light);
    box-shadow: var(--shadow);
    animation: slideDown 0.3s ease;
    z-index: 999;
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    padding: 10px 20px;
    width: 100%;
    text-align: center;
    font-size: 1rem;
  }

  .nav-links a::after {
    display: none;
  }

  .menu-toggle {
    display: block;
  }

  .search-box {
    display: none;
  }

  .theme-toggle {
    padding: 6px 10px;
    font-size: 1rem;
  }

  .banner {
    padding: 1.8rem 1.5rem;
    margin: 1.5rem 0;
    border-radius: 20px;
  }

  .banner-text h1 {
    font-size: 1.8rem;
  }

  .banner-text p {
    font-size: 1rem;
  }

  .banner-art svg {
    width: 180px;
  }

  .stats {
    gap: 1.5rem;
    margin-top: 1.5rem;
  }

  .stat {
    font-size: 1.8rem;
  }

  .section-title {
    margin: 2.5rem 0 1.5rem;
    font-size: 1.4rem;
  }

  .grid-cards {
    grid-template-columns: 1fr;
    gap: 1.2rem;
  }

  .card {
    padding: 1.5rem;
  }

  .howto-steps {
    padding: 1.5rem;
  }

  .footer {
    padding: 2.5rem 0 1.5rem;
    border-radius: 20px 20px 0 0;
  }

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

  .go-top {
    bottom: 20px;
    right: 20px;
    padding: 10px 14px;
    font-size: 1rem;
  }

  .friend-links {
    flex-direction: column;
    gap: 0.8rem;
    align-items: flex-start;
  }
}

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

  .logo {
    font-size: 1.2rem;
  }

  .logo svg {
    width: 28px;
    height: 28px;
  }

  .banner {
    padding: 1.5rem 1.2rem;
  }

  .btn-group {
    flex-direction: column;
    width: 100%;
  }

  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
  }

  .article-item {
    padding: 1rem 1.2rem;
  }

  .article-item .meta {
    gap: 10px;
    font-size: 0.8rem;
  }

  .faq-question {
    padding: 0.9rem 1.2rem;
    font-size: 0.95rem;
  }

  .faq-answer {
    padding: 0 1.2rem 1rem;
  }

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

  .stats {
    gap: 1rem;
  }
}

/* ===== 动画定义 ===== */
@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes pulse {
  0%, 100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}

/* ===== 打印样式 ===== */
@media print {
  .navbar,
  .footer,
  .go-top,
  .search-box,
  .theme-toggle,
  .menu-toggle {
    display: none !important;
  }

  body {
    background: white;
    color: black;
    font-size: 12pt;
  }

  .container {
    max-width: 100%;
    padding: 0;
  }

  .banner {
    break-after: avoid;
  }

  .card,
  .article-item,
  .faq-item,
  .howto-steps {
    break-inside: avoid;
    box-shadow: none;
    border: 1px solid #ddd;
  }
}

/* ===== 辅助功能优化 ===== */
:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  background: var(--accent);
  color: white;
  padding: 8px 16px;
  border-radius: 4px;
  z-index: 1001;
  transition: top 0.3s;
}

.skip-link:focus {
  top: 8px;
}

/* ===== 暗色模式下的图片/图标调整 ===== */
html[data-theme="dark"] img {
  filter: brightness(0.9);
}

html[data-theme="dark"] .banner-art svg text {
  fill: #E2E8F0;
}

/* ===== 卡片图标悬停 ===== */
.card:hover .card-icon {
  transform: scale(1.1) rotate(-5deg);
  transition: transform 0.3s ease;
}

/* ===== 数字统计装饰 ===== */
.stat-wrap::after {
  content: '';
  width: 40px;
  height: 3px;
  background: var(--gradient-accent);
  border-radius: 3px;
  margin-top: 8px;
}

/* ===== 文章阅读更多链接箭头 ===== */
.article-item a::after {
  content: '→';
  transition: transform 0.2s;
  display: inline-block;
  margin-left: 4px;
}

.article-item a:hover::after {
  transform: translateX(4px);
}

/* ===== FAQ 加号图标旋转 ===== */
.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

/* ===== 首页 banner 背景装饰 ===== */
.banner::after {
  content: '';
  position: absolute;
  bottom: -30px;
  left: -30px;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  opacity: 0.05;
  pointer-events: none;
  border-radius: 50%;
}

/* ===== 暗黑模式主题切换过渡 ===== */
body,
.banner,
.card,
.article-item,
.faq-item,
.howto-steps,
.navbar {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* ===== 无障碍：减少动态效果 ===== */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ===== 高对比度模式 ===== */
@media (prefers-contrast: high) {
  :root {
    --text-primary: #000000;
    --text-secondary: #1a1a1a;
    --border-light: #000000;
  }

  html[data-theme="dark"] {
    --text-primary: #ffffff;
    --text-secondary: #f0f0f0;
    --border-light: #ffffff;
  }
}

/* ===== 结语：性能优化 - 使用 GPU 加速 ===== */
.banner,
.card,
.navbar {
  transform: translateZ(0);
  backface-visibility: hidden;
  will-change: transform;
}

/* ===== 字体渲染优化 ===== */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ===== 选中文本颜色 ===== */
::selection {
  background: var(--accent);
  color: white;
}

/* ===== 键盘用户导航 ===== */
.nav-links a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 4px;
}