/* table-fx.css — table motion layer (js/table-fx.js): ghosts on #tbl-fx,
   ring colours, table-settings sheet. Transform / opacity only; nothing
   here moves layout. Sizes scale with the seat scale (--s). */

#tbl-fx { position: absolute; inset: 0; pointer-events: none; z-index: 7; overflow: hidden; }
#tbl-fx .fxg {
  position: absolute;
  transform: translate(-50%, -50%);
  pointer-events: none;
  will-change: transform, opacity;
}

/* chip stacks: 1–5 chips, offset upward (denomination colours) */
#tbl-fx .fx-stack {
  position: relative;
  display: block;
  width: calc(var(--s, 1) * 17px);
  height: calc(var(--s, 1) * 17px + (var(--n, 1) - 1) * var(--s, 1) * 2.8px);
}
#tbl-fx .fx-stack i {
  position: absolute;
  left: 0;
  bottom: calc(var(--k, 0) * var(--s, 1) * 2.8px);
  width: calc(var(--s, 1) * 17px);
  height: calc(var(--s, 1) * 17px);
  filter: drop-shadow(0 1px 1px #000a);
}
#tbl-fx .fx-chip { display: block; width: 100%; height: 100%; }
#tbl-fx .fx-fly.pot .fx-stack { transform: scale(1.2); }
#tbl-fx .fx-pile { width: calc(var(--s, 1) * 40px); height: auto; display: block; }

/* the card back that covers a face during a flip (same back as .cardback) */
#tbl-layer .pcard .fx-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  border-radius: inherit;
  background: repeating-linear-gradient(45deg, #1b1b1f 0 3px, #24242a 3px 6px) center / cover;
  box-shadow: inset 0 0 0 1.5px #D4B98A;
  pointer-events: none;
}
#tbl-fx .fx-muck .fx-back {
  display: block;
  width: calc(var(--s, 1) * 16px);
  height: calc(var(--s, 1) * 23px);
  border-radius: 2px;
  background: repeating-linear-gradient(45deg, #1b1b1f 0 3px, #24242a 3px 6px);
  border: 1.5px solid #D4B98A;
  box-sizing: border-box;
}

/* speech pill (Check) and the +won pop */
#tbl-fx .fx-say, #tbl-fx .fx-pop {
  white-space: nowrap;
  font-family: 'Sora', 'Manrope', system-ui, sans-serif;
  font-weight: 800;
  letter-spacing: .02em;
}
#tbl-fx .fx-say {
  padding: 1px 8px;
  border-radius: 9px;
  background: #0a0d12e6;
  border: 1px solid #ffffff33;
  color: #dfe6ee;
  font-size: calc(var(--s, 1) * 10px);
}
#tbl-fx .fx-pop {
  color: #F4F2EE;
  font-family: 'Barlow Condensed', 'Sora', sans-serif;
  font-size: calc(var(--s, 1) * 17px);
  text-shadow: 0 1px 0 #000, 0 2px 6px rgba(0,0,0,.85);
}

/* rings around the avatar (muted, owner 2026-10-07): all-in burst in
   red-amber #C0674A, winner ring champagne #D4B98A with a soft glow */
#tbl-fx .fx-ring {
  width: calc(var(--s, 1) * 58px);
  height: calc(var(--s, 1) * 58px);
  border-radius: 50%;
  box-sizing: border-box;
}
#tbl-fx .fx-ring.allin { border: 2px solid rgba(192,103,74,.6); box-shadow: none; }
#tbl-fx .fx-ring.win { border: 2px solid #D4B98A; box-shadow: 0 0 10px 2px rgba(212,185,138,.32); }

/* action clock ring: amber at 5 s, red at 3 s, gold while the time bank runs
   (data-ring set by PF.fx.clockFx; overrides the actor / hero colours) */
.seat .ring circle.fill { transition: stroke-dashoffset .1s linear, stroke .25s ease; }
.seat[data-ring="amber"] .ring circle.fill { stroke: #ffa21f; }
.seat[data-ring="red"] .ring circle.fill { stroke: #ff3b4a; }
.seat[data-ring="bank"] .ring circle.fill { stroke: #D4B98A; }
.seat[data-ring="amber"] .secb { background: #ffa21f; color: #241a02; }
.seat[data-ring="red"] .secb { background: #ff3b4a; color: #fff; }
.seat[data-ring="bank"] .secb { background: #D4B98A; color: #241a02; }

/* table settings sheet (sound / vibrate / reduced motion) */
.tset { padding: 6px 24px 24px; display: flex; flex-direction: column; gap: 4px; }
.tset label {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 44px; border-bottom: 1px solid #ffffff12; font-size: 14px; color: #e6ebf1;
}
.tset input[type="checkbox"] { width: 20px; height: 20px; accent-color: #2fd682; }
.tset input[type="range"] { width: 150px; accent-color: #2fd682; }
.tset input[type="range"]:disabled { opacity: .4; }
.tset .hint { font-size: 11.5px; color: #8c8c8c; margin-top: 8px; line-height: 1.4; }

@media (prefers-reduced-motion: reduce) {
  .seat .ring circle.fill { transition: none; }
}

/* winner sparkle burst + gold WINNER foil word removed (owner 2026-10-07:
   subtle, premium, never gaudy): the winner gets a champagne ring + soft glow */

/* steady seat rings (Flutter SeatFxRing): all-in holds a thin red-amber ring
   with a breathing glow for the rest of the hand; the winner holds a
   champagne ring + soft glow until the next hand. Behind the avatar. */
#tbl-layer .seat.allin::before, #tbl-layer .seat.winner::before {
  content: ""; position: absolute; left: -31px; top: -31px; width: 62px; height: 62px; border-radius: 50%;
  box-sizing: border-box; pointer-events: none; z-index: 1;
}
#tbl-layer .seat.allin::before { border: 1.6px solid rgba(192,103,74,.72); animation: fxBreathAllin 1.6s ease-in-out infinite alternate; }
#tbl-layer .seat.winner::before { border: 2px solid #D4B98A; animation: fxBreathWin 1.4s ease-in-out infinite alternate; }
@keyframes fxBreathAllin { from { box-shadow: 0 0 4px 1px rgba(192,103,74,.14); } to { box-shadow: 0 0 8px 2px rgba(192,103,74,.26); } }
@keyframes fxBreathWin { from { box-shadow: 0 0 5px 1px rgba(212,185,138,.16), inset 0 0 0 1px rgba(243,236,223,.18); } to { box-shadow: 0 0 10px 3px rgba(212,185,138,.34), inset 0 0 0 1px rgba(243,236,223,.18); } }
@media (prefers-reduced-motion: reduce) { #tbl-layer .seat.allin::before, #tbl-layer .seat.winner::before { animation: none; } }
