:root {
  color-scheme: light;
  --bg: #f7f8fb;
  --surface: #ffffff;
  --surface-muted: #eef4f1;
  --text: #17201c;
  --muted: #61716b;
  --line: #dce5e1;
  --accent: #0b7a5b;
  --accent-strong: #07533f;
  --amber: #d28b23;
  --ink: #101815;
  --shadow: 0 18px 42px rgba(24, 48, 41, 0.1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  line-height: 1.7;
}

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

a:hover {
  color: var(--accent-strong);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 32px;
  border-bottom: 1px solid rgba(220, 229, 225, 0.9);
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: var(--ink);
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: #f4efff;
  border: 1px solid rgba(134, 59, 255, 0.16);
}

.brand-mark img {
  display: block;
  width: 30px;
  height: 30px;
  object-fit: contain;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  line-height: 1.2;
}

.brand small {
  margin-top: -4px;
  color: var(--muted);
  font-size: 12px;
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
}

.top-nav a {
  white-space: nowrap;
}

.main-site-link,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  font-weight: 700;
}

.main-site-link,
.button.primary {
  background: var(--accent);
  color: #fff;
}

.button.secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.85);
  color: var(--text);
}

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

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

.hero {
  min-height: 520px;
  display: flex;
  align-items: center;
  padding: 72px 32px;
  background:
    linear-gradient(90deg, rgba(10, 18, 16, 0.82), rgba(10, 18, 16, 0.54)),
    url("https://images.unsplash.com/photo-1642790551116-18e150f248e9?auto=format&fit=crop&w=1800&q=80");
  background-position: center;
  background-size: cover;
  color: #fff;
}

.hero-content {
  width: min(920px, 100%);
  margin: 0 auto;
}

.eyebrow {
  margin: 0 0 10px;
  color: #b7ead7;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(42px, 8vw, 88px);
  line-height: 1.04;
  letter-spacing: 0;
}

.hero-lede {
  max-width: 680px;
  margin: 24px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: clamp(18px, 2.2vw, 23px);
}

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

.section {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
  padding: 56px 0;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 42px;
  align-items: start;
}

.intro > div {
  font-size: 19px;
}

.callout,
.pager-link {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.callout {
  padding: 24px;
}

.callout strong {
  color: var(--accent-strong);
}

.docs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
  padding-top: 0;
}

.doc-card {
  min-height: 260px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow);
}

.doc-card span {
  color: var(--amber);
  font-weight: 900;
}

.doc-card h2 {
  margin: 42px 0 10px;
  font-size: 22px;
  line-height: 1.25;
}

.doc-card p {
  margin: 0;
  color: var(--muted);
}

.docs-shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 760px);
  gap: 56px;
  width: min(1180px, calc(100% - 48px));
  margin: 0 auto;
  padding: 48px 0 72px;
}

.docs-sidebar {
  position: sticky;
  top: 96px;
  align-self: start;
  max-height: calc(100vh - 120px);
  overflow: auto;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.docs-sidebar p {
  margin: 18px 0 8px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.docs-sidebar p:first-child {
  margin-top: 0;
}

.docs-sidebar a {
  display: block;
  position: relative;
  margin: 1px 0;
  padding: 8px 10px 8px 12px;
  border-radius: 7px;
  color: var(--text);
  font-size: 14px;
}

.docs-sidebar a:hover {
  background: var(--surface-muted);
  color: var(--accent-strong);
}

.docs-sidebar a.is-active {
  border: 1px solid rgba(11, 122, 91, 0.22);
  background: #dff1eb;
  color: var(--accent-strong);
  font-weight: 800;
}

.docs-sidebar a.is-active::before {
  position: absolute;
  top: 9px;
  bottom: 9px;
  left: 0;
  width: 3px;
  border-radius: 999px;
  background: var(--accent);
  content: "";
}

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

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 14px;
}

.docs-content h1 {
  margin: 14px 0 12px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.08;
}

.page-description {
  margin: 0 0 34px;
  color: var(--muted);
  font-size: 20px;
}

.docs-content h2 {
  margin-top: 38px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 26px;
  line-height: 1.3;
}

.docs-content h3 {
  margin-top: 30px;
  font-size: 20px;
}

.docs-content p,
.docs-content li {
  color: #2a3934;
  font-size: 17px;
}

.docs-content code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-muted);
  color: var(--accent-strong);
}

.doc-pager {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 64px;
}

.pager-link {
  display: flex;
  flex: 1 1 260px;
  min-height: 58px;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-color: rgba(11, 122, 91, 0.22);
  background: linear-gradient(180deg, #ffffff, #f8fbfa);
  color: var(--accent-strong);
  box-shadow: 0 10px 26px rgba(24, 48, 41, 0.08);
  transition: border-color 160ms ease, background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.pager-link:hover {
  border-color: rgba(11, 122, 91, 0.34);
  background: #fff;
  box-shadow: 0 16px 32px rgba(24, 48, 41, 0.12);
  color: var(--accent-strong);
  transform: translateY(-1px);
}

.pager-copy {
  display: flex;
  min-width: 0;
  align-items: baseline;
  gap: 4px;
}

.pager-kicker,
.reference-link span {
  display: inline;
  color: var(--muted);
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
}

.pager-link strong {
  display: inline;
  min-width: 0;
  color: var(--accent-strong);
  font-size: 17px;
  line-height: 1.3;
}

.pager-direction {
  display: grid;
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  place-items: center;
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--accent-strong);
  font-size: 16px;
  font-weight: 800;
  line-height: 1;
}

.pager-link.next {
  justify-content: flex-end;
}

.pager-link.is-empty {
  display: none;
}

.reference-link {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}

.reference-link a {
  font-weight: 700;
}

.site-footer {
  padding: 40px 32px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: #fbfcfd;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  width: min(1180px, 100%);
  margin: 0 auto;
}

.footer-title {
  display: inline-block;
  color: var(--ink);
  font-size: 18px;
  font-weight: 900;
}

.footer-brand p {
  max-width: 760px;
  margin: 14px 0 0;
  font-size: 14px;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 18px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
}

.footer-links section {
  min-width: 0;
}

.footer-links h2 {
  margin: 0 0 12px;
  color: var(--text);
  font-size: 13px;
  line-height: 1.3;
}

.footer-links a {
  display: block;
  min-height: 30px;
  padding: 4px 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

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

.site-footer p {
  margin: 0;
}

@media (max-width: 920px) {
  .site-header {
    padding: 0 24px;
  }

  .nav-toggle {
    display: block;
    flex: 0 0 auto;
  }

  .top-nav {
    position: absolute;
    top: 72px;
    right: 16px;
    left: 16px;
    display: none;
    padding: 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #fff;
    box-shadow: var(--shadow);
  }

  .top-nav.is-open {
    display: grid;
    gap: 12px;
  }

  .top-nav a {
    display: flex;
    min-height: 42px;
    align-items: center;
  }

  .intro,
  .docs-shell {
    grid-template-columns: 1fr;
  }

  .docs-sidebar {
    position: static;
    max-height: none;
  }

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

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

}

@media (max-width: 620px) {
  .site-header {
    min-height: 64px;
    padding: 0 16px;
  }

  .brand {
    gap: 10px;
    max-width: calc(100% - 54px);
  }

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

  .brand-mark img {
    width: 27px;
    height: 27px;
  }

  .brand strong {
    max-width: 11em;
    font-size: 15px;
    line-height: 1.25;
  }

  .brand small {
    display: none;
  }

  .nav-toggle {
    width: 40px;
    height: 40px;
  }

  .top-nav {
    top: 64px;
    right: 12px;
    left: 12px;
    max-height: calc(100vh - 84px);
    overflow: auto;
  }

  .hero {
    min-height: 430px;
    padding: 48px 22px;
    background-position: 62% center;
  }

  .eyebrow {
    font-size: 12px;
  }

  .hero h1 {
    font-size: 36px;
    line-height: 1.12;
  }

  .hero-lede {
    margin-top: 18px;
    font-size: 17px;
  }

  .hero-actions {
    display: grid;
    margin-top: 26px;
  }

  .button {
    width: 100%;
    min-height: 46px;
  }

  .section,
  .docs-shell {
    width: min(100% - 28px, 1120px);
  }

  .section {
    padding: 40px 0;
  }

  .intro {
    gap: 24px;
  }

  .intro > div {
    font-size: 17px;
  }

  .callout {
    padding: 20px;
  }

  .doc-card {
    min-height: 0;
    padding: 20px;
  }

  .doc-card h2 {
    margin-top: 28px;
    font-size: 20px;
  }

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

  .docs-shell {
    gap: 28px;
    padding: 28px 0 52px;
  }

  .docs-sidebar {
    max-height: 260px;
    padding: 16px;
    overflow: auto;
  }

  .docs-sidebar nav {
    grid-template-columns: 1fr;
  }

  .docs-sidebar p {
    margin: 16px 0 6px;
    font-size: 11px;
  }

  .docs-sidebar a {
    min-height: 34px;
    padding: 7px 10px 7px 12px;
    font-size: 14px;
  }

  .breadcrumbs {
    font-size: 13px;
  }

  .docs-content h1 {
    margin-top: 12px;
    font-size: 32px;
    line-height: 1.14;
  }

  .page-description {
    margin-bottom: 26px;
    font-size: 17px;
  }

  .docs-content h2 {
    margin-top: 32px;
    padding-top: 16px;
    font-size: 23px;
  }

  .docs-content h3 {
    font-size: 19px;
  }

  .docs-content p,
  .docs-content li {
    font-size: 16px;
  }

  .docs-content ul,
  .docs-content ol {
    padding-left: 22px;
  }

  .site-footer {
    padding: 34px 16px;
  }

  .footer-inner {
    gap: 24px;
  }

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

  .footer-links a {
    min-height: 32px;
  }

  .doc-pager {
    gap: 12px;
    margin-top: 48px;
  }

  .pager-link {
    flex-basis: 100%;
    min-height: 54px;
    padding: 13px 14px;
  }

  .pager-link.next {
    justify-content: space-between;
  }

  .pager-copy {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .pager-link.next .pager-copy {
    order: 1;
  }

  .pager-link.next .pager-direction {
    order: 2;
  }

  .pager-kicker {
    font-size: 12px;
  }

  .pager-link strong {
    font-size: 16px;
  }

  .reference-link {
    align-items: flex-start;
    flex-direction: column;
    gap: 6px;
    font-size: 14px;
  }
}

@media (max-width: 380px) {
  .brand strong {
    max-width: 9.5em;
    font-size: 14px;
  }

  .hero h1,
  .docs-content h1 {
    font-size: 30px;
  }

  .docs-content h2 {
    font-size: 21px;
  }
}
