body {
  margin: 0;
  background: #f5f7fb;
  color: #172033;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  overflow-x: hidden;
}

.doc-shell {
  min-height: 100vh;
  overflow-x: hidden;
}

.doc-header {
  background: #132033;
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.doc-header-inner,
.doc-main {
  width: min(1180px, calc(100vw - 40px));
  margin: 0 auto;
}

.doc-header-inner {
  padding: 28px 0 24px;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand-name {
  margin: 0;
  font-size: 26px;
  font-weight: 750;
}

.brand-subtitle {
  margin: 8px 0 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
}

.header-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.header-actions a {
  color: #fff;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 13px;
}

.doc-main {
  padding: 24px 0 48px;
}

.doc-grid {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.doc-nav {
  position: sticky;
  top: 18px;
  padding: 14px;
  background: #fff;
  border: 1px solid #dfe6f0;
  border-radius: 8px;
}

.doc-nav a {
  display: block;
  padding: 8px 10px;
  color: #344054;
  text-decoration: none;
  border-radius: 6px;
  font-size: 14px;
}

.doc-nav a:hover {
  background: #eef4ff;
  color: #175cd3;
}

.doc-content {
  display: grid;
  gap: 18px;
  min-width: 0;
}

.doc-section {
  background: #fff;
  border: 1px solid #dfe6f0;
  border-radius: 8px;
  padding: 22px;
  min-width: 0;
}

.doc-section h2 {
  margin: 0 0 14px;
  font-size: 20px;
}

.doc-section h3 {
  margin: 20px 0 10px;
  font-size: 16px;
}

.doc-section p {
  line-height: 1.7;
  color: #475467;
}

.notice-box {
  margin-top: 14px;
  padding: 14px 16px;
  background: #f8fbff;
  border: 1px solid #bfdbfe;
  border-radius: 8px;
}

.notice-box strong {
  display: block;
  color: #175cd3;
  font-size: 14px;
  margin-bottom: 4px;
}

.notice-box p {
  margin: 0;
}

.endpoint {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin: 12px 0;
  min-width: 0;
}

.method {
  padding: 4px 8px;
  background: #dcfce7;
  color: #166534;
  border-radius: 6px;
  font-weight: 700;
  font-size: 13px;
}

code,
pre {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

code {
  overflow-wrap: anywhere;
  word-break: break-word;
}

pre {
  overflow-x: hidden;
  margin: 12px 0 0;
  padding: 14px;
  background: #101828;
  color: #e5e7eb;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  word-break: break-word;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
  font-size: 13px;
  table-layout: fixed;
}

th,
td {
  padding: 10px 12px;
  border-bottom: 1px solid #eef2f6;
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
  word-break: break-word;
}

th {
  color: #344054;
  background: #f8fafc;
  font-weight: 700;
}

.sdk-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 12px;
}

.sdk-tab {
  border: 1px solid #cfd6e2;
  background: #fff;
  color: #344054;
  border-radius: 6px;
  padding: 8px 10px;
  cursor: pointer;
  font-size: 13px;
}

.sdk-tab.active {
  border-color: #1677ff;
  background: #eef4ff;
  color: #175cd3;
  font-weight: 700;
}

.sdk-panel {
  display: none;
}

.sdk-panel.active {
  display: block;
}

.hint {
  color: #667085;
  font-size: 13px;
}

.docs-login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.docs-login-card {
  width: min(420px, 100%);
  background: #fff;
  border: 1px solid #dfe6f0;
  border-radius: 8px;
  padding: 28px;
  box-shadow: 0 18px 50px rgba(16, 24, 40, 0.08);
}

.docs-login-card h1 {
  margin: 0;
  font-size: 22px;
  color: #172033;
}

.docs-login-card p {
  margin: 10px 0 18px;
  color: #667085;
  line-height: 1.6;
}

.docs-login-card form {
  display: grid;
  gap: 12px;
}

.docs-login-card input,
.docs-login-card button {
  height: 42px;
  border-radius: 6px;
  font-size: 14px;
}

.docs-login-card input {
  border: 1px solid #cfd6e2;
  padding: 0 12px;
  outline: none;
}

.docs-login-card input:focus {
  border-color: #1677ff;
  box-shadow: 0 0 0 3px rgba(22, 119, 255, 0.14);
}

.docs-login-card button {
  border: 0;
  background: #1677ff;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
}

.docs-login-error {
  color: #b42318 !important;
  margin-bottom: 0 !important;
}

@media (max-width: 880px) {
  .doc-header-inner,
  .doc-main {
    width: min(100vw - 24px, 1180px);
  }

  .brand-row {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .doc-nav {
    position: static;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .doc-header-inner,
  .doc-main {
    width: min(100vw - 20px, 1180px);
  }

  .doc-header-inner {
    padding: 22px 0 20px;
  }

  .brand-name {
    font-size: 22px;
    line-height: 1.25;
  }

  .header-actions {
    width: 100%;
  }

  .header-actions a {
    flex: 1;
    text-align: center;
  }

  .doc-main {
    padding: 16px 0 32px;
  }

  .doc-grid {
    gap: 14px;
  }

  .doc-nav {
    gap: 4px;
    padding: 10px;
  }

  .doc-nav a {
    padding: 8px;
    font-size: 13px;
  }

  .doc-section {
    padding: 16px;
  }

  .doc-section h2 {
    font-size: 18px;
  }

  .endpoint {
    align-items: flex-start;
  }

  .endpoint code {
    display: block;
    width: 100%;
  }

  pre {
    padding: 12px;
    font-size: 11px;
  }
}
