/* Docs tab, v2: the home look for the command guide. Every command's syntax, slash alternative,
   options and examples are always visible; motion only adds polish and rests under reduced motion. */

:root {
  --docs-head: 74px;
  --docs-rail-h: 0px;
  --docs-mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --docs-grad-v: linear-gradient(180deg, #c2185b, #c2410c 50%, #5b46d6);
  --docs-ring-a: #c2185b;
  --docs-ring-b: #ea7340;
  --docs-ring-c: #6a59e3;
  --docs-ring-d: #0b6f8c;
}
:root[data-theme="dark"] {
  --docs-grad-v: linear-gradient(180deg, #ff8cc8, #ffbf91 50%, #b7a7ff);
  --docs-ring-a: #ff8cc8;
  --docs-ring-b: #ffbf91;
  --docs-ring-c: #b7a7ff;
  --docs-ring-d: #6fe0f5;
}
@media (max-width: 1079px) { :root { --docs-rail-h: 58px; } }
@media (max-width: 620px) { :root { --docs-head: 66px; } }

@property --docs-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

/* Links such as /docs#command-drop land below the floating header (and the sticky rail on narrow screens). */
html { scroll-padding-top: calc(var(--docs-head) + var(--docs-rail-h) + 24px); }
body.docs-v2 main { overflow-x: clip; }

:root .docs-v2 code {
  padding: .12em .42em;
  border: 1px solid var(--v2-line);
  border-radius: 7px;
  color: var(--v2-text);
  background: var(--v2-elev-2);
  font-family: var(--docs-mono);
  font-size: .88em;
  overflow-wrap: anywhere;
}
:root .docs-v2 kbd {
  display: inline-grid;
  place-items: center;
  min-width: 26px;
  height: 26px;
  padding: 0 7px;
  border: 1px solid var(--v2-line-2);
  border-bottom-width: 2px;
  border-radius: 8px;
  color: var(--v2-muted);
  background: var(--v2-elev-2);
  font: 700 12px/1 var(--docs-mono);
}

/* Hero: copy and command finder beside a framed window onto the archive scene. */
.docs-intro {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
  align-items: center;
  gap: clamp(32px, 4.5vw, 72px);
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding: 124px 0 52px;
}
.docs-intro-copy { display: grid; justify-items: start; gap: 20px; min-width: 0; }
.docs-intro h1 {
  margin: 0;
  color: var(--v2-text);
  font-size: clamp(40px, 4.4vw, 62px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -.035em;
}
.docs-intro h1 > span { display: block; padding-bottom: .06em; }
.docs-lede { max-width: 44ch; margin: 0; color: var(--v2-soft); font-size: clamp(17px, 1.35vw, 19px); line-height: 1.5; }
.docs-fine { max-width: 54ch; margin: -4px 0 0; color: var(--v2-muted); font-size: 13.5px; line-height: 1.5; }

/* Command finder (site.js drives the combobox; these are only looks). */
.docs-finder { position: relative; z-index: 5; width: min(560px, 100%); margin-top: 4px; }
.docs-finder-field {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  height: 62px;
  padding: 0 14px 0 18px;
  border: 1px solid var(--v2-line-2);
  border-radius: 18px;
  color: var(--v2-text);
  background: var(--v2-elev);
  box-shadow: var(--v2-shadow);
  cursor: text;
  transition: border-color .25s ease, box-shadow .3s ease;
}
.docs-finder-field::before {
  content: "";
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 2px;
  /* Built here, not on :root, so the animated --docs-angle is read on this element. */
  background: conic-gradient(from var(--docs-angle, 0deg), var(--docs-ring-a), var(--docs-ring-b), var(--docs-ring-c), var(--docs-ring-d), var(--docs-ring-a));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  mask-composite: exclude;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}
.docs-finder-field:hover { border-color: var(--v2-violet); }
.docs-finder-field:focus-within { border-color: transparent; box-shadow: 0 0 0 6px var(--v2-spot), var(--v2-shadow-lg); }
.docs-finder-field:focus-within::before { opacity: 1; animation: docs-spin 3.6s linear infinite; }
@keyframes docs-spin { to { --docs-angle: 360deg; } }
.docs-finder-icon { color: var(--v2-violet); }
.docs-finder-field input {
  min-width: 0;
  height: 100%;
  padding: 0;
  border: 0;
  outline: 0;
  color: var(--v2-text);
  background: transparent;
  font-size: 16.5px;
  font-weight: 550;
}
.docs-finder-field input::placeholder { color: var(--v2-muted); opacity: 1; }
:root .docs-finder-field input:focus-visible { outline: none; }
.docs-finder-popover {
  position: absolute;
  z-index: 6;
  inset: calc(100% + 10px) 0 auto;
  overflow: hidden;
  border: 1px solid var(--v2-line-2);
  border-radius: 18px;
  color: var(--v2-text);
  background: var(--v2-elev);
  box-shadow: var(--v2-shadow-lg);
  transform-origin: 50% 0;
}
.docs-finder-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 42px;
  padding: 0 16px;
  border-bottom: 1px solid var(--v2-line);
  color: var(--v2-muted);
  background: var(--v2-grad-glow), var(--v2-elev);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.docs-finder-head strong { color: var(--v2-text); font: inherit; }
.docs-finder-listbox {
  max-height: min(392px, 52vh);
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 6px;
  scrollbar-width: thin;
}
.docs-finder-option {
  position: relative;
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 8px 12px 8px 14px;
  border-radius: 12px;
  cursor: pointer;
  transition: background-color .15s ease;
}
.docs-finder-option::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 3px;
  background: var(--docs-grad-v);
  transform: scaleY(0);
  transition: transform .2s var(--v2-ease-out);
}
.docs-finder-option:hover, .docs-finder-option[aria-selected="true"] { background: var(--v2-elev-2); }
.docs-finder-option[aria-selected="true"]::before { transform: none; }
:root .docs-finder-option code { justify-self: start; font-size: 13px; font-weight: 800; }
.docs-finder-option-copy { min-width: 0; }
.docs-finder-option-copy strong { display: block; color: var(--v2-text); font-size: 14.5px; font-weight: 750; }
.docs-finder-option-copy small {
  display: block;
  overflow: hidden;
  margin-top: 2px;
  color: var(--v2-muted);
  font-size: 12.5px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.docs-finder-option-category {
  max-width: 150px;
  overflow: hidden;
  padding: 4px 9px;
  border-radius: 999px;
  color: var(--v2-soft);
  background: var(--v2-elev-2);
  font-size: 11.5px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.docs-finder-option:hover .docs-finder-option-category,
.docs-finder-option[aria-selected="true"] .docs-finder-option-category { background: var(--v2-elev); }
.docs-finder-empty { margin: 0; padding: 26px 20px 28px; text-align: center; }
.docs-finder-empty strong, .docs-finder-empty span { display: block; }
.docs-finder-empty strong { color: var(--v2-text); font-size: 15px; }
.docs-finder-empty span { margin-top: 6px; color: var(--v2-muted); font-size: 13px; }

/* Quick jumps under the finder. */
.docs-quick { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; }
.docs-quick-label { color: var(--v2-muted); font-size: 13px; font-weight: 700; }
.docs-quick ul { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; list-style: none; }
.docs-quick a,
.docs-index a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 4px 12px 4px 5px;
  border: 1px solid var(--v2-line);
  border-radius: 12px;
  color: var(--v2-soft);
  background: var(--v2-glass);
  font-size: 13.5px;
  font-weight: 650;
  transition: transform .22s var(--v2-ease), border-color .22s ease, color .22s ease, box-shadow .22s ease;
}
.docs-quick a:hover,
.docs-index a:hover { transform: translateY(-2px); border-color: var(--v2-line-2); color: var(--v2-text); box-shadow: var(--v2-shadow); }
:root .docs-quick code,
:root .docs-index code { padding: 5px 8px; border: 0; border-radius: 8px; color: var(--v2-text); background: var(--v2-elev-2); font-size: 12.5px; font-weight: 800; }
/* Each chip keeps its look while an invisible layer makes it at least 44px tall to tap. Chip rows sit
   44px or more apart, so the layers meet without overlapping a neighbouring chip or the text around. */
.docs-quick a,
.docs-index a { position: relative; }
.docs-quick a::after,
.docs-index a::after { content: ""; position: absolute; inset: min(0px, calc(50% - 22px)) 0; }

/* The framed archive window: poster first, decorative video only when site policy allows it. */
.docs-stage {
  --rx: 0deg;
  --ry: 0deg;
  position: relative;
  min-width: 0;
  padding-bottom: 18px;
  transform: perspective(1400px) rotateX(var(--rx)) rotateY(var(--ry));
  transition: transform .6s var(--v2-ease);
}
.docs-stage::before {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 12% 6% 0 10%;
  border-radius: 40%;
  background: radial-gradient(closest-side, rgba(255, 140, 200, .45), rgba(150, 130, 255, .3) 55%, transparent);
  filter: blur(38px);
  pointer-events: none;
}
:root[data-theme="dark"] .docs-stage::before { opacity: .6; }
.docs-window {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--v2-line-2);
  border-radius: 24px;
  background: var(--v2-elev);
  box-shadow: var(--v2-shadow-lg);
}
.docs-window::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  background: linear-gradient(115deg, transparent 38%, rgba(255, 255, 255, .26) 48%, transparent 58%);
  transform: translateX(-120%);
  pointer-events: none;
}
.docs-window-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 42px;
  padding: 0 14px;
  border-bottom: 1px solid var(--v2-line);
  color: var(--v2-muted);
  background: var(--v2-elev-2);
  font-size: 12.5px;
  font-weight: 650;
}
.docs-window-bar i { width: 10px; height: 10px; border-radius: 50%; background: #ff5f57; }
.docs-window-bar i:nth-child(2) { background: #febc2e; }
.docs-window-bar i:nth-child(3) { margin-right: 8px; background: #28c840; }
.docs-window-scene { position: relative; isolation: isolate; overflow: hidden; aspect-ratio: 16 / 10; }
.docs-window .scene-page-backdrop img,
.docs-window .scene-page-backdrop .scene-page-video { object-position: 50% 42%; }
.docs-window[data-video-state="playing"] .scene-page-video { opacity: 1; }
.docs-window .scene-page-backdrop::after { background: linear-gradient(180deg, rgba(26, 18, 70, 0) 52%, rgba(26, 18, 70, .34)); }
:root[data-theme="dark"] .docs-window .scene-page-backdrop::after { background: linear-gradient(180deg, rgba(9, 11, 22, .2), rgba(9, 11, 22, .55)); }
.docs-typer {
  position: absolute;
  z-index: 2;
  left: 18px;
  bottom: 18px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: calc(100% - 170px);
  min-height: 46px;
  margin: 0;
  padding: 0 16px 0 14px;
  border: 1px solid rgba(255, 255, 255, .36);
  border-radius: 14px;
  color: #fff;
  background: rgba(16, 14, 44, .62);
  box-shadow: 0 16px 30px -16px rgba(10, 8, 40, .7);
  backdrop-filter: blur(12px) saturate(140%);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  font: 700 15px/1.2 var(--docs-mono);
}
.docs-typer-prompt { color: #ffa3d4; font-size: 18px; }
:root .docs-typer code { overflow: hidden; padding: 0; border: 0; color: #fff; background: none; font: inherit; white-space: pre; text-overflow: clip; }
.docs-typer-caret { flex: 0 0 auto; width: 9px; height: 18px; margin-left: -6px; border-radius: 2px; background: #ffa3d4; }
.docs-window-mascot {
  position: absolute;
  z-index: 4;
  right: 22px;
  bottom: -22px;
  width: clamp(104px, 11vw, 150px);
  height: auto;
  aspect-ratio: 480 / 714;
  filter: drop-shadow(0 18px 22px rgba(20, 10, 60, .28));
}

/* Directory layout: a sticky category rail beside the commands. */
.docs-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
  align-items: start;
  gap: 44px;
  width: min(1240px, calc(100% - 40px));
  margin: 0 auto;
  padding-top: 28px;
}
.docs-rail {
  position: sticky;
  top: calc(var(--docs-head) + 22px);
  display: grid;
  gap: 10px;
  max-height: calc(100vh - var(--docs-head) - 40px);
  overflow-y: auto;
  padding: 6px 10px 16px 16px;
  margin: -4px -6px 0 -16px;
  scrollbar-width: none;
}
.docs-rail::-webkit-scrollbar { display: none; }
.docs-rail-search {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 0 10px 0 14px;
  border: 1px solid var(--v2-line-2);
  border-radius: 14px;
  color: var(--v2-soft);
  background: var(--v2-elev);
  box-shadow: var(--v2-shadow);
  font-size: 14px;
  font-weight: 650;
  transition: border-color .2s ease, color .2s ease, transform .2s var(--v2-ease);
}
.docs-rail-search svg { flex: 0 0 auto; color: var(--v2-violet); }
.docs-rail-search kbd { margin-left: auto; }
.docs-rail-search:hover { color: var(--v2-text); border-color: var(--v2-violet); transform: translateY(-1px); }
.docs-rail-label { margin: 12px 0 2px 12px; color: var(--v2-muted); font-size: 11.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.docs-rail-track { position: relative; }
.docs-rail-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.docs-rail-list a {
  position: relative;
  display: grid;
  grid-template-columns: 30px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  min-height: 46px;
  padding: 6px 12px 6px 9px;
  border: 1px solid transparent;
  border-radius: 13px;
  color: var(--v2-muted);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.25;
  transition: color .25s ease, background-color .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.docs-rail-list a:hover { color: var(--v2-text); background: var(--v2-elev-2); }
.docs-rail-list a.is-current { color: var(--v2-text); border-color: var(--v2-line); background: var(--v2-elev); box-shadow: var(--v2-shadow); }
.docs-rail-icon {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 9px;
  color: var(--cat);
  background: var(--v2-elev-2);
  background: color-mix(in srgb, var(--cat) 14%, transparent);
  font-size: 14px;
  transition: transform .45s var(--v2-spring);
}
.docs-rail-list a.is-current .docs-rail-icon { transform: scale(1.1) rotate(-8deg); }
.docs-rail-count { color: var(--v2-muted); font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; }
/* The marker slides to the current category and fills as you read through it. */
.docs-rail-indicator {
  position: absolute;
  z-index: 1;
  top: 0;
  left: -11px;
  width: 3px;
  height: 100px;
  overflow: hidden;
  border-radius: 3px;
  background: var(--v2-line-2);
  opacity: 0;
  transform-origin: 0 0;
  transform: translate3d(0, var(--docs-iy, 0px), 0) scaleY(calc(var(--docs-ih, 46) / 100));
  pointer-events: none;
}
.docs-rail-indicator > span {
  position: absolute;
  inset: 0;
  background: var(--docs-grad-v);
  transform-origin: 50% 0;
  transform: scaleY(var(--docs-progress, 0));
}
.docs-rail.has-current .docs-rail-indicator { opacity: 1; }
.docs-rail.is-enhanced .docs-rail-indicator { transition: transform .5s var(--v2-ease-out), opacity .3s ease; }

/* Category colours (rail icons and section badges share them). */
:is(.docs-rail-list li, .docs-category) { --cat: var(--v2-violet); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 1) { --cat: var(--v2-pink); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 2) { --cat: var(--v2-violet); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 3) { --cat: var(--v2-peach); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 4) { --cat: var(--v2-gold); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 5) { --cat: var(--v2-cyan); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 6) { --cat: var(--v2-pink); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 7) { --cat: var(--v2-mint); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 8) { --cat: var(--v2-violet); }
:is(.docs-rail-list li, .docs-category):nth-child(9n + 9) { --cat: var(--v2-peach); }

/* Categories. */
.docs-directory { display: grid; gap: clamp(56px, 6vw, 88px); min-width: 0; }
.docs-category-head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 6px 18px;
  margin-bottom: 24px;
}
.docs-category-icon {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 18px;
  color: #fff;
  background: var(--cat);
  box-shadow: 0 16px 30px -16px var(--cat);
  font-size: 26px;
  line-height: 1;
}
:root[data-theme="dark"] .docs-category-icon { color: #12142a; }
.docs-category-title h2 { margin: 0; color: var(--v2-text); font-size: clamp(28px, 3vw, 40px); font-weight: 800; line-height: 1.05; }
.docs-category-title p { margin: 5px 0 0; color: var(--v2-muted); font-size: 14px; font-weight: 650; }
.docs-index { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; padding: 0; list-style: none; }
.docs-index a { min-height: 38px; padding-right: 11px; font-size: 13px; background: var(--v2-elev); }
.docs-index a:hover { border-color: var(--cat); }
.docs-index li:nth-child(2) { --i: 1; } .docs-index li:nth-child(3) { --i: 2; } .docs-index li:nth-child(4) { --i: 3; }
.docs-index li:nth-child(5) { --i: 4; } .docs-index li:nth-child(6) { --i: 5; } .docs-index li:nth-child(7) { --i: 6; }
.docs-index li:nth-child(8) { --i: 7; } .docs-index li:nth-child(9) { --i: 8; } .docs-index li:nth-child(10) { --i: 9; }
.docs-index li:nth-child(11) { --i: 10; } .docs-index li:nth-child(n + 12) { --i: 11; }

/* Command cards: the quickest syntax and what it does, then one compact strip with everything else. */
.docs-command-list { display: grid; gap: 12px; }
.docs-command {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  grid-template-areas: "pill name tags" "desc desc desc" "facts facts facts";
  align-items: center;
  gap: 10px 16px;
  padding: 20px 28px 18px 26px;
  border: 1px solid var(--v2-line);
  border-radius: 22px;
  background: var(--v2-elev);
  box-shadow: var(--v2-shadow);
  transition: border-color .35s ease, box-shadow .35s ease;
}
.docs-command::before {
  content: "";
  position: absolute;
  z-index: 1;
  top: 22px;
  bottom: 22px;
  left: -1px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--docs-grad-v);
  transform: scaleY(0);
  transform-origin: 50% 0;
  transition: transform .55s var(--v2-ease-out);
}
.docs-command:is(.is-reading, .is-search-target)::before { transform: none; }
.docs-command.is-reading { border-color: var(--v2-line-2); }
.docs-command.is-search-target { border-color: transparent; box-shadow: 0 0 0 2px var(--v2-violet), 0 0 0 8px var(--v2-spot), var(--v2-shadow-lg); }
.docs-command-name {
  grid-area: name;
  min-width: 0;
  margin: 0;
  color: var(--v2-text);
  font-size: 21px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -.02em;
  overflow-wrap: anywhere;
}
.docs-command-prefix {
  grid-area: pill;
  position: relative;
  display: inline-flex;
  justify-self: start;
  max-width: 100%;
  padding: 1.5px;
  border-radius: 13px;
  background: var(--v2-grad);
  box-shadow: 0 12px 26px -16px rgba(106, 89, 227, .85);
}
:root .docs-command-prefix code {
  display: block;
  padding: 7px 12px;
  border: 0;
  border-radius: 11.5px;
  color: var(--v2-text);
  background: var(--v2-elev);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -.01em;
  white-space: nowrap;
  transition: color .35s ease, background-color .35s ease;
}
:root .docs-command:is(.is-reading, .is-search-target) .docs-command-prefix code { color: #fff; background-color: transparent; }
:root[data-theme="dark"] .docs-command:is(.is-reading, .is-search-target) .docs-command-prefix code { color: #12142a; }
.docs-command-tags { grid-area: tags; display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; margin: 0; padding: 0; list-style: none; }
.docs-command-tags li {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border: 1px solid var(--v2-line);
  border-radius: 999px;
  color: var(--v2-soft);
  background: var(--v2-elev-2);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.docs-command-tags li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--v2-mint); }
.docs-command-tags .docs-tag-prefix::before { background: var(--v2-violet); }
.docs-command-tags .docs-tag-server::before { background: var(--v2-gold); }
.docs-command-tags .docs-tag-anywhere::before { background: var(--v2-cyan); }
.docs-command-desc { grid-area: desc; max-width: 82ch; margin: 2px 0 0; color: var(--v2-soft); font-size: 15.5px; line-height: 1.6; }
.docs-command-facts {
  grid-area: facts;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 30px;
  margin: 2px 0 0;
  padding-top: 14px;
  border-top: 1px dashed var(--v2-line-2);
}
.docs-fact { display: flex; align-items: flex-start; gap: 10px; min-width: 0; max-width: 100%; }
.docs-fact dt { flex: 0 0 auto; color: var(--v2-muted); font-size: 11.5px; font-weight: 800; line-height: 24px; letter-spacing: .08em; text-transform: uppercase; }
.docs-fact dd { min-width: 0; margin: 0; color: var(--v2-soft); font-size: 14px; line-height: 1.65; }
:root .docs-fact dd > code { display: inline-block; max-width: 100%; font-size: 13.5px; line-height: 1.5; vertical-align: top; }
.docs-fact-aliases dd { display: flex; flex-wrap: wrap; gap: 6px; }
.docs-fact-row, .docs-fact-block { flex-basis: 100%; }
.docs-fact-block { display: block; }
.docs-fact-block dt { margin-bottom: 8px; }
.docs-examples { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
:root .docs-examples code { display: inline-block; padding: 3px 9px; border-radius: 9px; }
.docs-options {
  display: grid;
  grid-template-columns: fit-content(42%) minmax(0, 1fr);
  gap: 7px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.docs-options > li { display: grid; grid-template-columns: minmax(0, 200px) minmax(0, 1fr); grid-template-columns: subgrid; grid-column: 1 / -1; align-items: baseline; }
.docs-option-term { min-width: 0; color: var(--v2-text); font-weight: 700; }
.docs-option-detail { min-width: 0; }
.docs-options > .docs-option-note { display: block; color: var(--v2-soft); }

/* Closing help. */
.docs-help {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 18px;
  width: min(1240px, calc(100% - 40px));
  margin: clamp(88px, 10vw, 136px) auto 76px;
  padding: clamp(46px, 6vw, 76px) 24px;
  overflow: hidden;
  border: 1px solid var(--v2-line);
  border-radius: 32px;
  background: var(--v2-grad-glow), var(--v2-elev);
  box-shadow: var(--v2-shadow-lg);
  text-align: center;
}
.docs-help h2 { margin: 0; color: var(--v2-text); font-size: clamp(30px, 4vw, 52px); font-weight: 800; line-height: 1.05; }
.docs-help h2 > span { display: block; }
.docs-help > p:not(.v2-eyebrow):not(.v2-fine) { max-width: 54ch; margin: 0; color: var(--v2-soft); font-size: 17px; line-height: 1.55; }
.docs-help .invite-arrow { margin-left: 0; font-size: inherit; opacity: .6; }

/* Motion: decorative, transform/opacity only, and only when the browser welcomes it. */
@media (prefers-reduced-motion: no-preference) {
  .docs-stage { animation: docs-stage-in 1.1s var(--v2-ease-out); }
  .docs-window::after { animation: docs-sheen 9s ease-in-out 1.4s infinite; }
  .docs-typer-caret { animation: docs-caret 1.05s steps(1) infinite; }
  .docs-finder-popover:not([hidden]) { animation: docs-pop-in .2s var(--v2-ease-out); }
  .v2-motion .docs-category-head[data-v2-reveal].v2-in .docs-category-icon { animation: docs-icon-pop .75s var(--v2-spring) both; }
  .v2-motion .docs-category-head[data-v2-reveal].v2-in .docs-index li { animation: docs-chip-in .42s var(--v2-ease-out) both; animation-delay: calc(140ms + var(--i, 0) * 26ms); }
  .docs-command.is-search-target .docs-command-prefix { animation: docs-pill-pop .6s var(--v2-spring); }
}
@keyframes docs-stage-in { from { transform: perspective(1400px) translate3d(0, 28px, 0) rotateX(9deg) rotateY(-7deg) scale(.97); } }
@keyframes docs-sheen { 0%, 78% { transform: translateX(-120%); } 100% { transform: translateX(120%); } }
@keyframes docs-caret { 50% { opacity: 0; } }
@keyframes docs-pop-in { from { opacity: 0; transform: translate3d(0, -6px, 0) scale(.985); } }
@keyframes docs-icon-pop { from { transform: scale(.55) rotate(-16deg); } }
@keyframes docs-chip-in { from { opacity: 0; transform: translate3d(0, 10px, 0); } }
@keyframes docs-pill-pop { 0% { transform: scale(.86); } 60% { transform: scale(1.06); } }

/* Loops rest on hidden tabs and with Save-Data (site.js sets body[data-motion-state]). */
body:is([data-motion-state="data-saving"], [data-motion-state="hidden"]) :is(.docs-typer-caret, .docs-window, .docs-finder-field)::after,
body:is([data-motion-state="data-saving"], [data-motion-state="hidden"]) .docs-typer-caret,
body:is([data-motion-state="data-saving"], [data-motion-state="hidden"]) .docs-finder-field::before { animation-play-state: paused !important; }

/* Tablet: the rail becomes a sticky glass bar of chips under the header. */
@media (max-width: 1079px) {
  .docs-layout { display: block; padding-top: 6px; }
  .docs-rail {
    position: sticky;
    z-index: 20;
    top: calc(var(--docs-head) + 8px);
    display: flex;
    align-items: center;
    gap: 6px;
    max-height: none;
    margin: 0 0 30px;
    padding: 5px;
    overflow: visible;
    border: 1px solid var(--v2-line);
    border-radius: 17px;
    background: var(--v2-glass);
    box-shadow: var(--v2-shadow);
    backdrop-filter: blur(18px) saturate(160%);
    -webkit-backdrop-filter: blur(18px) saturate(160%);
  }
  :root .docs-rail-label, :root .docs-rail-search kbd { display: none; }
  .docs-rail-search { flex: 0 0 44px; justify-content: center; width: 44px; min-height: 44px; padding: 0; border-radius: 12px; box-shadow: none; }
  .docs-rail-search span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .docs-rail-track {
    flex: 1 1 auto;
    min-width: 0;
    margin: -6px 0;
    padding: 6px 0;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 12px, #000 calc(100% - 18px), transparent);
    mask-image: linear-gradient(90deg, transparent, #000 12px, #000 calc(100% - 18px), transparent);
  }
  .docs-rail-track::-webkit-scrollbar { display: none; }
  .docs-rail-list { display: flex; gap: 4px; width: max-content; padding: 0 12px 0 8px; }
  .docs-rail-list a { grid-template-columns: auto auto; gap: 8px; min-height: 44px; padding: 0 13px 0 7px; border-radius: 12px; white-space: nowrap; font-size: 13.5px; }
  .docs-rail-list a.is-current { box-shadow: none; }
  .docs-rail-icon { width: 28px; height: 28px; font-size: 13px; }
  .docs-rail-count { display: none; }
  .docs-rail-indicator {
    top: auto;
    bottom: 6px;
    left: 0;
    width: 100px;
    height: 3px;
    transform: translate3d(var(--docs-ix, 0px), 0, 0) scaleX(calc(var(--docs-iw, 120) / 100));
  }
  .docs-rail-indicator > span { background: var(--v2-grad); transform-origin: 0 50%; transform: scaleX(var(--docs-progress, 0)); }
}

@media (max-width: 900px) {
  .docs-intro { grid-template-columns: minmax(0, 1fr); gap: 36px; padding-top: 108px; padding-bottom: 36px; }
  .docs-stage { width: min(100%, 620px); }
}

@media (max-width: 720px) {
  .docs-command {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-areas: "pill name" "tags tags" "desc desc" "facts facts";
    gap: 10px 12px;
    padding: 18px 16px 16px;
    border-radius: 18px;
  }
  .docs-command::before { top: 18px; bottom: 18px; }
  :root .docs-command-prefix code { padding: 6px 10px; font-size: 15.5px; }
  .docs-command-tags { justify-content: flex-start; }
  .docs-command-name { font-size: 19px; }
  .docs-command-desc { font-size: 15px; line-height: 1.55; }
  .docs-command-facts { gap: 8px 18px; padding-top: 12px; }
  .docs-fact { flex-wrap: wrap; gap: 2px 10px; }
  :root .docs-fact dd > code { font-size: 13px; }
  :root .docs-examples code { padding: 2px 8px; font-size: 12.5px; }
  .docs-options { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .docs-options > li { grid-template-columns: minmax(0, 1fr); gap: 3px; }
  .docs-category-head { gap: 4px 14px; margin-bottom: 18px; }
  .docs-category-icon { width: 50px; height: 50px; border-radius: 15px; font-size: 22px; }
  .docs-index { gap: 6px; margin-top: 10px; }
  .docs-index a { min-height: 38px; gap: 6px; padding: 3px 10px 3px 4px; font-size: 12.5px; }
  :root .docs-index code { padding: 4px 6px; font-size: 12px; }
}

@media (max-width: 620px) {
  .docs-intro, .docs-layout, .docs-help { width: calc(100% - 32px); }
  .docs-intro { gap: 30px; padding-top: 96px; }
  .docs-intro h1 { font-size: clamp(36px, 10.4vw, 48px); }
  .docs-lede { font-size: 16.5px; }
  .docs-finder-field { grid-template-columns: auto minmax(0, 1fr); height: 58px; padding: 0 12px 0 15px; border-radius: 16px; }
  :root .docs-finder-field kbd { display: none; }
  .docs-finder-option { grid-template-columns: 70px minmax(0, 1fr); gap: 10px; padding-inline: 12px 10px; }
  .docs-finder-option-category { display: none; }
  .docs-quick { gap: 8px; }
  .docs-quick ul { gap: 6px; }
  .docs-quick a { min-height: 38px; gap: 6px; padding-right: 10px; font-size: 13px; }
  .docs-window { border-radius: 20px; }
  .docs-window-bar { height: 36px; }
  .docs-window-scene { aspect-ratio: 16 / 11; }
  .docs-typer { left: 12px; bottom: 12px; max-width: calc(100% - 110px); min-height: 40px; padding: 0 12px 0 11px; font-size: 13.5px; }
  .docs-window-mascot { right: 10px; bottom: -14px; width: 92px; }
  .docs-help { padding-inline: 18px; border-radius: 24px; }
  .docs-help .v2-actions { width: 100%; }
  .docs-help .v2-actions .v2-button { flex: 1 1 auto; }
}

@media (hover: none), (pointer: coarse) {
  :root .docs-finder-field kbd { display: none; }
  .docs-finder-field { grid-template-columns: auto minmax(0, 1fr); }
}

@media (forced-colors: active) {
  .docs-finder-field:focus-within { outline: 2px solid CanvasText; outline-offset: 2px; }
  .docs-command.is-search-target { outline: 3px solid Highlight; }
}

@media (prefers-reduced-motion: reduce) {
  .docs-stage, .docs-window::after, .docs-typer-caret, .docs-finder-field::before, .docs-finder-popover,
  .docs-category-icon, .docs-index li, .docs-command-prefix { animation: none !important; }
  .docs-stage, .docs-rail-indicator, .docs-rail-indicator > span, .docs-command::before, .docs-command,
  .docs-rail-list a, .docs-rail-icon, .docs-quick a, .docs-index a, .docs-rail-search, :root .docs-command-prefix code { transition: none !important; }
  .docs-stage { transform: none !important; }
}

@media print {
  .docs-stage, .docs-finder, .docs-quick, .docs-rail, .docs-index, .docs-help .v2-actions, .v2-progress { display: none !important; }
  .docs-intro, .docs-layout { display: block; width: auto; padding: 0; }
  .docs-intro { padding-bottom: 18px; }
  .docs-directory { display: block; }
  .docs-category { margin-top: 28px; }
  .docs-command { break-inside: avoid; margin-bottom: 10px; box-shadow: none; border-color: #bbb; }
  .docs-command::before { display: none; }
  .docs-help { box-shadow: none; }
}

.docs-command-arena { grid-column: 1 / -1; margin: 0; color: var(--v2-soft); font-size: 15px; line-height: 1.6; }
