:root {
  --bg: #f4f3ef;
  --fg: #131312;
  --quiet: #5d5c57;
  --rule: #d9d8d1;
  --raised: #eae8e2;
  --link: #131312;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141413;
    --fg: #ecebe6;
    --quiet: #a3a29b;
    --rule: #34332f;
    --raised: #1d1d1b;
    --link: #ecebe6;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

a { color: var(--link); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 2px; }

.skip { position: absolute; left: 16px; top: -48px; background: var(--fg); color: var(--bg); padding: 8px 12px; }
.skip:focus { top: 8px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip-path: inset(50%); white-space: nowrap;
}

.top {
  position: sticky; top: 0; z-index: 2;
  display: flex; align-items: center; gap: 16px;
  padding: 12px 16px; background: var(--bg); border-bottom: 1px solid var(--rule);
}
.brand { font-weight: 600; text-decoration: none; white-space: nowrap; }
.brand span { font-weight: 400; color: var(--quiet); }
.help { margin-left: auto; white-space: nowrap; }

.search { position: relative; flex: 1; max-width: 420px; margin-left: auto; }
.search input {
  width: 100%; height: 40px; padding: 0 12px; font: inherit; color: inherit;
  background: var(--raised); border: 1px solid var(--rule); border-radius: 0;
}
.results {
  position: absolute; left: 0; right: 0; top: 44px; margin: 0; padding: 0; list-style: none;
  background: var(--bg); border: 1px solid var(--rule); max-height: 70vh; overflow: auto;
}
.results a { display: block; padding: 10px 12px; text-decoration: none; border-bottom: 1px solid var(--rule); }
.results a:hover, .results a:focus-visible { background: var(--raised); }
.results small { display: block; color: var(--quiet); }

.frame { display: grid; grid-template-columns: 1fr; max-width: 1200px; margin: 0 auto; }

.side { border-bottom: 1px solid var(--rule); padding: 0 16px; }
.side > summary { padding: 12px 0; cursor: pointer; }
.side ul { list-style: none; margin: 0; padding: 0; }
.side li a { display: block; padding: 6px 0; text-decoration: none; color: var(--quiet); }
.side li a:hover, .side li a[aria-current] { color: var(--fg); }
.side li a[aria-current] { font-weight: 600; }
.side details { border-top: 1px solid var(--rule); }
.side details summary { padding: 10px 0; cursor: pointer; font-weight: 600; }
.side .guides { padding-bottom: 12px; }

main { padding: 24px 16px 64px; min-width: 0; max-width: 760px; }

@media (min-width: 900px) {
  .frame { grid-template-columns: 280px 1fr; gap: 48px; padding: 0 24px; }
  .side { border: 0; padding: 24px 0; position: sticky; top: 65px; align-self: start; max-height: calc(100vh - 65px); overflow: auto; }
  .side > summary { display: none; }
  main { padding: 32px 0 80px; }
}

h1 { font-size: 2rem; line-height: 1.2; margin: 0 0 16px; font-weight: 600; }
h2 { font-size: 1.35rem; margin: 48px 0 12px; padding-top: 16px; border-top: 1px solid var(--rule); font-weight: 600; }
h3 { font-size: 1.05rem; margin: 32px 0 8px; font-weight: 600; }
h4 { font-size: 1rem; margin: 0; font-weight: 600; }
p, ul, ol { margin: 0 0 16px; }
li { margin-bottom: 6px; }
code { font: 0.9em ui-monospace, Consolas, monospace; background: var(--raised); padding: 1px 4px; }

.lead { font-size: 1.1rem; }
.path, .note, .meta, .options, .blocks { color: var(--quiet); }
.path { font-size: 0.9rem; }
.note { font-size: 0.95rem; }

.setting { padding: 12px 0; border-top: 1px solid var(--rule); }
.setting p { margin: 4px 0 0; }
.setting .meta, .setting .options { font-size: 0.875rem; }
.setting ul { margin: 8px 0 0; }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps > li { counter-increment: step; position: relative; padding-left: 40px; margin-bottom: 16px; }
.steps > li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 28px; height: 28px; border: 1px solid var(--fg); border-radius: 50%;
  display: grid; place-items: center; font-size: 0.85rem;
}

.callout { border-left: 2px solid var(--fg); padding: 4px 0 4px 16px; margin: 0 0 16px; }

.faq details { border-top: 1px solid var(--rule); padding: 12px 0; }
.faq summary { cursor: pointer; font-weight: 600; }
.faq details p:first-of-type { margin-top: 8px; }

.form { width: 100%; min-height: 900px; border: 0; }

table { border-collapse: collapse; width: 100%; margin: 0 0 16px; font-size: 0.95rem; }
th, td { text-align: left; vertical-align: top; padding: 8px 12px 8px 0; border-top: 1px solid var(--rule); }
.table { overflow-x: auto; }

.foot { border-top: 1px solid var(--rule); padding: 16px; color: var(--quiet); font-size: 0.9rem; text-align: center; }
.foot p { margin: 0; }

@media (max-width: 599px) {
  .top { flex-wrap: wrap; }
  .search { order: 3; flex-basis: 100%; max-width: none; }
}
