/* SPDX-License-Identifier: GPL-2.0-or-later */
/* Shared by zaryob.github.io, kilavuzlar and syscall. Sync with scripts/sync_console_theme.py. */
@font-face { font-family: "IBM Plex Mono"; src: url("fonts/IBMPlexMono-Regular.woff2") format("woff2"); font-style: normal; font-weight: 400; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("fonts/IBMPlexMono-Medium.woff2") format("woff2"); font-style: normal; font-weight: 500 700; font-display: swap; }
:root {
  color-scheme: light;
  --paper: #f5f3ed; --surface: #eeece5; --wash: #e8e6df;
  --ink: #252a30; --muted: #59616c; --line: #c7c9c8;
  --accent: #815310; --accent-dark: #815310; --link: #815310;
  --red: #815310; --dark: #eeece5; --success: #37643b;
  --warning: #815310; --danger: #a02d35; --selection: #ded5bd; --control-border: #9d814f;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Consolas, monospace;
  --shell-width: 1440px;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #171a1f; --surface: #20242b; --wash: #272c34;
  --ink: #dce0e6; --muted: #a5adb8; --line: #363e49;
  --accent: #e2b56f; --accent-dark: #e2b56f; --link: #e2b56f;
  --red: #e2b56f; --dark: #20242b; --success: #a7ca9b;
  --warning: #e2b56f; --danger: #f2a0a3; --selection: #48402d; --control-border: #8e7959;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --paper: #171a1f; --surface: #20242b; --wash: #272c34;
    --ink: #dce0e6; --muted: #a5adb8; --line: #363e49;
    --accent: #e2b56f; --accent-dark: #e2b56f; --link: #e2b56f;
    --red: #e2b56f; --dark: #20242b; --success: #a7ca9b;
    --warning: #e2b56f; --danger: #f2a0a3; --selection: #48402d; --control-border: #8e7959;
  }
}
* { box-sizing: border-box; }
html { scroll-padding-top: 6rem; }
body.console-site { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.8 var(--font-mono); font-synthesis: none; }
.console-site :is(h1,h2,h3,h4,h5,h6,button,input,select,textarea,code,pre,kbd,summary) { font-family: var(--font-mono); letter-spacing: 0; }
.console-site :is(h1,h2,h3,h4) { color: var(--ink); font-weight: 500; line-height: 1.45; overflow-wrap: anywhere; }
.console-site h1 { font-size: clamp(24px, 2.5vw, 32px); }
.console-site h2 { font-size: 21px; }
.console-site h3 { font-size: 17px; }
.console-site :is(strong,b) { font-weight: 500; }
.console-site a, .console-site a:visited { color: var(--link); text-underline-offset: .24em; }
.console-site a:hover { color: var(--ink); }
.console-site :is(button,input,select,textarea) { color: var(--ink); background: var(--paper); border: 1px solid var(--control-border); border-radius: 0; font-size: 14px; line-height: 1.5; box-shadow: none; }
.console-site :is(button,select) { cursor: pointer; }
.console-site :is(button,input,select) { min-height: 38px; padding: 7px 10px; }
.console-site button:hover { color: var(--accent); background: var(--surface); border-color: var(--accent); }
.console-site button:active { background: var(--selection); }
.console-site :is(button,input,select):disabled { opacity: .55; cursor: not-allowed; }
.console-icon { width: 15px; height: 16px; display: inline-block; fill: currentColor; flex: 0 0 15px; vertical-align: -.16em; }
.console-site input::placeholder { color: var(--muted); opacity: 1; }
.console-site input[type="checkbox"] { min-height: auto; accent-color: var(--accent); }
.console-site :focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.console-site ::selection { background: var(--selection); color: var(--ink); }
.console-site pre { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 2px; padding: 20px; overflow-x: auto; font-size: 14px; line-height: 1.8; }
.console-site code { color: inherit; font-size: .93em; }
.console-site :not(pre) > code { background: var(--surface); padding: .1em .25em; overflow-wrap: anywhere; }
.console-site pre code { padding: 0; background: transparent; font: inherit; overflow-wrap: normal; }
.console-site img { max-width: 100%; height: auto; }
.console-site blockquote { margin: 1.5rem 0; padding: .25rem 1.25rem; border-left: 2px solid var(--accent); color: var(--muted); }
.console-site hr { border: 0; border-top: 1px solid var(--line); opacity: 1; }
.console-site kbd { background: var(--surface); border: 1px solid var(--line); border-radius: 2px; color: var(--muted); padding: 2px 6px; font-size: 12px; }
.console-header { position: sticky; z-index: 20; top: 0; background: var(--paper); border-bottom: 1px solid var(--line); }
.console-header__inner { max-width: var(--shell-width); min-height: 74px; margin: auto; padding: 0 36px; display: flex; align-items: center; gap: 36px; }
.console-brand, .console-brand:visited { flex-shrink: 0; font-size: 21px; font-weight: 500; text-decoration: none; color: var(--ink) !important; white-space: nowrap; }
.console-brand span { color: var(--accent); }
.console-nav { display: flex; flex: 1; min-width: 0; align-self: stretch; align-items: stretch; gap: 24px; margin: 0; }
.console-nav a, .console-nav a:visited { display: flex; align-items: center; border-bottom: 2px solid transparent; padding: 18px 0 16px; font-size: 16px; color: var(--ink); text-decoration: none; white-space: nowrap; }
.console-nav a:hover, .console-nav a[aria-current] { color: var(--accent); border-bottom-color: var(--accent); }
.console-nav > a, .console-writing > a { gap: 9px; }
.console-writing { display: flex; align-items: stretch; position: relative; }
.console-categories { display: flex; align-items: stretch; margin: 0; }
.console-categories > summary { display: flex; align-items: center; gap: 9px; padding: 18px 0 16px; border-bottom: 2px solid transparent; cursor: pointer; color: var(--ink); list-style: none; font-size: 16px; text-decoration: none; }
.console-categories > summary::-webkit-details-marker { display: none; }
.console-categories > summary .console-icon:last-child { width: 10px; height: 10px; flex-basis: 10px; }
.console-categories[open] > summary, .console-categories > summary:hover, .console-writing.is-current summary { color: var(--accent); border-bottom-color: var(--accent); }
.console-categories[open] > summary .console-icon:last-child { transform: rotate(180deg); }
.console-category-menu { position: absolute; z-index: 30; top: 100%; left: 0; width: 260px; padding: 8px; background: var(--paper); border: 1px solid var(--control-border); }
.console-nav .console-category-menu a { color: var(--ink); min-height: 42px; padding: 9px 12px; font-size: 14px; line-height: 1.5; gap: 12px; border: 0; }
.console-nav .console-category-menu a:first-child { border-bottom: 1px solid var(--line); margin-bottom: 5px; }
.console-nav .console-category-menu a:hover, .console-nav .console-category-menu a[aria-current] { color: var(--accent); background: var(--surface); }
.console-nav .console-category-menu a .console-icon { color: var(--accent); }
.console-tools { display: flex; align-self: center; align-items: center; gap: 14px; margin-left: auto; flex-shrink: 0; }
.console-search-open { display: none; align-items: center; justify-content: space-between; gap: 10px; min-width: 108px; color: var(--muted) !important; text-align: left; }
:is(.console-theme,.console-language) { display: none; position: relative; align-items: center; gap: 8px; margin: 0; font-size: 12px; color: var(--muted); }
.console-js :is(.console-search-open,.console-theme,.console-language) { display: flex; }
:is(.console-theme,.console-language) select {
  /* Safari's native popup bezel ignores some of the shared box styling. */
  -webkit-appearance: none;
  appearance: none;
  width: 96px;
  max-width: 106px;
  height: 38px;
  padding: 7px 28px 7px 10px;
  font: 12px/1.5 var(--font-mono);
}
:is(.console-theme,.console-language)::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 50%;
  width: 10px;
  height: 10px;
  transform: translateY(-50%);
  background: var(--muted);
  -webkit-mask: url("select-chevron.svg") center / contain no-repeat;
  mask: url("select-chevron.svg") center / contain no-repeat;
  pointer-events: none;
}
.console-menu { display: none; }
.console-menu .console-icon { display: block; width: 18px; height: 18px; }
.console-menu[aria-expanded="true"] { color: var(--accent); border-color: var(--accent); background: var(--surface); }
.console-sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.console-site .skip-link { position: fixed; top: -100px; left: 16px; z-index: 50; background: var(--surface); color: var(--ink); padding: 8px 14px; transform: none; }
.console-site .skip-link:focus { top: 10px; }
.console-footer { max-width: var(--shell-width); margin: 0 auto; padding: 20px 36px; border-top: 1px solid var(--line); color: var(--muted); font-size: 12px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; }
.console-hints { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.console-hints kbd:not(:first-child) { margin-left: 12px; }
.console-search { width: min(720px, calc(100% - 32px)); max-height: calc(100dvh - 48px); margin: 8vh auto auto; padding: 24px; border: 1px solid var(--line); border-radius: 2px; background: var(--paper); color: var(--ink); }
.console-search::backdrop { background: rgb(0 0 0 / .65); }
.console-search__heading { display: flex; justify-content: space-between; gap: 16px; align-items: center; margin-bottom: 20px; }
.console-search__heading h2 { margin: 0; font-size: 18px; }
.console-search label { display: block; margin-bottom: 8px; font-size: 13px; color: var(--muted); }
.console-search input { width: 100%; min-height: 46px; }
.console-search__results { padding: 0; margin: 16px 0 0; list-style: none; max-height: 50vh; overflow-y: auto; }
.console-search__results li { border-top: 1px solid var(--line); }
.console-search__results a { display: block; padding: 12px 4px; text-decoration: none; }
.console-search__results small { display: block; color: var(--muted); font-size: 11px; margin-bottom: 3px; }
.console-search__status { font-size: 12px; color: var(--muted); margin: 12px 0 0; }
.console-code { position: relative; margin: 1.4rem 0; }
.console-code pre { margin: 0; padding-top: 52px; }
.console-copy { position: absolute; top: 8px; right: 8px; min-height: 30px !important; padding: 4px 9px !important; font-size: 12px !important; }
.console-site .highlight { background: transparent; color: var(--ink); }
.console-site .highlight * { color: var(--ink); background: transparent; font-style: normal; font-weight: 400; }
.console-site pre.highlight { background: var(--surface); }
.console-site .highlight .err { background: transparent; color: var(--danger); }
.console-site .highlight :is(.c,.c1,.cm,.cp,.cs,.w) { color: var(--muted); font-style: normal; }
.console-site .highlight :is(.k,.kc,.kd,.kn,.kp,.kr,.kt,.nb,.nt,.o,.ow,.gp,.gh,.gu) { color: var(--accent); font-weight: 500; }
.console-site .highlight :is(.gd,.gr,.ne) { color: var(--danger); }
.console-site .highlight .gi { color: var(--success); }
.console-site .highlight :is(.s,.s1,.s2,.sb,.sc,.sd,.se,.sh,.si,.sr,.ss) { color: var(--success); }
.console-site .highlight :is(.m,.mf,.mh,.mi,.mo,.il,.na,.nf,.nc,.nn,.nv,.vc,.vg,.vi,.no) { color: var(--ink); }
@media (max-width: 1320px) {
  .console-header__inner { gap: 24px; padding-inline: 24px; }
  .console-nav { gap: 12px; }
  .console-nav > a, .console-categories > summary { gap: 6px; font-size: 14px; }
  .console-search-open { min-width: 76px; gap: 12px; }
  :is(.console-theme,.console-language) > span { display: none; }
  .console-tools { gap: 10px; }
}
@media (max-width: 1180px) {
  html { scroll-padding-top: 5rem; }
  .console-header__inner { flex-wrap: wrap; gap: 0 18px; min-height: 68px; padding: 12px 20px; }
  .console-brand { margin: 0; }
  .console-js .console-menu { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 40px; margin-left: auto; padding: 8px; }
  .console-nav { order: 3; flex: 0 0 100%; width: 100%; gap: 0; flex-direction: column; max-height: calc(100dvh - 88px); overflow-y: auto; overscroll-behavior: contain; }
  .console-js .console-nav { display: none; }
  .console-js .console-nav.is-open { display: flex; padding-top: 12px; }
  .console-nav > a { gap: 10px; }
  .console-nav a { min-height: 44px; padding: 8px; border-bottom: 0; border-left: 2px solid transparent; }
  .console-nav a[aria-current] { border-left-color: var(--accent); background: var(--surface); }
  .console-writing { flex-wrap: wrap; width: 100%; }
  .console-categories { display: block; width: 100%; }
  .console-categories > summary { position: static; width: 100%; min-height: 44px; padding: 8px; border-bottom: 0; border-left: 2px solid transparent; gap: 10px; }
  .console-writing.is-current summary { border-left-color: var(--accent); background: var(--surface); }
  .console-categories > summary .console-icon:last-child { margin-left: auto; }
  .console-category-menu { position: static; width: 100%; padding: 4px 8px 8px 20px; border: 0; border-left: 1px solid var(--line); }
  .console-tools { align-self: stretch; justify-content: space-between; flex-wrap: wrap; width: 100%; margin: 12px 0 0; padding: 16px 8px 8px; border-top: 1px solid var(--line); gap: 14px 20px; }
  .console-search-open { flex: 1 0 100%; min-width: 120px; justify-content: flex-start; }
  .console-search-open kbd { margin-left: auto; }
  :is(.console-theme,.console-language) > span { display: inline; }
}
@media (max-width: 560px) {
  body.console-site { font-size: 14px; }
  .console-header__inner { padding: 12px 16px; gap: 12px; }
  .console-brand { font-size: 18px; margin: 0; }
  .console-tools { gap: 12px; }
  .console-search-open { padding-inline: 10px; }
  :is(.console-theme,.console-language) select { width: 83px; padding-inline: 8px 26px; }
  .console-footer { padding: 20px 16px; font-size: 11px; }
  .console-search { padding: 16px; }
  .console-site pre { font-size: 12px; padding: 16px; }
  .console-code pre { padding-top: 48px; }
}
@media (max-width: 380px) {
  .console-header__inner { gap: 10px 8px; }
  .console-brand { font-size: 17px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto !important; } }

/* Language controls share the theme palette and Safari select reset. */
.console-language select { width: 66px; max-width: 66px; }
.console-language-note { margin: 0 0 24px; padding: 12px 16px; border-left: 2px solid var(--accent); background: var(--surface); color: var(--muted); font-size: 12px; }
.console-language-note[hidden] { display: none; }
.console-language-note a { margin-inline-start: 12px; white-space: nowrap; }
