:root {
  color-scheme: light;
  --ink: #16161d;
  --paper: #f7f6f2;
  --violet: #5b3fd6;
  --lime: #c6f432;
  --muted: #585766;
  --line: #d9d5e2;
  font: 100%/1.6 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; }
[hidden] { display: none !important; }
a { color: var(--violet); text-underline-offset: .2em; }
a:hover { text-decoration-thickness: .15em; }
:focus-visible { outline: 3px solid var(--violet); outline-offset: 4px; }
.wrap { width: min(70rem, calc(100% - 2rem)); margin-inline: auto; }
.site-header { border-bottom: 1px solid var(--line); }
.header-inner, .footer-inner { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-block: 1rem; }
.brand { color: var(--ink); display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; font-weight: 750; }
.brand-mark { display: grid; place-items: center; width: 2.2rem; height: 2.2rem; border-radius: .65rem; background: var(--lime); color: var(--ink); }
.brand-sub, .site-header nav, .site-footer { color: var(--muted); font-size: .9rem; }
.hero { background: #eee9ff; border-bottom: 1px solid var(--line); }
.hero-inner { padding-block: clamp(2.6rem, 7vw, 5.5rem); }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.025em; }
h1 { font-size: clamp(2rem, 5vw, 3.65rem); margin: 0 0 1.2rem; overflow-wrap: anywhere; }
.search-box { display: flex; gap: .5rem; max-width: 44rem; }
.search-box input, .search-box button { min-height: 3.25rem; font: inherit; border-radius: .65rem; }
.search-box input { flex: 1; min-width: 0; border: 1px solid #877da2; background: white; padding-inline: .85rem; }
.search-box button { background: var(--violet); color: white; border: 0; padding-inline: 1.15rem; font-weight: 700; cursor: pointer; }
#search-panel { max-width: 44rem; }
.sections, .section-page, .article-shell { padding-block: 2.5rem 4rem; }
.section-grid, .article-list, .toc ul { margin: 0; padding: 0; list-style: none; }
.section-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.section-grid a, .article-list a { display: block; background: #fff; border: 1px solid var(--line); border-radius: .8rem; padding: 1rem; text-decoration: none; color: var(--ink); }
.section-grid a { position: relative; height: 100%; min-height: 6.1rem; padding-right: 2.4rem; }
.section-grid a:hover, .article-list a:hover { border-color: var(--violet); }
.section-grid h2 { font-size: 1.12rem; margin: 0 0 .45rem; }
.section-grid span, .article-list span { color: var(--muted); font-size: .9rem; }
.section-grid .arrow { position: absolute; top: 1rem; right: 1rem; color: var(--violet); }
.article-list { display: grid; gap: .55rem; max-width: 46rem; }
.article-list span { display: block; }
.crumb { display: flex; flex-wrap: wrap; gap: .55rem; margin-bottom: 1.35rem; font-size: .92rem; }
.article-layout { display: grid; grid-template-columns: minmax(0, 45rem) minmax(10rem, 16rem); gap: clamp(1rem, 5vw, 4rem); align-items: start; }
.toc { grid-column: 2; grid-row: 1; position: sticky; top: 1rem; border-left: 1px solid var(--line); padding-left: 1rem; }
.toc li { margin-top: .4rem; }
.prose { grid-column: 1; grid-row: 1; min-width: 0; overflow-wrap: break-word; }
.prose h1 { font-size: clamp(2rem, 4vw, 3.1rem); }
.prose h2 { margin-top: 2.25rem; }
.prose h3, .prose h4 { margin-top: 1.5rem; }
.prose li + li { margin-top: .5rem; }
.prose code { background: #eee9ff; padding: .1em .3em; border-radius: .25rem; }
.prose img { max-width: 100%; height: auto; }
.site-footer { border-top: 1px solid var(--line); }
.footer-inner nav { display: flex; gap: 1rem; }
.sr-only, .skip:not(:focus) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.skip:focus { position: fixed; z-index: 2; padding: .5rem; background: var(--paper); }
@media (max-width: 52rem) {
  .section-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout { display: flex; flex-direction: column; }
  .toc { position: static; margin-bottom: .75rem; }
}
@media (max-width: 32rem) {
  .section-grid { grid-template-columns: 1fr; }
  .header-inner { align-items: start; }
  .brand-sub { display: block; }
}
