:root {
  --ink: #14181d;
  --ink-soft: #5b6672;
  --line: #e2e6ea;
  --bg: #ffffff;
  --bg-soft: #f6f8fa;
  --accent: #14532d;
  --accent-soft: #eef4f0;
  --danger: #8a2020;
  --radius: 6px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
}

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

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

.masthead {
  border-bottom: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 40px 0 32px;
}

.eyebrow {
  margin: 0 0 6px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--accent);
}

.masthead h1 { margin: 0 0 10px; font-size: 34px; line-height: 1.15; letter-spacing: -0.02em; }

.lede { margin: 0; max-width: 62ch; color: var(--ink-soft); }

.freshness { margin: 14px 0 0; font-size: 13px; color: var(--ink-soft); }

.stale {
  margin: 12px 0 0;
  padding: 10px 14px;
  max-width: 62ch;
  border: 1px solid var(--danger);
  border-radius: var(--radius);
  font-size: 13px;
  color: var(--danger);
  background: var(--bg);
}

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

.layout {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 40px;
  padding-top: 32px;
  padding-bottom: 56px;
  align-items: start;
}

@media (max-width: 860px) {
  .layout { grid-template-columns: 1fr; gap: 24px; }
}

/* filters ----------------------------------------------------------------- */

.filters { position: sticky; top: 24px; }

@media (max-width: 860px) { .filters { position: static; } }

.field { margin-bottom: 16px; }

.field label {
  display: block;
  margin-bottom: 5px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.field input,
.field select,
.sort select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg);
  color: inherit;
  font: inherit;
  font-size: 14px;
}

.field input:focus-visible,
.field select:focus-visible,
.sort select:focus-visible,
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.reset {
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  font: inherit;
  font-size: 13px;
  text-decoration: underline;
  cursor: pointer;
}

.sources {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-soft);
}

.sources h2 {
  margin: 0 0 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.sources ul { margin: 0; padding: 0; list-style: none; }
.sources li { margin-bottom: 5px; }
.sources .off { color: #97a1ab; }

/* results ----------------------------------------------------------------- */

.results-bar {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 10px;
}

.results-bar p { margin: 0; font-size: 14px; color: var(--ink-soft); }

.sort { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-soft); }
.sort select { width: auto; }

.listings { width: 100%; border-collapse: collapse; font-size: 15px; }

.listings th {
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: left;
  color: var(--ink-soft);
  white-space: nowrap;
}

.listings td { padding: 13px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }

.listings tbody tr:hover { background: var(--bg-soft); }

.role a { color: var(--ink); font-weight: 600; text-decoration: none; }
.role a:hover { color: var(--accent); text-decoration: underline; }

.role .out {
  display: inline-block;
  margin-left: 5px;
  color: var(--ink-soft);
  font-weight: 400;
  font-size: 12px;
}

.tag {
  display: inline-block;
  margin-top: 5px;
  padding: 2px 7px;
  border-radius: 100px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 11px;
  line-height: 1.5;
}

.muted { color: var(--ink-soft); }
.nowrap { white-space: nowrap; }
.num { font-variant-numeric: tabular-nums; }

@media (max-width: 720px) {
  .listings thead { display: none; }
  .listings tr { display: block; padding: 14px 0; border-bottom: 1px solid var(--line); }
  .listings td { display: block; padding: 2px 0; border: 0; }
  .listings tbody tr:hover { background: none; }
}

.empty,
.error { margin: 28px 0; color: var(--ink-soft); }
.error { color: var(--danger); }

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

.foot {
  padding-top: 20px;
  padding-bottom: 48px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--ink-soft);
}

.foot p { margin: 0 0 5px; max-width: 70ch; }
