@font-face { font-family: "Geist"; src: url("/fonts/Geist-Variable.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
/* Draft of a subinternal research post, in the dress of the Harness² post beside it. */
@font-face { font-family: "Geist Mono"; src: url("/fonts/GeistMono-Variable.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
:root {
  --paper: #E9E7E2; --card: #F4F3EF; --ink: #141518; --ink-2: #44464d; --muted: #5f6168;
  --line: rgb(20 21 24 / 0.1); --line-2: rgb(20 21 24 / 0.18);
  --graphite: #2b2b2e; --on-dark: #F2F1EE; --on-dark-2: rgb(242 241 238 / 0.62); --dark-line: rgb(242 241 238 / 0.13);
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
}
* { box-sizing: border-box; }
html { background: var(--paper); scroll-padding-top: 88px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.7 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
/* mttr's control principle: a fill, a hairline, a short soft shadow. The one main action is graphite, not black. */
.btn { display: inline-flex; align-items: center; height: 40px; padding: 0 16px; border: 0; border-radius: 12px; background: linear-gradient(#3a3a3c, #232324); color: #fff !important; font: 500 14.5px/1 var(--sans); text-decoration: none; white-space: nowrap; box-shadow: 0 1px 2px rgb(0 0 0 / 0.3), 0 6px 14px -6px rgb(0 0 0 / 0.35), inset 0 1px 0 rgb(255 255 255 / 0.16); transition: filter 140ms ease; }
.btn:hover { filter: brightness(1.15); }
.btn:active { transform: translateY(0.5px); }
.news { display: flex; justify-content: center; align-items: center; gap: 12px; margin: 0; padding: 9px 16px; background: var(--graphite); color: var(--on-dark-2); font: 400 13.5px/1.4 var(--sans); }
.news a { display: inline-flex; align-items: center; gap: 12px; color: var(--on-dark); text-decoration: none; }
.news a:hover span { text-decoration: underline; text-underline-offset: 3px; }
.news i { padding: 2px 8px; border-radius: 6px; background: linear-gradient(#ffffff, #e9e9ea); color: #232324; font: 500 11.5px/1.5 var(--sans); font-style: normal; box-shadow: 0 1px 2px rgb(0 0 0 / 0.3), inset 0 -1px 0 rgb(0 0 0 / 0.08); }
.news em { color: var(--on-dark-2); font-style: normal; }
.site { position: sticky; top: 0; z-index: 10; background: rgb(233 231 226 / 0.86); -webkit-backdrop-filter: saturate(1.4) blur(14px); backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid var(--line); }
.site-in { display: flex; align-items: center; gap: 40px; max-width: 1240px; height: 64px; margin: 0 auto; padding: 0 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; font-size: 16px; letter-spacing: -0.01em; text-decoration: none; }
.brand svg { width: 26px; height: 26px; }
.brand .tile { fill: var(--ink); } .brand .mark { fill: var(--paper); }
.site nav { display: flex; gap: 28px; font-size: 14.5px; }
.site nav a { color: var(--ink-2); text-decoration: none; }
.site nav a:hover, .site nav a[aria-current] { color: var(--ink); }
.site-end { margin-left: auto; }

.head { max-width: 1240px; margin: 0 auto; padding: 88px 24px 56px; }
.kicker { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0 0 28px; color: var(--muted); font: 13px/1.4 var(--mono); }
.kicker a { color: var(--ink); text-decoration: none; }
h1 { margin: 0; font-size: clamp(36px, 5.4vw, 68px); text-wrap: balance; font-weight: 500; line-height: 1.02; letter-spacing: -0.035em; }
.dek { max-width: 58ch; text-wrap: pretty; margin: 28px 0 0; color: var(--ink-2); font-size: 21px; line-height: 1.5; letter-spacing: -0.01em; }

/* The matrix: five scenarios against the three things that decide fit. */
.matrix-wrap { max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.matrix { overflow-x: auto; border-radius: 20px; background: var(--graphite); color: var(--on-dark); }
.matrix table { width: 100%; min-width: 900px; table-layout: fixed; border-collapse: collapse; font-size: 14.5px; }
.matrix col.name { width: 22%; }
.matrix th, .matrix td { padding: 18px 20px; border-bottom: 1px solid var(--dark-line); text-align: left; vertical-align: top; }
.matrix tr:last-child td, .matrix tr:last-child th { border-bottom: 0; }
.matrix thead th { padding-top: 20px; padding-bottom: 14px; color: var(--on-dark-2); font: 400 12px/1.4 var(--mono); }
.matrix tbody th { font-weight: 500; font-size: 15.5px; }
.matrix tbody th a { color: var(--on-dark); text-decoration: none; }
.matrix tbody th a:hover { text-decoration: underline; text-underline-offset: 3px; }
.matrix tbody th small { display: block; margin-bottom: 4px; color: var(--on-dark-2); font: 400 12px/1.4 var(--mono); }
.matrix td { color: var(--on-dark-2); }
.matrix td b { display: block; margin-bottom: 2px; color: var(--on-dark); font-weight: 500; }
.level { display: inline-flex; align-items: center; height: 22px; margin-bottom: 8px; padding: 0 9px; border-radius: 7px; font: 500 12px/1 var(--sans); }
.l3 { background: linear-gradient(#ffffff, #e9e9ea); color: #232324; box-shadow: 0 1px 2px rgb(0 0 0 / 0.35), inset 0 -1px 0 rgb(0 0 0 / 0.08); }
.l2 { border: 1px solid rgb(255 255 255 / 0.14); background: rgb(255 255 255 / 0.08); color: var(--on-dark); box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.08), 0 1px 2px rgb(0 0 0 / 0.25); }
.l1 { border: 1px solid rgb(255 255 255 / 0.16); color: var(--on-dark-2); }
figcaption { margin: 14px 0 0; color: var(--muted); font-size: 14px; line-height: 1.55; }
figcaption b { color: var(--ink); font-weight: 600; }

.body { display: grid; grid-template-columns: 220px minmax(0, 720px); justify-content: center; gap: 72px; max-width: 1240px; margin: 0 auto; padding: 72px 24px 40px; }
.toc { position: sticky; top: 96px; align-self: start; font-size: 13.5px; }
.toc b { display: block; margin-bottom: 12px; font-weight: 500; }
.toc ol { margin: 0; padding: 0; list-style: none; border-left: 1px solid var(--line-2); }
.toc li a { display: block; margin-left: -1px; padding: 5px 0 5px 14px; border-left: 1px solid transparent; color: var(--muted); text-decoration: none; }
.toc li a:hover { color: var(--ink); border-color: var(--ink); }
.byline { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; line-height: 1.6; }
.byline b { display: block; color: var(--ink); font-weight: 500; }
.byline a { color: var(--ink); }

article > :first-child { margin-top: 0; }
article h2 { margin: 72px 0 16px; font-size: 28px; font-weight: 500; line-height: 1.2; letter-spacing: -0.02em; }
article p { margin: 0 0 18px; color: var(--ink-2); }
article p b { color: var(--ink); font-weight: 600; }
article code { padding: 1px 6px; border-radius: 6px; background: rgb(20 21 24 / 0.06); font: 0.84em var(--mono); white-space: nowrap; }
.callout { box-shadow: 0 1px 2px rgb(0 0 0 / 0.04); margin: 0 0 8px; padding: 20px 22px; border-left: 2px solid var(--ink); background: var(--card); border-radius: 0 12px 12px 0; color: var(--ink-2); font-size: 15.5px; }
.callout b { color: var(--ink); }

/* One scenario */
.case { margin-top: 72px; scroll-margin-top: 88px; }
.case-head { display: flex; align-items: baseline; gap: 16px; margin: 0 0 14px; }
.case-head span { color: var(--muted); font: 13px var(--mono); }
.case-head h2 { margin: 0; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; margin: 24px 0; overflow: hidden; border: 1px solid var(--line-2); border-radius: 14px; background: var(--line-2); box-shadow: 0 1px 2px rgb(0 0 0 / 0.05); }
.facts div { padding: 16px 18px; background: var(--card); font-size: 14.5px; line-height: 1.55; color: var(--ink-2); }
.facts small { display: block; margin-bottom: 6px; color: var(--muted); font: 12px var(--mono); }
.code { margin: 24px 0; overflow: hidden; border-radius: 14px; background: var(--graphite); color: var(--on-dark); }
.code > span { display: flex; justify-content: space-between; gap: 12px; padding: 10px 18px; border-bottom: 1px solid var(--dark-line); color: var(--on-dark-2); font: 12px var(--mono); }
.code pre { margin: 0; padding: 18px; overflow-x: auto; font: 13.5px/1.7 var(--mono); white-space: pre-wrap; }
.code .k { color: #9fd8b5; }
.watch { display: grid; grid-template-columns: 96px 1fr; gap: 16px; margin: 0; padding: 16px 0 0; border-top: 1px solid var(--line); font-size: 15.5px; color: var(--ink-2); }
.watch b { color: var(--ink); font-weight: 600; font-size: 14px; }

.qs { margin: 24px 0 0; padding: 0; list-style: none; counter-reset: q; }
.qs li { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 18px 0; border-top: 1px solid var(--line); counter-increment: q; color: var(--ink-2); }
.qs li::before { content: counter(q); display: grid; place-items: center; width: 26px; height: 26px; border-radius: 8px; background: var(--ink); color: var(--paper); font: 500 12px/1 var(--mono); }
.qs b { display: block; color: var(--ink); font-weight: 600; }


@media (max-width: 1100px) { .body { grid-template-columns: minmax(0, 720px); gap: 0; } .toc { display: none; } }
@media (max-width: 640px) {
  .news em { display: none; }
  .news span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .news a { min-width: 0; }
  /* The matrix as one block a scenario, each answer under the question it answers. */
  .matrix table, .matrix tbody, .matrix tr, .matrix th, .matrix td { display: block; width: auto; min-width: 0; }
  .matrix thead, .matrix colgroup { display: none; }
  .matrix tr { padding: 18px 18px 6px; border-bottom: 1px solid var(--dark-line); }
  .matrix tr:last-child { border-bottom: 0; }
  .matrix tbody th, .matrix td { padding: 0 0 14px; border: 0; }
  .matrix td::before { display: block; margin-bottom: 8px; color: var(--on-dark-2); font: 400 11.5px/1.4 var(--mono); }
  .matrix td:nth-of-type(1)::before { content: "Does the work repeat in one field?"; }
  .matrix td:nth-of-type(2)::before { content: "Can a run be checked?"; }
  .matrix td:nth-of-type(3)::before { content: "How strong is the starting harness?"; }
}
@media (max-width: 760px) {
  .site nav { display: none; }
  .head { padding: 56px 16px 40px; }
  .matrix-wrap, .body { padding-left: 16px; padding-right: 16px; }
  .dek { font-size: 18px; }
  .matrix { border-radius: 14px; }
  .facts { grid-template-columns: 1fr; }
  .watch { grid-template-columns: 1fr; gap: 4px; }
}

/* The header: a field of dots with the post's subject lit (scripts/research-header.py). */
.hero-fig { max-width: 1240px; margin: 0 auto 8px; padding: 0 24px; }
.hero-fig svg { display: block; width: 100%; height: auto; border-radius: 22px; }
.data { width: 100%; margin: 20px 0 28px; border-collapse: collapse; font-size: 15px; }
.data th, .data td { padding: 12px 12px 12px 0; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; color: var(--ink-2); }
.data thead th { color: var(--muted); font-size: 13px; font-weight: 500; border-bottom-color: var(--line-2); }
.data td:first-child { color: var(--ink); font-weight: 500; }
.data .n { text-align: right; padding-right: 0; font-variant-numeric: tabular-nums; white-space: nowrap; }
.steps { margin: 16px 0 24px; padding-left: 22px; }
.steps li { margin: 8px 0; color: var(--ink-2); line-height: 1.6; }
.refs { padding-left: 0 !important; list-style: none; counter-reset: r; font-size: 14.5px; }
.refs li { position: relative; padding-left: 36px; counter-increment: r; }
.refs li::before { content: "[" counter(r) "]"; position: absolute; left: 0; color: var(--muted); font: 12.5px/2 var(--mono); }
.steps li b { color: var(--ink); font-weight: 600; }

/* How mttr grades: the four stages with Shopify's average on a tick meter, and the spread of grades. */
.grade { margin: 24px 0 8px; overflow: hidden; border-radius: 20px; background: var(--graphite); color: var(--on-dark); }
.grade table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
.grade th, .grade td { padding: 16px 20px; border-bottom: 1px solid var(--dark-line); text-align: left; vertical-align: middle; }
.grade thead th { padding-top: 18px; padding-bottom: 12px; color: var(--on-dark-2); font: 400 12px/1.4 var(--mono); }
.grade tbody th { width: 26%; font-weight: 500; font-size: 15.5px; }
.grade tbody th small { display: block; margin-top: 2px; color: var(--on-dark-2); font: 400 12px/1.4 var(--mono); }
.grade td { color: var(--on-dark-2); }
.grade .tm { width: 34%; white-space: nowrap; }
.grade .tm b { margin-left: 12px; color: var(--on-dark); font-weight: 600; font-variant-numeric: tabular-nums; }
.tk { width: 177px; height: 18px; vertical-align: middle; }
.grades { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); }
.grades div { padding: 16px 20px 18px; border-right: 1px solid var(--dark-line); }
.grades div:last-child { border-right: 0; }
.grades b { display: block; font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
.grades span { display: block; margin-top: 2px; color: var(--on-dark); font-variant-numeric: tabular-nums; }
.grades small { display: block; color: var(--on-dark-2); font: 400 12px/1.4 var(--mono); }
.grade-cap { padding: 12px 20px; border-top: 1px solid var(--dark-line); color: var(--on-dark-2); font: 400 12px/1.5 var(--mono); }

/* What the skill carries: its reference files, each with what it covers. */
.files { margin: 20px 0 8px; padding: 0; list-style: none; border-top: 1px solid var(--line-2); }
.files li { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); font-size: 15px; color: var(--ink-2); }
.files a { color: var(--ink); font: 500 13.5px/1.6 var(--mono); text-decoration: none; white-space: nowrap; }
.files a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* The one call to action: the skill, on a graphite card, with the words to hand an agent. */
.get { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 24px; margin: 32px 0 8px; padding: 28px; border-radius: 20px; background: var(--graphite); color: var(--on-dark); }
.get h3 { margin: 0; font-size: 21px; font-weight: 500; letter-spacing: -0.015em; }
.get p { margin: 8px 0 0; color: var(--on-dark-2); font-size: 15px; line-height: 1.6; }
.get pre { grid-column: 1 / -1; margin: 0; padding: 14px 16px; border: 1px solid var(--dark-line); border-radius: 12px; color: var(--on-dark); font: 13px/1.6 var(--mono); white-space: pre-wrap; }
.get .btn { background: linear-gradient(#ffffff, #e9e9ea); color: #232324 !important; white-space: nowrap; }
.get .also { grid-column: 1 / -1; margin: 0; color: var(--on-dark-2); font-size: 14px; }
.get .also a { color: var(--on-dark); }
@media (max-width: 640px) {
  .grade thead { display: none; }
  .grade tr, .grade th, .grade td { display: block; width: auto; }
  .grade tbody th { width: auto; padding-bottom: 4px; border-bottom: 0; }
  .grade td { padding-top: 4px; padding-bottom: 4px; border-bottom: 0; }
  .grade tr { padding-bottom: 12px; border-bottom: 1px solid var(--dark-line); }
  .grade .tm { width: auto; }
  .grades { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .grades div:nth-child(3) { border-right: 0; }
  .grades div:nth-child(-n+3) { border-bottom: 1px solid var(--dark-line); }
  .files li { grid-template-columns: 1fr; gap: 4px; }
  .get { grid-template-columns: 1fr; padding: 22px; }
}

/* Headings break into even lines and no paragraph ends on a word alone. */
h1, h2, h3, h4 { text-wrap: balance; }
p, li, dd, figcaption, blockquote, summary { text-wrap: pretty; }

/* A wide table scrolls inside its own box on a phone, never the page. */
.data-wrap { overflow-x: auto; margin: 20px 0 28px; }
.data-wrap .data { margin: 0; min-width: 640px; }
.data tr.all td { color: var(--ink); font-weight: 600; }
.data th.n, .data td.n { padding-left: 16px; }
.data thead th { white-space: nowrap; }
.hero-fig .narrow { display: none; }
@media (max-width: 600px) { .hero-fig .wide { display: none; } .hero-fig .narrow { display: block; } }
