:root {
  color-scheme: light;
  --docs-bg: #f6f8fc;
  --docs-paper: #ffffff;
  --docs-ink: #0a1c3e;
  --docs-muted: #65708a;
  --docs-line: #dfe6f3;
  --docs-blue: #2157e6;
  --docs-blue-dark: #133da8;
  --docs-code: #0c1730;
  --docs-code-muted: #9fb0cf;
  --docs-green: #0f8a59;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 86px;
}

body {
  margin: 0;
  background: var(--docs-bg);
  color: var(--docs-ink);
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

.api-docs-topbar {
  position: sticky;
  z-index: 20;
  top: 0;
  display: flex;
  height: 70px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: 1px solid rgba(214, 224, 241, .9);
  padding: 0 clamp(18px, 4vw, 54px);
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(18px);
}

.api-docs-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
}

.api-docs-brand img {
  width: 42px;
  height: 42px;
  border: 1px solid var(--docs-line);
  border-radius: 12px;
  background: #fff;
  object-fit: contain;
}

.api-docs-brand span {
  display: grid;
  gap: 1px;
}

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

.api-docs-brand small {
  color: var(--docs-muted);
  font-size: 12px;
}

.api-docs-top-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.api-docs-version {
  border-radius: 999px;
  padding: 6px 10px;
  background: #eef3ff;
  color: var(--docs-blue-dark);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
}

.api-docs-top-actions a,
.api-docs-footer a {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  padding: 0 15px;
  background: var(--docs-blue);
  color: #fff;
  font-size: 13px;
  font-weight: 750;
  text-decoration: none;
}

.api-docs-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  width: min(1440px, 100%);
  margin: 0 auto;
}

.api-docs-sidebar {
  position: sticky;
  top: 70px;
  align-self: start;
  height: calc(100vh - 70px);
  overflow-y: auto;
  border-right: 1px solid var(--docs-line);
  padding: 30px 28px 50px;
  background: #fbfcff;
}

.api-docs-sidebar p {
  margin: 22px 0 8px;
  color: #9aa5b9;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .12em;
}

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

.api-docs-sidebar nav {
  display: grid;
  gap: 2px;
}

.api-docs-sidebar a {
  display: flex;
  min-height: 36px;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  padding: 7px 9px;
  color: #43506b;
  font-size: 13px;
  text-decoration: none;
}

.api-docs-sidebar a:hover,
.api-docs-sidebar a.is-active {
  background: #edf3ff;
  color: var(--docs-blue-dark);
}

.api-docs-sidebar a code {
  color: var(--docs-blue);
  font-size: 9px;
  font-weight: 850;
}

.api-docs-main {
  min-width: 0;
  padding: 56px clamp(28px, 6vw, 92px) 90px;
  background: var(--docs-paper);
}

.api-docs-intro {
  max-width: 900px;
  padding: 38px 0 68px;
}

.api-docs-eyebrow {
  margin: 0 0 14px;
  color: var(--docs-blue);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .16em;
}

.api-docs-intro h1 {
  max-width: 780px;
  margin: 0;
  font-size: clamp(38px, 5.3vw, 66px);
  letter-spacing: -.045em;
  line-height: 1.08;
}

.api-docs-intro > p:not(.api-docs-eyebrow) {
  max-width: 760px;
  margin: 24px 0 0;
  color: var(--docs-muted);
  font-size: clamp(16px, 2vw, 19px);
  line-height: 1.8;
}

.api-docs-base {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  max-width: 760px;
  margin-top: 32px;
  border: 1px solid var(--docs-line);
  border-radius: 14px;
  padding: 12px 13px 12px 16px;
  background: #fafcff;
}

.api-docs-base span {
  color: var(--docs-muted);
  font-size: 12px;
  font-weight: 750;
}

.api-docs-base code {
  min-width: 0;
  color: var(--docs-blue-dark);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.api-docs-base button,
.api-docs-code button {
  min-height: 34px;
  border: 1px solid var(--docs-line);
  border-radius: 8px;
  padding: 0 11px;
  background: #fff;
  color: var(--docs-blue-dark);
  cursor: pointer;
  font-size: 12px;
  font-weight: 750;
}

.api-docs-section,
.api-docs-endpoint {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 22px;
  max-width: 980px;
  border-top: 1px solid var(--docs-line);
  padding: 60px 0;
}

.api-docs-section-number {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 12px;
  background: #edf3ff;
  color: var(--docs-blue);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 850;
}

.api-docs-section h2,
.api-docs-endpoint h2 {
  margin: 0 0 14px;
  font-size: clamp(28px, 3.4vw, 38px);
  letter-spacing: -.025em;
}

.api-docs-section h3,
.api-docs-endpoint h3 {
  margin: 34px 0 10px;
  font-size: 19px;
}

.api-docs-section p,
.api-docs-endpoint > p,
.api-docs-endpoint > div + p {
  color: var(--docs-muted);
  line-height: 1.8;
}

.api-docs-section code,
.api-docs-endpoint code {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
}

.api-docs-steps {
  display: grid;
  gap: 0;
  margin: 28px 0 0;
  padding: 0;
  list-style: none;
  counter-reset: docs-step;
}

.api-docs-steps li {
  position: relative;
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 18px;
  border-top: 1px solid var(--docs-line);
  padding: 17px 0 17px 42px;
  counter-increment: docs-step;
}

.api-docs-steps li::before {
  position: absolute;
  top: 17px;
  left: 2px;
  color: var(--docs-blue);
  content: "0" counter(docs-step);
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  font-weight: 850;
}

.api-docs-steps span {
  color: var(--docs-muted);
  line-height: 1.65;
}

.api-docs-callout {
  margin-top: 24px;
  border-left: 3px solid var(--docs-blue);
  border-radius: 0 10px 10px 0;
  padding: 15px 17px;
  background: #f1f5ff;
  color: #3e4f72;
  line-height: 1.7;
}

.api-docs-callout.is-warning {
  border-left-color: #d49220;
  background: #fff8e9;
}

.api-docs-table-wrap {
  max-width: 100%;
  margin-top: 22px;
  overflow-x: auto;
  border: 1px solid var(--docs-line);
  border-radius: 12px;
}

.api-docs-table-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.api-docs-table-wrap th,
.api-docs-table-wrap td {
  min-width: 110px;
  border-bottom: 1px solid var(--docs-line);
  padding: 13px 15px;
  text-align: left;
  vertical-align: top;
}

.api-docs-table-wrap tr:last-child td {
  border-bottom: 0;
}

.api-docs-table-wrap th {
  background: #f8faff;
  color: #4f5b72;
  font-size: 12px;
}

.api-docs-table-wrap td {
  color: var(--docs-muted);
  line-height: 1.6;
}

.api-docs-table-wrap td code {
  color: var(--docs-blue-dark);
}

.api-docs-code {
  max-width: 100%;
  margin-top: 20px;
  overflow: hidden;
  border: 1px solid #1d2c4d;
  border-radius: 13px;
  background: var(--docs-code);
}

.api-docs-code > div {
  display: flex;
  min-height: 44px;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  border-bottom: 1px solid #243453;
  padding: 0 12px 0 16px;
  color: var(--docs-code-muted);
  font-size: 12px;
}

.api-docs-code button {
  border-color: #304466;
  background: #152442;
  color: #dce7ff;
}

.api-docs-code pre {
  margin: 0;
  overflow-x: auto;
  padding: 19px;
  color: #dce7ff;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  line-height: 1.75;
  tab-size: 2;
}

.api-docs-code code {
  font-family: inherit;
}

.api-docs-inline-value {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border: 1px solid var(--docs-line);
  border-radius: 10px;
  padding: 13px;
  background: #f8faff;
  color: var(--docs-blue-dark);
  white-space: nowrap;
}

.api-docs-endpoint {
  display: block;
  max-width: 980px;
}

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

.api-docs-endpoint-head > span {
  min-width: 48px;
  border-radius: 7px;
  padding: 6px 8px;
  color: #fff;
  font-size: 10px;
  font-weight: 900;
  text-align: center;
}

.api-docs-endpoint-head .is-get {
  background: var(--docs-green);
}

.api-docs-endpoint-head .is-post {
  background: var(--docs-blue);
}

.api-docs-endpoint-head > code {
  color: var(--docs-ink);
  font-size: clamp(15px, 2vw, 18px);
  font-weight: 800;
  overflow-wrap: anywhere;
}

.api-docs-endpoint-head > strong {
  margin-left: auto;
  color: var(--docs-muted);
  font-size: 13px;
}

.api-docs-response-grid {
  display: grid;
  grid-template-columns: minmax(180px, .45fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.api-docs-response-grid h4 {
  margin: 24px 0 5px;
}

.api-docs-status-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  margin: 24px 0;
  overflow: hidden;
  border: 1px solid var(--docs-line);
  border-radius: 12px;
  background: var(--docs-line);
}

.api-docs-status-grid div {
  display: grid;
  gap: 7px;
  padding: 16px;
  background: #fff;
}

.api-docs-status-grid code {
  color: var(--docs-blue-dark);
  font-size: 12px;
}

.api-docs-status-grid span {
  color: var(--docs-muted);
  font-size: 13px;
}

.api-docs-tabs {
  display: flex;
  gap: 4px;
  margin-top: 24px;
  border-bottom: 1px solid var(--docs-line);
}

.api-docs-tabs button {
  min-height: 42px;
  border: 0;
  border-bottom: 2px solid transparent;
  padding: 0 16px;
  background: none;
  color: var(--docs-muted);
  cursor: pointer;
}

.api-docs-tabs button.is-active {
  border-bottom-color: var(--docs-blue);
  color: var(--docs-blue-dark);
  font-weight: 800;
}

.api-docs-tab-panel[hidden] {
  display: none;
}

.api-docs-footer {
  display: flex;
  max-width: 980px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-top: 42px;
  border-radius: 18px;
  padding: 26px;
  background: #102b63;
  color: #fff;
}

.api-docs-footer div {
  display: grid;
  gap: 5px;
}

.api-docs-footer span {
  color: rgba(255, 255, 255, .68);
  font-size: 13px;
}

.api-docs-footer a {
  flex: 0 0 auto;
  background: #fff;
  color: var(--docs-blue-dark);
}

.api-docs-toast {
  position: fixed;
  z-index: 50;
  right: 22px;
  bottom: 22px;
  border-radius: 10px;
  padding: 11px 15px;
  background: #10254c;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .18);
  color: #fff;
  font-size: 13px;
}

@media (max-width: 980px) {
  .api-docs-layout {
    grid-template-columns: 1fr;
  }

  .api-docs-sidebar {
    position: sticky;
    z-index: 15;
    top: 70px;
    display: flex;
    height: auto;
    gap: 5px;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--docs-line);
    padding: 9px 14px;
  }

  .api-docs-sidebar p {
    display: none;
  }

  .api-docs-sidebar nav {
    display: flex;
    gap: 4px;
  }

  .api-docs-sidebar a {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .api-docs-main {
    padding-top: 28px;
  }
}

@media (max-width: 680px) {
  html {
    scroll-padding-top: 126px;
  }

  .api-docs-topbar {
    height: 64px;
    padding: 0 14px;
  }

  .api-docs-brand img {
    width: 38px;
    height: 38px;
  }

  .api-docs-brand small,
  .api-docs-version {
    display: none;
  }

  .api-docs-top-actions a {
    min-height: 38px;
    padding: 0 12px;
  }

  .api-docs-sidebar {
    top: 64px;
  }

  .api-docs-main {
    padding: 22px 18px 60px;
  }

  .api-docs-intro {
    padding: 32px 0 48px;
  }

  .api-docs-intro h1 {
    font-size: 40px;
  }

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

  .api-docs-base span {
    grid-column: 1 / -1;
  }

  .api-docs-section {
    grid-template-columns: 1fr;
    gap: 14px;
    padding: 44px 0;
  }

  .api-docs-endpoint {
    padding: 44px 0;
  }

  .api-docs-steps li {
    grid-template-columns: 1fr;
    gap: 5px;
  }

  .api-docs-response-grid,
  .api-docs-status-grid {
    grid-template-columns: 1fr;
  }

  .api-docs-endpoint-head > strong {
    width: 100%;
    margin-left: 60px;
  }

  .api-docs-tabs {
    overflow-x: auto;
  }

  .api-docs-tabs button {
    flex: 0 0 auto;
  }

  .api-docs-footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
