.docs-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr) 200px;
  gap: 40px;
  align-items: start;
  padding: 40px 0 80px;
}

.docs-sidebar-desktop,
.docs-sidebar-mobile {
  min-width: 0;
}

.docs-sidebar-desktop {
  position: sticky;
  top: 24px;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
}

.docs-sidebar-mobile {
  display: none;
}

.docs-nav-label {
  margin: 0 0 12px;
  color: var(--tertiary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.docs-nav-list {
  position: sticky;
  top: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.docs-nav-list li + li {
  margin-top: 4px;
}

.docs-nav-list a {
  display: block;
  padding: 8px 10px;
  border-radius: var(--radius-small);
  color: var(--muted);
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
}

.docs-nav-list a:hover {
  color: var(--text);
}

.docs-nav-list a[aria-current="page"] {
  color: #000000;
  background: var(--accent);
}

.docs-content {
  min-width: 0;
  max-width: 72ch;
}

.docs-eyebrow {
  margin: 0 0 12px;
  color: var(--tertiary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.docs-content h1 {
  max-width: none;
  margin-bottom: 16px;
  overflow-wrap: anywhere;
  font-size: clamp(2.25rem, 4vw, 3rem);
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 0.95;
  text-transform: uppercase;
  text-align: left;
}

.docs-content h1,
.docs-content h2,
.docs-content h3 {
  scroll-margin-top: 24px;
}

.heading-anchor {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem;
  height: 1.5rem;
  margin-left: 0.2em;
  padding: 4px;
  color: var(--tertiary);
  opacity: 0.45;
  vertical-align: -0.35em;
  text-decoration: none;
  transition: color 150ms ease, opacity 150ms ease;
}

.heading-anchor:hover,
.heading-anchor:focus-visible {
  color: var(--text);
  opacity: 1;
}

.heading-anchor svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.docs-copy-status {
  position: fixed;
  z-index: 20;
  right: 24px;
  bottom: 24px;
  padding: 10px 14px;
  border: var(--border);
  color: #000000;
  background: var(--accent);
  box-shadow: var(--shadow-small);
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 150ms ease, transform 150ms ease;
}

.docs-copy-status.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .heading-anchor,
  .docs-copy-status {
    transition: none;
  }
}

.docs-intro {
  max-width: none;
  margin-bottom: 32px;
  color: var(--muted);
  font-size: 19px;
}

.docs-content h2 {
  margin: 40px 0 16px;
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.docs-content h2:first-of-type {
  margin-top: 0;
}

.docs-content h3 {
  margin: 24px 0 10px;
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.docs-content p {
  margin-bottom: 16px;
  color: var(--muted);
}

.docs-content ul,
.docs-content ol {
  margin: 0 0 16px;
  padding-left: 22px;
  color: var(--muted);
}

.docs-content li + li {
  margin-top: 6px;
}

.docs-content li::marker {
  color: var(--text);
}

.docs-content strong {
  color: var(--text);
}

.docs-content a {
  font-weight: 700;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.docs-content table {
  width: 100%;
  margin: 0 0 24px;
  border-collapse: collapse;
  font-size: 15px;
}

.docs-content th,
.docs-content td {
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.docs-content th {
  background: var(--accent);
  color: #000000;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.docs-content td {
  background: var(--panel);
  color: #000000;
}

.docs-content code {
  display: inline;
  padding: 2px 5px;
  color: #000000;
  background: var(--accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.85em;
  white-space: normal;
}

.docs-content pre {
  margin: 0 0 20px;
  padding: 14px 16px;
  overflow-x: auto;
  border-radius: var(--radius-medium);
  background: var(--sunken);
}

.docs-content pre code {
  display: block;
  padding: 0;
  color: #000000;
  background: none;
  font-size: 13px;
  line-height: 1.6;
  white-space: pre;
}

.docs-callout {
  margin: 0 0 20px;
  padding: 14px 18px;
  background: var(--sidebar);
  color: #000000;
}

.docs-callout p {
  margin-bottom: 0;
  color: #000000;
}

.docs-callout p + p {
  margin-top: 10px;
}

.docs-next {
  margin-top: 40px;
  font-size: 14px;
}

.docs-toc {
  position: sticky;
  top: 24px;
  min-width: 0;
}

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

.docs-toc li + li {
  margin-top: 4px;
}

.docs-toc a {
  display: block;
  padding: 4px 0;
  color: var(--muted);
  font-size: 13px;
  text-decoration: none;
}

.docs-toc a:hover {
  color: var(--text);
  text-decoration: underline;
}

@media (max-width: 900px) {
  .docs-shell {
    display: block;
    padding: 24px 0 64px;
  }

  .docs-sidebar-desktop,
  .docs-toc {
    display: none;
  }

  .docs-sidebar-mobile {
    display: block;
    margin-bottom: 28px;
    background: var(--panel);
  }

  .docs-sidebar-mobile summary {
    padding: 12px 16px;
    color: #000000;
    background: var(--accent);
    font-weight: 900;
    font-size: 13px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
  }

  .docs-sidebar-mobile .docs-nav-list {
    position: static;
    padding: 10px 16px 16px;
  }

  .docs-content {
    max-width: none;
  }
}
