/* Article: can a mine search its own technical records offline? Tokens, header, footer, contents row, chips and buttons come from /site.css. */

/* cover: the article's core in its tray */
.tray { margin-top: clamp(8px, 2vw, 20px); }
.tray .ticks {
  height: 12px;
  background:
    repeating-linear-gradient(to right, rgb(var(--ink) / .55) 0 1px, transparent 1px 60px) left bottom / 100% 12px no-repeat,
    repeating-linear-gradient(to right, rgb(var(--ink) / .28) 0 1px, transparent 1px 12px) left bottom / 100% 6px no-repeat;
}
.tray .cover { display: block; width: 100%; height: clamp(56px, 9vw, 96px); object-fit: cover; background: rgb(var(--sand-light)); }
.traymeta { display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 10px 0 0; }
.traymeta b { color: rgb(var(--brand)); font-weight: 600; }
.tagrow { margin-top: 12px; }

.opening { padding: clamp(20px, 4vw, 40px) 0 clamp(8px, 2vw, 16px); }
.opening h1 { margin: 0; max-width: 21ch; font-size: clamp(30px, 4.8vw, 52px); line-height: 1.02; letter-spacing: -.038em; font-weight: 700; text-wrap: balance; }
.basis { margin: clamp(18px, 3vw, 28px) 0 0; }
.intro { margin: 10px 0 0; max-width: 40ch; font-size: clamp(18px, 2.4vw, 23px); line-height: 1.34; letter-spacing: -.012em; font-weight: 500; }
.intro mark { background: none; color: rgb(var(--brand)); white-space: nowrap; }

/* big numbers */
.stats { list-style: none; margin: clamp(26px, 4vw, 44px) 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 0 28px; border-top: 1px solid rgb(var(--ink)); }
.stats li { padding: 14px 0 16px; border-bottom: 1px solid rgb(var(--ink) / .14); }
.stats b { display: block; font-size: clamp(34px, 5.4vw, 52px); line-height: 1.05; letter-spacing: -.035em; font-weight: 700; color: rgb(var(--brand)); white-space: nowrap; }
.stats span { display: block; margin-top: 6px; max-width: 26ch; font-size: 14.5px; line-height: 1.4; color: rgb(var(--ink) / .78); }

section.block > h2 { max-width: 22ch; }
section.block > p.lede a, .repo a { color: rgb(var(--brand)); }
.lede, .intro, .stats span, .says, .pair p, .checks li, .plotcap { text-wrap: pretty; }
.says { margin: 18px 0 0; max-width: 62ch; padding-left: 14px; border-left: 3px solid rgb(var(--brand)); font-size: clamp(15.5px, 1.9vw, 17.5px); line-height: 1.5; }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 8px 44px; margin-top: clamp(22px, 4vw, 36px); }
.pair h3 { margin: 0 0 6px; font-size: 17px; letter-spacing: -.01em; }
.pair p { margin: 0 0 12px; max-width: 46ch; color: rgb(var(--ink) / .78); font-size: 15.5px; }
.pair code, .says code, .lede code { font: 500 .92em/1 var(--mono); color: rgb(var(--ink)); }

/* figure panels */
.plot picture, .plot img, .plot svg { display: block; width: 100%; height: auto; }
.plotcap { max-width: 62ch; font-size: 13.5px; line-height: 1.45; color: rgb(var(--ink) / .68); }
.trend { margin-top: clamp(22px, 4vw, 36px); border: 1px solid rgb(var(--ink) / .16); background: #fff; }
.trend-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 18px; padding: 11px clamp(12px, 2.4vw, 20px); background: rgb(var(--ink)); color: rgb(var(--paper)); }
.tagname, .readout { font: 500 12px/1.4 var(--mono); letter-spacing: .08em; text-transform: uppercase; }
.tagname { color: rgb(var(--paper) / .72); }
.readout { color: rgb(var(--coral)); }
.plot { padding: clamp(6px, 1.6vw, 14px); }
.trend .plotcap { margin: 0; padding: 0 clamp(12px, 2.4vw, 20px) 14px; }

.controls { display: flex; flex-wrap: wrap; align-items: end; gap: 14px 28px; padding: 14px clamp(12px, 2.4vw, 20px) 4px; }
.controls[hidden] { display: none; }
.ctl { display: grid; gap: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chips button { padding: 9px 15px; border: 1px solid rgb(var(--ink) / .25); border-radius: 999px; background: transparent; color: inherit; font: 600 13px/1 var(--mono); cursor: pointer; transition: background .2s ease, color .2s ease, border-color .2s ease; }
.chips button:hover { border-color: rgb(var(--ink)); }
.chips button[aria-pressed="true"] { background: rgb(var(--brand)); border-color: rgb(var(--brand)); color: #fff; }
.chips button:focus-visible { outline: 2px solid rgb(var(--brand)); outline-offset: 3px; }


/* 01: the passage behind the picked part */
.passage { margin: 0; padding: 4px clamp(12px, 2.4vw, 20px) 16px; }
.passage p { margin: 0; max-width: 64ch; font-size: clamp(15.5px, 1.9vw, 17px); line-height: 1.5; padding-left: 14px; border-left: 3px solid rgb(var(--brand)); }
.passage cite { display: block; margin-top: 8px; padding-left: 17px; font: 500 12px/1.5 var(--mono); letter-spacing: .04em; font-style: normal; color: rgb(var(--ink) / .66); }

/* 02: the replayed lists */
.ask { margin: 0; padding: 14px clamp(12px, 2.4vw, 20px) 4px; font-size: 15.5px; line-height: 1.45; font-weight: 600; }
.hits { list-style: none; counter-reset: h; margin: 0; padding: 6px clamp(12px, 2.4vw, 20px) 14px; }
.hits li { counter-increment: h; display: grid; grid-template-columns: 30px 1fr; gap: 0 10px; padding: 11px 0; border-top: 1px solid rgb(var(--ink) / .1); }
.hits li:first-child { border-top: 0; }
.hits li::before { content: counter(h); grid-row: span 3; font: 600 15px/1.4 var(--mono); color: rgb(var(--ink) / .66); }
.hits li.hit::before { color: rgb(var(--brand)); }
.hits .src { font: 500 12px/1.5 var(--mono); letter-spacing: .04em; color: rgb(var(--ink) / .66); }
.hits .snip { margin: 2px 0 0; font-size: 15px; line-height: 1.45; overflow-wrap: anywhere; }
.hits .snip.said { font-style: italic; color: rgb(var(--ink) / .8); }
.hits .snip.said::before { content: "In our words: "; font-style: normal; font: 500 12px/1.4 var(--mono); letter-spacing: .04em; color: rgb(var(--ink) / .72); }
.hits .mark { display: inline-block; margin-top: 6px; padding: 2px 8px; border-radius: 999px; background: rgb(var(--brand)); color: #fff; font: 600 12px/1.5 var(--mono); letter-spacing: .03em; justify-self: start; }
.hits .mark.wrong, .hits .mark.decoy { background: rgb(var(--sand)); color: rgb(var(--ink)); }
.hits .gap { grid-template-columns: 1fr; }
.hits .gap::before { content: none; }
.hits .gap p { margin: 0; font: 600 13px/1.5 var(--mono); color: rgb(var(--brand)); }

/* 05: what to do */
.checks { list-style: none; counter-reset: c; margin: clamp(20px, 4vw, 34px) 0 0; padding: 0; border-top: 1px solid rgb(var(--ink)); }
.checks li { counter-increment: c; display: grid; grid-template-columns: clamp(44px, 8vw, 76px) 1fr; padding: 16px 0; border-bottom: 1px solid rgb(var(--ink) / .14); color: rgb(var(--ink) / .76); font-size: 15.5px; }
.checks li::before { content: counter(c, decimal-leading-zero); grid-row: span 2; font: 500 13px/1.7 var(--mono); color: rgb(var(--brand)); }
.checks b { display: block; color: rgb(var(--ink)); font-size: clamp(17px, 2.4vw, 21px); letter-spacing: -.012em; font-weight: 600; }


/* method and sources */
.method .pair p b { color: rgb(var(--ink)); }
.repo { margin: 18px 0 0; max-width: 62ch; font-size: 14.5px; color: rgb(var(--ink) / .7); }

.cta { margin-top: clamp(44px, 9vw, 96px); padding: clamp(24px, 5vw, 52px); background: rgb(var(--ink)); color: rgb(var(--paper)); }
.cta .label { color: rgb(var(--paper) / .72); }
.cta h2 { margin: 8px 0 0; max-width: 20ch; font-size: clamp(26px, 4.4vw, 42px); line-height: 1.08; letter-spacing: -.03em; font-weight: 600; text-wrap: balance; }
.cta p { margin: 14px 0 22px; max-width: 44ch; color: rgb(var(--paper) / .72); }
.cta .btn { background: rgb(var(--brand)); color: #fff; }
.cta .btn:hover { background: rgb(var(--coral)); color: rgb(var(--ink)); }

/* between phone and desktop the phone figures are used, kept to a size where their text reads at 12 px or more */
@media (min-width: 601px) and (max-width: 760px) { .plot picture, .plot svg { max-width: 460px; margin: 0 auto; } }
@media (prefers-reduced-motion: reduce) { .chips button { transition: none; } }

/* sources */
.refs { margin: 18px 0 0; padding-left: 1.4em; max-width: 72ch; font-size: 14px; line-height: 1.5; color: rgb(var(--ink) / .74); }
.refs li { margin-bottom: 8px; padding-left: 4px; }
.refs a { color: rgb(var(--brand)); overflow-wrap: anywhere; }
@media (max-width: 600px) { .stats { grid-template-columns: 1fr 1fr; } }
