:root {
  --background: #f7f7f3;
  --foreground: #11110f;
  --muted: #666661;
  --border: #dcdcd6;
  --code-background: #11110f;
  --content-width: 72rem;
  --font-sans: Inter, "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1.5rem;
  --space-5: 2.5rem;
  --space-6: 4rem;
}

* {
  box-sizing: border-box;
}

html {
  color: var(--foreground);
  background: var(--background);
  font-family: var(--font-sans);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--foreground);
  background: var(--background);
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--foreground);
  outline-offset: 3px;
}

code,
pre {
  font-family: var(--font-mono);
}

.wy-body-for-nav {
  background: var(--background);
}

.wy-nav-side,
.wy-side-scroll {
  background: #f0f0eb;
}

.wy-nav-side {
  border-right: 1px solid var(--border);
}

.wy-side-nav-search {
  padding: 1.5rem;
  background: #f0f0eb;
}

.docs-brand {
  display: flex;
  gap: 0.7rem;
  align-items: center;
  color: var(--foreground) !important;
  font-size: 1.1rem;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.wy-side-nav-search > .docs-brand {
  display: flex;
  justify-content: center;
}

.docs-brand img {
  width: 3.5rem;
  height: auto;
  margin: 0;
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.wy-side-nav-search input[type="text"] {
  border: 1px solid var(--border);
  border-radius: 0;
  box-shadow: none;
  color: var(--foreground);
  background: var(--background);
  font-family: var(--font-sans);
}

.wy-menu-vertical {
  padding-block: 1rem;
}

.wy-menu-vertical p.caption {
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
}

.wy-menu-vertical a {
  color: var(--foreground);
}

.wy-menu-vertical a:hover,
.wy-menu-vertical li.current > a,
.wy-menu-vertical li.on a {
  color: var(--foreground);
  background: #e5e5df;
}

.wy-nav-content-wrap,
.wy-nav-content {
  background: var(--background);
}

.wy-nav-content {
  max-width: 58rem;
  padding: clamp(2rem, 6vw, 5rem);
}

.rst-content h1,
.rst-content h2,
.rst-content h3 {
  color: var(--foreground);
  font-family: var(--font-sans);
  font-weight: 600;
  letter-spacing: -0.035em;
}

.rst-content h1 {
  font-size: clamp(2.5rem, 7vw, 4.5rem);
}

.rst-content h2 {
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.rst-content p,
.rst-content li {
  color: #383834;
  line-height: 1.75;
}

.rst-content code {
  border: 0;
  color: var(--foreground);
  background: #e9e9e3;
}

.rst-content div[class^="highlight"],
.rst-content pre {
  border: 1px solid #292927;
  border-radius: 0;
  background: var(--code-background);
}

.rst-content pre code {
  color: #e6edf3;
  background: transparent;
}

.rst-content .hljs {
  color: #e6edf3;
  background: var(--code-background);
}

.rst-content .hljs-comment,
.rst-content .hljs-quote {
  color: #a8b0bb;
}

.rst-content .hljs-keyword,
.rst-content .hljs-selector-tag,
.rst-content .hljs-literal,
.rst-content .hljs-section,
.rst-content .hljs-link {
  color: #ff9b9b;
}

.rst-content .hljs-string,
.rst-content .hljs-regexp,
.rst-content .hljs-addition,
.rst-content .hljs-attribute,
.rst-content .hljs-meta .hljs-string {
  color: #b7dcff;
}

.rst-content .hljs-attr,
.rst-content .hljs-variable,
.rst-content .hljs-template-variable,
.rst-content .hljs-type,
.rst-content .hljs-number,
.rst-content .hljs-symbol,
.rst-content .hljs-bullet {
  color: #c7b8ff;
}

.rst-content .hljs-title,
.rst-content .hljs-title.class_,
.rst-content .hljs-title.function_,
.rst-content .hljs-selector-id,
.rst-content .hljs-selector-class {
  color: #f2cc8f;
}

.rst-content .hljs-built_in,
.rst-content .hljs-doctag,
.rst-content .hljs-name,
.rst-content .hljs-meta {
  color: #8fd8c7;
}

.rst-content .hljs-deletion {
  color: #ffb3b3;
  background: #4b1f24;
}

.rst-content .hljs-addition {
  background: #173b2c;
}

.rst-content .hljs-emphasis {
  font-style: italic;
}

.rst-content .hljs-strong {
  font-weight: 700;
}

.wy-breadcrumbs {
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
}

.wy-breadcrumbs a,
.rst-content a {
  color: var(--foreground);
  text-decoration: underline;
  text-decoration-color: #a4a49e;
  text-underline-offset: 0.18em;
}

.wy-nav-top {
  color: var(--foreground);
  background: var(--background);
  border-bottom: 1px solid var(--border);
}

@media (max-width: 768px) {
  .wy-nav-side {
    border-right: 0;
  }

  .wy-nav-content {
    padding: 2rem 1.25rem 4rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
