/* design: v2 */
/* stackingkits.com, design v2: a launderette. Cobalt blue for the hero, page heads and footer (the shop sign), a pale
   rinse-blue reading surface, white cards outlined in ink like the machines, and signal yellow for the one thing the site
   finds, the kit (its part number, the button, the tags). Rubik for headings, Karla for text, Red Hat Mono for model and
   part numbers (all OFL, self-hosted). Light surfaces in dark mode too (color-scheme: light), so every pair is checked
   once, by tests/design.test.ts. */

@font-face { font-family: "Rubik"; src: url("/fonts/rubik.woff2") format("woff2"); font-weight: 500 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Karla"; src: url("/fonts/karla.woff2") format("woff2"); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Red Hat Mono"; src: url("/fonts/red-hat-mono.woff2") format("woff2"); font-weight: 400 600; font-style: normal; font-display: swap; }

:root {
  --brand: #2340c4;        /* launderette cobalt: the hero, page heads and footer */
  --brand-deep: #1a2f99;
  --bg: #e3eaf7;           /* pale rinse blue, the reading surface */
  --card: #ffffff;
  --band: #cdd8f0;
  --text: #121a3a;         /* ink, the machines' outline */
  --muted: #44506f;
  --line: #b8c4e0;
  --rule: #121a3a;
  --link: #1f38b0;
  --on-brand: #ffffff;
  --on-brand-muted: #dde3fb;
  --signal: #ffcf3f;       /* the kit */
  --signal-text: #121a3a;
  --btn: #ffcf3f;
  --btn-hover: #ffc01a;
  --btn-text: #121a3a;
  --yes: #155a34; --yes-bg: #d8efe0;
  --warn: #7a4c00; --warn-bg: #fbe8bd;
  --no: #3d4766; --no-bg: #e2e7f3;
  --display: "Rubik", "Arial Rounded MT Bold", system-ui, sans-serif;
  --sans: "Karla", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Red Hat Mono", ui-monospace, "Cascadia Mono", Consolas, monospace;
  --radius: 14px;
  color-scheme: light;
}

/* ---------- type ---------- */
body { font-family: var(--sans); font-size: 18px; line-height: 1.6; background: var(--bg); color: var(--text); }
main { overflow-x: clip; }
h1, h2, h3 { font-family: var(--display); font-weight: 700; letter-spacing: -0.01em; color: var(--text); text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); line-height: 1.04; margin: 0.1em 0 0.3em; font-weight: 800; }
h2 { font-size: clamp(1.45rem, 2.8vw, 1.9rem); line-height: 1.15; margin: 1.6em 0 0.5em; }
h3 { font-size: 1.15rem; line-height: 1.25; margin: 0 0 0.3em; }
a { color: var(--link); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2.5px; }
.code { font-family: var(--mono); font-weight: 600; letter-spacing: 0.01em; }
.wrap { max-width: 1180px; padding: 0 24px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } body { font-size: 17px; } }
::selection { background: var(--signal); color: var(--signal-text); }
.label { font-size: 0.9rem; line-height: 1.5; color: var(--muted); margin: 10px 0 0; }
.section-sub { color: var(--muted); margin-top: -0.2em; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- header ---------- */
.site-header { background: var(--bg); border-bottom: 0; }
.header-row { padding-top: 10px; padding-bottom: 10px; max-width: none; padding-left: clamp(16px, 3.6vw, 56px); padding-right: clamp(16px, 3.6vw, 56px); }
.brand { gap: 10px; }
.brand svg.logo-mark { width: 42px; height: 42px; }
.wordmark { font-family: var(--display); font-weight: 800; font-size: 1.5rem; line-height: 1; color: var(--text); }
.main-nav { gap: 4px 24px; }
.main-nav a { font-family: var(--display); font-weight: 600; font-size: 1.02rem; color: var(--text); }
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--link); text-decoration-color: var(--signal); text-decoration-thickness: 4px; }
.menu-btn { font-family: var(--display); font-weight: 700; color: var(--text); border: 2.5px solid var(--text); border-radius: 12px; background: var(--card); }
@media (max-width: 760px) { .wordmark { font-size: 1.25rem; } .brand svg.logo-mark { width: 36px; height: 36px; } .has-menu.menu-open .main-nav a { border-top-color: var(--line); } }

/* ---------- buttons ---------- */
.btn { background: var(--btn); color: var(--btn-text); border: 3px solid var(--rule); border-radius: 12px; font-family: var(--display); font-weight: 700; font-size: 1.08rem; padding: 11px 24px; cursor: pointer; box-shadow: 4px 4px 0 var(--rule); }
.btn:hover { background: var(--btn-hover); color: var(--btn-text); }
.btn:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--rule); }

/* ---------- the checker: two machine rows, the dryer on top as in real life ---------- */
.checker { background: var(--card); color: var(--text); border: 3px solid var(--rule); border-radius: var(--radius); padding: 16px 18px 12px; display: grid; gap: 12px; max-width: 640px; box-shadow: 6px 6px 0 var(--rule); }
.machine-row { border: 0; margin: 0; padding: 0; display: grid; grid-template-columns: minmax(0, 11rem) minmax(0, 1fr); gap: 8px; }
.machine-row legend { font-family: var(--display); font-weight: 700; font-size: 1.02rem; padding: 0; margin-bottom: 6px; }
.machine-row .where { font-family: var(--sans); font-weight: 400; color: var(--muted); font-size: 0.92rem; margin-left: 4px; }
.kit-line { height: 14px; border: 2.5px solid var(--rule); border-radius: 5px; background: var(--signal); display: flex; justify-content: space-between; align-items: center; padding: 0 10px; margin: 2px -6px; }
.kit-line span { width: 6px; height: 6px; border-radius: 50%; background: var(--rule); }
.checker select, .checker input[type="text"] { font: inherit; font-size: 1.02rem; padding: 10px 12px; border: 2.5px solid var(--rule); border-radius: 10px; background: #ffffff; color: var(--text); min-width: 0; width: 100%; }
.checker input[type="text"] { font-family: var(--mono); text-transform: uppercase; }
.checker input[type="text"]::placeholder { font-family: var(--sans); text-transform: none; color: var(--muted); opacity: 1; }
.checker select:focus, .checker input:focus { outline: 3px solid var(--signal); outline-offset: 2px; }
.checker-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.checker-foot label { font-weight: 700; }
.checker-foot select { width: auto; flex: 1 1 10rem; }
.checker-foot .btn { margin-left: auto; }
.checker-help { margin: 0; font-size: 0.9rem; color: var(--muted); }
@media (max-width: 520px) { .machine-row { grid-template-columns: 1fr; } .checker-foot .btn { margin-left: 0; width: 100%; } }

/* ---------- home: the hero ---------- */
.hero { background: var(--brand); color: var(--on-brand); position: relative; overflow: hidden; }
.hero-in { max-width: none; padding: 34px clamp(16px, 3.6vw, 56px) 0; display: grid; grid-template-columns: minmax(0, 40rem) minmax(0, 1fr); gap: 20px 40px; align-items: end; }
.hero-text { padding-bottom: 46px; align-self: center; }
.hero h1 { color: var(--on-brand); font-size: clamp(2.4rem, 4.6vw, 4rem); line-height: 1; margin: 0 0 14px; }
.hero-sub { font-size: 1.14rem; line-height: 1.5; margin: 0 0 22px; max-width: 34em; color: var(--on-brand); }
.hero-art { line-height: 0; justify-self: end; width: 100%; max-width: 620px; }
.hero-art .hero-scene { display: block; width: 100%; height: auto; }
@media (max-width: 980px) { .hero-in { grid-template-columns: 1fr; } .hero-text { padding-bottom: 8px; } .hero-art { max-width: 440px; justify-self: center; } }
@media (max-width: 600px) { .hero h1 { font-size: 2.3rem; } .hero-sub { font-size: 1.04rem; } }

/* ---------- home: below the hero ---------- */
.answers, .covered, .before { padding-top: 8px; padding-bottom: 8px; }
.answer-strip { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 0; border: 3px solid var(--rule); border-radius: var(--radius); background: var(--card); overflow: hidden; }
.answer { display: grid; grid-template-columns: 76px minmax(0, 1fr); gap: 14px; padding: 18px; align-items: start; }
.answer + .answer { border-left: 3px dashed var(--line); }
.answer .spot { width: 76px; height: 76px; }
.answer p { margin: 0; }
.a-yes h3 { color: var(--yes); } .a-warn h3 { color: var(--warn); } .a-no h3 { color: var(--no); }
@media (max-width: 900px) { .answer-strip { grid-template-columns: 1fr; } .answer + .answer { border-left: 0; border-top: 3px dashed var(--line); } }
.brand-shelf { list-style: none; padding: 0; margin: 1em 0; columns: 2 22rem; column-gap: 36px; }
.brand-shelf li { break-inside: avoid; display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; padding: 10px 0; border-bottom: 2px solid var(--line); }
.brand-name { font-family: var(--display); font-weight: 700; min-width: 7rem; }
.brand-kits a { font-size: 0.95rem; margin-right: 10px; }
.before { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 24px; align-items: start; }
.before-art .spot { width: 120px; height: 120px; }
.guide-list { padding-left: 1.2em; }
.guide-list li { margin: 0.4em 0; }
@media (max-width: 600px) { .before { grid-template-columns: 1fr; } .before-art { display: none; } }

/* ---------- article pages: a cobalt head with its spot ---------- */
.crumbs { margin: 0; padding: 4px 0 12px; font-size: 0.9rem; color: var(--muted); }
.page-head, .page-head.has-art { background: var(--brand); color: var(--on-brand); border-radius: 20px; padding: 24px clamp(18px, 3vw, 36px) 20px; margin-bottom: 26px; max-width: none; align-items: center; border: 3px solid var(--rule); }
.page-head h1 { color: var(--on-brand); margin-top: 0; }
.page-head .lede, .page-head .byline, .page-head .disclosure { color: var(--on-brand); }
.page-head .lede { font-size: 1.14rem; }
.page-head .byline { font-size: 0.88rem; color: var(--on-brand-muted); }
.page-head .byline a, .page-head .disclosure a { color: var(--on-brand-muted); }
.page-head-art { width: clamp(90px, 15vw, 160px); }
.page-head-art .spot { width: 100%; height: auto; }
@media (max-width: 560px) { .page-head.has-art { flex-direction: row; gap: 10px; } .page-head-art { width: 76px; } .page-head h1 { font-size: 1.8rem; } }
.page-body { max-width: 940px; }
.toc { border: 2.5px solid var(--rule); background: var(--card); border-radius: var(--radius); }
.toc-title { font-family: var(--display); font-weight: 700; }

/* ---------- the answer ---------- */
.verdict { border: 3px solid var(--rule); border-radius: var(--radius); padding: 16px 20px; margin: 0 0 1.4em; background: var(--card); }
.verdict h2 { margin-top: 0.1em; }
.v-yes { border-left: 14px solid var(--yes); }
.v-warn { border-left: 14px solid #d99400; }
.v-no, .v-ask { border-left: 14px solid var(--no); }
.notes { margin: 0.4em 0; padding-left: 1.2em; }
.source { font-size: 0.9rem; color: var(--muted); }
.codes .code { display: inline-block; margin: 0 8px 6px 0; }

/* ---------- kits ---------- */
.kit-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; margin: 1em 0; }
.kit-card { background: var(--card); border: 2.5px solid var(--rule); border-radius: var(--radius); padding: 14px 18px; min-width: 0; }
.kit-card p { margin: 0.35em 0; }
.kit-part { margin: 0; }
.kit-part .code, .kit-hero .code { background: var(--signal); color: var(--signal-text); border: 2.5px solid var(--rule); border-radius: 8px; padding: 2px 10px; font-size: 1.15rem; display: inline-block; }
.kit-part.big .code { font-size: 1.7rem; padding: 4px 14px; }
.aka { font-size: 0.88rem; color: var(--muted); margin-left: 6px; }
.kit-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 0.8rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; background: var(--band); color: var(--text); }
.tag-shelf { background: var(--yes-bg); color: var(--yes); }
.tag-uni { background: var(--warn-bg); color: var(--warn); }
.shops { font-size: 0.92rem; }
.code-list .code { display: inline-block; margin: 0 10px 6px 0; font-size: 0.95rem; }
.maker-says li { margin: 0.5em 0; }

/* ---------- footer ---------- */
.site-footer { background: var(--brand-deep); color: var(--on-brand); border-top: 6px solid var(--signal); }
.site-footer a, .footer-note, .footer-publisher, .footer-col h2, .footer-brand { color: var(--on-brand); }
.footer-note, .footer-publisher { color: var(--on-brand-muted); }
.footer-col h2 { font-family: var(--display); }
.maker-says .maker { font-family: var(--display); font-weight: 700; margin-right: 6px; }
