
:root {
  color-scheme: light;
  --ink: #000;
  --paper: #fff;
  --body: #2b2b28;
  --mute: #6b6b66;
  --soft: #8a8a84;
  --rule: #e2e2dc;
  --grid: rgba(0, 0, 0, .055);
  --dot: rgba(0, 0, 0, .09);
  --hl: rgba(0, 0, 0, .07);
  --nav: rgba(255, 255, 255, .9);
  --sans: "Instrument Sans", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --gutter: 72px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
  color-scheme: dark;
    --ink: #ecece6;
    --paper: #0c0c0b;
    --body: #c9c9c3;
    --mute: #8f8f88;
    --soft: #6f6f69;
    --rule: #2a2a27;
    --grid: rgba(255, 255, 255, .045);
    --dot: rgba(255, 255, 255, .08);
    --hl: rgba(255, 255, 255, .1);
    --nav: rgba(12, 12, 11, .88);
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #ecece6;
  --paper: #0c0c0b;
  --body: #c9c9c3;
  --mute: #8f8f88;
  --soft: #6f6f69;
  --rule: #2a2a27;
  --grid: rgba(255, 255, 255, .045);
  --dot: rgba(255, 255, 255, .08);
  --hl: rgba(255, 255, 255, .1);
  --nav: rgba(12, 12, 11, .88);
}
* { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  color: var(--ink); font: 400 17px/1.55 var(--sans); -webkit-font-smoothing: antialiased;
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    radial-gradient(var(--dot) 1px, transparent 1.2px);
  background-size: 80px 80px, 80px 80px, 16px 16px;
  background-position: -1px -1px, -1px -1px, 0 0;
}
a { color: inherit; }
.wrap { max-width: 1160px; margin: 0 auto; padding: 0 28px 0 calc(28px + var(--gutter)); position: relative; }
.mono { font-family: var(--mono); font-size: 12.5px; letter-spacing: .02em; }

/* nav */
nav { position: sticky; top: 0; z-index: 20; background: var(--nav); backdrop-filter: blur(8px); border-bottom: 1px solid var(--ink); }
nav .wrap { display: flex; align-items: center; justify-content: space-between; height: 58px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; font-weight: 600; font-size: 19px; letter-spacing: -.02em; }
.brand svg { height: 22px; width: auto; }
nav ul { display: flex; gap: 26px; list-style: none; padding: 0; }
nav ul a { text-decoration: none; color: var(--mute); font-size: 14.5px; transition: color .2s; }
nav ul a:hover { color: var(--ink); }
nav ul a.on { color: var(--ink); }

/* theme toggle */
.theme { display: inline-grid; place-items: center; width: 34px; height: 34px; border: 1px solid var(--ink); background: none; color: var(--ink); cursor: pointer; margin-left: 22px; }
.theme svg { width: 16px; height: 16px; }
.theme .sun { display: none; }
.theme[aria-pressed="true"] .sun { display: block; }
.theme[aria-pressed="true"] .moon { display: none; }
.nav-right { display: flex; align-items: center; }

/* chart elements, themed */
.gridline { stroke: var(--rule); }
.ink-line { stroke: var(--ink); fill: none; }
.ink-fill { fill: var(--ink); }
.hatch { fill: none; stroke: var(--ink); stroke-width: 1; }
.chart rect { transition: width .9s var(--ease); }
.on-fill { fill: #fff; mix-blend-mode: difference; }
.dim { color: var(--mute); }

/* the bus: one trace down the left gutter, vias at each section */
#bus { position: absolute; left: 0; top: 0; width: 100%; pointer-events: none; z-index: 1; }
#bus .base { stroke: var(--ink); stroke-width: 1; opacity: .18; fill: none; }
#bus .live { stroke: var(--ink); stroke-width: 2; fill: none; }
#bus .via { fill: var(--paper); stroke: var(--ink); stroke-width: 1.5; }
#bus .via.lit { fill: var(--ink); }
#bus .q { fill: var(--ink); }

/* hero */
.hero { padding: 72px 0 40px; position: relative; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; align-items: start; }
.refdes { display: inline-flex; gap: 10px; align-items: center; color: var(--mute); }
.refdes b { color: var(--ink); font-weight: 500; border: 1px solid var(--ink); padding: 1px 6px; }
.hero h1 { font-weight: 500; font-size: clamp(42px, 6.4vw, 84px); line-height: .98; letter-spacing: -.045em; margin-top: 26px; min-height: 2em; }
.hero p.lede { margin-top: 26px; max-width: 470px; color: var(--body); font-size: 18px; min-height: 4.7em; }
.tok { position: relative; white-space: pre-wrap; }
.tok::before { content: ""; position: absolute; left: 0; top: .1em; bottom: .05em; width: 1px; background: var(--ink); opacity: 0; }
.tok.fresh::before { opacity: .55; }
.tok.fresh { background: var(--hl); }
.hero h1 .tok:nth-child(n+3) { color: var(--soft); }
.meter { margin-top: 18px; color: var(--mute); font-variant-numeric: tabular-nums; }
.meter span { color: var(--ink); }

/* schematic */
.schem { border: 1px solid var(--ink); background: var(--paper); position: relative; }
.schem-head, .schem-foot { display: flex; justify-content: space-between; gap: 12px; padding: 9px 12px; color: var(--mute); flex-wrap: wrap; }
.schem-head { border-bottom: 1px solid var(--ink); }
.schem-foot { border-top: 1px solid var(--ink); }
.schem-head b, .schem-foot b { color: var(--ink); font-weight: 500; font-variant-numeric: tabular-nums; }
.schem svg { display: block; width: 100%; height: auto; }
.schem text { font-family: var(--mono); font-size: 12px; fill: var(--ink); }
.schem .dim { fill: var(--mute); }
.schem .wire { stroke: var(--ink); stroke-width: 1.4; fill: none; }
.schem .flow { stroke: var(--ink); stroke-width: 3.2; fill: none; stroke-dasharray: 1.5 13; stroke-linecap: round; }
.schem .part { fill: var(--paper); stroke: var(--ink); stroke-width: 1.4; }
.schem .fillbar { fill: var(--ink); }
.schem .tp { fill: var(--paper); stroke: var(--ink); stroke-width: 1.4; }
#scope { display: block; width: 100%; height: 150px; border-top: 1px solid var(--ink); }

/* sections */
section { padding: 120px 0; position: relative; }
.label { margin-bottom: 30px; }
h2 { font-weight: 500; font-size: clamp(30px, 4.2vw, 50px); line-height: 1.04; letter-spacing: -.035em; max-width: 18ch; }
.cols { display: grid; grid-template-columns: 5fr 6fr; gap: 72px; align-items: start; }
.cols > * { min-width: 0; }
.prose p + p { margin-top: 1em; }
.prose { color: var(--body); max-width: 54ch; }

.facts { display: grid; grid-template-columns: repeat(2, 1fr); margin-top: 72px; border: 1px solid var(--ink); background: var(--paper); }
.fact { padding: 28px; }
.fact + .fact { border-left: 1px solid var(--ink); }
.fact .n { font-size: clamp(56px, 8vw, 100px); font-weight: 500; letter-spacing: -.05em; line-height: 1; font-variant-numeric: tabular-nums; }
.fact .n small { font-size: .42em; letter-spacing: -.02em; margin-left: 4px; }
.fact p { margin-top: 14px; color: var(--body); max-width: 36ch; }
.fact .mono { color: var(--mute); display: block; margin-bottom: 18px; }

.table { margin-top: 56px; border: 1px solid var(--ink); background: var(--paper); }
.row { display: grid; grid-template-columns: 150px 80px 1fr 190px; gap: 20px; align-items: center; padding: 13px 16px; border-bottom: 1px solid var(--rule); }
.row:last-child { border-bottom: 0; }
.row.head { color: var(--mute); border-bottom: 1px solid var(--ink); }
.row .m { font-weight: 500; }
.bar { position: relative; height: 18px; }
.bar i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; transition: width 1.1s var(--ease); }
.bar i.chip { background: var(--ink); z-index: 1; }
.bar i.board { background: repeating-linear-gradient(-55deg, var(--ink) 0 1.5px, transparent 1.5px 6px); outline: 1px solid var(--ink); outline-offset: -1px; }
.row .v { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.key { display: flex; gap: 24px; margin-top: 16px; color: var(--mute); }
.key i { display: inline-block; width: 14px; height: 10px; margin-right: 8px; vertical-align: -1px; background: var(--ink); }
.key i.board { background: repeating-linear-gradient(-55deg, var(--ink) 0 1.5px, transparent 1.5px 6px); outline: 1px solid var(--ink); outline-offset: -1px; }
.note { margin-top: 22px; color: var(--mute); max-width: 72ch; font-size: 15px; }

/* charts */
.chart { margin: 56px 0 0; border: 1px solid var(--ink); background: var(--paper); }
.chart-bar { display: flex; justify-content: space-between; gap: 16px; padding: 10px 14px; color: var(--mute); flex-wrap: wrap; border-bottom: 1px solid var(--ink); }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; padding: 10px 8px 0; }
.chart figcaption { color: var(--mute); padding: 10px 14px 14px; max-width: 86ch; line-height: 1.6; }
.chart text { font-family: var(--mono); font-size: 12px; fill: var(--mute); }
.chart .lbl { fill: var(--ink); font-size: 12.5px; }
.toggle { display: inline-flex; border: 1px solid var(--ink); }
.toggle button { font: inherit; background: none; border: 0; padding: 3px 12px; cursor: pointer; color: var(--ink); }
.toggle button[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.dot { transition: transform .9s var(--ease); }
.col rect { transition: opacity .2s; }

/* method */
ol.steps { list-style: none; padding: 0; counter-reset: s; border: 1px solid var(--ink); background: var(--paper); }
ol.steps li { counter-increment: s; display: grid; grid-template-columns: 64px 1fr; padding: 18px 18px 18px 0; border-bottom: 1px solid var(--rule); }
ol.steps li:last-child { border-bottom: 0; }
ol.steps li::before { content: "S" counter(s); font-family: var(--mono); font-size: 12.5px; color: var(--mute); padding: 3px 0 0 18px; }
ol.steps b { font-weight: 600; }

.limits { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 56px; border: 1px solid var(--ink); background: var(--paper); }
.limits div { padding: 24px; }
.limits div + div { border-left: 1px solid var(--ink); }
.limits h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.limits p { color: var(--body); font-size: 15.5px; }

.cta { display: inline-flex; align-items: center; gap: 12px; margin-top: 32px; padding: 13px 18px; background: var(--ink); color: var(--paper); text-decoration: none; font-weight: 500; transition: gap .25s var(--ease); }
.cta:hover { gap: 18px; }
pre { margin-top: 24px; border: 1px solid var(--ink); background: var(--paper); padding: 18px 20px; font: 13.5px/1.7 var(--mono); overflow-x: auto; }
pre .c { color: var(--mute); }

/* title block, as on a drawing */
footer { padding: 40px 0 64px; }
.titleblock { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; border: 1.5px solid var(--ink); background: var(--paper); }
.titleblock > div { padding: 12px 14px; border-left: 1px solid var(--ink); }
.titleblock > div:first-child { border-left: 0; display: flex; gap: 14px; align-items: center; }
.titleblock .k { display: block; color: var(--mute); font-size: 10.5px; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 4px; }
.titleblock svg { height: 30px; width: auto; }

@media (max-width: 900px) {
  :root { --gutter: 0px; }
  #bus { display: none; }
  .hero-grid, .cols, .limits, .facts { grid-template-columns: 1fr; gap: 40px; }
  .limits, .facts { gap: 0; }
  .limits div + div, .fact + .fact { border-left: 0; border-top: 1px solid var(--ink); }
  .row { grid-template-columns: 1fr 64px 150px; }
  .row .bar { grid-column: 1 / -1; grid-row: 2; }
  .row.head .bar-h { display: none; }
  nav ul li:last-child { display: none; }
  nav ul { gap: 16px; }
  .brand span, .brand { font-size: 17px; }
  .theme { margin-left: 14px; }
  section { padding: 84px 0; }
  .wrap { padding: 0 16px; }
  .titleblock { grid-template-columns: 1fr 1fr; }
  .titleblock > div:nth-child(3) { border-left: 0; }
  .titleblock > div:nth-child(n+3) { border-top: 1px solid var(--ink); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* multi-page additions */
body[data-page="research"] [data-nav="research"],
body[data-page="tools"] [data-nav="tools"],
body[data-page="lab"] [data-nav="lab"] { color: var(--ink); text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; }

.page-head { padding: 88px 0 40px; }
.page-head h1 { font-weight: 500; font-size: clamp(38px, 5.6vw, 72px); line-height: 1; letter-spacing: -.04em; margin-top: 24px; max-width: 18ch; }
.page-head .lede { margin-top: 24px; max-width: 62ch; color: var(--body); font-size: 18.5px; }
.page-head .lede a { text-underline-offset: 3px; }
section.tight { padding: 64px 0; }

.areas { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 56px; border: 1px solid var(--ink); background: var(--paper); }
.area { display: block; padding: 26px; text-decoration: none; transition: background .25s; }
.area + .area { border-left: 1px solid var(--ink); }
a.area:hover { background: var(--hl); }
.area .mono { color: var(--mute); }
.area h3 { font-size: 21px; font-weight: 500; letter-spacing: -.02em; margin: 30px 0 10px; }
.area p { color: var(--body); font-size: 15.5px; }

.notes { display: grid; gap: 0; margin-top: 40px; border: 1px solid var(--ink); background: var(--paper); }
.note-card { display: grid; grid-template-columns: 180px 1fr auto; gap: 8px 28px; align-items: baseline; padding: 26px; text-decoration: none; border-top: 1px solid var(--rule); transition: background .25s; }
.note-card:first-child { border-top: 0; }
.note-card:hover { background: var(--hl); }
.note-card .mono { color: var(--mute); }
.note-card h3 { font-size: 24px; font-weight: 500; letter-spacing: -.025em; }
.note-card p { grid-column: 2; color: var(--body); max-width: 70ch; font-size: 15.5px; }
.note-card .go { grid-column: 3; grid-row: 1; color: var(--ink); white-space: nowrap; }

.facts { grid-template-columns: repeat(3, 1fr); }

.note-body { padding-top: 8px; padding-bottom: 80px; }
.note-body > * { max-width: 760px; }
.note-body > figure, .note-body > table { max-width: none; }
.note-body h2 { font-size: clamp(24px, 2.8vw, 32px); margin: 72px 0 18px; max-width: 30ch; }
.note-body h3 { font-size: 19px; font-weight: 600; margin: 32px 0 10px; }
.note-body p, .note-body li { color: var(--body); font-size: 17px; }
.note-body p + p { margin-top: 1em; }
.note-body ul, .note-body ol { padding-left: 1.2em; margin: 14px 0; }
.note-body li + li { margin-top: 6px; }
.note-body strong { color: var(--ink); font-weight: 600; }
.note-body code { font-family: var(--mono); font-size: .86em; background: var(--hl); padding: 1px 5px; }
.note-body pre code { background: none; padding: 0; }
.note-body table { width: 100%; border-collapse: collapse; margin: 26px 0; font-variant-numeric: tabular-nums; border: 1px solid var(--ink); background: var(--paper); font-size: 15px; }
.note-body th { text-align: left; font-family: var(--mono); font-size: 12px; font-weight: 500; color: var(--mute); border-bottom: 1px solid var(--ink); padding: 9px 12px; }
.note-body td { padding: 8px 12px; border-top: 1px solid var(--rule); }
.note-body th[style*="right"], .note-body td[style*="right"] { text-align: right; }
.note-body a { text-underline-offset: 3px; }
.note-body .chart { margin: 36px 0; }
.source { margin-top: 64px; padding-top: 18px; border-top: 1px solid var(--ink); color: var(--mute); }

@media (max-width: 900px) {
  .areas, .facts { grid-template-columns: 1fr; }
  .area + .area { border-left: 0; border-top: 1px solid var(--ink); }
  .note-card { grid-template-columns: 1fr; }
  .note-card p, .note-card .go { grid-column: 1; grid-row: auto; }
  .note-body table { display: block; overflow-x: auto; }
  .page-head { padding: 56px 0 24px; }
}
