:root {
  --bg: #101417;
  --panel: #171d21;
  --panel2: #1d252a;
  --line: #344047;
  --ink: #edf1ee;
  --muted: #9ba8a8;
  --accent: #9bd6b8;
  --amber: #e7c47c;
  --danger: #f19a91;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font:
    14px/1.4 ui-sans-serif,
    system-ui,
    sans-serif;
}
button,
input,
select,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
.skip {
  position: absolute;
  left: -999px;
}
.skip:focus {
  left: 8px;
  top: 8px;
  z-index: 9;
  background: white;
  color: black;
  padding: 8px;
}
header {
  height: 58px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 0 max(16px, calc((100% - 1500px) / 2));
  position: sticky;
  top: 0;
  background: #101417ee;
  backdrop-filter: blur(12px);
  z-index: 3;
}
.brand {
  color: var(--ink);
  text-decoration: none;
  font-size: 17px;
  font-weight: 750;
}
.brand span,
.budget {
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
  margin-left: 7px;
}
.budget {
  margin-left: auto;
}
.budget b {
  color: var(--ink);
}
.button,
.quiet {
  border: 1px solid var(--line);
  background: var(--panel2);
  color: var(--ink);
  border-radius: 5px;
  padding: 8px 11px;
}
.button {
  background: var(--accent);
  border-color: var(--accent);
  color: #112019;
  font-weight: 700;
}
.quiet {
  background: transparent;
}
.quiet:hover,
.views button:hover {
  border-color: var(--accent);
  color: var(--accent);
}
main {
  max-width: 1500px;
  margin: auto;
  padding: 14px 16px 86px;
}
.toolbar {
  border: 1px solid var(--line);
  background: var(--panel);
  padding: 10px;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}
.views,
.filters,
.grid {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}
.views button {
  border: 0;
  border-bottom: 2px solid transparent;
  background: none;
  color: var(--muted);
  padding: 7px;
}
.views button.active {
  color: var(--ink);
  border-bottom-color: var(--accent);
}
label {
  display: block;
  font-size: 11px;
  color: var(--muted);
}
input,
select,
textarea {
  display: block;
  margin-top: 3px;
  width: 100%;
  background: #0f1417;
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 7px;
  min-height: 34px;
}
textarea {
  min-height: 56px;
  resize: vertical;
}
.filters label {
  min-width: 110px;
}
.filters label:first-child {
  min-width: 180px;
}
.workspace {
  display: grid;
  grid-template-columns: minmax(430px, 1.15fr) minmax(360px, 0.85fr);
  gap: 12px;
  margin-top: 12px;
}
.list-pane,
.detail-pane,
.compare {
  border: 1px solid var(--line);
  background: var(--panel);
  min-width: 0;
}
.list-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px;
  border-bottom: 1px solid var(--line);
  gap: 10px;
  flex-wrap: wrap;
}
.list-head span {
  color: var(--muted);
  font-size: 12px;
}
.candidate {
  padding: 11px;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 26px 1fr auto;
  gap: 9px;
  align-items: start;
}
.candidate.opportunity {
  grid-template-columns: minmax(0, 1fr) auto;
}
.candidate:hover,
.candidate.selected {
  background: var(--panel2);
}
.candidate h3 {
  font-size: 14px;
  margin: 0 0 3px;
}
.candidate .meta,
.signal {
  font-size: 12px;
  color: var(--muted);
}
.candidate .price {
  text-align: right;
  color: var(--amber);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.candidate.opportunity .price {
  max-width: 12rem;
  overflow-wrap: anywhere;
}
.tags {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.tag {
  font-size: 10px;
  border: 1px solid var(--line);
  border-radius: 99px;
  padding: 2px 6px;
  color: var(--muted);
}
.tag.state {
  color: var(--accent);
  border-color: #496354;
}
.tag.stale {
  color: var(--amber);
}
.candidate button.link {
  border: 0;
  background: none;
  color: var(--ink);
  padding: 0;
  text-align: left;
}
.empty,
#detail-empty {
  padding: 25px;
  color: var(--muted);
}
.hidden {
  display: none !important;
}
.detail-pane {
  position: sticky;
  top: 71px;
  max-height: calc(100vh - 84px);
  overflow: auto;
}
.detail {
  padding: 14px;
}
.detail h2 {
  font-size: 19px;
  margin: 0;
}
.detail h3 {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--accent);
  margin: 19px 0 4px;
}
.detail p {
  margin: 4px 0;
}
.detail-actions {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  margin: 12px 0;
}
.detail select {
  max-width: 210px;
}
.history {
  padding: 0;
  margin: 7px 0;
  list-style: none;
}
.history li {
  border-top: 1px solid var(--line);
  padding: 6px 0;
  font-size: 12px;
}
.compare {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 4;
  padding: 10px 16px;
  box-shadow: 0 -8px 30px #0008;
}
.compare > div:first-child {
  display: flex;
  gap: 12px;
  align-items: baseline;
}
.compare small {
  color: var(--muted);
}
.compare > button {
  position: absolute;
  right: 16px;
  top: 8px;
}
.compare-scroll {
  overflow: auto;
  margin-top: 7px;
  max-height: min(34vh, 290px);
}
.compare table {
  border-collapse: collapse;
  min-width: 680px;
  width: 100%;
  font-size: 12px;
}
.compare th,
.compare td {
  padding: 6px 8px;
  text-align: left;
  border-top: 1px solid var(--line);
  vertical-align: top;
}
.compare th {
  color: var(--muted);
}
dialog {
  width: min(720px, calc(100% - 20px));
  max-height: calc(100dvh - 20px);
  overflow: auto;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--ink);
  padding: 16px;
  box-shadow: 0 20px 70px #000;
}
dialog::backdrop {
  background: #000a;
}
.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.modal-head h2 {
  font-size: 20px;
  margin: 0;
}
.x {
  border: 0;
  background: none;
  color: var(--ink);
  font-size: 25px;
}
.grid > * {
  flex: 1 1 160px;
}
details {
  margin-top: 10px;
  color: var(--muted);
}
summary {
  cursor: pointer;
}
fieldset {
  border: 1px solid var(--line);
  margin: 12px 0;
}
footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  margin-top: 13px;
}
.error {
  color: var(--danger);
  min-height: 18px;
}
.muted {
  color: var(--muted);
  font-size: 12px;
}
@media (max-width: 760px) {
  header {
    padding: 0 10px;
    gap: 8px;
  }
  .brand span,
  .budget {
    display: none;
  }
  main {
    padding: 9px 0 94px;
  }
  .toolbar {
    border-left: 0;
    border-right: 0;
  }
  .filters {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .filters label:first-child {
    grid-column: span 2;
    min-width: 0;
  }
  .filters label {
    min-width: 0;
  }
  .workspace {
    display: block;
    margin-top: 0;
  }
  .detail-pane {
    display: none;
    position: fixed;
    inset: 58px 0 0;
    z-index: 5;
    max-height: none;
    border: 0;
  }
  .detail-pane.mobile-open {
    display: block;
  }
  .list-pane {
    border-left: 0;
    border-right: 0;
  }
  .candidate {
    grid-template-columns: 24px 1fr auto;
  }
  .candidate.opportunity {
    grid-template-columns: minmax(0, 1fr) minmax(5.5rem, auto);
  }
  .candidate.opportunity .price {
    max-width: 7rem;
    white-space: normal;
  }
  .compare {
    padding: 8px 10px;
  }
  .compare > button {
    right: 10px;
  }
  .compare-scroll {
    margin-right: -10px;
  }
  .detail {
    padding: 14px;
  }
  .detail .back {
    display: inline-block;
  }
  .workspace:has(.mobile-open) .list-pane {
    display: none;
  }
}
@media (min-width: 761px) {
  .back {
    display: none !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
  }
}
@media (min-width: 761px) {
  .back {
    display: inline-block !important;
  }
}
@media (max-width: 760px) {
  main {
    padding-bottom: 18px;
  }
  .compare {
    position: static;
    margin-top: 12px;
    padding: 8px 10px;
    border-left: 0;
    border-right: 0;
    box-shadow: none;
  }
  .compare > button {
    position: static;
    margin-top: 8px;
  }
  .compare-scroll {
    max-height: min(50dvh, 390px);
    overscroll-behavior: contain;
  }
}
