/* Velum Studio developer docs (velumstudio.dev/docs/).
   The .dev site's language: the ink ground, cream type, the wordmark's
   champagne-to-blush, and the 64 px grid. Dark first, light on request or
   by the system. No framework; every color is a token below. */

@font-face {
  font-family: "Inter";
  src: url(fonts/InterVariable-latin.woff2) format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #0c090a;
  --bg: #0c090a;
  --bg-raised: #141012;
  --bg-sunken: #090708;
  --bg-hover: rgba(244, 233, 216, .05);
  --bg-code: #110d0f;
  --bg-chip: rgba(244, 233, 216, .07);
  --line: rgba(244, 233, 216, .09);
  --line-strong: rgba(244, 233, 216, .16);
  --text: #f2e9dd;
  --text-2: #c5b9ad;
  --text-3: #988c84;
  --accent: #e9c78c;
  --accent-strong: #f6dcae;
  --rose: #eab4c4;
  --link-under: rgba(233, 199, 140, .38);
  --sel: rgba(233, 199, 140, .14);
  --focus: #f3d39b;
  --warn: #f2b36b;
  --ok: #8fd6a6;
  --grid: rgba(244, 233, 216, .045);
  --sheen-a: rgba(255, 214, 160, .10);
  --sheen-b: rgba(214, 150, 190, .08);
  --sheen-c: rgba(190, 210, 255, .07);
  --shadow: 0 18px 50px rgba(0, 0, 0, .45), 0 2px 8px rgba(0, 0, 0, .35);
  --hair: linear-gradient(90deg, transparent, rgba(233, 199, 140, .55) 30%, rgba(234, 180, 196, .55) 70%, transparent);

  /* code */
  --c-text: #e9dfd2;
  --c-com: #8a7f86;
  --c-key: #f2a9bf;
  --c-str: #e8c88f;
  --c-num: #b5c4f2;
  --c-fn: #f7e6c8;
  --c-type: #a9d4e8;
  --c-prop: #efcf9f;
  --c-punc: #a99d95;

  --wm-dark: block;
  --wm-light: none;
  --silk: .55;

  --radius: 10px;
  --radius-s: 6px;
  --top: 60px;
  --side: 272px;
  --toc: 220px;
  --measure: 46rem;
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) { color-scheme: light; }
  :root:not([data-theme="dark"]) {
    --bg: #fbf8f3; --bg-raised: #ffffff; --bg-sunken: #f4eee5; --bg-hover: rgba(40, 24, 28, .045);
    --bg-code: #f7f2ea; --bg-chip: rgba(40, 24, 28, .06); --line: rgba(40, 24, 28, .10); --line-strong: rgba(40, 24, 28, .18);
    --text: #1e1618; --text-2: #4e4246; --text-3: #6c5f63; --accent: #8a5525; --accent-strong: #6d3f17;
    --rose: #a1476a; --link-under: rgba(138, 85, 37, .35); --sel: rgba(138, 85, 37, .10); --focus: #8a5525;
    --warn: #9a5a0c; --ok: #2c7a47; --grid: rgba(40, 24, 28, .05);
    --sheen-a: rgba(233, 180, 110, .16); --sheen-b: rgba(214, 140, 175, .12); --sheen-c: rgba(150, 175, 235, .10);
    --shadow: 0 18px 50px rgba(60, 35, 20, .14), 0 2px 8px rgba(60, 35, 20, .08);
    --hair: linear-gradient(90deg, transparent, rgba(169, 111, 61, .5) 30%, rgba(161, 71, 106, .45) 70%, transparent);
    --c-text: #2a2023; --c-com: #6b5e62; --c-key: #a3365a; --c-str: #855510; --c-num: #2f56a6; --c-fn: #5c3a1c;
    --c-type: #1d6a8a; --c-prop: #7a4618; --c-punc: #6c5f63;
    --wm-dark: none; --wm-light: block; --silk: .13;
  }
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #fbf8f3; --bg-raised: #ffffff; --bg-sunken: #f4eee5; --bg-hover: rgba(40, 24, 28, .045);
  --bg-code: #f7f2ea; --bg-chip: rgba(40, 24, 28, .06); --line: rgba(40, 24, 28, .10); --line-strong: rgba(40, 24, 28, .18);
  --text: #1e1618; --text-2: #4e4246; --text-3: #6c5f63; --accent: #8a5525; --accent-strong: #6d3f17;
  --rose: #a1476a; --link-under: rgba(138, 85, 37, .35); --sel: rgba(138, 85, 37, .10); --focus: #8a5525;
  --warn: #9a5a0c; --ok: #2c7a47; --grid: rgba(40, 24, 28, .05);
  --sheen-a: rgba(233, 180, 110, .16); --sheen-b: rgba(214, 140, 175, .12); --sheen-c: rgba(150, 175, 235, .10);
  --shadow: 0 18px 50px rgba(60, 35, 20, .14), 0 2px 8px rgba(60, 35, 20, .08);
  --hair: linear-gradient(90deg, transparent, rgba(169, 111, 61, .5) 30%, rgba(161, 71, 106, .45) 70%, transparent);
  --c-text: #2a2023; --c-com: #6b5e62; --c-key: #a3365a; --c-str: #855510; --c-num: #2f56a6; --c-fn: #5c3a1c;
  --c-type: #1d6a8a; --c-prop: #7a4618; --c-punc: #6c5f63;
  --wm-dark: none; --wm-light: block; --silk: .13;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: calc(var(--top) + 20px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
::selection { background: var(--sel); }
img, svg { display: block; max-width: 100%; }
a { color: var(--accent); text-decoration: underline; text-decoration-color: var(--link-under); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-strong); text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
code, kbd, pre { font-family: ui-monospace, "SF Mono", "Cascadia Code", "JetBrains Mono", Menlo, Consolas, "Liberation Mono", monospace; font-size: .875em; }
kbd { display: inline-block; min-width: 1.6em; padding: 0 .35em; border: 1px solid var(--line-strong); border-bottom-width: 2px; border-radius: 5px; font-size: .75rem; line-height: 1.5; text-align: center; color: var(--text-2); background: var(--bg-raised); }
.i { width: 18px; height: 18px; flex: none; }
.i.sm { width: 14px; height: 14px; display: inline-block; vertical-align: -2px; }
.muted { color: var(--text-3); }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; padding: 8px 14px; border-radius: 8px; background: var(--accent); color: var(--ink); text-decoration: none; font-weight: 600; }
.skip:focus { top: 10px; }

/* ---- top bar ----------------------------------------------------------------- */

.topbar {
  position: sticky; top: 0; z-index: 30;
  height: var(--top);
  display: flex; align-items: center; gap: 14px;
  padding: 0 20px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(14px);
  backdrop-filter: saturate(1.4) blur(14px);
}
.topbar::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--hair); opacity: .7; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); flex: none; }
.brand .wm { height: 21px; width: auto; }
.brand .wm-dark { display: var(--wm-dark); }
.brand .wm-light { display: var(--wm-light); height: 19px; }
.brand-sub { font-size: 13px; font-weight: 550; letter-spacing: .01em; color: var(--text-2); padding: 2px 9px; border: 1px solid var(--line-strong); border-radius: 999px; }
.toplinks { display: flex; gap: 2px; margin-left: 18px; }
.toplinks a { padding: 6px 10px; border-radius: 7px; font-size: 14px; font-weight: 500; color: var(--text-2); text-decoration: none; }
.toplinks a:hover { color: var(--text); background: var(--bg-hover); }
.toplinks a[aria-current] { color: var(--text); }
.search-open {
  margin-left: auto; display: flex; align-items: center; gap: 8px; height: 36px; padding: 0 8px 0 12px; min-width: 210px;
  border: 1px solid var(--line-strong); border-radius: 9px; background: var(--bg-raised); color: var(--text-3);
  font: inherit; font-size: 14px; cursor: pointer;
}
.search-open:hover { color: var(--text-2); border-color: var(--text-3); }
.search-open span { flex: 1; text-align: left; }
.theme-toggle, .nav-toggle {
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 9px; border: 1px solid transparent;
  background: transparent; color: var(--text-2); cursor: pointer;
}
.theme-toggle:hover, .nav-toggle:hover { background: var(--bg-hover); color: var(--text); }
.theme-toggle .i { display: none; }
:root:not([data-theme]) .theme-toggle .t-system, :root[data-theme="light"] .theme-toggle .t-light, :root[data-theme="dark"] .theme-toggle .t-dark { display: block; }
.nav-toggle { display: none; }

/* Account: Log in (on velumstudio.app, which signs you in here too), or the
   signed-in chip and a Log out for this site. Drawn by /auth.js. */
.acct { display: flex; align-items: center; gap: 6px; flex: none; }
.acct-link { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--line-strong); color: var(--text-2); font-size: 14px; font-weight: 550; text-decoration: none; }
.acct-link:hover { color: var(--text); background: var(--bg-hover); }
.acct-link.signed-in { padding: 0 10px 0 5px; border-radius: 999px; }
.acct-link .acct-chip-avatar { width: 24px; height: 24px; flex: 0 0 24px; border-radius: 50%; background-size: cover; background-position: center; display: grid; place-items: center; font-size: 12px; font-weight: 700; color: #070506; }
.acct-link .acct-chip-avatar.letter { background: linear-gradient(135deg, #f4d479, #d4af37 60%, #b4902a); }
.acct-link .acct-chip-name { max-width: 12ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-logout { height: 36px; padding: 0 10px; border-radius: 9px; border: 1px solid transparent; background: transparent; color: var(--text-3); font: inherit; font-size: 13px; cursor: pointer; }
.acct-logout:hover { color: var(--text); background: var(--bg-hover); }
@media (max-width: 640px) { .acct-link .acct-chip-name { display: none; } .acct-link.signed-in { padding: 0 5px; } }

/* ---- layout ------------------------------------------------------------------- */

.layout {
  display: grid;
  grid-template-columns: var(--side) minmax(0, 1fr) var(--toc);
  max-width: 1500px;
  margin: 0 auto;
}
.sidebar {
  position: sticky; top: var(--top); align-self: start;
  height: calc(100vh - var(--top)); height: calc(100dvh - var(--top));
  overflow-y: auto; overscroll-behavior: contain;
  padding: 26px 14px 40px 20px;
  scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent;
}
.nav-root, .nav-root ul { list-style: none; margin: 0; padding: 0; }
.nav-section { margin-bottom: 22px; }
.nav-label { display: block; padding: 0 10px 6px; font-size: 12.5px; font-weight: 650; letter-spacing: .02em; color: var(--text-3); }
.sidebar a { display: block; padding: 5px 10px; border-radius: 7px; font-size: 14px; line-height: 1.4; color: var(--text-2); text-decoration: none; }
.sidebar a:hover { color: var(--text); background: var(--bg-hover); }
.sidebar a[aria-current="page"] { color: var(--text); background: var(--bg-chip); box-shadow: inset 2px 0 0 var(--accent); font-weight: 550; }
.nav-sub { display: none; margin: 2px 0 4px 10px !important; padding-left: 8px !important; border-left: 1px solid var(--line); }
.nav-sub.open { display: block; }
.nav-sub a { font-size: 13.5px; padding: 4px 10px; }

.main { min-width: 0; padding: 40px 48px 64px; }
.main:focus { outline: none; }
.doc { max-width: var(--measure); margin: 0 auto; }
.doc.wide { max-width: 72rem; }
.toc {
  position: sticky; top: var(--top); align-self: start;
  max-height: calc(100vh - var(--top)); overflow-y: auto;
  padding: 44px 20px 40px 8px; font-size: 13px;
  scrollbar-width: thin;
}
.toc-title { margin: 0 0 8px; font-weight: 650; font-size: 12.5px; color: var(--text-3); letter-spacing: .02em; }
.toc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.toc li a { display: block; padding: 3px 0 3px 12px; margin-left: -1px; border-left: 1px solid transparent; color: var(--text-3); text-decoration: none; line-height: 1.4; }
.toc li.l3 a { padding-left: 24px; }
.toc li a:hover { color: var(--text); }
.toc li a.on { color: var(--text); border-left-color: var(--accent); }
body.kind-reference .toc li a { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 12px; }

/* ---- prose -------------------------------------------------------------------- */

.eyebrow { margin: 0 0 6px; font-size: 13px; font-weight: 600; letter-spacing: .02em; color: var(--accent); }
.doc h1 { margin: 0 0 12px; font-size: clamp(30px, 4vw, 40px); line-height: 1.12; font-weight: 680; letter-spacing: -.022em; }
.lede { margin: 0 0 28px; font-size: 18px; line-height: 1.6; color: var(--text-2); max-width: 44rem; }
.doc h2 { margin: 2.4em 0 .6em; font-size: 24px; line-height: 1.25; font-weight: 650; letter-spacing: -.012em; }
.doc h3 { margin: 1.9em 0 .5em; font-size: 18px; line-height: 1.35; font-weight: 640; letter-spacing: -.006em; }
.doc h4 { margin: 1.6em 0 .4em; font-size: 15.5px; font-weight: 650; }
.doc h2 code, .doc h3 code { font-size: .86em; }
.doc p, .doc ul, .doc ol, .doc dl { margin: 0 0 1em; }
.doc ul, .doc ol { padding-left: 1.3em; }
.doc li { margin: .3em 0; }
.doc li > p { margin: 0 0 .4em; }
.doc strong { font-weight: 640; color: var(--text); }
.doc hr { border: 0; height: 1px; background: var(--line); margin: 2.4em 0; }
.doc dt { font-weight: 640; margin-top: .8em; }
.doc dd { margin: .2em 0 0 1.2em; color: var(--text-2); }
.doc :not(pre) > code, .doc a > code {
  padding: .12em .38em; border-radius: 5px; background: var(--bg-chip); color: var(--text); font-size: .84em; white-space: nowrap;
}
.doc a > code { color: var(--accent); }
.doc a.ref { text-decoration: none; }
.doc a.ref:hover code { background: var(--sel); }
.doc blockquote { margin: 1.2em 0; padding: .2em 0 .2em 1em; border-left: 2px solid var(--line-strong); color: var(--text-2); }
.doc img { border-radius: var(--radius); }

/* Callouts (Markdown admonitions). */
.admonition { margin: 1.4em 0; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-raised); }
.admonition > :last-child { margin-bottom: 0; }
.admonition-title { margin: 0 0 4px !important; font-weight: 650; font-size: 14px; letter-spacing: .01em; color: var(--accent); }
.admonition.warning { border-color: color-mix(in srgb, var(--warn) 45%, transparent); }
.admonition.warning .admonition-title { color: var(--warn); }
.admonition.status { border-style: dashed; }
.admonition.status .admonition-title { color: var(--rose); }

/* Tables. */
.table-wrap { margin: 1.2em 0 1.6em; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.doc table { width: 100%; border-collapse: collapse; font-size: 14.5px; line-height: 1.5; }
.doc > table, .doc > .tabs + table { display: block; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.doc th { text-align: left; font-weight: 620; font-size: 13px; color: var(--text-2); background: var(--bg-sunken); white-space: nowrap; }
.doc th, .doc td { padding: 9px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.doc tr:last-child td { border-bottom: 0; }
.doc td code { white-space: nowrap; }
.doc td.num { white-space: nowrap; font-variant-numeric: tabular-nums; }
.doc td.val { white-space: nowrap; }

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

.code { position: relative; margin: 1.2em 0 1.5em; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-code); overflow: hidden; }
.code-head { display: flex; align-items: center; gap: 10px; min-height: 36px; padding: 0 8px 0 14px; border-bottom: 1px solid var(--line); font-size: 12.5px; color: var(--text-3); }
.code-lang { font-weight: 600; color: var(--text-2); }
.code-cap { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.copy { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 8px; border: 1px solid transparent; border-radius: 6px; background: none; color: var(--text-3); font: inherit; font-size: 12px; cursor: pointer; }
.copy:hover { color: var(--text); background: var(--bg-hover); }
.copy .i { width: 14px; height: 14px; }
.code pre { margin: 0; padding: 14px 16px 16px; overflow-x: auto; color: var(--c-text); line-height: 1.6; font-size: 13.5px; tab-size: 4; scrollbar-width: thin; }
.code pre code { font-size: inherit; }
.tabs { margin: 1.2em 0 1.5em; }
.tabs .code { margin: 0; border-top-left-radius: 0; border-top-right-radius: 0; }
.tablist { display: none; gap: 2px; padding: 4px 4px 0; border: 1px solid var(--line); border-bottom: 0; border-radius: var(--radius) var(--radius) 0 0; background: var(--bg-sunken); overflow-x: auto; }
.js .tablist { display: flex; }
.tablist button { padding: 7px 12px 8px; border: 0; border-radius: 7px 7px 0 0; background: none; color: var(--text-3); font: inherit; font-size: 13px; font-weight: 550; cursor: pointer; white-space: nowrap; }
.tablist button:hover { color: var(--text); }
.tablist button[aria-selected="true"] { color: var(--text); background: var(--bg-code); box-shadow: inset 0 2px 0 var(--accent); }
.tabpanel + .tabpanel { margin-top: 10px; }
.js .tabpanel { margin-top: 0; }
.js .tabpanel:not(.active) { display: none; }
.js .tabs .code-head .code-lang { display: none; }
.js .tabs .code-head { min-height: 0; border: 0; padding: 0; }
.tabs { position: relative; }
.js .tabs .code { position: static; }
.js .tabs .code-head .copy { position: absolute; top: 5px; right: 6px; }
.js .tablist { padding-right: 90px; }
.code-col pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.js .tabs .code-head .code-cap { display: none; }
.code-note { margin: 18px 0 6px !important; font-size: 12.5px; font-weight: 600; color: var(--text-3); letter-spacing: .02em; }

/* Pygments' short classes. */
.c, .ch, .cm, .c1, .cs, .cp, .cpf { color: var(--c-com); font-style: italic; }
.k, .kd, .kn, .kr, .kt, .kv, .kp, .ow { color: var(--c-key); }
.kc { color: var(--c-num); }
.s, .s1, .s2, .sb, .sc, .sd, .se, .sh, .si, .sx, .sa, .dl, .ss { color: var(--c-str); }
.m, .mi, .mf, .mh, .mo, .il, .mb { color: var(--c-num); }
.nf, .fm, .nb, .bp { color: var(--c-fn); }
.nc, .nn, .nt, .ne { color: var(--c-type); }
.na, .nl, .py, .nd { color: var(--c-prop); }
[data-lang="json"] .nt, [data-lang="jsonrpc"] .nt { color: var(--c-prop); }
.o, .p { color: var(--c-punc); }
.err { color: inherit; background: none; }
.gp { color: var(--c-com); user-select: none; }

/* ---- reference ------------------------------------------------------------------ */

.api { padding: 34px 0 30px; border-top: 1px solid var(--line); }
.api:first-of-type { border-top: 0; padding-top: 6px; }
.table-wrap + .api { border-top: 1px solid var(--line); margin-top: 32px; }
.doc .api-h { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin: 0 0 8px; font-size: 22px; }
.doc .api-h code { padding: 0; background: none; font-size: 21px; font-weight: 600; color: var(--text); white-space: normal; overflow-wrap: anywhere; }
.api-name { font-size: 16px; font-weight: 500; color: var(--text-3); letter-spacing: 0; }
.api-desc { color: var(--text-2); max-width: 52rem; }
.badges { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 6px !important; }
.badge { display: inline-flex; align-items: center; height: 21px; padding: 0 8px; border-radius: 999px; background: var(--bg-chip); color: var(--text-2); font-size: 11.5px; font-weight: 600; letter-spacing: .01em; white-space: nowrap; text-decoration: none; }
a.badge:hover { color: var(--text); }
.badge.req { color: var(--accent); background: var(--sel); }
.badge.opt { color: var(--text-3); background: transparent; border: 1px solid var(--line); }
.badge.warn { color: var(--warn); background: color-mix(in srgb, var(--warn) 14%, transparent); }
.badge.ctl { color: var(--rose); background: color-mix(in srgb, var(--rose) 12%, transparent); }
.api-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0 40px; }
.api-col > h3:first-child { margin-top: 1.2em; }
.doc .api-col h3 { font-size: 13px; font-weight: 650; letter-spacing: .03em; color: var(--text-3); margin: 1.8em 0 .5em; }
.code-col { padding-top: 18px; }
.code-col .code:first-child { margin-top: 0; }
.raw { margin-top: 10px; }
.raw summary, .child summary { cursor: pointer; font-size: 13px; color: var(--text-3); font-weight: 550; list-style: none; display: inline-flex; align-items: center; gap: 6px; padding: 3px 0; }
.raw summary::-webkit-details-marker, .child summary::-webkit-details-marker { display: none; }
.raw summary::before, .child summary::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(-45deg); transition: transform .15s var(--ease); margin-right: 2px; }
.raw[open] summary::before, .child[open] summary::before { transform: rotate(45deg); }
.raw summary:hover, .child summary:hover { color: var(--text); }
.raw .code pre { max-height: 420px; }

.fields, .variants { list-style: none; margin: 0 0 .8em !important; padding: 0 !important; }
.field { margin: 0 !important; padding: 11px 0 12px; border-bottom: 1px solid var(--line); }
.field:last-child { border-bottom: 0; }
.fhead { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.doc code.fname { padding: 0; background: none; font-size: 14px; font-weight: 600; color: var(--text); }
.ftype { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 12.5px; color: var(--text-3); }
a.ftype { text-decoration: none; color: var(--text-3); }
a.ftype:hover, .ftype a:hover { color: var(--accent); }
.ftype a.shape { color: var(--accent); text-decoration: none; }
.fdesc { margin: 4px 0 0 !important; font-size: 14.5px; color: var(--text-2); }
.fmeta { margin: 4px 0 0 !important; font-size: 13.5px; color: var(--text-3); }
.fmeta code { font-size: .86em !important; }
.doc ul.values { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 6px 0 4px; }
.doc ul.values li { margin: 0; }
.doc h3.api-h code { font-size: 18px; }
.child { margin: 8px 0 0 2px; padding-left: 14px; border-left: 1px solid var(--line); }
.child > .fields { margin-top: 2px !important; }
.variant { margin: 0 0 6px !important; }
.vhead { margin: 10px 0 2px !important; font-size: 13.5px; color: var(--text-2); font-weight: 550; }
.shape-is { margin: 0 0 4px !important; color: var(--text-2); font-size: 14.5px; }
.state { margin: 0 0 4px !important; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.tlabel { font-size: 13px; color: var(--text-3); }
.group-h { display: flex; gap: 10px; align-items: baseline; }
.group-h a { color: var(--text); text-decoration: none; }
.group-h a:hover { color: var(--accent); }
.ref-table td:first-child { width: 1%; }

/* Tokens. */
.tokens td:first-child { white-space: nowrap; }
.tokens .tok { display: block; padding: 0 !important; background: none !important; font-weight: 600; }
.tokens .tlabel { display: block; }
.tokens .cssvar { display: block; padding: 0 !important; background: none !important; color: var(--text-3) !important; font-size: 11.5px !important; margin-top: 2px; }
.sw { display: inline-block; width: 15px; height: 15px; margin-right: 8px; vertical-align: -3px; border-radius: 4px; background: linear-gradient(var(--sw), var(--sw)), repeating-conic-gradient(#8a8a8a 0 25%, #d0d0d0 0 50%) 0 0 / 8px 8px; box-shadow: inset 0 0 0 1px rgba(128, 128, 128, .35); }
.inherit { display: block; font-size: 12px; }
.pair { display: inline-grid; place-items: center; width: 30px; height: 22px; margin-right: 6px; border-radius: 5px; background: var(--bg); color: var(--fg); background: var(--bg); font-size: 12px; font-weight: 650; vertical-align: middle; box-shadow: inset 0 0 0 1px rgba(128, 128, 128, .3); }
.pairs .pair { background: var(--bg) !important; }
ul.plain { list-style: none; padding: 0 !important; }
ul.status li { display: flex; align-items: center; gap: 2px; }

/* Figures. */
.shot { margin: 1.6em 0; }
.shot img { width: 100%; height: auto; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.shot figcaption { margin-top: 10px; font-size: 13px; color: var(--text-3); text-align: center; }
.shots { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

/* ---- the home page ------------------------------------------------------------------ */

body.kind-home .layout { grid-template-columns: var(--side) minmax(0, 1fr); }
.doc.home { max-width: 66rem; }
.hero { position: relative; margin: -40px -48px 8px; padding: 76px 48px 56px; overflow: hidden; isolation: isolate; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px; background-position: -1px -1px;
  -webkit-mask: radial-gradient(75% 90% at 30% 20%, #000, transparent 78%);
  mask: radial-gradient(75% 90% at 30% 20%, #000, transparent 78%);
}
.hero::after {
  content: ""; position: absolute; inset: -20% -10% 0; z-index: -2;
  background:
    radial-gradient(40% 50% at 18% 30%, var(--sheen-a), transparent 70%),
    radial-gradient(34% 44% at 62% 12%, var(--sheen-b), transparent 70%),
    radial-gradient(30% 40% at 88% 48%, var(--sheen-c), transparent 70%);
}
/* The silk from the coming-soon page, cooler, drifting in from the right. */
.hero .silk {
  position: absolute; z-index: -3; inset: 0 -12% -30% 30%;
  background: url(/img/ground-1440.webp) center 60% / cover no-repeat;
  filter: hue-rotate(-18deg) saturate(.85);
  opacity: var(--silk, .55);
  -webkit-mask: linear-gradient(90deg, transparent, #000 45%), linear-gradient(transparent 0, #000 30%, #000 70%, transparent);
  -webkit-mask-composite: source-in;
  mask: linear-gradient(90deg, transparent, #000 45%) intersect, linear-gradient(transparent 0, #000 30%, #000 70%, transparent);
  pointer-events: none;
}
.hero .eyebrow { margin-bottom: 14px; }
.hero h1 { font-size: clamp(36px, 5.4vw, 62px); line-height: 1.04; letter-spacing: -.035em; font-weight: 720; margin: 0 0 18px; }
.hero h1 .sheen-text { background: linear-gradient(100deg, #f4d79f 0%, #fff1d9 28%, #f0c367 52%, #e5b1c0 86%); -webkit-background-clip: text; background-clip: text; color: transparent; }
:root[data-theme="light"] .hero h1 .sheen-text { background: linear-gradient(100deg, #8a5525 0%, #a96f3d 40%, #a1476a 90%); -webkit-background-clip: text; background-clip: text; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .hero h1 .sheen-text { background: linear-gradient(100deg, #8a5525 0%, #a96f3d 40%, #a1476a 90%); -webkit-background-clip: text; background-clip: text; } }
.hero .lede { font-size: 19px; max-width: 40rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.btn { display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 18px; border-radius: 10px; font-weight: 600; font-size: 15px; text-decoration: none; border: 1px solid var(--line-strong); color: var(--text); background: var(--bg-raised); }
.btn:hover { color: var(--text); border-color: var(--text-3); }
.btn.primary { background: linear-gradient(180deg, #f2d29a, #e2b673); border-color: transparent; color: #24170c; }
.btn.primary:hover { background: linear-gradient(180deg, #f7dcab, #e8c083); color: #24170c; }
:root[data-theme="light"] .btn.primary { background: linear-gradient(180deg, #9a6331, #7e4a1f); color: #fff8ef; }
@media (prefers-color-scheme: light) { :root:not([data-theme="dark"]) .btn.primary { background: linear-gradient(180deg, #9a6331, #7e4a1f); color: #fff8ef; } }
.btn .i { width: 16px; height: 16px; }

.counts { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; list-style: none; padding: 0 !important; margin: 8px 0 40px !important; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--bg-raised); }
.counts li { margin: 0 !important; border-left: 1px solid var(--line); }
.counts li:first-child { border-left: 0; }
.counts a { display: flex; flex-direction: column; padding: 16px 18px; text-decoration: none; color: var(--text-2); font-size: 13.5px; }
.counts a:hover { background: var(--bg-hover); }
.counts strong { font-size: 28px; line-height: 1.1; font-weight: 680; color: var(--text); letter-spacing: -.02em; font-variant-numeric: tabular-nums; }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; margin: 18px 0 36px; }
.card { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 20px 20px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg-raised); color: var(--text-2); text-decoration: none; transition: border-color .2s var(--ease), transform .2s var(--ease), box-shadow .2s var(--ease); }
.card:hover { color: var(--text-2); border-color: var(--line-strong); transform: translateY(-2px); box-shadow: var(--shadow); }
.card .ci { display: grid; place-items: center; width: 36px; height: 36px; margin-bottom: 6px; border-radius: 10px; color: var(--accent); background: var(--sel); }
.card .ci .i { width: 19px; height: 19px; }
.card h3 { margin: 0 !important; font-size: 16.5px; color: var(--text); }
.card p { margin: 0; font-size: 14.5px; line-height: 1.55; }
.card .more { margin-top: auto; padding-top: 10px; font-size: 13.5px; font-weight: 600; color: var(--accent); display: inline-flex; align-items: center; gap: 6px; }
.card .more .i { width: 15px; height: 15px; transition: transform .2s var(--ease); }
.card:hover .more .i { transform: translateX(3px); }

/* ---- pager, footer ----------------------------------------------------------------- */

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; max-width: var(--measure); margin: 56px auto 0; }
.kind-reference .pager, .kind-home .pager { max-width: 72rem; }
.pager a { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--text); font-weight: 600; font-size: 15px; }
.pager a:hover { border-color: var(--line-strong); background: var(--bg-hover); }
.pager a span { font-size: 12.5px; font-weight: 500; color: var(--text-3); }
.pager .next { grid-column: 2; text-align: right; }
.foot { max-width: var(--measure); margin: 40px auto 0; padding-top: 22px; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--text-2); }
.kind-reference .foot, .kind-home .foot { max-width: 72rem; }
.foot p { margin: 0 0 6px; }
.foot a { color: var(--text-2); }
.foot a:hover { color: var(--text); }

/* ---- search ------------------------------------------------------------------------ */

dialog.search {
  width: min(680px, calc(100vw - 32px)); max-height: min(640px, calc(100vh - 120px));
  margin: 72px auto auto; padding: 0;
  border: 1px solid var(--line-strong); border-radius: 14px;
  background: var(--bg-raised); color: var(--text); box-shadow: var(--shadow);
  overflow: hidden;
}
dialog.search[open] { display: flex; flex-direction: column; }
dialog.search::backdrop { background: rgba(5, 3, 4, .55); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
.search-box { display: flex; align-items: center; gap: 10px; padding: 0 12px 0 16px; border-bottom: 1px solid var(--line); color: var(--text-3); }
.search-box input { flex: 1; min-width: 0; height: 56px; border: 0; outline: 0; background: none; color: var(--text); font: inherit; font-size: 17px; }
.search-box input::-webkit-search-cancel-button { display: none; }
.search-close { border: 0; background: none; padding: 4px; cursor: pointer; }
.search-results { list-style: none; margin: 0; padding: 8px; overflow-y: auto; flex: 1; }
.search-results li { margin: 0; }
.search-results a { display: block; padding: 9px 12px; border-radius: 9px; text-decoration: none; color: var(--text-2); }
.search-results a .t { display: block; font-weight: 600; color: var(--text); font-size: 15px; }
.search-results a .s { display: block; font-size: 12.5px; color: var(--text-3); margin-top: 1px; }
.search-results a .x { display: block; font-size: 13.5px; color: var(--text-2); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-results a mark { background: none; color: var(--accent); font-weight: 650; }
.search-results [aria-selected="true"] a { background: var(--sel); }
.search-results .empty { padding: 26px 12px; text-align: center; color: var(--text-3); }
.search-hint { margin: 0; padding: 10px 16px; border-top: 1px solid var(--line); font-size: 12.5px; color: var(--text-3); display: flex; align-items: center; gap: 6px; }

/* ---- smaller screens --------------------------------------------------------------- */

@media (max-width: 1279px) {
  .layout { grid-template-columns: var(--side) minmax(0, 1fr); }
  .toc { display: none; }
}
@media (max-width: 1100px) {
  .api-grid { grid-template-columns: minmax(0, 1fr); }
  .code-col { padding-top: 4px; }
  .toplinks { display: none; }
}
@media (max-width: 900px) {
  :root { --top: 56px; }
  .layout, body.kind-home .layout { grid-template-columns: minmax(0, 1fr); }
  .nav-toggle { display: grid; margin-left: -8px; }
  .sidebar {
    position: fixed; z-index: 25; top: var(--top); left: 0; bottom: 0; width: min(320px, 86vw); height: auto;
    background: var(--bg); border-right: 1px solid var(--line); box-shadow: var(--shadow);
    transform: translateX(-102%); transition: transform .25s var(--ease); visibility: hidden;
  }
  body.nav-open .sidebar { transform: none; visibility: visible; }
  body.nav-open::after { content: ""; position: fixed; inset: var(--top) 0 0 0; z-index: 20; background: rgba(5, 3, 4, .45); }
  .main { padding: 28px 16px 48px; }
  .hero { margin: -28px -16px 8px; padding: 48px 16px 36px; }
  .search-open { min-width: 0; width: 36px; padding: 0; justify-content: center; border-color: transparent; background: none; }
  .search-open span, .search-open kbd { display: none; }
  .counts { grid-template-columns: repeat(3, 1fr); }
  .counts li:nth-child(4) { border-left: 0; }
  .counts li:nth-child(n+4) { border-top: 1px solid var(--line); }
  .shots { grid-template-columns: 1fr; }
  .topbar { padding: 0 12px; gap: 6px; }
}
@media (max-width: 520px) {
  .brand-sub { display: none; }
  .counts { grid-template-columns: repeat(2, 1fr); }
  .counts li { border-left: 0 !important; border-top: 1px solid var(--line); }
  .counts li:nth-child(even) { border-left: 1px solid var(--line) !important; }
  .counts li:nth-child(-n+2) { border-top: 0; }
  .counts li:last-child { grid-column: span 2; border-left: 0 !important; }
  .pager { grid-template-columns: 1fr; }
  .pager .next { grid-column: 1; }
  .doc h1 { font-size: 30px; }
  .lede { font-size: 17px; }
  .doc .api-h code { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}

@media print {
  .topbar, .sidebar, .toc, .pager, dialog { display: none !important; }
  .layout { display: block; }
  .main { padding: 0; }
  .js .tabpanel:not(.active) { display: block; }
}

/* Long inline code in running text wraps rather than pushing the page sideways. */
.doc p > code, .doc li > code, .doc li > strong > code, .doc p > strong > code, .doc dd > code { white-space: normal; overflow-wrap: anywhere; }
