/* Parts Counter: a hardware parts counter. White trays, black label-maker tape, zinc and safety orange.
   Type: Parts Counter Sans (Hubot Sans with a plain zero; display, numerals), Redaction (reading; Redaction 50 for stamps), Azeret Mono (labels, specs, prices). */

/* Parts Counter Sans is Hubot Sans with the bar taken out of its zero (tools/fonts/plain_zero.py); the OFL reserves the name "Hubot" for the original, so the changed file carries a new name. */
@font-face { font-family: "Parts Counter Sans"; src: url("/fonts/parts-counter-sans-latin-wdth-normal.woff2") format("woff2-variations"); font-weight: 500 900; font-stretch: 75% 100%; font-display: swap; }
@font-face { font-family: "Redaction"; src: url("/fonts/redaction-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Redaction"; src: url("/fonts/redaction-latin-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Redaction 50"; src: url("/fonts/redaction-50-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Azeret Mono"; src: url("/fonts/azeret-mono-latin-wght-normal.woff2") format("woff2-variations"); font-weight: 100 900; font-display: swap; }

:root {
  --zinc: #e2e4e1;
  --zinc-2: #d3d6d2;
  --steel: #c8ccc8;
  --steel-dark: #8f9590;
  --tray: #ffffff;
  --ink: #15171a;
  --ink-2: #3e4347;
  --ink-3: #565c61;
  --tape: #121314;
  --tape-ink: #f6f6f2;
  --orange: #ff7300;
  --orange-ink: #a84a00;
  --orange-tint: #ffe6d1;
  --hair: rgba(21, 23, 26, 0.18);
  --display: "Parts Counter Sans", "Arial Narrow", sans-serif;
  --read: "Redaction", "Times New Roman", serif;
  --mono: "Azeret Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --stamp: "Redaction 50", "Redaction", serif;
  --gutter: clamp(16px, 4vw, 44px);
  --max: 1280px;
  color-scheme: light;
}

@view-transition { navigation: auto; }

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--zinc);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='b'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.003 .85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .1 0 0 0 0 .11 0 0 0 0 .12 0 0 0 .17 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23b)'/%3E%3C/svg%3E");
  color: var(--ink);
  font: 400 1.0625rem/1.55 var(--read);
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration-color: var(--orange); text-decoration-thickness: 2px; text-underline-offset: 0.2em; }
a:hover { color: var(--orange-ink); text-decoration-thickness: 3px; }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 2px; }
.vh { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--tape); color: var(--tape-ink); padding: 8px 12px; z-index: 50; font: 600 0.8rem var(--mono); }
.skip:focus { left: 8px; }
main { display: block; }
main:focus { outline: none; }

/* label-maker tape: the site's signature. Raised letters on glossy tape, each piece cut and stuck on by hand:
   tools/lib/html.mjs gives every piece its own tilt (--tilt) and cut ends (--cl, --cr), and sets the letters of big
   pieces one by one (.tape__l) so their spacing wanders the way an embosser's does. */
.tape { --tilt: 0deg; --cl: 3px; --cr: 3px; --tape-bg: var(--tape); position: relative; isolation: isolate; display: inline-block; padding: 6px 12px 5px; color: #f2f1eb; font: 700 0.72rem/1 var(--mono); letter-spacing: 0.15em; text-transform: uppercase; text-shadow: 0 -1px 0 rgba(255,255,255,0.34), 0 1px 0 rgba(0,0,0,0.95), 0 0 1px rgba(255,255,255,0.35); transform: rotate(var(--tilt)); }
.tape::before, .tape::after { content: ""; position: absolute; z-index: -1; clip-path: polygon(var(--cl) 0, 100% 0, calc(100% - var(--cr)) 100%, 0 100%); }
.tape::before { inset: 0; background: linear-gradient(180deg, rgba(255,255,255,0.24) 0, rgba(255,255,255,0.07) 15%, rgba(255,255,255,0) 40%, rgba(0,0,0,0) 70%, rgba(0,0,0,0.4) 100%), linear-gradient(100deg, rgba(255,255,255,0) 28%, rgba(255,255,255,0.08) 45%, rgba(255,255,255,0) 58%), var(--tape-bg); }
.tape::after { inset: 1px -1px -2px 1px; z-index: -2; background: rgba(0, 0, 0, 0.3); }
.tape__l i { font-style: normal; display: inline-block; }
.tape__l i:nth-child(3n+2) { transform: translateY(-0.5px); }
.tape__l i:nth-child(5n+1) { margin-right: 0.05em; }
.tape__l i:nth-child(7n+3) { transform: translateY(0.6px) rotate(-2deg); }
.tape__l i:nth-child(4n) { margin-right: -0.04em; }
.tape--l { font-size: 0.8rem; padding: 7px 14px 6px; }
.tape--s { font-size: 0.66rem; padding: 5px 9px 4px; letter-spacing: 0.1em; }
.tape--orange { --tape-bg: var(--orange); color: var(--ink); text-shadow: 0 -1px 0 rgba(255,255,255,0.5), 0 1px 0 rgba(0,0,0,0.18); }

/* ---------- counter sign and header ---------- */
.sign { background: var(--tape); color: var(--tape-ink); font: 700 0.78rem/1 var(--display); font-stretch: 80%; letter-spacing: 0.07em; text-transform: uppercase; }
.sign p { max-width: var(--max); margin: 0 auto; padding: 8px var(--gutter); display: flex; flex-wrap: wrap; gap: 4px 22px; }
.sign span::before { content: "\2022"; color: var(--orange); margin-right: 8px; }
.top { position: relative; z-index: 5; background: var(--zinc-2); border-bottom: 3px solid var(--ink); }
.top__bar { max-width: var(--max); margin: 0 auto; padding: 12px var(--gutter); display: flex; align-items: center; gap: 18px; }
.mark { display: inline-flex; align-items: center; gap: 0.18em; text-decoration: none; color: var(--ink); font-family: var(--display); font-stretch: 75%; font-weight: 900; font-size: clamp(1.4rem, 2.5vw, 1.85rem); text-transform: uppercase; line-height: 1; white-space: nowrap; }
.mark:hover { color: var(--ink); }
.mark__amp { display: inline-grid; place-items: center; width: 1.12em; height: 1.12em; border-radius: 50%; background: var(--orange); color: var(--ink); font-family: var(--read); font-style: italic; font-weight: 400; text-transform: none; font-size: 0.82em; line-height: 1; }
.nav { margin-left: auto; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 2px; }
.nav a { display: block; padding: 9px 10px; font: 700 1rem/1 var(--display); font-stretch: 88%; color: var(--ink); text-decoration: none; border-radius: 3px; }
.nav a:hover { background: var(--tray); color: var(--ink); }
.nav a[aria-current="page"] { background: var(--tape); color: var(--tape-ink); }
.top__tools { display: flex; gap: 8px; align-items: center; }
.rigchip, .bagbtn { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 6px 12px; border: 2px solid var(--ink); border-radius: 3px; font: 700 0.92rem/1 var(--display); font-stretch: 88%; color: var(--ink); text-decoration: none; background: var(--tray); white-space: nowrap; }
.rigchip__label { color: var(--ink-3); }
.rigchip.is-set { background: var(--orange); }
.rigchip.is-set .rigchip__label { color: var(--ink); }
.rigchip.is-set .rigchip__value { font-weight: 800; }
.bagbtn { background: var(--tape); color: var(--tape-ink); }
.bagbtn:hover { color: var(--tape-ink); background: #2a2d31; }
.bagbtn__n { min-width: 1.5em; padding: 3px 5px; background: var(--orange); color: var(--ink); text-align: center; font-weight: 800; border-radius: 2px; }
.menu { display: none; position: relative; }
.menu summary { list-style: none; cursor: pointer; display: inline-flex; align-items: center; min-height: 38px; padding: 6px 14px; border: 2px solid var(--ink); border-radius: 3px; font: 800 0.95rem/1 var(--display); font-stretch: 88%; background: var(--tray); }
.menu summary::-webkit-details-marker { display: none; }
.menu nav { position: absolute; right: 0; top: calc(100% + 8px); background: var(--tray); border: 2px solid var(--ink); box-shadow: 5px 5px 0 var(--ink); min-width: 230px; padding: 6px; }
.menu ul { list-style: none; margin: 0; padding: 0; }
.menu a { display: block; padding: 12px; font: 700 1.05rem/1 var(--display); font-stretch: 88%; color: var(--ink); text-decoration: none; }
.menu a:hover { background: var(--orange-tint); }
@media (max-width: 1080px) { .nav { display: none; } .menu { display: block; } .top__tools { margin-left: auto; } }
@media (max-width: 560px) {
  .top__bar { flex-wrap: wrap; gap: 10px; }
  .top__tools { order: 3; width: 100%; justify-content: space-between; }
  .menu { margin-left: auto; }
  .sign p { gap: 2px 14px; font-size: 0.6rem; }
}

/* ---------- page and type ---------- */
.sheet { max-width: var(--max); margin: 0 auto; padding: 20px var(--gutter) 80px; }
h1, h2, h3 { font-family: var(--display); font-weight: 850; line-height: 0.98; margin: 0 0 0.4em; color: var(--ink); }
h1 { font-stretch: 75%; font-size: clamp(2.3rem, 5.4vw, 4.4rem); letter-spacing: -0.01em; }
h2 { font-stretch: 75%; font-size: clamp(1.45rem, 2.5vw, 2rem); }
h3 { font-stretch: 90%; font-size: 1.12rem; font-weight: 750; }
p { margin: 0 0 0.9em; }
.kicker { margin: 0 0 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.kicker .icon { width: 44px; height: 30px; }
.lede { font-size: clamp(1.12rem, 1.6vw, 1.3rem); line-height: 1.45; max-width: 60ch; }
.lede-s { color: var(--ink-2); max-width: 70ch; }
.note { font: 500 0.78rem/1.5 var(--mono); color: var(--ink-2); border-left: 4px solid var(--orange); padding: 2px 0 2px 10px; }
.sec-h { display: flex; align-items: center; gap: 14px; margin-top: 64px; }
.sec-h::after { content: ""; flex: 1; height: 3px; background: var(--ink); }
.crumbs ol { list-style: none; margin: 0 0 22px; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font: 600 0.9rem/1.4 var(--display); font-stretch: 90%; color: var(--ink-3); }
.crumbs li + li::before { content: "/"; margin-right: 4px; }
.crumbs a { color: var(--ink-2); text-decoration-thickness: 1px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 12px 20px; border: 2px solid var(--ink); border-radius: 2px; background: var(--orange); color: var(--ink); font: 800 1.05rem/1 var(--display); font-stretch: 88%; letter-spacing: 0.01em; text-decoration: none; cursor: pointer; box-shadow: 0 4px 0 var(--ink); transition: transform .1s ease, box-shadow .1s ease; }
.btn:hover { color: var(--ink); transform: translateY(-1px); box-shadow: 0 5px 0 var(--ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn:disabled, .btn:disabled:hover { background: var(--tray); color: var(--ink); border-style: dashed; box-shadow: none; transform: none; cursor: not-allowed; }
.btn--ghost { background: var(--tray); }
.btn--dark { background: var(--tape); color: var(--tape-ink); box-shadow: 0 4px 0 var(--orange); }
.btn--dark:hover { color: var(--tape-ink); box-shadow: 0 5px 0 var(--orange); }

.stamp { display: inline-block; margin: 0 6px 6px 0; padding: 3px 7px 2px; border: 2px solid var(--orange-ink); color: var(--orange-ink); font: 400 0.8rem/1 var(--stamp); text-transform: uppercase; letter-spacing: 0.06em; transform: rotate(-2deg); background: rgba(255, 115, 0, 0.08); }
.stamp--fits { border-color: var(--ink); color: var(--ink); background: var(--orange); transform: rotate(1.5deg); }

/* ---------- drawings ---------- */
.drawing { width: 100%; height: auto; overflow: visible; }
.drawing .ink { fill: none; stroke: var(--ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.drawing .ink.thick { stroke-width: 6; opacity: .35; }
.drawing .hatch { stroke: var(--ink); stroke-width: 1; opacity: .5; }
.drawing .dim path, .drawing .mark, .drawing .lead, .drawing .flow { fill: none; stroke: var(--orange); stroke-width: 2; stroke-linecap: round; }
.drawing .flow { stroke-dasharray: 5 6; stroke-width: 2.4; }
.drawing text { font-family: var(--mono); font-size: 10.5px; fill: var(--ink-2); }
.drawing .label { font-size: 13px; fill: var(--ink); font-weight: 800; }
.drawing .dim text { fill: var(--orange-ink); font-weight: 700; }
/* drawings sit on drafting sheets: off-white with a ruled frame inside the edge */
.figure { margin: 28px 0; padding: 24px 24px 16px; background: #fdfdfb; border: 1px solid var(--ink); outline: 1px solid var(--ink); outline-offset: -8px; max-width: 600px; box-shadow: 0 12px 22px -18px rgba(0, 0, 0, 0.6); }
.figure .drawing { display: block; max-width: 440px; margin: 0 auto; }
/* two drawings in a row in a guide (90° then 45°, say) sit side by side on a wide screen */
@media (min-width: 900px) { .prose .figure:has(+ .figure), .prose .figure + .figure { display: inline-block; vertical-align: top; width: calc(50% - 16px); max-width: none; } .prose .figure:has(+ .figure) { margin-right: 20px; } }
.figure figcaption { font: 500 0.72rem/1.4 var(--mono); color: var(--ink-3); margin-top: 10px; }
.icon { width: 60px; height: 40px; }
.icon .ink { fill: none; stroke: var(--ink); stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- home ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); gap: clamp(24px, 4vw, 64px); align-items: center; padding: clamp(8px, 2.5vw, 36px) 0 8px; }
.hero__h { font-stretch: 75%; font-weight: 900; font-size: clamp(2.5rem, 5.4vw, 4.9rem); line-height: 0.95; letter-spacing: -0.01em; margin-bottom: 0.38em; }
/* one orange dimension under the phrase that matters, the way the drawings mark the measurement that decides fit */
.hero__h .dim { padding: 0 0.04em 0.17em; background: linear-gradient(var(--orange), var(--orange)) left bottom 0.03em / 100% 0.075em no-repeat, linear-gradient(var(--orange), var(--orange)) left bottom / 0.075em 0.36em no-repeat, linear-gradient(var(--orange), var(--orange)) right bottom / 0.075em 0.36em no-repeat; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.hero__cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 26px; margin-top: 22px; }
.hero__link { font: 800 1.1rem/1.2 var(--display); font-stretch: 88%; }
.hero__link::after { content: " \2192"; }
.hero__promises { list-style: none; margin: 22px 0 0; padding: 14px 0 0; border-top: 2px solid var(--ink); display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 22px; font: 600 0.8rem/1.35 var(--mono); color: var(--ink-2); max-width: 36rem; }
.hero__promises li { position: relative; padding-left: 16px; }
.hero__promises li::before { content: ""; position: absolute; left: 0; top: 0.42em; width: 8px; height: 8px; background: var(--orange); }
.hero__promises a { color: var(--ink); }
@media (max-width: 420px) { .hero__promises { grid-template-columns: 1fr; } }
/* the counter: a rubber mat with best sellers laid out on their trays */
.counter { position: relative; padding: 16px 16px 18px; border-radius: 10px; background-color: #2b2e32; background-image: radial-gradient(rgba(255, 255, 255, 0.075) 1px, transparent 1.3px); background-size: 9px 9px; box-shadow: inset 0 2px 0 rgba(255, 255, 255, 0.07), inset 0 -4px 0 rgba(0, 0, 0, 0.35), 0 22px 34px -22px rgba(0, 0, 0, 0.75); }
.counter__h { margin: 0 0 14px; font-size: 1rem; }
.counter__trays { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 14px; }
.tray a { --r: 0deg; display: flex; flex-direction: column; align-items: flex-start; gap: 7px; height: 100%; padding: 8px 8px 12px; background: var(--tray); border-radius: 7px; color: var(--ink); text-decoration: none; box-shadow: inset 0 0 0 1px #c3c8c4, inset 0 0 0 5px #fff, inset 0 0 0 6px #e2e5e1, 0 3px 0 #8f9590, 0 14px 18px -12px rgba(0, 0, 0, 0.8); transform: rotate(var(--r)); transition: transform 0.15s ease, box-shadow 0.15s ease; }
.tray:nth-child(1) a { --r: -1.3deg; }
.tray:nth-child(2) a { --r: 0.9deg; }
.tray:nth-child(3) a { --r: 0.5deg; }
.tray:nth-child(4) a { --r: -0.8deg; }
.tray a:hover { color: var(--ink); transform: rotate(0deg) translateY(-3px); box-shadow: inset 0 0 0 1px #c3c8c4, inset 0 0 0 5px #fff, inset 0 0 0 6px #e2e5e1, 0 0 0 3px var(--orange), 0 18px 22px -12px rgba(0, 0, 0, 0.85); }
.tray__well { position: relative; display: block; align-self: stretch; aspect-ratio: 1 / 1; background: #fff; border-radius: 4px; overflow: hidden; }
/* the price, on a price-gun sticker stuck to the corner of the tray's well */
.tray__tag { position: absolute; right: 8px; bottom: 8px; padding: 6px 9px 5px; background: var(--orange); color: var(--ink); border-radius: 3px; font: 800 0.86rem/1 var(--mono); letter-spacing: 0.02em; transform: rotate(-3deg); box-shadow: 0 1px 0 rgba(0, 0, 0, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.35); }
.tray:nth-child(even) .tray__tag { transform: rotate(2.5deg); }
.tray__well img { width: 100%; height: 100%; object-fit: contain; }
.tray__name { font: 400 0.98rem/1.22 var(--read); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tray a:hover .tray__name { text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; }

@media (max-width: 860px) { .hero { grid-template-columns: 1fr; } .counter { padding: 12px 12px 14px; } .counter__trays { gap: 12px 10px; } .tray__name { font-size: 0.9rem; } }

/* the picker is a steel plate with four screws: where the rig's joint gets set */
.picker { margin-top: 44px; padding: 26px 26px 24px; border: 1px solid #7f8581; border-radius: 4px; background-color: #d9dcd8; background-image: radial-gradient(circle at 14px 14px, #f4f5f3 0 2px, #7d837f 2.5px 4.5px, transparent 5px), radial-gradient(circle at calc(100% - 14px) 14px, #f4f5f3 0 2px, #7d837f 2.5px 4.5px, transparent 5px), radial-gradient(circle at 14px calc(100% - 14px), #f4f5f3 0 2px, #7d837f 2.5px 4.5px, transparent 5px), radial-gradient(circle at calc(100% - 14px) calc(100% - 14px), #f4f5f3 0 2px, #7d837f 2.5px 4.5px, transparent 5px), linear-gradient(160deg, #eceeeb 0%, #d4d8d4 55%, #c6cac6 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), inset 0 -2px 0 rgba(0, 0, 0, 0.12), 0 16px 26px -20px rgba(0, 0, 0, 0.7); }
.picker--fig { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 28px; align-items: start; }
.picker__drawing { margin: 0; max-width: none; }
@media (max-width: 900px) { .picker--fig { grid-template-columns: 1fr; } .picker__drawing { max-width: 460px; } }
.picker__h { margin-top: 0; margin-bottom: 14px; font-size: 1rem; }
.picker__help { color: var(--ink-2); max-width: 70ch; }
.picker__form fieldset { border: 0; margin: 0 0 18px; padding: 0 0 16px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; border-bottom: 1px solid rgba(21, 23, 26, 0.16); }
.picker__form legend { float: left; width: 100%; display: flex; align-items: center; gap: 10px; margin: 0 0 4px; font: 800 1.25rem/1.1 var(--display); font-stretch: 85%; color: var(--ink); }
.picker__hint { flex: 0 0 100%; margin: 0 0 6px; color: var(--ink-2); font-size: 1rem; line-height: 1.45; }
.step { display: inline-grid; place-items: center; width: 1.6em; height: 1.6em; border-radius: 50%; background: var(--ink); color: var(--orange); font: 800 0.8em/1 var(--display); flex: none; box-shadow: inset 0 -2px 0 rgba(255, 255, 255, 0.15); }
.picker__out { font: 500 1.08rem/1.45 var(--read); color: var(--ink); min-height: 1.4em; margin: 0 0 12px; }
.picker__out strong { font: 800 1.08rem/1.3 var(--display); font-stretch: 88%; white-space: nowrap; }
.picker__actions { display: flex; gap: 12px; flex-wrap: wrap; }
.picker__saved { margin: 12px 0 0; color: var(--ink-2); font-size: 0.95rem; }
.picker__links-h { margin: 20px 0 8px; font: 700 0.98rem/1.3 var(--display); font-stretch: 90%; color: var(--ink-2); }
.picker__links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.picker__links a { display: inline-block; padding: 9px 12px; border: 2px solid var(--ink); border-radius: 2px; font: 600 0.76rem/1 var(--mono); text-decoration: none; color: var(--ink); background: var(--tray); }
.picker__links a:hover { background: var(--orange); }

.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 8px 12px; border: 2px solid var(--ink); border-radius: 3px; font: 600 0.76rem/1 var(--mono); background: var(--tray); cursor: pointer; user-select: none; box-shadow: 0 2px 0 var(--ink); }
.chip:active { transform: translateY(2px); box-shadow: none; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip:has(input:checked) { background: var(--tape); color: var(--tape-ink); }
.chip:has(input:focus-visible) { outline: 3px solid var(--orange); outline-offset: 2px; }

.drawers__list { list-style: none; margin: 18px 0 0; padding: 12px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; border-radius: 6px; background: linear-gradient(180deg, #9ca29e, #858b87); box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.4), 0 1px 0 rgba(255, 255, 255, 0.55); }
@media (max-width: 640px) { .drawers__list { grid-template-columns: repeat(2, minmax(0, 1fr)); padding: 8px; gap: 8px; } }
.drawer { height: 100%; display: flex; flex-direction: column; color: var(--ink); text-decoration: none; }
.drawer__box { position: relative; display: block; height: 150px; margin: 0 10px; padding: 12px 12px 0; overflow: hidden; border: 1px solid #676d69; border-bottom: 0; border-radius: 3px 3px 0 0; background: linear-gradient(180deg, #a9afab 0%, #c6cbc7 100%); box-shadow: inset 0 10px 14px -8px rgba(0, 0, 0, 0.55), inset 8px 0 10px -8px rgba(0, 0, 0, 0.4), inset -8px 0 10px -8px rgba(0, 0, 0, 0.4); transition: height 0.18s ease; }
.drawer__box img { width: 100%; height: 100%; object-fit: contain; object-position: center bottom; background: #fff; border-radius: 3px 3px 0 0; padding: 8px 8px 0; box-shadow: 0 -2px 6px rgba(0, 0, 0, 0.25); }
.drawer:hover .drawer__box { height: 162px; }
.drawer__front { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px 10px 14px; border: 1px solid #676d69; border-radius: 3px; background: linear-gradient(180deg, #e2e5e1 0%, #c8ccc8 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8), inset 0 -3px 0 rgba(0, 0, 0, 0.13), 0 -4px 8px -4px rgba(0, 0, 0, 0.4); position: relative; }
.drawer:hover .drawer__front { background: linear-gradient(180deg, #f0f1ef 0%, #d5d9d5 100%); }
@media (max-width: 640px) { .drawer__box { height: 104px; margin: 0 6px; padding: 8px 8px 0; } .drawer:hover .drawer__box { height: 112px; } }
.drawer:active .drawer__front { transform: translateY(1px); }
.drawer__label { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 8px; width: 100%; max-width: 260px; padding: 7px 10px; background: #fcfbf6; border: 3px solid #8b918d; border-radius: 2px; box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3); }
.drawer__label .icon { width: 34px; height: 24px; }
.drawer__name { font: 800 0.78rem/1.15 var(--mono); text-transform: uppercase; letter-spacing: 0.05em; }
.drawer__n { font: 600 0.72rem/1 var(--mono); color: var(--ink-3); }
.drawer__pull { display: block; width: 64px; height: 16px; border: 4px solid #5a5f5c; border-top: 0; border-radius: 0 0 12px 12px; box-shadow: 0 3px 3px -1px rgba(0, 0, 0, 0.35); }
.drawer:hover .drawer__pull { border-color: var(--orange-ink); }
@media (max-width: 640px) { .drawer__label { grid-template-columns: minmax(0, 1fr) auto; } .drawer__label .icon { display: none; } }
.strip { margin: 56px 0 0; padding: 18px 20px; display: flex; flex-wrap: wrap; gap: 10px 28px; background: var(--tape); color: var(--tape-ink); font: 600 0.8rem/1.4 var(--mono); }
.strip p { margin: 0; }
.strip p::before { content: "\2022  "; color: var(--orange); }

/* guides are punched reference sheets: the zinc shows through the two holes at the top */
.refs { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); gap: 18px; }
.ref a { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; height: 100%; padding: 34px 20px 20px; background-color: #fdfdfa; background-image: radial-gradient(circle, var(--zinc) 0 4.5px, #a3a9a5 5px, transparent 5.6px), radial-gradient(circle, var(--zinc) 0 4.5px, #a3a9a5 5px, transparent 5.6px); background-size: 14px 14px; background-repeat: no-repeat; background-position: calc(50% - 44px) 10px, calc(50% + 44px) 10px; border: 1px solid #b2b7b3; color: var(--ink); text-decoration: none; box-shadow: 0 12px 20px -16px rgba(0, 0, 0, 0.65); transition: transform 0.12s ease, box-shadow 0.12s ease; }
.ref a:hover { color: var(--ink); transform: translateY(-2px) rotate(-0.4deg); box-shadow: 0 16px 22px -14px rgba(0, 0, 0, 0.7); }
.ref__t { font-family: var(--display); font-stretch: 85%; font-weight: 800; font-size: 1.3rem; line-height: 1.08; }
.ref a:hover .ref__t { text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 3px; }
.ref__d { color: var(--ink-2); font-size: 0.98rem; line-height: 1.45; }
.more-link { margin-top: 18px; font: 800 1.1rem/1.2 var(--display); font-stretch: 88%; }

/* ---------- trays (product cards) ---------- */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 212px), 1fr)); gap: 16px; margin: 18px 0 0; }
@media (max-width: 480px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
/* product cards are white trays: a raised rim inside the edge, sitting on the zinc */
.card { position: relative; display: flex; flex-direction: column; background: var(--tray); border-radius: 7px; padding: 8px 8px 12px; box-shadow: inset 0 0 0 1px #b9bfbb, inset 0 0 0 5px #fff, inset 0 0 0 6px #e1e4e0, 0 3px 0 #9ba19d, 0 12px 18px -14px rgba(0, 0, 0, 0.7); transition: transform 0.12s ease, box-shadow 0.12s ease; }
.card:hover { transform: translateY(-3px); box-shadow: inset 0 0 0 1px #b9bfbb, inset 0 0 0 5px #fff, inset 0 0 0 6px #e1e4e0, 0 0 0 3px var(--orange), 0 16px 22px -14px rgba(0, 0, 0, 0.75); }
.card__link { color: var(--ink); text-decoration: none; display: block; }
.card__link::after { content: ""; position: absolute; inset: 0; }
.card__photo { display: block; aspect-ratio: 1 / 1; background: #fff; margin: 0 0 10px; border-radius: 4px; overflow: hidden; }
.card__photo img { width: 100%; height: 100%; object-fit: contain; }
.card__name { font-family: var(--read); font-weight: 400; font-size: 1rem; line-height: 1.25; margin: 0 0 8px; }
.card:hover .card__name { text-decoration: underline; text-decoration-color: var(--orange); text-decoration-thickness: 2px; }
.card__price { margin: 0 0 8px; font: 800 0.88rem/1 var(--mono); }
.card__joints { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-wrap: wrap; gap: 5px; position: relative; }

.card__spec { margin: 0 0 6px; font: 600 0.74rem/1.4 var(--mono); color: var(--ink-2); }
.card__spec--joints { color: var(--ink); }
.card__stamps { margin: auto 0 0; }
.card .stamp { font-size: 0.68rem; }

/* ---------- category ---------- */
.cat__head { display: grid; grid-template-columns: minmax(0, 1fr); gap: 28px; align-items: end; padding-bottom: 20px; border-bottom: 3px solid var(--ink); }
.cat__head:has(.cat__drawing) { grid-template-columns: minmax(0, 1fr) minmax(0, 420px); }
.cat__drawing { margin: 0; }
@media (max-width: 860px) { .cat__head { grid-template-columns: 1fr; } .cat__drawing { max-width: 420px; } }
.filters { margin: 18px 0 8px; display: grid; gap: 10px; }
.filters fieldset { border: 0; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.filters legend { float: left; width: 9.5em; font: 800 0.92rem/2.5 var(--display); font-stretch: 88%; color: var(--ink); }
.filters__count { font: 600 0.8rem/1.3 var(--mono); color: var(--ink-2); margin: 4px 0 0; }
.filters__hint { margin: 0; color: var(--ink-2); font-size: 0.95rem; }
.filters__rig { margin: 0 0 4px; }
.btn--small { min-height: 42px; padding: 9px 14px; font-size: 0.95rem; box-shadow: 0 3px 0 var(--ink); }
.opts__hint { flex: 0 0 100%; margin: -4px 0 4px; color: var(--ink-2); font-size: 0.95rem; }
.fit-help { margin: -4px 0 14px; font-size: 0.95rem; color: var(--ink-2); }
.fitlinks--go a { padding: 11px 14px; font: 800 0.98rem/1.2 var(--display); font-stretch: 88%; background: var(--orange); }

/* ---------- product page ---------- */
/* the name and price come first on a phone; on a wide screen they head the right-hand column above the buy box */
.pdp { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr); grid-template-areas: "photos head" "photos buy"; grid-template-rows: auto 1fr; column-gap: clamp(20px, 4vw, 56px); align-items: start; }
.pdp__head { grid-area: head; }
.pdp__buy { grid-area: buy; }
.pdp__photos { grid-area: photos; position: sticky; top: 12px; }
@media (max-width: 900px) { .pdp { grid-template-columns: 1fr; grid-template-areas: "head" "photos" "buy"; grid-template-rows: none; row-gap: 14px; } .pdp__title { font-size: clamp(1.7rem, 7vw, 2.4rem); } .gallery__dots { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; } .gallery__dots li { flex: 0 0 auto; } }
@media (max-width: 900px) { .pdp__photos { position: static; } }
.gallery { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; background: #fff; border-radius: 8px; padding: 8px; box-shadow: inset 0 0 0 1px #b9bfbb, inset 0 0 0 5px #fff, inset 0 0 0 6px #e1e4e0, 0 3px 0 #9ba19d, 0 16px 24px -18px rgba(0, 0, 0, 0.7); scrollbar-width: thin; }
.gallery__item { flex: 0 0 100%; margin: 0; scroll-snap-align: start; aspect-ratio: 1 / 1; display: grid; place-items: center; background: #fff; }
.gallery__item img { width: 100%; height: 100%; object-fit: contain; }
.gallery__dots { list-style: none; margin: 16px 0 0; padding: 0; display: flex; gap: 8px; flex-wrap: wrap; }
.gallery__dots a { display: block; width: 72px; height: 72px; padding: 3px; border: 2px solid var(--steel); border-radius: 4px; background: #fff; overflow: hidden; }
.gallery__dots a:hover, .gallery__dots a.is-on { border-color: var(--ink); }
.gallery__dots img { width: 100%; height: 100%; object-fit: contain; filter: contrast(1.25); }
.pdp__title { font-size: clamp(2rem, 3.8vw, 3.2rem); }
.pdp__price { font: 800 1.3rem/1 var(--mono); margin: 0 0 12px; }
.buy { margin-top: 16px; padding: 20px; border: 1px solid #7f8581; border-radius: 4px; background: linear-gradient(160deg, #f1f2f0 0%, #dfe2de 60%, #d3d7d3 100%); box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85), inset 0 -2px 0 rgba(0, 0, 0, 0.1), 0 16px 26px -20px rgba(0, 0, 0, 0.7); }
.opts { border: 0; margin: 0 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.opts legend { width: 100%; margin-bottom: 10px; font: 800 1rem/1 var(--display); font-stretch: 88%; color: var(--ink); }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; }
.opt span { display: inline-block; min-height: 40px; padding: 11px 12px; border: 2px solid var(--ink); border-radius: 3px; font: 600 0.76rem/1 var(--mono); background: var(--tray); cursor: pointer; box-shadow: 0 2px 0 var(--ink); }
.opt input:checked + span { background: var(--tape); color: var(--tape-ink); }
.opt input:focus-visible + span { outline: 3px solid var(--orange); outline-offset: 2px; }
.fitline { margin: 6px 0 14px; padding: 12px 14px; background: linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0, rgba(255, 255, 255, 0) 38%, rgba(0, 0, 0, 0.3) 100%), var(--tape); color: var(--tape-ink); font: 700 0.82rem/1.45 var(--mono); letter-spacing: 0.02em; border-left: 6px solid var(--orange); text-shadow: 0 1px 0 rgba(0, 0, 0, 0.9); }
.btn--bag { width: 100%; font-size: 0.92rem; min-height: 56px; }
.buynow { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 6px; }
.buynow li { display: flex; justify-content: space-between; gap: 10px; padding: 9px 0; border-bottom: 2px solid var(--zinc); font: 600 0.8rem/1.3 var(--mono); }
.js .buynow { display: none; }
.buy__notes { list-style: none; margin: 16px 0 0; padding: 0; font: 500 0.76rem/1.5 var(--mono); color: var(--ink-2); }
.buy__notes li { padding-left: 16px; position: relative; margin-bottom: 5px; }
.buy__notes li::before { content: "\2022"; position: absolute; left: 2px; color: var(--orange-ink); }
.buy__notes strong { color: var(--ink); }
.buy__checkout { margin: 12px 0 0; font: 400 0.7rem/1.5 var(--mono); color: var(--ink-3); }
.fitlinks { margin-top: 18px; }
.fitlinks__h { margin: 0 0 8px; font: 700 0.98rem/1.3 var(--display); font-stretch: 90%; color: var(--ink-2); }
.fitlinks ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.fitlinks a { display: inline-block; padding: 8px 11px; border: 2px solid var(--ink); border-radius: 3px; background: var(--tray); color: var(--ink); text-decoration: none; font: 600 0.78rem/1 var(--mono); box-shadow: 0 2px 0 var(--ink); }
.fitlinks a:hover { background: var(--orange); color: var(--ink); }
.spec__tapes { list-style: none; margin: 0; padding: 2px 0; display: flex; flex-wrap: wrap; gap: 8px 6px; }

.facts, .box, .fitswith, .qa, .set, .sources { margin-top: 52px; }
.facts h2, .box h2, .fitswith h2, .qa h2, .set h2, .sources h2 { display: flex; align-items: center; gap: 14px; }
.facts h2::after, .box h2::after, .fitswith h2::after, .qa h2::after, .set h2::after, .sources h2::after { content: ""; flex: 1; height: 3px; background: var(--ink); }
.spec { width: 100%; max-width: 760px; border-collapse: collapse; font: 600 0.86rem/1.4 var(--mono); background: #fdfdfa; border: 1px solid #b2b7b3; border-top: 4px solid var(--ink); box-shadow: 0 12px 20px -16px rgba(0, 0, 0, 0.6); }
.spec th, .spec td { text-align: left; vertical-align: top; padding: 11px 12px; border-bottom: 2px solid var(--zinc); }
.spec th { width: 34%; font: 700 0.95rem/1.35 var(--display); font-stretch: 90%; color: var(--ink-3); }
.box ul { margin: 0; padding-left: 1.2em; }
.set__row { margin: 0 0 8px; padding-left: 1.3em; font: 600 0.84rem/1.8 var(--mono); }
.set__total { font: 800 0.9rem/1.4 var(--mono); }
.qa__item { border-bottom: 2px solid var(--hair); padding: 14px 0; max-width: 760px; }
.qa__item summary { cursor: pointer; font-family: var(--display); font-stretch: 90%; font-weight: 800; font-size: 1.08rem; }
.qa__item p { margin: 10px 0 0; }

/* ---------- Fit Index ---------- */
.joint__head { padding-bottom: 18px; border-bottom: 3px solid var(--ink); }
/* the Fit Index's own header is the title sheet of the chart, pinned up like the tables below it */
.fit__head { position: relative; padding: 34px clamp(20px, 4vw, 44px) 26px; background: #fdfdfa; border: 1px solid #b2b7b3; box-shadow: 0 16px 26px -20px rgba(0, 0, 0, 0.65); }
.fit__head::before, .fit__head::after { content: ""; position: absolute; top: 10px; width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffc49a 0, var(--orange) 45%, #a84a00 100%); box-shadow: 0 2px 2px rgba(0, 0, 0, 0.35); }
.fit__head::before { left: 12px; }
.fit__head::after { right: 12px; }
.fit__head .lede { margin-bottom: 0; }
.joint-pages { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.joint-pages a { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; padding: 14px; border: 1px solid #b2b7b3; border-top: 6px solid var(--ink); border-radius: 3px; background: #fdfdfa; color: var(--ink); text-decoration: none; box-shadow: 0 10px 18px -14px rgba(0, 0, 0, 0.6); transition: transform 0.12s ease, border-color 0.12s ease; }
.joint-pages a:hover { color: var(--ink); border-top-color: var(--orange); transform: translateY(-2px); }
.jp__k { grid-row: span 2; font-family: var(--display); font-stretch: 75%; font-weight: 900; font-size: 2.7rem; line-height: 0.88; }
.jp__k small, .joint__big small { font-size: 0.38em; font-stretch: 90%; margin-left: 2px; }
.jp__t { font: 800 1.02rem/1.15 var(--display); font-stretch: 88%; align-self: end; }
.jp__n { font: 500 0.7rem/1.3 var(--mono); color: var(--ink-3); }
.joint__big { display: inline-block; margin-right: 12px; padding: 0 0.08em; background: var(--orange); font-stretch: 75%; font-weight: 900; font-size: 1.2em; }
/* the Fit Index tables are charts pinned up behind the counter: paper, two orange pins, thin rules */
.table-wrap { position: relative; overflow-x: auto; margin: 16px 0; background: #fdfdfa; border: 1px solid #b2b7b3; box-shadow: 0 14px 24px -18px rgba(0, 0, 0, 0.65); }
.table-wrap::before, .table-wrap::after { content: ""; position: absolute; top: 8px; width: 11px; height: 11px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffc49a 0, var(--orange) 45%, #a84a00 100%); box-shadow: 0 2px 2px rgba(0, 0, 0, 0.35); }
.table-wrap::before { left: 9px; }
.table-wrap::after { right: 9px; }
.fit-table { width: 100%; border-collapse: collapse; font: 600 0.78rem/1.35 var(--mono); }
.fit-table caption { caption-side: top; text-align: left; padding: 14px 30px 10px; font: 400 0.95rem/1.4 var(--read); color: var(--ink-2); border-bottom: 1px solid #cfd3cf; }
.fit-table th { position: sticky; top: 0; background: var(--tape); color: var(--tape-ink); text-align: left; padding: 10px; font: 700 0.86rem/1.2 var(--display); font-stretch: 88%; white-space: nowrap; }
.fit-table td { padding: 9px 10px; border-bottom: 1px solid #dcdfdb; vertical-align: top; }
.fit-table tr.grp td { border-top: 3px solid var(--ink); }
.fit-table td:first-child { white-space: nowrap; font-weight: 800; }

/* ---------- guides and static pages ---------- */
.guide { max-width: 980px; }
.guide__head { padding-bottom: 18px; border-bottom: 3px solid var(--ink); margin-bottom: 28px; }
.guide__meta { font: 600 0.92rem/1.3 var(--display); font-stretch: 90%; color: var(--ink-3); }
.prose { font-size: 1.12rem; line-height: 1.62; }
.prose > p, .prose > ul, .prose > ol, .prose > h2, .prose > h3 { max-width: 68ch; }
.prose h2 { margin-top: 1.8em; }
.prose h3 { margin-top: 1.4em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: 0.35em; }
.prose strong { font-weight: 400; background: var(--orange-tint); padding: 0 0.15em; }
.prose .grid { margin: 18px 0 26px; }
.sources ol { font: 400 0.98rem/1.45 var(--read); padding-left: 1.4em; }
.sources li { margin-bottom: 10px; }
.sources a { display: inline-block; padding: 3px 0; }
.contact { display: grid; gap: 8px; max-width: 560px; margin-top: 20px; }
.contact label { font: 800 1rem/1 var(--display); font-stretch: 88%; color: var(--ink); margin-top: 10px; }
.contact input, .contact textarea { font: 400 1rem/1.4 var(--read); padding: 12px; border: 2px solid var(--ink); border-radius: 2px; background: var(--tray); color: var(--ink); }
.contact button { justify-self: start; margin-top: 12px; }
.contact__msg { font: 700 0.84rem/1.45 var(--mono); min-height: 1.4em; margin: 6px 0 0; }
.contact .cf-turnstile { margin-top: 12px; min-height: 65px; }
.contact__direct { margin-top: 18px; color: var(--ink-2); }
.nf__big { font: 900 clamp(6rem, 22vw, 14rem)/0.82 var(--display); font-stretch: 75%; margin: 20px 0 6px; }
.nf__big span { background: var(--orange); padding: 0 0.04em; }

/* ---------- footer ---------- */
.foot { background: var(--tape); color: var(--tape-ink); padding: 40px var(--gutter) 44px; }
.foot a { color: var(--tape-ink); text-decoration-color: var(--orange); }
.foot a:hover { color: var(--orange); }
.foot__grid { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 2fr repeat(3, 1fr); gap: 24px; }
@media (max-width: 760px) { .foot__grid { grid-template-columns: 1fr 1fr; } }
.foot__mark { font-family: var(--display); font-stretch: 75%; font-weight: 900; font-size: 1.7rem; text-transform: uppercase; margin: 0 0 8px; }
.foot__line { color: #c9ccc9; max-width: 40ch; }
.foot__h { font: 800 1rem/1 var(--display); font-stretch: 88%; color: #aeb3ae; margin: 0 0 14px; }
.foot ul { list-style: none; margin: 0; padding: 0; }
.foot li { margin-bottom: 8px; }
.foot__age { max-width: var(--max); margin: 30px auto 6px; font: 800 0.8rem/1.4 var(--mono); color: var(--orange); }
.foot__small { max-width: var(--max); margin: 0 auto; font: 400 0.72rem/1.55 var(--mono); color: #c9ccc9; }

/* ---------- bag drawer and age check (added by script) ---------- */
dialog { border: 2px solid var(--ink); background: var(--tray); color: var(--ink); padding: 0; }
dialog::backdrop { background: rgba(21, 23, 26, 0.6); }
.bag { width: min(440px, 100vw); max-width: 100vw; height: 100dvh; max-height: 100dvh; margin: 0 0 0 auto; border-width: 0 0 0 3px; display: flex; flex-direction: column; }
.bag:not([open]) { display: none; }
.bag__head { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; background: var(--tape); color: var(--tape-ink); }
.bag__head h2 { margin: 0; color: var(--tape-ink); }
.bag__close { background: var(--tray); border: 2px solid var(--tray); border-radius: 3px; min-height: 38px; padding: 8px 14px; font: 800 0.95rem/1 var(--display); font-stretch: 88%; cursor: pointer; color: var(--ink); }
.bag__body { display: flex; flex-direction: column; flex: 1; min-height: 0; }
.bag__lines { list-style: none; margin: 0; padding: 8px 18px; overflow-y: auto; flex: 0 1 auto; min-height: 0; }
.bag__more { flex: 0 0 auto; padding: 2px 18px 14px; }
.bag__more-h { margin: 10px 0 8px; font: 800 0.95rem/1.2 var(--display); font-stretch: 88%; color: var(--ink); }
.bag__more ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.bag__more-row { display: grid; grid-template-columns: 48px 1fr auto; gap: 10px; align-items: center; padding: 8px; background: var(--tray); border: 1px solid #c3c8c4; border-radius: 4px; }
.bag__more-row img { width: 48px; height: 48px; object-fit: contain; background: #fff; }
.bag__more-info a { display: block; font-size: 0.9rem; line-height: 1.25; color: var(--ink); text-decoration: none; }
.bag__more-price { font: 700 0.74rem/1.4 var(--mono); color: var(--ink-2); }
.bag__more-price em { display: block; font-style: normal; color: var(--orange-ink); }
.bag__more-btn { display: inline-flex; align-items: center; min-height: 38px; padding: 0 12px; border: 2px solid var(--ink); border-radius: 2px; background: var(--orange); color: var(--ink); font: 800 0.88rem/1 var(--display); font-stretch: 88%; text-decoration: none; cursor: pointer; white-space: nowrap; }
.bag__more-btn:hover { color: var(--ink); }
.bag__line { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; padding: 14px 0; border-bottom: 2px solid var(--zinc); align-items: start; }
.bag__line img { width: 64px; height: 64px; object-fit: contain; background: #fff; border: 2px solid var(--zinc); }
.bag__name { font-size: 0.98rem; line-height: 1.25; display: block; color: var(--ink); text-decoration: none; }
.bag__var { font: 600 0.74rem/1.3 var(--mono); color: var(--ink-3); }
.bag__qty { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; }
.bag__qty button, .bag__rm { border: 2px solid var(--ink); background: var(--zinc); border-radius: 2px; min-width: 34px; min-height: 34px; font: 800 0.85rem/1 var(--mono); cursor: pointer; color: var(--ink); }
.bag__rm { padding: 0 10px; font: 700 0.85rem/1 var(--display); font-stretch: 88%; }
.bag__price { font: 800 0.86rem/1 var(--mono); }
.bag__foot { margin-top: auto; padding: 16px 18px 20px; border-top: 3px solid var(--ink); background: var(--zinc); }
.bag__sum { display: flex; justify-content: space-between; font: 800 1rem/1 var(--mono); margin-bottom: 10px; }
.bag__ship { font: 700 0.78rem/1.4 var(--mono); margin: 0 0 6px; }
.bag__bar { height: 10px; border: 2px solid var(--ink); background: var(--tray); margin: 0 0 12px; }
.bag__bar span { display: block; height: 100%; background: var(--orange); }
.bag__notes { list-style: none; margin: 0 0 12px; padding: 0; font: 500 0.74rem/1.55 var(--mono); color: var(--ink-2); }
.bag__notes li::before { content: "\2022  "; color: var(--orange-ink); }
.bag__go { width: 100%; }
.bag__empty { padding: 24px 18px; color: var(--ink-2); }
.bagpage .bag__lines { padding-left: 0; padding-right: 0; }
.gate { max-width: min(470px, calc(100vw - 32px)); padding: 0; text-align: left; box-shadow: 10px 10px 0 var(--orange); }
.gate .gate__top { margin: 0; background: var(--tape); color: var(--tape-ink); padding: 12px 22px; font: 700 0.7rem/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; }
.gate__body { padding: 22px 22px 24px; }
.gate h2 { font-size: 2.3rem; margin-bottom: 10px; }
.gate p { color: var(--ink-2); }
.gate__btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); background: var(--tape); color: var(--tape-ink); padding: 12px 16px; font: 700 0.78rem/1.3 var(--mono); border-radius: 2px; box-shadow: 0 4px 0 var(--orange); z-index: 60; }

@media (prefers-reduced-motion: reduce) {
  @view-transition { navigation: none; }
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
  .card:hover, .btn:hover, .joint-pages a:hover { transform: none; }
}
@media print {
  .top, .foot, .buy, .picker, .filters, .sign { display: none; }
  body { background: #fff; }
}

/* ---------- fixes from the round 1 pre-check ---------- */
/* Azeret Mono's fi ligature reads as "fı": no ligatures anywhere the mono face is used */
.tape, .sign, .nav a, .rigchip, .bagbtn, .btn, .crumbs, .note, .card__price, .card__joints, .card__spec, .stamp,
.chip, .opt span, .fitline, .buynow, .buy__notes, .buy__checkout, .spec, .fit-table, .figure figcaption, .drawing text,
.bag, .gate__top, .toast, .picker__out, .filters, .sources, .guide__meta, .jp__t, .jp__n, .foot__h, .foot__small, .foot__age,
.prose table, .kicker, .drawer__n, .drawer__name, .set__row, .set__total, .contact label, .picker__links a, .tray__price, .hero__link, .hero__promises, .more-link { font-variant-ligatures: none; font-feature-settings: "liga" 0, "calt" 0; }

/* only with JavaScript: the variant radios and the fit line that follows them */
html:not(.js) .js-only { display: none !important; }
.buynow ul { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 6px; }
.buynow li { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 9px 0; border-bottom: 2px solid var(--zinc); font: 600 0.8rem/1.3 var(--mono); }
.buynow__fit { grid-column: 1 / -1; font-weight: 500; font-size: 0.72rem; color: var(--ink-2); }

/* plain Markdown tables in guides (the Side by side comparisons) look like the fit tables */
.prose table { width: 100%; max-width: 860px; border-collapse: collapse; margin: 18px 0 26px; background: #fdfdfa; border: 1px solid #b2b7b3; box-shadow: 0 14px 24px -18px rgba(0, 0, 0, 0.6); font: 500 0.82rem/1.4 var(--mono); }
.prose table caption { caption-side: top; text-align: left; padding: 12px 12px 10px; font: 400 0.95rem/1.4 var(--read); color: var(--ink-2); border-bottom: 1px solid #cfd3cf; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid #dcdfdb; }
.prose thead th { background: var(--tape); color: var(--tape-ink); font: 700 0.9rem/1.2 var(--display); font-stretch: 88%; }
.prose tbody td:first-child, .prose tbody th { font-weight: 800; color: var(--ink); width: 28%; text-align: left; }
.prose tbody tr:nth-child(even) td, .prose tbody tr:nth-child(even) th { background: #f7f8f6; }

/* Fit Index: one header row per joint */
.fit-table tr.grp-h th { background: var(--zinc-2); color: var(--ink); text-transform: none; letter-spacing: 0; font: 600 0.95rem/1.5 var(--display); font-stretch: 92%; padding: 12px 10px; border-top: 3px solid var(--ink); white-space: normal; position: static; }
.fit-table tr.grp-h .tape { margin-right: 6px; }

/* phones: wrap names, drop the columns a phone doesn't need, keep tables inside the screen */
@media (max-width: 700px) {
  .fit-table td:first-child { white-space: normal; min-width: 10em; }
  .fit-table { font-size: 0.72rem; }
  .fit-table th, .fit-table td { padding: 8px 7px; }
  .col-opt { display: none; }
  .prose table { font-size: 0.74rem; }
  .prose th, .prose td { padding: 8px; }
  .cat__drawing { display: none; }
  .filters fieldset { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 6px; scrollbar-width: thin; }
  .filters legend { float: none; width: auto; margin-right: 6px; }
  .filters .chip { flex: 0 0 auto; }
  .picker__form .chip { flex: 1 1 auto; justify-content: center; }
  .picker { padding: 22px 16px 20px; }
}


/* joint pages: notes beside the drawing */
.joint-notes__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: 28px; align-items: start; }
.joint-notes__grid p { max-width: 60ch; }
.joint-notes .figure { margin: 0; }
@media (max-width: 860px) { .joint-notes__grid { grid-template-columns: 1fr; } }
.guides-mini ul { padding-left: 1.2em; }
.guides-mini li { margin-bottom: 6px; }

/* the three best sellers under the drawers fill their row instead of leaving most of it empty */
.picks .grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); max-width: 980px; }
@media (max-width: 480px) { .picks .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* guide tables on a phone: one small card per row, the first cell as its heading, then label and value */
@media (max-width: 700px) {
  .table-wrap--stack { overflow: visible; background: none; border: 0; box-shadow: none; }
  .table-wrap--stack::before, .table-wrap--stack::after { display: none; }
  .fit-table--stack, .fit-table--stack tbody, .fit-table--stack tr, .fit-table--stack td { display: block; width: 100%; }
  .fit-table--stack caption { display: block; padding: 0 0 10px; border: 0; font-size: 0.95rem; }
  .fit-table--stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .fit-table--stack tr { margin: 0 0 10px; padding: 10px 12px 8px; background: #fdfdfa; border: 1px solid #b2b7b3; border-top: 4px solid var(--ink); box-shadow: 0 10px 18px -16px rgba(0, 0, 0, 0.6); }
  .fit-table--stack td { padding: 4px 0; border: 0; display: grid; grid-template-columns: minmax(6.5em, 34%) minmax(0, 1fr); gap: 10px; font-size: 0.8rem; }
  .fit-table--stack td::before { content: attr(data-label); font: 700 0.86rem/1.35 var(--display); font-stretch: 88%; color: var(--ink-3); }
  .fit-table--stack td:first-child { display: block; padding: 0 0 6px; font: 400 1.02rem/1.3 var(--read); white-space: normal; min-width: 0; }
  .fit-table--stack td:first-child::before { content: none; }
  .fit-table--stack td[data-empty] { display: none; }
}

/* a data table inside a guide is already on its pinned sheet: no second border, width cap or row tint from .prose */
.prose .table-wrap table { max-width: none; margin: 0; border: 0; box-shadow: none; background: none; }
.prose .table-wrap tbody tr:nth-child(even) td { background: none; }
.prose .table-wrap tbody td:first-child { width: auto; }
@media (max-width: 700px) {
  .fit-table--stack td:first-child { width: 100%; }
  .fit-table--stack tbody tr:nth-child(even) td { background: none; }
}
.prose .table-wrap caption { padding: 14px 30px 10px; }
/* names wrap in their own column, which leaves the short values room to stay on one line */
@media (min-width: 701px) {
  .fit-table td:first-child { white-space: normal; min-width: 12em; max-width: 24em; }
}

/* Fit Index: links to each table, and the picker folded into one line */
.jump { margin: 22px 0 0; }
.jump ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.jump a { display: inline-block; padding: 8px 12px; border: 2px solid var(--ink); border-radius: 3px; background: var(--tray); color: var(--ink); text-decoration: none; font: 700 0.95rem/1 var(--display); font-stretch: 88%; box-shadow: 0 2px 0 var(--ink); }
.jump a:hover { background: var(--orange); color: var(--ink); }
.picker-fold { margin-top: 26px; }
.picker-fold > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 12px; padding: 14px 18px; border: 1px solid #7f8581; border-radius: 4px; background: linear-gradient(160deg, #eceeeb 0%, #d4d8d4 100%); font: 800 1.05rem/1.3 var(--display); font-stretch: 88%; color: var(--ink); }
.picker-fold > summary::-webkit-details-marker { display: none; }
.picker-fold > summary::before { content: "+"; display: inline-grid; place-items: center; width: 1.5em; height: 1.5em; flex: none; border-radius: 50%; background: var(--ink); color: var(--orange); font: 800 1rem/1 var(--mono); }
.picker-fold[open] > summary::before { content: "\2212"; }
.picker-fold[open] > summary { border-radius: 4px 4px 0 0; border-bottom: 0; }
.picker-fold .picker { margin-top: 0; border-radius: 0 0 4px 4px; }
