pre code.hljs {
  display: block;
  overflow-x: auto;
  padding: 1em
}
code.hljs {
  padding: 3px 5px
}
/*!
  Theme: GitHub Dark
  Description: Dark theme as seen on github.com
  Author: github.com
  Maintainer: @Hirse
  Updated: 2021-05-15

  Outdated base version: https://github.com/primer/github-syntax-dark
  Current colors taken from GitHub's CSS
*/
.hljs {
  color: #c9d1d9;
  background: #0d1117
}
.hljs-doctag,
.hljs-keyword,
.hljs-meta .hljs-keyword,
.hljs-template-tag,
.hljs-template-variable,
.hljs-type,
.hljs-variable.language_ {
  /* prettylights-syntax-keyword */
  color: #ff7b72
}
.hljs-title,
.hljs-title.class_,
.hljs-title.class_.inherited__,
.hljs-title.function_ {
  /* prettylights-syntax-entity */
  color: #d2a8ff
}
.hljs-attr,
.hljs-attribute,
.hljs-literal,
.hljs-meta,
.hljs-number,
.hljs-operator,
.hljs-variable,
.hljs-selector-attr,
.hljs-selector-class,
.hljs-selector-id {
  /* prettylights-syntax-constant */
  color: #79c0ff
}
.hljs-regexp,
.hljs-string,
.hljs-meta .hljs-string {
  /* prettylights-syntax-string */
  color: #a5d6ff
}
.hljs-built_in,
.hljs-symbol {
  /* prettylights-syntax-variable */
  color: #ffa657
}
.hljs-comment,
.hljs-code,
.hljs-formula {
  /* prettylights-syntax-comment */
  color: #8b949e
}
.hljs-name,
.hljs-quote,
.hljs-selector-tag,
.hljs-selector-pseudo {
  /* prettylights-syntax-entity-tag */
  color: #7ee787
}
.hljs-subst {
  /* prettylights-syntax-storage-modifier-import */
  color: #c9d1d9
}
.hljs-section {
  /* prettylights-syntax-markup-heading */
  color: #1f6feb;
  font-weight: bold
}
.hljs-bullet {
  /* prettylights-syntax-markup-list */
  color: #f2cc60
}
.hljs-emphasis {
  /* prettylights-syntax-markup-italic */
  color: #c9d1d9;
  font-style: italic
}
.hljs-strong {
  /* prettylights-syntax-markup-bold */
  color: #c9d1d9;
  font-weight: bold
}
.hljs-addition {
  /* prettylights-syntax-markup-inserted */
  color: #aff5b4;
  background-color: #033a16
}
.hljs-deletion {
  /* prettylights-syntax-markup-deleted */
  color: #ffdcd7;
  background-color: #67060c
}
.hljs-char.escape_,
.hljs-link,
.hljs-params,
.hljs-property,
.hljs-punctuation,
.hljs-tag {
  /* purposely ignored */
  
}/*
 * Docs layout + component styling, layered on top of the themed Bootstrap
 * bundle. A highlight.js theme is prepended to this file at build time
 * (see build:docs-assets), so this file owns everything except token colors.
 */

:root {
  --docs-bg: #0d1117;
  --docs-text: #c9d1d9;
  --docs-heading: #f0f6fc;
  --docs-accent: #8b5cf6;
  --docs-accent-soft: rgba(139, 92, 246, 0.15);
  --docs-border: #21262d;
  --docs-surface: #12161c;
  --docs-surface-2: #0b0e13;
  --docs-muted: #8b949e;
  --docs-headroom-bg: #30363d;
  --docs-headroom-fg: #adbac7;
  /* Code blocks and diagrams share a surface, a shade off the page. */
  --docs-code-bg: #0d1117;
  --docs-code-border: #30363d;
  --docs-code-label: #8b949e;
  --docs-sidebar-w: 250px;
  --docs-toc-w: 220px;
}

:root[data-bs-theme='light'] {
  --docs-bg: #ffffff;
  --docs-text: #24292f;
  --docs-heading: #1f2328;
  --docs-accent: #7c3aed;
  --docs-accent-soft: rgba(124, 58, 237, 0.12);
  --docs-border: #d0d7de;
  --docs-surface: #f6f8fa;
  --docs-surface-2: #eaeef2;
  --docs-muted: #57606a;
  --docs-headroom-bg: #e2e8ef;
  --docs-headroom-fg: #57606a;
  --docs-code-bg: #f6f8fa;
  --docs-code-border: #d0d7de;
  --docs-code-label: #57606a;
}

body {
  background: var(--docs-bg);
  color: var(--docs-text);
}

/* ── Shell / layout ─────────────────────────────────────────────────────── */
.docs-shell {
  display: grid;
  grid-template-columns: var(--docs-sidebar-w) minmax(0, 1fr) var(--docs-toc-w);
  gap: 2.5rem;
  max-width: 1400px;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 4rem;
  align-items: start;
}
.docs-shell-nav {
  position: sticky;
  top: 1rem;
  max-height: calc(100vh - 2rem);
  overflow-y: auto;
}
.docs-shell-toc {
  position: sticky;
  top: 1rem;
  max-height: calc(100vh - 2rem);
  overflow-y: auto;
}
.docs-main {
  min-width: 0;
}

/* The top header + theme toggle are the shared .site-header (see site.css).
   Site links inside the mobile drawer, shown only on small screens. */
.docs-drawer-links {
  display: none;
}

/* ── Version switcher ───────────────────────────────────────────────────── */
.docs-versions {
  display: flex;
  gap: 0.25rem;
  margin-bottom: 0.75rem;
}
.docs-version {
  flex: 1;
  text-align: center;
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--docs-border);
  border-radius: 0.4rem;
  font-size: 0.8rem;
  text-transform: capitalize;
  color: var(--docs-muted);
  text-decoration: none;
}
.docs-version.active {
  background: var(--docs-accent);
  border-color: var(--docs-accent);
  color: #fff;
}

/* ── Search ─────────────────────────────────────────────────────────────── */
.docs-search {
  width: 100%;
  padding: 0.4rem 0.65rem;
  margin-bottom: 0.5rem;
  background: var(--docs-surface-2);
  border: 1px solid var(--docs-border);
  border-radius: 0.4rem;
  color: inherit;
  font-size: 0.85rem;
}
.docs-search:focus {
  outline: none;
  border-color: var(--docs-accent);
}
.docs-search-results:not(:empty) {
  margin-bottom: 0.75rem;
  border: 1px solid var(--docs-border);
  border-radius: 0.4rem;
  overflow: hidden;
}
.docs-search-hit {
  display: flex;
  flex-direction: column;
  padding: 0.4rem 0.65rem;
  text-decoration: none;
  border-bottom: 1px solid var(--docs-border);
}
.docs-search-hit:last-child {
  border-bottom: none;
}
.docs-search-hit:hover {
  background: var(--docs-accent-soft);
}
.docs-search-hit-title {
  font-size: 0.85rem;
  color: var(--docs-text);
}
.docs-search-hit-group {
  font-size: 0.7rem;
  color: var(--docs-muted);
}

/* The matched snippet. Two lines at most: a result list is for choosing a page, and a
   third line of context turns six results into a page of prose to read instead. */
.docs-search-hit-excerpt {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 0.8125rem;
  color: var(--bs-secondary-color);
}
.docs-search-hit-excerpt mark {
  padding: 0;
  background: rgba(var(--bs-primary-rgb), 0.22);
  color: inherit;
  border-radius: 0.15rem;
}

/* Only ever filled in when a channel published without a full-text index, so it
   takes no space in the normal case. */
.docs-search-note:empty {
  display: none;
}
.docs-search-note {
  margin: -0.25rem 0 0.75rem;
  font-size: 0.75rem;
  line-height: 1.4;
  color: var(--docs-muted);
}

/* ── Sidebar nav ────────────────────────────────────────────────────────── */
.docs-nav-group {
  margin-bottom: 1.25rem;
}
.docs-nav-heading {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--docs-muted);
  margin: 0 0 0.4rem;
}
.docs-nav-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.docs-nav-link {
  display: block;
  padding: 0.28rem 0.65rem;
  border-radius: 0.35rem;
  font-size: 0.88rem;
  color: var(--docs-text);
  text-decoration: none;
  border-left: 2px solid transparent;
}
.docs-nav-link:hover {
  background: var(--docs-surface);
  color: var(--docs-heading);
}
.docs-nav-link.active {
  color: var(--docs-heading);
  background: var(--docs-accent-soft);
  border-left-color: var(--docs-accent);
  font-weight: 600;
}

/* ── Breadcrumb ─────────────────────────────────────────────────────────── */
.docs-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  align-items: center;
  font-size: 0.8rem;
  color: var(--docs-muted);
  margin-bottom: 1rem;
}
.docs-breadcrumb a {
  color: var(--docs-muted);
  text-decoration: none;
}
.docs-breadcrumb a:hover {
  color: var(--docs-accent);
}
.docs-breadcrumb-sep {
  opacity: 0.5;
}

/* ── Article typography ─────────────────────────────────────────────────── */
.docs-article {
  max-width: 46rem;
}
.docs-article h1,
.docs-article h2,
.docs-article h3 {
  color: var(--docs-heading);
}
.docs-article h1 {
  font-size: 2.15rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
}
.docs-article h2 {
  font-size: 1.5rem;
  font-weight: 650;
  margin: 2.25rem 0 0.85rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--docs-border);
}
.docs-article h3 {
  font-size: 1.2rem;
  margin: 1.75rem 0 0.6rem;
}
.docs-article h2 a.anchor,
.docs-article h3 a.anchor {
  opacity: 0;
  margin-left: 0.4rem;
  color: var(--docs-accent);
  text-decoration: none;
}
.docs-article h2:hover a.anchor,
.docs-article h3:hover a.anchor {
  opacity: 1;
}
.docs-article p,
.docs-article li {
  line-height: 1.7;
}
.docs-article a {
  color: var(--docs-accent);
  text-underline-offset: 2px;
}
.docs-article :not(pre) > code {
  background: var(--docs-surface);
  border: 1px solid var(--docs-border);
  border-radius: 0.3rem;
  padding: 0.1rem 0.35rem;
  font-size: 0.86em;
}
.docs-article table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0;
  font-size: 0.9rem;
}
.docs-article th,
.docs-article td {
  border: 1px solid var(--docs-border);
  padding: 0.5rem 0.7rem;
  text-align: left;
}
.docs-article th {
  background: var(--docs-surface);
}

/* ── Code blocks ────────────────────────────────────────────────────────── */
.code-block {
  position: relative;
  margin: 1.25rem 0;
  border: 1px solid var(--docs-code-border);
  border-radius: 0.5rem;
  background: var(--docs-code-bg);
  overflow: hidden;
}
.code-block pre {
  margin: 0;
  padding: 1rem 1.1rem;
  overflow-x: auto;
}
.code-block code {
  font-size: 0.85rem;
  background: none;
  border: none;
  padding: 0;
}
.code-lang {
  position: absolute;
  top: 0.5rem;
  right: 3.6rem;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--docs-code-label);
}
.copy-btn {
  position: absolute;
  top: 0.45rem;
  right: 0.5rem;
  padding: 0.15rem 0.5rem;
  font-size: 0.7rem;
  color: #8b949e;
  background: #161b22;
  border: 1px solid #30363d;
  border-radius: 0.3rem;
  cursor: pointer;
}
.copy-btn:hover {
  color: #fff;
  border-color: var(--docs-accent);
}

/* ── Callouts ───────────────────────────────────────────────────────────── */
.callout {
  margin: 1.25rem 0;
  padding: 0.85rem 1.1rem;
  border: 1px solid var(--docs-border);
  border-left-width: 3px;
  border-radius: 0.4rem;
  background: var(--docs-surface);
}
.callout > :last-child {
  margin-bottom: 0;
}
.callout-title {
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}
.callout-note {
  border-left-color: #58a6ff;
}
.callout-note .callout-title {
  color: #58a6ff;
}
.callout-tip {
  border-left-color: #3fb950;
}
.callout-tip .callout-title {
  color: #3fb950;
}
.callout-important {
  border-left-color: var(--docs-accent);
}
.callout-important .callout-title {
  color: var(--docs-accent);
}
.callout-warning {
  border-left-color: #d29922;
}
.callout-warning .callout-title {
  color: #d29922;
}
.callout-caution {
  border-left-color: #f85149;
}
.callout-caution .callout-title {
  color: #f85149;
}

/* ── Docs index ─────────────────────────────────────────────────────────────
   The docs home: every group, every page, and each page's own description on its
   own line so the list scans as a table of contents rather than a wall of links. */
.docs-index-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.docs-index-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--docs-border);
}
.docs-index-list li:last-child {
  border-bottom: none;
}
.docs-index-list a {
  font-weight: 600;
}
.docs-index-desc {
  display: block;
  font-size: 0.875rem;
  color: var(--docs-muted);
}

/* ── Disclosure blocks ──────────────────────────────────────────────────────
   The docs use <details>/<summary> for progressive disclosure: extra install
   methods, channel switching, the scriptable setup path. Raw HTML passes through
   marked untouched, so they worked and toggled but wore browser defaults, which
   sat oddly beside the callouts they appear next to. Same container aesthetic as
   .callout above, and the same tokens, so both themes follow whatever the
   callouts follow. */
.docs-article details {
  margin: 1.25rem 0;
  border: 1px solid var(--docs-border);
  border-radius: 0.4rem;
  background: var(--docs-surface);
}
.docs-article summary {
  /* The affordance. Padding lives here rather than on the container so the whole
     row is the click target, open or closed. */
  padding: 0.7rem 1.1rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-radius: 0.4rem;
}
/* Safari still paints its own triangle through `list-style: none`. */
.docs-article summary::-webkit-details-marker {
  display: none;
}
.docs-article summary::before {
  content: '▸';
  color: var(--docs-accent);
  font-size: 0.85em;
  /* Rotation about the glyph's own centre, so it does not drift as it turns. */
  transition: transform 0.15s ease;
}
.docs-article details[open] > summary::before {
  transform: rotate(90deg);
}
.docs-article summary:hover {
  color: var(--docs-accent);
}
.docs-article summary:focus-visible {
  outline: 2px solid var(--docs-accent);
  outline-offset: -2px;
}
/* Interior spacing: without this the first paragraph or fenced block after the
   summary touches the container edge, and a code block bleeds into the border. */
.docs-article details[open] > summary {
  border-bottom: 1px solid var(--docs-border);
  border-radius: 0.4rem 0.4rem 0 0;
}
.docs-article details > *:not(summary) {
  margin-left: 1.1rem;
  margin-right: 1.1rem;
}
.docs-article details > *:not(summary):first-of-type {
  margin-top: 0.9rem;
}
.docs-article details > *:last-child {
  margin-bottom: 0.9rem;
}

/* ── Syntax highlighting in light mode ──────────────────────────────────── */
/*
 * The build prepends highlight.js's github-dark theme, which is right for dark
 * mode and unreadable on a light page. These re-colour the same token classes
 * with the values from highlight.js's github (light) theme, scoped to the light
 * color mode so dark mode is untouched.
 */
:root[data-bs-theme='light'] .hljs {
  color: #24292e;
  background: transparent;
}
:root[data-bs-theme='light'] .hljs-doctag,
:root[data-bs-theme='light'] .hljs-keyword,
:root[data-bs-theme='light'] .hljs-meta .hljs-keyword,
:root[data-bs-theme='light'] .hljs-template-tag,
:root[data-bs-theme='light'] .hljs-template-variable,
:root[data-bs-theme='light'] .hljs-type,
:root[data-bs-theme='light'] .hljs-variable.language_ {
  color: #d73a49;
}
:root[data-bs-theme='light'] .hljs-title,
:root[data-bs-theme='light'] .hljs-title.class_,
:root[data-bs-theme='light'] .hljs-title.class_.inherited__,
:root[data-bs-theme='light'] .hljs-title.function_ {
  color: #6f42c1;
}
:root[data-bs-theme='light'] .hljs-attr,
:root[data-bs-theme='light'] .hljs-attribute,
:root[data-bs-theme='light'] .hljs-literal,
:root[data-bs-theme='light'] .hljs-meta,
:root[data-bs-theme='light'] .hljs-number,
:root[data-bs-theme='light'] .hljs-operator,
:root[data-bs-theme='light'] .hljs-variable,
:root[data-bs-theme='light'] .hljs-selector-attr,
:root[data-bs-theme='light'] .hljs-selector-class,
:root[data-bs-theme='light'] .hljs-selector-id {
  color: #005cc5;
}
:root[data-bs-theme='light'] .hljs-regexp,
:root[data-bs-theme='light'] .hljs-string,
:root[data-bs-theme='light'] .hljs-meta .hljs-string {
  color: #032f62;
}
:root[data-bs-theme='light'] .hljs-built_in,
:root[data-bs-theme='light'] .hljs-symbol {
  color: #e36209;
}
:root[data-bs-theme='light'] .hljs-comment,
:root[data-bs-theme='light'] .hljs-code,
:root[data-bs-theme='light'] .hljs-formula {
  color: #6a737d;
}
:root[data-bs-theme='light'] .hljs-name,
:root[data-bs-theme='light'] .hljs-quote,
:root[data-bs-theme='light'] .hljs-selector-tag,
:root[data-bs-theme='light'] .hljs-selector-pseudo {
  color: #22863a;
}
:root[data-bs-theme='light'] .hljs-subst {
  color: #24292e;
}
:root[data-bs-theme='light'] .hljs-section {
  color: #005cc5;
  font-weight: bold;
}
:root[data-bs-theme='light'] .hljs-bullet {
  color: #735c0f;
}
:root[data-bs-theme='light'] .hljs-emphasis {
  color: #24292e;
  font-style: italic;
}
:root[data-bs-theme='light'] .hljs-strong {
  color: #24292e;
  font-weight: bold;
}
:root[data-bs-theme='light'] .hljs-addition {
  color: #22863a;
  background-color: #f0fff4;
}
:root[data-bs-theme='light'] .hljs-deletion {
  color: #b31d28;
  background-color: #ffeef0;
}

/* ── Mermaid diagrams ───────────────────────────────────────────────────── */
pre.mermaid {
  margin: 1.5rem 0;
  padding: 1.25rem;
  text-align: center;
  background: var(--docs-code-bg);
  border: 1px solid var(--docs-code-border);
  border-radius: 0.5rem;
  overflow-x: auto;
}
pre.mermaid:not([data-processed]) {
  color: var(--docs-muted);
  font-size: 0.8rem;
}

/* ── Context-region budget bar (context.md) ─────────────────────────────── */
.ctx-bar {
  display: flex;
  margin: 1.25rem 0;
  border: 1px solid var(--docs-border);
  border-radius: 0.5rem;
  overflow: hidden;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
  color: #fff;
}
.ctx-seg {
  padding: 0.6rem 0.3rem;
}
.ctx-pinned {
  background: #8b5cf6;
}
.ctx-codebase {
  background: #6366f1;
}
.ctx-conversation {
  background: #3b82f6;
}
.ctx-history {
  background: #0ea5e9;
}
.ctx-headroom {
  background: var(--docs-headroom-bg);
  color: var(--docs-headroom-fg);
}

/* ── On-page TOC ────────────────────────────────────────────────────────── */
.docs-toc-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--docs-muted);
  margin: 0 0 0.5rem;
}
.docs-toc-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-left: 1px solid var(--docs-border);
}
.docs-toc-list a {
  display: block;
  padding: 0.2rem 0.75rem;
  font-size: 0.82rem;
  color: var(--docs-muted);
  text-decoration: none;
  margin-left: -1px;
  border-left: 1px solid transparent;
}
.docs-toc-list a:hover {
  color: var(--docs-accent);
  border-left-color: var(--docs-accent);
}
.docs-toc-l3 a {
  padding-left: 1.5rem;
}

/* ── Prev / next + edit ─────────────────────────────────────────────────── */
.docs-page-actions {
  display: flex;
  gap: 1.25rem;
  margin-top: 2rem;
}
.docs-edit {
  display: inline-block;
  font-size: 0.82rem;
  color: var(--docs-muted);
  text-decoration: none;
}
.docs-edit:hover {
  color: var(--docs-accent);
}
.docs-prevnext {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--docs-border);
}
.docs-prevnext-link {
  display: flex;
  flex-direction: column;
  padding: 0.75rem 1rem;
  border: 1px solid var(--docs-border);
  border-radius: 0.5rem;
  text-decoration: none;
  min-width: 0;
}
.docs-prevnext-link.next {
  text-align: right;
  margin-left: auto;
}
.docs-prevnext-link:hover {
  border-color: var(--docs-accent);
}
.docs-prevnext-dir {
  font-size: 0.72rem;
  color: var(--docs-muted);
}
.docs-prevnext-title {
  font-size: 0.95rem;
  color: var(--docs-text);
}

/* ── Responsive: mobile nav drawer ──────────────────────────────────────── */
@media (max-width: 1100px) {
  .docs-shell {
    grid-template-columns: var(--docs-sidebar-w) minmax(0, 1fr);
  }
  .docs-shell-toc {
    display: none;
  }
}

@media (max-width: 800px) {
  .docs-shell {
    grid-template-columns: minmax(0, 1fr);
  }
  /* The sidebar becomes a slide-in overlay drawer; the shared header
     hamburger toggles html[data-nav-open]. */
  .docs-shell-nav {
    position: fixed;
    inset: 0 auto 0 0;
    width: 280px;
    max-width: 85vw;
    z-index: 1040;
    margin: 0;
    padding: 1.25rem;
    background: var(--docs-surface-2);
    border-right: 1px solid var(--docs-border);
    transform: translateX(-100%);
    transition: transform 0.2s ease;
    max-height: none;
    overflow-y: auto;
  }
  html[data-nav-open] .docs-shell-nav {
    transform: translateX(0);
  }
  html[data-nav-open] .site-nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1035;
    background: rgba(0, 0, 0, 0.5);
  }
  .docs-drawer-links {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--docs-border);
  }
  .docs-drawer-links a {
    color: var(--docs-muted);
    text-decoration: none;
    font-size: 0.9rem;
  }
}
