:root {
  --c-bg: #f4f7fb;
  --c-bg-alt: #ffffff;
  --c-surface: rgba(255, 255, 255, 0.72);
  --c-surface-solid: #ffffff;
  --c-border: rgba(26, 58, 92, 0.12);
  --c-text: #16283d;
  --c-text-soft: #4a6076;
  --c-text-mute: #7a8ea1;
  --c-primary: #1a3a5c;
  --c-primary-soft: #2c5a86;
  --c-accent: #4fc3f7;
  --c-accent-deep: #1e9fd8;
  --c-gradient: linear-gradient(135deg, #1a3a5c 0%, #2c6a9e 55%, #4fc3f7 100%);
  --c-gradient-soft: linear-gradient(135deg, rgba(79, 195, 247, 0.14), rgba(26, 58, 92, 0.08));
  --c-shadow-sm: 0 2px 8px rgba(22, 40, 61, 0.06);
  --c-shadow-md: 0 10px 30px rgba(22, 40, 61, 0.10);
  --c-shadow-lg: 0 20px 50px rgba(22, 40, 61, 0.16);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --header-h: 68px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --font: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

html[data-theme="dark"] {
  --c-bg: #0b1520;
  --c-bg-alt: #101d2b;
  --c-surface: rgba(22, 38, 55, 0.72);
  --c-surface-solid: #16263a;
  --c-border: rgba(120, 170, 210, 0.16);
  --c-text: #e6eef6;
  --c-text-soft: #a9c0d4;
  --c-text-mute: #7d94a8;
  --c-primary: #4fc3f7;
  --c-primary-soft: #81d4fa;
  --c-accent: #4fc3f7;
  --c-accent-deep: #29b0e8;
  --c-gradient: linear-gradient(135deg, #0f2a45 0%, #1a4a72 55%, #2b7fb8 100%);
  --c-gradient-soft: linear-gradient(135deg, rgba(79, 195, 247, 0.16), rgba(15, 42, 69, 0.5));
  --c-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --c-shadow-md: 0 10px 30px rgba(0, 0, 0, 0.4);
  --c-shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.55);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--c-text);
  background: var(--c-bg);
  background-image:
    radial-gradient(1200px 600px at 100% -10%, rgba(79, 195, 247, 0.10), transparent 60%),
    radial-gradient(900px 500px at -10% 20%, rgba(26, 58, 92, 0.08), transparent 60%);
  background-attachment: fixed;
  transition: background-color 0.35s var(--ease), color 0.35s var(--ease);
  overflow-x: hidden;
}

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

a {
  color: var(--c-accent-deep);
  text-decoration: none;
  transition: color 0.25s var(--ease);
}

a:hover,
a:focus-visible {
  color: var(--c-primary);
}

ul,
ol {
  padding-left: 1.4em;
}

li + li {
  margin-top: 0.35em;
}

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

h1 { font-size: clamp(1.6rem, 3.4vw, 2.4rem); }
h2 { font-size: clamp(1.35rem, 2.6vw, 1.9rem); }
h3 { font-size: clamp(1.1rem, 1.9vw, 1.35rem); }
h4 { font-size: 1.05rem; }

p { margin: 0 0 1em; }

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

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

/* ============ 顶部提示条 ============ */
#topbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  padding: 8px 20px;
  font-size: 0.82rem;
  color: #eaf6ff;
  background: var(--c-gradient);
  position: relative;
  z-index: 60;
}

#topbar span {
  letter-spacing: 0.04em;
}

#topbar a {
  color: #ffffff;
  padding: 2px 12px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: var(--radius-pill);
  font-size: 0.78rem;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}

#topbar a:hover {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  transform: translateY(-1px);
}

/* ============ 导航栏 ============ */
#site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--c-surface);
  -webkit-backdrop-filter: blur(16px) saturate(160%);
  backdrop-filter: blur(16px) saturate(160%);
  border-bottom: 1px solid var(--c-border);
  transition: box-shadow 0.3s var(--ease), background 0.35s var(--ease);
}

#site-header.is-scrolled {
  box-shadow: var(--c-shadow-md);
}

.header-inner {
  max-width: 1240px;
  margin: 0 auto;
  min-height: var(--header-h);
  padding: 8px 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

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

.logo svg {
  border-radius: 9px;
  box-shadow: 0 4px 14px rgba(26, 58, 92, 0.28);
  transition: transform 0.35s var(--ease);
}

.logo:hover svg {
  transform: rotate(-6deg) scale(1.06);
}

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

#main-nav {
  flex: 1 1 auto;
}

#main-nav ul {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

#main-nav li + li {
  margin-top: 0;
}

#main-nav a {
  display: inline-block;
  padding: 6px 12px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
  color: var(--c-text-soft);
  font-weight: 500;
  position: relative;
  transition: color 0.25s var(--ease), background 0.25s var(--ease);
}

#main-nav a::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 2px;
  width: 0;
  height: 2px;
  border-radius: 2px;
  background: var(--c-gradient);
  transform: translateX(-50%);
  transition: width 0.3s var(--ease);
}

#main-nav a:hover,
#main-nav a:focus-visible {
  color: var(--c-primary);
  background: var(--c-gradient-soft);
}

#main-nav a:hover::after {
  width: 60%;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

#site-search {
  display: flex;
  align-items: center;
  background: var(--c-surface-solid);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-pill);
  padding: 3px 4px 3px 14px;
  transition: box-shadow 0.25s var(--ease), border-color 0.25s var(--ease);
}

#site-search:focus-within {
  border-color: var(--c-accent);
  box-shadow: 0 0 0 3px rgba(79, 195, 247, 0.18);
}

#search-input {
  border: 0;
  outline: 0;
  background: transparent;
  font-family: inherit;
  font-size: 0.85rem;
  color: var(--c-text);
  width: 150px;
  padding: 6px 0;
}

#search-input::placeholder {
  color: var(--c-text-mute);
}

#site-search button,
#theme-toggle,
#menu-toggle {
  font-family: inherit;
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  background: var(--c-gradient);
  border: 0;
  border-radius: var(--radius-pill);
  padding: 7px 16px;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), filter 0.25s var(--ease);
}

#theme-toggle {
  background: var(--c-surface-solid);
  color: var(--c-text-soft);
  border: 1px solid var(--c-border);
}

#site-search button:hover,
#theme-toggle:hover,
#menu-toggle:hover {
  transform: translateY(-2px);
  box-shadow: var(--c-shadow-md);
  filter: brightness(1.05);
}

#menu-toggle {
  display: none;
}

/* ============ 面包屑 ============ */
#breadcrumb {
  max-width: 1240px;
  margin: 0 auto;
  padding: 14px 20px 0;
}

#breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.82rem;
  color: var(--c-text-mute);
}

#breadcrumb li + li {
  margin-top: 0;
}

#breadcrumb li + li::before {
  content: "/";
  margin-right: 8px;
  color: var(--c-text-mute);
  opacity: 0.6;
}

#breadcrumb a {
  color: var(--c-text-soft);
}

#breadcrumb a:hover {
  color: var(--c-accent-deep);
}

#breadcrumb [aria-current="page"] {
  color: var(--c-text);
  font-weight: 600;
}

/* ============ 主内容布局 ============ */
main {
  max-width: 1240px;
  margin: 0 auto;
  padding: 20px 20px 60px;
  display: block;
}

main > section {
  background: var(--c-surface);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3.4vw, 40px);
  margin-bottom: 28px;
  box-shadow: var(--c-shadow-sm);
  transition: box-shadow 0.35s var(--ease), transform 0.35s var(--ease), border-color 0.35s var(--ease);
  scroll-margin-top: calc(var(--header-h) + 20px);
  animation: fadeUp 0.7s var(--ease) both;
}

main > section:hover {
  box-shadow: var(--c-shadow-md);
  border-color: rgba(79, 195, 247, 0.35);
}

main > section > h2 {
  position: relative;
  padding-left: 16px;
  margin-top: 0;
}

main > section > h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.18em;
  bottom: 0.18em;
  width: 5px;
  border-radius: 4px;
  background: var(--c-gradient);
}

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

/* ============ Banner 轮播 ============ */
#banner {
  padding: 0 !important;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: #0f2a45;
  position: relative;
}

.banner-track {
  display: flex;
  transition: transform 0.6s var(--ease);
  will-change: transform;
}

.banner-slide {
  flex: 0 0 100%;
  min-width: 100%;
  position: relative;
}

.banner-slide svg {
  width: 100%;
  height: auto;
  display: block;
}

.banner-slide::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(15, 42, 69, 0.55) 0%, rgba(15, 42, 69, 0.05) 60%, transparent 100%);
  pointer-events: none;
}

.banner-controls {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 16px;
}

.banner-prev,
.banner-next {
  font-family: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  color: #eaf6ff;
  background: rgba(255, 255, 255, 0.14);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-pill);
  padding: 6px 16px;
  cursor: pointer;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}

.banner-prev:hover,
.banner-next:hover {
  background: rgba(79, 195, 247, 0.4);
  transform: translateY(-2px);
}

.banner-dots {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 6px;
}

.banner-dots button {
  width: 9px;
  height: 9px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.45);
  cursor: pointer;
  transition: width 0.3s var(--ease), background 0.3s var(--ease);
}

.banner-dots button[aria-selected="true"] {
  width: 26px;
  border-radius: var(--radius-pill);
  background: var(--c-accent);
}

/* ============ 首屏说明 ============ */
#intro-title {
  margin-top: 0;
  background: var(--c-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.intro-lead {
  font-size: 1.02rem;
  color: var(--c-text-soft);
  line-height: 1.85;
}

.intro-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 26px;
}

.stat {
  text-align: center;
  padding: 20px 12px;
  border-radius: var(--radius-md);
  background: var(--c-gradient-soft);
  border: 1px solid var(--c-border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.stat:hover {
  transform: translateY(-6px);
  box-shadow: var(--c-shadow-md);
}

.stat-num {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 800;
  color: var(--c-primary);
  font-variant-numeric: tabular-nums;
}

.stat-unit {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--c-accent-deep);
  margin-left: 2px;
}

.stat p {
  margin: 6px 0 0;
  font-size: 0.84rem;
  color: var(--c-text-mute);
}

/* ============ 列表与内容细节 ============ */
#about ul,
#products ul,
#solutions ul,
#industry ul,
#notes ul,
#extended ul {
  list-style: none;
  padding-left: 0;
}

#about ul li,
#products ul li,
#solutions ul li,
#industry ul li,
#notes ul li,
#extended ul li {
  position: relative;
  padding-left: 22px;
}

#about ul li::before,
#products ul li::before,
#solutions ul li::before,
#industry ul li::before,
#notes ul li::before,
#extended ul li::before {
  content: "";
  position: absolute;
  left: 4px;
  top: 0.62em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-gradient);
}

#products h3,
#solutions h3,
#industry h3,
#install h3,
#cases h3,
#about h3 {
  margin-top: 1.6em;
  padding-bottom: 8px;
  border-bottom: 1px dashed var(--c-border);
}

#install ol {
  counter-reset: step;
  list-style: none;
  padding-left: 0;
}

#install ol li {
  position: relative;
  padding: 14px 16px 14px 56px;
  margin-bottom: 10px;
  border-radius: var(--radius-md);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

#install ol li:hover {
  transform: translateX(4px);
  box-shadow: var(--c-shadow-sm);
}

#install ol li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--c-gradient);
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
}

/* ============ 新闻中心 ============ */
.news-list {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}

.news-list li {
  margin: 0;
  padding: 20px;
  border-radius: var(--radius-md);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}

.news-list li:hover {
  transform: translateY(-5px);
  box-shadow: var(--c-shadow-md);
  border-color: rgba(79, 195, 247, 0.45);
}

.news-list time {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--c-accent-deep);
  background: var(--c-gradient-soft);
  padding: 2px 12px;
  border-radius: var(--radius-pill);
  margin-bottom: 8px;
}

.news-list h3 {
  margin: 0 0 8px;
  font-size: 1.05rem;
}

.news-list p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--c-text-soft);
}

/* ============ 技术文章卡片 ============ */
#articles {
  display: block;
}

#articles > p {
  color: var(--c-text-soft);
}

.article-card {
  display: block;
  padding: 22px;
  margin-bottom: 14px;
  border-radius: var(--radius-md);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
  position: relative;
  overflow: hidden;
}

.article-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--c-gradient);
  transform: scaleY(0);
  transform-origin: top;
  transition: transform 0.35s var(--ease);
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--c-shadow-md);
  border-color: rgba(79, 195, 247, 0.4);
}

.article-card:hover::before {
  transform: scaleY(1);
}

.article-card h3 {
  margin: 0 0 6px;
  font-size: 1.1rem;
}

.article-card h3 a {
  color: var(--c-text);
}

.article-card h3 a:hover {
  color: var(--c-accent-deep);
}

.article-meta {
  font-size: 0.78rem;
  color: var(--c-text-mute);
  margin: 0 0 10px;
}

.article-card p {
  font-size: 0.92rem;
  color: var(--c-text-soft);
  margin-bottom: 12px;
}

.read-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--c-accent-deep);
  padding: 6px 16px;
  border-radius: var(--radius-pill);
  background: var(--c-gradient-soft);
  transition: gap 0.25s var(--ease), background 0.25s var(--ease), transform 0.25s var(--ease);
}

.read-more::after {
  content: "→";
  transition: transform 0.25s var(--ease);
}

.read-more:hover {
  background: var(--c-gradient);
  color: #fff;
  transform: translateY(-2px);
}

.read-more:hover::after {
  transform: translateX(3px);
}

/* ============ 客户案例引用 ============ */
blockquote {
  margin: 16px 0;
  padding: 18px 22px;
  border-left: 4px solid var(--c-accent);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--c-gradient-soft);
  color: var(--c-text-soft);
  font-style: normal;
}

blockquote p {
  margin: 0 0 6px;
  font-size: 0.95rem;
}

blockquote cite {
  display: block;
  font-size: 0.8rem;
  color: var(--c-text-mute);
  font-style: normal;
  text-align: right;
}

/* ============ FAQ 手风琴 ============ */
#faq details {
  border: 1px solid var(--c-border);
  border-radius: var(--radius-md);
  background: var(--c-bg-alt);
  margin-bottom: 12px;
  overflow: hidden;
  transition: box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}

#faq details[open] {
  border-color: rgba(79, 195, 247, 0.45);
  box-shadow: var(--c-shadow-sm);
}

#faq summary {
  cursor: pointer;
  padding: 16px 48px 16px 20px;
  font-weight: 600;
  color: var(--c-text);
  position: relative;
  list-style: none;
  transition: background 0.25s var(--ease), color 0.25s var(--ease);
}

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

#faq summary::after {
  content: "+";
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--c-gradient-soft);
  color: var(--c-accent-deep);
  font-weight: 700;
  font-size: 1rem;
  transition: transform 0.3s var(--ease), background 0.3s var(--ease);
}

#faq details[open] summary::after {
  content: "−";
  transform: translateY(-50%) rotate(180deg);
  background: var(--c-gradient);
  color: #fff;
}

#faq summary:hover {
  background: var(--c-gradient-soft);
}

#faq details p {
  margin: 0;
  padding: 0 20px 18px;
  font-size: 0.92rem;
  color: var(--c-text-soft);
  animation: fadeUp 0.4s var(--ease) both;
}

/* ============ 联系我们 ============ */
#contact address {
  font-style: normal;
}

#contact address ul {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px 20px;
}

#contact address li {
  margin: 0;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  font-size: 0.9rem;
  color: var(--c-text-soft);
  transition: border-color 0.25s var(--ease), transform 0.25s var(--ease);
}

#contact address li:hover {
  border-color: rgba(79, 195, 247, 0.5);
  transform: translateX(3px);
}

/* ============ 网站地图 & 友情链接 ============ */
#sitemap ul,
#links ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

#sitemap li,
#links li {
  margin: 0;
}

#sitemap a,
#links a {
  display: inline-block;
  padding: 7px 16px;
  font-size: 0.85rem;
  border-radius: var(--radius-pill);
  background: var(--c-bg-alt);
  border: 1px solid var(--c-border);
  color: var(--c-text-soft);
  transition: background 0.25s var(--ease), color 0.25s var(--ease), transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

#sitemap a:hover,
#links a:hover {
  background: var(--c-gradient);
  color: #fff;
  border-color: transparent;
  transform: translateY(-3px);
  box-shadow: var(--c-shadow-sm);
}

/* ============ 页脚 ============ */
#site-footer {
  background: var(--c-gradient);
  color: #dbeaf6;
  margin-top: 40px;
  position: relative;
  overflow: hidden;
}

#site-footer::before {
  content: "";
  position: absolute;
  top: -120px;
  right: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(79, 195, 247, 0.18);
  filter: blur(10px);
  pointer-events: none;
}

.footer-inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 50px 20px 30px;
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 36px;
  position: relative;
  z-index: 1;
}

.footer-about h2,
.footer-legal h2 {
  font-size: 1rem;
  color: #ffffff;
  margin: 0 0 10px;
  padding-left: 12px;
  position: relative;
}

.footer-about h2::before,
.footer-legal h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.2em;
  bottom: 0.2em;
  width: 3px;
  border-radius: 2px;
  background: var(--c-accent);
}

.footer-about p,
.footer-legal p {
  font-size: 0.85rem;
  line-height: 1.8;
  color: rgba(219, 234, 246, 0.82);
  margin: 0 0 10px;
}

.footer-legal h2:not(:first-child) {
  margin-top: 22px;
}

.footer-copy {
  grid-column: 1 / -1;
  border-top: 1px solid rgba(255, 255, 255, 0.18);
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
}

.footer-copy p {
  margin: 0;
  font-size: 0.8rem;
  color: rgba(219, 234, 246, 0.7);
}

#site-footer a {
  color: #9fe0ff;
}

#site-footer a:hover {
  color: #ffffff;
  text-decoration: underline;
}

/* ============ 返回顶部 ============ */
#back-to-top {
  position: fixed;
  right: 22px;
  bottom: 26px;
  z-index: 80;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--c-gradient);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  cursor: pointer;
  box-shadow: var(--c-shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px) scale(0.9);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease), visibility 0.3s, box-shadow 0.3s var(--ease);
}

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

#back-to-top:hover {
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 24px 50px rgba(26, 58, 92, 0.4);
}

/* ============ 滚动进入动画 ============ */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ============ 响应式 ============ */
@media (max-width: 1080px) {
  .header-inner {
    gap: 12px;
  }
  #search-input {
    width: 120px;
  }
  #main-nav a {
    padding: 6px 8px;
    font-size: 0.85rem;
  }
}

@media (max-width: 900px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 26px;
  }
  .intro-stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .news-list {
    grid-template-columns: 1fr;
  }
  #contact address ul {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  :root {
    --header-h: 60px;
  }

  #topbar {
    font-size: 0.74rem;
    gap: 8px;
    padding: 6px 12px;
  }

  .header-inner {
    flex-wrap: nowrap;
    padding: 8px 14px;
  }

  #menu-toggle {
    display: inline-block;
    margin-left: auto;
  }

  #main-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--c-surface-solid);
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--c-border);
    box-shadow: var(--c-shadow-md);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s var(--ease);
    flex-basis: 100%;
  }

  #main-nav.is-open {
    max-height: 70vh;
    overflow-y: auto;
  }

  #main-nav ul {
    flex-direction: column;
    align-items: stretch;
    padding: 10px 14px 16px;
    gap: 2px;
  }

  #main-nav a {
    display: block;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
  }

  #main-nav a::after {
    display: none;
  }

  .header-tools {
    order: 3;
    flex-basis: 100%;
    justify-content: space-between;
    padding-bottom: 4px;
  }

  #site-search {
    flex: 1 1 auto;
  }

  #search-input {
    width: 100%;
  }

  #theme-toggle {
    flex-shrink: 0;
  }

  main {
    padding: 14px 14px 40px;
  }

  main > section {
    border-radius: var(--radius-md);
    padding: 20px 16px;
    margin-bottom: 18px;
  }

  #banner {
    border-radius: var(--radius-md);
  }

  .banner-controls {
    bottom: 8px;
    gap: 6px;
  }

  .banner-prev,
  .banner-next {
    padding: 5px 12px;
    font-size: 0.72rem;
  }

  .intro-stats {
    gap: 10px;
  }

  .stat {
    padding: 14px 8px;
  }

  h1 { font-size: 1.45rem; }
  h2 { font-size: 1.25rem; }

  #install ol li {
    padding: 12px 12px 12px 48px;
  }

  #install ol li::before {
    left: 10px;
    width: 26px;
    height: 26px;
    font-size: 0.78rem;
  }

  .article-card {
    padding: 16px;
  }

  #faq summary {
    padding: 14px 44px 14px 16px;
    font-size: 0.92rem;
  }

  #faq details p {
    padding: 0 16px 16px;
  }

  #back-to-top {
    right: 14px;
    bottom: 16px;
    width: 42px;
    height: 42px;
    font-size: 0.6rem;
  }

  .footer-inner {
    padding: 36px 16px 24px;
  }

  .footer-copy {
    flex-direction: column;
  }
}

@media (max-width: 400px) {
  .intro-stats {
    grid-template-columns: 1fr;
  }
  .logo-text {
    font-size: 1rem;
  }
}

/* ============ 打印 ============ */
@media print {
  #topbar,
  #site-header,
  #banner,
  #back-to-top,
  .banner-controls,
  #site-search,
  #theme-toggle,
  #menu-toggle {
    display: none !important;
  }
  body {
    background: #fff;
    color: #000;
  }
  main > section {
    box-shadow: none;
    border: 1px solid #ccc;
    break-inside: avoid;
  }
  #site-footer {
    background: #fff;
    color: #000;
  }
  .footer-about p,
  .footer-legal p,
  .footer-copy p {
    color: #333;
  }
}