:root {
  --primary: #e94560;
  --primary-dark: #c73550;
  --primary-light: #ff6b81;
  --secondary: #533483;
  --accent: #0f3460;
  --bg-dark: #1a1a2e;
  --bg-darker: #16213e;
  --bg-card: #0f3460;
  --bg-card-hover: #1a4a7a;
  --text-primary: #ffffff;
  --text-secondary: #b8c1ec;
  --text-muted: #8892b0;
  --border-color: rgba(233, 69, 96, 0.2);
  --glass-bg: rgba(26, 26, 46, 0.75);
  --glass-border: rgba(255, 255, 255, 0.08);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(233, 69, 96, 0.3);
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-xl: 32px;
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --font-mono: "SF Mono", "Fira Code", "Fira Mono", "Roboto Mono", monospace;
  --max-width: 1200px;
  --header-height: 72px;
}

[data-theme="light"] {
  --bg-dark: #f5f7fa;
  --bg-darker: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #f0f2f8;
  --text-primary: #1a1a2e;
  --text-secondary: #4a4a6a;
  --text-muted: #7a7a9a;
  --border-color: rgba(233, 69, 96, 0.15);
  --glass-bg: rgba(255, 255, 255, 0.8);
  --glass-border: rgba(0, 0, 0, 0.06);
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.12);
  --shadow-glow: 0 0 30px rgba(233, 69, 96, 0.15);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-dark);
  color: var(--text-primary);
  line-height: 1.7;
  font-size: 16px;
  overflow-x: hidden;
  transition: background-color var(--transition-slow), color var(--transition-slow);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--primary);
  text-decoration: none;
  transition: color var(--transition-fast), opacity var(--transition-fast);
}

a:hover {
  color: var(--primary-light);
}

a:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

ul,
ol {
  list-style: none;
}

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

h1 {
  font-size: clamp(1.75rem, 4vw, 3rem);
  margin-bottom: 1.5rem;
  background: linear-gradient(135deg, var(--text-primary) 0%, var(--primary-light) 50%, var(--primary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.75rem;
}

h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  border-radius: 2px;
}

h3 {
  font-size: clamp(1.15rem, 2vw, 1.5rem);
  margin-bottom: 0.75rem;
}

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

p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

strong {
  color: var(--text-primary);
  font-weight: 600;
}

blockquote {
  border-left: 4px solid var(--primary);
  padding: 1rem 1.5rem;
  margin: 1rem 0;
  background: var(--glass-bg);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

blockquote p {
  margin-bottom: 0;
  font-style: italic;
  color: var(--text-secondary);
}

time {
  font-size: 0.875rem;
  color: var(--text-muted);
}

header[role="banner"] {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--glass-bg);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid var(--glass-border);
  transition: background var(--transition-base), box-shadow var(--transition-base);
}

header[role="banner"]:hover {
  box-shadow: var(--shadow-md);
}

header[role="banner"] nav > div {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  height: var(--header-height);
}

header[role="banner"] nav > div > a:first-child {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-primary);
  font-size: 1.25rem;
  font-weight: 700;
  white-space: nowrap;
  flex-shrink: 0;
}

header[role="banner"] nav > div > a:first-child svg {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

header[role="banner"] nav > div > a:first-child:hover svg {
  transform: rotate(-8deg) scale(1.08);
  box-shadow: var(--shadow-glow);
}

header[role="banner"] nav > div > a:first-child span {
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

header[role="banner"] nav ul {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  flex: 1;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

header[role="banner"] nav ul::-webkit-scrollbar {
  display: none;
}

header[role="banner"] nav ul li a {
  display: block;
  padding: 0.5rem 0.85rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  white-space: nowrap;
  transition: all var(--transition-fast);
  position: relative;
}

header[role="banner"] nav ul li a::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 60%;
  height: 2px;
  background: var(--primary);
  border-radius: 1px;
  transition: transform var(--transition-base);
}

header[role="banner"] nav ul li a:hover {
  color: var(--text-primary);
  background: rgba(233, 69, 96, 0.1);
}

header[role="banner"] nav ul li a:hover::after {
  transform: translateX(-50%) scaleX(1);
}

header[role="banner"] form[role="search"] {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

header[role="banner"] form[role="search"] label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
}

header[role="banner"] form[role="search"] input {
  width: 180px;
  padding: 0.5rem 1rem;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  font-size: 0.875rem;
  font-family: inherit;
  outline: none;
  transition: all var(--transition-base);
}

header[role="banner"] form[role="search"] input::placeholder {
  color: var(--text-muted);
}

header[role="banner"] form[role="search"] input:focus {
  width: 240px;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(233, 69, 96, 0.15);
  background: rgba(255, 255, 255, 0.1);
}

header[role="banner"] form[role="search"] button {
  padding: 0.5rem 1rem;
  border: none;
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 0.875rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
}

header[role="banner"] form[role="search"] button:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-glow);
}

header[role="banner"] form[role="search"] button:active {
  transform: translateY(0);
}

#theme-toggle {
  width: 40px;
  height: 40px;
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  font-size: 1.1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  flex-shrink: 0;
}

#theme-toggle:hover {
  background: rgba(233, 69, 96, 0.15);
  border-color: var(--primary);
  transform: rotate(20deg) scale(1.1);
}

#menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  font-size: 1.2rem;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  flex-shrink: 0;
}

#menu-toggle:hover {
  background: rgba(233, 69, 96, 0.15);
  border-color: var(--primary);
}

main {
  padding-top: var(--header-height);
}

main > section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4rem 1.5rem;
}

main > section:nth-child(even) {
  background: var(--bg-darker);
  max-width: 100%;
  padding-left: calc((100% - var(--max-width)) / 2 + 1.5rem);
  padding-right: calc((100% - var(--max-width)) / 2 + 1.5rem);
}

#home {
  max-width: 100%;
  padding: 0;
  position: relative;
  overflow: hidden;
}

#home > h1,
#home > p,
#home > div,
#home > ul {
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

#home > h1 {
  padding-top: 4rem;
  text-align: center;
  animation: fadeInUp 0.8s ease both;
}

#home > p:first-of-type {
  text-align: center;
  font-size: 1.1rem;
  max-width: 800px;
  animation: fadeInUp 0.8s ease 0.1s both;
}

#home > p:nth-of-type(2) {
  text-align: center;
  font-size: 1rem;
  max-width: 800px;
  animation: fadeInUp 0.8s ease 0.2s both;
}

#home > div:nth-of-type(1) {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin: 2rem auto;
  animation: fadeInUp 0.8s ease 0.3s both;
}

#home > div:nth-of-type(1) a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2rem;
  border-radius: var(--radius-xl);
  font-weight: 600;
  font-size: 1rem;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

#home > div:nth-of-type(1) a:first-child {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 4px 20px rgba(233, 69, 96, 0.4);
}

#home > div:nth-of-type(1) a:first-child::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  transition: left 0.6s ease;
}

#home > div:nth-of-type(1) a:first-child:hover::before {
  left: 100%;
}

#home > div:nth-of-type(1) a:first-child:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 30px rgba(233, 69, 96, 0.6);
}

#home > div:nth-of-type(1) a:last-child {
  background: transparent;
  color: var(--text-primary);
  border: 2px solid var(--glass-border);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

#home > div:nth-of-type(1) a:last-child:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

#home > div[aria-label="Banner轮播"] {
  max-width: 100%;
  padding: 0;
  margin: 2rem 0 0;
  position: relative;
  animation: fadeInUp 0.8s ease 0.4s both;
}

#home > div[aria-label="Banner轮播"] svg {
  width: 100%;
  height: auto;
  border-radius: 0;
  display: block;
}

#home > div[aria-label="Banner轮播"]::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 80px;
  background: linear-gradient(to top, var(--bg-dark), transparent);
  pointer-events: none;
}

#home > ul[aria-label="平台数据"] {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  padding: 3rem 1.5rem 4rem;
  max-width: var(--max-width);
  margin: 0 auto;
  animation: fadeInUp 0.8s ease 0.5s both;
}

#home > ul[aria-label="平台数据"] li {
  text-align: center;
  padding: 2rem 1rem;
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

#home > ul[aria-label="平台数据"] li::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
  opacity: 0;
  transition: opacity var(--transition-base);
}

#home > ul[aria-label="平台数据"] li:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-glow);
  border-color: var(--primary);
}

#home > ul[aria-label="平台数据"] li:hover::before {
  opacity: 1;
}

#home > ul[aria-label="平台数据"] li strong {
  display: block;
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  background: linear-gradient(135deg, var(--primary), var(--primary-light));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.25rem;
}

#home > ul[aria-label="平台数据"] li {
  font-size: 0.9rem;
  color: var(--text-muted);
}

nav[aria-label="面包屑导航"] {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 1.5rem 1.5rem 0;
}

nav[aria-label="面包屑导航"] ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
}

nav[aria-label="面包屑导航"] ol li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
}

nav[aria-label="面包屑导航"] ol li:not(:last-child)::after {
  content: "/";
  color: var(--text-muted);
  opacity: 0.5;
}

nav[aria-label="面包屑导航"] ol li a {
  color: var(--text-secondary);
}

nav[aria-label="面包屑导航"] ol li a:hover {
  color: var(--primary);
}

nav[aria-label="面包屑导航"] ol li[aria-current="page"] {
  color: var(--primary);
  font-weight: 600;
}

main > section > article {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  margin-bottom: 1.5rem;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

main > section > article::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  opacity: 0;
  transition: opacity var(--transition-base);
}

main > section > article:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(233, 69, 96, 0.3);
}

main > section > article:hover::before {
  opacity: 1;
}

main > section > article h3 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

main > section > article h3::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
  flex-shrink: 0;
  box-shadow: 0 0 10px var(--primary);
}

main > section > article ul,
main > section > article ol {
  padding-left: 0;
}

main > section > article ul li,
main > section > article ol li {
  position: relative;
  padding: 0.5rem 0 0.5rem 1.75rem;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--glass-border);
  transition: all var(--transition-fast);
}

main > section > article ul li:last-child,
main > section > article ol li:last-child {
  border-bottom: none;
}

main > section > article ul li:hover,
main > section > article ol li:hover {
  color: var(--text-primary);
  padding-left: 2rem;
}

main > section > article ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  transition: all var(--transition-fast);
}

main > section > article ul li:hover::before {
  box-shadow: 0 0 10px var(--primary);
  transform: translateY(-50%) scale(1.3);
}

main > section > article ol {
  counter-reset: item;
}

main > section > article ol li {
  counter-increment: item;
}

main > section > article ol li::before {
  content: counter(item);
  position: absolute;
  left: 0;
  top: 0.5rem;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

main > section > article ol li:hover::before {
  box-shadow: 0 0 12px var(--primary);
  transform: scale(1.15);
}

main > section > article h4 {
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

main > section > article h4 + p {
  margin-bottom: 0;
}

#cases blockquote {
  margin: 1rem 0;
  transition: all var(--transition-base);
}

#cases blockquote:hover {
  transform: translateX(6px);
  border-left-color: var(--primary-light);
  box-shadow: var(--shadow-sm);
}

#articles article {
  cursor: pointer;
}

#articles article h3 a {
  color: var(--text-primary);
  transition: color var(--transition-fast);
}

#articles article h3 a:hover {
  color: var(--primary);
}

#articles article > a:last-child {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--primary);
  margin-top: 0.5rem;
  transition: all var(--transition-fast);
}

#articles article > a:last-child::after {
  content: "→";
  transition: transform var(--transition-fast);
}

#articles article > a:last-child:hover {
  color: var(--primary-light);
}

#articles article > a:last-child:hover::after {
  transform: translateX(4px);
}

#faq details {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-md);
  margin-bottom: 0.75rem;
  overflow: hidden;
  transition: all var(--transition-base);
}

#faq details:hover {
  border-color: rgba(233, 69, 96, 0.3);
  box-shadow: var(--shadow-sm);
}

#faq details[open] {
  border-color: var(--primary);
  box-shadow: var(--shadow-glow);
}

#faq summary {
  padding: 1.25rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.75rem;
  list-style: none;
  transition: all var(--transition-fast);
  position: relative;
  padding-right: 3rem;
}

#faq summary::-webkit-details-marker {
  display: none;
}

#faq summary::before {
  content: "Q";
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
  transition: all var(--transition-base);
}

#faq summary::after {
  content: "+";
  position: absolute;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.5rem;
  color: var(--primary);
  font-weight: 300;
  transition: transform var(--transition-base);
  line-height: 1;
}

#faq details[open] summary::after {
  transform: translateY(-50%) rotate(45deg);
}

#faq summary:hover {
  background: rgba(233, 69, 96, 0.05);
}

#faq details[open] summary {
  border-bottom: 1px solid var(--glass-border);
  background: rgba(233, 69, 96, 0.05);
}

#faq details p {
  padding: 1.25rem 1.5rem;
  margin-bottom: 0;
  animation: fadeIn 0.3s ease;
}

#howto article ol {
  counter-reset: howto;
}

#howto article ol li {
  counter-increment: howto;
  padding-left: 3.5rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
}

#howto article ol li::before {
  content: counter(howto);
  width: 32px;
  height: 32px;
  font-size: 0.9rem;
  top: 1rem;
}

#howto article ol li h4 {
  margin-bottom: 0.25rem;
}

#contact article p {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
}

#contact article p strong {
  min-width: 100px;
  color: var(--primary);
}

#sitemap ul {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 0.75rem;
}

#sitemap ul li {
  padding: 0;
  border: none;
}

#sitemap ul li::before {
  display: none;
}

#sitemap ul li a {
  display: block;
  padding: 0.75rem 1rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  text-align: center;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition-base);
}

#sitemap ul li a:hover {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

footer[role="contentinfo"] {
  background: var(--bg-darker);
  border-top: 1px solid var(--glass-border);
  padding: 3rem 1.5rem 2rem;
  margin-top: 2rem;
}

footer[role="contentinfo"] > section {
  max-width: var(--max-width);
  margin: 0 auto 2rem;
}

footer[role="contentinfo"] h2 {
  font-size: 1.1rem;
  color: var(--text-primary);
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
}

footer[role="contentinfo"] h2::after {
  width: 40px;
  height: 3px;
}

footer[role="contentinfo"] section[aria-label="友情链接"] ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

footer[role="contentinfo"] section[aria-label="友情链接"] ul li a {
  display: inline-block;
  padding: 0.4rem 1rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  font-size: 0.85rem;
  color: var(--text-secondary);
  transition: all var(--transition-base);
}

footer[role="contentinfo"] section[aria-label="友情链接"] ul li a:hover {
  background: rgba(233, 69, 96, 0.15);
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-2px);
}

footer[role="contentinfo"] section[aria-label="版权声明"] p,
footer[role="contentinfo"] section[aria-label="隐私政策"] p,
footer[role="contentinfo"] section[aria-label="免责声明"] p,
footer[role="contentinfo"] section[aria-label="网站安全说明"] p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.8;
}

footer[role="contentinfo"] section[aria-label="更新时间"] {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid var(--glass-border);
  margin-bottom: 0;
}

footer[role="contentinfo"] section[aria-label="更新时间"] p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

#back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: #fff;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(233, 69, 96, 0.4);
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-base);
  z-index: 999;
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  transform: translateY(-4px) scale(1.08);
  box-shadow: 0 8px 30px rgba(233, 69, 96, 0.6);
}

#back-to-top:active {
  transform: translateY(-2px) scale(1.02);
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity: 0;
    transform: translateX(-30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity: 0;
    transform: translateX(30px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}

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

.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.reveal-left {
  opacity: 0;
  transform: translateX(-30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-left.visible {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal-right.visible {
  opacity: 1;
  transform: translateX(0);
}

@media (max-width: 1024px) {
  header[role="banner"] nav ul {
    gap: 0;
  }

  header[role="banner"] nav ul li a {
    padding: 0.5rem 0.6rem;
    font-size: 0.82rem;
  }

  header[role="banner"] form[role="search"] input {
    width: 140px;
  }

  header[role="banner"] form[role="search"] input:focus {
    width: 180px;
  }

  #home > ul[aria-label="平台数据"] {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  :root {
    --header-height: 64px;
  }

  header[role="banner"] nav > div {
    padding: 0 1rem;
    gap: 0.75rem;
  }

  header[role="banner"] nav ul {
    display: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--glass-border);
    flex-direction: column;
    padding: 1rem;
    gap: 0.25rem;
    max-height: calc(100vh - var(--header-height));
    overflow-y: auto;
  }

  header[role="banner"] nav ul.open {
    display: flex;
    animation: fadeIn 0.3s ease;
  }

  header[role="banner"] nav ul li a {
    padding: 0.75rem 1rem;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
  }

  header[role="banner"] form[role="search"] {
    display: none;
  }

  #menu-toggle {
    display: flex;
  }

  main > section {
    padding: 2.5rem 1rem;
  }

  main > section:nth-child(even) {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  #home > h1 {
    padding-top: 2.5rem;
    font-size: 1.5rem;
  }

  #home > p:first-of-type,
  #home > p:nth-of-type(2) {
    padding-left: 1rem;
    padding-right: 1rem;
    font-size: 0.95rem;
  }

  #home > div:nth-of-type(1) {
    padding-left: 1rem;
    padding-right: 1rem;
  }

  #home > div:nth-of-type(1) a {
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    flex: 1;
    min-width: 140px;
  }

  #home > ul[aria-label="平台数据"] {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    padding: 2rem 1rem 3rem;
  }

  #home > ul[aria-label="平台数据"] li {
    padding: 1.25rem 0.75rem;
  }

  main > section > article {
    padding: 1.25rem;
    border-radius: var(--radius-md);
  }

  main > section > article:hover {
    transform: translateY(-2px);
  }

  #faq summary {
    padding: 1rem 1rem;
    padding-right: 2.5rem;
    font-size: 0.9rem;
  }

  #faq summary::after {
    right: 1rem;
  }

  #faq details p {
    padding: 1rem;
    font-size: 0.875rem;
  }

  #howto article ol li {
    padding-left: 3rem;
  }

  #howto article ol li::before {
    width: 28px;
    height: 28px;
    font-size: 0.8rem;
  }

  #sitemap ul {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }

  #sitemap ul li a {
    padding: 0.6rem 0.5rem;
    font-size: 0.8rem;
  }

  footer[role="contentinfo"] {
    padding: 2rem 1rem 1.5rem;
  }

  #back-to-top {
    bottom: 1.25rem;
    right: 1.25rem;
    width: 42px;
    height: 42px;
    font-size: 1.1rem;
  }

  blockquote {
    padding: 0.75rem 1rem;
  }
}

@media (max-width: 480px) {
  #home > ul[aria-label="平台数据"] {
    grid-template-columns: 1fr 1fr;
    gap: 0.5rem;
  }

  #home > ul[aria-label="平台数据"] li {
    padding: 1rem 0.5rem;
  }

  #home > ul[aria-label="平台数据"] li strong {
    font-size: 1.25rem;
  }

  #home > ul[aria-label="平台数据"] li {
    font-size: 0.75rem;
  }

  #home > div:nth-of-type(1) {
    flex-direction: column;
    align-items: stretch;
  }

  #home > div:nth-of-type(1) a {
    width: 100%;
  }

  main > section > article {
    padding: 1rem;
  }

  #contact article p {
    flex-direction: column;
    gap: 0;
  }

  #contact article p strong {
    min-width: auto;
  }

  #sitemap ul {
    grid-template-columns: repeat(2, 1fr);
  }
}

@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;
  }

  .reveal,
  .reveal-left,
  .reveal-right {
    opacity: 1;
    transform: none;
  }
}

@media print {
  header[role="banner"],
  #back-to-top,
  #theme-toggle,
  #menu-toggle {
    display: none;
  }

  body {
    background: #fff;
    color: #000;
  }

  main {
    padding-top: 0;
  }

  main > section > article {
    box-shadow: none;
    border: 1px solid #ddd;
    break-inside: avoid;
  }
}

::selection {
  background: rgba(233, 69, 96, 0.3);
  color: var(--text-primary);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

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

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  border-radius: 5px;
  border: 2px solid var(--bg-dark);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--primary-light), var(--primary));
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}

@media (hover: none) {
  main > section > article:hover {
    transform: none;
    box-shadow: none;
  }

  #home > ul[aria-label="平台数据"] li:hover {
    transform: none;
    box-shadow: none;
  }

  #sitemap ul li a:hover {
    transform: none;
  }
}