:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --bg-line: #e6ebf2;
  --text: #172033;
  --muted: #5b667a;
  --primary: #165dff;
  --primary-strong: #0f43b8;
  --green: #078b6f;
  --amber: #c97900;
  --cyan: #007d9c;
  --red: #c24747;
  --purple: #6a55b8;
  --surface: #ffffff;
  --shadow: 0 20px 60px rgba(23, 32, 51, 0.12);
  --radius: 8px;
  --container: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  text-rendering: optimizeLegibility;
}

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

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

button,
input {
  font: inherit;
}

.container {
  width: min(100% - 40px, var(--container));
  margin: 0 auto;
}

.narrow {
  width: min(100% - 40px, 860px);
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 1000;
  padding: 10px 14px;
  color: #fff;
  background: var(--primary);
  border-radius: var(--radius);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid rgba(230, 235, 242, 0.92);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  min-height: 76px;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 210px;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  color: #fff;
  background: var(--text);
  border-radius: 8px;
  font-weight: 800;
}

.brand strong,
.brand em {
  display: block;
  line-height: 1.2;
}

.brand strong {
  font-size: 18px;
  letter-spacing: 0;
}

.brand em {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
}

.site-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 4px;
}

.site-nav a {
  padding: 10px 14px;
  color: var(--muted);
  border-radius: var(--radius);
  font-size: 15px;
}

.site-nav a:hover,
.site-nav a.is-active {
  color: var(--primary);
  background: #eef4ff;
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 4px auto;
  background: var(--text);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  font-weight: 700;
  line-height: 1.25;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #fff;
  background: var(--primary);
  box-shadow: 0 12px 24px rgba(22, 93, 255, .18);
}

.btn-primary:hover {
  background: var(--primary-strong);
}

.btn-secondary {
  color: var(--primary);
  background: #eef4ff;
  border-color: #d7e4ff;
}

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

.btn-outline-light {
  color: #fff;
  border-color: rgba(255, 255, 255, .5);
}

.btn-large {
  min-height: 50px;
  padding: 13px 22px;
  font-size: 16px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  color: var(--primary);
  font-weight: 700;
}

.text-link::after {
  content: "→";
  margin-left: 6px;
}

.hero {
  padding: 88px 0 54px;
  background: linear-gradient(180deg, #f8fbff 0%, #fff 100%);
  border-bottom: 1px solid var(--bg-line);
}

.hero-grid,
.page-hero-grid,
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.78fr);
  align-items: center;
  gap: 48px;
}

.hero-copy {
  max-width: 680px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--green);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 22px;
  font-size: clamp(42px, 7vw, 72px);
  line-height: 1.04;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.hero-title-line {
  display: block;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.16;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.28;
  letter-spacing: 0;
}

.hero-lede,
.page-hero p,
.section-head p,
.section-intro {
  color: var(--muted);
  font-size: 18px;
}

.hero-actions,
.cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 36px 0 0;
}

.hero-stats div {
  padding: 18px;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.hero-stats dt {
  color: var(--text);
  font-size: 28px;
  font-weight: 900;
}

.hero-stats dd {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 14px;
}

.hero-media img {
  width: 100%;
  border: 1px solid #dfe6f0;
  box-shadow: var(--shadow);
}

.section {
  padding: 84px 0;
}

.section-tight {
  padding: 22px 0 0;
}

.section-alt {
  background: var(--bg-soft);
}

.section-head {
  max-width: 780px;
  margin-bottom: 36px;
}

.source-note {
  display: flex;
  gap: 12px;
  padding: 16px 18px;
  color: var(--muted);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.source-note strong {
  color: var(--text);
  white-space: nowrap;
}

.feature-grid,
.article-grid,
.tutorial-grid,
.edition-grid,
.download-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.feature-card,
.edition-card,
.download-card,
.tutorial-card,
.article-card,
.scenario-list article,
.steps article,
.timeline article,
.news-feature,
.download-summary,
.compare-table,
.source-cards,
.support-aside,
.faq-item {
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: var(--surface);
}

.feature-card,
.edition-card,
.download-card,
.tutorial-card,
.article-card,
.scenario-list article,
.steps article,
.timeline article {
  padding: 24px;
}

.feature-card p,
.edition-card p,
.download-card p,
.tutorial-card p,
.article-card p,
.scenario-list p,
.steps p,
.timeline p {
  color: var(--muted);
  margin-bottom: 0;
}

.icon {
  display: inline-grid;
  place-items: center;
  width: 54px;
  height: 36px;
  margin-bottom: 18px;
  color: #fff;
  background: var(--primary);
  border-radius: 7px;
  font-size: 13px;
  font-weight: 900;
}

.icon-green { background: var(--green); }
.icon-amber { background: var(--amber); }
.icon-cyan { background: var(--cyan); }
.icon-red { background: var(--red); }
.icon-purple { background: var(--purple); }

.scenario-list {
  display: grid;
  gap: 16px;
}

.edition-grid,
.download-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.edition-title,
.download-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 14px;
}

.edition-title span,
.download-card-head span,
.article-card span,
.news-tag,
.tutorial-card span {
  display: inline-flex;
  min-height: 28px;
  align-items: center;
  padding: 4px 10px;
  color: var(--green);
  background: #e8f6f2;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
}

.edition-card .btn,
.download-card .btn {
  margin-top: 22px;
}

.section-cta {
  padding-top: 0;
}

.cta-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 38px;
  color: #fff;
  background: #123a7a;
  border-radius: var(--radius);
}

.cta-band p {
  color: rgba(255, 255, 255, .78);
  margin-bottom: 0;
}

.cta-band .eyebrow {
  color: #85e0c5;
}

.page-hero {
  padding: 70px 0;
  background: var(--bg-soft);
  border-bottom: 1px solid var(--bg-line);
}

.download-summary {
  padding: 30px;
}

.download-summary span,
.download-summary small {
  display: block;
  color: var(--muted);
}

.download-summary strong {
  display: block;
  margin: 8px 0;
  color: var(--primary);
  font-size: 58px;
  line-height: 1;
}

.check-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 24px;
  color: var(--muted);
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  width: 10px;
  height: 10px;
  background: var(--green);
  border-radius: 50%;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.steps span,
.timeline span {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  margin-bottom: 18px;
  color: #fff;
  background: var(--text);
  border-radius: 50%;
  font-weight: 900;
}

.compare-table {
  overflow: hidden;
}

.compare-table div {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 16px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--bg-line);
}

.compare-table div:last-child {
  border-bottom: 0;
}

.compare-table strong {
  color: var(--text);
}

.compare-table span {
  color: var(--muted);
}

.support-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.support-aside {
  position: sticky;
  top: 98px;
  padding: 22px;
}

.support-aside h2,
.news-side h2 {
  font-size: 20px;
}

.support-aside a,
.news-side a,
.footer-grid a {
  display: flex;
  color: var(--muted);
  padding: 7px 0;
}

.support-aside a:hover,
.news-side a:hover,
.footer-grid a:hover {
  color: var(--primary);
}

.faq-list {
  display: grid;
  gap: 14px;
}

.faq-item {
  overflow: hidden;
}

.faq-item button {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 20px 22px;
  color: var(--text);
  border: 0;
  background: transparent;
  cursor: pointer;
  font-weight: 800;
  text-align: left;
}

.faq-item button span:last-child {
  color: var(--primary);
  font-size: 24px;
}

.faq-content {
  display: none;
  padding: 0 22px 22px;
  color: var(--muted);
}

.faq-item.is-open .faq-content {
  display: block;
}

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

.doc-search {
  display: block;
  padding: 24px;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.doc-search span {
  display: block;
  margin-bottom: 10px;
  color: var(--muted);
  font-weight: 700;
}

.doc-search input {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  color: var(--text);
  border: 1px solid #d6deea;
  border-radius: var(--radius);
  outline: 0;
}

.doc-search input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(22, 93, 255, .12);
}

.tutorial-card ol {
  margin: 18px 0 0;
  padding-left: 20px;
  color: var(--muted);
}

.empty-state {
  padding: 18px;
  color: var(--muted);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.timeline {
  display: grid;
  gap: 16px;
}

.news-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 28px;
  align-items: stretch;
}

.news-feature {
  padding: 34px;
}

.news-feature time,
.article-card time {
  display: block;
  margin: 14px 0 10px;
  color: var(--muted);
}

.news-feature h2 {
  max-width: 760px;
}

.news-feature p {
  max-width: 820px;
  color: var(--muted);
}

.news-side {
  padding: 24px;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
}

.source-cards {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 16px;
  align-items: stretch;
  padding: 24px;
}

.source-cards article {
  min-width: 0;
}

.source-cards a {
  display: grid;
  place-items: center;
  min-height: 96px;
  color: var(--primary);
  background: #eef4ff;
  border-radius: var(--radius);
  font-weight: 800;
  text-align: center;
}

.site-footer {
  padding: 56px 0 22px;
  color: rgba(255, 255, 255, .76);
  background: #101827;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 42px;
}

.brand-footer .brand-mark {
  background: #fff;
  color: #101827;
}

.brand-footer strong {
  color: #fff;
}

.brand-footer em,
.footer-grid p,
.footer-grid a {
  color: rgba(255, 255, 255, .72);
}

.footer-grid h2 {
  color: #fff;
  font-size: 17px;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, .12);
  font-size: 14px;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.modal.is-open {
  display: flex;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 16, 28, .56);
}

.modal-panel {
  position: relative;
  width: min(100%, 720px);
  max-width: calc(100vw - 48px);
  max-height: min(92vh, 760px);
  overflow: auto;
  padding: 32px;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.modal-close {
  position: absolute;
  right: 18px;
  top: 18px;
  width: 40px;
  height: 40px;
  color: var(--text);
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  background: #fff;
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
}

.modal-copy {
  color: var(--muted);
}

.modal-panel h2 {
  padding-right: 46px;
  overflow-wrap: anywhere;
}

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

.qr-card {
  padding: 20px;
  border: 1px solid var(--bg-line);
  border-radius: var(--radius);
  text-align: center;
}

.qr-card img {
  width: 196px;
  height: 196px;
  margin: 0 auto 16px;
  border: 1px solid var(--bg-line);
}

.qr-card p {
  color: var(--muted);
}

.modal-official {
  margin-top: 20px;
}

body.modal-open {
  overflow: hidden;
}

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

  .nav-toggle {
    display: block;
    order: 3;
    justify-self: end;
  }

  .site-nav {
    position: absolute;
    left: 20px;
    right: 20px;
    top: 76px;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border: 1px solid var(--bg-line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow);
  }

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

  .header-inner > .btn {
    justify-self: end;
  }

  .hero-grid,
  .page-hero-grid,
  .split,
  .news-layout,
  .support-layout {
    grid-template-columns: 1fr;
  }

  .support-aside {
    position: static;
  }

  .feature-grid,
  .article-grid,
  .tutorial-grid,
  .support-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .source-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 720px) {
  .container,
  .narrow {
    width: min(100% - 28px, var(--container));
  }

  .header-inner {
    min-height: 68px;
    gap: 10px;
  }

  .brand {
    min-width: 0;
  }

  .brand strong {
    font-size: 16px;
  }

  .brand em {
    display: none;
  }

  .brand-mark {
    width: 38px;
    height: 38px;
  }

  .header-inner > .btn {
    display: none;
  }

  .site-nav {
    top: 68px;
    left: 14px;
    right: 14px;
  }

  .hero,
  .page-hero {
    padding: 52px 0 40px;
  }

  h1 {
    font-size: 38px;
    line-height: 1.08;
    word-break: break-word;
  }

  .hero-lede,
  .page-hero p,
  .section-head p,
  .section-intro {
    font-size: 16px;
  }

  .section {
    padding: 58px 0;
  }

  .feature-grid,
  .article-grid,
  .tutorial-grid,
  .edition-grid,
  .download-grid,
  .steps,
  .qr-grid {
    grid-template-columns: 1fr;
  }

  .hero-stats {
    grid-template-columns: 1fr;
  }

  .cta-band,
  .source-note,
  .footer-bottom {
    display: block;
  }

  .cta-band {
    padding: 28px;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .compare-table div {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .source-cards {
    grid-template-columns: 1fr;
  }

  .modal-panel {
    width: 100%;
    max-width: calc(100vw - 28px);
    max-height: calc(100vh - 28px);
    overflow-x: hidden;
    padding: 26px 18px;
  }

  .modal-panel h2 {
    padding-right: 38px;
    font-size: 26px;
    line-height: 1.18;
  }

  .modal-close {
    right: 12px;
    top: 12px;
    width: 36px;
    height: 36px;
  }

  .qr-card img {
    width: min(196px, 100%);
    height: auto;
  }
}
