:root {
  --bg: #fbfbf8;
  --panel: #ffffff;
  --text: #202124;
  --muted: #5f6368;
  --border: #deded8;
  --accent: #206a5d;
  --accent-ink: #11443b;
  --code-bg: #f3f5f4;
  --shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

* {
  box-sizing: border-box;
}

html {
  color: var(--text);
  background: var(--bg);
  font-family:
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial,
    sans-serif;
  line-height: 1.6;
}

body {
  margin: 0;
}

a {
  color: var(--accent);
}

a:hover {
  color: var(--accent-ink);
}

.site-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--panel);
  padding: 8px 12px;
  border: 1px solid var(--border);
}

.skip-link:focus {
  left: 8px;
  z-index: 10;
}

.site-header {
  background: var(--panel);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.site-header__inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand {
  color: var(--text);
  text-decoration: none;
  display: grid;
  gap: 1px;
}

.brand__title {
  font-weight: 750;
  font-size: 1.18rem;
}

.brand__tagline {
  color: var(--muted);
  font-size: 0.86rem;
}

.top-nav a {
  font-weight: 600;
  text-decoration: none;
}

.repo-link {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid var(--accent);
  border-radius: 6px;
  color: var(--accent-ink);
  background: #eef6f2;
}

.repo-link:hover {
  background: #dceee7;
  color: var(--accent-ink);
}

.docs-layout {
  display: grid;
  grid-template-columns: 245px minmax(0, 1fr);
  gap: 38px;
  padding: 32px 0 52px;
}

.sidebar {
  position: sticky;
  top: 24px;
  align-self: start;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  box-shadow: var(--shadow);
}

.sidebar__group {
  margin: 2px 0;
}

.sidebar__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 36px;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--text);
  cursor: pointer;
  font-size: 0.94rem;
  list-style: none;
}

.sidebar__summary::-webkit-details-marker {
  display: none;
}

.sidebar__summary::after {
  flex: 0 0 auto;
  content: "";
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(-45deg);
  transition: transform 0.16s ease;
}

.sidebar__group[open] .sidebar__summary::after {
  transform: rotate(45deg);
}

.sidebar__summary:hover,
.sidebar__group--active .sidebar__summary {
  background: #e8f1ee;
  color: var(--accent-ink);
}

.sidebar__summary-link {
  color: inherit;
  text-decoration: none;
  flex: 1 1 auto;
}

.sidebar__summary-link--active {
  color: var(--accent-ink);
}

.sidebar__children {
  margin: 2px 0 6px 10px;
  padding-left: 10px;
  border-left: 1px solid var(--border);
}

.sidebar__link {
  display: block;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--text);
  text-decoration: none;
  font-size: 0.94rem;
}

.sidebar__child-link {
  padding: 6px 9px;
  color: var(--muted);
  font-size: 0.86rem;
}

.sidebar__link:hover,
.sidebar__link--active {
  background: #e8f1ee;
  color: var(--accent-ink);
}

.sidebar__link--repo {
  margin-top: 10px;
  border-top: 1px solid var(--border);
  border-radius: 0 0 6px 6px;
  color: var(--accent-ink);
  font-weight: 650;
}

.content {
  min-width: 0;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 34px;
  box-shadow: var(--shadow);
}

.content h1 {
  margin-top: 0;
  font-size: 2.1rem;
  line-height: 1.18;
}

.content h2 {
  margin-top: 2.1rem;
  padding-top: 0.4rem;
  border-top: 1px solid var(--border);
}

.content h3 {
  margin-top: 1.5rem;
}

.content table {
  display: block;
  width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  margin: 1rem 0;
}

.content th,
.content td {
  border: 1px solid var(--border);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

.content th {
  background: #f4f6f5;
}

.content img {
  display: block;
  width: auto;
  max-width: min(100%, 760px);
  height: auto;
  margin: 1.1rem auto 0.45rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.content figure {
  margin: 1.35rem 0;
}

.content figcaption {
  color: var(--muted);
  font-size: 0.92rem;
  text-align: center;
}

code {
  background: var(--code-bg);
  padding: 0.12rem 0.28rem;
  border-radius: 4px;
  font-size: 0.92em;
}

pre {
  overflow-x: auto;
  padding: 14px 16px;
  background: #17211f;
  color: #ecf4f1;
  border-radius: 8px;
}

pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

blockquote {
  margin-left: 0;
  padding: 0.6rem 1rem;
  border-left: 4px solid var(--accent);
  background: #f1f7f4;
  color: var(--accent-ink);
}

.site-footer {
  border-top: 1px solid var(--border);
  color: var(--muted);
  padding: 18px 0;
  font-size: 0.9rem;
}

.site-footer .site-shell {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

@media (max-width: 820px) {
  .docs-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .sidebar {
    position: static;
  }

  .sidebar nav {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
  }

  .sidebar__group {
    flex: 1 1 180px;
  }

  .sidebar__children {
    margin-left: 6px;
  }

  .content {
    padding: 24px 18px;
  }

  .site-footer .site-shell {
    display: grid;
  }
}
