:root {
    /* ─── Brand ───────────────────────────────────────────── */
    --primary:        #f97316;
    --primary-rgb:    249, 115, 22;
    --primary-dark:   #ea580c;
    --accent:         #f59e0b;

    /* ─── Backgrounds ─────────────────────────────────────── */
    --bg:             #0d1117;
    --bg-deep:        #090c10;
    --surface:        #161b22;

    /* ─── Text ────────────────────────────────────────────── */
    --text:           #e6edf3;
    --text-muted:     #7d8590;
    --text-subtle:    #484f58;
    --text-bright:    #e2e8f0;

    /* ─── Borders ─────────────────────────────────────────── */
    --border:         #21262d;
    --border-soft:    #30363d;

    /* ─── Status colours ──────────────────────────────────── */
    --green:          #22c55e;
    --green-dim:      rgba(34, 197, 94, 0.1);
    --blue:           #58a6ff;
    --blue-dim:       rgba(88, 166, 255, 0.1);
    --amber:          #f59e0b;
    --amber-dim:      rgba(245, 158, 11, 0.12);
    --red:            #ef4444;
    --red-dim:        rgba(239, 68, 68, 0.1);
    --purple:         #bc8cff;
    --purple-dim:     rgba(188, 140, 255, 0.1);

    /* ─── Layout ──────────────────────────────────────────── */
    --sidebar-w:      256px;
    --header-h:       48px;
    --font:           Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --mono:           "JetBrains Mono", "Fira Code", Consolas, monospace;
    --r:              8px;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

[hidden] { display: none !important; }

html {
    background: var(--bg);
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
}
@media (prefers-reduced-motion: no-preference) {
    html { scroll-behavior: smooth; }
}
/* Set while the mobile drawer is open */
html.scroll-lock { overflow: hidden; }

/* Only <body> clips horizontal overflow: it propagates to the viewport so the
   window stays the scroller. Clipping <html> as well (or giving body a fixed
   height) turns <body> into its own scroll container, which breaks window
   scroll events, the scroll spy and the scroll lock. */
body {
    font-family: var(--font);
    font-size: 14px;
    background: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

button {
    font: inherit;
    color: inherit;
    -webkit-tap-highlight-color: transparent;
}

:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-soft); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #4a5568; }

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Header ────────────────────────────────────────────── */
#docs-header {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: var(--header-h);
    background: var(--bg-deep);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    padding: 0 20px;
    z-index: 200;
    gap: 12px;
}

.h-logo {
    display: flex;
    align-items: center;
    gap: 9px;
    text-decoration: none !important;
}

.h-mark {
    width: 26px;
    height: 26px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: var(--r);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 11px;
    color: #fff;
    letter-spacing: -0.3px;
    flex-shrink: 0;
}
.h-mark.has-logo {
    width: auto;
    padding: 2px 0;
    background: none;
    border-radius: 0;
}
.h-mark img { height: 22px; width: auto; display: block; }

.h-brand {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-bright);
    letter-spacing: -0.2px;
}

.h-sep {
    display: none;
    width: 1px;
    height: 18px;
    background: var(--border-soft);
}

.h-badge {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.2px;
    color: var(--primary);
    background: rgba(var(--primary-rgb), 0.1);
    padding: 4px 10px;
    border-radius: 999px;
    border: 1px solid rgba(var(--primary-rgb), 0.35);
    white-space: nowrap;
}

.h-spacer { flex: 1; }

.h-link {
    font-size: 12px;
    color: var(--text-subtle);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: color 0.15s;
}
.h-link:hover { color: var(--text-muted); text-decoration: none; }

/* Mobile nav toggle (shown below the drawer breakpoint) */
.h-menu {
    display: none;
    align-items: center;
    gap: 8px;
    height: 32px;
    padding: 0 10px;
    border-radius: 6px;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-muted);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    font-size: 12px;
}
.h-menu:hover { background: rgba(255, 255, 255, 0.08); color: var(--text); }

/* ── Layout ─────────────────────────────────────────────── */
#layout {
    display: flex;
    margin-top: var(--header-h);
    min-height: calc(100vh - var(--header-h));
    min-height: calc(100dvh - var(--header-h));
}

/* ── Sidebar ─────────────────────────────────────────────── */
#sidebar {
    position: fixed;
    top: var(--header-h);
    left: 0; bottom: 0;
    width: var(--sidebar-w);
    background: var(--bg-deep);
    border-right: 1px solid var(--border);
    overflow-y: auto;
    overflow-x: hidden;
    overscroll-behavior: contain;
    padding-bottom: env(safe-area-inset-bottom);
}

.sb-overlay {
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 250;
}

.sb-section {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
}
.sb-section:last-child { border-bottom: none; }

.sb-cap,
.sb-tag {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    font-family: var(--mono);
}
.sb-cap { padding: 0 16px 6px; }
.sb-tag { padding: 8px 16px 4px; }

.sb-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 16px;
    font-size: 12px;
    color: #9aabb8;
    transition: color 0.12s, background 0.12s;
    white-space: nowrap;
    overflow: hidden;
    text-decoration: none;
}
.sb-link:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
    text-decoration: none;
}
.sb-link:focus-visible { outline-offset: -2px; }
.sb-link.active {
    color: var(--primary);
    background: rgba(var(--primary-rgb), 0.08);
}

.sb-method {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
    width: 36px;
    text-align: right;
}

.sb-path {
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--mono);
    font-size: 11px;
    color: #6d7f90;
    flex: 1;
}
.sb-link:hover .sb-path,
.sb-link.active .sb-path { color: inherit; }

/* sidebar method colours */
.sm-get    { color: var(--green); }
.sm-post   { color: var(--blue); }
.sm-put    { color: var(--amber); }
.sm-patch  { color: var(--purple); }
.sm-delete { color: var(--red); }

/* ── Main content ──────────────────────────────────────── */
#content {
    margin-left: var(--sidebar-w);
    flex: 1;
    min-width: 0;
    padding: 44px 52px 80px;
    max-width: 840px;
}

/* ── Overview ──────────────────────────────────────────── */
#overview {
    scroll-margin-top: calc(var(--header-h) + 20px);
}

#ov-logo img {
    height: 44px;
    width: auto;
    display: block;
    margin-bottom: 20px;
}

.ov-title {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 10px;
    color: var(--text-bright);
}

.ov-desc {
    font-size: 14px;
    line-height: 1.65;
    color: var(--text-muted);
    margin-bottom: 20px;
    max-width: 600px;
}

.ov-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 32px;
}

.chip {
    display: flex;
    align-items: baseline;
    gap: 6px;
    min-width: 0;
    max-width: 100%;
    padding: 4px 12px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    font-size: 12px;
    line-height: 1.5;
    color: var(--text);
    overflow-wrap: break-word;
}
.chip > span:last-child { min-width: 0; }
.chip-lbl {
    flex-shrink: 0;
    white-space: nowrap;
    color: var(--text-muted);
    font-size: 11px;
    font-family: var(--mono);
}
.chip-note { color: var(--text-muted); }
.chip-accent {
    color: var(--accent);
    font-weight: 500;
    white-space: nowrap;
}

.rule {
    border: none;
    border-top: 1px solid var(--border);
    margin: 40px 0;
}

/* ── Tag heading ───────────────────────────────────────── */
.tag-h {
    font-size: 18px;
    font-weight: 700;
    letter-spacing: -0.3px;
    margin-bottom: 16px;
    color: var(--text-bright);
}

/* ── Endpoint card ─────────────────────────────────────── */
.ep {
    border: 1px solid var(--border);
    border-radius: var(--r);
    overflow: hidden;
    margin-bottom: 10px;
    background: var(--surface);
    scroll-margin-top: calc(var(--header-h) + 20px);
    transition: border-color 0.15s;
}
.ep:hover { border-color: var(--border-soft); }

.ep-hd {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 13px 18px;
    border: 0;
    background: none;
    text-align: left;
    cursor: pointer;
    user-select: none;
    transition: background 0.12s;
}
.ep-hd:hover { background: rgba(255, 255, 255, 0.02); }
.ep-hd:focus-visible { outline-offset: -2px; }
.ep.open .ep-hd { border-bottom: 1px solid var(--border); }

.meth {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 700;
    padding: 3px 7px;
    border-radius: 4px;
    min-width: 50px;
    text-align: center;
    flex-shrink: 0;
    letter-spacing: 0.04em;
}

.m-get    { color: var(--green);  background: var(--green-dim); }
.m-post   { color: var(--blue);   background: var(--blue-dim); }
.m-put    { color: var(--amber);  background: var(--amber-dim); }
.m-patch  { color: var(--purple); background: var(--purple-dim); }
.m-delete { color: var(--red);    background: var(--red-dim); }

.ep-path {
    font-family: var(--mono);
    font-size: 13px;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.ep-sum {
    font-size: 12px;
    color: var(--text-muted);
    flex-shrink: 0;
    max-width: 260px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.chevron {
    color: var(--text-subtle);
    transition: transform 0.2s;
    flex-shrink: 0;
}
.ep.open > .ep-hd .chevron,
.resp-item.open > .resp-hd .chevron { transform: rotate(90deg); }

.ep-body { padding: 20px 18px; }
/* Collapsed only when the script can expand it; without JS everything shows. */
.js .ep:not(.open) > .ep-body { display: none; }

.ep-desc {
    font-size: 13px;
    line-height: 1.65;
    color: var(--text-muted);
    margin-bottom: 18px;
}

/* ── Auth tag ───────────────────────────────────────────── */
.auth-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 9px;
    background: var(--amber-dim);
    border: 1px solid rgba(245, 158, 11, 0.2);
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
    color: var(--amber);
    margin-bottom: 18px;
}

/* ── Section label ──────────────────────────────────────── */
.slbl {
    font-family: var(--mono);
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 8px;
    opacity: 0.85;
}
.slbl-gap     { margin-top: 12px; }
.slbl-section { margin-top: 20px; }

/* ── Parameters ─────────────────────────────────────────── */
.tbl-wrap {
    width: 100%;
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: var(--r);
    background: rgba(255, 255, 255, 0.01);
}
.tbl-wrap::-webkit-scrollbar { height: 6px; }

.ptbl {
    width: 100%;
    min-width: 560px;
    border-collapse: collapse;
}
.ptbl th {
    text-align: left;
    padding: 6px 12px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-subtle);
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.02);
}
.ptbl td {
    padding: 9px 12px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
    font-size: 13px;
}
.ptbl tr:last-child td { border-bottom: none; }

.ptbl .p-name {
    font-family: var(--mono);
    font-size: 12px;
    white-space: nowrap;
}

.req-dot {
    display: inline-block;
    width: 5px;
    height: 5px;
    margin-left: 4px;
    border-radius: 50%;
    background: var(--red);
    vertical-align: middle;
}

.in-badge {
    font-family: var(--mono);
    font-size: 10px;
    padding: 1px 6px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-muted);
    border: 1px solid var(--border);
}

.type-badge {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--purple);
}

.p-desc {
    font-size: 12px;
    color: var(--text-muted);
    line-height: 1.5;
}
.p-ex {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-subtle);
    margin-top: 3px;
    overflow-wrap: anywhere;
}

/* ── Responses ──────────────────────────────────────────── */
.resp-list { margin-bottom: 22px; }

.resp-item {
    border: 1px solid var(--border);
    border-radius: var(--r);
    margin-bottom: 6px;
    overflow: hidden;
}

.resp-hd {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 9px 13px;
    border: 0;
    background: none;
    text-align: left;
}
button.resp-hd {
    cursor: pointer;
    user-select: none;
    transition: background 0.12s;
}
button.resp-hd:hover { background: rgba(255, 255, 255, 0.02); }
.resp-hd:focus-visible { outline-offset: -2px; }

.stat {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 4px;
    min-width: 36px;
    text-align: center;
    flex-shrink: 0;
}
.s2 { color: var(--green); background: var(--green-dim); }
.s3 { color: var(--amber); background: var(--amber-dim); }
.s4 { color: var(--red);   background: var(--red-dim); }
.s5 { color: var(--red);   background: var(--red-dim); }

.resp-desc {
    font-size: 12px;
    color: var(--text-muted);
    flex: 1;
    min-width: 0;
}

.resp-body {
    padding: 12px 13px;
    border-top: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.01);
}
.js .resp-item:not(.open) > .resp-body { display: none; }

/* ── Schema ─────────────────────────────────────────────── */
.schema-wrap {
    border: 1px solid var(--border);
    border-radius: var(--r);
    overflow: hidden;
    margin-top: 6px;
    font-size: 12px;
}

.schema-hdr,
.schema-row {
    display: grid;
    grid-template-columns: 150px 120px minmax(0, 1fr);
    gap: 8px;
    padding: 8px 12px;
}

.schema-hdr {
    padding-block: 5px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid var(--border);
}
.schema-hdr span {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-subtle);
}

.schema-row {
    border-bottom: 1px solid var(--border);
    align-items: baseline;
}
.schema-row:last-child { border-bottom: none; }
.schema-row:nth-child(odd) { background: rgba(255, 255, 255, 0.01); }

.s-field {
    font-family: var(--mono);
    font-size: 12px;
    overflow-wrap: anywhere;
}
.s-type { font-family: var(--mono); font-size: 11px; color: var(--purple); overflow-wrap: anywhere; }
.s-desc { font-size: 12px; color: var(--text-muted); line-height: 1.4; }
.s-ex   { font-family: var(--mono); font-size: 11px; color: var(--text-subtle); margin-top: 2px; overflow-wrap: anywhere; }

.arr-note {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

/* ── Code block ─────────────────────────────────────────── */
.code-wrap {
    position: relative;
    margin-top: 6px;
    border-radius: var(--r);
    overflow: hidden;
    border: 1px solid var(--border);
}

.code-blk {
    background: var(--bg-deep);
    padding: 12px 64px 12px 16px;
    font-family: var(--mono);
    font-size: 12px;
    color: #c9d1d9;
    line-height: 1.65;
    overflow-x: auto;
    white-space: pre;
}

.copy-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(22, 27, 34, 0.92);
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
    border-radius: 6px;
    padding: 2px 8px;
    font-size: 10px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}
.copy-btn:hover { background: var(--surface); color: var(--text); }
.copy-btn.ok    { color: var(--green); border-color: rgba(34, 197, 94, 0.35); }
/* Copying needs the script */
html:not(.js) .copy-btn { display: none; }

/* ── Code tabs (cURL / JavaScript / Python) ────────────── */
.code-tablist {
    display: flex;
    gap: 4px;
    margin-top: 6px;
}
html:not(.js) .code-tablist { display: none; }

.code-tab {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--text-muted);
    background: none;
    border: 1px solid transparent;
    border-radius: 6px;
    padding: 3px 9px;
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
}
.code-tab:hover { color: var(--text); }
.code-tab.active {
    color: var(--primary);
    background: rgba(var(--primary-rgb), 0.1);
    border-color: rgba(var(--primary-rgb), 0.35);
}

.js .code-panel:not(.active) { display: none; }
/* Without the tab bar, each stacked panel names its language */
.code-panel-lbl {
    font-family: var(--mono);
    font-size: 10px;
    color: var(--text-subtle);
    margin-top: 10px;
}
.js .code-panel-lbl { display: none; }

/* ── Header call to action ─────────────────────────────── */
.h-cta {
    font-size: 12px;
    font-weight: 600;
    color: #fff;
    background: var(--primary);
    border-radius: 6px;
    padding: 5px 12px;
    text-decoration: none;
    white-space: nowrap;
    transition: background 0.15s;
}
.h-cta:hover { background: var(--primary-dark); text-decoration: none; }

/* ── Tag description ───────────────────────────────────── */
.tag-desc {
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-muted);
    margin: -8px 0 16px;
    max-width: 640px;
}

/* ── Quick start ───────────────────────────────────────── */
#quickstart {
    scroll-margin-top: calc(var(--header-h) + 20px);
}

.qs-lead {
    margin: -8px 0 28px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.65;
}

.qs-steps {
    list-style: none;
    counter-reset: qs;
    max-width: 680px;
}
.qs-steps > li {
    counter-increment: qs;
    position: relative;
    padding: 28px 0 28px 44px;
    border-top: 1px solid var(--border);
    min-width: 0;
}
.qs-steps > li:first-child { padding-top: 0; border-top: none; }
.qs-steps > li:last-child { padding-bottom: 0; }
.qs-steps > li::before {
    content: counter(qs, decimal-leading-zero);
    position: absolute;
    left: 0;
    top: 31px;
    font-family: var(--mono);
    font-size: 12px;
    font-variant-numeric: tabular-nums;
    color: var(--text-muted);
}
.qs-steps > li:first-child::before { top: 3px; }

.qs-title {
    margin-bottom: 8px;
    color: var(--text-bright);
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    letter-spacing: -0.2px;
}
.qs-description {
    color: var(--text);
    font-size: 14px;
    line-height: 1.7;
}
.qs-steps code {
    font-family: var(--mono);
    font-size: 12px;
    color: var(--text);
    overflow-wrap: anywhere;
}

.qs-cta {
    display: inline-flex;
    align-items: center;
    margin-top: 16px;
    padding: 8px 14px;
    border-radius: 6px;
    background: var(--primary);
    color: var(--bg-deep);
    font-size: 12px;
    font-weight: 600;
    line-height: 1.5;
    text-decoration: none;
    transition: background 0.15s;
}
.qs-cta:hover { background: var(--primary-dark); text-decoration: none; }

.qs-steps .code-wrap { margin-top: 14px; }
.qs-steps .code-blk {
    padding: 16px 72px 16px 18px;
    color: var(--text);
}
.qs-steps .copy-btn { top: 12px; font-size: 11px; }

.qs-endpoint {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-top: 16px;
    min-width: 0;
}
.qs-method {
    font-family: var(--mono);
    font-size: 11px;
    font-weight: 500;
    color: var(--text-muted);
    flex-shrink: 0;
}
.qs-billing {
    margin: 10px 0 16px;
    color: var(--text-muted);
    font-size: 12px;
    line-height: 1.65;
}

.qs-request,
.qs-response {
    overflow: hidden;
    border: 1px solid var(--border-soft);
    border-radius: var(--r);
    background: var(--bg-deep);
}
.qs-request .code-tablist {
    gap: 6px;
    margin: 0;
    padding: 8px 10px;
    border-bottom: 1px solid var(--border);
}
.qs-request .code-tab {
    font-family: var(--font);
    font-size: 12px;
    padding: 5px 10px;
}
.qs-request .code-tab.active {
    background: none;
    border-color: transparent;
    border-bottom-color: var(--primary);
    border-radius: 0;
}
.qs-request .code-wrap,
.qs-response .code-wrap {
    margin: 0;
    border: none;
    border-radius: 0;
}
.qs-request .code-panel-lbl { margin: 0; padding: 12px 18px 0; }
html:not(.js) .qs-request .code-panel + .code-panel { border-top: 1px solid var(--border); }

.qs-response { margin-top: 16px; }
.qs-response-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px 16px;
    padding: 12px 18px;
    border-bottom: 1px solid var(--border);
    font-size: 12px;
    color: var(--text-muted);
}
.qs-status {
    font-family: var(--mono);
    font-size: 11px;
    font-variant-numeric: tabular-nums;
    color: var(--text);
}

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 980px) {
    #content { padding: 32px 22px 70px; }
    .ep-sum  { max-width: 200px; }
}

/* Sidebar becomes an off-canvas drawer */
@media (max-width: 860px) {
    #docs-header { padding: 0 16px; }
    .h-sep  { display: block; }
    .h-menu { display: inline-flex; }
    .h-link { display: none; }

    #sidebar {
        width: min(84vw, 320px);
        transform: translateX(-110%);
        visibility: hidden;
        transition: transform 0.22s ease, visibility 0s linear 0.22s;
        z-index: 300;
        box-shadow: 14px 0 40px rgba(0, 0, 0, 0.4);
    }
    body.sb-open #sidebar {
        transform: translateX(0);
        visibility: visible;
        transition: transform 0.22s ease;
    }
    .sb-link { padding-block: 9px; }

    #content { margin-left: 0; padding: 26px 16px 64px; }
    .h-cta   { padding: 5px 10px; }

    /* Endpoint header: method + path + chevron, summary on its own line */
    .ep-hd   { flex-wrap: wrap; gap: 8px 10px; padding: 12px 14px; }
    .ep-path { white-space: normal; overflow-wrap: break-word; }
    .ep-sum  { order: 1; flex-basis: 100%; max-width: none; white-space: normal; }
    .ep-body { padding: 16px 14px; }
}

/* Phones: logo, menu and call to action share one row without spilling off-screen. */
@media (max-width: 480px) {
    #docs-header { gap: 10px; }
    .h-sep, .h-badge, .h-menu-txt { display: none; }
    .h-menu, .h-cta { min-height: 36px; }
    .h-cta { display: inline-flex; align-items: center; }
}

@media (max-width: 680px) {
    .ov-title { font-size: 22px; }

    .qs-steps > li { padding-left: 32px; }
    /* Keep Copy above scrollable code, never over a long command. */
    .qs-steps .code-wrap { padding-top: 36px; background: var(--bg-deep); }
    .qs-steps .code-blk { padding: 0 12px 14px; }
    .qs-steps .copy-btn { top: 8px; }
    html:not(.js) .qs-steps .code-wrap { padding-top: 14px; }
    .qs-request .code-tablist { gap: 2px; padding-inline: 6px; }
    .qs-request .code-tab { padding-inline: 8px; }
    .qs-response-heading { padding-inline: 12px; }

    /* Parameters: one stacked block per row */
    .ptbl, .ptbl tbody { display: block; min-width: 0; }
    .ptbl thead { display: none; }
    .ptbl tr {
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        gap: 6px 10px;
        padding: 10px 12px;
        border-bottom: 1px solid var(--border);
    }
    .ptbl tr:last-child { border-bottom: none; }
    .ptbl td { display: block; padding: 0; border: none; }
    .ptbl td:last-child { flex-basis: 100%; }
    .ptbl .p-name { white-space: normal; overflow-wrap: anywhere; }

    /* Schema: name + type on one line, description below */
    .schema-hdr { display: none; }
    .schema-row { grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; }
    .schema-row > :last-child { grid-column: 1 / -1; }
}
