@import url("https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap");

:root {
  --bg: #f5f7fb;
  --sidebar: #0f172a;
  --sidebar-text: #f8fafc;
  --accent: #38bdf8;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #475569;
  --topbar-height: 64px;
  --sidebar-width: 260px;
  --layout-gap: 32px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body.mobile-menu-open {
  overflow: hidden;
}

.layout {
  display: flex;
  flex: 1;
  width: 100%;
  align-items: flex-start;
  gap: var(--layout-gap);
}

.topbar {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 6px 24px;
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--topbar-height);
  display: flex;
  align-items: center;
}

.topbar-inner {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.logo-link img {
  height: 26px;
  display: block;
}

.menu-toggle {
  display: none;
  border: none;
  background: transparent;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  gap: 6px;
}

.menu-toggle span {
  width: 24px;
  height: 2px;
  background: #0f172a;
  display: block;
}

.mobile-menu {
  position: fixed;
  top: var(--topbar-height);
  left: 0;
  right: 0;
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(6px);
  padding: 16px;
  z-index: 95;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  display: none;
}

.mobile-menu.open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-menu-panel {
  background: #fff;
  border-radius: 16px;
  border: 1px solid var(--border);
  padding: 20px;
}

.mobile-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.mobile-menu-label {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--muted);
  font-weight: 600;
}

.mobile-close {
  background: transparent;
  border: none;
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.mobile-nav {
  display: flex;
  flex-direction: column;
}

.mobile-nav a {
  padding: 12px 0;
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  border-bottom: 1px solid var(--border);
}

.mobile-nav a:last-child {
  border-bottom: none;
}

a {
  color: inherit;
}

.sidebar {
  width: var(--sidebar-width);
  flex: 0 0 var(--sidebar-width);
  background: var(--sidebar);
  color: var(--sidebar-text);
  height: calc(100vh - var(--topbar-height));
  padding: 24px 20px 32px;
  position: sticky;
  top: var(--topbar-height);
  overflow-y: auto;
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.05);
}

.brand {
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.brand .logo img {
  max-width: 200px;
  height: auto;
  display: block;
  padding: 12px;
  background: #fff;
  border-radius: 10px;
}

.brand .tagline {
  font-size: 13px;
  color: rgba(248, 250, 252, 0.7);
}

.nav-section {
  margin-bottom: 16px;
}

.nav-home {
  border: none;
  padding-bottom: 0;
  margin-bottom: 20px;
}

.nav-home a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  background: rgba(248, 250, 252, 0.1);
  text-decoration: none;
  font-weight: 600;
}

.nav-section-title {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
  color: rgba(248, 250, 252, 0.6);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-section-title::after {
  content: "–";
  font-size: 16px;
}

.nav-section.collapsed .nav-section-title::after {
  content: "+";
}

.section-link {
  font-size: 13px;
  color: var(--accent);
  text-decoration: none;
  margin-left: auto;
}

.nav-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 1000px;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.nav-section.collapsed ul {
  max-height: 0;
}

.nav-section li {
  margin-bottom: 6px;
}

.nav-section a {
  display: block;
  padding: 8px 10px;
  border-radius: 6px;
  text-decoration: none;
  color: var(--sidebar-text);
  font-size: 14px;
}

.nav-section a.active,
.nav-section a:hover {
  background: rgba(56, 189, 248, 0.2);
  color: #fff;
}

.method {
  display: inline-block;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 11px;
  text-transform: uppercase;
  margin-right: 6px;
}

.method-get {
  background: rgba(34, 197, 94, 0.15);
  color: #22c55e;
}

.method-post {
  background: rgba(59, 130, 246, 0.2);
  color: #3b82f6;
}

.content {
  flex: 1 1 auto;
  padding: 40px clamp(32px, 5vw, 72px);
  max-width: none;
  min-width: 0;
}

.hero {
  background: #fff;
  padding: 32px;
  border-radius: 12px;
  border: 1px solid var(--border);
  margin-bottom: 32px;
}

.api-key-cta {
  background: #0b1220;
  color: #f8fafc;
  border-radius: 14px;
  padding: 22px 24px;
  margin: 24px 0;
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.25);
}

.api-key-cta h2 {
  margin: 0 0 8px;
  font-size: 20px;
}

.api-key-cta p {
  margin: 0 0 12px;
  color: rgba(248, 250, 252, 0.85);
}

.api-key-cta .cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.api-key-cta a.cta-primary,
.api-key-cta a.cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
}

.api-key-cta a.cta-primary {
  background: #38bdf8;
  color: #03202f;
}

.api-key-cta a.cta-secondary {
  border: 1px solid rgba(248, 250, 252, 0.4);
  color: #f8fafc;
}

.api-key-cta small {
  display: block;
  margin-top: 12px;
  color: rgba(248, 250, 252, 0.6);
  font-size: 12px;
}

.try-me {
  border: 1px solid var(--border);
  border-radius: 16px;
  margin-top: 32px;
  background: #fff;
  box-shadow: var(--shadow);
}

.try-toggle {
  width: 100%;
  padding: 14px 20px;
  border: none;
  background: transparent;
  font-size: 16px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}

.try-toggle::after {
  content: "▸";
  margin-left: auto;
  font-size: 14px;
  color: var(--muted);
}

.try-toggle.open::after {
  content: "▾";
}

.try-panel {
  border-top: 1px solid var(--border);
  padding: 20px;
}

.try-panel[hidden] {
  display: none;
}

.try-panel[hidden] {
  display: none;
}

.try-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.try-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.try-group h3 {
  margin: 0;
  font-size: 16px;
}

.try-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 14px;
}

.try-field span {
  font-weight: 600;
  font-size: 14px;
  color: var(--muted);
}

.try-field em {
  font-style: normal;
  font-weight: 500;
  color: var(--muted);
  margin-left: 6px;
}

.try-field input,
.try-field select,
.try-field textarea {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  font-size: 14px;
  font-family: inherit;
}

.try-field textarea {
  min-height: 140px;
  resize: vertical;
}

.try-field.note {
  color: var(--muted);
  font-style: italic;
  border: 1px dashed var(--border);
  padding: 12px;
  border-radius: 10px;
}

.try-hint {
  font-size: 13px;
  color: var(--muted);
  margin: 0;
}

.try-files {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.try-files-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 600;
  font-size: 14px;
}

.try-add-file,
.try-add-query {
  border: 1px dashed var(--border);
  background: transparent;
  padding: 8px 12px;
  border-radius: 8px;
  font-size: 13px;
  cursor: pointer;
  align-self: flex-start;
}

.try-file-list,
.try-custom-query-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.try-file-row,
.try-query-row {
  display: flex;
  gap: 8px;
  align-items: center;
}

.try-file-label {
  min-width: 80px;
  font-weight: 600;
  color: var(--muted);
}

.try-query-row input[type="text"] {
  flex: 1;
}

.try-file-row input[type="file"] {
  flex: 1;
}

.try-file-remove,
.try-query-remove {
  border: none;
  background: transparent;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  color: var(--muted);
}

.try-checkbox {
  font-size: 13px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.try-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.try-submit {
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 10px 24px;
  font-weight: 600;
  cursor: pointer;
}

.try-submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.try-status {
  font-size: 14px;
  color: var(--muted);
}

.try-output {
  background: #0f172a;
  color: #f1f5f9;
  padding: 16px;
  border-radius: 12px;
  font-size: 13px;
  max-height: 320px;
  overflow: auto;
}

.try-curl-block {
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 12px;
  background: #fff;
}

.try-curl-block pre {
  background: #0f172a;
  color: #e2e8f0;
  padding: 12px;
  border-radius: 10px;
  font-size: 12px;
  overflow-x: auto;
}

.try-advanced-toggle {
  border: none;
  background: transparent;
  color: var(--accent);
  font-weight: 600;
  cursor: pointer;
  align-self: flex-start;
  padding: 0;
}

.try-advanced {
  border-top: 1px dashed var(--border);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.try-advanced[hidden] {
  display: none;
}

.toc {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 16px;
}

.toc a {
  background: #fff;
  border: 1px solid var(--border);
  padding: 6px 12px;
  border-radius: 20px;
  text-decoration: none;
  font-size: 14px;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.service-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.service-card a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.content-filter {
  margin: 24px 0;
  display: flex;
  gap: 12px;
  align-items: center;
}

.content-filter input {
  flex: 1;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
}

.op-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 18px;
}

.op-card h3 {
  margin-top: 0;
}

.op-card .footer-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.card {
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 24px;
}

.card ul {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--muted);
}

.operation {
  max-width: 960px;
  width: 100%;
  margin: 0 auto;
}

.operation header {
  background: #fff;
  padding: 32px;
  border-radius: 12px;
  border: 1px solid var(--border);
  margin-bottom: 32px;
}

.service-section {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 24px;
}

.op-list {
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}

.op-list li {
  margin-bottom: 10px;
}

.op-list a {
  text-decoration: none;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.breadcrumb {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
}

.operation h1 {
  margin-top: 0;
}

.lead {
  color: var(--muted);
  max-width: 700px;
}

.method-list {
  margin-top: 16px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.path {
  background: var(--bg);
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 13px;
}

section {
  margin-bottom: 32px;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

table th,
table td {
  text-align: left;
  padding: 10px;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

pre {
  background: #0f172a;
  color: #cbd5f5;
  padding: 16px;
  border-radius: 10px;
  overflow: auto;
}

.example {
  margin-bottom: 24px;
}

.example-images {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  margin-top: 16px;
  align-items: flex-start;
  justify-content: center;
}

.example-images figure {
  flex: 1 1 260px;
  max-width: 360px;
  width: 100%;
  margin: 0;
}

.example-images img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 12px;
  border: 1px solid var(--border);
  box-shadow: 0 10px 25px rgba(15, 23, 42, 0.1);
}

.example-images figcaption {
  text-align: center;
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.example-block,
.example-command {
  margin-bottom: 32px;
}

.example-command pre {
  margin-top: 12px;
}

.label {
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 4px;
  color: var(--muted);
}

@media (min-width: 1100px) and (max-width: 1500px) {
  .content {
    max-width: calc(100vw - var(--sidebar-width) - var(--layout-gap));
  }
}

@media (max-width: 1100px) {
  .layout {
    flex-direction: column;
    gap: 0;
  }
  .sidebar {
    display: none;
  }
  .content {
    padding: 32px 20px 48px;
  }
  .menu-toggle {
    display: inline-flex;
  }
  .mobile-menu {
    display: block;
  }
  .operation {
    max-width: min(960px, 90vw);
  }
}

@media (max-width: 900px) {
  .example-images {
    justify-content: center;
  }
  .example-images figure {
    flex: 1 1 240px;
    max-width: min(320px, 90vw);
  }
}

@media (max-width: 600px) {
  .example-images figure {
    flex-basis: 100%;
    max-width: min(280px, 90vw);
  }
  .api-key-cta {
    padding: 20px;
  }
}
.search {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: none;
  margin-bottom: 18px;
  font-size: 14px;
}

.operation img {
  max-width: 100%;
  height: auto;
}
.api-key-note {
  font-size: 13px;
  color: var(--muted);
  margin-top: 12px;
}

.api-key-note a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}
