/* TemanQRIS API docs. "Kertas dan Tinta": cream paper, ink text and code,
   one orange accent, the logo's slash as the only decorative motif.
   Components read tokens only; raw colors live in the token blocks. */

:root {
    color-scheme: light dark;

    --paper: #FFFAF0;
    --surface: #FFFFFF;
    --sunken: #F6F1E6;
    --ink: #1A1A2E;
    --ink-2: #4A4A5E;
    --ink-3: #6B6B7B;
    --line: #E8E1D0;
    --line-strong: #C9BFA5;
    --brand: #E55A2B;
    --brand-hover: #F2703F;
    --brand-ink: #B23F14;
    --brand-ink-strong: #8F3411;
    --brand-tint: #FFEDE5;
    --brand-tint-2: #FFD9C7;
    --focus: #1A1A2E;
    --scrim: rgba(15, 15, 28, 0.55);
    --selection: #FFD9C7;

    --code-bg: #1A1A2E;
    --code-bg-2: #232340;
    --code-line: #34345A;
    --code-text: #E8E6F0;
    --code-muted: #9B9BB8;
    --code-keyword: #FF9E7A;
    --code-string: #8EE3C0;
    --code-number: #FFD166;
    --code-prop: #8FB8FF;
    --code-func: #C9A7FF;
    --code-focus: #FFB08A;
    --code-selected-bg: rgba(255, 255, 255, 0.08);
    --code-selected-text: #FFFFFF;
    --dot-2xx: #5FD6A5;
    --dot-4xx: #FFD166;
    --dot-5xx: #FF8E84;

    --get-text: #0B5CAD; --get-bg: #E3F0FD; --get-line: #BBD8F7;
    --post-text: #0A7B55; --post-bg: #DDF6EC; --post-line: #B4E7D0;
    --put-text: #8A5A00; --put-bg: #FFF1CC; --put-line: #F2D98C;
    --del-text: #B42318; --del-bg: #FDE7E4; --del-line: #F6C2BC;
    --muted-bg: #EFEADD;
    /* widget.js ships its own look; the preview mirrors it exactly */
    --widget-bg: #FF6B35;
    --widget-text: #FFFFFF;
    --widget-ink: #1A1A2E;
    --code-selection: rgba(255, 176, 138, 0.35);

    --shadow-1: 0 1px 2px rgba(26, 26, 46, 0.06);
    --shadow-2: 0 4px 12px -2px rgba(26, 26, 46, 0.10), 0 1px 3px rgba(26, 26, 46, 0.06);
    --shadow-pop: 0 24px 48px -12px rgba(26, 26, 46, 0.28), 0 0 0 1px rgba(26, 26, 46, 0.06);

    --font-sans: 'Nunito', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

    --sidebar-w: 288px;
    --toc-w: 240px;
    --topbar-h: 56px;
    --content-max: 760px;
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --dur-fast: 120ms;
    --dur: 180ms;
    --dur-slow: 240ms;

    --z-sticky: 10;
    --z-topbar: 20;
    --z-scrim: 40;
    --z-drawer: 50;
    --z-palette-scrim: 90;
    --z-palette: 100;
    --z-toast: 110;
}

@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) {
        --paper: #0F0F1C; --surface: #17172A; --sunken: #121224;
        --ink: #F4F1EA; --ink-2: #C4C2D0; --ink-3: #9C9AAE;
        --line: #2A2A45; --line-strong: #4A4A6A;
        --brand: #FF7A4D; --brand-hover: #FF9A73;
        --brand-ink: #FF9A73; --brand-ink-strong: #FFB596;
        --brand-tint: rgba(255, 122, 77, 0.14); --brand-tint-2: rgba(255, 122, 77, 0.28);
        --focus: #FFB08A; --scrim: rgba(0, 0, 0, 0.62); --selection: rgba(255, 122, 77, 0.35);
        --code-bg: #0B0B16; --code-bg-2: #151528; --code-line: #26264A;
        --get-text: #7DB8FF; --get-bg: #0F2238; --get-line: #1F3B5E;
        --post-text: #5FD6A5; --post-bg: #0E2A20; --post-line: #1D4A39;
        --put-text: #F2C14E; --put-bg: #2C2208; --put-line: #4D3C12;
        --del-text: #FF8E84; --del-bg: #35130F; --del-line: #5C221B;
        --muted-bg: #1C1C33;
        --shadow-1: 0 1px 2px rgba(0, 0, 0, 0.45);
        --shadow-2: 0 4px 12px -2px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.45);
        --shadow-pop: 0 24px 48px -12px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.06);
    }
}

:root[data-theme="dark"] {
    --paper: #0F0F1C; --surface: #17172A; --sunken: #121224;
    --ink: #F4F1EA; --ink-2: #C4C2D0; --ink-3: #9C9AAE;
    --line: #2A2A45; --line-strong: #4A4A6A;
    --brand: #FF7A4D; --brand-hover: #FF9A73;
    --brand-ink: #FF9A73; --brand-ink-strong: #FFB596;
    --brand-tint: rgba(255, 122, 77, 0.14); --brand-tint-2: rgba(255, 122, 77, 0.28);
    --focus: #FFB08A; --scrim: rgba(0, 0, 0, 0.62); --selection: rgba(255, 122, 77, 0.35);
    --code-bg: #0B0B16; --code-bg-2: #151528; --code-line: #26264A;
    --get-text: #7DB8FF; --get-bg: #0F2238; --get-line: #1F3B5E;
    --post-text: #5FD6A5; --post-bg: #0E2A20; --post-line: #1D4A39;
    --put-text: #F2C14E; --put-bg: #2C2208; --put-line: #4D3C12;
    --del-text: #FF8E84; --del-bg: #35130F; --del-line: #5C221B;
    --muted-bg: #1C1C33;
    --shadow-1: 0 1px 2px rgba(0, 0, 0, 0.45);
    --shadow-2: 0 4px 12px -2px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.45);
    --shadow-pop: 0 24px 48px -12px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.06);
}

/* ------------------------------------------------------------ base */

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

html {
    scroll-behavior: smooth;
    /* the one offset for every anchor: topbar plus breathing room */
    scroll-padding-top: 80px;
    -webkit-text-size-adjust: 100%;
    scrollbar-gutter: stable;
}

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink-2);
    font-family: var(--font-sans);
    font-size: 16px;
    line-height: 1.75;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    text-rendering: optimizeLegibility;
    /* clip, not hidden: hidden would turn body into a scroll container and
       break the sticky sidebar, topbar and TOC */
    overflow-x: clip;
}

::selection { background: var(--selection); color: var(--ink); }

a { color: var(--brand-ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--brand-ink-strong); text-decoration-thickness: 2px; }

:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

code, kbd, pre { font-family: var(--font-mono); }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.i { display: inline-block; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; vertical-align: middle; }

.sr-only {
    position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

.skip-link {
    position: fixed; top: 8px; left: 8px; z-index: var(--z-toast);
    padding: 8px 14px; border-radius: 8px; background: var(--ink); color: var(--paper);
    font-weight: 700; text-decoration: none; transform: translateY(-160%);
}
.skip-link:focus { transform: none; }

.kbd {
    display: inline-flex; align-items: center; justify-content: center; gap: 2px;
    min-width: 22px; height: 22px; padding: 0 6px; border-radius: 6px;
    border: 1px solid var(--line); background: var(--sunken); color: var(--ink-2);
    font: 600 12px/1 var(--font-mono);
}

.icon-btn {
    display: inline-flex; align-items: center; justify-content: center;
    width: 36px; height: 36px; padding: 0; border: 1px solid transparent; border-radius: 8px;
    background: transparent; color: var(--ink-2); cursor: pointer;
    transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.icon-btn:hover { background: var(--sunken); color: var(--ink); }

/* ------------------------------------------------------------ shell */

.shell { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); min-height: 100dvh; }
.page { min-width: 0; display: flex; flex-direction: column; }
.page-body { display: grid; grid-template-columns: minmax(0, 1fr); align-items: start; }

/* ------------------------------------------------------------ sidebar */

.sidebar {
    position: sticky; top: 0; height: 100dvh;
    display: flex; flex-direction: column;
    background: var(--sunken); border-right: 1px solid var(--line);
    z-index: var(--z-sticky);
}

.sidebar-head {
    display: flex; align-items: center; gap: 10px;
    height: 64px; padding: 0 16px; flex: none;
    border-bottom: 1px solid var(--line);
}

.brand { display: inline-flex; align-items: center; gap: 8px; min-width: 0; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand-mark { width: 28px; height: 28px; flex: none; overflow: visible; display: block; }
.wordmark { font-weight: 800; font-size: 18px; line-height: 1; letter-spacing: -0.01em; white-space: nowrap; color: var(--ink); }
.wordmark-accent { color: var(--brand); }

.version-badge {
    margin-left: auto; flex: none; white-space: nowrap;
    display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: 999px;
    background: var(--brand-tint); border: 1px solid var(--brand-tint-2); color: var(--brand-ink-strong);
    font: 700 12px/1 var(--font-mono); font-variant-numeric: tabular-nums; text-decoration: none;
}
.version-badge:hover { color: var(--brand-ink-strong); border-color: var(--brand); text-decoration: none; }

.drawer-close { display: none; }

.sidebar-search { padding: 16px 16px 4px; flex: none; }

.search-trigger {
    display: flex; align-items: center; gap: 8px; width: 100%; height: 40px;
    padding: 0 10px 0 12px; border-radius: 10px;
    background: var(--surface); border: 1px solid var(--line-strong); box-shadow: var(--shadow-1);
    color: var(--ink-3); font: 600 14px/1 var(--font-sans); cursor: pointer; text-align: left;
    transition: border-color var(--dur-fast) var(--ease-out);
}
.search-trigger:hover { border-color: var(--ink-3); }
.search-trigger:active { transform: translateY(1px); }
.search-trigger-label { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kbd-group { display: inline-flex; gap: 4px; flex: none; }

.sidebar-nav { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 16px 16px; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }

.nav-group + .nav-group { margin-top: 4px; }

.nav-cat {
    display: flex; align-items: center; gap: 8px; width: 100%; height: 36px; margin-top: 12px;
    padding: 0 12px; border: 0; border-radius: 8px; background: transparent; cursor: pointer;
    color: var(--ink-3); text-align: left;
}
.nav-cat:hover { color: var(--ink); }
.nav-cat-label { flex: 1; font: 800 12px/16px var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; }
.nav-chevron { transition: transform var(--dur) var(--ease-out); }
.nav-group.is-open .nav-chevron { transform: rotate(90deg); }

.nav-panel { display: grid; grid-template-rows: 1fr; transition: grid-template-rows 200ms var(--ease-out), visibility 0s; }
.nav-panel > .nav-list { overflow: hidden; min-height: 0; }
.js .nav-group:not(.is-open) .nav-panel { grid-template-rows: 0fr; visibility: hidden; transition: grid-template-rows 200ms var(--ease-out), visibility 0s 200ms; }

.nav-list { list-style: none; margin: 0; padding: 2px 0 0; }

.nav-link {
    position: relative; display: flex; align-items: center; gap: 6px;
    min-height: 36px; padding: 6px 10px 6px 8px; border-radius: 8px;
    color: var(--ink-2); font: 600 14px/20px var(--font-sans); text-decoration: none;
    transition: background var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.nav-link:hover { background: var(--surface); color: var(--ink); text-decoration: none; }
.nav-slash { width: 14px; height: 12px; flex: none; }
.nav-text { flex: 1; min-width: 0; }
.nav-badge { flex: none; display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 999px; background: var(--brand-tint); border: 1px solid var(--brand-tint-2); color: var(--brand-ink-strong); font: 700 11px/1 var(--font-sans); }
.nav-method { flex: none; font: 700 11px/1 var(--font-mono); letter-spacing: 0.02em; }
.m-get { color: var(--get-text); }
.m-post { color: var(--post-text); }
.m-put, .m-patch { color: var(--put-text); }
.m-delete { color: var(--del-text); }

.nav-link[aria-current="location"] { background: var(--brand-tint); color: var(--brand-ink-strong); font-weight: 700; }
.nav-link[aria-current="location"] .nav-slash,
.toc-link.is-active::before {
    background:
        linear-gradient(var(--brand), var(--brand)) 0 0 / 3px 100% no-repeat,
        linear-gradient(var(--brand), var(--brand)) 6px 0 / 3px 100% no-repeat;
    transform: skewX(-24deg);
}

.sidebar-foot { flex: none; display: flex; flex-direction: column; gap: 2px; padding: 12px 16px 16px; border-top: 1px solid var(--line); }
.foot-link { display: flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 12px; border-radius: 8px; color: var(--ink-2); font: 600 14px/20px var(--font-sans); text-decoration: none; }
.foot-link:hover { background: var(--surface); color: var(--ink); text-decoration: none; }

/* ------------------------------------------------------------ topbar */

.topbar {
    position: sticky; top: 0; z-index: var(--z-topbar);
    display: flex; align-items: center; gap: 12px; height: var(--topbar-h); padding: 0 24px 0 48px;
    background: color-mix(in srgb, var(--paper) 92%, transparent);
    border-bottom: 1px solid var(--line);
    -webkit-backdrop-filter: saturate(140%) blur(8px); backdrop-filter: saturate(140%) blur(8px);
}
.menu-btn, .brand-top, .search-icon-btn { display: none; }
.crumbs { display: flex; align-items: center; gap: 8px; min-width: 0; font: 600 14px/20px var(--font-sans); color: var(--ink-3); white-space: nowrap; overflow: hidden; }
.crumb { overflow: hidden; text-overflow: ellipsis; }
.crumb-sep { color: var(--brand); font-weight: 800; transform: skewX(-10deg); }
.crumb-current { color: var(--ink); }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; flex: none; }
.btn-ghost {
    display: inline-flex; align-items: center; height: 36px; padding: 0 14px; border-radius: 8px;
    border: 1px solid var(--line-strong); color: var(--ink); background: transparent;
    font: 700 14px/1 var(--font-sans); text-decoration: none; white-space: nowrap;
}
.btn-ghost:hover { border-color: var(--ink-3); background: var(--surface); color: var(--ink); text-decoration: none; }

.theme-sun { display: none; }
:root[data-theme="dark"] .theme-sun { display: inline-block; }
:root[data-theme="dark"] .theme-moon { display: none; }
@media (prefers-color-scheme: dark) {
    :root:not([data-theme="light"]) .theme-sun { display: inline-block; }
    :root:not([data-theme="light"]) .theme-moon { display: none; }
}

/* ------------------------------------------------------------ article */

.article { min-width: 0; width: 100%; max-width: calc(var(--content-max) + 96px); margin: 0 auto; padding: 40px 48px 64px; outline: none; }

.section { padding-top: 24px; }
.section + .section { margin-top: 40px; border-top: 1px solid var(--line); padding-top: 48px; }

h1, h2, h3, h4 { color: var(--ink); font-family: var(--font-sans); text-wrap: balance; }
h1 { margin: 0 0 16px; font-size: 40px; line-height: 48px; font-weight: 800; letter-spacing: -0.02em; }
h2 { margin: 0 0 16px; font-size: 28px; line-height: 36px; font-weight: 800; letter-spacing: -0.015em; }
h3 { margin: 40px 0 12px; font-size: 20px; line-height: 28px; font-weight: 700; letter-spacing: -0.01em; }
/* headings receive focus only programmatically, after a jump */
h1[tabindex="-1"]:focus, h2[tabindex="-1"]:focus, h3[tabindex="-1"]:focus { outline: none; }
.heading-anchor {
    display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-left: 6px;
    border: 0; border-radius: 6px; background: transparent; color: var(--ink-3); cursor: pointer; vertical-align: middle;
    opacity: 0; transition: opacity var(--dur-fast) var(--ease-out);
}
h2:hover .heading-anchor, h3:hover .heading-anchor, .heading-anchor:focus-visible { opacity: 1; }
.heading-anchor:hover { color: var(--brand-ink); background: var(--sunken); }

p { margin: 0 0 16px; max-width: 72ch; }
strong { color: var(--ink); font-weight: 700; }
ul, ol { margin: 0 0 16px; padding-left: 22px; max-width: 72ch; }
li { margin: 4px 0; }
li::marker { color: var(--ink-3); }

:not(pre) > code, .code-link code {
    padding: 1px 6px; border-radius: 6px; border: 1px solid var(--line); background: var(--sunken);
    color: var(--ink); font-size: 0.86em; font-weight: 500; overflow-wrap: anywhere; word-break: normal;
}
.code-link { text-decoration: none; }
.code-link code { color: var(--brand-ink); border-color: var(--brand-tint-2); }
.code-link:hover code { background: var(--brand-tint); }

.intro-lead { font-size: 18px; line-height: 30px; color: var(--ink-2); }
.lead-who { padding: 12px 16px; border-radius: 12px; background: var(--sunken); border: 1px solid var(--line); }

.modes { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin: 8px 0 24px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); overflow: hidden; }
.mode { padding: 20px; }
.mode + .mode { border-left: 1px solid var(--line); }
.mode p { margin: 0; font-size: 15px; line-height: 24px; }
.mode .mode-name { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: var(--ink); font-weight: 800; font-size: 16px; }
.mode .mode-name .i { color: var(--brand); }

.base-url { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 0 0 16px; padding: 10px 10px 10px 16px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.base-url-label { font: 800 12px/16px var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.base-url .base-url-value { flex: 1 1 auto; min-width: max-content; white-space: nowrap; overflow-wrap: normal; border: 0; background: none; padding: 0; font-size: 15px; color: var(--ink); }
.intro-sub { margin-top: 48px; font-size: 22px; line-height: 30px; }

.entry-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.entry-card {
    display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 14px; row-gap: 2px;
    padding: 18px 20px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
    text-decoration: none; color: var(--ink-2);
    transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.entry-card:hover { border-color: var(--ink-3); box-shadow: var(--shadow-1); text-decoration: none; color: var(--ink-2); }
.entry-icon { grid-row: 1 / span 2; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; background: var(--brand-tint); color: var(--brand-ink-strong); }
.entry-title { color: var(--ink); font-weight: 800; line-height: 24px; }
.entry-text { font-size: 14px; line-height: 20px; }

.section-head { display: flex; align-items: flex-start; gap: 12px; }
.section-head h1, .section-head h2 { flex: 1; min-width: 0; }
.md-btn {
    display: inline-flex; align-items: center; gap: 6px; flex: none; margin-top: 4px;
    height: 32px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface);
    color: var(--ink-3); font: 600 13px/1 var(--font-sans); cursor: pointer;
    transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.md-btn:hover { color: var(--ink); border-color: var(--line-strong); }
.md-btn .check-icon { display: none; }
.md-btn.is-copied { color: var(--post-text); border-color: var(--post-line); }
.md-btn.is-copied .check-icon { display: inline-block; }
.md-btn.is-copied .copy-icon { display: none; }
.section-intro .md-btn { margin-top: 8px; }
.btn-llm { gap: 6px; font-family: var(--font-mono); font-weight: 500; font-size: 13px; color: var(--ink-2); }

/* ------------------------------------------------------------ endpoint */

.endpoint {
    margin: 0 0 24px; padding: 16px 20px; border-radius: 12px;
    background: var(--surface); border: 1px solid var(--line);
}
.endpoint-row { display: flex; align-items: center; gap: 12px; min-width: 0; }
.endpoint-path { flex: 1; min-width: 0; color: var(--ink); font: 500 15px/24px var(--font-mono); overflow-wrap: anywhere; }
.endpoint .endpoint-path { padding: 0; border: 0; background: none; font-size: 15px; }
.path-var { color: var(--brand-ink); font-weight: 700; }
.copy-path { flex: none; }

.method {
    display: inline-flex; align-items: center; height: 24px; padding: 0 8px; border-radius: 6px; flex: none;
    font: 700 12px/1 var(--font-mono); letter-spacing: 0.02em; border: 1px solid;
}
.method-sm { height: 20px; padding: 0 6px; font-size: 11px; }
.method-get { color: var(--get-text); background: var(--get-bg); border-color: var(--get-line); }
.method-post { color: var(--post-text); background: var(--post-bg); border-color: var(--post-line); }
.method-put, .method-patch { color: var(--put-text); background: var(--put-bg); border-color: var(--put-line); }
.method-delete { color: var(--del-text); background: var(--del-bg); border-color: var(--del-line); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 12px 0 0; padding: 0; max-width: none; }
.chip {
    display: inline-flex; align-items: center; gap: 6px; min-height: 28px; margin: 0; padding: 2px 10px; border-radius: 999px;
    background: var(--sunken); border: 1px solid var(--line); color: var(--ink-2); font: 600 12px/18px var(--font-sans);
}
.chip .i { color: var(--ink-3); }
.chip code { font-size: 11px !important; padding: 0 4px !important; }

.ep-row { display: flex; align-items: flex-start; gap: 12px; flex-wrap: wrap; margin: 0 0 24px; }
.ep-row-label { font: 800 12px/28px var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.ep-chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; flex: 1; min-width: 0; }
.ep-chips li { margin: 0; min-width: 0; }
.ep-chip {
    display: inline-flex; align-items: center; gap: 8px; min-height: 32px; max-width: 100%; padding: 4px 10px 4px 6px; border-radius: 8px;
    background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none;
}
a.ep-chip:hover { border-color: var(--ink-3); text-decoration: none; color: var(--ink); }
.ep-chip code { padding: 0 !important; border: 0 !important; background: none !important; font-size: 13px !important; color: var(--ink) !important; }

/* ------------------------------------------------------------ tables */

.table-wrap { margin: 0 0 24px; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 22px; font-variant-numeric: tabular-nums; }
th {
    padding: 10px 14px; text-align: left; background: var(--sunken); color: var(--ink-3); border-bottom: 1px solid var(--line);
    font: 800 12px/16px var(--font-sans); letter-spacing: 0.06em; text-transform: uppercase; white-space: nowrap;
}
th code { text-transform: none; letter-spacing: 0; }
td { padding: 12px 14px; vertical-align: top; border-bottom: 1px solid var(--line); color: var(--ink-2); }
tr:last-child td { border-bottom: 0; }
td:first-child { color: var(--ink); }

.params .param-name { width: 28%; font-family: var(--font-mono); font-weight: 600; }
.params .param-name code { font-size: 13px; }
.params .param-type { width: 14%; font: 400 12px/22px var(--font-mono); color: var(--ink-3); }
.param-loc { display: inline-block; margin-left: 4px; padding: 0 6px; border-radius: 6px; background: var(--muted-bg); color: var(--ink-3); font: 600 11px/18px var(--font-mono); }

.req { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 999px; font: 700 12px/1 var(--font-sans); white-space: nowrap; border: 1px solid transparent; }
.req-dot { width: 7px; height: 7px; border-radius: 50%; }
.req-yes { background: var(--brand-tint); color: var(--brand-ink-strong); border-color: var(--brand-tint-2); }
.req-yes .req-dot { background: currentColor; }
.req-no { background: var(--sunken); color: var(--ink-3); border-color: var(--line); }
.req-no .req-dot { border: 1.5px solid currentColor; }

.http { display: inline-flex; align-items: center; height: 22px; padding: 0 7px; border-radius: 6px; font: 700 12px/1 var(--font-mono); border: 1px solid; }
.http.s2 { color: var(--post-text); background: var(--post-bg); border-color: var(--post-line); }
.http.s4 { color: var(--put-text); background: var(--put-bg); border-color: var(--put-line); }
.http.s5 { color: var(--del-text); background: var(--del-bg); border-color: var(--del-line); }

.state { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px 2px 8px; border-radius: 999px; border: 1px solid; white-space: nowrap; }
.state code { padding: 0 !important; border: 0 !important; background: none !important; color: inherit !important; font-weight: 700 !important; }
.state-pending, .state-awaiting-confirmation { color: var(--put-text); background: var(--put-bg); border-color: var(--put-line); }
.state-paid { color: var(--post-text); background: var(--post-bg); border-color: var(--post-line); }
.state-expired { color: var(--ink-3); background: var(--sunken); border-color: var(--line); }
.state-cancelled { color: var(--del-text); background: var(--del-bg); border-color: var(--del-line); }

/* ------------------------------------------------------------ code */

.code-block {
    margin: 0 0 24px; border-radius: 12px; overflow: hidden;
    background: var(--code-bg); border: 1px solid var(--code-line); color: var(--code-text);
}
.code-bar {
    display: flex; align-items: center; gap: 8px; min-height: 44px; padding: 6px 8px 6px 12px;
    background: var(--code-bg-2); border-bottom: 1px solid var(--code-line);
}
.code-label { flex: none; padding-right: 4px; color: var(--code-muted); font: 700 12px/1 var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; }
.code-tabs { display: flex; gap: 4px; flex: 1; min-width: 0; overflow-x: auto; scrollbar-width: none; }
.code-tabs::-webkit-scrollbar { display: none; }
.code-tab {
    position: relative; display: inline-flex; align-items: center; gap: 6px; flex: none;
    height: 32px; padding: 0 12px; border: 0; border-radius: 8px; background: transparent; cursor: pointer;
    color: var(--code-muted); font: 600 13px/1 var(--font-sans); white-space: nowrap;
}
.code-tab:hover { color: var(--code-text); }
.code-tab[aria-selected="true"] { background: var(--code-selected-bg); color: var(--code-selected-text); font-weight: 700; }
.code-tab[aria-selected="true"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px; border-radius: 2px; background: var(--brand); }
.code-block :focus-visible { outline-color: var(--code-focus); }
.res-tab { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.res-desc { font-family: var(--font-sans); font-weight: 600; opacity: 0.85; }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.dot.s2 { background: var(--dot-2xx); }
.dot.s4 { background: var(--dot-4xx); }
.dot.s5 { background: var(--dot-5xx); }

.copy-btn {
    display: inline-flex; align-items: center; gap: 6px; flex: none; margin-left: auto;
    height: 32px; padding: 0 10px; border: 0; border-radius: 8px; background: transparent; cursor: pointer;
    color: var(--code-muted); font: 600 13px/1 var(--font-sans);
}
.copy-btn:hover { color: var(--code-text); background: var(--code-selected-bg); }
.copy-btn .check-icon, .copy-path .check-icon { display: none; }
.copy-btn.is-copied, .copy-path.is-copied { color: var(--code-string); }
.copy-btn.is-copied .check-icon, .copy-path.is-copied .check-icon { display: inline-block; }
.copy-btn.is-copied .copy-icon, .copy-path.is-copied .copy-icon { display: none; }
.copy-path.is-copied { color: var(--post-text); }
.copy-btn-light { color: var(--ink-2); border: 1px solid var(--line-strong); background: var(--surface); }
.copy-btn-light:hover { color: var(--ink); background: var(--sunken); }
.copy-btn-light.is-copied { color: var(--post-text); }

.code-panel pre {
    margin: 0; padding: 16px 20px; overflow-x: auto; tab-size: 2;
    font: 400 13.5px/22px var(--font-mono); color: var(--code-text); white-space: pre;
    scrollbar-width: thin; scrollbar-color: var(--code-line) transparent;
}
.code-panel pre::selection, .code-panel pre *::selection { background: var(--code-selection); color: var(--code-selected-text); }
.code-panel code { font: inherit; }
.comment { color: var(--code-muted); font-style: italic; }
.string { color: var(--code-string); }
.number { color: var(--code-number); }
.keyword { color: var(--code-keyword); }
.property { color: var(--code-prop); }
.function { color: var(--code-func); }

.res-head { display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 8px 20px 0; color: var(--code-muted); font: 500 12px/20px var(--font-mono); }
.res-cause { margin: 12px 20px 0; max-width: none; color: var(--code-text); font-size: 13px; line-height: 20px; }
.res-cause + pre { padding-top: 8px; }
.res-cause code, .res-note code { background: var(--code-selected-bg) !important; border-color: var(--code-line) !important; color: var(--code-text) !important; }
.res-note { display: flex; gap: 8px; margin: 0; max-width: none; padding: 12px 20px 16px; border-top: 1px solid var(--code-line); color: var(--code-text); font: 600 14px/22px var(--font-sans); }
.res-note .i { margin-top: 3px; color: var(--code-number); }

/* ------------------------------------------------------------ MCP */

/* Ten agents do not fit one row, so the tabs wrap instead of hiding behind a swipe. */
.code-tabs-wrap { flex-wrap: wrap; overflow: visible; }
.code-bar:has(.code-tabs-wrap) { align-items: flex-start; }
.panel-note { margin: 0; max-width: none; padding: 14px 20px 0; color: var(--code-text); font: 500 14px/22px var(--font-sans); }
.panel-note + pre { padding-top: 10px; }
.panel-note:not(:first-child) { padding-top: 4px; }
.panel-note code { background: var(--code-selected-bg) !important; border-color: var(--code-line) !important; color: var(--code-text) !important; }
.panel-note a { color: inherit; text-decoration: underline; }
.panel-note:last-child { padding-bottom: 16px; }
.nav-cat .pill-new { margin-left: 8px; }
/* Keep X-API-Key and friends in one piece inside the step text. */
section[id^="mcp"] .steps code { white-space: nowrap; }
.mcp-tools td > code:first-child { white-space: nowrap; font-weight: 700; }
.mcp-tools .mcp-ep { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 6px; }
.mcp-tools .mcp-ep code { overflow-wrap: anywhere; }
.mcp-tools td:not(:first-child) { white-space: nowrap; }
@media (max-width: 720px) {
    .mcp-tools tr { display: flex; flex-wrap: wrap; column-gap: 20px; }
    .mcp-tools td:first-child { flex: 1 0 100%; min-width: 0; }
}

/* ------------------------------------------------------------ callouts */

.callout {
    display: flex; gap: 12px; margin: 0 0 24px; padding: 16px 20px; border-radius: 12px; border: 1px solid;
    font-size: 14px; line-height: 22px;
}
.callout-icon { margin-top: 1px; }
.callout-body { min-width: 0; }
.callout-body p { margin: 0 0 6px; }
.callout-body p:last-child { margin-bottom: 0; }
.callout-title { font-weight: 800; }
.callout a { color: inherit; text-decoration: underline; }
.callout-info { background: var(--get-bg); border-color: var(--get-line); color: var(--get-text); }
.callout-tips { background: var(--post-bg); border-color: var(--post-line); color: var(--post-text); }
.callout-warning { background: var(--put-bg); border-color: var(--put-line); color: var(--put-text); }
.callout-danger { background: var(--del-bg); border-color: var(--del-line); color: var(--del-text); }
.callout-sandbox { background: var(--brand-tint); border-color: var(--brand-tint-2); color: var(--brand-ink-strong); }
.callout strong, .callout-title { color: inherit; }
.callout :not(pre) > code { color: inherit; background: var(--surface); border-color: currentColor; border-color: color-mix(in srgb, currentColor 30%, transparent); }

/* ------------------------------------------------------------ steps */

.steps { list-style: none; padding: 0; margin: 0 0 24px; counter-reset: none; }
.steps > li { position: relative; display: flex; gap: 14px; margin: 0; padding-bottom: 16px; }
.steps > li::before {
    content: ""; position: absolute; left: 13.5px; top: 30px; bottom: 0; width: 1px; background: var(--line-strong);
}
.steps > li:last-child { padding-bottom: 0; }
.steps > li:last-child::before { display: none; }
.step-mark {
    position: relative; z-index: 1; display: inline-flex; align-items: center; justify-content: center; flex: none;
    width: 28px; height: 28px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line-strong);
    color: var(--ink); font: 700 13px/1 var(--font-mono);
}
.step-done { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.step-body { min-width: 0; padding-top: 2px; }
.step-body p { margin: 0; }
.step-title { color: var(--ink); font-weight: 800; }

.checklist { list-style: none; padding: 0; }
.checklist li { display: flex; gap: 10px; align-items: flex-start; }
.check-box { margin-top: 4px; color: var(--post-text); }

.lifecycle { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 0 0 24px; max-width: none; }
.lifecycle li { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.lifecycle li:not(.lc-arrow) { height: 40px; padding: 0 14px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line-strong); color: var(--ink); font-weight: 700; font-size: 14px; }
.lifecycle li:not(.lc-arrow) .i { color: var(--brand); }
.lc-arrow { color: var(--ink-3); }

.uc-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0 0 24px; }
.uc-card {
    display: flex; flex-direction: column; gap: 6px; padding: 20px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line);
    color: var(--ink-2); text-decoration: none; transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.uc-card:hover { border-color: var(--ink-3); box-shadow: var(--shadow-1); text-decoration: none; color: var(--ink-2); }
.uc-icon { color: var(--brand); margin-bottom: 6px; }
.uc-title { color: var(--ink); font-weight: 800; line-height: 22px; }
.uc-text { font-size: 14px; line-height: 20px; flex: 1; }
.uc-go { display: inline-flex; align-items: center; gap: 6px; margin-top: 6px; color: var(--brand-ink); font-weight: 700; font-size: 14px; }

.widget-preview { margin: 0 0 24px; padding: 28px 20px 16px; border-radius: 12px; border: 1px dashed var(--line-strong); background: var(--surface); text-align: center; }
.widget-demo-btn {
    display: inline-flex; align-items: center; gap: 10px; padding: 14px 28px; border-radius: 50px;
    background: #FF6B35; color: #FFFFFF; border: 3px solid #1A1A2E; box-shadow: 4px 4px 0 #1A1A2E; font-weight: 700; font-size: 15px;
}
.widget-preview figcaption { margin-top: 14px; color: var(--ink-3); font-size: 13px; }

/* ------------------------------------------------------------ changelog */

.cl-entry { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: 40px; padding: 32px 0; }
.cl-entry + .cl-entry { border-top: 1px solid var(--line); }
.cl-meta { position: sticky; top: 88px; align-self: start; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.cl-version { color: var(--ink); font: 700 18px/24px var(--font-mono); font-variant-numeric: tabular-nums; }
.cl-meta time { color: var(--ink-3); font-size: 14px; }
.pill-new { display: inline-flex; height: 22px; align-items: center; padding: 0 8px; border-radius: 999px; background: var(--brand-tint); border: 1px solid var(--brand-tint-2); color: var(--brand-ink-strong); font: 700 12px/1 var(--font-sans); }
.cl-content h3 { margin-top: 0; }
.cl-group { margin-bottom: 20px; }
.cl-group ul { margin: 10px 0 0; }
.cl-type { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; border: 1px solid; font: 700 12px/1 var(--font-sans); }
.cl-added { color: var(--post-text); background: var(--post-bg); border-color: var(--post-line); }
.cl-changed { color: var(--get-text); background: var(--get-bg); border-color: var(--get-line); }
.cl-fixed { color: var(--put-text); background: var(--put-bg); border-color: var(--put-line); }

.article-foot { margin-top: 64px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; }
.article-updated { color: var(--ink-3); }

/* ------------------------------------------------------------ toc */

.toc { display: none; }
.toc-title { margin: 0 0 8px; color: var(--ink-3); font: 800 12px/16px var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; }
.toc-list { list-style: none; margin: 0; padding: 0; max-width: none; }
.toc-list li { margin: 0; }
.toc-list ol { list-style: none; margin: 0; padding: 0 0 0 12px; }
.toc-link { position: relative; display: block; padding: 4px 0 4px 16px; color: var(--ink-3); font: 600 13px/20px var(--font-sans); text-decoration: none; }
.toc-link::before { content: ""; position: absolute; left: 2px; top: 9px; width: 9px; height: 11px; }
.toc-link:hover { color: var(--ink); text-decoration: none; }
.toc-link.is-active { color: var(--brand-ink); font-weight: 800; }
.toc-top { display: inline-flex; align-items: center; gap: 6px; margin-top: 16px; padding: 4px 0; border: 0; background: none; color: var(--ink-3); font: 600 13px/20px var(--font-sans); cursor: pointer; }
.toc-top:hover { color: var(--ink); }

@media (min-width: 1280px) {
    .page-body { grid-template-columns: minmax(0, 1fr) var(--toc-w); }
    .toc {
        display: block; position: sticky; top: calc(var(--topbar-h) + 32px);
        max-height: calc(100dvh - var(--topbar-h) - 56px); overflow-y: auto; padding: 32px 24px 24px 0;
        scrollbar-width: thin;
    }
    .article { padding-left: 48px; padding-right: 48px; }
}

/* ------------------------------------------------------------ palette */

.palette { position: fixed; inset: 0; z-index: var(--z-palette); }
.palette[hidden] { display: none; }
.palette-scrim { position: absolute; inset: 0; background: var(--scrim); z-index: var(--z-palette-scrim); animation: fade-in 160ms var(--ease-out); }
.palette-box {
    position: relative; z-index: var(--z-palette);
    width: min(640px, calc(100vw - 32px)); margin: 12vh auto 0; border-radius: 16px; overflow: hidden;
    background: var(--surface); box-shadow: var(--shadow-pop); display: flex; flex-direction: column; max-height: 76vh;
    animation: pop-in 160ms var(--ease-out);
}
.palette.is-closing .palette-box { animation: pop-out 110ms ease-in forwards; }
.palette.is-closing .palette-scrim { animation: fade-out 110ms ease-in forwards; }
.palette-input-row { display: flex; align-items: center; gap: 10px; height: 56px; padding: 0 16px; border-bottom: 1px solid var(--line); flex: none; }
.palette-search-icon { color: var(--ink-3); }
.palette-input { flex: 1; min-width: 0; height: 100%; border: 0; outline: none; background: transparent; color: var(--ink); font: 600 16px/1 var(--font-sans); }
.palette-input::placeholder { color: var(--ink-3); }
.palette-close { display: none; }
.palette-list { overflow-y: auto; max-height: min(60vh, 420px); padding: 8px; overscroll-behavior: contain; }
.palette-group + .palette-group { margin-top: 8px; }
.palette-group-label { padding: 8px 12px 4px; color: var(--ink-3); font: 800 12px/16px var(--font-sans); letter-spacing: 0.08em; text-transform: uppercase; }
.palette-row { display: flex; align-items: center; gap: 12px; min-height: 44px; padding: 6px 12px; border-radius: 8px; color: var(--ink-2); cursor: pointer; }
.palette-row[aria-selected="true"] { background: var(--brand-tint); color: var(--ink); }
.palette-list:focus-within .palette-row[aria-selected="true"], .palette.kbd-nav .palette-row[aria-selected="true"] { box-shadow: inset 0 0 0 2px var(--brand-tint-2); }
.palette-row-icon { color: var(--ink-3); }
.palette-row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.palette-row-title { color: var(--ink); font: 700 14px/20px var(--font-sans); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-row-path { font: 500 12px/18px var(--font-mono); color: var(--ink-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.palette-row-cat { flex: none; color: var(--ink-3); font: 600 12px/1 var(--font-sans); }
.palette-row mark { background: none; color: var(--brand-ink); font-weight: 800; }
.palette-empty { margin: 0; padding: 24px 20px; max-width: none; color: var(--ink-2); font-size: 14px; }
.palette-empty code { font-size: 13px; }
.palette-foot { display: flex; gap: 16px; align-items: center; height: 40px; padding: 0 16px; background: var(--sunken); border-top: 1px solid var(--line); color: var(--ink-3); font: 600 12px/1 var(--font-sans); flex: none; }
.palette-foot span { display: inline-flex; align-items: center; gap: 4px; }
.palette-foot .kbd { height: 20px; min-width: 20px; padding: 0 4px; }

@keyframes pop-in { from { opacity: 0; transform: scale(0.98); } to { opacity: 1; transform: none; } }
@keyframes pop-out { to { opacity: 0; transform: scale(0.98); } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes fade-out { to { opacity: 0; } }

/* ------------------------------------------------------------ toast */

.toast {
    position: fixed; left: 50%; bottom: 24px; z-index: var(--z-toast);
    display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border-radius: 10px;
    background: var(--ink); color: var(--paper); box-shadow: var(--shadow-2); font: 700 14px/1 var(--font-sans);
    transform: translate(-50%, 16px); opacity: 0; pointer-events: none;
    transition: opacity var(--dur) var(--ease-out), transform var(--dur) var(--ease-out);
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ------------------------------------------------------------ responsive */

@media (max-width: 1279px) {
    .article { padding-left: 40px; padding-right: 40px; }
}

@media (max-width: 1023px) {
    .shell { display: block; }
    .sidebar {
        position: fixed; top: 0; bottom: 0; left: 0; height: 100dvh; width: min(88vw, 340px);
        z-index: var(--z-drawer); background: var(--paper); border-right: 0; border-radius: 0 16px 16px 0;
        box-shadow: var(--shadow-pop); transform: translateX(-104%); visibility: hidden;
        transition: transform 170ms ease-in, visibility 0s 170ms;
    }
    .sidebar.is-open { transform: translateX(0); visibility: visible; transition: transform var(--dur-slow) var(--ease-out), visibility 0s; }
    .drawer-close { display: inline-flex; flex: none; width: 44px; height: 44px; margin-right: -8px; }
    .version-badge { margin-left: auto; }
    .drawer-scrim { position: fixed; inset: 0; z-index: var(--z-scrim); background: var(--scrim); animation: fade-in var(--dur) var(--ease-out); }
    .drawer-scrim[hidden] { display: none; }
    .topbar { padding: 0 12px; gap: 8px; }
    .menu-btn, .search-icon-btn { display: inline-flex; width: 44px; height: 44px; }
    .brand-top { display: inline-flex; }
    .crumbs { display: none; }
    .btn-ghost { display: none; }
    .md-btn { width: 44px; height: 44px; justify-content: center; padding: 0; margin-top: -4px; }
    .md-btn .copy-label { display: none; }
    .theme-btn { width: 44px; height: 44px; }
    .article { padding: 32px 24px 56px; }
    .nav-link { min-height: 44px; }
    .foot-link { min-height: 44px; }
}

@media (max-width: 720px) {
    .modes { grid-template-columns: 1fr; }
    .mode + .mode { border-left: 0; border-top: 1px solid var(--line); }
    .entry-cards, .uc-cards { grid-template-columns: 1fr; }

    .table-wrap { border: 0; background: none; border-radius: 0; overflow: visible; }
    .table-wrap table, .table-wrap thead, .table-wrap tbody, .table-wrap tr, .table-wrap td { display: block; width: auto; }
    .table-wrap thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
    .table-wrap tr { margin: 0 0 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
    .table-wrap td { padding: 4px 0; border: 0; }
    .table-wrap td::before { content: attr(data-label); display: block; color: var(--ink-3); font: 800 11px/16px var(--font-sans); letter-spacing: 0.06em; text-transform: uppercase; }
    .table-wrap td:first-child::before { display: none; }
    .table-wrap td:first-child { font-weight: 700; padding-bottom: 6px; }
    .params .param-name, .params .param-type { width: auto; }
    .params td[data-label="Tipe"], .params td[data-label="Status"] { display: inline-flex; align-items: center; gap: 8px; margin-right: 12px; }
    .params td[data-label="Tipe"]::before, .params td[data-label="Status"]::before { display: none; }
    .empty-cell::after { content: "-"; color: var(--ink-3); }

    .cl-entry { grid-template-columns: 1fr; gap: 12px; }
    .cl-meta { position: static; flex-direction: row; align-items: center; gap: 12px; }
}

@media (max-width: 640px) {
    h1 { font-size: 30px; line-height: 38px; }
    h2 { font-size: 24px; line-height: 32px; }
    h3 { font-size: 18px; line-height: 26px; margin-top: 32px; }
    .article { padding: 24px 16px 48px; }
    .section + .section { margin-top: 32px; padding-top: 40px; }
    .intro-lead { font-size: 17px; line-height: 28px; }
    .endpoint { padding: 14px; }
    .endpoint-path { font-size: 14px; }
    .code-panel pre { padding: 14px 16px; font-size: 13px; }
    .code-bar { padding-left: 8px; }
    .copy-label { display: none; }
    .copy-btn { width: 44px; height: 44px; justify-content: center; padding: 0; }
    .copy-btn-light { width: auto; height: 36px; padding: 0 10px; }
    .copy-btn-light .copy-label { display: inline; }
    .res-head { padding: 8px 16px 0; }
    .res-note { padding: 12px 16px 14px; }
    .callout { padding: 14px 16px; }
    .lifecycle { flex-direction: column; align-items: stretch; }
    .lifecycle li:not(.lc-arrow) { justify-content: flex-start; }
    .lc-arrow { justify-content: center; transform: rotate(90deg); height: 16px; }
    .wordmark { font-size: 17px; }

    .palette-box { width: 100vw; height: 100dvh; max-height: none; margin: 0; border-radius: 0; }
    .palette-list { max-height: none; flex: 1; }
    .palette-esc { display: none; }
    .palette-close { display: inline-flex; align-items: center; height: 36px; padding: 0 12px; border-radius: 8px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); font: 700 14px/1 var(--font-sans); cursor: pointer; }
    .palette-row-cat { display: none; }
    .palette-foot { display: none; }
}

@media (pointer: coarse) {
    .nav-link, .foot-link { min-height: 44px; }
    .copy-path, .icon-btn { min-width: 44px; min-height: 44px; }
    .code-tab { height: 40px; }
    .heading-anchor { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: 1ms !important; transition-duration: 1ms !important; transition-delay: 0s !important; }
    .sidebar, .sidebar.is-open { transition: none; }
    .nav-chevron { transition: none; }
}

@media (forced-colors: active) {
    .method, .code-tab, .chip, .req, .http, .state, .version-badge { border: 1px solid CanvasText; }
    .nav-link[aria-current="location"] { outline: 1px solid CanvasText; }
}

@media print {
    .sidebar, .topbar, .toc, .palette, .toast, .copy-btn, .copy-path, .heading-anchor { display: none !important; }
    .shell { display: block; }
    .code-panel[hidden] { display: block !important; }
}
