:root {
  --bg: #ffffff;
  --fg: #111111;
  --fg-2: #4a4a4a;
  --muted: #8a8a8a;
  --line: #ececec;
  --hover: #f7f7f7;
  --chip: #f2f2f2;
  --accent: #111111;
  --warn: #c2410c;
  --fresh: #15803d;
  --brand: #ff5a3c;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f0f0f; --fg: #f2f2f2; --fg-2: #bdbdbd; --muted: #7d7d7d;
    --line: #232323; --hover: #171717; --chip: #1e1e1e; --accent: #f2f2f2;
    --warn: #fb923c; --fresh: #4ade80; --brand: #ff7259;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 15px/1.5 Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }

.wrap { max-width: 860px; margin: 0 auto; padding: 0 20px; }

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: inline-flex; color: var(--fg); text-decoration: none; padding: 4px 0; border-radius: 6px; }
.brand svg { height: 32px; width: auto; display: block; overflow: visible; }
.brand .ink { fill: none; stroke: currentColor; stroke-width: 4.4; stroke-linecap: round; stroke-linejoin: round; }
.brand .dot { fill: var(--brand); transition: transform .35s cubic-bezier(.34, 1.56, .64, 1); }
.brand:hover .dot, .brand:focus-visible .dot { transform: translateY(-3px); }
.brand:focus-visible { outline: 2px solid var(--fg); outline-offset: 4px; }
@media (prefers-reduced-motion: reduce) { .brand .dot { transition: none; } }
.tabs { display: flex; gap: 4px; }
.tab {
  background: none; border: 0; padding: 6px 12px; border-radius: 8px; cursor: pointer; color: var(--muted);
}
.tab:hover { color: var(--fg); }
a.tab { text-decoration: none; }
.tab.active { color: var(--fg); background: var(--chip); }
#savedCount:empty { display: none; }
#savedCount { font-size: .8em; color: var(--muted); }

/* Intro */
.intro { padding: 48px 0 28px; }
.intro h1 { font-size: clamp(1.8rem, 5vw, 2.6rem); font-weight: 600; letter-spacing: -.035em; line-height: 1.1; margin: 0 0 10px; }
.intro .h1-sub { color: var(--muted); }
.sub { margin: 0; color: var(--muted); }

/* Controls */
.controls { display: grid; gap: 12px; position: sticky; top: 0; background: var(--bg); padding: 12px 0; z-index: 5; }
.search {
  display: flex; align-items: center; gap: 10px; border: 1px solid var(--line); border-radius: 12px;
  padding: 0 14px; transition: border-color .15s;
}
.search:focus-within { border-color: var(--fg); }
.search svg { width: 18px; height: 18px; fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; flex-shrink: 0; }
.search input { flex: 1; border: 0; outline: 0; background: transparent; padding: 13px 0; font-size: 1rem; min-width: 0; }
.search input::-webkit-search-cancel-button { cursor: pointer; }
kbd {
  font: 500 .75rem Inter, sans-serif; color: var(--muted); border: 1px solid var(--line);
  border-radius: 5px; padding: 1px 6px;
}
.filters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.filters select {
  appearance: none; border: 1px solid var(--line); background: var(--bg); border-radius: 999px;
  padding: 7px 30px 7px 14px; cursor: pointer; font-size: .9rem; width: 100%; min-width: 0;
  text-overflow: ellipsis; white-space: nowrap; overflow: hidden;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 16px) 52%, calc(100% - 11px) 52%;
  background-size: 5px 5px; background-repeat: no-repeat;
}
.filters select:hover { border-color: var(--muted); }
.filters select.set { border-color: var(--fg); }
@media (max-width: 760px) { .filters { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

.result-bar { display: flex; justify-content: space-between; align-items: center; padding: 14px 0 6px; color: var(--muted); font-size: .88rem; border-bottom: 1px solid var(--line); }
.link { background: none; border: 0; padding: 0; cursor: pointer; color: var(--fg); text-decoration: underline; text-underline-offset: 3px; font-size: .88rem; }

/* List */
.list { list-style: none; margin: 0; padding: 0; }
.job { border-bottom: 1px solid var(--line); }
.row {
  display: grid; grid-template-columns: 40px 1fr auto; gap: 14px; align-items: center;
  padding: 16px 8px; margin: 0 -8px; border-radius: 10px; cursor: pointer; width: calc(100% + 16px);
  background: none; border: 0; text-align: left;
}
.row:hover { background: var(--hover); }
.row:focus-visible { outline: 2px solid var(--fg); outline-offset: -2px; }
.logo {
  width: 40px; height: 40px; border-radius: 9px; background: var(--chip); overflow: hidden;
  display: grid; place-items: center; font-weight: 600; font-size: .85rem; color: var(--fg-2);
  border: 1px solid var(--line);
}
.logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.main { min-width: 0; }
.title { font-weight: 500; font-size: 1rem; margin: 0; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.meta { color: var(--muted); font-size: .86rem; margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.meta .co { color: var(--fg-2); }
.side { text-align: right; font-size: .82rem; color: var(--muted); white-space: nowrap; display: grid; gap: 2px; justify-items: end; }
.side .new { color: var(--fresh); }
.side .soon { color: var(--warn); }

/* Expanded */
.detail { padding: 0 0 20px 54px; display: none; }
.job.open .detail { display: block; animation: in .18s ease; }
.job.open .row { background: var(--hover); }
@keyframes in { from { opacity: 0; transform: translateY(-4px); } }
.snippet { color: var(--fg-2); margin: 4px 0 14px; max-width: 62ch; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
.chip { background: var(--chip); border-radius: 6px; padding: 3px 9px; font-size: .8rem; color: var(--fg-2); }
.facts { display: flex; flex-wrap: wrap; gap: 4px 20px; font-size: .85rem; color: var(--muted); margin-bottom: 16px; }
.facts b { color: var(--fg); font-weight: 500; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--bg); cursor: pointer; font-size: .9rem; text-decoration: none;
}
.btn:hover { border-color: var(--muted); }
.btn.primary { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.btn.primary:hover { opacity: .85; }
.btn.on { border-color: var(--fg); }

/* About page */
.about { max-width: 620px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.about p { margin: 0 0 18px; font-size: 1.05rem; line-height: 1.65; color: var(--fg-2); }
.about p:last-child { margin-top: 28px; }
.via { font-size: .8rem; color: var(--muted); margin-left: 4px; }
.via a { color: var(--fg-2); text-underline-offset: 2px; }
.via a:hover { color: var(--fg); }

.empty { text-align: center; color: var(--muted); padding: 64px 0; }

.foot { color: var(--muted); font-size: .82rem; padding: 40px 0 56px; }
.foot p { margin: 0 0 4px; }

@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .intro { padding: 24px 0 16px; }
  .row { grid-template-columns: 36px 1fr; gap: 12px; }
  .logo { width: 36px; height: 36px; }
  .side { grid-column: 2; justify-items: start; text-align: left; display: flex; gap: 10px; }
  .detail { padding-left: 0; }
  kbd { display: none; }
  .controls { position: static; }
  .filters { grid-template-columns: 1fr 1fr; }
  #fSort { grid-column: 1 / -1; }
}
