/* pa/public/css/game.css — only what is specific to Presidents' table.
   Page chrome, seats, cards, hand tray, lobby and reveal rows come from
   the shared kit stylesheets. */

/* Room reserved around the felt: top bar + status strip + info strip +
   this game's tray (role chip, up to a full hand of cards, Play / Pass). */
.table-felt { --tbl-felt-chrome: 400px; }

/* ── Status strip: round counter + direction arrow ── */
#direction-arrow {
  display: inline-block;
  color: var(--tbl-accent);
  font-weight: 800;
  transition: transform 0.25s ease;
}
#direction-arrow.reversed { transform: scaleX(-1); }

/* ── Centre pile ── */
#center-pile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  z-index: 5;
}
#pile-cards { display: flex; justify-content: center; height: 62px; }
#pile-cards .pcard { width: 44px; height: 62px; font-size: 14px; margin-left: -14px; }
#pile-cards .pcard:first-child { margin-left: 0; }
#pile-empty-label { font-size: 0.72rem; color: var(--tbl-text-muted); text-transform: uppercase; letter-spacing: 0.06em; }
#pile-need-label { font-size: 0.7rem; color: var(--tbl-accent); font-weight: 700; text-align: center; max-width: 220px; }

/* ── Seat tokens: role badge in the body, card count / "3rd out" in the foot ── */
.tk-seat.finished { opacity: 0.55; }
.opp-count { font-size: 0.68rem; color: var(--tbl-text-mid); font-weight: 400; }
.opp-out-label { font-size: 0.66rem; font-weight: 700; color: var(--tbl-text-muted); }
.role-badge {
  font-size: 0.6rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding: 1px 6px;
  border-radius: 999px;
  white-space: nowrap;
}
.role-badge.president { background: rgba(255, 215, 0, 0.18); color: var(--tbl-accent); border: 1px solid var(--tbl-accent); }
.role-badge.vice_president { background: rgba(255, 215, 0, 0.08); color: var(--tbl-accent); border: 1px solid rgba(255, 215, 0, 0.4); }
.role-badge.vice_asshole { background: rgba(209, 69, 58, 0.08); color: var(--danger); border: 1px solid rgba(209, 69, 58, 0.4); }
.role-badge.asshole { background: rgba(209, 69, 58, 0.15); color: var(--danger); border: 1px solid var(--danger); }

/* ── Tray ── */
#my-status-row { flex-wrap: wrap; justify-content: center; }
.must-lead-banner {
  text-align: center;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--tbl-on-accent);
  background: var(--tbl-accent);
  padding: 4px 12px;
  border-radius: 999px;
  max-width: 100%;
}
#hand-area { gap: 10px; }
#hand-area .pcard.legal { cursor: pointer; box-shadow: 0 0 0 2px var(--tbl-accent), 0 2px 4px rgba(0,0,0,0.3); }
#hand-area .pcard.illegal { opacity: 0.4; cursor: default; box-shadow: 0 2px 4px rgba(0,0,0,0.3); }
#hand-area .pcard.selected { transform: translateY(-10px); box-shadow: 0 0 0 3px var(--tbl-accent), 0 6px 14px rgba(0,0,0,0.45); }
#hand-area .pcard.legal.selected:hover { transform: translateY(-10px); }
@media (max-width: 480px) {
  #hand-area { gap: 6px; }
  #hand-area .pcard { width: 40px; height: 58px; font-size: 13px; }
  #pile-cards .pcard { width: 38px; height: 54px; font-size: 12px; margin-left: -18px; }
}

/* ── Direction-reversed banner over the felt (non-blocking, fades out) ── */
.direction-banner {
  position: absolute;
  inset: 0;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.25s ease;
  background: radial-gradient(ellipse at center, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0) 70%);
}
.direction-banner.show { opacity: 1; }
.direction-banner-title { font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,0.8); }
.direction-banner-cards { display: flex; gap: 6px; }
.direction-banner-cards .pcard { width: 46px; height: 64px; font-size: 14px; }
.direction-banner-sub { font-size: 0.78rem; font-weight: 600; color: #fff; text-shadow: 0 1px 4px rgba(0,0,0,0.8); }

/* ── Dealing screen ── */
#screen-dealing-body { width: 100%; max-width: 420px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
#dealing-assign-list { width: 100%; display: flex; flex-direction: column; gap: 8px; }
.deal-row {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--tbl-panel-bg);
  border: 1px solid var(--tbl-panel-border);
  border-radius: 10px;
  padding: 8px 12px;
}
.deal-name { flex: 1; font-weight: 600; font-size: 0.9rem; color: var(--tbl-text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.deal-controls { display: flex; align-items: center; gap: 10px; }
.deal-controls .icon-btn { background: rgba(255,255,255,0.05); border-color: var(--tbl-panel-border); color: var(--tbl-text); }
.deal-controls .icon-btn:hover { border-color: var(--tbl-accent); background: var(--tbl-panel-bg); }
.deal-count { font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: var(--tbl-accent); min-width: 28px; text-align: center; }
#dealing-remaining { font-size: 0.85rem; font-weight: 600; }
#dealing-timer { color: var(--tbl-text-muted); font-size: 0.8rem; }
#dealing-timer:empty { display: none; }

/* ── Round summary + standings ── */
.reveal-hand-row.president { border-color: var(--tbl-accent); }
.reveal-hand-row.vice_president { border-color: rgba(255, 215, 0, 0.4); }
.reveal-hand-row.vice_asshole { border-color: rgba(209, 69, 58, 0.4); }
.reveal-hand-row.asshole { border-color: var(--danger); }
.reveal-place-col { display: flex; align-items: center; gap: 10px; min-width: 0; }
.reveal-place-num { font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; min-width: 24px; text-align: center; color: var(--tbl-text-mid); }
.reveal-name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gameover-standings { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 6px; }
.gameover-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  background: var(--tbl-panel-bg);
  border: 1px solid var(--tbl-panel-border);
  border-radius: 8px;
  font-size: 0.85rem;
}
.gameover-row.winner { border-color: var(--tbl-accent); }
.gameover-row .times-pres { color: var(--tbl-accent); font-weight: 700; }
