/* ============================================================
   Low Quality Image — "photocopy manual" design system v1
   Paper, ink, one toner-red action colour, mono instrumentation.
   ============================================================ */

:root {
  /* palette */
  --paper: #f2ede2;
  --paper-2: #fbf7ee;
  --ink: #191712;
  --ink-soft: #4a4437;
  --line: #d5cbba;
  --red: #b7361b;
  --red-deep: #8e2a14;
  --amber: #c98a1e;
  --teal: #1e5b63;
  --ok: #2c6b3f;
  --white: #ffffff;

  /* type */
  --font-body: "Bricolage Grotesque", system-ui, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
  --text-xs: 12px;
  --text-sm: 14px;
  --text-base: 16px;
  --text-lg: 18px;
  --text-xl: 22px;
  --text-2xl: 28px;
  --text-3xl: 36px;
  --text-4xl: 48px;

  /* space */
  --s1: 4px;
  --s2: 8px;
  --s3: 12px;
  --s4: 16px;
  --s5: 24px;
  --s6: 32px;
  --s7: 48px;
  --s8: 64px;

  /* shape */
  --radius: 12px;
  --radius-sm: 8px;
  --shadow-1: 0 1px 2px rgba(25, 23, 18, 0.08);
  --shadow-2: 0 8px 24px rgba(25, 23, 18, 0.1);
  --rule: 1px solid var(--line);
  --rule-ink: 1.5px solid var(--ink);
  --container: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background-color: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: var(--text-lg);
  line-height: 1.6;
  font-weight: 400;
  background-image: radial-gradient(rgba(25, 23, 18, 0.045) 0.6px, transparent 0.6px);
  background-size: 4px 4px;
}

[hidden] {
  display: none !important;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--ink);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--red-deep);
}

:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
  border-radius: 2px;
}

h1,
h2,
h3,
h4 {
  line-height: 1.15;
  letter-spacing: -0.015em;
  margin: 0 0 var(--s3);
  font-weight: 800;
  text-wrap: balance;
}

h1 {
  font-size: var(--text-4xl);
}

h2 {
  font-size: var(--text-3xl);
}

h3 {
  font-size: var(--text-xl);
}

h4 {
  font-size: var(--text-lg);
}

p {
  margin: 0 0 var(--s4);
}

p:last-child {
  margin-bottom: 0;
}

ul,
ol {
  margin: 0 0 var(--s4);
  padding-left: 1.15em;
}

li {
  margin-bottom: var(--s2);
}

strong {
  font-weight: 600;
}

code,
kbd,
samp {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: rgba(25, 23, 18, 0.06);
  padding: 1px 5px;
  border-radius: 4px;
}

hr {
  border: 0;
  border-top: var(--rule);
  margin: var(--s7) 0;
}

/* ---------- layout ---------- */

.shell {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding-left: var(--s5);
  padding-right: var(--s5);
}

.section {
  padding: var(--s8) 0;
  border-top: var(--rule);
}

.section-tight {
  padding: var(--s7) 0;
}

.section-head {
  max-width: 62ch;
  margin-bottom: var(--s6);
}

.section-head p {
  color: var(--ink-soft);
  margin-bottom: 0;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--ink);
  color: var(--paper-2);
  padding: var(--s2) var(--s4);
  z-index: 50;
}

.skip:focus {
  left: var(--s3);
  top: var(--s3);
}

/* ---------- masthead ---------- */

.masthead {
  position: sticky;
  top: 0;
  z-index: 20;
  background-color: var(--paper);
  border-bottom: var(--rule-ink);
}

.masthead-in {
  display: flex;
  align-items: center;
  gap: var(--s5);
  min-height: 64px;
  padding-top: var(--s2);
  padding-bottom: var(--s2);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--s3);
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  background: var(--ink);
  color: var(--paper-2);
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  font-weight: 600;
  border-radius: var(--radius-sm);
  transform: rotate(-3deg);
}

.brand-name {
  font-size: var(--text-lg);
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--s4);
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.nav a {
  text-decoration: none;
  padding: 10px 2px;
  border-bottom: 2px solid transparent;
}

.nav a:hover {
  border-bottom-color: var(--red);
  color: var(--ink);
}

.masthead-cta {
  flex: none;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--s2);
  min-height: 48px;
  padding: 0 var(--s5);
  border-radius: var(--radius);
  border: var(--rule-ink);
  background-color: var(--paper-2);
  color: var(--ink);
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow-1);
  transition: transform 150ms ease, box-shadow 150ms ease, background-color 150ms ease;
}

.btn:hover {
  transform: translate(-1px, -1px);
  box-shadow: var(--shadow-2);
  color: var(--ink);
}

.btn-primary {
  background-color: var(--red);
  border-color: var(--red-deep);
  color: var(--white);
}

.btn-primary:hover {
  background-color: var(--red-deep);
  color: var(--white);
}

.btn-sm {
  min-height: 40px;
  padding: 0 var(--s4);
  font-size: var(--text-xs);
}

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s3);
  margin-top: var(--s5);
}

/* ---------- type helpers ---------- */

.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--s2);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: var(--s3);
}

.eyebrow::before {
  content: "";
  width: 18px;
  height: 2px;
  background: var(--red);
  flex: none;
}

.lede {
  font-size: var(--text-lg);
  color: var(--ink-soft);
  max-width: 60ch;
}

.mono {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
}

.muted {
  color: var(--ink-soft);
}

.small {
  font-size: var(--text-sm);
}

.prose {
  max-width: 68ch;
}

.prose h2 {
  margin-top: var(--s7);
}

.prose h2:first-child {
  margin-top: 0;
}

.prose h3 {
  margin-top: var(--s5);
}

/* ---------- hero ---------- */

.hero {
  padding: var(--s7) 0 var(--s8);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: var(--s7);
  align-items: center;
}

.hero h1 {
  font-size: var(--text-4xl);
  max-width: 18ch;
  margin-bottom: var(--s4);
}

.hero .lede {
  margin-bottom: var(--s5);
}

.hero-note {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--ink-soft);
  margin-top: var(--s4);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  margin: var(--s4) 0 0;
  padding: 0;
  list-style: none;
}

.chips li {
  margin: 0;
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.02em;
  border: var(--rule);
  border-radius: 999px;
  padding: 5px 10px;
  background: var(--paper-2);
  color: var(--ink-soft);
}

/* specimen card: the one memorable element */
.specimen {
  position: relative;
  background-color: var(--paper-2);
  border: var(--rule-ink);
  border-radius: var(--radius);
  padding: var(--s4);
  box-shadow: var(--shadow-2);
}

.specimen::before,
.specimen::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border: 2px solid var(--red);
}

.specimen::before {
  top: 8px;
  left: 8px;
  border-right: 0;
  border-bottom: 0;
}

.specimen::after {
  bottom: 8px;
  right: 8px;
  border-left: 0;
  border-top: 0;
}

.specimen-main {
  position: relative;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: var(--rule);
  background: var(--line);
}

.specimen-main > img {
  width: 100%;
  display: block;
}

.specimen-tag {
  position: absolute;
  top: var(--s2);
  right: var(--s2);
  padding: 4px 8px;
  border-radius: 6px;
  background-color: var(--ink);
  color: var(--paper-2);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.specimen-inset {
  position: absolute;
  left: var(--s2);
  top: var(--s2);
  width: 34%;
  margin: 0;
  border: 2px solid var(--paper-2);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-1);
  background-color: var(--paper-2);
}

.specimen-inset img {
  width: 100%;
  display: block;
}

.specimen-inset figcaption {
  padding: 3px 6px;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background-color: var(--paper-2);
}

.specimen-foot {
  margin-top: var(--s3);
  padding-top: var(--s3);
  border-top: var(--rule);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-soft);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s1) var(--s2);
  line-height: 1.5;
}

/* ---------- tool index ---------- */

.tool-index {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.tool-index li {
  margin: 0;
}

.tool-card {
  display: flex;
  flex-direction: column;
  gap: var(--s2);
  height: 100%;
  padding: var(--s5);
  background-color: var(--paper-2);
  border: var(--rule);
  border-radius: var(--radius);
  text-decoration: none;
  transition: transform 150ms ease, box-shadow 150ms ease, border-color 150ms ease;
}

.tool-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-2);
  border-color: var(--ink);
  color: var(--ink);
}

.tool-card .num {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--red);
  letter-spacing: 0.08em;
}

.tool-card h3 {
  margin: 0;
  font-size: var(--text-lg);
}

.tool-card p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
  line-height: 1.5;
}

.tool-card .go {
  margin-top: auto;
  padding-top: var(--s3);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
}

/* ---------- numbered steps ---------- */

.steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--s5);
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.steps li {
  margin: 0;
  padding-top: var(--s4);
  border-top: 2px solid var(--ink);
  counter-increment: step;
}

.steps .step-n {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--red);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.steps .step-n::after {
  content: " 0" counter(step);
}

.steps h3 {
  font-size: var(--text-lg);
  margin: var(--s1) 0 var(--s2);
}

.steps p {
  font-size: var(--text-sm);
  color: var(--ink-soft);
  margin: 0;
}

/* ---------- definitions ---------- */

.defs {
  margin: 0;
  border-top: var(--rule);
}

.defs div {
  display: grid;
  grid-template-columns: minmax(0, 0.42fr) minmax(0, 0.58fr);
  gap: var(--s4);
  padding: var(--s4) 0;
  border-bottom: var(--rule);
}

.defs dt {
  font-weight: 600;
}

.defs dd {
  margin: 0;
  color: var(--ink-soft);
}

/* ---------- style cards ---------- */

.styles {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s5);
}

.style-card {
  background-color: var(--paper-2);
  border: var(--rule);
  border-radius: var(--radius);
  padding: var(--s5);
  box-shadow: var(--shadow-1);
}

.style-card h3 {
  margin-bottom: var(--s1);
}

.style-card .tagline {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  color: var(--red);
  text-transform: uppercase;
  margin-bottom: var(--s3);
}

.style-card p {
  font-size: var(--text-sm);
  color: var(--ink-soft);
}

.recipe {
  margin: var(--s3) 0;
  padding: var(--s3);
  border-left: 3px solid var(--ink);
  background: rgba(25, 23, 18, 0.04);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  line-height: 1.6;
  color: var(--ink);
}

.style-meta {
  display: grid;
  gap: var(--s2);
  margin: var(--s3) 0 0;
  font-size: var(--text-sm);
}

.style-meta p {
  margin: 0;
}

.style-meta b {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: block;
  margin-bottom: 2px;
}

.traits {
  list-style: none;
  padding: 0;
  margin: var(--s2) 0 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
}

.traits li {
  position: relative;
  padding-left: var(--s4);
  margin-bottom: var(--s1);
}

.traits li::before {
  content: "×";
  position: absolute;
  left: 0;
  color: var(--red);
  font-weight: 600;
}

/* ---------- generic cards ---------- */

.cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--s4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.cards li {
  margin: 0;
  padding: var(--s5);
  background-color: var(--paper-2);
  border: var(--rule);
  border-radius: var(--radius);
}

.cards h3 {
  font-size: var(--text-lg);
  margin-bottom: var(--s2);
}

.cards p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
}

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

/* ---------- table ---------- */

.table-wrap {
  overflow-x: auto;
  border: var(--rule);
  border-radius: var(--radius);
  background: var(--paper-2);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--text-sm);
}

th,
td {
  text-align: left;
  padding: var(--s3) var(--s4);
  border-bottom: var(--rule);
  vertical-align: top;
}

th {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: rgba(25, 23, 18, 0.04);
}

tr:last-child td {
  border-bottom: 0;
}

/* ---------- faq ---------- */

.faq {
  border-top: var(--rule-ink);
}

.faq details {
  border-bottom: var(--rule);
}

.faq summary {
  display: flex;
  justify-content: space-between;
  gap: var(--s4);
  align-items: baseline;
  padding: var(--s4) 0;
  cursor: pointer;
  font-weight: 600;
  font-size: var(--text-lg);
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: "+";
  font-family: var(--font-mono);
  font-size: var(--text-xl);
  color: var(--red);
  flex: none;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "–";
}

.faq .answer {
  padding: 0 0 var(--s5);
  max-width: 68ch;
  color: var(--ink-soft);
}

.faq .answer p {
  margin: 0;
}

/* ---------- callout / cta band ---------- */

.band {
  background-color: var(--ink);
  color: var(--paper-2);
  border-radius: var(--radius);
  padding: var(--s7);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--s5);
}

.band h2 {
  color: var(--paper-2);
  margin: 0;
  max-width: 24ch;
}

.band p {
  color: var(--line);
  margin: var(--s2) 0 0;
  max-width: 46ch;
}

.band .btn {
  background-color: var(--paper-2);
  border-color: var(--paper-2);
  color: var(--ink);
}

.band .btn:hover {
  background-color: var(--white);
  color: var(--ink);
}

.note {
  border: var(--rule);
  border-left: 4px solid var(--amber);
  background: var(--paper-2);
  padding: var(--s4);
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
}

.note b {
  color: var(--ink);
}

/* ---------- tool page ---------- */

.tool-head {
  padding: var(--s6) 0 var(--s5);
}

.tool-head h1 {
  font-size: var(--text-3xl);
  max-width: 22ch;
  margin-bottom: var(--s3);
}

.tool-head .lede {
  max-width: 66ch;
}

.tool-app {
  padding: var(--s4);
}

.bench {
  border: var(--rule-ink);
  border-radius: var(--radius);
  background-color: var(--paper-2);
  box-shadow: var(--shadow-2);
  overflow: hidden;
}

.bench-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s3);
  padding: var(--s3) var(--s4);
  border-bottom: var(--rule);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
  background: rgba(25, 23, 18, 0.04);
}

.bench-body {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 0;
}

.bench-stage {
  padding: var(--s4);
  border-right: var(--rule);
  min-height: 320px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: var(--s3);
}

.drop {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--s3);
  text-align: center;
  padding: var(--s6) var(--s4);
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  transition: border-color 150ms ease, background-color 150ms ease;
}

.drop[data-over="1"] {
  border-color: var(--red);
  background: var(--paper-2);
}

.drop h2 {
  font-size: var(--text-xl);
  margin: 0;
}

.drop p {
  margin: 0;
  font-size: var(--text-sm);
  color: var(--ink-soft);
  max-width: 34ch;
}

.pair {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s2);
}

.pair figure {
  margin: 0;
}

.pair img {
  width: 100%;
  border-radius: var(--radius-sm);
  border: var(--rule);
  background: var(--line);
  cursor: zoom-in;
}

.pair figcaption {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: var(--s1);
}

.readout {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s2);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  border-top: var(--rule);
  padding-top: var(--s3);
}

.readout b {
  display: block;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 400;
}

.readout span {
  font-size: var(--text-sm);
}

.bench-controls {
  padding: var(--s4);
  display: flex;
  flex-direction: column;
  gap: var(--s4);
}

.presets {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
}

.chip {
  min-height: 40px;
  padding: 0 var(--s3);
  border: var(--rule);
  border-radius: var(--radius);
  background: var(--paper);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  cursor: pointer;
  color: var(--ink);
  transition: background-color 150ms ease, border-color 150ms ease;
}

.chip:hover {
  border-color: var(--ink);
  background: var(--paper-2);
}

.chip[aria-pressed="true"] {
  background-color: var(--ink);
  border-color: var(--ink);
  color: var(--paper-2);
}

.control {
  display: grid;
  gap: var(--s1);
}

.control-head {
  display: flex;
  justify-content: space-between;
  gap: var(--s2);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
}

.control-head output {
  color: var(--red);
}

input[type="range"] {
  width: 100%;
  accent-color: var(--red);
  height: 32px;
}

fieldset.formats {
  border: 0;
  padding: 0;
  margin: 0;
  display: flex;
  gap: var(--s2);
}

fieldset.formats legend {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  margin-bottom: var(--s2);
}

.formats label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 var(--s3);
  border: var(--rule);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  cursor: pointer;
}

.formats input {
  accent-color: var(--red);
}

.bench-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  align-items: center;
}

.preset-note {
  margin: var(--s2) 0 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.5;
  color: var(--ink-soft);
}

.bench-hint {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.5;
  color: var(--ink-soft);
  max-width: 44ch;
}

.status {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--ink-soft);
}

.status[data-tone="error"] {
  color: var(--red);
}

/* ---------- related / blog ---------- */

.link-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: var(--rule);
}

.link-list li {
  margin: 0;
  border-bottom: var(--rule);
}

.link-list a {
  display: flex;
  justify-content: space-between;
  gap: var(--s4);
  align-items: baseline;
  padding: var(--s3) 0;
  text-decoration: none;
  font-weight: 600;
}

.link-list a:hover {
  color: var(--red-deep);
}

.link-list span {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  color: var(--ink-soft);
  font-weight: 400;
}

.post-list {
  display: grid;
  gap: var(--s4);
  margin: 0;
  padding: 0;
  list-style: none;
}

.post-list li {
  margin: 0;
}

.post-card {
  display: block;
  padding: var(--s5);
  border: var(--rule);
  border-radius: var(--radius);
  background: var(--paper-2);
  text-decoration: none;
  transition: border-color 150ms ease, transform 150ms ease;
}

.post-card:hover {
  border-color: var(--ink);
  transform: translateY(-1px);
  color: var(--ink);
}

.post-card h3 {
  margin-bottom: var(--s2);
  font-size: var(--text-xl);
}

.post-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: var(--text-sm);
}

.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s3);
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  color: var(--ink-soft);
  text-transform: uppercase;
  margin-bottom: var(--s3);
}

.article-head {
  padding: var(--s6) 0 var(--s5);
  border-bottom: var(--rule);
}

.article-head h1 {
  max-width: 24ch;
}

.article-body {
  padding: var(--s6) 0 var(--s7);
}

.article-body h2 {
  margin-top: var(--s7);
}

.article-body h3 {
  margin-top: var(--s5);
}

.article-body ul {
  max-width: 68ch;
}

.callout {
  margin: var(--s6) 0;
  padding: var(--s5);
  border: var(--rule);
  border-left: 4px solid var(--red);
  background: var(--paper-2);
  border-radius: 0 var(--radius) var(--radius) 0;
}

.callout b {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  display: block;
  margin-bottom: var(--s2);
}

.callout p {
  margin: 0;
}

/* ---------- footer ---------- */

.footer {
  margin-top: var(--s8);
  background-color: var(--ink);
  color: var(--line);
  padding: var(--s7) 0 var(--s5);
}

.footer-in {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) repeat(3, minmax(0, 0.7fr));
  gap: var(--s5);
}

.footer-name {
  font-weight: 800;
  color: var(--paper-2);
  font-size: var(--text-lg);
  margin-bottom: var(--s2);
}

.footer-blurb {
  font-size: var(--text-sm);
  color: var(--line);
  max-width: 34ch;
}

.footer h2 {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--paper-2);
  margin-bottom: var(--s3);
}

.footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: var(--text-sm);
}

.footer li {
  margin-bottom: var(--s2);
}

.footer a {
  color: var(--line);
  text-decoration: none;
}

.footer a:hover {
  color: var(--paper-2);
  text-decoration: underline;
}

.footer-legal {
  margin-top: var(--s6);
  padding-top: var(--s4);
  border-top: 1px solid rgba(213, 203, 186, 0.25);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s2);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--line);
}

/* ---------- responsive ---------- */

@media (max-width: 960px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: var(--s6);
  }

  .tool-index,
  .cards-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .bench-body {
    grid-template-columns: 1fr;
  }

  .bench-stage {
    border-right: 0;
    border-bottom: var(--rule);
  }

  .footer-in {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  body {
    font-size: var(--text-base);
  }

  .shell {
    padding-left: var(--s4);
    padding-right: var(--s4);
  }

  .masthead-in {
    flex-wrap: wrap;
    gap: var(--s2) var(--s3);
    padding-top: var(--s2);
    padding-bottom: var(--s2);
  }

  .brand-name {
    font-size: var(--text-base);
  }

  .masthead-cta {
    display: none;
  }

  .nav {
    width: 100%;
    gap: var(--s3);
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .nav a {
    padding: 8px 0;
    font-size: 12px;
  }

  .hero {
    padding: var(--s5) 0 var(--s6);
  }

  .hero h1,
  h1 {
    font-size: var(--text-2xl);
  }

  h2 {
    font-size: var(--text-2xl);
  }

  .lede {
    font-size: var(--text-base);
  }

  .section {
    padding: var(--s7) 0;
  }

  .tool-index,
  .cards,
  .cards-3,
  .styles,
  .steps,
  .defs div,
  .footer-in {
    grid-template-columns: 1fr;
  }

  .pair {
    grid-template-columns: 1fr;
  }

  .btn {
    width: 100%;
  }

  .btn-row .btn {
    width: 100%;
  }

  .band {
    padding: var(--s5);
  }

  .band .btn {
    width: 100%;
  }

  .bench-actions .btn {
    width: 100%;
  }

  .tool-head h1 {
    font-size: var(--text-2xl);
  }

  .faq summary {
    font-size: var(--text-base);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
