:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --panel: #f7f9fb;
  --panel-strong: #ffffff;
  --text: #17202a;
  --nav-text: #344054;
  --muted: #667085;
  --border: #d8dee7;
  --border-soft: #e8edf3;
  --accent: #087f5b;
  --accent-soft: #e6f4ef;
  --link: #1264a3;
  --code-bg: #f2f4f7;
  --code-text: #9f1239;
  --topbar-bg: rgba(255, 255, 255, 0.94);
  --sidebar-bg: #ffffff;
  --figure-bg: #ffffff;
  --pre-bg: #101828;
  --pre-text: #edf2f7;
  --button-bg: #ffffff;
  --modal-bg: #ffffff;
  --modal-backdrop: rgba(16, 24, 40, 0.42);
  --shadow: 0 12px 30px rgba(16, 24, 40, 0.08);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121212;
    --panel: #1e1e1e;
    --panel-strong: #242424;
    --text: #f4f5f8;
    --nav-text: #d8d8d8;
    --muted: #a7a7a7;
    --border: #343434;
    --border-soft: #292929;
    --accent: #ffce31;
    --accent-soft: rgba(255, 206, 49, 0.13);
    --link: #79b8ff;
    --code-bg: #292929;
    --code-text: #ffd166;
    --topbar-bg: rgba(18, 18, 18, 0.94);
    --sidebar-bg: #121212;
    --figure-bg: #1b1b1b;
    --pre-bg: #090909;
    --pre-text: #f3f4f6;
    --button-bg: #1e1e1e;
    --modal-bg: #1e1e1e;
    --modal-backdrop: rgba(0, 0, 0, 0.62);
    --shadow: 0 18px 38px rgba(0, 0, 0, 0.34);
  }
}

html[data-theme="light"] {
  --bg: #ffffff;
  --panel: #f7f9fb;
  --panel-strong: #ffffff;
  --text: #17202a;
  --nav-text: #344054;
  --muted: #667085;
  --border: #d8dee7;
  --border-soft: #e8edf3;
  --accent: #087f5b;
  --accent-soft: #e6f4ef;
  --link: #1264a3;
  --code-bg: #f2f4f7;
  --code-text: #9f1239;
  --topbar-bg: rgba(255, 255, 255, 0.94);
  --sidebar-bg: #ffffff;
  --figure-bg: #ffffff;
  --pre-bg: #101828;
  --pre-text: #edf2f7;
  --button-bg: #ffffff;
  --modal-bg: #ffffff;
  --modal-backdrop: rgba(16, 24, 40, 0.42);
  --shadow: 0 12px 30px rgba(16, 24, 40, 0.08);
}

html[data-theme="dark"] {
  --bg: #121212;
  --panel: #1e1e1e;
  --panel-strong: #242424;
  --text: #f4f5f8;
  --nav-text: #d8d8d8;
  --muted: #a7a7a7;
  --border: #343434;
  --border-soft: #292929;
  --accent: #ffce31;
  --accent-soft: rgba(255, 206, 49, 0.13);
  --link: #79b8ff;
  --code-bg: #292929;
  --code-text: #ffd166;
  --topbar-bg: rgba(18, 18, 18, 0.94);
  --sidebar-bg: #121212;
  --figure-bg: #1b1b1b;
  --pre-bg: #090909;
  --pre-text: #f3f4f6;
  --button-bg: #1e1e1e;
  --modal-bg: #1e1e1e;
  --modal-backdrop: rgba(0, 0, 0, 0.62);
  --shadow: 0 18px 38px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 8px 12px;
  border-radius: 8px;
  background: var(--text);
  color: #fff;
  transform: translateY(-140%);
}

.skip-link:focus {
  transform: translateY(0);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: minmax(150px, 1fr) minmax(320px, 780px) minmax(150px, 1fr);
  gap: 16px;
  align-items: center;
  min-height: 64px;
  padding: 0 24px;
  border-bottom: 1px solid var(--border);
  background: var(--topbar-bg);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  width: max-content;
  min-width: 138px;
  color: var(--text);
}

.brand-logo {
  width: 138px;
  height: auto;
}

.brand-logo-dark {
  display: none;
}

html[data-theme="dark"] .brand-logo-light {
  display: none;
}

html[data-theme="dark"] .brand-logo-dark {
  display: block;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .brand-logo-light {
    display: none;
  }

  :root:not([data-theme="light"]) .brand-logo-dark {
    display: block;
  }
}

.menu-toggle {
  display: none;
  width: 40px;
  height: 40px;
  place-items: center;
  gap: 4px;
  padding: 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--button-bg);
  box-shadow: var(--shadow);
  cursor: pointer;
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 0;
  border-radius: 2px;
  background: var(--text);
}

.assistant-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  justify-self: center;
  width: min(100%, 780px);
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 10px;
  background: var(--panel-strong);
  color: var(--muted);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), var(--shadow);
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.assistant-search:hover {
  border-color: var(--accent);
  color: var(--text);
}

.assistant-search-icon {
  position: relative;
  width: 16px;
  height: 16px;
  border: 2px solid var(--accent);
  border-radius: 50%;
}

.assistant-search-icon::after {
  content: "";
  position: absolute;
  right: -6px;
  bottom: -4px;
  width: 7px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(45deg);
}

.assistant-search-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.assistant-search-key {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 2px 7px;
  background: var(--panel);
  color: var(--muted);
  font-size: 12px;
  font-weight: 750;
}

.theme-toggle {
  position: relative;
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  justify-self: end;
  width: 58px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 3px;
  background: var(--button-bg);
  cursor: pointer;
}

.theme-toggle::before {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: var(--accent);
  transition: transform 160ms ease;
}

html[data-theme="dark"] .theme-toggle::before {
  transform: translateX(24px);
}

.theme-toggle-sun,
.theme-toggle-moon {
  position: relative;
  z-index: 1;
  width: 14px;
  height: 14px;
  justify-self: center;
  border-radius: 50%;
}

.theme-toggle-sun {
  border: 2px solid var(--text);
}

.theme-toggle-moon {
  box-shadow: inset -4px -1px 0 0 var(--text);
}

.nav-search {
  display: grid;
  gap: 4px;
  margin-bottom: 16px;
}

.nav-search span {
  color: var(--muted);
  font-size: 12px;
  font-weight: 650;
}

.nav-search input {
  width: 100%;
  min-height: 38px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  color: var(--text);
  background: var(--panel-strong);
  font: inherit;
  line-height: 1.2;
}

.shell {
  display: grid;
  grid-template-columns: 300px minmax(0, 860px) 260px;
  gap: 32px;
  align-items: start;
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 28px;
}

.sidebar,
.toc {
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
  overflow: auto;
}

.sidebar {
  border-right: 1px solid var(--border-soft);
  background: var(--sidebar-bg);
  padding: 24px 20px 40px 0;
}

.sidebar-nav {
  font-size: 14px;
  line-height: 1.4;
}

.nav-root,
.nav-link,
.nav-label,
.nav-item summary {
  border-radius: 8px;
}

.nav-root,
.nav-link {
  display: block;
  padding: 7px 10px;
  color: var(--nav-text);
}

.nav-root {
  margin-bottom: 10px;
  font-weight: 720;
}

.nav-root.is-active,
.nav-link.is-active {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 760;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-list .nav-list {
  margin: 3px 0 6px 12px;
  padding-left: 10px;
  border-left: 1px solid var(--border-soft);
}

.nav-item {
  margin: 1px 0;
}

.nav-item[hidden] {
  display: none;
}

.nav-item summary {
  display: flex;
  align-items: center;
  min-height: 34px;
  padding: 4px 8px;
  color: var(--nav-text);
  cursor: pointer;
  font-weight: 720;
}

.nav-item summary:hover,
.nav-link:hover,
.nav-root:hover {
  background: var(--panel);
  text-decoration: none;
}

.nav-item summary::marker {
  color: var(--muted);
}

.nav-item summary a {
  padding: 0;
}

.nav-label {
  display: block;
  padding: 7px 10px;
  color: var(--muted);
}

.content {
  min-width: 0;
  padding: 34px 0 72px;
}

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  align-items: center;
  margin-bottom: 22px;
  color: var(--muted);
  font-size: 13px;
}

.breadcrumbs a,
.breadcrumbs span {
  display: inline-flex;
  align-items: center;
  max-width: 100%;
}

.breadcrumbs > * + *::before {
  content: "/";
  margin: 0 8px;
  color: var(--muted);
}

.doc-article {
  min-width: 0;
}

.doc-article h1,
.doc-article h2,
.doc-article h3,
.doc-article h4,
.doc-article h5,
.doc-article h6 {
  margin: 34px 0 14px;
  color: var(--text);
  line-height: 1.2;
  scroll-margin-top: 86px;
}

.doc-article h1 {
  margin-top: 0;
  font-size: 42px;
  letter-spacing: 0;
}

.doc-article h2 {
  margin-top: 52px;
  padding-top: 22px;
  border-top: 1px solid var(--border-soft);
  font-size: 28px;
}

.doc-article h3 {
  font-size: 22px;
}

.doc-article h4 {
  font-size: 18px;
}

.doc-article p,
.doc-article ul,
.doc-article ol,
.doc-article blockquote,
.doc-article figure,
.doc-article .table-wrap,
.doc-article pre {
  margin: 0 0 18px;
}

.doc-article ul,
.doc-article ol {
  padding-left: 24px;
}

.doc-article li {
  margin: 5px 0;
}

.doc-article blockquote {
  border-left: 4px solid var(--accent);
  padding: 14px 18px;
  border-radius: 0 8px 8px 0;
  background: var(--accent-soft);
  color: var(--text);
}

.doc-article blockquote p:last-child {
  margin-bottom: 0;
}

.doc-article code,
.doc-inline-term {
  border-radius: 6px;
  background: var(--code-bg);
  padding: 2px 5px;
  color: var(--code-text);
}

.doc-inline-term {
  font-weight: 680;
}

.doc-article code {
  font-family: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
  font-size: 0.92em;
}

.doc-article pre {
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--pre-bg);
  padding: 16px;
}

.doc-article pre code {
  background: transparent;
  color: var(--pre-text);
  padding: 0;
  white-space: pre;
}

.doc-article figure {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--figure-bg);
  box-shadow: var(--shadow);
}

.doc-article figure:has(> img),
.doc-article figure:has(> picture),
.doc-article figure:has(.doc-image-group img) {
  cursor: zoom-in;
}

.doc-article figure:has(> img)::after,
.doc-article figure:has(> picture)::after,
.doc-article figure:has(.doc-image-group img)::after {
  content: "Открыть изображение";
  position: absolute;
  top: 12px;
  right: 12px;
  opacity: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 9px;
  background: var(--modal-bg);
  color: var(--text);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.2;
  box-shadow: var(--shadow);
  transform: translateY(-4px);
  transition:
    opacity 140ms ease,
    transform 140ms ease;
  pointer-events: none;
}

.doc-article figure:has(> img):hover::after,
.doc-article figure:has(> picture):hover::after,
.doc-article figure:has(.doc-image-group img):hover::after {
  opacity: 1;
  transform: translateY(0);
}

.small-text {
  font-size: 12px;
}

.doc-image-picture {
  display: block;
}

.doc-image-picture:not(.is-portrait) {
  max-height: 65vh;
}

.doc-image-group {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(10px, 2vw, 16px);
  padding: clamp(12px, 2.4vw, 22px);
  background:
    linear-gradient(180deg, rgba(8, 127, 91, 0.04), rgba(18, 100, 163, 0.07)),
    var(--figure-bg);
}

.doc-image-group-item {
  --doc-image-aspect-ratio: 1;
  display: flex;
  flex: var(--doc-image-aspect-ratio) 1 0;
  min-width: min(180px, 100%, calc(65vh * var(--doc-image-aspect-ratio)));
  max-width: min(100%, calc(65vh * var(--doc-image-aspect-ratio)));
}

.doc-image-group-item > img,
.doc-image-group-item > picture {
  width: 100%;
}

.doc-image-group .doc-image-picture:not(.is-portrait) {
  max-height: none;
}

.doc-image-group .doc-image-picture.is-portrait {
  flex: none;
  align-items: center;
  padding: 0;
  background: transparent;
}

.doc-image-group .missing-image {
  width: 100%;
  min-height: 180px;
}

.doc-image-picture.is-portrait {
  display: flex;
  justify-content: center;
  padding: clamp(12px, 3vw, 28px);
  background:
    linear-gradient(180deg, rgba(8, 127, 91, 0.05), rgba(18, 100, 163, 0.08)),
    var(--figure-bg);
}

.doc-article figure img {
  display: block;
  width: 100%;
}

.doc-article figure .doc-image-picture:not(.is-portrait) img {
  width: auto;
  max-width: 100%;
  max-height: 65vh;
  margin-inline: auto;
  object-fit: contain;
}

.doc-article figure .doc-image-picture.is-portrait img {
  width: auto;
  max-width: min(100%, 302px);
  max-height: min(52vh, 534px);
  border-radius: 8px;
  box-shadow: 0 16px 36px rgba(16, 24, 40, 0.18);
  object-fit: contain;
}

.doc-article figure .doc-image-group .doc-image-picture img {
  width: 100%;
  max-width: 100%;
  max-height: none;
  margin-inline: 0;
  border-radius: 0;
  box-shadow: none;
  object-fit: contain;
}

.doc-article figcaption {
  border-top: 1px solid var(--border-soft);
  padding: 10px 14px;
  color: var(--muted);
  font-size: 14px;
}

.missing-image {
  display: grid;
  gap: 8px;
  place-items: center;
  min-height: 220px;
  padding: 28px;
  background:
    linear-gradient(135deg, rgba(8, 127, 91, 0.08), rgba(18, 100, 163, 0.08)),
    var(--figure-bg);
  color: var(--muted);
  text-align: center;
}

.missing-image span {
  color: var(--text);
  font-weight: 760;
}

.missing-image code {
  max-width: 100%;
  overflow-wrap: anywhere;
  background: var(--code-bg);
  color: var(--nav-text);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
}

.doc-article table {
  width: 100%;
  border-collapse: collapse;
  min-width: 620px;
}

.doc-article th,
.doc-article td {
  border-bottom: 1px solid var(--border-soft);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.doc-article th {
  background: var(--panel);
  font-weight: 760;
}

.doc-article tr:last-child td {
  border-bottom: 0;
}

.toc {
  padding: 32px 0 40px;
}

.toc-nav {
  border-left: 1px solid var(--border-soft);
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.45;
}

.toc-nav p {
  margin: 0 0 12px;
  color: var(--text);
  font-weight: 760;
}

.toc-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.toc-nav li {
  margin: 7px 0;
}

.toc-nav .toc-level-3 {
  padding-left: 14px;
}

.toc-nav a {
  color: var(--muted);
}

.toc-empty {
  color: var(--muted);
}

.pager {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.pager-link {
  min-height: 86px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  color: var(--text);
}

.pager-link:hover {
  border-color: var(--accent);
  text-decoration: none;
}

.pager-link span {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 13px;
}

.pager-link strong {
  display: block;
  overflow-wrap: anywhere;
  line-height: 1.35;
}

.pager-link.next {
  text-align: right;
}

.pager-link.previous:last-child {
  grid-column: 1 / -1;
}

.assistant-modal[hidden] {
  display: none;
}

.assistant-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 20px;
}

.assistant-modal-backdrop {
  position: absolute;
  inset: 0;
  background: var(--modal-backdrop);
  backdrop-filter: blur(6px);
}

.assistant-dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 560px);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 28px;
  background: var(--modal-bg);
  box-shadow: var(--shadow);
}

.assistant-dialog-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--button-bg);
  cursor: pointer;
}

.assistant-dialog-close::before,
.assistant-dialog-close::after {
  content: "";
  position: absolute;
  top: 15px;
  left: 8px;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--text);
}

.assistant-dialog-close::before {
  transform: rotate(45deg);
}

.assistant-dialog-close::after {
  transform: rotate(-45deg);
}

.assistant-dialog-kicker {
  margin: 0 0 8px;
  color: var(--accent);
  font-size: 13px;
  font-weight: 800;
}

.assistant-dialog h2 {
  margin: 0 0 14px;
  font-size: 28px;
  line-height: 1.2;
}

.assistant-dialog p {
  margin: 0 0 14px;
  color: var(--muted);
}

.assistant-dialog-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.assistant-dialog-primary,
.assistant-dialog-secondary {
  min-height: 40px;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 14px;
  font: inherit;
  font-weight: 760;
  cursor: pointer;
}

.assistant-dialog-primary {
  background: var(--accent);
  color: #121212;
}

.assistant-dialog-primary:hover {
  text-decoration: none;
}

.assistant-dialog-secondary {
  background: var(--button-bg);
  color: var(--text);
}

body.is-assistant-modal-open {
  overflow: hidden;
}

.image-viewer[hidden] {
  display: none;
}

.image-viewer {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.86);
}

.image-viewer-backdrop {
  position: absolute;
  inset: 0;
}

.image-viewer-stage {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 100vw;
  height: 100vh;
  overflow: hidden;
  cursor: grab;
  touch-action: none;
  user-select: none;
}

.image-viewer-stage:active {
  cursor: grabbing;
}

.image-viewer-stage img {
  max-width: min(92vw, 1400px);
  max-height: 86vh;
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
  transform-origin: center center;
  transition: transform 80ms linear;
  will-change: transform;
}

.image-viewer-toolbar {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 2;
  display: flex;
  gap: 8px;
  align-items: center;
}

.image-viewer-toolbar [hidden] {
  display: none;
}

.image-viewer-toolbar button {
  display: grid;
  place-items: center;
  min-width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(18, 18, 18, 0.82);
  color: #fff;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
}

.image-viewer-toolbar button:hover {
  border-color: rgba(255, 206, 49, 0.8);
}

.image-viewer-toolbar button:disabled {
  opacity: 0.45;
  cursor: default;
}

.image-viewer-toolbar button:disabled:hover {
  border-color: rgba(255, 255, 255, 0.22);
}

.image-viewer-toolbar [data-image-zoom-reset] {
  min-width: 58px;
  font-size: 13px;
}

.image-viewer-counter {
  display: grid;
  place-items: center;
  min-width: 54px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  background: rgba(18, 18, 18, 0.82);
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
}

.image-viewer-toolbar [data-image-viewer-close] {
  position: relative;
}

.image-viewer-toolbar [data-image-viewer-close]::before,
.image-viewer-toolbar [data-image-viewer-close]::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
}

.image-viewer-toolbar [data-image-viewer-close]::before {
  transform: rotate(45deg);
}

.image-viewer-toolbar [data-image-viewer-close]::after {
  transform: rotate(-45deg);
}

body.is-image-viewer-open {
  overflow: hidden;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle::before {
    transform: translateX(24px);
  }
}

@media (max-width: 1180px) {
  .shell {
    grid-template-columns: 280px minmax(0, 1fr);
  }

  .toc {
    display: none;
  }
}

@media (max-width: 860px) {
  .topbar {
    grid-template-columns: auto minmax(0, 1fr) auto;
    row-gap: 10px;
    min-height: 118px;
    padding: 12px 16px;
  }

  .brand {
    justify-self: start;
  }

  .menu-toggle {
    display: grid;
    align-self: center;
    justify-self: start;
  }

  .assistant-search {
    grid-column: 1 / -1;
    grid-row: auto;
    order: 2;
    width: 100%;
    margin-bottom: 12px;
  }

  .shell {
    display: block;
    padding: 0 18px;
  }

  .sidebar {
    position: fixed;
    inset: 118px auto 0 0;
    z-index: 30;
    width: min(88vw, 340px);
    height: calc(100vh - 118px);
    border-right: 1px solid var(--border);
    background: var(--sidebar-bg);
    padding: 20px;
    transform: translateX(-105%);
    transition: transform 160ms ease;
    box-shadow: var(--shadow);
  }

  body.is-sidebar-open .sidebar {
    transform: translateX(0);
  }

  .content {
    padding-top: 28px;
  }

  .breadcrumbs {
    margin-bottom: 16px;
    font-size: 12px;
    line-height: 1.35;
  }

  .breadcrumbs > *:not(:first-child):not(:last-child) {
    display: none;
  }

  .breadcrumbs > * + *::before {
    margin: 0 6px;
  }

  .breadcrumbs > *:last-child:not(:nth-child(2))::before {
    content: "... /";
  }

  .doc-article h1 {
    font-size: 32px;
  }

  .doc-article h2 {
    font-size: 24px;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 15px;
  }

  .shell {
    padding: 0 14px;
  }

  .doc-article h1 {
    font-size: 28px;
  }

  .brand {
    min-width: 118px;
  }

  .brand-logo {
    width: 118px;
  }

  .assistant-search-key {
    display: none;
  }

  .assistant-dialog {
    padding: 24px 18px;
  }

  .image-viewer-toolbar {
    top: 12px;
    right: 12px;
  }

  .image-viewer-toolbar button {
    min-width: 38px;
    height: 38px;
  }

  .pager {
    grid-template-columns: 1fr;
  }

  .pager-link.next {
    text-align: left;
  }
}
