:root {
  --bg: #faf9f6;
  --surface: #ffffff;
  --ink: #16161a;
  --muted: #6b6b73;
  --faint: #a4a4ab;
  --line: #e6e4de;
  --accent: #c8102e;
  --new-bg: #fff4d6;
  --chip-bg: #f0eee8;
  --serif: 'Source Serif 4', Georgia, serif;
  --sans: Inter, system-ui, -apple-system, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121214;
    --surface: #1b1b1f;
    --ink: #ececef;
    --muted: #9c9ca6;
    --faint: #66666f;
    --line: #2c2c32;
    --accent: #ff5a6e;
    --new-bg: #3a2f12;
    --chip-bg: #26262b;
  }
}

* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 var(--sans); }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }
.wrap { max-width: 1400px; margin: 0 auto; padding: 0 24px; }

.masthead { padding: 40px 0 24px; border-bottom: 3px double var(--ink); }
.kicker { margin: 0 0 6px; font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.masthead h1 { margin: 0; font: 700 clamp(32px, 5vw, 52px)/1.05 var(--serif); letter-spacing: -.01em; }
.lede { margin: 10px 0 0; color: var(--muted); max-width: 60ch; }

.toolbar { position: sticky; top: 0; z-index: 5; background: color-mix(in srgb, var(--bg) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.toolbar-inner { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding-top: 12px; padding-bottom: 12px; }
#search { flex: 0 1 280px; min-width: 200px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); font: inherit; }
#search:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { padding: 5px 11px; border: 1px solid transparent; border-radius: 999px; background: var(--chip-bg); color: var(--ink); font: 500 13px var(--sans); cursor: pointer; }
.chip[aria-pressed="false"] { background: transparent; border-color: var(--line); color: var(--faint); text-decoration: line-through; }

.day { margin: 32px 0; }
.day-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.day-head h2 { margin: 0; font: 700 22px var(--serif); }
.day-head .rel { font-size: 13px; color: var(--muted); }

.table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; overflow: hidden; table-layout: fixed; }
.table th, .table td { padding: 12px 14px; vertical-align: top; text-align: left; border-bottom: 1px solid var(--line); }
.table tr:last-child td, .table tr:last-child th { border-bottom: 0; }
.table thead th { font: 600 12px var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: var(--chip-bg); }
.table th.site, .table td.site { width: 150px; }
.table tbody th { font: 600 14px var(--sans); }
.table tbody th a { display: flex; align-items: center; gap: 8px; }
.badge { flex: none; display: grid; place-items: center; width: 24px; height: 24px; border-radius: 6px; color: #fff; font: 700 12px var(--sans); }

.cell a.title { font: 500 16px/1.3 var(--serif); }
.cell.new { background: var(--new-bg); }
.cell .same { color: var(--faint); font: 400 13px/1.35 var(--sans); }
.cell .same::before { content: '↺ '; }
.cell .err { color: var(--faint); font-size: 13px; font-style: italic; }
.cell .label { display: none; }
mark { background: color-mix(in srgb, var(--accent) 22%, transparent); color: inherit; border-radius: 2px; }

.status { color: var(--muted); text-align: center; }
.status:empty { display: none; }
.more { text-align: center; margin: 24px 0 64px; }
#more { padding: 12px 28px; border: 1px solid var(--ink); border-radius: 999px; background: transparent; color: var(--ink); font: 600 14px var(--sans); cursor: pointer; }
#more:hover { background: var(--ink); color: var(--bg); }
#more:disabled { opacity: .5; cursor: wait; }

@media (max-width: 760px) {
  .wrap { padding: 0 16px; }
  .masthead { padding-top: 28px; }
  #search { flex: 1 1 100%; }
  .table, .table tbody, .table tr, .table th, .table td { display: block; width: auto !important; }
  .table thead { display: none; }
  .table tbody tr { border-bottom: 1px solid var(--line); padding: 4px 0; }
  .table tbody tr:last-child { border-bottom: 0; }
  .table th, .table td { border: 0; padding: 6px 14px; }
  .table tbody th { padding-top: 10px; }
  .cell .label { display: inline-block; min-width: 44px; color: var(--muted); font: 600 12px var(--sans); }
  .cell.new { margin: 0 8px; border-radius: 8px; }
}
