.docs { --head: 64px; }
.docs .wrap { max-width: 1360px; }

.docs-header { position: sticky; top: 0; z-index: 40; background: rgba(255, 255, 255, .9); -webkit-backdrop-filter: saturate(180%) blur(14px); backdrop-filter: saturate(180%) blur(14px); border-bottom: 1px solid var(--line); }
.docs-top { display: flex; align-items: center; gap: 24px; height: var(--head); }
.docs-top .links { margin-left: auto; }
.docs-brand { display: flex; align-items: center; gap: 12px; flex: none; }
.docs-label { font: 500 12px var(--mono); text-decoration: none; color: var(--muted); padding: 3px 8px; border: 1px solid var(--line); border-radius: 6px; }
.docs-menu { display: none; }
.docs-search { position: relative; flex: 1; max-width: 440px; }
.docs-search input { width: 100%; height: 38px; padding: 0 40px 0 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--soft); font: 14px var(--sans); color: var(--fg); outline: none; -webkit-appearance: none; appearance: none; }
.docs-search input:focus { border-color: var(--fg); background: var(--bg); }
.docs-search kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 11px var(--mono); color: var(--faint); border: 1px solid var(--line); border-radius: 5px; padding: 1px 6px; pointer-events: none; }
.docs-results { position: absolute; top: 44px; left: 0; right: 0; z-index: 50; max-height: 62vh; overflow: auto; padding: 6px; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 18px 40px -18px rgba(10, 10, 10, .25); }
.docs-results a { display: block; padding: 9px 10px; border-radius: 8px; text-decoration: none; }
.docs-results a:hover, .docs-results a.on { background: var(--soft); }
.docs-results b { display: block; font-weight: 500; font-size: 14px; }
.docs-results small { display: block; margin-top: 2px; font: 11.5px var(--mono); color: var(--faint); }
.docs-results span { display: block; margin-top: 3px; font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.docs-results .none { padding: 12px; font-size: 14px; color: var(--muted); }

.docs-shell { display: grid; grid-template-columns: 228px minmax(0, 1fr) 200px; gap: 56px; align-items: start; padding-top: 36px; padding-bottom: 96px; }
.docs-side { position: sticky; top: calc(var(--head) + 28px); max-height: calc(100vh - var(--head) - 44px); overflow-y: auto; overscroll-behavior: contain; margin-left: -10px; padding: 0 6px 24px 0; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.docs-nav p { margin: 26px 0 6px; padding-left: 10px; font: 11px var(--mono); text-transform: uppercase; letter-spacing: .09em; color: var(--faint); }
.docs-nav p:first-child { margin-top: 0; }
.docs-nav ul { list-style: none; margin: 0; padding: 0; }
.docs-nav a { display: block; padding: 6px 10px; border-radius: 8px; font-size: 14.5px; line-height: 1.4; color: var(--muted); text-decoration: none; }
.docs-nav a:hover { color: var(--fg); background: var(--soft); }
.docs-nav a.on { color: var(--fg); background: var(--soft); font-weight: 500; }

.docs-main { min-width: 0; max-width: 760px; }
.docs-eyebrow { margin: 0 0 10px; font: 12px var(--mono); text-transform: uppercase; letter-spacing: .09em; color: var(--faint); }
.docs-main h1 { max-width: none; margin: 0 0 12px; font-size: clamp(32px, 4vw, 42px); }
.docs-lede { margin: 0 0 30px; font-size: 18px; line-height: 1.55; color: var(--muted); }
.docs-body { font-size: 16px; line-height: 1.7; }
.docs-body > :first-child { margin-top: 0; }
.docs-body h2 { margin: 48px 0 12px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 24px; font-weight: 500; letter-spacing: -.02em; line-height: 1.3; scroll-margin-top: calc(var(--head) + 16px); }
.docs-body h3 { margin: 32px 0 8px; font-size: 18px; font-weight: 500; letter-spacing: -.01em; scroll-margin-top: calc(var(--head) + 24px); }
.docs-body .anchor { margin-left: 8px; color: var(--faint); font-weight: 400; text-decoration: none; opacity: 0; }
.docs-body h2:hover .anchor, .docs-body h3:hover .anchor, .docs-body .anchor:focus { opacity: 1; }
.docs-body p, .docs-body li, .docs-body td { color: #33332f; }
.docs-body strong { color: var(--fg); font-weight: 500; }
.docs-body a { color: var(--fg); text-decoration-color: var(--faint); text-underline-offset: 3px; }
.docs-body a:hover { text-decoration-color: var(--fg); }
.docs-body ul, .docs-body ol { padding-left: 22px; }
.docs-body li { margin: 4px 0; }
.docs-body code { padding: 1px 5px; font: .87em var(--mono); background: var(--soft); border: 1px solid var(--line); border-radius: 5px; overflow-wrap: anywhere; }
.docs-body pre code { padding: 0; font: inherit; background: none; border: 0; overflow-wrap: normal; }
.docs-body hr { margin: 40px 0; border: 0; border-top: 1px solid var(--line); }

.hl { margin: 20px 0; background: #fbfbfa; border: 1px solid var(--line); border-radius: 12px; overflow: hidden; }
.code-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: 38px; padding: 0 6px 0 14px; background: var(--soft); border-bottom: 1px solid var(--line); }
.code-head span { overflow: hidden; font: 500 12px var(--mono); color: var(--muted); white-space: nowrap; text-overflow: ellipsis; }
.hl[data-lang="bash"] .code-head > span::before { content: "$"; margin-right: 8px; color: var(--faint); }
.hl pre { margin: 0; padding: 14px 16px 16px; overflow-x: auto; font: 13.5px/1.65 var(--mono); color: #1d1d1b; background: none; border: 0; border-radius: 0; tab-size: 2; scrollbar-width: thin; scrollbar-color: #d9d9d4 transparent; }
.hl[data-lang="text"] pre { color: #45453f; white-space: pre-wrap; overflow-wrap: anywhere; }
.copy { display: inline-flex; flex: none; align-items: center; gap: 6px; height: 28px; padding: 0 9px; font: 500 12.5px var(--sans); color: var(--muted); background: transparent; border: 0; border-radius: 7px; cursor: pointer; }
.copy:hover { color: var(--fg); background: var(--bg); }
.copy:focus-visible { outline: 2px solid var(--fg); outline-offset: 1px; }
.copy svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.copy.done { color: var(--ok); }
.hl .t-c, .hl .t-c1, .hl .t-cm, .hl .t-ch, .hl .t-cs { color: #9b9b96; font-style: italic; }
.hl .t-k, .hl .t-kd, .hl .t-kn, .hl .t-kc, .hl .t-kr, .hl .t-kt, .hl .t-ow { color: #6a5bb5; }
.hl .t-s, .hl .t-s1, .hl .t-s2, .hl .t-sb, .hl .t-sd, .hl .t-sh, .hl .t-se, .hl .t-si, .hl .t-sx, .hl .t-dl { color: #7a6a00; }
.hl .t-m, .hl .t-mi, .hl .t-mf, .hl .t-mh, .hl .t-il { color: #1f7a45; }
.hl .t-nt, .hl .t-na { color: #0a0a0a; font-weight: 500; }
.hl .t-nf, .hl .t-nb, .hl .t-bp { color: #2d5ea8; }
.hl .t-nv, .hl .t-vg, .hl .t-vi { color: #a3471f; }
.hl .t-o, .hl .t-p { color: #77776f; }
.hl .t-gp { color: #9b9b96; user-select: none; }

.docs-body table { display: block; width: 100%; margin: 18px 0; overflow-x: auto; font-size: 14.5px; table-layout: auto; border-collapse: collapse; }
.docs-body th { width: auto; padding: 9px 12px; font: 11.5px var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--faint); border-bottom: 1px solid var(--line); white-space: nowrap; }
.docs-body th:nth-child(2) { width: auto; }
.docs-body td { padding: 9px 12px; vertical-align: top; border-bottom: 1px solid var(--line); }
.docs-body tbody tr:hover td { background: transparent; }
.docs-body tbody tr:last-child td { border-bottom: 1px solid var(--line); }
.docs-body td code { white-space: nowrap; }

.docs-body blockquote { margin: 18px 0; padding: 10px 16px; background: var(--soft); border-left: 3px solid var(--line); border-radius: 0 10px 10px 0; }
.docs-body blockquote p { margin: 6px 0; }
.docs-body .callout.note { border-left-color: #8a8a84; }
.docs-body .callout.warning { background: #fdf6e7; border-left-color: var(--wait); }
.docs-body .callout.tip { background: #eef8f1; border-left-color: var(--ok); }

.docs-pager { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 60px; }
.docs-pager a { display: block; padding: 14px 16px; text-decoration: none; border: 1px solid var(--line); border-radius: 12px; font-weight: 500; }
.docs-pager a:hover { border-color: var(--fg); }
.docs-pager span { display: block; margin-bottom: 4px; font: 11.5px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 400; }
.docs-pager .next { grid-column: 2; text-align: right; }
.docs-edit { margin-top: 22px; font-size: 13px; }
.docs-edit a { color: var(--muted); }

.docs-toc { position: sticky; top: calc(var(--head) + 28px); max-height: calc(100vh - var(--head) - 44px); overflow-y: auto; font-size: 13px; scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.docs-toc p { margin: 0 0 8px; font: 11px var(--mono); text-transform: uppercase; letter-spacing: .09em; color: var(--faint); }
.docs-toc ul { list-style: none; margin: 0; padding: 0; border-left: 1px solid var(--line); }
.docs-toc a { display: block; margin-left: -1px; padding: 4px 0 4px 12px; color: var(--muted); text-decoration: none; border-left: 1px solid transparent; line-height: 1.4; }
.docs-toc a:hover { color: var(--fg); }
.docs-toc a.on { color: var(--fg); border-left-color: var(--fg); }

.docs-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin: 22px 0; }
.docs-cards a { display: block; padding: 16px; text-decoration: none; border: 1px solid var(--line); border-radius: 12px; }
.docs-cards a:hover { border-color: var(--fg); }
.docs-cards b { display: block; margin-bottom: 4px; font-weight: 500; color: var(--fg); }
.docs-cards span { font-size: 14px; color: var(--muted); line-height: 1.5; }

@media (max-width: 1240px) {
  .docs-shell { grid-template-columns: 220px minmax(0, 1fr); gap: 48px; }
  .docs-toc { display: none; }
}
@media (max-width: 860px) {
  .docs { --head: 60px; }
  .docs .wrap { padding: 0 16px; }
  .docs-top { gap: 12px; }
  .docs-search { position: static; max-width: none; min-width: 0; }
  .docs-search input { height: 40px; padding-right: 12px; font-size: 16px; }
  .docs-search kbd { display: none; }
  .docs-results { top: calc(var(--head) - 2px); left: 12px; right: 12px; max-height: calc(100vh - var(--head) - 24px); }
  .js .docs-menu { display: inline-flex; flex: none; align-items: center; justify-content: center; width: 40px; height: 40px; padding: 0; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: 10px; cursor: pointer; }
  .docs-menu svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
  .docs-menu .i-close, .docs-menu[aria-expanded="true"] .i-open { display: none; }
  .docs-menu[aria-expanded="true"] .i-close { display: inline; }
  .docs-shell { grid-template-columns: minmax(0, 1fr); gap: 0; padding-top: 28px; }
  .docs-side { position: static; max-height: none; overflow: visible; margin: 0 0 28px; padding: 0; }
  .js .docs-side { display: none; }
  .js .docs-side.open { display: block; position: fixed; top: var(--head); right: 0; bottom: 0; left: 0; z-index: 35; margin: 0; padding: 18px 16px 48px; overflow-y: auto; background: var(--bg); }
  .js .docs-side.open .docs-nav a { padding: 9px 10px; font-size: 16px; }
  .menu-open { overflow: hidden; }
  .docs-body h2 { font-size: 21px; }
  .docs-body td code { white-space: normal; }
  .code-head { height: 36px; }
  .hl pre { padding: 12px 14px 14px; font-size: 12.5px; }
  .docs-pager { grid-template-columns: 1fr; }
  .docs-pager .next { grid-column: 1; text-align: left; }
}
@media (max-width: 600px) {
  .docs-top .links { display: none; }
}
@media (max-width: 360px) {
  .docs-label { display: none; }
}
