/* ============================================================
   NameShift 官网样式 — 纯静态，无任何依赖
   主题：亮 / 暗（跟随系统偏好，可手动切换并记忆）
   ============================================================ */

/* ---------- 设计变量 ---------- */
:root {
  --bg: #f5f7fb;
  --bg-soft: #ecf0f7;
  --surface: #ffffff;
  --surface-2: #f2f5fa;
  --text: #18202e;
  --muted: #5c6675;
  --border: #e3e8f0;
  --primary: #2e7cf6;
  --primary-strong: #1d63d8;
  --primary-soft: rgba(46, 124, 246, 0.1);
  --ok: #15803d;
  --ok-soft: rgba(22, 163, 74, 0.12);
  --warn: #b45309;
  --warn-soft: rgba(217, 119, 6, 0.14);
  --docs: #6d5bd0;
  --docs-soft: rgba(109, 91, 208, 0.12);
  --shadow-sm: 0 1px 2px rgba(23, 32, 55, 0.05), 0 2px 8px rgba(23, 32, 55, 0.05);
  --shadow-md: 0 4px 14px rgba(23, 32, 55, 0.08), 0 12px 32px rgba(23, 32, 55, 0.08);
  --shadow-lg: 0 8px 24px rgba(23, 32, 55, 0.1), 0 24px 64px rgba(23, 32, 55, 0.12);
  --radius: 14px;
  --nav-h: 64px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  --mono: "Cascadia Code", "SF Mono", Consolas, "JetBrains Mono", monospace;
}

html[data-theme="dark"] {
  --bg: #12151b;
  --bg-soft: #171a22;
  --surface: #191c24;
  --surface-2: #20242e;
  --text: #e9ecf2;
  --muted: #99a2b2;
  --border: #272c38;
  --primary: #4a8dff;
  --primary-strong: #2f79f2;
  --primary-soft: rgba(74, 141, 255, 0.14);
  --ok: #34d399;
  --ok-soft: rgba(52, 211, 153, 0.14);
  --warn: #fbbf24;
  --warn-soft: rgba(251, 191, 36, 0.16);
  --docs: #a99bff;
  --docs-soft: rgba(169, 155, 255, 0.16);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3), 0 2px 8px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, 0.35), 0 12px 32px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.4), 0 24px 64px rgba(0, 0, 0, 0.45);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  transition: background 0.3s ease, color 0.3s ease;
}

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

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

h1, h2, h3, p {
  margin: 0;
}

code {
  font-family: var(--mono);
  font-size: 0.86em;
  background: var(--primary-soft);
  color: var(--primary-strong);
  padding: 0.1em 0.4em;
  border-radius: 6px;
}

kbd {
  font-family: var(--mono);
  font-size: 0.78em;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 6px;
  padding: 1px 6px;
  margin: 0 2px;
}

html[data-theme="dark"] code {
  color: var(--primary);
}

.container {
  width: min(1120px, 100% - 48px);
  margin-inline: auto;
}

.container-narrow {
  width: min(760px, 100% - 48px);
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  border: none;
  border-radius: 12px;
  padding: 12px 24px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
  white-space: nowrap;
}

.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(46, 124, 246, 0.35);
}

.btn-primary:hover {
  background: var(--primary-strong);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(46, 124, 246, 0.4);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
}

.btn-ghost:hover {
  border-color: var(--primary);
  color: var(--primary);
  transform: translateY(-1px);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 16px;
  border-radius: 14px;
}

.btn-sm {
  padding: 8px 18px;
  font-size: 14px;
  border-radius: 10px;
}

.btn-block {
  width: 100%;
}

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.icon-btn:hover {
  background: var(--primary-soft);
  color: var(--primary);
}

.icon-btn svg {
  width: 18px;
  height: 18px;
}

/* 主题图标：亮色下显示月亮，暗色下显示太阳 */
.icon-sun { display: none; }
.icon-moon { display: block; }
html[data-theme="dark"] .icon-sun { display: block; }
html[data-theme="dark"] .icon-moon { display: none; }

/* ---------- 顶部导航 ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--nav-h);
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease, background 0.25s ease;
}

.nav.is-scrolled {
  border-bottom-color: var(--border);
}

.nav-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 28px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.2px;
}

.brand-logo {
  display: block;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  box-shadow: 0 2px 10px rgba(46, 124, 246, 0.35);
  flex: none;
}

.footer .brand-logo {
  width: 30px;
  height: 30px;
}

.nav-links {
  display: flex;
  gap: 26px;
  margin-inline: auto;
}

.nav-links a {
  color: var(--muted);
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1px;
  margin-left: auto;
}

.nav-burger {
  display: none;
}

/* 「免费下载」与左侧四个图标按钮拉开一点距离（图标组本身用 gap 收紧） */
.nav-cta {
  margin-left: 25px;
}

/* 社区外链：宽屏显示右上角图标按钮，≤1020px 换成导航栏里的文字链接。
   地址统一在 js/site-config.js 的 ⑦ 配置，留空由脚本隐藏。
   注：品牌图标允许实心填充（外链身份需要辨识度），
   站内功能图标统一用 stroke 描边，两类不要混用。 */
.nav-social {
  display: inline-flex;
}

.nav-links .link-social {
  display: none;
}

/* GitHub 官方 mark 是实心填充，且图形铺满整个 24 视框（直径约 23.7），
   而其余三个描边图标的实际外廓只有 19~20，同样的 18px 下会明显显大。
   这里单独收小一档做视觉等比补偿，使四个按钮看起来一样大。 */
.icon-btn[data-github] svg {
  width: 15px;
  height: 15px;
}

/* 移动端下拉菜单 */
@media (max-width: 820px) {
  .nav-links {
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    padding: 8px 24px;
    display: none;
  }

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

  .nav-links a {
    padding: 13px 4px;
    border-bottom: 1px solid var(--border);
  }

  .nav-links a:last-child {
    border-bottom: none;
  }

  .nav-burger {
    display: inline-flex;
  }

  .nav-cta {
    display: none;
  }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: calc(var(--nav-h) + 72px) 0 88px;
  overflow: hidden;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.55;
  pointer-events: none;
}

.hero::before {
  width: 480px;
  height: 480px;
  top: -180px;
  right: -120px;
  background: radial-gradient(circle, rgba(46, 124, 246, 0.28), transparent 65%);
}

.hero::after {
  width: 380px;
  height: 380px;
  bottom: -160px;
  left: -140px;
  background: radial-gradient(circle, rgba(90, 160, 255, 0.2), transparent 65%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
  gap: 48px;
  align-items: center;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-soft);
  border: 1px solid color-mix(in srgb, var(--primary) 25%, transparent);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 22px;
}

.hero-badge .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
  animation: pulse 2s infinite;
}

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

.hero-title {
  font-size: clamp(38px, 5.2vw, 58px);
  line-height: 1.18;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.hero-title em {
  font-style: normal;
  background: linear-gradient(120deg, var(--primary) 20%, #6fb0ff 90%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-sub {
  margin-top: 20px;
  font-size: 18px;
  color: var(--muted);
  max-width: 34em;
}

.hero-sub strong {
  color: var(--text);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 36px;
  list-style: none;
  padding: 0;
  margin: 38px 0 0;
}

.hero-stats li {
  display: flex;
  flex-direction: column;
}

.hero-stats strong {
  font-size: 22px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.3;
}

.hero-stats span {
  font-size: 13px;
  color: var(--muted);
}

/* ---------- Hero 演示卡 ---------- */
.hero-demo {
  min-width: 0;
}

.demo-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
  padding: 24px 26px 18px;
  position: relative;
}

.demo-card::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: 20px;
  padding: 1px;
  background: linear-gradient(135deg, rgba(46, 124, 246, 0.45), transparent 40%, rgba(46, 124, 246, 0.2));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.demo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.demo-scene {
  font-size: 15.5px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-soft);
  padding: 5px 14px;
  border-radius: 9px;
  transition: opacity 0.25s ease;
}

.demo-live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13.5px;
  color: var(--muted);
}

.live-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--ok);
  animation: pulse 1.6s infinite;
}

.demo-cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px minmax(0, 1.15fr) 84px;
  gap: 10px;
  font-size: 13px;
  color: var(--muted);
  padding: 0 2px 9px;
  border-bottom: 1px solid var(--border);
}

.demo-group {
  display: none;
}

.demo-group.is-active {
  display: grid;
  gap: 4px;
  padding-top: 7px;
}

.demo-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px minmax(0, 1.15fr) 84px;
  align-items: center;
  gap: 10px;
  padding: 10px 2px;
  border-radius: 8px;
  font-size: 15.5px;
  animation: rowIn 0.5s ease both;
}

.demo-group.is-active .demo-row:nth-child(1) { animation-delay: 0.05s; }
.demo-group.is-active .demo-row:nth-child(2) { animation-delay: 0.2s; }
.demo-group.is-active .demo-row:nth-child(3) { animation-delay: 0.35s; }

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

.f-before {
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 14.5px;
}

.demo-row svg {
  width: 18px;
  height: 18px;
  color: var(--primary);
}

.f-after {
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--mono);
  font-size: 14.5px;
}

.f-state {
  justify-self: end;
  font-size: 12.5px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
}

.f-state.ok {
  color: var(--ok);
  background: var(--ok-soft);
}

.f-state.warn {
  color: var(--warn);
  background: var(--warn-soft);
}

.demo-foot {
  margin-top: 12px;
  padding: 11px 2px 2px;
  border-top: 1px dashed var(--border);
}

.demo-note {
  font-size: 13.5px;
  color: var(--muted);
}

/* ---------- 通用 Section ---------- */
.section {
  padding: 96px 0;
}

.section-alt {
  background: var(--bg-soft);
  transition: background 0.3s ease;
}

.kicker {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--primary);
  text-transform: uppercase;
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: -0.3px;
}

.section-title em {
  font-style: normal;
  color: var(--primary);
}

.section-sub {
  margin-top: 16px;
  font-size: 17px;
  color: var(--muted);
  max-width: 44em;
}

/* ---------- 区块标题统一居中 ----------
   与下载卡片、dl-note 等既有居中元素保持同一节奏；主页 .section
   与更新日志页 .page-head 共用这一套 kicker / section-title / section-sub */
.section .kicker,
.section .section-title,
.section .section-sub,
.page-head .kicker,
.page-head .section-title,
.page-head .section-sub {
  text-align: center;
}

.section .section-sub,
.page-head .section-sub {
  margin-inline: auto;
}

/* ---------- 痛点 ---------- */
.pain-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 48px;
}

.pain-card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 30px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.25s ease;
}

.pain-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.pain-x {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: var(--warn-soft);
  color: var(--warn);
  font-weight: 800;
  font-size: 15px;
  margin-bottom: 18px;
}

.pain-card h3 {
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 10px;
}

.pain-card p {
  font-size: 15px;
  color: var(--muted);
}

.answer-strip {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  margin-top: 36px;
  padding: 24px 28px;
  background: linear-gradient(120deg, var(--primary), #4f95ff);
  border-radius: var(--radius);
  color: #fff;
  box-shadow: 0 8px 24px rgba(46, 124, 246, 0.35);
}

.answer-strip svg {
  width: 26px;
  height: 26px;
  flex: none;
  margin-top: 4px;
}

.answer-strip p {
  font-size: 17px;
  line-height: 1.6;
}

/* ---------- 六大模式 ---------- */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 48px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--primary) 40%, var(--border));
  box-shadow: var(--shadow-md);
}

.feature-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--primary-soft);
  color: var(--primary);
  margin-bottom: 18px;
}

.feature-icon svg {
  width: 22px;
  height: 22px;
}

.feature-card h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14.5px;
  color: var(--muted);
}

.tip-strip {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin-top: 36px;
  padding: 20px 26px;
  background: var(--surface);
  border: 1px dashed color-mix(in srgb, var(--primary) 45%, var(--border));
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 15.5px;
}

.tip-strip svg {
  width: 22px;
  height: 22px;
  flex: none;
  color: var(--primary);
  margin-top: 3px;
}

.tip-strip strong {
  color: var(--text);
}

/* ---------- 安全 ---------- */
.safety-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-top: 48px;
}

.safety-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 26px 24px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.25s ease;
}

.safety-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.safety-card h3 {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 10px;
}

.safety-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex: none;
  border-radius: 11px;
  background: var(--primary-soft);
  color: var(--primary);
}

.safety-icon svg {
  width: 20px;
  height: 20px;
}

.safety-card p {
  font-size: 14.5px;
  color: var(--muted);
}

/* ---------- 右键菜单演示 ---------- */
.ctx-demo {
  margin-top: 48px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  transition: background 0.3s ease, border-color 0.3s ease;
}

.ctx-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 20px;
}

.ctx-tab {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 999px;
  padding: 7px 20px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.ctx-tab:hover {
  color: var(--text);
  border-color: var(--primary);
}

.ctx-tab.is-active {
  color: var(--primary);
  background: var(--primary-soft);
  border-color: var(--primary);
}

.ctx-stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 148px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
}

.ctx-win {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 240px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
}

.ctx-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 12px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
  border-radius: 12px 12px 0 0;
  font-size: 12px;
  color: var(--muted);
}

.ctx-bar i {
  width: 9px;
  height: 9px;
  flex: none;
  border-radius: 50%;
  background: var(--border);
}

.ctx-bar-path {
  margin-left: 6px;
  font-family: var(--mono);
  font-size: 11px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ctx-bar-logo {
  width: 16px;
  height: 16px;
  flex: none;
  border-radius: 5px;
  background: var(--primary);
}

.ctx-bar-name {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--text);
}

.ctx-set {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* 场景切换：只显示当前场景那一组 */
.ctx-demo[data-scene="file"] .ctx-set[data-for="folder"],
.ctx-demo[data-scene="folder"] .ctx-set[data-for="file"] {
  display: none;
}

.ctx-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
}

.ctx-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 8px;
  border-radius: 8px;
  font-size: 12.5px;
}

.ctx-row svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--muted);
}

.ctx-name {
  font-family: var(--mono);
  font-size: 11.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ctx-row.is-sel {
  background: var(--primary-soft);
  box-shadow: inset 0 0 0 1px var(--primary);
}

.ctx-row.is-sel svg {
  color: var(--primary);
}

/* 阶段 1：选中项依次落入高亮 */
.ctx-demo[data-stage="1"] .ctx-row.is-sel {
  animation: ctxSelect 0.36s ease both;
}
.ctx-demo[data-stage="1"] .ctx-row.is-sel:nth-child(2) { animation-delay: 0.08s; }
.ctx-demo[data-stage="1"] .ctx-row.is-sel:nth-child(3) { animation-delay: 0.16s; }
.ctx-demo[data-stage="1"] .ctx-row.is-sel:nth-child(4) { animation-delay: 0.24s; }

@keyframes ctxSelect {
  from { background: transparent; box-shadow: none; transform: translateX(-4px); }
  to { background: var(--primary-soft); box-shadow: inset 0 0 0 1px var(--primary); transform: none; }
}

/* 右键落点涟漪（阶段 2） */
.ctx-ripple {
  position: absolute;
  left: 42%;
  top: 34%;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid var(--warn);
  opacity: 0;
  pointer-events: none;
  z-index: 2;
}

.ctx-ripple::after {
  content: "";
  position: absolute;
  inset: -7px;
  border-radius: 50%;
  border: 1px solid var(--warn);
  opacity: 0.5;
}

.ctx-demo[data-stage="2"] .ctx-ripple {
  opacity: 1;
  animation: ctxRipple 0.7s ease-out;
}

@keyframes ctxRipple {
  from { transform: scale(0.4); opacity: 0; }
  40% { opacity: 1; }
  to { transform: scale(1); opacity: 0.75; }
}

/* 右键菜单（仅在阶段 2 浮出） */
.ctx-menu {
  position: absolute;
  left: 48%;
  top: 38%;
  width: 198px;
  padding: 5px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(-6px) scale(0.97);
  transform-origin: top left;
  pointer-events: none;
  z-index: 3;
  transition: opacity 0.22s ease, transform 0.22s ease;
}

.ctx-demo[data-stage="2"] .ctx-menu {
  opacity: 1;
  transform: none;
}

.ctx-menu-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--text);
}

.ctx-menu-item svg {
  width: 15px;
  height: 15px;
  flex: none;
  color: var(--muted);
}

.ctx-menu-item.is-target {
  background: var(--primary);
  color: #fff;
}

.ctx-menu-item.is-target svg {
  color: #fff;
}

/* 导入流动区 */
.ctx-flow {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding-bottom: 24px;
}

.ctx-flow .ctx-set {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.ctx-chip {
  display: flex;
  align-items: center;
  gap: 6px;
  width: 136px;
  padding: 6px 9px;
  background: var(--primary-soft);
  border: 1px solid var(--primary);
  border-radius: 8px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text);
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  opacity: 0;
  transform: translateX(-16px);
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.ctx-chip svg {
  width: 14px;
  height: 14px;
  flex: none;
  color: var(--primary);
}

.ctx-demo[data-stage="4"] .ctx-chip {
  opacity: 1;
  transform: none;
}

.ctx-demo[data-stage="5"] .ctx-chip {
  opacity: 0;
  transform: translateX(16px);
}

.ctx-chip:nth-of-type(2) { transition-delay: 0.08s; }
.ctx-chip:nth-of-type(3) { transition-delay: 0.16s; }

.ctx-arrow {
  position: absolute;
  bottom: 6px;
  left: 50%;
  width: 56px;
  height: 14px;
  margin-left: -28px;
  color: var(--muted);
  opacity: 0.75;
}

/* NameShift 窗口：阶段 1-2 未启动，阶段 3 起就位 */
.ctx-app {
  opacity: 1;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.ctx-demo[data-stage="1"] .ctx-app,
.ctx-demo[data-stage="2"] .ctx-app {
  opacity: 0.45;
  transform: translateY(6px) scale(0.985);
}

.ctx-table {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px;
}

.ctx-thead,
.ctx-trow {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 58px;
  gap: 8px;
  align-items: center;
}

.ctx-thead {
  padding: 0 8px 2px;
  font-size: 11px;
  color: var(--muted);
}

.ctx-trow {
  padding: 5px 8px;
  border-radius: 8px;
  background: var(--surface-2);
  font-family: var(--mono);
  font-size: 11px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.ctx-trow span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ctx-state {
  justify-self: start;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  font-family: var(--font);
  font-size: 10.5px;
  color: var(--muted);
}

.ctx-demo[data-stage="5"] .ctx-trow {
  opacity: 1;
  transform: none;
}

.ctx-demo[data-stage="5"] .ctx-trow:nth-child(2) { transition-delay: 0.06s; }
.ctx-demo[data-stage="5"] .ctx-trow:nth-child(3) { transition-delay: 0.12s; }

.ctx-app-foot {
  margin-top: auto;
  padding: 8px 12px 12px;
}

.ctx-receiving,
.ctx-wait {
  font-size: 12px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.ctx-receiving {
  color: var(--muted);
}

.ctx-wait {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border: 1px dashed var(--warn);
  border-radius: 999px;
  color: var(--warn);
}

.ctx-demo[data-stage="3"] .ctx-receiving,
.ctx-demo[data-stage="4"] .ctx-receiving {
  opacity: 1;
}

.ctx-demo[data-stage="5"] .ctx-wait {
  opacity: 1;
  animation: ctxPulse 1.8s ease-in-out 0.3s infinite;
}

@keyframes ctxPulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

.ctx-caption {
  margin: 18px 0 0;
  text-align: center;
  font-size: 14px;
  color: var(--muted);
  min-height: 1.7em;
}

/* 步骤卡：复用 .feature-grid / .feature-card，只补一个序号徽章 */
.ctx-num {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  height: 30px;
  padding: 0 10px;
  margin-bottom: 18px;
  border-radius: 9px;
  background: var(--primary-soft);
  color: var(--primary);
  font-family: var(--mono);
  font-size: 13px;
  font-weight: 700;
}

/* ---------- 截图切换区 ---------- */
.shots {
  margin-top: 48px;
}

.shots-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 26px;
}

.shots-tab {
  font-family: inherit;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--muted);
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: 999px;
  padding: 9px 22px;
  cursor: pointer;
  transition: all 0.2s ease;
}

.shots-tab:hover {
  color: var(--primary);
  border-color: var(--primary);
}

.shots-tab.is-active {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 2px 10px rgba(46, 124, 246, 0.35);
}

.shots-frame {
  max-width: 1080px;
  margin-inline: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.shots-bar {
  display: flex;
  gap: 7px;
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  background: var(--surface-2);
}

.shots-bar i {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--border);
}

.shots-bar i:first-child {
  background: #fc5f57;
}

.shots-bar i:nth-child(2) {
  background: #febc2e;
}

.shots-bar i:last-child {
  background: #28c840;
}

.shots-body {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--surface-2);
}

.shot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  opacity: 0;
  transform: scale(1.015);
  transition: opacity 0.45s ease, transform 0.45s ease;
  pointer-events: none;
}

.shot.is-active {
  opacity: 1;
  transform: scale(1);
  pointer-events: auto;
  cursor: zoom-in;
}

/* ---------- 截图全屏预览（Lightbox） ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 40px 5px 0;
  background: rgba(8, 10, 16, 0.88);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

/* 单图模式（赞助二维码）：隐藏翻页按钮与圆点指示器 */
.lightbox.is-single .lb-prev,
.lightbox.is-single .lb-next,
.lightbox.is-single .lb-dots {
  display: none;
}

.lb-figure {
  margin: 0;
  max-width: 100%;
  text-align: center;
  transform: scale(0.97);
  transition: transform 0.25s ease;
}

.lightbox.is-open .lb-figure {
  transform: scale(1);
}

.lb-img {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
}

/* 说明文字与圆点悬浮在图片下缘，不占用图片高度 */
.lb-cap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 46px;
  margin: 0;
  color: #f2f5fa;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 1px;
  text-align: center;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.85), 0 0 4px rgba(0, 0, 0, 0.6);
  pointer-events: none;
}

.lb-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.lb-btn:hover {
  background: rgba(255, 255, 255, 0.24);
}

.lb-btn svg {
  width: 22px;
  height: 22px;
}

.lb-close {
  position: absolute;
  top: 14px;
  right: 14px;
}

.lb-prev {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
}

.lb-next {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
}

.lb-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 20px;
  display: flex;
  justify-content: center;
  gap: 9px;
  margin: 0;
}

.lb-dots i {
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.6);
}

.lb-dots i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.32);
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease;
}

.lb-dots i.is-active {
  background: #fff;
  transform: scale(1.3);
}

body.lb-open {
  overflow: hidden;
}

/* ---------- 技术栈 ---------- */
.tech {
  text-align: center;
}

.tech .section-sub {
  margin-inline: auto;
}

.tech-badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  list-style: none;
  padding: 0;
  margin: 36px 0 0;
}

.tech-badges li {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-soft);
  border: 1px solid color-mix(in srgb, var(--primary) 22%, transparent);
  padding: 8px 18px;
  border-radius: 999px;
}

.tech-quote {
  max-width: 680px;
  margin: 40px auto 0;
  padding: 26px 30px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  text-align: left;
}

.tech-quote p {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.8;
}

.tech-quote strong {
  color: var(--text);
}

/* ---------- 下载 ---------- */
.dl-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 420px));
  justify-content: center;
  gap: 26px;
  margin-top: 48px;
}

.dl-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 34px 32px 28px;
  box-shadow: var(--shadow-sm);
  text-align: center;
  transition: transform 0.2s ease, box-shadow 0.25s ease;
}

.dl-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.dl-os {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: var(--primary-soft);
  color: var(--primary);
  margin-bottom: 16px;
}

.dl-os svg {
  width: 30px;
  height: 30px;
}

.dl-card h3 {
  font-size: 21px;
  font-weight: 700;
}

.dl-meta {
  font-size: 14px;
  color: var(--muted);
  margin: 6px 0 0;
}

/* 下载操作区：默认一个主按钮，鼠标划过卡片时切换为两个具体版本 */
.dl-actions {
  position: relative;
  height: 58px;
  margin-top: 22px;
}

.dl-main-btn {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  margin: 0;
  transform: translateY(-50%);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.dl-hover {
  position: absolute;
  inset: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-content: center;
  gap: 14px;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.dl-opt {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}

.dl-opt .btn {
  width: 100%;
  padding: 11px 10px;
  font-size: 14.5px;
}

.dl-opt .btn em {
  font-style: normal;
  font-family: var(--mono);
  font-size: 11px;
  font-weight: 600;
  opacity: 0.85;
  margin-left: 4px;
}

.dl-card:hover .dl-main-btn,
.dl-card:focus-within .dl-main-btn {
  opacity: 0;
  transform: translateY(-50%) translateY(-10px);
  pointer-events: none;
}

.dl-card:hover .dl-hover,
.dl-card:focus-within .dl-hover {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* 触屏设备无悬停能力：始终直接显示两个具体选项 */
@media (hover: none) {
  .dl-main-btn {
    display: none;
  }

  .dl-actions {
    height: auto;
  }

  .dl-hover {
    position: static;
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }
}

.dl-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px 14px;
  margin-top: 34px;
  font-size: 14px;
  color: var(--muted);
}

.dl-note p {
  margin: 0;
}

.dl-pan {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: none;
  color: var(--primary);
  font-weight: 600;
}

.dl-pan:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.dl-pan .ext {
  width: 13px;
  height: 13px;
}

/* ---------- 赞助 ---------- */
/* 淡蓝渐晕：夹在下载区（浅灰）与 FAQ（浅灰）之间，用底色差异突出「支持」时刻 */
.sponsor {
  background: linear-gradient(
    180deg,
    var(--bg) 0%,
    var(--primary-soft) 14%,
    var(--primary-soft) 86%,
    var(--bg) 100%
  );
  transition: background 0.3s ease;
}

.sponsor .section-sub strong {
  color: var(--text);
}

.sponsor-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 330px);
  gap: 26px;
  margin-top: 44px;
}

.sponsor-copy {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 28px 30px;
  box-shadow: var(--shadow-sm);
}

.sponsor-copy h3 {
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 14px;
}

.sponsor-copy ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 11px;
  font-size: 15px;
  color: var(--muted);
}

.sponsor-copy li {
  position: relative;
  padding-left: 20px;
}

.sponsor-copy li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 0.55em;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--primary);
}

.sponsor-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 20px;
  font-size: 14.5px;
  font-weight: 600;
}

.sponsor-link:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.sponsor-link .ext {
  width: 13px;
  height: 13px;
}

/* 收款二维码卡：白底收款图在暗色主题下同样是一张白色卡片，保证可扫描 */
.sponsor-qr {
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 14px;
  box-shadow: var(--shadow-sm);
}

.sponsor-qr-btn {
  display: block;
  padding: 0;
  border: 0;
  background: none;
  border-radius: 10px;
  overflow: hidden;
  cursor: zoom-in;
}

.sponsor-qr-btn img {
  width: 100%;
  height: auto;
  transition: transform 0.25s ease;
}

.sponsor-qr-btn:hover img {
  transform: scale(1.03);
}

.sponsor-qr figcaption {
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}

/* 感谢墙：名单在 js/site-config.js 的 SPONSOR_WALL 中维护，为空时整块隐藏 */
.sponsor-wall {
  margin-top: 26px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px 26px;
  box-shadow: var(--shadow-sm);
}

.sponsor-wall[hidden] {
  display: none;
}

.sponsor-wall-title {
  font-size: 18px;
  font-weight: 700;
}

.sponsor-stats {
  margin-top: 10px;
  font-size: 15px;
  color: var(--muted);
}

.sponsor-stats strong {
  color: var(--primary);
}

.sponsor-wall-sub {
  margin-top: 4px;
  font-size: 13.5px;
  color: var(--muted);
}

.sponsor-list {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.sponsor-item {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px 14px;
}

.sponsor-item-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.sponsor-name {
  font-size: 14.5px;
  font-weight: 700;
}

.sponsor-amount {
  flex: none;
  font-size: 14.5px;
  font-weight: 700;
  color: var(--primary);
}

.sponsor-date {
  display: block;
  margin-top: 2px;
  font-size: 12px;
  color: var(--muted);
}

.sponsor-msg {
  margin: 4px 0 0;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
}

/* 展开全部 / 收起 */
.sponsor-more {
  display: block;
  margin: 16px auto 0;
  padding: 8px 24px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  color: var(--primary);
  background: var(--primary-soft);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.sponsor-more:hover {
  background: var(--primary);
  color: #fff;
}

.sponsor-more[hidden] {
  display: none;
}

@media (max-width: 680px) {
  .sponsor-card {
    grid-template-columns: 1fr;
  }
}

.footer-sponsor {
  font-size: 14px;
}

.footer-sponsor a {
  font-weight: 600;
}

.footer-sponsor a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- FAQ ---------- */
.faq-list {
  margin-top: 40px;
  display: grid;
  gap: 14px;
}

.faq-list details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 4px 24px;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s ease;
}

.faq-list details[open] {
  border-color: color-mix(in srgb, var(--primary) 40%, var(--border));
}

.faq-list summary {
  padding: 16px 0;
  font-size: 16.5px;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 36px;
  user-select: none;
}

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

.faq-list summary::after {
  content: "+";
  position: absolute;
  right: 2px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  font-weight: 500;
  color: var(--primary);
  transition: transform 0.25s ease;
}

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

.faq-list details p {
  padding: 0 0 18px;
  color: var(--muted);
  font-size: 15px;
}

.faq-list details p strong {
  color: var(--text);
}

/* ---------- 更新日志时间线 ---------- */
.log-timeline {
  position: relative;
  margin-top: 48px;
  padding-left: 34px;
}

/* 时间线竖线 */
.log-timeline::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  border-radius: 1px;
  background: var(--border);
}

.log-entry {
  position: relative;
  padding-bottom: 46px;
}

.log-entry:last-child {
  padding-bottom: 8px;
}

/* 版本节点圆点 */
.log-dot {
  position: absolute;
  left: -31px;
  top: 6px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 0 4px var(--primary-soft);
}

.log-head {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.log-version {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: 0.3px;
}

.log-badge {
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: var(--primary);
  padding: 3px 11px;
  border-radius: 999px;
}

.log-date {
  font-family: var(--mono);
  font-size: 13.5px;
  color: var(--muted);
}

.log-list {
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 9px;
}

.log-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 15px;
  line-height: 1.65;
  color: var(--muted);
}

.log-tag {
  flex: none;
  margin-top: 2px;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 999px;
}

.log-tag.add {
  color: var(--ok);
  background: var(--ok-soft);
}

.log-tag.improve {
  color: var(--primary);
  background: var(--primary-soft);
}

.log-tag.fix {
  color: var(--warn);
  background: var(--warn-soft);
}

.log-tag.change {
  color: var(--muted);
  background: var(--surface-2);
  border: 1px solid var(--border);
  padding: 1px 8px;
}

.log-tag.docs {
  color: var(--docs);
  background: var(--docs-soft);
}

.log-empty {
  color: var(--muted);
  font-size: 15px;
}

/* ---------- 子页面（更新日志等） ---------- */
.page-head {
  padding: calc(var(--nav-h) + 72px) 0 56px;
}

.nav-links a[aria-current="page"] {
  color: var(--primary);
  font-weight: 600;
}

/* 外链小图标 */
.nav-links a .ext,
.faq-more .ext,
.dl-pan .ext {
  opacity: 0.55;
  transition: opacity 0.2s ease;
}

.nav-links a:hover .ext,
.faq-more a:hover .ext,
.dl-pan:hover .ext {
  opacity: 1;
}

.nav-links a .ext {
  width: 12px;
  height: 12px;
  margin-left: 3px;
  vertical-align: -1px;
}

.faq-more .ext {
  width: 13px;
  height: 13px;
  margin-left: 2px;
  vertical-align: -2px;
}

/* FAQ 末尾的更多帮助引导 */
.faq-more {
  margin-top: 24px;
  font-size: 15px;
  color: var(--muted);
}

.faq-more a {
  color: var(--primary);
  font-weight: 600;
}

.faq-more a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---------- 页脚 ---------- */
.footer {
  border-top: 1px solid var(--border);
  background: var(--bg-soft);
  padding: 44px 0;
  transition: background 0.3s ease;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-align: center;
}

.footer-tagline {
  font-size: 14px;
  color: var(--muted);
}

.footer-meta {
  font-size: 13px;
  color: var(--muted);
  opacity: 0.8;
}

.footer-icp {
  font-size: 12.5px;
}

.footer-icp a {
  color: var(--muted);
  transition: color 0.2s ease;
}

.footer-icp a:hover {
  color: var(--primary);
}

/* ---------- 滚动渐显 ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

/* 渐显延迟：同容器内错落出现 */
.reveal:nth-child(2) { transition-delay: 0.08s; }
.reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal:nth-child(4) { transition-delay: 0.24s; }

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .demo-row {
    animation: none;
  }

  /* 右键演示：关掉循环动画，停留在「就位」终态 */
  .ctx-demo .ctx-row.is-sel,
  .ctx-demo .ctx-ripple,
  .ctx-demo .ctx-wait {
    animation: none;
  }
}

/* ---------- 响应式 ---------- */
@media (max-width: 1020px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .hero-copy {
    text-align: center;
  }

  .hero-sub {
    margin-inline: auto;
  }

  .hero-cta,
  .hero-stats {
    justify-content: center;
  }

  .hero-demo {
    max-width: 680px;
    margin-inline: auto;
    width: 100%;
  }

  .pain-grid,
  .feature-grid,
  .safety-grid,
  .ctx-steps {
    grid-template-columns: repeat(2, 1fr);
  }

  .ctx-stage {
    grid-template-columns: minmax(0, 1fr) 124px minmax(0, 1fr);
    gap: 10px;
  }

  .ctx-chip {
    width: 116px;
  }

  .ctx-menu {
    width: 178px;
  }

  /* 社区外链：改为导航栏里的文字链接 */
  .nav-social {
    display: none;
  }

  .nav-links .link-social {
    display: inline-flex;
    align-items: center;
    gap: 5px;
  }
}

@media (max-width: 680px) {
  .section {
    padding: 68px 0;
  }

  .hero {
    padding-top: calc(var(--nav-h) + 48px);
  }

  .pain-grid,
  .feature-grid,
  .safety-grid,
  .dl-grid {
    grid-template-columns: 1fr;
  }

  .log-timeline {
    padding-left: 26px;
  }

  .log-dot {
    left: -23px;
  }

  .page-head {
    padding: calc(var(--nav-h) + 48px) 0 40px;
  }

  .lightbox {
    padding: 40px 4px 0;
  }

  .lb-prev {
    left: 8px;
  }

  .lb-next {
    right: 8px;
  }

  .lb-img {
    max-height: 70vh;
  }

  .lb-dots {
    bottom: 16px;
  }

  .lb-cap {
    bottom: 40px;
  }

  .hero-stats {
    gap: 18px 26px;
  }

  .demo-cols,
  .demo-row {
    grid-template-columns: minmax(0, 1fr) 18px minmax(0, 1fr) 64px;
    gap: 7px;
  }

  .f-before,
  .f-after {
    font-size: 11.5px;
  }

  .answer-strip,
  .tip-strip {
    flex-direction: column;
    gap: 10px;
  }

  /* 右键演示：窄屏上下堆叠，流动区改为横向并转纵向位移 */
  .ctx-demo {
    padding: 16px 14px;
  }

  .ctx-stage {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .ctx-win {
    min-height: 0;
  }

  .ctx-flow {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    padding-bottom: 0;
  }

  .ctx-flow .ctx-set {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    width: auto;
  }

  .ctx-chip {
    width: auto;
    max-width: 150px;
    transform: translateY(-12px);
  }

  .ctx-demo[data-stage="4"] .ctx-chip {
    transform: none;
  }

  .ctx-demo[data-stage="5"] .ctx-chip {
    transform: translateY(12px);
  }

  .ctx-arrow {
    display: none;
  }

  .ctx-menu {
    left: 30%;
    top: 32%;
  }
}

/* ---------- MenuGo 演示卡 ---------- */

.mg-state {
  color: var(--primary);
  font-weight: 700;
}

.mg-seg {
  display: flex;
  gap: 4px;
  padding: 4px;
  margin: 14px 0;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-2);
}

.mg-seg-btn {
  flex: 1 1 0;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.18s, color 0.18s;
}

.mg-seg-btn:hover:not(.is-active) {
  background: var(--surface);
  color: var(--text);
}

.mg-seg-btn.is-active {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
}

.mg-seg-btn svg {
  width: 16px;
  height: 16px;
}

.mg-reg {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--primary-soft);
}

.mg-reg-title {
  margin: 0 0 4px;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.mg-reg-key {
  display: block;
  padding: 0;
  border: 0;
  background: none;
  font-family: var(--mono);
  font-size: 11.5px;
  color: var(--primary-strong);
  word-break: break-all;
}

.mg-reg-key.mg-flash {
  animation: mg-flash 0.5s ease-out;
}

@keyframes mg-flash {
  0% {
    background: var(--primary-soft);
  }
  100% {
    background: transparent;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mg-reg-key.mg-flash {
    animation: none;
  }
}

/* ---------- 原理区：注册表清单 ---------- */

.how-frame {
  max-width: 880px;
  margin: 0 auto;
}

.how-table {
  display: flex;
  flex-direction: column;
  padding: 10px 18px 14px;
}

.how-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 9px 0;
  border-bottom: 1px dashed var(--border);
  font-size: 14px;
}

.how-row:last-child {
  border-bottom: 0;
}

.how-k {
  flex: 0 0 96px;
  font-weight: 600;
  color: var(--text);
}

/* ---------- 原理区：终端式注册表清单 ---------- */

.reg-demo {
  max-width: 880px;
  margin: 0 auto;
}

.reg-term {
  /* 浅色主题：白色代码块 */
  --term-bg: #ffffff;
  --term-bar-bg: var(--surface-2);
  --term-bar-border: var(--border);
  --term-dot: var(--border);
  --term-title: var(--muted);
  --term-text: #3b465a;
  --term-muted: var(--muted);
  --term-prompt: var(--primary-strong);
  --term-cmt: var(--muted);
  --term-add: var(--ok);
  --term-add-soft: #166534;
  --term-del: #dc2626;
  --term-border: rgba(127, 142, 168, 0.25);

  border: 1px solid var(--term-border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--term-bg);
  box-shadow: var(--shadow-md);
}

html[data-theme="dark"] .reg-term {
  /* 深色主题：保持终端深色 */
  --term-bg: #0f131b;
  --term-bar-bg: rgba(255, 255, 255, 0.04);
  --term-bar-border: rgba(255, 255, 255, 0.07);
  --term-dot: rgba(255, 255, 255, 0.14);
  --term-title: #7d8798;
  --term-text: #dbe3ef;
  --term-muted: #6b7686;
  --term-prompt: #4a8dff;
  --term-add: #4ade80;
  --term-add-soft: #86efac;
  --term-del: #f87171;
}

.reg-term-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  background: var(--term-bar-bg);
  border-bottom: 1px solid var(--term-bar-border);
}

.reg-term-bar i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--term-dot);
}

.reg-term-bar i:first-child {
  background: #f66;
}

.reg-term-bar i:nth-child(2) {
  background: #fc6;
}

.reg-term-bar i:nth-child(3) {
  background: #6c6;
}

.reg-term-bar span {
  margin-left: 8px;
  font-size: 11px;
  color: var(--term-title);
  font-family: var(--mono);
}

.reg-term-body {
  padding: 14px 18px 16px;
  font-family: var(--mono);
  font-size: 12px;
  line-height: 1.75;
  color: var(--term-text);
  overflow-x: auto;
}

.reg-cmd {
  margin: 10px 0 4px;
}

.reg-cmd:first-child {
  margin-top: 0;
}

.reg-prompt {
  color: var(--term-prompt);
  font-weight: 600;
}

.reg-cmt {
  color: var(--term-cmt);
}

.reg-line {
  margin: 2px 0 2px 14px;
}

.reg-line.sub {
  margin-left: 30px;
  font-size: 11px;
  color: var(--term-muted);
}

.reg-op {
  display: inline-block;
  width: 14px;
  font-weight: 700;
}

.reg-line.add .reg-op,
.reg-line.add {
  color: var(--term-add);
}

.reg-line.del .reg-op,
.reg-line.del {
  color: var(--term-del);
}

.reg-line.add.sub {
  color: var(--term-add-soft);
  opacity: 0.85;
}

.reg-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 14px;
}

.reg-card {
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.reg-card h3 {
  margin: 0 0 6px;
  font-size: 13px;
}

.reg-card p {
  margin: 0;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}

@media (max-width: 760px) {
  .reg-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- 界面预览：代码还原的 MenuGo 窗口 ---------- */


.mgapp {
  max-width: 620px;
  margin: 0 auto;
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg);
  font-size: 12px;
  line-height: 1.45;
  box-shadow: var(--shadow-md);
  transition: background 0.3s ease;
}

.mgapp-titlebar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.mgapp-titlebar img {
  width: 16px;
  height: 16px;
  border-radius: 4px;
}

.mgapp-title {
  font-weight: 600;
  font-size: 12px;
}

.mgapp-winbtns {
  margin-left: auto;
  display: flex;
  gap: 6px;
}

.mgapp-winbtns i {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
}

.mgapp-winbtns i.close {
  background: #e5484d;
}

.mgapp-topbar {
  display: flex;
  align-items: baseline;
  gap: 8px;
  padding: 10px 14px 8px;
}

.mgapp-brand {
  font-weight: 700;
  font-size: 14px;
}

.mgapp-tag {
  font-size: 10.5px;
  color: var(--muted);
}

.mgapp-card {
  margin: 2px 12px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.mgapp-line {
  color: var(--muted);
}

.mgapp-state {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  transition: color 0.3s ease;
}

.mgapp[data-style="classic"] .mgapp-state {
  color: var(--primary);
}

.mgapp-desc {
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
}

.mgapp-seg {
  display: flex;
  gap: 4px;
  margin-top: 10px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
}

.mgapp-seg-btn {
  flex: 1 1 0;
  padding: 6px 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--muted);
  font-size: 11.5px;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.25s, color 0.25s;
}

.mgapp-seg-btn:hover:not(.is-active) {
  background: var(--surface);
  color: var(--text);
}

.mgapp-seg-btn.is-active {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
}

.mgapp-toast {
  margin-top: 10px;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--warn-soft);
  color: var(--warn);
  font-size: 10.5px;
  opacity: 0;
  transform: translateY(-2px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.mgapp.is-pending .mgapp-toast {
  opacity: 1;
  transform: none;
}

.mgapp-status {
  display: flex;
  justify-content: space-between;
  padding: 8px 14px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  font-size: 10.5px;
  color: var(--muted);
}

.mgapp-caption {
  margin: 10px 4px 0;
  font-size: 11.5px;
  color: var(--muted);
  text-align: center;
}

@media (prefers-reduced-motion: reduce) {
  .mgapp-seg-btn,
  .mgapp-state,
  .mgapp-toast {
    transition: none;
  }
}

/* 下载区仅一张卡片时居中显示 */
.dl-grid:has(> :only-child) {
  grid-template-columns: minmax(0, 420px);
}
.hero-title {
  font-size: clamp(38px, 5.2vw, 56px);
}
/* ---------- Hero 大一号 ---------- */

.hero-sub {
  margin-top: 22px;
  font-size: 19px;
}

.hero-badge {
  font-size: 14px;
}

.btn-lg {
  padding: 15px 30px;
  font-size: 17px;
}

.hero-stats strong {
  font-size: 25px;
}


/* ---------- 界面预览：窗口 + 右键菜单双栏联动 ---------- */

.demo-pair {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  max-width: 1000px;
  margin: 0 auto;
}

.demo-pair .mgapp {
  max-width: none;
}

.ctxmock {
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.ctxmock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 14px;
  background: var(--surface-2);
  border-bottom: 1px solid var(--border);
}

.ctxmock-file {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 500;
}

.ctxmock-file svg {
  width: 15px;
  height: 15px;
  color: var(--primary);
}

.ctxmock-style {
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-soft);
  padding: 3px 9px;
  border-radius: 999px;
  white-space: nowrap;
}

.ctxmock-body {
  position: relative;
  display: grid;
  min-height: 380px;
  padding: 12px;
}

.cmenu {
  grid-area: 1 / 1;
  align-self: start;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  box-shadow: var(--shadow-md);
  padding: 5px;
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transition: opacity 0.35s ease, transform 0.35s ease;
  pointer-events: none;
}

.demo-pair[data-style="default"] .cmenu-win11 {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.demo-pair[data-style="classic"] .cmenu-classic {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}

.cmenu-row {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 10px;
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--text);
  cursor: default;
}

.cmenu-row:hover {
  background: var(--surface-2);
}

.cmenu-row svg {
  width: 14px;
  height: 14px;
  color: var(--muted);
}

.cmenu-row .arr {
  margin-left: auto;
  font-size: 10px;
  color: var(--muted);
}

.cmenu-sep {
  height: 1px;
  margin: 4px 6px;
  background: var(--border);
}

.cmenu-row.cmenu-more {
  color: var(--primary);
  font-weight: 500;
}

.cmenu-row.cmenu-more svg {
  color: var(--primary);
}

.ctxmock-cap {
  margin: 0;
  padding: 9px 14px 11px;
  border-top: 1px solid var(--border);
  font-size: 11.5px;
  color: var(--muted);
}

@media (max-width: 860px) {
  .demo-pair {
    grid-template-columns: 1fr;
  }
}


/* ---------- 界面预览：左窗口大、右菜单小 ---------- */

.demo-pair {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
}

/* ---------- 首页演示窗口放大（真实占位，避免被 hero 裁剪） ---------- */


.hero-demo .mgapp {
  max-width: 620px;
}

/* ---------- Hero 终版：标题单行 + 右侧窗口放大 ---------- */

.hero-inner {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
  gap: 48px;
}

.hero-title {
  font-size: clamp(38px, 5.2vw, 56px);
}

@media (max-width: 1020px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }
}

/* 首页统计条：居中放在演示窗口下方 */
.hero-demo .hero-stats {
  justify-content: center;
  margin-top: 20px;
}

/* ---------- 界面预览：双卡等宽等高、占满整行 ---------- */

.demo-pair {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: stretch;
  max-width: none;
}

.demo-pair .mgapp {
  margin: 0;
  max-width: none;
  display: flex;
  flex-direction: column;
}

.demo-pair .mgapp .mgapp-card {
  flex: 1 1 auto;
}

.demo-pair .mgapp .mgapp-status {
  margin-top: auto;
}

/* ---------- 首页统计：2×2 卡片矩阵 ---------- */

.hero-demo .hero-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.stat-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 5px;
  padding: 13px 15px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  list-style: none;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.stat-card:hover {
  border-color: var(--primary);
  transform: translateY(-1px);
}

.stat-icon {
  display: inline-grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--primary-soft);
  color: var(--primary);
}

.stat-icon svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stat-num {
  font-size: 19px;
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}

.stat-label {
  font-size: 11.5px;
  color: var(--muted);
}

/* ---------- 界面预览：上下排版 + 流动连接 ---------- */

.demo-pair {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 720px;
  margin: 0 auto;
}

.demo-pair .mgapp {
  width: 100%;
  max-width: 640px;
  margin: 0;
}

.demo-pair .ctxmock {
  width: 100%;
}

.demo-pair .cmenu {
  width: min(460px, 100%);
  margin-inline: auto;
}

.pair-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  padding: 10px 0;
}

.pair-flow-line {
  position: relative;
  width: 2px;
  height: 40px;
  border-radius: 1px;
  background: var(--border);
  overflow: hidden;
}

.pair-flow-line::after {
  content: "";
  position: absolute;
  left: 0;
  top: -45%;
  width: 100%;
  height: 45%;
  background: linear-gradient(180deg, transparent, var(--primary));
  animation: pair-flow-down 1.4s ease-in infinite;
}

@keyframes pair-flow-down {
  to {
    top: 100%;
  }
}

.pair-flow-label {
  font-size: 11.5px;
  color: var(--muted);
}

.demo-pair.is-flowing .pair-flow-line {
  background: var(--primary-soft);
}

.demo-pair.is-flowing .pair-flow-label {
  color: var(--primary);
}

@media (prefers-reduced-motion: reduce) {
  .pair-flow-line::after {
    animation: none;
  }
}

/* ---------- 首页统计：缩小并与演示窗口左右对齐 ---------- */

.hero-demo .hero-stats {
  max-width: 620px;
  margin-inline: auto;
  gap: 10px;
  margin-top: 16px;
}

.stat-card {
  padding: 11px 13px;
  gap: 4px;
}

.stat-icon {
  width: 26px;
  height: 26px;
  border-radius: 7px;
}

.stat-icon svg {
  width: 13px;
  height: 13px;
}

.stat-num {
  font-size: 17px;
}

.stat-label {
  font-size: 11px;
}

/* ---------- 界面预览：两卡同宽对齐 + 与上方文字拉开间距 ---------- */

.demo-pair {
  max-width: 660px;
  margin-top: 28px;
}

.demo-pair .mgapp {
  width: 100%;
  max-width: none;
}

/* ---------- 首页统计：四卡一行 ---------- */

.hero-demo .hero-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 720px) {
  .hero-demo .hero-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- 首页统计：更小的内容自适应卡片 ---------- */

.hero-demo .hero-stats {
  grid-template-columns: repeat(4, auto);
  justify-content: start;
  gap: 8px;
  max-width: none;
  margin-top: 14px;
}

.stat-card {
  padding: 9px 11px;
  gap: 3px;
}

.stat-icon {
  width: 22px;
  height: 22px;
  border-radius: 6px;
}

.stat-icon svg {
  width: 11px;
  height: 11px;
}

.stat-num {
  font-size: 15px;
}

.stat-label {
  font-size: 10.5px;
}

@media (max-width: 720px) {
  .hero-demo .hero-stats {
    grid-template-columns: repeat(2, auto);
  }
}

/* 右键菜单容器高度由内容决定，消除底部空隙 */
.ctxmock-body {
  min-height: 0;
}

/* 首页统计卡：相对上方窗口居中 */
.hero-demo .hero-stats {
  justify-content: center;
}

/* ---------- 首页：窗口顶与标题水平对齐 + 统计与窗口同宽 ---------- */

.hero-inner {
  align-items: start;
}

.hero-demo {
  margin-top: 90px; /* 徽章块高度：使窗口顶边与标题顶边平齐 */
}

.hero-demo .hero-stats {
  max-width: 620px;
  margin-inline: auto;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  justify-content: stretch;
}

@media (max-width: 1020px) {
  .hero-inner {
    align-items: center;
  }

  .hero-demo {
    margin-top: 0;
  }
}
