/* Your turn, the same in every game: this green, whatever your seat colour, and a notice in
   the middle of the screen for a moment when the turn begins (turnsplash.js). */
:root { --turn-green: #1f9d55; }

.turn-splash {
  position: fixed; left: 50%; top: 42%; z-index: 1200; transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none;
  padding: 18px 34px; border-radius: 18px; text-align: center; max-width: min(520px, 90vw);
  background: var(--turn-green); color: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.85), 0 18px 48px rgba(0, 0, 0, 0.5);
  /* its own layer: the browser only moves and fades it, nothing under it is repainted */
  will-change: transform, opacity; contain: layout paint;
  animation: turn-splash 2.2s ease-out forwards;
}
.turn-splash.last { background: #c26a00; }
.turn-splash b { font-size: clamp(1.8rem, 6vw, 2.8rem); font-weight: 850; letter-spacing: 0.02em; text-shadow: 0 2px 3px rgba(0, 0, 0, 0.35); }
.turn-splash span { font-size: 0.95rem; text-shadow: 0 1px 2px rgba(0, 0, 0, 0.35); }
@keyframes turn-splash {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(0.7); }
  12% { opacity: 1; transform: translate(-50%, -50%) scale(1.06); }
  20% { transform: translate(-50%, -50%) scale(1); }
  80% { opacity: 1; }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .turn-splash { animation: turn-splash-fade 2.2s linear forwards; } }
@keyframes turn-splash-fade { 0%, 80% { opacity: 1; } 100% { opacity: 0; } }

/* The frame flash when a turn begins. Each game puts the glow on a ::after layer over its table
   and runs this on it: only opacity changes, so the map under it is not repainted every frame
   (animating box-shadow on the table itself made the whole board repaint, a visible hiccup). */
@keyframes turn-glow { 40% { opacity: 1; } }

/* The badge by the turn line, where a game shows one. */
.your-turn-pill {
  display: inline-block; flex: 0 0 auto; white-space: nowrap; padding: 1px 10px; border-radius: 999px;
  background: var(--turn-green); color: #fff; font-weight: 750; text-shadow: 0 1px 1px rgba(0, 0, 0, 0.35);
}
