:root {
  --bg: #0f172a;
  --surface: #111827;
  --panel: #ffffff;
  --page-bg: #f8fafc;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #475569;
  --accent: #2563eb;
  --accent-soft: #eff6ff;
  --code-bg: #0f172a;
  --code-fg: #e2e8f0;
  --get: #059669;
  --post: #2563eb;
  --delete: #dc2626;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
  background: var(--page-bg);
  color: var(--text);
  line-height: 1.65;
}
.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 60px;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--text);
  text-decoration: none;
}
.version-pill {
  font-size: 0.75rem;
  font-weight: 600;
  background: var(--accent-soft);
  color: var(--accent);
  padding: 2px 8px;
  border-radius: 999px;
}
.topnav a {
  color: var(--muted);
  text-decoration: none;
  margin-left: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}
.topnav a:hover, .topnav a.active { color: var(--accent); }
.layout {
  max-width: 1280px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: calc(100vh - 60px);
}
.sidebar {
  border-right: 1px solid var(--border);
  background: #ffffff;
  padding: 28px 20px;
  position: sticky;
  top: 60px;
  height: calc(100vh - 60px);
  overflow-y: auto;
}
.nav-group { margin-bottom: 24px; }
.nav-title {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #64748b;
  font-weight: 700;
  margin-bottom: 8px;
}
.sidebar a {
  display: block;
  padding: 6px 10px;
  border-radius: 6px;
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  margin-bottom: 2px;
}
.sidebar a:hover, .sidebar a.active {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}
.content {
  padding: 40px 48px 80px;
  max-width: 900px;
}
h1 { font-size: 2rem; letter-spacing: -0.02em; margin-bottom: 12px; }
h2 {
  font-size: 1.35rem;
  margin-top: 42px;
  margin-bottom: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
h3 { font-size: 1.05rem; margin: 22px 0 8px; }
p { color: var(--muted); margin-bottom: 16px; }
.lead { font-size: 1.08rem; color: #334155; margin-bottom: 24px; }
.endpoint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  border: 1px solid var(--border);
  padding: 8px 14px;
  border-radius: 8px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88rem;
  margin: 8px 0 16px;
}
.badge {
  color: #fff;
  font-weight: 700;
  font-size: 0.72rem;
  padding: 2px 8px;
  border-radius: 4px;
}
.badge.get { background: var(--get); }
.badge.post { background: var(--post); }
.badge.delete { background: var(--delete); }
.code-card {
  background: var(--code-bg);
  color: var(--code-fg);
  border-radius: 10px;
  overflow: hidden;
  margin: 16px 0 26px;
}
.code-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 14px;
  background: #1e293b;
  font-size: 0.78rem;
  color: #94a3b8;
}
.copy-btn {
  background: #334155;
  color: #f8fafc;
  border: none;
  border-radius: 4px;
  padding: 3px 9px;
  font-size: 0.75rem;
  cursor: pointer;
}
.copy-btn:hover { background: #475569; }
pre {
  padding: 16px;
  overflow-x: auto;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85rem;
  line-height: 1.55;
}
code.inline {
  background: #e2e8f0;
  color: #0f172a;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.85em;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
  margin: 14px 0 24px;
  font-size: 0.9rem;
}
th, td {
  text-align: left;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}
th { background: #f1f5f9; font-weight: 600; color: #334155; }
.callout {
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  padding: 14px 18px;
  border-radius: 0 8px 8px 0;
  margin: 18px 0;
  color: #1e3a8a;
  font-size: 0.92rem;
}
footer {
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  font-size: 0.84rem;
  color: #64748b;
}
@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; }
  .sidebar { position: static; height: auto; border-right: none; border-bottom: 1px solid var(--border); }
  .content { padding: 24px 20px; }
}
