/* ── Pick widget (game card) — clickable odds cells ──
   "The odds you see is the thing you click." Each cell folds the read-only
   odds value and the clickable pick target into one unit per the Phase 5
   UI-SPEC (05-UI-SPEC.md). Colors come from base.html :root tokens + the alpha
   values listed in the UI-SPEC §Color. No off-palette hex. */

.picks-widget {
  font-size: .85rem;
}

.picks-rows {
  display: flex;
  flex-direction: column;
  gap: 1rem; /* md (web) — gap between market groups */
}

/* ── Market group: uppercase label + two cells ── */
.odds-pick-group {
  display: flex;
  flex-direction: column;
  gap: .5rem;
}

.odds-pick-label {
  font-size: .6rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--muted);
}

.odds-pick-cells {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: .5rem;
}

/* ── Clickable odds cell: resting ── */
.odds-pick-cell {
  position: relative;
  overflow: hidden;
  background: rgba(0, 0, 0, .25);
  color: var(--card-text);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: .5rem;
  min-height: 44px;
  padding: .5rem .75rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: .25rem;
  cursor: pointer;
  text-align: left;
  width: 100%;
  transition: background .15s, border-color .15s;
}

/* Top row: side label (left) + distribution % (right) */
.odds-pick-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: .5rem;
}

/* Side label */
.odds-pick-side {
  font-size: .8rem;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Distribution % (top-right, muted, tabular) */
.odds-pick-dist {
  font-size: .72rem;
  font-weight: 600;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

/* Odds value (line + price) — single emphasis weight */
.odds-pick-value {
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.2;
}

/* Price in muted parens */
.odds-pick-price {
  color: rgba(255, 255, 255, .65);
  font-weight: 600;
}

/* "Your pick" subtext (selected only) */
.odds-pick-yourpick {
  font-size: .65rem;
  font-weight: 600;
  color: var(--teal);
}

/* In-cell distribution fill bar — bottom inner edge */
.odds-pick-fill {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  background: rgba(255, 255, 255, .06);
  pointer-events: none;
}

/* Hover (unselected, unlocked) */
.odds-pick-cell:hover:not(.selected):not([disabled]):not(.locked) {
  border-color: var(--teal);
  background: rgba(52, 211, 153, .06);
}

/* Focus (keyboard) — never remove the outline */
.odds-pick-cell:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: 2px;
}

/* Selected ("your pick") */
.odds-pick-cell.selected {
  background: rgba(52, 211, 153, .15);
  border-color: var(--teal);
}
.odds-pick-cell.selected .odds-pick-value {
  color: #fff;
}
.odds-pick-cell.selected .odds-pick-fill {
  background: rgba(52, 211, 153, .10);
}

/* Selected + hover */
.odds-pick-cell.selected:hover:not([disabled]):not(.locked) {
  background: rgba(52, 211, 153, .22);
}

/* Active / pressed */
.odds-pick-cell:active {
  background: rgba(52, 211, 153, .28);
}

/* Disabled / locked — settled side keeps .selected styling AND dims */
.odds-pick-cell[disabled],
.odds-pick-cell.locked {
  opacity: .6;
  cursor: not-allowed;
  pointer-events: none;
}

/* Loading spinner inside a cell (replaces the % during in-flight submit) */
.odds-pick-cell .spinner-border-sm {
  width: .7rem;
  height: .7rem;
}

/* ── AI badge (used by Tasks 6/7) ── */
.ai-badge {
  color: var(--ai-purple);
  background: rgba(167, 139, 250, .15);
  border-radius: 999px;
  font-size: .65rem;
  font-weight: 600;
  padding: .15rem .5rem;
}

/* Error message under the rows */
.pick-error {
  font-size: .7rem;
  color: var(--loss);
  margin-top: .15rem;
}

/* Visually-hidden live region for announcements */
.picks-live {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ── Mobile ── */
@media (max-width: 576px) {
  .odds-pick-cell {
    min-height: 44px;
    padding: .5rem .6rem;
  }
  .odds-pick-side {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  .odds-pick-value {
    font-size: .85rem;
  }
}
