:root {
  --plate: #dfe5e2;
  --plate-deep: #cdd6d2;
  --sheet: #f2f5f3;
  --ink: #12303a;
  --ink-soft: #4a6169;
  --line: #b4c1bc;
  --s-emerging: #5e9c1f;
  --s-growing: #1f55c8;
  --s-peak: #bf1f79;
  --s-saturated: #b96a09;
  --s-declining: #6f7f7b;
  --focus: #1f55c8;
}
@media (prefers-color-scheme: dark) {
  :root {
    --plate: #182a30;
    --plate-deep: #203740;
    --sheet: #1f343c;
    --ink: #e6efec;
    --ink-soft: #a8bcb8;
    --line: #38525a;
    --s-emerging: #93d24d;
    --s-growing: #7ba6ff;
    --s-peak: #f26db7;
    --s-saturated: #eda94b;
    --s-declining: #9fb1ad;
    --focus: #7ba6ff;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--plate);
  color: var(--ink);
  font: 400 16px/1.5 "Golos Text", system-ui, sans-serif;
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
h1, h2, h3, p, dl, dd, ol, ul { margin: 0; padding: 0; }
ol, ul { list-style: none; }

.top {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 32px;
  padding: 16px clamp(16px, 3vw, 32px);
  border-bottom: 2px solid var(--ink);
}
.brand { font: 700 20px "Unbounded", sans-serif; text-decoration: none; }
.top nav { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.top nav a, .tabs a { text-decoration: none; padding: 2px 0; border-bottom: 3px solid transparent; }
.top nav a[aria-current], .tabs a[aria-current] { border-bottom-color: currentColor; font-weight: 600; }

main { padding: clamp(16px, 3vw, 32px); }
.head { max-width: 68ch; margin-bottom: 24px; }
h1 { font: 700 clamp(26px, 4vw, 38px)/1.15 "Unbounded", sans-serif; overflow-wrap: anywhere; }
.lede { margin-top: 8px; color: var(--ink-soft); }
.sec { font: 500 18px "Unbounded", sans-serif; margin: 32px 0 16px; }
.tabs { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-top: 12px; }
.empty { color: var(--ink-soft); }

.board { display: grid; grid-template-columns: repeat(5, minmax(220px, 1fr)); gap: 0; overflow-x: auto; }
.col { padding: 0 12px 16px; border-left: 2px solid var(--line); min-width: 0; }
.col:first-child { padding-left: 0; border-left: 0; }
.col h2 {
  display: flex; justify-content: space-between; align-items: baseline;
  font: 500 15px "Unbounded", sans-serif; padding-bottom: 8px; margin-bottom: 8px;
  border-bottom: 5px solid var(--stage);
}
.col h2 span { font: 500 15px "Golos Text", sans-serif; color: var(--ink-soft); }
.c-emerging, .s-emerging { --stage: var(--s-emerging); }
.c-growing, .s-growing { --stage: var(--s-growing); }
.c-peak, .s-peak { --stage: var(--s-peak); }
.c-saturated, .s-saturated { --stage: var(--s-saturated); }
.c-declining, .s-declining { --stage: var(--s-declining); }

.tile {
  display: grid; grid-template-columns: 56px 1fr; column-gap: 12px;
  padding: 10px 0; text-decoration: none; border-bottom: 1px solid var(--line);
}
.tile:hover .tname { text-decoration: underline; }
.tile .layers { grid-row: span 2; }
.tname { font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.tnums { font-size: 13px; color: var(--ink-soft); font-variant-numeric: tabular-nums; }

/* Weekly supply drawn as printed layers: a thick bead means a busy week. */
.layers { display: flex; flex-direction: column; justify-content: center; gap: 1px; width: 100%; }
.layers i { display: block; height: 3px; background: var(--plate-deep); position: relative; border-radius: 2px; }
.layers i::after {
  content: ""; position: absolute; inset: 0; width: var(--w); border-radius: 2px;
  background: var(--stage, var(--ink));
}
.layers.tall { width: min(360px, 100%); gap: 3px; flex-shrink: 0; }
.layers.tall i { height: 14px; border-radius: 7px; }
.layers.tall i::after { border-radius: 7px; }

.feed { margin-top: 32px; font-size: 14px; color: var(--ink-soft); }
.feed .bad { color: var(--s-peak); font-weight: 600; }

.typehead { display: flex; flex-wrap: wrap; gap: 24px 48px; justify-content: space-between; }
.typehead > div { flex: 1 1 320px; min-width: 0; }
.typehead .stage { margin-top: 10px; }
.big { display: flex; flex-wrap: wrap; gap: 16px 32px; margin-top: 20px; }
.big dt { font-size: 13px; color: var(--ink-soft); }
.big dd { font: 700 26px "Unbounded", sans-serif; }

.stage {
  display: inline-block; padding: 1px 8px; font-size: 13px; font-weight: 600;
  border: 2px solid var(--stage); border-radius: 4px; color: var(--ink);
}

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 16px; }
.card {
  display: flex; flex-direction: column; background: var(--sheet);
  border-bottom: 5px solid var(--line); min-width: 0;
}
.card[data-decided="take"] { border-bottom-color: var(--s-emerging); }
.card[data-decided="no"] { opacity: .55; }
.shot { display: block; background: var(--plate-deep); }
.shot img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.facts { padding: 12px; flex: 1; }
.facts h3 { font-size: 17px; font-weight: 600; line-height: 1.25; overflow-wrap: anywhere; }
.facts h3 a { text-decoration: none; }
.facts h3 a:hover { text-decoration: underline; }
.by { font-size: 14px; color: var(--ink-soft); overflow-wrap: anywhere; }
.kind { margin-top: 8px; font-size: 14px; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.facts dl { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; margin-top: 10px; }
.facts dt { font-size: 12px; color: var(--ink-soft); }
.facts dd { font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.act { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 1px; background: var(--line); }
.act button {
  font: 600 15px "Golos Text", sans-serif; padding: 12px 4px; border: 0; cursor: pointer;
  background: var(--sheet); color: var(--ink);
}
.act .b-take { background: var(--s-emerging); color: #0c1f05; }
.act button:hover { filter: brightness(.94); }
.done { padding: 12px; font-weight: 600; display: flex; justify-content: space-between; gap: 12px; }
.undo { background: none; border: 0; padding: 0; color: var(--ink-soft); text-decoration: underline; cursor: pointer; font: inherit; font-weight: 400; }

.ask { margin-top: 10px; font-size: 14px; font-weight: 600; color: var(--s-saturated); }
.out { margin-left: auto; }
.out button { background: none; border: 0; padding: 0; color: var(--ink-soft); font: inherit; cursor: pointer; text-decoration: underline; }
.login { display: grid; gap: 12px; max-width: 320px; margin-top: 16px; }
.login input { font: inherit; padding: 10px; border: 2px solid var(--ink); background: var(--sheet); color: var(--ink); }
.login button { font: 600 16px "Golos Text", sans-serif; padding: 12px; border: 0; background: var(--ink); color: var(--plate); cursor: pointer; }
.err { color: var(--s-peak); font-weight: 600; }

.funnel { display: grid; gap: 4px; max-width: 760px; }
.funnel li { position: relative; padding: 8px 12px; background: var(--plate-deep); z-index: 0; }
.funnel li::before {
  content: ""; position: absolute; inset: 0; width: var(--w); background: var(--s-growing);
  opacity: .28; z-index: -1;
}
.funnel .minus { font-size: 15px; }
.funnel .final::before { background: var(--s-emerging); opacity: .5; }
.funnel b { font-variant-numeric: tabular-nums; }
.reasons { columns: 2 280px; }
.reasons li { padding: 2px 0; break-inside: avoid; overflow-wrap: anywhere; }

@media (max-width: 720px) {
  .board { grid-template-columns: 1fr; }
  .col { padding: 0 0 16px; border-left: 0; }
}
