/* ===== 基础重置 & 变量 ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --primary: #2563eb;
  --primary-dark: #1648c7;
  --accent: #7c3aed;
  --ink: #1d1d1f;
  --text: #1d1d1f;
  --text-muted: #6e6e73;
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-soft: #fbfbfd;
  --border: rgba(0, 0, 0, .1);
  --shadow: 0 24px 80px rgba(0, 0, 0, .12);
  --radius: 8px;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --primary: #60a5fa;
    --primary-dark: #3b82f6;
    --accent: #a78bfa;
    --ink: #f5f5f7;
    --text: #f5f5f7;
    --text-muted: #a1a1a6;
    --bg: #000000;
    --surface: #1d1d1f;
    --surface-soft: #161617;
    --border: rgba(255, 255, 255, .14);
    --shadow: 0 24px 80px rgba(0, 0, 0, .42);
  }
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --primary: #60a5fa;
  --primary-dark: #3b82f6;
  --accent: #a78bfa;
  --ink: #f5f5f7;
  --text: #f5f5f7;
  --text-muted: #a1a1a6;
  --bg: #000000;
  --surface: #1d1d1f;
  --surface-soft: #161617;
  --border: rgba(255, 255, 255, .14);
  --shadow: 0 24px 80px rgba(0, 0, 0, .42);
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

body.modal-open {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

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

.container {
  width: min(100%, 1180px);
  margin: 0 auto;
  padding: 0 24px;
}

.hero-container {
  width: min(100%, 1480px);
  padding: 0 clamp(24px, 4vw, 72px);
}

/* ===== 导航 ===== */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(251, 251, 253, .78);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid rgba(0, 0, 0, .06);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  flex: none;
  font-size: .98rem;
  font-weight: 700;
  color: var(--ink);
  letter-spacing: 0;
  white-space: nowrap;
}

.logo i {
  color: var(--primary);
  font-size: 1.2rem;
}

.logo-icon {
  width: 22px;
  height: 22px;
  flex: none;
  border-radius: 5px;
  object-fit: contain;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  padding: 8px 13px;
  border-radius: 999px;
  color: rgba(29, 29, 31, .76);
  font-size: .9rem;
  transition: background .2s ease, color .2s ease;
}

.nav-links a:hover,
.nav-links a.active {
  background: rgba(0, 102, 204, .09);
  color: var(--primary);
}

.language-menu {
  position: relative;
  display: flex;
  align-items: center;
}

.language-current {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 7px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, .7);
  color: var(--text-muted);
  font: inherit;
  font-size: .88rem;
  cursor: pointer;
}

.language-options {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 136px;
  display: none;
  padding: 6px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: 0 16px 44px rgba(0, 0, 0, .12);
}

.language-options::before {
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  width: 100%;
  height: 9px;
}

.language-menu:hover .language-options,
.language-menu.is-open .language-options {
  display: grid;
  gap: 2px;
}

.language-options a {
  display: block;
  border-radius: 7px;
  padding: 8px 10px;
  white-space: nowrap;
}

.nav-toggle,
.nav-toggle-button {
  display: none;
}

.theme-toggle {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 130;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(255, 255, 255, .78);
  color: var(--ink);
  font: inherit;
  font-size: .86rem;
  font-weight: 650;
  cursor: pointer;
  box-shadow: 0 12px 32px rgba(0, 0, 0, .12);
  backdrop-filter: saturate(180%) blur(18px);
  transition: transform .2s ease, border-color .2s ease, color .2s ease, background .2s ease;
}

.theme-toggle:hover {
  transform: translateY(-1px);
  color: var(--primary);
  border-color: rgba(0, 102, 204, .32);
}

.theme-toggle i {
  font-size: 1rem;
}

/* ===== 首页 ===== */
.hero {
  min-height: 100vh;
  padding: 118px 0 80px;
  display: flex;
  align-items: center;
  background:
    linear-gradient(180deg, #fff 0%, #f5f5f7 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, .65fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: center;
}

.hero-content {
  min-width: 0;
}

.hero-title {
  display: block;
  width: 100%;
  max-width: none;
  white-space: nowrap;
  overflow: visible;
  --hero-title-min-size: 3.25rem;
  font-size: 6.1rem;
  line-height: .96;
  font-weight: 800;
  color: var(--ink);
  margin-bottom: 22px;
  letter-spacing: 0;
}

.hero-title.is-wrapped {
  white-space: normal;
  overflow-wrap: anywhere;
}

.hero-subtitle {
  font-size: clamp(1.35rem, 2vw, 1.85rem);
  line-height: 1.25;
  color: var(--ink);
  font-weight: 650;
  margin-bottom: 12px;
  letter-spacing: 0;
}

.hero-desc {
  font-size: 1.08rem;
  color: var(--text-muted);
  max-width: 530px;
  margin-bottom: 34px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 11px 21px;
  border-radius: 999px;
  font-size: .94rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}

.btn i {
  font-size: 1.05rem;
}

.btn-android,
.btn-ios {
  background: var(--primary);
  color: #fff;
}

.btn-android:hover,
.btn-ios:hover {
  background: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: 0 14px 32px rgba(0, 102, 204, .22);
}

.btn-group {
  color: var(--primary);
  border-color: rgba(0, 102, 204, .32);
  background: rgba(255, 255, 255, .7);
}

.btn-group:hover {
  background: var(--primary);
  color: #fff;
  transform: translateY(-1px);
}

.hero-showcase {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 22px;
  min-width: 0;
  min-height: 540px;
}

.showcase-card {
  width: min(42vw, 250px);
  max-height: 560px;
  overflow: visible;
  border-radius: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
  transition: transform .35s ease, box-shadow .35s ease;
}

.showcase-card:nth-child(1) {
  transform: translateY(28px);
}

.showcase-card:nth-child(2) {
  transform: translateY(-28px);
}

.showcase-card:hover {
  transform: translateY(0) scale(1.02);
}

.showcase-card img {
  width: 100%;
  height: auto;
  border-radius: 0;
  object-fit: contain;
  filter: drop-shadow(0 24px 44px rgba(0, 0, 0, .16));
}

.showcase-placeholder {
  width: min(100%, 360px);
  min-height: 460px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border-radius: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-muted);
  box-shadow: var(--shadow);
}

.showcase-placeholder i {
  font-size: 3rem;
  color: var(--primary);
}

/* ===== 特性区域 ===== */
.features {
  padding: 36px 0 84px;
  background: var(--bg);
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.feature-card {
  min-height: 230px;
  padding: 34px 30px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(0, 0, 0, .04);
  text-align: left;
}

.feature-icon {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 102, 204, .1);
  color: var(--primary);
  font-size: 1.35rem;
  margin-bottom: 22px;
}

.feature-card h3 {
  font-size: 1.32rem;
  line-height: 1.2;
  color: var(--ink);
  margin-bottom: 10px;
  letter-spacing: 0;
}

.feature-card p {
  color: var(--text-muted);
  font-size: .96rem;
}

/* ===== 通用页面 ===== */
.page-shell {
  padding-top: 52px;
  min-height: calc(100vh - 92px);
}

.page-hero {
  background: linear-gradient(180deg, #fff 0%, #f5f5f7 100%);
  padding: 78px 0 48px;
}

.page-hero-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
}

.compact-hero h1 {
  font-size: clamp(2.5rem, 6vw, 5.4rem);
  line-height: 1;
  color: var(--ink);
  letter-spacing: 0;
  margin-bottom: 14px;
}

.compact-hero p {
  max-width: 640px;
  color: var(--text-muted);
  font-size: 1.12rem;
}

.eyebrow {
  color: var(--primary) !important;
  font-size: .9rem !important;
  font-weight: 700;
  margin-bottom: 14px;
}

.language-switcher {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.language-switcher a {
  padding: 8px 13px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .75);
  border: 1px solid rgba(0, 0, 0, .08);
  color: var(--text-muted);
  font-size: .88rem;
}

.language-switcher a.active {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
}

/* ===== 文档页 ===== */
.docs-index {
  padding-top: 42px;
  padding-bottom: 78px;
}

.docs-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.docs-article-card {
  min-height: 176px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 18px;
  align-items: center;
  padding: 26px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(0, 0, 0, .06);
  color: var(--ink);
  transition: transform .2s ease, box-shadow .2s ease, color .2s ease;
}

.docs-article-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .08);
  color: var(--primary);
}

.docs-article-icon {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 102, 204, .1);
  color: var(--primary);
  font-size: 1.35rem;
}

.docs-article-card h2 {
  font-size: 1.22rem;
  line-height: 1.25;
  margin-bottom: 8px;
  letter-spacing: 0;
}

.docs-article-card p {
  color: var(--text-muted);
  font-size: .96rem;
}

.docs-article-card > .bi {
  color: var(--text-muted);
  font-size: 1.4rem;
}

.empty-docs {
  min-height: 260px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text-muted);
}

.empty-docs i {
  color: var(--primary);
  font-size: 2rem;
}

.docs-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 34px;
  padding-top: 42px;
  padding-bottom: 78px;
}

.docs-toc {
  position: sticky;
  top: 76px;
  align-self: start;
  background: var(--surface);
  border: 1px solid rgba(0, 0, 0, .06);
  border-radius: var(--radius);
  padding: 20px;
}

.toc-title {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 700;
  margin-bottom: 14px;
}

.article-list-title {
  margin-top: 4px;
}

.docs-toc nav {
  display: grid;
  gap: 6px;
}

.docs-article-nav {
  margin-bottom: 22px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(0, 0, 0, .08);
}

.docs-toc a,
.docs-toc p {
  color: var(--text-muted);
  font-size: .92rem;
}

.docs-toc a {
  display: block;
  padding: 5px 0;
}

.docs-toc a:hover {
  color: var(--primary);
}

.docs-article-nav a.active {
  color: var(--primary);
  font-weight: 700;
}

.toc-level-3 { padding-left: 14px !important; }
.toc-level-4,
.toc-level-5,
.toc-level-6 { padding-left: 28px !important; }

.doc-content {
  background: var(--surface);
  border: 1px solid rgba(0, 0, 0, .06);
  border-radius: var(--radius);
  padding: clamp(26px, 5vw, 56px);
  color: var(--ink);
}

.doc-content h1,
.doc-content h2,
.doc-content h3,
.doc-content h4,
.doc-content h5,
.doc-content h6 {
  color: var(--ink);
  line-height: 1.2;
  margin: 1.5em 0 .6em;
  letter-spacing: 0;
}

.doc-content h1:first-child,
.doc-content h2:first-child,
.doc-content h3:first-child {
  margin-top: 0;
}

.doc-content h1 { font-size: 2.2rem; }
.doc-content h2 { font-size: 1.68rem; }
.doc-content h3 { font-size: 1.28rem; }

.doc-content p,
.doc-content li {
  color: #3f3f46;
  font-size: 1rem;
}

.doc-content p + p,
.doc-content ul + p,
.doc-content blockquote + p {
  margin-top: 14px;
}

.doc-content ul {
  padding-left: 22px;
  margin: 12px 0 18px;
}

.doc-content a {
  color: var(--primary);
}

.doc-content code {
  padding: 2px 6px;
  border-radius: 6px;
  background: #f2f2f4;
  color: #b42318;
  font-size: .92em;
}

.doc-content pre {
  overflow: auto;
  padding: 18px;
  margin: 18px 0;
  border-radius: var(--radius);
  background: #1d1d1f;
  color: #fff;
}

.doc-content pre code {
  padding: 0;
  background: transparent;
  color: inherit;
}

.doc-content blockquote {
  margin: 18px 0;
  padding: 14px 18px;
  border-left: 4px solid var(--primary);
  background: #f5f5f7;
  color: var(--text-muted);
}

/* ===== 反馈页 ===== */
.feedback-page {
  min-height: 100vh;
  padding: 120px 24px 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    linear-gradient(180deg, rgba(255,255,255,.95), rgba(245,245,247,.96)),
    radial-gradient(circle at 50% 0%, rgba(0, 102, 204, .12), transparent 45%);
}

.feedback-actions {
  width: min(100%, 720px);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.feedback-action {
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border: 1px solid rgba(0, 0, 0, .06);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: 1.32rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .08);
  transition: transform .22s ease, box-shadow .22s ease, color .22s ease;
}

.feedback-action i {
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 102, 204, .1);
  color: var(--primary);
  font-size: 1.6rem;
}

.feedback-action:hover {
  transform: translateY(-3px);
  color: var(--primary);
  box-shadow: 0 26px 72px rgba(0, 0, 0, .12);
}

.submit-action {
  font-family: inherit;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background: rgba(0, 0, 0, .42);
  backdrop-filter: blur(14px);
}

.modal-backdrop[hidden] {
  display: none;
}

.modal-dialog {
  position: relative;
  width: min(100%, 560px);
  max-height: min(720px, 90vh);
  overflow: auto;
  border-radius: var(--radius);
  background: var(--surface);
  padding: 30px;
  box-shadow: 0 24px 90px rgba(0, 0, 0, .24);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: #f2f2f4;
  color: var(--text-muted);
  cursor: pointer;
}

.modal-dialog h2 {
  color: var(--ink);
  margin-bottom: 16px;
  padding-right: 38px;
  letter-spacing: 0;
}

.modal-content {
  color: #3f3f46;
  margin-bottom: 22px;
}

.modal-content a {
  color: var(--primary);
}

.confirm-check {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--ink);
  margin-bottom: 22px;
}

.confirm-check input {
  margin-top: 5px;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.modal-primary,
.modal-secondary {
  min-height: 40px;
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  cursor: pointer;
}

.modal-primary {
  background: var(--primary);
  color: #fff;
}

.modal-primary:disabled {
  background: #c7c7cc;
  cursor: not-allowed;
}

.modal-secondary {
  background: #f2f2f4;
  color: var(--ink);
}

/* ===== 列表页 ===== */
.list-section {
  padding-top: 42px;
  padding-bottom: 78px;
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.upgrade-channel-card {
  border-color: rgba(0, 102, 204, .28);
  background: linear-gradient(145deg, rgba(0, 102, 204, .1), var(--surface));
}

.rights-upgrade-section {
  padding-top: 42px;
  padding-bottom: 78px;
}

.rights-upgrade-form {
  width: min(100%, 720px);
  margin: 0 auto;
  padding: 30px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.form-field {
  display: grid;
  gap: 8px;
  margin-bottom: 20px;
}

.form-field[hidden] {
  display: none;
}

.form-field label {
  color: var(--ink);
  font-weight: 650;
}

.form-field input,
.form-field select {
  width: 100%;
  min-height: 48px;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  color: var(--ink);
  background: var(--surface);
  font: inherit;
}

.form-field input:focus,
.form-field select:focus {
  outline: 3px solid rgba(0, 102, 204, .15);
  border-color: var(--primary);
}

.upgrade-submit {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 22px;
  border: 0;
  border-radius: 999px;
  color: #fff;
  background: var(--primary);
  font: inherit;
  font-weight: 650;
  cursor: pointer;
}

.upgrade-countdown {
  color: var(--text-muted);
  font-size: .92rem;
}

.upgrade-result {
  width: min(100%, 720px);
  margin: 18px auto 0;
  padding: 16px 18px;
  border-radius: 12px;
}

.upgrade-result.success { color: #176b2c; background: rgba(36, 138, 61, .12); }
.upgrade-result.error { color: #b42318; background: rgba(215, 0, 21, .1); }

.channel-card {
  min-height: 190px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  padding: 26px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid rgba(0, 0, 0, .06);
  color: var(--ink);
  transition: transform .2s ease, box-shadow .2s ease, color .2s ease;
}

.channel-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 20px 60px rgba(0, 0, 0, .08);
  color: var(--primary);
}

.channel-icon {
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: rgba(0, 102, 204, .1);
  color: var(--primary);
  font-size: 1.45rem;
  overflow: hidden;
}

.channel-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.channel-body h2 {
  font-size: 1.24rem;
  line-height: 1.25;
  margin-bottom: 8px;
  letter-spacing: 0;
}

.channel-body p {
  color: var(--text-muted);
  font-size: .96rem;
}

.channel-meta {
  margin-bottom: 6px;
  color: var(--primary) !important;
  font-weight: 650;
}

.channel-action {
  grid-column: 2;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: var(--primary);
  font-size: .92rem;
  font-weight: 650;
}

/* ===== 页脚 ===== */
.footer {
  padding: 28px 0;
  text-align: center;
  color: var(--text-muted);
  font-size: .86rem;
  border-top: 1px solid rgba(0, 0, 0, .06);
}

.footer-inner {
  text-align: center;
}

.footer-inner p {
  margin: 0;
}

.footer-inner img {
  display: inline;
  vertical-align: middle;
}

.footer-inner > * + * {
  margin-top: 12px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.footer-links a {
  color: var(--text-muted);
  transition: color .2s;
}

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

/* ===== 夜间主题 ===== */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .navbar {
    background: rgba(22, 22, 23, .78);
    border-bottom-color: rgba(255, 255, 255, .1);
  }

  :root:not([data-theme="light"]) .nav-links a {
    color: rgba(245, 245, 247, .76);
  }

  :root:not([data-theme="light"]) .language-current {
    background: rgba(29, 29, 31, .72);
  }

  :root:not([data-theme="light"]) .language-options {
    box-shadow: 0 18px 50px rgba(0, 0, 0, .42);
  }

  :root:not([data-theme="light"]) .theme-toggle {
    background: rgba(29, 29, 31, .78);
  }

  :root:not([data-theme="light"]) .nav-links a:hover,
  :root:not([data-theme="light"]) .nav-links a.active {
    background: rgba(41, 151, 255, .14);
  }

  :root:not([data-theme="light"]) .hero,
  :root:not([data-theme="light"]) .page-hero {
    background: linear-gradient(180deg, #111113 0%, #000 100%);
  }

  :root:not([data-theme="light"]) .btn-group {
    background: rgba(29, 29, 31, .72);
    border-color: rgba(41, 151, 255, .4);
  }

  :root:not([data-theme="light"]) .features,
  :root:not([data-theme="light"]) .feedback-page {
    background: var(--bg);
  }

  :root:not([data-theme="light"]) .feedback-page {
    background:
      linear-gradient(180deg, rgba(17,17,19,.96), rgba(0,0,0,.96)),
      radial-gradient(circle at 50% 0%, rgba(41, 151, 255, .18), transparent 45%);
  }

  :root:not([data-theme="light"]) .feature-card,
  :root:not([data-theme="light"]) .docs-article-card,
  :root:not([data-theme="light"]) .channel-card,
  :root:not([data-theme="light"]) .empty-docs,
  :root:not([data-theme="light"]) .docs-toc,
  :root:not([data-theme="light"]) .doc-content,
  :root:not([data-theme="light"]) .feedback-action,
  :root:not([data-theme="light"]) .modal-dialog {
    border-color: rgba(255, 255, 255, .1);
  }

  :root:not([data-theme="light"]) .feature-icon,
  :root:not([data-theme="light"]) .docs-article-icon,
  :root:not([data-theme="light"]) .channel-icon,
  :root:not([data-theme="light"]) .feedback-action i {
    background: rgba(41, 151, 255, .14);
  }

  :root:not([data-theme="light"]) .language-switcher a {
    background: rgba(29, 29, 31, .82);
    border-color: rgba(255, 255, 255, .12);
  }

  :root:not([data-theme="light"]) .docs-article-nav {
    border-bottom-color: rgba(255, 255, 255, .12);
  }

  :root:not([data-theme="light"]) .doc-content p,
  :root:not([data-theme="light"]) .doc-content li,
  :root:not([data-theme="light"]) .modal-content {
    color: #d2d2d7;
  }

  :root:not([data-theme="light"]) .doc-content code {
    background: #2c2c2e;
    color: #ffb4a9;
  }

  :root:not([data-theme="light"]) .doc-content pre {
    background: #0f0f10;
  }

  :root:not([data-theme="light"]) .doc-content blockquote {
    background: #161617;
  }

  :root:not([data-theme="light"]) .modal-close,
  :root:not([data-theme="light"]) .modal-secondary {
    background: #2c2c2e;
    color: var(--text);
  }

  :root:not([data-theme="light"]) .modal-primary:disabled {
    background: #3a3a3c;
    color: #8e8e93;
  }

  :root:not([data-theme="light"]) .footer {
    border-top-color: rgba(255, 255, 255, .1);
  }
}

:root[data-theme="dark"] .navbar {
  background: rgba(22, 22, 23, .78);
  border-bottom-color: rgba(255, 255, 255, .1);
}

:root[data-theme="dark"] .nav-links a {
  color: rgba(245, 245, 247, .76);
}

:root[data-theme="dark"] .language-current,
:root[data-theme="dark"] .btn-group {
  background: rgba(29, 29, 31, .72);
}

:root[data-theme="dark"] .language-options {
  box-shadow: 0 18px 50px rgba(0, 0, 0, .42);
}

:root[data-theme="dark"] .theme-toggle {
  background: rgba(29, 29, 31, .78);
}

:root[data-theme="dark"] .nav-links a:hover,
:root[data-theme="dark"] .nav-links a.active {
  background: rgba(41, 151, 255, .14);
}

:root[data-theme="dark"] .hero,
:root[data-theme="dark"] .page-hero {
  background: linear-gradient(180deg, #111113 0%, #000 100%);
}

:root[data-theme="dark"] .btn-group {
  border-color: rgba(41, 151, 255, .4);
}

:root[data-theme="dark"] .features,
:root[data-theme="dark"] .feedback-page {
  background: var(--bg);
}

:root[data-theme="dark"] .feedback-page {
  background:
    linear-gradient(180deg, rgba(17,17,19,.96), rgba(0,0,0,.96)),
    radial-gradient(circle at 50% 0%, rgba(41, 151, 255, .18), transparent 45%);
}

:root[data-theme="dark"] .feature-card,
:root[data-theme="dark"] .docs-article-card,
:root[data-theme="dark"] .channel-card,
:root[data-theme="dark"] .empty-docs,
:root[data-theme="dark"] .docs-toc,
:root[data-theme="dark"] .doc-content,
:root[data-theme="dark"] .feedback-action,
:root[data-theme="dark"] .modal-dialog {
  border-color: rgba(255, 255, 255, .1);
}

:root[data-theme="dark"] .feature-icon,
:root[data-theme="dark"] .docs-article-icon,
:root[data-theme="dark"] .channel-icon,
:root[data-theme="dark"] .feedback-action i {
  background: rgba(41, 151, 255, .14);
}

:root[data-theme="dark"] .language-switcher a {
  background: rgba(29, 29, 31, .82);
  border-color: rgba(255, 255, 255, .12);
}

:root[data-theme="dark"] .docs-article-nav,
:root[data-theme="dark"] .footer {
  border-top-color: rgba(255, 255, 255, .1);
}

:root[data-theme="dark"] .docs-article-nav {
  border-bottom-color: rgba(255, 255, 255, .12);
}

:root[data-theme="dark"] .doc-content p,
:root[data-theme="dark"] .doc-content li,
:root[data-theme="dark"] .modal-content {
  color: #d2d2d7;
}

:root[data-theme="dark"] .doc-content code {
  background: #2c2c2e;
  color: #ffb4a9;
}

:root[data-theme="dark"] .doc-content pre {
  background: #0f0f10;
}

:root[data-theme="dark"] .doc-content blockquote {
  background: #161617;
}

:root[data-theme="dark"] .modal-close,
:root[data-theme="dark"] .modal-secondary {
  background: #2c2c2e;
  color: var(--text);
}

:root[data-theme="dark"] .modal-primary:disabled {
  background: #3a3a3c;
  color: #8e8e93;
}

/* ===== 响应式 ===== */
@media (max-width: 920px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 34px;
    text-align: center;
  }

  .hero-desc {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-title {
    width: auto;
    white-space: normal;
  }

  .hero-buttons,
  .hero-showcase {
    justify-content: center;
  }

  .hero-showcase {
    min-height: auto;
  }

  .features-grid,
  .docs-card-grid,
  .channel-grid,
  .docs-layout {
    grid-template-columns: 1fr;
  }

  .docs-toc {
    position: static;
  }

  .page-hero-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .language-switcher {
    justify-content: flex-start;
  }
}

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

  .nav-inner {
    min-height: 54px;
  }

  .nav-toggle-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: var(--ink);
    cursor: pointer;
  }

  .nav-links {
    position: absolute;
    top: 54px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px 18px 16px;
    background: rgba(251, 251, 253, .96);
    border-bottom: 1px solid rgba(0, 0, 0, .06);
  }

  @media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .nav-links {
      background: rgba(22, 22, 23, .96);
      border-bottom-color: rgba(255, 255, 255, .1);
    }
  }

  :root[data-theme="dark"] .nav-links {
    background: rgba(22, 22, 23, .96);
    border-bottom-color: rgba(255, 255, 255, .1);
  }

  .nav-toggle:checked ~ .nav-links {
    display: flex;
  }

  .nav-links a {
    border-radius: var(--radius);
    padding: 12px 10px;
  }

  .language-menu {
    display: block;
  }

  .language-current {
    display: none;
  }

  .language-options {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    min-width: 0;
    box-shadow: none;
    background: transparent;
    border: 0;
    padding: 8px 0 0;
  }

  .hero {
    padding: 104px 0 56px;
    min-height: auto;
  }

  .hero-title {
    font-size: clamp(2.7rem, 16vw, 4rem);
  }

  .hero-buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .btn {
    width: 100%;
  }

  .hero-showcase {
    gap: 10px;
  }

  .showcase-card {
    width: min(46vw, 180px);
  }

  .showcase-card:nth-child(1),
  .showcase-card:nth-child(2) {
    transform: none;
  }

  .features {
    padding: 20px 0 56px;
  }

  .features-grid {
    gap: 12px;
  }

  .feature-card {
    min-height: auto;
    padding: 26px 22px;
  }

  .page-hero {
    padding: 58px 0 34px;
  }

  .docs-layout {
    padding-top: 24px;
    padding-bottom: 48px;
  }

  .docs-index {
    padding-top: 24px;
    padding-bottom: 48px;
  }

  .list-section {
    padding-top: 24px;
    padding-bottom: 48px;
  }

  .doc-content {
    padding: 24px 20px;
  }

  .docs-article-card {
    grid-template-columns: 1fr auto;
  }

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

  .channel-action {
    grid-column: auto;
  }

  .docs-article-icon {
    display: none;
  }

  .doc-content h1 { font-size: 1.84rem; }
  .doc-content h2 { font-size: 1.42rem; }

  .feedback-page {
    padding: 94px 18px 54px;
  }

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

  .feedback-action {
    min-height: 156px;
  }

  .modal-dialog {
    padding: 26px 20px;
  }
}
