/* Layout idea: a drafting sheet. One reading column for rules, wide grids for computed cross-sections. */
@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/figtree-latin-500-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/figtree-latin-600-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/figtree-latin-700-normal.woff2") format("woff2");
}
:root {
  --paper: #f3f5f7;
  --sheet: #ffffff;
  --ink: #17212b;
  --muted: #5b6875;
  --rule: #d5dbe1;
  --accent: #1d5fd1;
  --c-base: #aeb8c2;
  --c-spacer: #e3e7eb;
  --c-conv: #6f9be8;
  --c-floor: #cfd5db;
  --c-out: #f0a800;
  --ok: #1a7f4e;
  --warn: #b5560a;
  --plate: transparent;
  --page: 85rem;
  --col: 52rem;
  --step--2: 0.694rem;
  --step--1: 0.833rem;
  --step-0: 1rem;
  --step-1: 1.2rem;
  --step-2: 1.44rem;
  --step-3: 1.728rem;
  --step-4: 2.074rem;
  --step-5: 2.488rem;
  --step-6: 2.986rem;
  --step-7: 3.583rem;
  --sp-05: 0.25rem;
  --sp-1: 0.5rem;
  --sp-15: 0.75rem;
  --sp-2: 1rem;
  --sp-3: 1.5rem;
  --sp-4: 2.5rem;
  --sp-5: 4rem;
  --sp-6: 6rem;
  --gutter: 1.25rem;
  --gap: var(--sp-3);
  --gap-wide: var(--sp-4);
  --row: var(--sp-5);
  --lh-display: 1.05;
  --lh-heading: 1.2;
  --lh-compact: 1.45;
  --lh-body: 1.55;
  --lh-cjk: 1.8;
  --track-caps: 0.04em;
  --track-caps-lg: 0.02em;
  --track-display: 0.01em;
  --f-display: "Figtree", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --f-body: "IBM Plex Sans", "Segoe UI", system-ui, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #10161c;
    --sheet: #18212a;
    --ink: #e6ecf2;
    --muted: #97a4b1;
    --rule: #2c3945;
    --accent: #7fb0ff;
    --c-base: #5d6b79;
    --c-spacer: #2e3b47;
    --c-conv: #3f73cf;
    --c-floor: #3a4753;
    --c-out: #ffbf2e;
    --ok: #5fd39a;
    --warn: #f0a15a;
    --plate: #e4e9ee;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #10161c;
  --sheet: #18212a;
  --ink: #e6ecf2;
  --muted: #97a4b1;
  --rule: #2c3945;
  --accent: #7fb0ff;
  --c-base: #5d6b79;
  --c-spacer: #2e3b47;
  --c-conv: #3f73cf;
  --c-floor: #3a4753;
  --c-out: #ffbf2e;
  --ok: #5fd39a;
  --warn: #f0a15a;
  --plate: #e4e9ee;
  color-scheme: dark;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: var(--step-0);
  line-height: var(--lh-body);
  font-kerning: normal;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
a {
  color: var(--accent);
  text-decoration-thickness: 0.0625em;
  text-underline-offset: 0.2em;
}
strong,
b,
th {
  font-weight: 600;
}
p,
li,
dd,
td,
figcaption {
  text-wrap: pretty;
}
table,
dl,
.count,
.lab-result,
.solver ol {
  font-variant-numeric: lining-nums tabular-nums;
}
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.wrap {
  max-width: var(--page);
  margin: 0 auto;
  padding: 0 var(--gutter);
}
.site-head {
  padding: var(--sp-6) 0 var(--sp-4);
  text-align: center;
}
.site-head h1 {
  font-family: var(--f-display);
  font-weight: 600;
  color: var(--accent);
  font-size: clamp(var(--step-5), 6vw, var(--step-7));
  line-height: var(--lh-display);
  margin: 0 0 var(--sp-15);
  text-transform: uppercase;
  letter-spacing: var(--track-caps-lg);
}
.brand {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: var(--sp-15);
  margin: 0 0 var(--sp-15);
}
.brand h1 {
  margin: 0;
}
.logo {
  flex: none;
  width: clamp(48px, 9vw, 72px);
  height: auto;
}
.logo .l-a {
  fill: var(--accent);
}
.logo .l-b {
  fill: var(--c-out);
}
.tagline {
  margin: 0 auto var(--sp-2);
  font-size: var(--step-1);
  color: var(--muted);
}
.lede {
  max-width: var(--col);
  margin: 0 auto;
  color: var(--muted);
}
.lede strong {
  color: var(--ink);
  font-weight: 600;
}
.toc {
  position: sticky;
  top: 0;
  z-index: 5;
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}
.toc .wrap {
  position: relative;
  display: flex;
  align-items: center;
  gap: var(--gutter);
  min-height: 52px;
}
.toc-brand {
  display: inline-flex;
  align-items: center;
  flex: none;
}
.toc-brand .logo {
  width: 34px;
}
#toc-list {
  display: flex;
  flex: 1;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--sp-05) var(--sp-4);
  min-width: 0;
  list-style: none;
  margin: 0;
  padding: var(--sp-15) 0;
}
#toc-list a {
  font-family: var(--f-display);
  font-size: var(--step-0);
  font-weight: 600;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
  letter-spacing: var(--track-caps);
}
#toc-list a:hover,
#toc-list a[aria-current] {
  color: var(--accent);
}
.toc-toggle {
  display: inline-flex;
  align-items: center;
  margin: 0 calc(-1 * var(--sp-1)) 0 0;
  padding: var(--sp-1);
  background: none;
  color: var(--ink);
  border: 0;
  cursor: pointer;
}
html:has(.mega:not([hidden])) {
  overflow: hidden;
}
.mega {
  position: absolute;
  top: 100%;
  right: 0;
  left: 0;
  max-height: calc(100vh - 53px);
  max-height: calc(100dvh - 53px);
  overflow-y: auto;
  padding: var(--sp-4) 0 var(--sp-5);
  background: var(--paper);
  border-bottom: 1px solid var(--rule);
}
.mega .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: var(--sp-4) var(--sp-5);
  min-height: 0;
}
.mega section {
  flex: 1 1 12rem;
}
.mega section:first-child {
  flex: 6 1 36rem;
}
.mega h2 {
  margin: 0 0 var(--sp-2);
  font-size: var(--step-0);
  color: var(--accent);
}
.mega ol,
.mega ul {
  display: block;
  margin: 0;
  padding: 0;
  list-style: none;
}
.mega ol {
  columns: 14rem 3;
  column-gap: var(--sp-4);
}
.mega ol > li {
  break-inside: avoid;
  padding-bottom: var(--sp-2);
}
.mega a {
  display: block;
  padding: 0.2rem 0;
  font-family: var(--f-body);
  font-size: var(--step--1);
  font-weight: 400;
  letter-spacing: 0;
  text-transform: none;
  text-decoration: none;
  color: var(--muted);
}
.mega h2 a,
.mega ol > li > a,
.mega section:not(:first-child) li a {
  font-size: var(--step-0);
  font-weight: 600;
  color: var(--ink);
}
.mega h2 a {
  font-family: var(--f-display);
  color: var(--accent);
}
.mega a:hover,
.mega a:focus-visible,
.mega a[aria-current] {
  color: var(--accent);
}
.mega b {
  display: inline-block;
  min-width: 1.6em;
  font-weight: 600;
  color: var(--muted);
}
@media (max-width: 700px) {
  #toc-list {
    display: none;
  }
  .toc-toggle {
    margin-left: auto;
  }
}
.page-head {
  padding: var(--sp-6) 0 var(--sp-2);
}
.page-head + main > section > :first-child {
  margin-top: 0;
}
.page-head h1 {
  font-family: var(--f-display);
  font-weight: 600;
  color: var(--accent);
  font-size: clamp(var(--step-4), 4.5vw, var(--step-6));
  line-height: var(--lh-display);
  text-transform: uppercase;
  text-wrap: balance;
  max-width: var(--col);
  margin: 0 auto;
  letter-spacing: var(--track-caps-lg);
}
.jp-credit {
  max-width: var(--col);
  margin: var(--sp-3) auto 0;
  text-align: left;
}
.jp-credit p {
  margin: 0;
  max-width: none;
}
.jp-credit [lang="ja"] {
  font-size: var(--step-2);
  line-height: var(--lh-cjk);
  margin-bottom: var(--sp-2);
}
.jp-credit .en {
  color: var(--muted);
  margin-bottom: var(--sp-1);
}
.start {
  margin: var(--sp-2) auto 0;
  font-size: var(--step-1);
}
.index {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  list-style: none;
  padding: 0;
  margin: var(--sp-4) 0;
  gap: var(--gap);
}
.index a {
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  height: 100%;
  padding: var(--sp-15);
  background: var(--sheet);
  border: 1px solid var(--rule);
  color: var(--ink);
  text-decoration: none;
  font-size: var(--step--1);
  line-height: var(--lh-compact);
}
.index a:hover {
  border-color: var(--accent);
}
.pic {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 130px;
  background: var(--paper);
}
.pic img.iso {
  max-height: 110px;
  width: auto;
}
.index strong {
  font-family: var(--f-display);
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  color: var(--accent);
  font-size: var(--step-2);
}
.index span {
  color: var(--muted);
}
main section {
  padding: var(--sp-3) 0 var(--sp-5);
}
h2 {
  font-family: var(--f-display);
  font-weight: 600;
  color: var(--accent);
  text-wrap: balance;
  letter-spacing: var(--track-display);
  font-size: var(--step-4);
  line-height: var(--lh-heading);
  margin: var(--sp-6) 0 var(--sp-3);
}
h3 {
  font-family: var(--f-display);
  font-weight: 600;
  text-wrap: balance;
  letter-spacing: var(--track-display);
  line-height: var(--lh-heading);
  font-size: var(--step-3);
  margin: var(--sp-5) 0 var(--sp-2);
}
h4 {
  font-size: var(--step--1);
  font-weight: 600;
  line-height: var(--lh-heading);
  margin: 0;
}
p,
.prose li {
  max-width: 68ch;
}
.prose > p {
  margin-top: var(--sp-3);
  margin-bottom: var(--sp-3);
}
.lead {
  color: var(--accent);
  font-size: var(--step-1);
  line-height: var(--lh-compact);
}
.prose ul:not([class]) {
  padding-left: 1.1em;
}
.prose > h2,
.prose > h3,
.prose > p,
.prose > .eq,
.prose > .eq-where,
.prose > .duo,
.prose > .eqs,
.prose > .credit,
.prose > .solver,
.prose > .lab,
.prose > .thread,
.prose > .tools,
.prose > .words,
.prose > .key,
.prose > .bridge,
.prose > .legend,
.prose > .filters,
.prose > .figs,
.prose > .tablewrap,
.prose > .src,
.prose > .index,
.prose > .pit,
.prose > .fam,
.prose > .grid,
.prose > ul:not([class]) {
  max-width: var(--col);
  margin-left: auto;
  margin-right: auto;
}
.eq {
  margin: var(--sp-4) 0;
  text-align: center;
}
math {
  color: var(--accent);
}
thead th.n {
  font-family: var(--f-display);
}
.eq math {
  font-size: var(--step-2);
}
@media (max-width: 520px) {
  .eq math {
    font-size: var(--step-0);
  }
}
.duo,
.eqs {
  display: grid;
  gap: var(--gap-wide);
  margin-top: var(--sp-4);
  margin-bottom: var(--sp-4);
}
.duo {
  align-items: start;
  grid-template-columns: 2fr 1fr;
}
.eqs {
  grid-template-columns: repeat(3, 1fr);
}
.eqs.two {
  grid-template-columns: repeat(2, 1fr);
}
.duo .tablewrap {
  margin: 0;
}
.duo table {
  min-width: 0;
}
.duo .tfig,
.eqs .tfig {
  max-width: none;
  align-items: center;
  justify-content: space-between;
}
.duo .tfig svg.sec {
  width: 100%;
  max-width: 18rem;
}
.eqs .eq {
  margin: 0;
}
.eqs {
  container-type: inline-size;
}
.eqs .eq math {
  font-size: min(var(--step-1), 2.1cqi);
}
.eqs figcaption {
  text-align: center;
}
.eqs .tfig {
  display: grid;
  grid-row: span 3;
  grid-template-rows: subgrid;
  justify-items: center;
  gap: var(--sp-2);
}
.eqs .eq {
  align-self: end;
  height: 2rem;
}
.eqs figcaption {
  align-self: start;
}
@media (max-width: 760px) {
  .figs,
  .figs:has(> :nth-child(3):last-child) {
    grid-template-columns: 1fr;
  }
  .duo,
  .eqs,
  .eqs.two {
    grid-template-columns: 1fr;
  }
  .eqs .eq math {
    font-size: var(--step-1);
  }
}
.eq-where {
  color: var(--muted);
  font-size: var(--step--1);
  text-align: center;
  line-height: var(--lh-compact);
}
code,
.n,
small {
  font-family: var(--f-mono);
  font-variant-numeric: tabular-nums;
}
code {
  font-size: inherit;
}
small {
  color: var(--muted);
  font-size: var(--step--2);
}
.tablewrap {
  overflow-x: auto;
  margin: var(--sp-4) 0;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: var(--step--1);
  min-width: 520px;
  line-height: var(--lh-compact);
}
caption {
  caption-side: top;
  text-align: left;
  color: var(--muted);
  font-size: var(--step--1);
  padding: 0 0 var(--sp-1);
  line-height: var(--lh-compact);
}
th,
td {
  padding: var(--sp-15) var(--sp-3) var(--sp-15) 0;
  text-align: left;
  vertical-align: middle;
}
th:last-child,
td:last-child {
  padding-right: 0;
}
thead th {
  font-family: var(--f-display);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: var(--track-caps);
  font-size: var(--step--1);
  color: var(--muted);
  vertical-align: bottom;
}
td.n,
th.n {
  text-align: right;
}
tbody th {
  white-space: nowrap;
  font-family: var(--f-mono);
  font-weight: 500;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  margin: var(--sp-4) 0;
  gap: var(--row) var(--gap-wide);
}
.card {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}
.card[hidden] {
  display: none;
}
.card header {
  display: flex;
  gap: var(--sp-1);
  align-items: baseline;
}
.id {
  font-family: var(--f-mono);
  font-size: var(--step--2);
  color: var(--accent);
  white-space: nowrap;
}
.card figure,
.tfig {
  margin: 0;
}
.card figure,
.plate {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow-x: auto;
}
.plate {
  align-self: stretch;
  max-width: 100%;
}
.tfig {
  flex: 0 1 24rem;
  flex-direction: column;
  gap: var(--sp-2);
  align-items: flex-start;
  display: flex;
  min-width: 0;
  max-width: 100%;
}
.tfig figcaption {
  font-size: var(--step--1);
  color: var(--muted);
  max-width: 46ch;
  line-height: var(--lh-compact);
  align-self: center;
  text-align: center;
  text-wrap: balance;
}
.figs > .tfig:has(> figcaption:nth-child(2)) {
  display: grid;
  grid-row: span 2;
  grid-template-rows: subgrid;
  justify-items: center;
  row-gap: var(--sp-2);
}
.figs > .tfig:has(> figcaption:nth-child(2)) > :first-child {
  align-self: center;
}
.figs > .tfig:has(> figcaption:nth-child(2)) > figcaption {
  align-self: start;
}
.figs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: stretch;
  margin: var(--sp-4) 0;
  gap: var(--row) var(--gap-wide);
}
.figs .plate {
  flex: 1 1 auto;
}
.figs:has(> :nth-child(3):last-child) {
  grid-template-columns: repeat(3, 1fr);
}
svg.sec {
  max-width: 100%;
  height: auto;
  flex: none;
}
.pair,
#chains figure {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-15);
  align-items: center;
  justify-items: center;
  width: 100%;
}
.pair {
  gap: var(--gap);
}
.pair svg.sec,
#chains figure svg.sec {
  max-height: 190px;
  width: auto;
}
img.iso {
  max-width: 100%;
  height: auto;
  background: var(--plate);
}
.pair img.iso,
#chains figure img.iso {
  max-height: 190px;
  width: auto;
}
.stack {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: var(--gap);
  width: 100%;
}
.stack svg.sec,
.stack img.iso {
  flex: 0 1 auto;
  max-width: 100%;
  height: auto;
}
.tps {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  margin-right: var(--sp-1);
  vertical-align: middle;
}
th .tps,
td .tps {
  justify-content: center;
  min-width: 6.5rem;
}
th:has(> .tps),
td:has(> .tps),
td.nw {
  white-space: nowrap;
}
img.tp {
  max-height: 2.5rem;
  width: auto;
}
td.th {
  padding: var(--sp-05) var(--sp-1);
  text-align: center;
  vertical-align: middle;
}
td.th svg.sec {
  display: block;
  max-height: 4.5rem;
  width: auto;
  margin: 0 auto;
}
td.th img.iso {
  display: block;
  max-height: 60px;
  width: auto;
  margin: 0 auto;
}
.iso path {
  stroke: var(--ink);
  stroke-width: 0.9;
  stroke-linejoin: round;
}
.iso .ft,
.iso .fc {
  filter: brightness(1.12);
}
.iso .fr,
.iso .fs {
  filter: brightness(0.82);
}
.sec .d.ld {
  stroke: var(--muted);
  stroke-width: 0.4;
}
.sec .x {
  fill: var(--warn);
  fill-opacity: 0.6;
  stroke: var(--warn);
  stroke-width: 0.8;
}
.sec .t {
  font-family: var(--f-mono);
  font-size: 5px;
  fill: var(--muted);
}
.sec .b,
.sec .st {
  stroke: var(--ink);
  stroke-width: 0.6;
  stroke-linejoin: round;
}
.sec .r-base {
  fill: var(--c-base);
}
.sec .r-spacer {
  fill: var(--c-spacer);
}
.sec .r-conv {
  fill: var(--c-conv);
}
.sec .r-floor {
  fill: var(--c-floor);
}
.sec .r-out {
  fill: var(--c-out);
}
.sec .r-ghost,
.sec .gh {
  fill: none;
  stroke: var(--muted);
  stroke-width: 0.6;
  stroke-dasharray: 2 1.5;
}
.sec .g {
  stroke: var(--muted);
  stroke-width: 0.35;
  stroke-dasharray: 1.6 1.6;
  opacity: 0.7;
}
.sec .d {
  stroke: var(--accent);
  stroke-width: 1.4;
}
.sec .dq {
  stroke: var(--c-out);
  stroke-width: 1.6;
}
.sec .arm {
  stroke: var(--ink);
  stroke-width: 2;
}
.sec .pv {
  fill: var(--c-out);
  stroke: var(--ink);
  stroke-width: 0.6;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1);
  list-style: none;
  margin: 0;
  padding: 0;
}
.chip {
  font-family: var(--f-mono);
  font-size: var(--step--2);
  color: var(--muted);
}
.chip:not(:last-child)::after {
  content: "·";
  margin-left: var(--sp-1);
  color: var(--muted);
}
.chip.on {
  color: var(--ok);
}
.chip.half {
  color: var(--warn);
}
.chip.dir {
  color: var(--ink);
}
dl {
  margin: 0;
  display: grid;
  gap: var(--sp-05);
  font-size: var(--step--1);
  line-height: var(--lh-compact);
}
dl div {
  display: grid;
  grid-template-columns: 5.2em 1fr;
  gap: var(--sp-1);
}
.card.part dl div {
  grid-template-columns: 7.5em 1fr;
}
dt {
  color: var(--muted);
}
dd {
  margin: 0;
}
.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  margin: var(--sp-5) 0 var(--sp-4);
  gap: var(--gap);
}
.filters fieldset {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1);
  border: 0;
  margin: 0;
  padding: 0;
}
.filters legend {
  width: 100%;
  padding: 0;
  margin-bottom: var(--sp-1);
  font-family: var(--f-display);
  font-size: var(--step--1);
  font-weight: 600;
  letter-spacing: var(--track-caps);
  text-transform: uppercase;
  color: var(--muted);
}
.filters button {
  display: grid;
  grid-template-rows: 2.5rem auto;
  justify-items: center;
  align-items: center;
  gap: var(--sp-05);
  min-width: 4.5rem;
  padding: var(--sp-1);
  background: var(--sheet);
  border: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: var(--step--2);
  line-height: var(--lh-heading);
  color: var(--muted);
  cursor: pointer;
}
.filters button img.tp {
  max-height: 2.5rem;
  width: auto;
}
.sym {
  font-family: var(--f-display);
  font-size: var(--step-3);
  font-weight: 600;
  line-height: 1;
  color: var(--ink);
}
.sym.ok {
  color: var(--ok);
}
.sym.warn {
  color: var(--warn);
}
.filters button:hover {
  border-color: var(--accent);
}
.filters button[aria-pressed="true"] {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
  color: var(--accent);
}
.filters .count {
  flex-basis: 100%;
}
.count {
  font-family: var(--f-mono);
  font-size: var(--step--1);
  color: var(--muted);
}
.legend {
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: var(--sp-1) var(--sp-2);
  list-style: none;
  padding: 0;
  margin: var(--sp-3) 0;
  font-size: var(--step--1);
  color: var(--muted);
  line-height: var(--lh-compact);
}
.legend i {
  display: inline-block;
  width: 12px;
  height: 12px;
  border: 1px solid var(--ink);
  vertical-align: -2px;
  margin-right: var(--sp-05);
}
.solver .lab-stage {
  margin-top: var(--sp-15);
}
.solver {
  background: var(--sheet);
  border: 1px solid var(--rule);
  padding: var(--sp-2);
}
.solver ol {
  font-family: var(--f-mono);
  font-size: var(--step--1);
  padding-left: 1.6em;
  margin: var(--sp-15) 0 0;
}
.pit {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 0;
  margin: var(--sp-4) 0;
  list-style: none;
  gap: var(--row) var(--gap-wide);
}
.pit li {
  font-size: var(--step--1);
  line-height: var(--lh-compact);
}
.pit strong {
  display: block;
  margin-bottom: var(--sp-05);
  font-family: var(--f-display);
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  font-size: var(--step-2);
}
.pn {
  display: block;
  margin-bottom: var(--sp-05);
  font-family: var(--f-mono);
  font-size: var(--step--2);
  color: var(--accent);
}
.pitfig {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  height: 150px;
  margin-bottom: var(--sp-2);
  justify-content: flex-start;
}
.pitfig img.iso {
  max-height: 130px;
  min-width: 0;
  width: auto;
}
.fam {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  padding: 0;
  margin: var(--sp-4) 0;
  list-style: none;
  gap: var(--row) var(--gap-wide);
}
.fam li {
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
  font-size: var(--step--1);
  line-height: var(--lh-compact);
}
.parts .used {
  color: var(--muted);
}
.index .num {
  margin-right: var(--sp-1);
  color: var(--muted);
  font-weight: 500;
}
.people {
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
  max-width: var(--col);
  margin: var(--sp-4) auto var(--sp-6);
  padding: 0;
  list-style: none;
}
.people > li {
  display: grid;
  grid-template-columns: 2fr 3fr;
  gap: var(--sp-1) var(--gap-wide);
  align-items: start;
}
.people .who strong {
  display: block;
  font-family: var(--f-display);
  font-weight: 600;
  font-size: var(--step-4);
  line-height: var(--lh-display);
  text-wrap: balance;
}
.people .who span {
  display: block;
  margin-top: var(--sp-1);
  font-size: var(--step-1);
  color: var(--muted);
}
.people .what > * {
  margin: 0 0 var(--sp-15);
  max-width: none;
}
.people .what > :last-child {
  margin-bottom: 0;
}
.people .what [lang="ja"] {
  font-size: var(--step-1);
  line-height: var(--lh-cjk);
}
.people .what ul {
  padding-left: 1.2em;
}
.note {
  font-size: var(--step--1);
  line-height: var(--lh-compact);
  color: var(--muted);
}
.thanks {
  gap: var(--sp-3);
}
.thanks .who strong {
  font-size: var(--step-2);
  line-height: var(--lh-heading);
}
.thanks .what {
  color: var(--muted);
}
@media (max-width: 760px) {
  .people > li {
    grid-template-columns: 1fr;
  }
}
.parts {
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
}
.parts strong {
  font-size: var(--step-1);
}
.fam strong {
  display: block;
  font-family: var(--f-display);
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  font-size: var(--step-2);
}
.m-ok {
  color: var(--ok);
}
.m-part {
  color: var(--warn);
}
.m-no {
  color: var(--muted);
}
.lab {
  background: var(--sheet);
  border: 1px solid var(--rule);
  padding: var(--sp-3);
  margin: var(--sp-4) 0;
}
.lab-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-15) var(--gap);
}
.stepper {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
}
#angle-tool .stepper {
  flex-wrap: wrap;
}
#angle-tool .stepper span {
  flex: 1 0 100%;
}
#angle-stage svg {
  width: auto;
  max-width: 100%;
  height: 14rem;
}
#angle-stage .t {
  font-size: 13px;
}
.stepper span {
  min-width: 6.5em;
}
.stepper output {
  font-family: var(--f-mono);
  min-width: 1.6em;
  text-align: center;
}
.solver .stepper output {
  min-width: 5.5em;
}
.lab button,
.solver button {
  font: inherit;
  font-size: var(--step--1);
  background: var(--paper);
  color: var(--ink);
  border: 1px solid var(--rule);
  padding: var(--sp-05) var(--sp-15);
  cursor: pointer;
}
.stepper button {
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  font-family: var(--f-mono);
  font-size: var(--step-1);
  touch-action: manipulation;
}
.lab-presets {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1);
  align-items: center;
  justify-content: space-between;
  margin-top: var(--sp-15);
  font-size: var(--step--1);
  color: var(--muted);
}
.lab-stage {
  overflow-x: auto;
  margin-top: var(--sp-15);
}
.lab-stage svg {
  display: block;
  width: 100%;
  min-width: 360px;
  height: auto;
}
.lab .lab-stage svg {
  margin-inline: auto;
}
.lab-stage text {
  font-family: var(--f-mono);
  font-size: 5px;
  fill: var(--muted);
}
.lab-stage .k-brick {
  fill: var(--c-base);
}
.lab-stage .k-plate {
  fill: var(--c-spacer);
}
.lab-stage .k-half {
  fill: var(--c-conv);
}
.lab-stage .k-quarter {
  fill: var(--c-out);
}
.lab-stage .k-col {
  fill: var(--c-floor);
}
.lab-stage .k-rest {
  fill: var(--warn);
  fill-opacity: 0.35;
  stroke: var(--warn);
}
.lab-stage rect {
  stroke: var(--ink);
  stroke-width: 0.5;
}
.lab-stage line {
  stroke: var(--muted);
  stroke-width: 0.35;
  stroke-dasharray: 1.6 1.6;
}
.lab-result {
  font-family: var(--f-mono);
  font-size: var(--step--1);
  margin: var(--sp-15) 0 0;
  max-width: none;
}
.lab-result.hit {
  color: var(--ok);
}
.lab-result.miss {
  color: var(--warn);
}
.credit {
  background: var(--sheet);
  border-left: 3px solid var(--accent);
  padding: var(--sp-15) var(--sp-15);
  max-width: 68ch;
}
.credit p {
  margin: 0 0 var(--sp-1);
}
.credit + .credit {
  margin-top: var(--sp-2);
}
.credit p:last-child {
  margin: 0;
}
.src li {
  margin-bottom: var(--sp-1);
}
.pager {
  display: grid;
  grid-template-columns: 1fr 1fr;
  max-width: calc(var(--col) + 2 * var(--gutter));
  margin-top: var(--sp-6);
  gap: var(--gap);
}
.pager a {
  display: block;
  padding: var(--sp-3);
  background: var(--sheet);
  border: 1px solid var(--rule);
  color: var(--ink);
  text-decoration: none;
}
.pager a:hover,
.pager a:focus-visible {
  border-color: var(--accent);
}
.pager-next {
  grid-column: 2;
  text-align: right;
}
.pager span,
.pager em {
  display: block;
  font-size: var(--step--1);
  font-style: normal;
  color: var(--muted);
  line-height: var(--lh-compact);
}
.pager strong {
  display: block;
  color: var(--accent);
  font-family: var(--f-display);
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  font-size: var(--step-2);
}
.crumb {
  max-width: var(--col);
  margin: 0 auto var(--sp-1);
  font-family: var(--f-display);
  font-size: var(--step-0);
  font-weight: 600;
  letter-spacing: var(--track-caps);
  text-transform: uppercase;
}
.crumb a {
  margin-right: 0.4em;
  text-decoration: none;
}
.crumb a::after,
.crumb span:not(:last-child)::after {
  content: " /";
  color: var(--muted);
}
.crumb span {
  margin-right: 0.4em;
  color: var(--muted);
}
.tfig > .eq {
  align-self: center;
}
.concept {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  max-width: var(--col);
  margin: var(--row) auto;
  gap: var(--gap-wide);
}
.concept .plate {
  justify-content: center;
}
.concept > div > :first-child {
  margin-top: 0;
}
.concept h3 {
  margin: 0 0 var(--sp-2);
}
.concept .tfig {
  max-width: none;
}
.ask {
  max-width: var(--col);
  margin: var(--sp-1) auto 0;
  font-size: var(--step-2);
  line-height: var(--lh-heading);
  color: var(--muted);
}
.tools {
  margin-top: var(--sp-2);
  display: flex;
  gap: var(--sp-2);
  align-items: center;
  font-size: var(--step--1);
}
.tools button {
  padding: var(--sp-05) var(--sp-15);
  background: var(--sheet);
  border: 1px solid var(--rule);
  font: inherit;
  color: var(--ink);
  cursor: pointer;
}
.tools button,
.tools a,
.lab-presets button {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  touch-action: manipulation;
}
.tools button:hover {
  border-color: var(--accent);
}
:fullscreen {
  padding: var(--sp-4);
  background: var(--paper);
  overflow: auto;
}
.words {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1) var(--sp-2);
  list-style: none;
  padding: 0;
}
.gloss {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  max-width: var(--col);
  margin: var(--sp-4) auto;
  gap: var(--row) var(--gap-wide);
}
.gloss > div {
  display: block;
}
.gloss dt {
  color: var(--ink);
  font-family: var(--f-display);
  font-weight: 600;
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  margin: var(--sp-1) 0 var(--sp-05);
  font-size: var(--step-2);
}
.gloss dd {
  margin: 0;
  font-size: var(--step-0);
}
.gloss .pic {
  height: 200px;
  background: none;
  justify-content: center;
  align-items: center;
}
.gloss .pic img,
.gloss .pic svg {
  min-width: 0;
  max-width: 50%;
  max-height: 200px;
  width: auto;
  height: auto;
}
.gloss .pic > :only-child {
  max-width: 100%;
}
.gloss .pic img {
  object-fit: contain;
  object-position: center;
}
.lessons {
  list-style: none;
  counter-reset: step;
  padding: 0;
}
@media (max-width: 760px) {
  .concept,
  .gloss {
    grid-template-columns: 1fr;
  }
}
.thread img {
  flex: none;
  width: 5rem;
  height: 4rem;
  object-fit: contain;
}
.hero-pic {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  gap: var(--gap-wide);
  margin: 0 auto var(--sp-4);
}
.hero-pic img {
  height: auto;
  max-width: 100%;
}
@media (max-width: 900px) {
  .hero-pic .side {
    display: none;
  }
}
.key {
  padding-left: var(--sp-2);
  border-left: 3px solid var(--accent);
  font-size: var(--step-1);
  font-weight: 500;
  line-height: var(--lh-compact);
}
.prose > .key {
  margin-top: var(--sp-4);
  margin-bottom: var(--sp-4);
}
.prose > .bridge {
  color: var(--muted);
  margin-top: var(--sp-6);
}
.thread {
  list-style: none;
  counter-reset: step;
  padding: 0;
  margin: var(--sp-3) auto var(--sp-5);
}
.thread[start="0"] {
  counter-reset: step -1;
}
.thread li {
  counter-increment: step;
  display: grid;
  align-items: baseline;
  max-width: none;
  padding: var(--sp-2) 0;
  grid-template-columns: 1fr 2fr;
  gap: var(--sp-05) var(--gap);
}
.thread a {
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-family: var(--f-display);
  font-weight: 600;
  line-height: var(--lh-heading);
  letter-spacing: var(--track-display);
  font-size: var(--step-2);
}
.thread a::before {
  content: counter(step);
  display: inline-block;
  min-width: 2rem;
  color: var(--muted);
}
@media (max-width: 520px) {
  .thread li {
    grid-template-columns: 1fr;
  }
  .thread span {
    padding-left: 2rem;
  }
}
footer {
  margin-top: var(--sp-6);
  padding: var(--sp-5) 0;
  color: var(--muted);
  font-size: var(--step--1);
  line-height: var(--lh-compact);
}
footer p {
  max-width: none;
  margin: 0 0 var(--sp-1);
}
.foot-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2) var(--sp-4);
  margin-bottom: var(--sp-3);
}
.foot-top ul {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1) var(--sp-3);
  margin: 0;
  padding: 0;
  list-style: none;
}
.foot-top a {
  color: var(--ink);
  text-decoration: none;
}
.foot-top a:hover,
.foot-top a:focus-visible {
  color: var(--accent);
}
.foot-brand .logo {
  width: 1.75rem;
  height: 1.75rem;
}
.foot-brand {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  font-family: var(--f-display);
  font-weight: 600;
  font-size: var(--step-0);
}
.grid.cat {
  grid-template-columns: repeat(2, 1fr);
}
@media (max-width: 760px) {
  .index,
  .pit,
  .fam,
  .grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid.cat {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 520px) {
  .index,
  .pit,
  .fam,
  .grid {
    grid-template-columns: 1fr;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
