/* Docs on Astryx Neutral, the same look as the OpenCarMind and TigerOCR docs and buildforpeople.dev.

   Astryx is Meta's open source design system (github.com/meta/astryx). Its components are React and this
   site is Sphinx with pydata-sphinx-theme, so the site takes what does not need React: the Neutral theme's
   tokens (colour roles, radius, shadow, motion, Figtree type) and the way its components look (a quiet top
   bar, tabs with an underline, a filled side navigation, pill buttons, muted cards and banners).
   The tokens are mapped onto the theme's --pst-* variables, then the theme's parts are restyled.

   Token values from @astryxdesign/theme-neutral 0.7.16: Copyright (c) Meta Platforms, Inc. and affiliates.
   MIT License. Figtree: SIL Open Font License 1.1, see fonts/figtree/figtree.LICENSE.txt.
   Dark is true black, as on buildforpeople.dev. */

@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 400;
  src: url("fonts/figtree/figtree-latin-ext-400-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 400;
  src: url("fonts/figtree/figtree-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 500;
  src: url("fonts/figtree/figtree-latin-ext-500-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 500;
  src: url("fonts/figtree/figtree-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 600;
  src: url("fonts/figtree/figtree-latin-ext-600-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 600;
  src: url("fonts/figtree/figtree-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 700;
  src: url("fonts/figtree/figtree-latin-ext-700-normal.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Figtree"; font-style: normal; font-display: swap; font-weight: 700;
  src: url("fonts/figtree/figtree-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---- Astryx tokens ------------------------------------------------------ */
html[data-theme="light"] {
  --color-background-body: #f1f1f1;  --color-background-surface: #ffffff;  --color-background-card: #ffffff;
  --color-background-muted: #f1f1f1; --color-accent: #1b1b1b;              --color-on-accent: #ffffff;
  --color-neutral: #0000000f;        --color-overlay-hover: #0000000d;     --color-overlay-pressed: #0000001a;
  --color-text-primary: #000000;     --color-text-secondary: #474747;      --color-text-info: #0067ce;
  --color-info: #0074e2;             --color-info-muted: #b9d7ff;          --color-border: #00000014;
  --color-border-emphasized: #d4d4d4;
  --color-background-green: #bce0bb; --color-text-green: #00490b;
  --color-background-yellow: #fae19e; --color-text-yellow: #4b3900;
  --color-background-blue: #b9d7ff;  --color-text-blue: #003978;
  --color-background-red: #ffc4be;   --color-text-red: #76000c;
  --color-background-gray: #e2e2e2;  --color-text-gray: #1b1b1b;
  --shadow-med: 0 2px 4px oklch(0 0 0 / 5%), 0 4px 12px oklch(0 0 0 / 10%);
  --shadow-high: 0 4px 6px oklch(0 0 0 / 10%), 0 12px 24px oklch(0 0 0 / 15%);
}
html[data-theme="dark"] {
  --color-background-body: #000000;  --color-background-surface: #1b1b1b;  --color-background-card: #111111;
  --color-background-muted: #1b1b1b; --color-accent: #f1f1f1;              --color-on-accent: #111111;
  --color-neutral: #ffffff1a;        --color-overlay-hover: #ffffff0d;     --color-overlay-pressed: #ffffff1a;
  --color-text-primary: #ffffff;     --color-text-secondary: #9e9e9e;      --color-text-info: #a1caff;
  --color-info: #6d9cfe;             --color-info-muted: #88bcff3d;        --color-border: #ffffff1a;
  --color-border-emphasized: #525252;
  --color-background-green: #2b422b; --color-text-green: #90ca90;
  --color-background-yellow: #453a1c; --color-text-yellow: #eec448;
  --color-background-blue: #253c5a;  --color-text-blue: #a1caff;
  --color-background-red: #5b2b28;   --color-text-red: #ffaea7;
  --color-background-gray: #303030;  --color-text-gray: #d4d4d4;
  --shadow-med: 0 2px 4px oklch(0 0 0 / 30%), 0 4px 12px oklch(0 0 0 / 40%);
  --shadow-high: 0 4px 6px oklch(0 0 0 / 40%), 0 12px 24px oklch(0 0 0 / 50%);
}
html {
  --radius-inner: .375rem; --radius-element: .625rem; --radius-container: .75rem; --radius-page: 1.75rem;
  --radius-full: 9999px; --motion-fast: 125ms; --ease: cubic-bezier(.2, 0, 0, 1);
  --font-figtree: "Figtree", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

/* ---- The tokens on the theme's variables -------------------------------- */
html[data-theme="light"], html[data-theme="dark"] {
  --pst-font-family-base: var(--font-figtree);
  --pst-font-family-heading: var(--font-figtree);
  --pst-font-weight-heading: 600;
  --pst-color-primary: var(--color-text-primary);
  --pst-color-secondary: var(--color-text-info);
  --pst-color-accent: var(--color-text-info);
  --pst-color-link: var(--color-text-info);
  --pst-color-link-hover: var(--color-text-primary);
  --pst-color-link-higher-contrast: var(--color-text-info);
  --pst-color-background: var(--color-background-body);
  --pst-color-on-background: var(--color-background-surface);
  --pst-color-surface: var(--color-background-muted);
  --pst-color-on-surface: var(--color-text-primary);
  --pst-color-text-base: var(--color-text-primary);
  --pst-color-text-muted: var(--color-text-secondary);
  --pst-color-heading-color: var(--color-text-primary);
  --pst-color-border: var(--color-border);
  --pst-color-shadow: transparent;
  --pst-color-inline-code: var(--color-text-primary);
  --pst-color-inline-code-links: var(--color-text-info);
  --pst-color-table-row-hover-bg: var(--color-overlay-hover);
  --pst-color-primary-bg: var(--color-neutral);
  --pst-color-target: var(--color-background-yellow);
}

body { font-family: var(--font-figtree); -webkit-font-smoothing: antialiased; }

/* ---- Top bar: quiet, on the page colour, no shadow ---------------------- */
.bd-header {
  background: var(--color-background-body) !important; box-shadow: none !important;
  border-bottom: 0 !important; backdrop-filter: none;
}
.bd-header .navbar-brand { font-weight: 600; letter-spacing: -.01em; }
.bd-header .navbar-brand img { border-radius: var(--radius-inner); }
.bd-header ul.navbar-nav > li.nav-item > .nav-link {
  font-weight: 500; color: var(--color-text-secondary); border-radius: 0; padding-block: .5rem;
  border-bottom: 2px solid transparent;
}
.bd-header ul.navbar-nav > li.nav-item > .nav-link:hover { color: var(--color-text-primary); text-decoration: none; }
.bd-header ul.navbar-nav > li.nav-item.current > .nav-link,
.bd-header ul.navbar-nav > li.nav-item > .nav-link.active {
  color: var(--color-text-primary); border-bottom-color: var(--color-accent);
}
.bd-header ul.navbar-nav > li.nav-item.current > .nav-link::before { display: none; }
.bd-header .navbar-nav .dropdown-menu {
  background: var(--color-background-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-container); box-shadow: var(--shadow-high); padding: .375rem;
}
.bd-header .navbar-nav .dropdown-menu .dropdown-item { border-radius: var(--radius-inner); }
.bd-header .navbar-nav .dropdown-menu .dropdown-item:hover { background: var(--color-overlay-hover); }

/* Search: a pill like the Astryx command palette trigger. */
.search-button-field {
  border-radius: var(--radius-full) !important; border: 0 !important;
  background: var(--color-neutral) !important; color: var(--color-text-secondary) !important;
  box-shadow: none !important;
}
.search-button-field:hover { background: var(--color-overlay-pressed) !important; color: var(--color-text-primary) !important; }
.search-button-field .kbd-shortcut__modifier, .search-button-field kbd {
  background: transparent; border: 0; box-shadow: none; color: inherit; opacity: .7; font-family: inherit;
}
.search-button__wrapper.show .search-button__search-container {
  border-radius: var(--radius-container); background: var(--color-background-surface);
  border: 1px solid var(--color-border); box-shadow: var(--shadow-high);
}
.bd-search { border-radius: var(--radius-full); border: 1px solid var(--color-border-emphasized); background: var(--color-background-surface); }
.bd-search:focus-within { box-shadow: 0 0 0 2px var(--color-info); }

/* Icon buttons and the versions menu: round, quiet. */
.bd-header .navbar-icon-links .nav-link, .theme-switch-button, .bd-header .btn.version-switcher__button {
  border-radius: var(--radius-full) !important; color: var(--color-text-secondary) !important;
}
.bd-header .navbar-icon-links .nav-link:hover, .theme-switch-button:hover, .bd-header .btn.version-switcher__button:hover {
  background: var(--color-overlay-hover) !important; color: var(--color-text-primary) !important;
}
.bd-header .btn.version-switcher__button { border: 0; background: var(--color-neutral); font-weight: 500; padding-inline: .875rem; }
.version-switcher__menu {
  min-width: 17rem; background: var(--color-background-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-container); box-shadow: var(--shadow-high); padding: .375rem;
}
.version-switcher__menu a { white-space: nowrap; border-radius: var(--radius-inner); }
.version-switcher__menu a.list-group-item { background: transparent; border: 0; color: var(--color-text-primary); }
.version-switcher__menu a.list-group-item:hover { background: var(--color-overlay-hover); }

/* ---- The page tile: sidebar, article and contents on one rounded surface - */
.bd-container { padding: 0 1rem 1rem; }
.bd-container__inner {
  background: var(--color-background-card); border-radius: var(--radius-page);
  max-width: 1440px; margin-inline: auto; padding-inline: .5rem;
}
@media (max-width: 959.98px) {
  .bd-container { padding: 0; }
  .bd-container__inner { border-radius: 0; }
}

/* Left: Astryx side navigation. Group heading small and grey, items fill when current. */
.bd-sidebar-primary { background: transparent; border-right: 0; padding-top: 1.5rem; }
.bd-sidebar-primary .sidebar-primary-items__start { border: 0; }
.bd-links__title {
  font-size: .75rem !important; font-weight: 600 !important; text-transform: none; letter-spacing: 0;
  color: var(--color-text-secondary) !important; margin: 0 0 .5rem .625rem !important;
}
.bd-sidebar-primary .bd-links { margin-right: 0; }
nav.bd-links li > a {
  display: block; padding: .4375rem .625rem !important; margin: 1px 0; border-radius: var(--radius-element);
  color: var(--color-text-primary) !important; font-size: .875rem; line-height: 1.35;
  box-shadow: none !important; border: 0 !important; text-decoration: none !important;
}
nav.bd-links li > a:hover { background: var(--color-overlay-hover); }
nav.bd-links li.current > a, nav.bd-links .current > a.current {
  background: var(--color-neutral) !important; font-weight: 600 !important; color: var(--color-text-primary) !important;
}
nav.bd-links li > a.reference.current::before, nav.bd-links .current > a::before { display: none !important; }
nav.bd-links ul ul { padding-left: .625rem; }
.bd-sidebar-primary #pst-collapse-sidebar-button {
  gap: .45rem; padding: .3rem .625rem; border-radius: var(--radius-full); color: var(--color-text-secondary);
  font-size: .8125rem; background: transparent; border: 0;
}
.bd-sidebar-primary #pst-collapse-sidebar-button .pst-icon,
.bd-sidebar-primary #pst-collapse-sidebar-button .pst-collapse-sidebar-label,
.bd-sidebar-primary #pst-collapse-sidebar-button .pst-expand-sidebar-label { color: inherit; text-decoration: none; }
.bd-sidebar-primary #pst-collapse-sidebar-button:hover { color: var(--color-text-primary); background: var(--color-overlay-hover); }

/* Right: "On this page". */
.bd-sidebar-secondary { background: transparent; border-left: 0; padding-top: 1.5rem; }
.bd-sidebar-secondary .onthispage, .bd-sidebar-secondary .page-toc .onthispage {
  font-size: .75rem; font-weight: 600; color: var(--color-text-secondary); text-transform: none; margin-bottom: .5rem;
}
.bd-sidebar-secondary .onthispage i { display: none; }
.bd-toc-nav nav, .bd-toc .page-toc, .bd-sidebar-secondary nav.page-toc { border-left: 0 !important; }
.bd-sidebar-secondary .toc-entry a.nav-link {
  border-left: 0 !important; box-shadow: none !important; padding: .25rem .5rem !important; margin-left: 0;
  border-radius: var(--radius-inner); font-size: .8125rem; color: var(--color-text-secondary) !important;
}
.bd-sidebar-secondary .toc-entry a.nav-link:hover { color: var(--color-text-primary) !important; background: var(--color-overlay-hover); text-decoration: none; }
.bd-sidebar-secondary .toc-entry a.nav-link.active { color: var(--color-text-primary) !important; font-weight: 600; background: transparent; }
.bd-sidebar-secondary .editthispage a, .bd-sidebar-secondary .tocsection a { color: var(--color-text-secondary); font-size: .8125rem; }

/* ---- The article ---------------------------------------------------------- */
.bd-main .bd-content .bd-article-container { max-width: 52rem; padding-top: 1.5rem; }
.bd-article { font-size: 1rem; line-height: 1.65; }
.bd-article h1 { font-size: 2.25rem; font-weight: 600; letter-spacing: -.02em; line-height: 1.15; margin-bottom: .75rem; }
.bd-article h2 { font-size: 1.5rem; font-weight: 600; letter-spacing: -.01em; margin-top: 2.5rem; }
.bd-article h3 { font-size: 1.1875rem; font-weight: 600; margin-top: 2rem; }
.bd-article h4 { font-size: 1rem; font-weight: 600; }
.bd-article a { text-underline-offset: 2px; }
.bd-article .headerlink { color: var(--color-text-secondary); }
.bd-header-article .bd-breadcrumbs .breadcrumb-item { font-size: .8125rem; color: var(--color-text-secondary); }
.bd-header-article .bd-breadcrumbs .breadcrumb-item a { color: var(--color-text-secondary); text-decoration: none; }
.bd-header-article .bd-breadcrumbs .breadcrumb-item a:hover { color: var(--color-text-primary); }
.bd-header-article .bd-breadcrumbs .breadcrumb-item.active { color: var(--color-text-primary); font-weight: 500; }

/* Code: muted containers, no border. Inline code: a small neutral chip. */
.bd-article div.highlight, .bd-article div.highlight pre {
  background: var(--color-background-muted) !important; border: 0 !important; border-radius: var(--radius-container) !important;
}
.bd-article div.highlight pre { padding: 1rem 1.125rem; font-size: .8125rem; line-height: 1.6; }
html[data-theme="dark"] .bd-article div.highlight, html[data-theme="dark"] .bd-article div.highlight pre { background: #161616 !important; }
.bd-article code.literal, .bd-article p code, .bd-article li code, .bd-article td code {
  background: var(--color-neutral); border: 0; border-radius: var(--radius-inner); padding: .1em .35em;
  color: var(--color-text-primary); font-size: .875em;
}
.bd-article a code.literal { color: var(--color-text-info); }
button.copybtn {
  border-radius: var(--radius-full); border: 0; background: var(--color-background-card); color: var(--color-text-secondary);
  box-shadow: var(--shadow-med);
}

/* Admonitions: Astryx banners. Tonal fill, rounded, no side bar or shadow. */
.bd-article .admonition, .bd-article div.admonition {
  border: 0 !important; border-radius: var(--radius-container) !important; box-shadow: none !important;
  background: var(--color-background-muted) !important; padding: .875rem 1.125rem !important;
}
.bd-article .admonition > .admonition-title {
  background: transparent !important; font-weight: 600; padding: 0 0 .25rem 1.75rem !important; margin: 0 !important;
}
.bd-article .admonition > .admonition-title::after { left: 0 !important; top: .05rem; }
.bd-article .admonition.note, .bd-article .admonition.tip, .bd-article .admonition.hint, .bd-article .admonition.seealso { background: var(--color-background-blue) !important; }
.bd-article .admonition.note > .admonition-title, .bd-article .admonition.tip > .admonition-title,
.bd-article .admonition.hint > .admonition-title, .bd-article .admonition.seealso > .admonition-title,
.bd-article .admonition.note > .admonition-title::after, .bd-article .admonition.tip > .admonition-title::after,
.bd-article .admonition.hint > .admonition-title::after, .bd-article .admonition.seealso > .admonition-title::after { color: var(--color-text-blue) !important; }
.bd-article .admonition.warning, .bd-article .admonition.caution, .bd-article .admonition.attention, .bd-article .admonition.important { background: var(--color-background-yellow) !important; }
.bd-article .admonition.warning > .admonition-title, .bd-article .admonition.caution > .admonition-title,
.bd-article .admonition.attention > .admonition-title, .bd-article .admonition.important > .admonition-title,
.bd-article .admonition.warning > .admonition-title::after, .bd-article .admonition.caution > .admonition-title::after,
.bd-article .admonition.attention > .admonition-title::after, .bd-article .admonition.important > .admonition-title::after { color: var(--color-text-yellow) !important; }
.bd-article .admonition.danger, .bd-article .admonition.error { background: var(--color-background-red) !important; }
.bd-article .admonition.danger > .admonition-title, .bd-article .admonition.error > .admonition-title,
.bd-article .admonition.danger > .admonition-title::after, .bd-article .admonition.error > .admonition-title::after { color: var(--color-text-red) !important; }
.bd-article .admonition > :last-child { margin-bottom: 0; }

/* Tables: hairlines, a muted header. */
.bd-article table { border-collapse: separate; border-spacing: 0; border: 1px solid var(--color-border); border-radius: var(--radius-container); overflow: hidden; }
.bd-article table th { background: var(--color-background-muted); font-weight: 600; border: 0; border-bottom: 1px solid var(--color-border); }
.bd-article table td { border: 0; border-top: 1px solid var(--color-border); }
.bd-article table tr:first-child td { border-top: 0; }
.bd-article table td, .bd-article table th { vertical-align: top; padding: .5rem .75rem; }

/* sphinx-design: quiet grey cards that lift on hover, pill buttons, underline tabs. */
.bd-article .sd-card {
  --sd-color-card-background: var(--color-background-muted); --sd-color-card-border: transparent;
  background: var(--color-background-muted) !important; border: 0 !important; border-radius: var(--radius-container) !important;
  box-shadow: none !important; transition: background-color var(--motion-fast) var(--ease), box-shadow var(--motion-fast) var(--ease);
  position: relative; overflow: hidden;
}
.bd-article .sd-card:hover { background: var(--color-background-card) !important; box-shadow: var(--shadow-med) !important; }
html[data-theme="dark"] .bd-article .sd-card:hover { background: var(--color-background-surface) !important; }
.bd-article .sd-card .sd-card-header, .bd-article .sd-card .sd-card-footer, .bd-article .sd-card .sd-card-body {
  background: transparent !important; border-color: var(--color-border);
}
.bd-article .sd-card .sd-card-title { font-weight: 600; }
.bd-article .sd-card .sd-card-text { color: var(--color-text-secondary); }
.bd-article .sd-btn, .bd-article a.sd-btn { border-radius: var(--radius-full) !important; font-weight: 500; }
.bd-article .sd-btn-primary { background: var(--color-accent) !important; border-color: var(--color-accent) !important; color: var(--color-on-accent) !important; }
.bd-article .sd-badge { border-radius: var(--radius-full); font-weight: 600; }
.bd-article .sd-tab-set > label { font-weight: 500; color: var(--color-text-secondary); border-bottom: 2px solid transparent; }
.bd-article .sd-tab-set > input:checked + label { color: var(--color-text-primary); border-bottom-color: var(--color-accent); }
.bd-article details.sd-dropdown { border: 0; border-radius: var(--radius-container); background: var(--color-background-muted); box-shadow: none; }
.bd-article details.sd-dropdown > summary { background: transparent; font-weight: 600; }
.bd-article details { border-radius: var(--radius-container); }
.bd-article details > summary { cursor: pointer; }

/* Previous and next: two muted tiles, as in the TigerOCR docs. */
.prev-next-area { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-top: 3rem; }
.prev-next-area a {
  display: flex; align-items: center; gap: .75rem; padding: .875rem 1.125rem; border-radius: var(--radius-container);
  background: var(--color-background-muted); color: var(--color-text-primary); text-decoration: none; max-width: none;
  transition: background-color var(--motion-fast) var(--ease);
}
.prev-next-area a:hover { background: color-mix(in srgb, var(--color-text-primary) 8%, var(--color-background-muted)); }
.prev-next-area a.right-next { grid-column: 2; justify-content: flex-end; text-align: right; }
.prev-next-area a p.prev-next-title { color: var(--color-text-primary) !important; font-weight: 600; text-decoration: none; }
.prev-next-area a p.prev-next-subtitle { color: var(--color-text-secondary); text-transform: capitalize; font-size: .8125rem; }
.prev-next-area a i { color: var(--color-text-secondary); }

.bd-footer { background: transparent; border-top: 0; font-size: .8125rem; color: var(--color-text-secondary); }
.bd-footer a { color: var(--color-text-secondary); }

/* Pointer light, as on buildforpeople.dev: ocm.js tracks the pointer in --gx and --gy. */
.ocm-glow { position: relative; }
.ocm-glow > .glow-layer {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0;
  transition: opacity .25s ease;
  background: radial-gradient(266px circle at var(--gx, 50%) var(--gy, 0%),
    color-mix(in srgb, var(--color-info) 7%, transparent), transparent 62%);
}
.ocm-glow:hover > .glow-layer { opacity: 1; }
@media (hover: none), (prefers-reduced-motion: reduce) { .ocm-glow > .glow-layer { display: none; } }

/* ---- Page content kept from the previous stylesheet ---------------------- */
/* Board captures and renders: screens sit side by side, wide figures fill the column. */
.ocm-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-start; margin: 1rem 0; }
.ocm-row img.ocm-shot { margin: 0; }
img.ocm-shot { max-width: 100%; height: auto; border-radius: var(--radius-container); }
img.ocm-figure { width: 100%; height: auto; border-radius: var(--radius-container); margin: .5rem 0 1rem; }
html[data-theme="light"] img.ocm-figure, html[data-theme="light"] img.ocm-shot { border: 1px solid var(--color-border-emphasized); }
.bd-article img { border-radius: var(--radius-container); }
/* The theme dims images in dark mode, which turns the white figures grey. Show them as drawn. */
html[data-theme="dark"] .bd-content img:not(.only-dark):not(.dark-light) { filter: none !important; }
p.ocm-caption { font-size: .875rem; color: var(--color-text-secondary); }
.ocm-hero { font-size: 1.15rem; line-height: 1.6; color: var(--color-text-secondary); }

/* Header comments and protocol listings wrap instead of scrolling sideways. */
div.highlight-text pre { white-space: pre-wrap; }

/* Top bar: keep it on one row from the theme's desktop breakpoint (992px) up.
   The theme lets the header items wrap, which pushed search, versions and the
   icons onto a second row on iPad landscape and small laptops. */
@media (min-width: 992px) {
  .bd-header .navbar-header-items { flex-wrap: nowrap; }
  .bd-header .navbar-header-items__center { min-width: 0; }
  .bd-header .navbar-header-items__center .navbar-nav { flex-wrap: nowrap; }
  .bd-header .navbar-header-items__center .nav-link { white-space: nowrap; }
  .bd-header .navbar-header-items__end { flex-shrink: 0; flex-wrap: nowrap; }
}

/* Under 1280px the search field shrinks to its icon. Ctrl+K still opens it. */
@media (min-width: 992px) and (max-width: 1279.98px) {
  .bd-header .search-button-field { width: 2.4rem; height: 2.4rem; padding: 0; justify-content: center; }
  .bd-header .search-button-field .search-button__default-text,
  .bd-header .search-button-field .search-button__kbd-shortcut { display: none; }
}

/* Between 992px and 1100px the links sit a little closer, so the row never touches the edge. */
@media (min-width: 992px) and (max-width: 1099.98px) {
  .bd-header .navbar-header-items__center ul.navbar-nav > li.nav-item > .nav-link { padding-inline: .25rem; }
}
