:root {
  color-scheme: dark;
  --ink: #efece6;
  --muted: #aaa59d;
  --subtle: #a09a91;
  --paper: #1c1d1f;
  --ground: #232426;
  --raised: #2a2b2e;
  --hover: #323336;
  --line: #3d3e41;
  --accent: #f29a72;
  --accent-strong: #ff8057;
  --accent-art: #ff8057;
  --accent-control: #ff8057;
  --model-orange: 230 92 41;
  --model-chalk: 184 176 158;
  --model-sage: 74 125 107;
  --model-blue: 51 92 133;
  --model-graphite: 48 56 51;
  --tool-shadow: #00000033;
  --selected: #32251e;
  --code-bg: #202123;
  --code-string: #aed0b0;
  --code-keyword: #e6b393;
  --code-number: #dfc187;
  --alert-bg: #282119;
  --alert-ink: #e9c28f;
  --window-rgb: 30 29 26;
  --window-ink: #eee3d2;
  --motion-line: #6d5240;
  --motion-dot: #fc8556;
  --shadow: #00000022;
}
:root[data-theme="light"] {
  color-scheme: light;
  --ink: #272723;
  --muted: #65635e;
  --subtle: #76716a;
  --paper: #faf9f6;
  --ground: #f1efe9;
  --raised: #ffffff;
  --hover: #ece9e2;
  --line: #dedad2;
  --accent: #b94b26;
  --accent-strong: #b94b26;
  --accent-art: #e36635;
  --accent-control: #e97746;
  --model-orange: 244 129 77;
  --model-chalk: 225 219 206;
  --model-sage: 142 180 163;
  --model-blue: 128 165 198;
  --model-graphite: 133 144 151;
  --tool-shadow: #35332d1c;
  --selected: #fff0e5;
  --code-bg: #f5f3ed;
  --code-string: #32633c;
  --code-keyword: #9c4725;
  --code-number: #835b16;
  --alert-bg: #f3e9d8;
  --alert-ink: #795320;
  --window-rgb: 255 252 245;
  --window-ink: #403c36;
  --motion-line: #c3ac94;
  --motion-dot: #b84f26;
  --shadow: #39280c15;
}
.theme-choice {
  display: flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
}
.theme-toggle {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 62px;
  height: 32px;
  padding: 7px;
  border: 1px solid var(--line);
  background: var(--ground);
  border-radius: 30px;
  color: var(--muted);
}
.theme-toggle svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  position: relative;
  z-index: 1;
}
.theme-thumb {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  background: var(--raised);
  border: 1px solid var(--line);
  border-radius: 50%;
  box-shadow: 0 1px 4px var(--shadow);
  transition: transform 0.18s ease;
}
.theme-toggle[aria-checked="true"] .theme-thumb {
  transform: translateX(30px);
}
.theme-toggle[aria-checked="true"] .theme-moon,
.theme-toggle[aria-checked="false"] .theme-sun {
  color: var(--accent);
}
.theme-toggle:hover {
  border-color: var(--subtle);
}
.theme-auto {
  background: transparent;
  border: 1px solid transparent;
  padding: 6px 7px;
  color: var(--subtle);
  font-size: 0.6875rem;
  border-radius: 5px;
}
.theme-auto[aria-pressed="true"] {
  color: var(--accent);
  background: var(--selected);
}
.theme-auto:hover {
  border-color: var(--line);
}
.home-header > .theme-choice {
  margin-left: auto;
}
.sidebar-foot {
  flex-wrap: wrap;
  gap: 12px;
}
@media (max-width: 760px) {
  .home-header > .theme-choice {
    position: absolute;
    right: 20px;
    top: 21px;
  }
  .home-header .brand {
    font-size: 1.1rem;
  }
  .theme-choice {
    gap: 4px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .theme-thumb {
    transition: none;
  }
}
