:root {
  --bg: #0e1116;
  --panel: #161b22;
  --panel-2: #1c232c;
  --line: #2a323d;
  --ink: #e6edf3;
  --ink-dim: #9aa7b4;
  --ink-faint: #6b7784;
  --green: #3fb950;
  --amber: #d29922;
  --red: #f85149;
  --blue: #58a6ff;
  --teal: #39c5cf;
  --radius: 8px;
}

* { box-sizing: border-box; }

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

/* ---------- chrome ---------- */

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 12px 20px;
  background: var(--panel); border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 10;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; }
.mark {
  display: grid; place-items: center; width: 28px; height: 28px;
  background: linear-gradient(135deg, var(--teal), var(--blue));
  color: #06121a; border-radius: 6px; font-size: 12px; font-weight: 700;
}
.topbar-right { display: flex; align-items: center; gap: 12px; }

.tabs {
  display: flex; gap: 4px; padding: 0 20px;
  background: var(--panel); border-bottom: 1px solid var(--line);
}
.tab {
  background: none; border: none; border-bottom: 2px solid transparent;
  color: var(--ink-dim); padding: 10px 14px; font: inherit; cursor: pointer;
}
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); border-bottom-color: var(--teal); }

main { padding: 20px; max-width: 1500px; margin: 0 auto; }
.h { font-size: 15px; margin: 0 0 12px; color: var(--ink-dim); font-weight: 600;
     text-transform: uppercase; letter-spacing: .04em; }

/* ---------- bits ---------- */

.btn {
  background: var(--panel-2); color: var(--ink); border: 1px solid var(--line);
  padding: 7px 13px; border-radius: 6px; font: inherit; cursor: pointer;
}
.btn:hover { background: #243040; }
.btn.primary { background: var(--blue); border-color: var(--blue); color: #06121a; font-weight: 600; }
.btn.primary:hover { filter: brightness(1.1); }
.btn.ghost { background: none; }
.btn.small { padding: 4px 9px; font-size: 12px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

.pill {
  display: inline-block; padding: 3px 9px; border-radius: 999px;
  font-size: 12px; font-weight: 600; white-space: nowrap;
}
.pill.ok      { background: rgba(63,185,80,.15);  color: var(--green); }
.pill.warn    { background: rgba(210,153,34,.15); color: var(--amber); }
.pill.err     { background: rgba(248,81,73,.15);  color: var(--red); }
.pill.info    { background: rgba(88,166,255,.15); color: var(--blue); }
.pill.neutral { background: rgba(154,167,180,.15); color: var(--ink-dim); }

.banner {
  padding: 10px 14px; border-radius: var(--radius); margin-bottom: 16px;
  background: rgba(88,166,255,.1); border: 1px solid rgba(88,166,255,.3); color: var(--blue);
}
.banner.err { background: rgba(248,81,73,.1); border-color: rgba(248,81,73,.3); color: var(--red); }
.banner.ok  { background: rgba(63,185,80,.1); border-color: rgba(63,185,80,.3); color: var(--green); }

.empty { color: var(--ink-faint); padding: 40px; text-align: center;
         border: 1px dashed var(--line); border-radius: var(--radius); }

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

.split { display: grid; grid-template-columns: 300px 1fr; gap: 20px; align-items: start; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

.race-list { display: flex; flex-direction: column; gap: 6px; }
.race-item {
  text-align: left; background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 10px 12px; cursor: pointer; color: inherit;
  font: inherit; display: flex; flex-direction: column; gap: 4px;
}
.race-item:hover { border-color: var(--teal); }
.race-item.active { border-color: var(--teal); background: var(--panel-2); }
.race-item .rl-top { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.race-item .venue { font-weight: 600; }
.race-item .meta { color: var(--ink-faint); font-size: 12px; }

/* ---------- tables ---------- */

table { width: 100%; border-collapse: collapse; }
th, td { padding: 8px 10px; text-align: right; border-bottom: 1px solid var(--line); }
th { color: var(--ink-dim); font-size: 12px; font-weight: 600; text-transform: uppercase;
     letter-spacing: .03em; white-space: nowrap; }
th:first-child, td:first-child, th.l, td.l { text-align: left; }
tbody tr:hover { background: rgba(255,255,255,.02); }
tr.is-value { background: rgba(63,185,80,.07); }
tr.is-value td:first-child { box-shadow: inset 3px 0 0 var(--green); }
.num { font-variant-numeric: tabular-nums; }
.pos { color: var(--green); font-weight: 600; }
.neg { color: var(--ink-faint); }

.panel { background: var(--panel); border: 1px solid var(--line);
         border-radius: var(--radius); padding: 16px; margin-bottom: 16px; overflow-x: auto; }
.panel-hd { display: flex; justify-content: space-between; align-items: baseline;
            gap: 12px; flex-wrap: wrap; margin-bottom: 12px; }
.panel-hd h3 { margin: 0; font-size: 16px; }
.sub { color: var(--ink-faint); font-size: 12px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
         gap: 12px; margin-bottom: 20px; }
.tile { background: var(--panel); border: 1px solid var(--line);
        border-radius: var(--radius); padding: 14px; }
.tile .label { color: var(--ink-dim); font-size: 12px; text-transform: uppercase;
               letter-spacing: .03em; margin-bottom: 6px; }
.tile .value { font-size: 22px; font-weight: 600; font-variant-numeric: tabular-nums; }

.tote-input {
  width: 72px; background: var(--bg); border: 1px solid var(--line);
  color: var(--ink); border-radius: 5px; padding: 4px 6px; text-align: right;
  font: inherit; font-variant-numeric: tabular-nums;
}
.tote-input:focus { border-color: var(--teal); }

.reasons { color: var(--ink-faint); font-size: 12px; }

/* ---------- forms ---------- */

.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px;
             background: var(--panel); border: 1px solid var(--line);
             border-radius: var(--radius); padding: 20px; }
.field label { display: block; margin-bottom: 6px; font-weight: 600; font-size: 13px; }
.field input { width: 100%; background: var(--bg); border: 1px solid var(--line);
               color: var(--ink); border-radius: 6px; padding: 8px 10px; font: inherit; }
.field .hint { color: var(--ink-faint); font-size: 12px; margin: 6px 0 0; }
.field-actions { display: flex; align-items: flex-end; }

/* ---------- prose ---------- */

.prose { background: var(--panel); border: 1px solid var(--line);
         border-radius: var(--radius); padding: 24px; max-width: 760px; }
.prose h3 { margin: 24px 0 8px; font-size: 15px; color: var(--teal); }
.prose h3:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--ink-dim); }
.prose code { background: var(--bg); padding: 1px 5px; border-radius: 4px;
              font-size: 13px; color: var(--ink); }
.prose .warn { border-left: 3px solid var(--amber); padding-left: 12px; color: var(--amber); }

:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }

.paste {
  width: 100%; background: var(--bg); border: 1px solid var(--line);
  color: var(--ink); border-radius: 6px; padding: 10px; font: inherit;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px;
  resize: vertical; min-height: 76px;
}
.paste:focus { border-color: var(--teal); }

/* ---------- race list filter ---------- */

.list-hd { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.list-hd .h { margin-bottom: 8px; }

.filter-row { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.filter-row label {
  color: var(--ink-dim); font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .03em;
}
.filter-row select {
  flex: 1; min-width: 0; background: var(--bg); color: var(--ink);
  border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; font: inherit;
}
.filter-row select:focus { border-color: var(--teal); }

.mini-select {
  background: var(--bg); color: var(--ink); border: 1px solid var(--line);
  border-radius: 5px; padding: 4px 6px; font: inherit; font-size: 12px;
}
.mini-select:focus { border-color: var(--teal); }

/* ---------- target price: the one number you act on ---------- */

.target-hero {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 14px; margin-bottom: 8px;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
}
.target-hero.is-bet { border-color: var(--green); background: rgba(63,185,80,.08); }
.target-hero .who { font-weight: 600; font-size: 15px; }
.target-hero .price {
  font-size: 22px; font-weight: 700; color: var(--blue);
  font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right;
}
.target-hero .price small { display: block; font-size: 11px; font-weight: 600;
  color: var(--ink-faint); text-transform: uppercase; letter-spacing: .04em; }

/* ==========================================================================
   MOBILE
   Primary target is a phone held one-handed with TAB open in another tab.
   Two structural changes rather than cosmetic shrinking:
     1. Master/detail becomes a drill-down - list OR race, never both.
     2. Wide tables become stacked cards, labelled from data-label.
   ========================================================================== */

@media (max-width: 760px) {

  /* --- chrome --- */
  body { -webkit-text-size-adjust: 100%; }

  .topbar {
    padding: 10px 12px calc(10px + env(safe-area-inset-bottom, 0px));
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
    flex-wrap: wrap; gap: 8px;
  }
  .topbar-right { gap: 8px; width: 100%; justify-content: space-between; }
  .topbar-right .btn { flex: 1; min-height: 44px; }

  .tabs { padding: 0 6px; overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { padding: 12px 12px; min-height: 44px; white-space: nowrap; }

  main { padding: 12px max(12px, env(safe-area-inset-right)) 32px max(12px, env(safe-area-inset-left)); }

  /* --- drill-down: show the list or the race, not both --- */
  .split { grid-template-columns: 1fr; gap: 0; }
  .split.showing-detail .col-list { display: none; }
  .split:not(.showing-detail) .col-detail { display: none; }

  .back-btn {
    display: flex; align-items: center; gap: 6px; width: 100%;
    min-height: 44px; margin-bottom: 12px;
  }

  /* --- bigger touch targets --- */
  .race-item { padding: 14px 12px; min-height: 60px; }
  .filter-row select { min-height: 44px; font-size: 16px; }  /* 16px stops iOS zoom */
  .btn { min-height: 44px; padding: 10px 14px; }
  .btn.small { min-height: 36px; }
  .paste { font-size: 16px; min-height: 120px; }
  .tote-input { min-height: 40px; width: 84px; font-size: 16px; }
  .field input { font-size: 16px; min-height: 44px; }

  .panel { padding: 12px; border-radius: 10px; }
  .panel-hd h3 { font-size: 15px; }

  /* --- tables become cards ---
     Two columns, not one stat per line. A 10-column table listed vertically
     produced a card per runner about a screen and a half tall; paired up and
     with the diagnostic columns dropped, a runner fits in four lines. */
  table.cardify thead { display: none; }
  table.cardify, table.cardify tbody { display: block; width: 100%; }
  table.cardify tr {
    display: grid; grid-template-columns: 1fr 1fr; gap: 2px 12px;
    border: 1px solid var(--line); border-radius: 10px;
    padding: 10px 12px; margin-bottom: 8px; background: var(--bg);
  }
  table.cardify tr.is-value { border-color: var(--green); background: rgba(63,185,80,.07); }
  table.cardify tr.is-value td:first-child { box-shadow: none; }
  table.cardify td {
    border: none; padding: 2px 0; text-align: right;
    display: flex; justify-content: space-between; align-items: baseline; gap: 8px;
    min-width: 0;
  }
  /* The runner name is the card heading, across both columns. */
  table.cardify td:first-child {
    grid-column: 1 / -1;
    text-align: left; font-weight: 600; font-size: 15px;
    padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid var(--line);
  }
  table.cardify td:first-child::before { content: none; }
  table.cardify td::before {
    content: attr(data-label);
    color: var(--ink-dim); font-size: 10px; font-weight: 600;
    text-transform: uppercase; letter-spacing: .03em; text-align: left;
    white-space: nowrap;
  }
  table.cardify td:empty { display: none; }

  /* Diagnostic columns - useful on a desktop, noise on a phone. The decision
     needs Market, BET AT, TAB and Edge; Back/Lay/Fair/Stake do not change it. */
  table.cardify td[data-label="Back"],
  table.cardify td[data-label="Lay"],
  table.cardify td[data-label="Fair"],
  table.cardify td[data-label="Stake"],
  table.cardify td[data-label="Placed"],
  table.cardify td[data-label="Race"],
  /* Money share is always empty - Betfair does not expose per-runner volume
     pre-race - and total matched is a whole-market figure shown in the header.
     Neither earns a line on a phone. */
  table.cardify td[data-label="Money"],
  table.cardify td[data-label="Matched"] { display: none; }

  /* BET AT is the number you act on. */
  table.cardify td[data-label="BET AT"] { font-size: 16px; font-weight: 700; }

  /* Verdict and the action buttons want the full width. */
  table.cardify td[data-label="Verdict"],
  table.cardify td[data-label=""] { grid-column: 1 / -1; }
  table.cardify td[data-label="Verdict"] { padding-top: 6px; }
  table.cardify td[data-label="Verdict"]::before { content: none; }

  /* --- sparklines --- */
  /* The SVG carried fixed width/height attributes, so inside a flex card it
     collapsed or overflowed. Give the path row the full card width and let the
     drawing stretch to fill it. */
  table.cardify td[data-label="Path"] { grid-column: 1 / -1; padding: 6px 0; }
  table.cardify td[data-label="Path"]::before { content: none; }
  table.cardify td[data-label="Path"] svg { width: 100% !important; height: 34px !important; }

  /* --- the one number that matters, made unmissable --- */
  .target-hero {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 10px; padding: 12px; margin-bottom: 8px;
    background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px;
  }
  .target-hero .who { font-weight: 600; font-size: 15px; }
  .target-hero .price {
    font-size: 26px; font-weight: 700; color: var(--blue);
    font-variant-numeric: tabular-nums; white-space: nowrap;
  }
  .target-hero .sub { display: block; }

  .tiles { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .tile { padding: 10px; }
  .tile .value { font-size: 19px; }

  .prose { padding: 16px; }
  .form-grid { padding: 14px; gap: 14px; }
}

/* Desktop keeps the real table. */
@media (min-width: 761px) {
  .back-btn { display: none; }
  table.cardify td::before { content: none; }
}

/* The paste diagnostic stays a table - as cards, a 13-runner field would be
   an enormous scroll. Keep it compact and let it scroll inside its panel. */
.reasons table { min-width: 340px; font-size: 12px; }
.reasons details { margin-top: 8px; }
.reasons summary { cursor: pointer; padding: 6px 0; min-height: 32px; }
@media (max-width: 760px) {
  .reasons { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .reasons summary { min-height: 44px; display: flex; align-items: center; }
}

/* ---------- Now: the cross-race shortlist ---------- */

.now-hd { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.win-pick { display: flex; gap: 4px; margin-bottom: 12px; }
.win-btn.active { background: var(--blue); border-color: var(--blue); color: #06121a; font-weight: 600; }

.now-race {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; margin-bottom: 10px;
  cursor: pointer; width: 100%; text-align: left; color: inherit; font: inherit;
  display: block;
}
.now-race:hover { border-color: var(--teal); }
.now-race.has-bet { border-color: var(--green); background: rgba(63,185,80,.06); }
.now-race.needs { border-left: 3px solid var(--amber); }

.now-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.now-venue { font-weight: 600; font-size: 15px; }
.now-when { font-variant-numeric: tabular-nums; font-weight: 600; color: var(--teal); white-space: nowrap; }
.now-when.soon { color: var(--amber); }
.now-when.imminent { color: var(--red); }
.now-meta { color: var(--ink-faint); font-size: 12px; margin-top: 2px; }

.now-bet {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line);
}
.now-bet .nb-name { font-weight: 600; }
.now-bet .nb-price { font-size: 19px; font-weight: 700; color: var(--green);
                     font-variant-numeric: tabular-nums; white-space: nowrap; }
.now-watch { display: flex; justify-content: space-between; gap: 10px;
             margin-top: 6px; font-size: 13px; color: var(--ink-dim); }
.now-watch .nw-price { font-variant-numeric: tabular-nums; color: var(--blue); font-weight: 600; }

@media (max-width: 760px) {
  .now-race { padding: 14px; margin-bottom: 8px; }
  .now-venue { font-size: 16px; }
  .now-bet .nb-price { font-size: 21px; }
}

/* ---------- form ---------- */

.form-runner { padding: 12px 0; border-top: 1px solid var(--line); }
.form-runner:first-of-type { border-top: none; }
.form-name { font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.form-block { display: flex; flex-direction: column; gap: 4px; }
.form-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.form-line { display: flex; gap: 3px; }

.fp {
  display: grid; place-items: center; width: 22px; height: 22px;
  border-radius: 4px; font-size: 12px; font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.fp-win { background: var(--green); color: #06121a; }
.fp-2   { background: rgba(88,166,255,.25); color: var(--blue); }
.fp-3   { background: rgba(57,197,207,.22); color: var(--teal); }
.fp-out { background: var(--panel-2); color: var(--ink-faint); }

.form-note { font-size: 12px; }
.form-note.warn { color: var(--amber); }
.form-note.good { color: var(--green); }
.form-note.info { color: var(--ink-dim); }

.form-verdict {
  font-size: 12px; padding: 6px 8px; border-radius: 6px; margin-top: 2px;
  background: var(--panel-2); color: var(--ink-dim);
}
.form-verdict.v-caution, .form-verdict.v-minor-concern {
  background: rgba(210,153,34,.12); color: var(--amber);
}
.form-verdict.v-supported { background: rgba(63,185,80,.12); color: var(--green); }

.form-details summary { cursor: pointer; font-size: 12px; color: var(--ink-dim);
                        padding: 6px 0; min-height: 32px; }
.form-table { margin-top: 4px; font-size: 12px; min-width: 460px; }
.form-table th, .form-table td { padding: 4px 6px; }

@media (max-width: 760px) {
  .form-details { overflow-x: auto; -webkit-overflow-scrolling: touch; }
  .form-details summary { min-height: 44px; display: flex; align-items: center; }
  .fp { width: 26px; height: 26px; font-size: 13px; }
}

/* ---------- consolidated runner card ----------
   Everything known about a runner in one place: price, edge, money movement
   and form. Replaces the separate value / flow / form / field panels. */

.race-hdr { margin-bottom: 12px; }
.race-call {
  margin-top: 10px; padding: 8px 10px; border-radius: 8px;
  font-weight: 600; font-size: 13px;
}
.race-call.call-bet { background: rgba(63,185,80,.14); color: var(--green); }
.race-call.call-pass { background: var(--panel-2); color: var(--ink-dim); }

.runner-card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; margin-bottom: 10px;
}
.runner-card.is-bet { border-color: var(--green); background: rgba(63,185,80,.06); }

.rc-head {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 10px; margin-bottom: 8px;
}
/* With a finishing-position badge in front, the name takes the slack so the
   probability still sits hard right. */
.rc-name { font-weight: 600; font-size: 15px; flex: 1 1 auto; min-width: 0; }

/* ---- finished races ---- */
.race-call.call-done { background: rgba(88,166,255,.12); color: var(--blue, #58a6ff); }

.runner-card.is-winner { border-color: var(--amber, #d29922); background: rgba(210,153,34,.07); }

.rc-pos {
  flex: 0 0 auto;
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 34px; height: 24px; padding: 0 6px;
  border-radius: 6px; font-size: 12px; font-weight: 700;
  font-variant-numeric: tabular-nums;
  background: var(--panel-2); color: var(--ink-dim);
}
.rc-pos.first { background: var(--amber, #d29922); color: #14171c; }
.rc-pos.placed { background: rgba(88,166,255,.18); color: var(--blue, #58a6ff); }
.rc-prob { font-variant-numeric: tabular-nums; color: var(--ink-dim); font-weight: 600; }

.rc-prices {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(72px, 1fr));
  gap: 8px; margin-bottom: 8px;
}
.rc-cell { background: var(--bg); border-radius: 8px; padding: 7px 9px; }
.rc-label {
  font-size: 10px; font-weight: 600; color: var(--ink-faint);
  text-transform: uppercase; letter-spacing: .04em;
}
.rc-value { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rc-target .rc-value { color: var(--blue); }
.rc-stake .rc-value { color: var(--green); }
.rc-pos .rc-value { color: var(--green); }
.rc-neg .rc-value { color: var(--ink-faint); }

.rc-verdict { font-size: 12px; color: var(--ink-faint); margin-bottom: 6px; }
.rc-verdict.good { color: var(--green); font-weight: 600; }

.rc-flow {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 6px 0; border-top: 1px solid var(--line); margin-bottom: 4px;
}
.rc-flow svg { flex: 0 0 120px; }

.rc-manual {
  display: flex; align-items: center; gap: 8px;
  padding-top: 8px; border-top: 1px solid var(--line); margin-top: 6px;
}

.runner-card .form-block { border-top: 1px solid var(--line); padding-top: 8px; }

@media (max-width: 760px) {
  .runner-card { padding: 14px; }
  .rc-name { font-size: 16px; }
  .rc-prices { grid-template-columns: repeat(2, 1fr); }
  .rc-value { font-size: 19px; }
  .rc-flow svg { flex: 1 1 100%; width: 100% !important; }
}

/* ---------- Picks: confluence across sources ---------- */

.pick-card {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 10px; padding: 12px 14px; margin-bottom: 10px;
}
.pick-card.has-edge { border-color: var(--green); background: rgba(63,185,80,.06); }

.pick-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.pick-name { font-weight: 600; font-size: 15px; }
.pick-angles { text-align: center; flex: 0 0 auto; }
.pick-count {
  font-size: 24px; font-weight: 700; color: var(--teal);
  line-height: 1; font-variant-numeric: tabular-nums;
}

.pick-price {
  display: flex; gap: 12px; align-items: center; flex-wrap: wrap;
  margin: 8px 0; padding: 7px 9px; border-radius: 8px;
  background: var(--bg); font-variant-numeric: tabular-nums; font-size: 13px;
}
.pick-price.ok { background: rgba(63,185,80,.12); }

.pick-fire { font-size: 12px; padding: 2px 0; }
.pick-fire.ang-price  { color: var(--blue); font-weight: 600; }
.pick-fire.ang-money  { color: var(--teal); }
.pick-fire.ang-form   { color: var(--green); }
.pick-fire.ang-weight { color: var(--indigo, #a5b4fc); }
.pick-against { font-size: 12px; color: var(--amber); padding: 2px 0; }

@media (max-width: 760px) {
  .pick-card { padding: 14px; }
  .pick-name { font-size: 16px; }
  .pick-count { font-size: 28px; }
}

/* ---------- daily review ---------- */
.rev-row {
  display: flex; align-items: baseline; justify-content: space-between; gap: 10px;
  padding: 7px 0; border-top: 1px solid var(--line); font-size: 13px; flex-wrap: wrap;
}
.rev-row.won { color: var(--green); }
.rev-why { color: var(--amber); font-size: 12px; }
@media (max-width: 760px) {
  .rev-row { flex-direction: column; gap: 2px; padding: 10px 0; }
}

.pick-form {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 6px 0; margin-bottom: 4px; font-size: 12px;
}

.pick-card.near-miss { opacity: .72; border-style: dashed; }

/* ---------- the bet call ---------- */
.bet-call {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 14px; margin: 8px 0 6px; border-radius: 10px;
  background: rgba(63,185,80,.14); border: 1px solid var(--green);
}
.bet-call.tier-weak { background: rgba(210,153,34,.12); border-color: var(--amber); }
.bet-action { font-size: 16px; font-weight: 700; }
.bet-stake {
  font-size: 24px; font-weight: 700; color: var(--green);
  font-variant-numeric: tabular-nums; white-space: nowrap;
}
.bet-call.tier-weak .bet-stake { color: var(--amber); }
.bet-meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }

@media (max-width: 760px) {
  .bet-action { font-size: 17px; }
  .bet-stake { font-size: 27px; }
}

.filter-row .chk { display: flex; align-items: center; gap: 6px; white-space: nowrap;
                   text-transform: none; letter-spacing: 0; font-weight: 500; }
.filter-row .chk input { width: 18px; height: 18px; }
@media (max-width: 760px) { .filter-row .chk input { width: 22px; height: 22px; } }
.race-item .win-row { color: var(--green); font-weight: 600; }
