:root {
  --bg: #e6eadf;
  --paper: rgba(250, 247, 240, 0.84);
  --paper-strong: #fffaf0;
  --ink: #13211b;
  --muted: #50615b;
  --line: rgba(19, 33, 27, 0.14);
  --teal: #0f6a4a;
  --teal-deep: #0a4a34;
  --amber: #f0ad2c;
  --coral: #e25e32;
  --lime: #dcff6d;
  --felt-dark: #0a3a24;
  --felt-mid: #115637;
  --felt-light: #1d7a50;
  --shadow: 0 24px 70px rgba(23, 28, 18, 0.16);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Avenir Next", "Trebuchet MS", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top right, rgba(15, 106, 74, 0.18), transparent 28%),
    radial-gradient(circle at left center, rgba(240, 173, 44, 0.12), transparent 24%),
    linear-gradient(145deg, #f3f1e8, #e6eadf 56%, #d8ddd1);
}

button,
input {
  font: inherit;
}

button {
  border: 0;
  border-radius: 16px;
  padding: 0.9rem 1rem;
  font-weight: 800;
  color: white;
  background: linear-gradient(135deg, var(--teal), var(--teal-deep));
  cursor: pointer;
  transition: transform 140ms ease, filter 140ms ease, box-shadow 140ms ease;
}

button:hover {
  transform: translateY(-1px);
  filter: saturate(1.08);
}

button:disabled {
  cursor: not-allowed;
  filter: grayscale(0.35);
  opacity: 0.55;
  transform: none;
  box-shadow: none;
}

button.secondary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.68);
}

input {
  width: 100%;
  padding: 0.9rem 1rem;
  border: 1px solid rgba(21, 38, 36, 0.18);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.8);
}

.hidden {
  display: none !important;
}

.shell {
  width: min(1580px, calc(100% - 0.8rem));
  margin: 0 auto;
  padding: 0.55rem 0 0.8rem;
}

.hero {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 0.2rem 0 0.45rem;
}

.eyebrow,
.meta-label {
  margin: 0;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero h1 {
  margin: 0;
  font-size: clamp(1.35rem, 2.1vw, 1.9rem);
  line-height: 1;
}

.hero-actions {
  display: flex;
  gap: 0.85rem;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.hero-chip {
  padding: 0.72rem 0.88rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(21, 38, 36, 0.1);
  font-weight: 800;
  font-size: 0.9rem;
}

.layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 0.8rem;
}

.panel,
.table-panel,
.status-card {
  border: 1px solid var(--line);
  background: var(--paper);
  backdrop-filter: blur(20px);
  box-shadow: var(--shadow);
}

.panel,
.table-panel {
  border-radius: 30px;
}

.panel {
  padding: 0.95rem;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.stack {
  display: grid;
  gap: 0.85rem;
}

.divider {
  text-align: center;
  color: var(--muted);
  font-weight: 700;
  padding: 0.5rem 0;
}

.room-code-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

.room-code {
  font-size: 1.55rem;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.room-actions {
  margin: 1rem 0;
}

.status-card {
  border-radius: 22px;
  padding: 0.95rem 1rem;
  margin-top: 0.85rem;
  transition: border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.status-card p {
  margin: 0.35rem 0 0;
}

.status-card--neutral {
  border-color: rgba(21, 38, 36, 0.12);
}

.status-card--calm {
  border-color: rgba(21, 116, 109, 0.28);
  background: linear-gradient(135deg, rgba(21, 116, 109, 0.12), rgba(255, 249, 241, 0.84));
}

.status-card--success {
  border-color: rgba(73, 157, 92, 0.34);
  background: linear-gradient(135deg, rgba(128, 221, 139, 0.14), rgba(255, 249, 241, 0.84));
}

.status-card--warning {
  border-color: rgba(240, 173, 44, 0.38);
  background: linear-gradient(135deg, rgba(240, 173, 44, 0.18), rgba(255, 249, 241, 0.84));
  box-shadow: 0 0 0 3px rgba(240, 173, 44, 0.08), var(--shadow);
}

.status-card--danger {
  border-color: rgba(226, 94, 50, 0.42);
  background: linear-gradient(135deg, rgba(226, 94, 50, 0.18), rgba(255, 249, 241, 0.86));
  box-shadow: 0 0 0 4px rgba(226, 94, 50, 0.1), var(--shadow);
}

.status-card--accent {
  border-color: rgba(100, 113, 255, 0.32);
  background: linear-gradient(135deg, rgba(100, 113, 255, 0.14), rgba(255, 249, 241, 0.86));
}

.status-card--special {
  border-color: rgba(198, 122, 31, 0.38);
  background: linear-gradient(135deg, rgba(198, 122, 31, 0.18), rgba(255, 249, 241, 0.86));
}

.drawn-card {
  margin: 0.6rem 0 0.9rem;
  min-height: 170px;
  display: grid;
  place-items: center;
}

.drawn-actions {
  display: grid;
  gap: 0.65rem;
}

.event-feed {
  list-style: none;
  margin: 0.7rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.65rem;
  max-height: 16rem;
  overflow: auto;
}

.event-feed li {
  padding: 0.75rem 0.85rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.72);
  font-size: 0.94rem;
}

.event-feed__item {
  border-left: 6px solid transparent;
}

.event-feed__item--neutral,
.event-feed__item--calm {
  border-left-color: rgba(21, 116, 109, 0.4);
}

.event-feed__item--info {
  border-left-color: rgba(59, 122, 231, 0.75);
  background: rgba(236, 244, 255, 0.88);
}

.event-feed__item--success {
  border-left-color: rgba(65, 166, 95, 0.82);
  background: rgba(237, 251, 239, 0.92);
}

.event-feed__item--warning {
  border-left-color: rgba(240, 173, 44, 0.9);
  background: rgba(255, 247, 225, 0.95);
  font-weight: 800;
}

.event-feed__item--danger {
  border-left-color: rgba(226, 94, 50, 0.9);
  background: rgba(255, 238, 232, 0.95);
  font-weight: 800;
}

.event-feed__item--accent {
  border-left-color: rgba(100, 113, 255, 0.84);
  background: rgba(240, 241, 255, 0.95);
}

.event-feed__item--special {
  border-left-color: rgba(198, 122, 31, 0.88);
  background: rgba(255, 244, 226, 0.95);
  font-weight: 800;
}

.table-panel {
  padding: 0.55rem;
}

.table-banner {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 0.78rem 0.95rem;
  border-radius: 24px;
  background:
    linear-gradient(120deg, rgba(21, 116, 109, 0.14), rgba(255, 255, 255, 0.55)),
    linear-gradient(45deg, rgba(240, 173, 44, 0.18), transparent 55%);
}

.table-banner h2 {
  margin: 0.18rem 0 0;
  font-size: clamp(1.08rem, 2vw, 1.65rem);
}

.timer-pill {
  padding: 0.75rem 1rem;
  border-radius: 999px;
  background: rgba(21, 38, 36, 0.92);
  color: white;
  font-weight: 800;
}

.players-board {
  margin-top: 0.55rem;
  border-radius: 34px;
}

.table-felt-shell {
  position: relative;
  min-height: clamp(640px, 82vh, 940px);
  border-radius: 34px;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 44%, rgba(255, 255, 255, 0.1), transparent 28%),
    radial-gradient(circle at center, rgba(255, 255, 255, 0.04), transparent 48%),
    radial-gradient(circle at 30% 26%, rgba(255, 255, 255, 0.05), transparent 20%),
    linear-gradient(160deg, var(--felt-light), var(--felt-dark) 72%);
  border: 10px solid rgba(72, 44, 17, 0.56);
  box-shadow:
    inset 0 0 0 3px rgba(255, 240, 214, 0.12),
    inset 0 30px 70px rgba(255, 255, 255, 0.04),
    inset 0 -40px 70px rgba(0, 0, 0, 0.14),
    0 28px 70px rgba(20, 25, 18, 0.18);
}

.motion-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 8;
  overflow: hidden;
}

.table-felt-shell::before {
  content: "";
  position: absolute;
  inset: 1.5rem;
  border-radius: 999px;
  border: 1px dashed rgba(244, 236, 206, 0.12);
}

.center-row {
  position: absolute;
  left: 50%;
  top: 49%;
  transform: translate(-50%, -50%);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 152px));
  gap: 0.62rem;
  z-index: 7;
}

.center-pile-card {
  border-radius: 24px;
  padding: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(5, 37, 26, 0.32);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
  text-align: center;
}

.center-pile-card--highlighted {
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.06),
    0 0 0 4px rgba(220, 255, 109, 0.3),
    0 0 24px rgba(220, 255, 109, 0.22);
}

.center-pile-card .meta-label {
  color: rgba(255, 247, 228, 0.7);
}

.card-face {
  min-height: 122px;
  display: grid;
  place-items: center;
  margin: 0.45rem 0;
}

.seat-orbit {
  position: absolute;
  inset: 1rem 1rem 1.2rem;
}

.empty-board {
  min-height: 460px;
}

.empty-board-copy {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin: 0;
  color: rgba(255, 250, 241, 0.84);
  font-weight: 800;
  text-align: center;
}

.player-seat {
  position: absolute;
  left: var(--seat-x);
  top: var(--seat-y);
  transform: translate(-50%, -50%);
  width: clamp(188px, 18vw, 236px);
  z-index: 2;
}

.player-seat--self {
  width: clamp(268px, 31vw, 340px);
  z-index: 4;
}

.player-panel {
  position: relative;
  padding: 0.72rem;
  border-radius: 28px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background:
    linear-gradient(160deg, rgba(255, 249, 237, 0.95), rgba(246, 237, 224, 0.84)),
    linear-gradient(45deg, rgba(21, 116, 109, 0.05), transparent 60%);
  box-shadow:
    0 16px 40px rgba(10, 22, 21, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.65);
  overflow: hidden;
}

.player-panel::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.22), transparent);
  transform: translateX(-100%);
}

.player-panel--active {
  border-color: rgba(220, 255, 109, 0.54);
  background:
    linear-gradient(135deg, rgba(220, 255, 109, 0.44), rgba(255, 251, 243, 0.96)),
    radial-gradient(circle at top right, rgba(226, 94, 50, 0.18), transparent 36%);
  box-shadow:
    0 0 0 5px rgba(220, 255, 109, 0.46),
    0 0 0 14px rgba(220, 255, 109, 0.1),
    0 26px 60px rgba(5, 20, 18, 0.32);
  filter: saturate(1.18) brightness(1.03);
}

.player-panel--active::before {
  animation: sweep 1.8s linear infinite;
}

.player-panel--self {
  outline: 2px solid rgba(21, 116, 109, 0.32);
}

.player-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
  margin-bottom: 0.5rem;
}

.player-name {
  margin: 0;
  font-size: 1rem;
  font-weight: 900;
}

.player-seat--self .player-name {
  font-size: 1.08rem;
}

.player-meta {
  margin: 0.25rem 0 0;
  color: var(--muted);
  font-size: 0.8rem;
}

.active-badge {
  padding: 0.4rem 0.56rem;
  border-radius: 999px;
  background: rgba(21, 38, 36, 0.95);
  color: var(--lime);
  font-size: 0.66rem;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.card-grid {
  display: grid;
  gap: 0.38rem;
}

.player-seat--self .card-grid {
  gap: 0.46rem;
}

.card-slot {
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  display: block;
  border-radius: 18px;
}

.card-slot:hover {
  box-shadow: none;
}

.card-slot--selectable .playing-card,
.card-slot--selectable .slot-empty {
  box-shadow:
    0 0 0 3px rgba(21, 116, 109, 0.18),
    0 12px 20px rgba(20, 25, 18, 0.12);
}

.card-slot--selected .playing-card,
.card-slot--selected .slot-empty {
  box-shadow:
    0 0 0 4px rgba(226, 94, 50, 0.75),
    0 16px 30px rgba(21, 38, 36, 0.18);
}

.card-slot--highlighted .playing-card,
.card-slot--highlighted .slot-empty {
  box-shadow:
    0 0 0 4px rgba(255, 225, 120, 0.82),
    0 0 22px rgba(255, 225, 120, 0.2),
    0 14px 26px rgba(21, 38, 36, 0.16);
}

.card-slot--selectable:hover .playing-card,
.card-slot--selectable:hover .slot-empty {
  transform: translateY(-2px);
}

.playing-card,
.slot-empty {
  position: relative;
  width: 100%;
  aspect-ratio: 180 / 252;
  border-radius: 16px;
  overflow: hidden;
  transition: transform 140ms ease, box-shadow 140ms ease;
}

.playing-card img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.playing-card--back {
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.16), transparent 28%),
    repeating-linear-gradient(
      45deg,
      rgba(255, 255, 255, 0.08) 0,
      rgba(255, 255, 255, 0.08) 8px,
      transparent 8px,
      transparent 16px
    ),
    linear-gradient(145deg, #194f63, #0f3b4e 58%, #102734);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow:
    inset 0 0 0 2px rgba(255, 255, 255, 0.16),
    0 10px 22px rgba(11, 29, 35, 0.16);
}

.playing-card__back-mark {
  padding: 0.44rem 0.6rem;
  border-radius: 999px;
  background: rgba(255, 246, 225, 0.15);
  color: #fff3d8;
  font-size: 0.84rem;
  font-weight: 900;
  letter-spacing: 0.18em;
}

.playing-card--center {
  width: 88px;
  max-width: 100%;
}

.playing-card--drawn {
  width: 104px;
}

.playing-card--reveal {
  width: 128px;
}

.playing-card-stack {
  position: relative;
  width: 88px;
  max-width: 100%;
}

.playing-card-stack::before,
.playing-card-stack::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 16px;
  background: linear-gradient(145deg, #1b5c72, #10384a);
  border: 1px solid rgba(255, 255, 255, 0.14);
}

.playing-card-stack::before {
  transform: translate(10px, 10px);
  opacity: 0.42;
}

.playing-card-stack::after {
  transform: translate(5px, 5px);
  opacity: 0.65;
}

.playing-card-stack .playing-card {
  position: relative;
  z-index: 2;
}

.deck-count-badge {
  position: absolute;
  right: -10px;
  bottom: -10px;
  min-width: 44px;
  height: 44px;
  padding: 0 0.7rem;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--amber), var(--coral));
  color: white;
  font-weight: 900;
  box-shadow: 0 12px 22px rgba(10, 20, 18, 0.24);
  z-index: 3;
}

.discard-placeholder {
  width: 88px;
  aspect-ratio: 180 / 252;
  max-width: 100%;
  border-radius: 16px;
  display: grid;
  place-items: center;
  text-align: center;
  color: rgba(255, 245, 224, 0.78);
  border: 1px dashed rgba(255, 255, 255, 0.24);
  background: rgba(7, 39, 36, 0.24);
  padding: 0.8rem;
  font-weight: 800;
}

.body--in-room .hero {
  align-items: center;
  padding: 0.05rem 0 0.2rem;
}

.body--in-room .eyebrow {
  display: none;
}

.body--in-room .hero h1 {
  font-size: clamp(0.92rem, 1.1vw, 1.08rem);
  margin: 0;
  line-height: 1;
}

.body--in-room .hero-copy {
  display: none;
}

.body--in-room .hero-chip {
  display: none;
}

.body--in-room .hero-actions {
  gap: 0.45rem;
}

.body--in-room .hero-actions button {
  padding: 0.62rem 0.85rem;
  border-radius: 14px;
  font-size: 0.88rem;
}

.body--in-room .shell {
  width: min(100%, calc(100% - 0.35rem));
  padding-top: 0.28rem;
  padding-bottom: 0.35rem;
}

.body--in-room .layout {
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 0.45rem;
  align-items: stretch;
}

.body--in-room .sidebar {
  gap: 0.65rem;
}

.body--in-room .panel {
  padding: 0.78rem;
  border-radius: 24px;
}

.body--in-room .room-actions {
  margin: 0.75rem 0;
}

.body--in-room .status-card {
  padding: 0.78rem 0.82rem;
  margin-top: 0.6rem;
}

.body--in-room .status-card p {
  font-size: 0.9rem;
}

.body--in-room .table-panel {
  padding: 0.42rem;
  border-radius: 28px;
}

.body--in-room .table-banner {
  padding: 0.62rem 0.8rem;
  border-radius: 20px;
}

.body--in-room .table-banner h2 {
  font-size: clamp(0.96rem, 1.4vw, 1.2rem);
}

.body--in-room .players-board {
  margin-top: 0.35rem;
}

.body--in-room .table-felt-shell {
  min-height: clamp(700px, calc(100vh - 5.7rem), 1040px);
  border-width: 8px;
}

.players-board[data-player-count="2"] .table-felt-shell {
  min-height: clamp(720px, calc(100vh - 5.45rem), 1080px);
}

.players-board[data-player-count="2"] .seat-orbit {
  inset: 0.5rem 0.8rem 0.55rem;
}

.players-board[data-player-count="2"] .player-seat--self {
  width: clamp(236px, 27vw, 300px);
}

.players-board[data-player-count="2"] .player-seat:not(.player-seat--self) {
  width: clamp(170px, 17vw, 210px);
}

.body--active-table .table-felt-shell::before {
  inset: 0.8rem;
}

.body--active-table .seat-orbit {
  inset: 0.55rem 0.6rem 0.75rem;
}

.body--active-table .player-seat {
  width: clamp(176px, 17vw, 220px);
}

.body--active-table .player-seat--self {
  width: clamp(244px, 28vw, 308px);
}

.body--active-table .player-panel {
  padding: 0.62rem;
  border-radius: 24px;
}

.body--active-table .player-header {
  margin-bottom: 0.42rem;
}

.body--active-table .player-name {
  font-size: 0.92rem;
}

.body--active-table .player-seat--self .player-name {
  font-size: 1rem;
}

.body--active-table .player-meta {
  font-size: 0.74rem;
}

.body--active-table .active-badge {
  padding: 0.34rem 0.48rem;
  font-size: 0.58rem;
}

.body--active-table .card-grid {
  gap: 0.32rem;
}

.body--active-table .player-seat--self .card-grid {
  gap: 0.38rem;
}

.slot-empty {
  display: grid;
  place-items: center;
  padding: 0.32rem;
  border: 1px dashed rgba(21, 38, 36, 0.2);
  background: rgba(21, 38, 36, 0.06);
  color: rgba(21, 38, 36, 0.42);
}

.slot-empty--highlighted {
  border-color: rgba(255, 225, 120, 0.8);
  box-shadow:
    0 0 0 4px rgba(255, 225, 120, 0.52),
    0 0 22px rgba(255, 225, 120, 0.16);
}

.slot-empty__copy {
  width: 100%;
  text-align: center;
}

.slot-empty__icon {
  width: 100%;
  height: 100%;
  min-height: 2.5rem;
  border-radius: 12px;
  background:
    radial-gradient(circle at 50% 28%, rgba(21, 38, 36, 0.14), transparent 0.28rem),
    radial-gradient(circle at 35% 52%, rgba(21, 38, 36, 0.11), transparent 0.24rem),
    radial-gradient(circle at 65% 52%, rgba(21, 38, 36, 0.11), transparent 0.24rem),
    radial-gradient(circle at 50% 76%, rgba(21, 38, 36, 0.14), transparent 0.28rem),
    linear-gradient(180deg, rgba(255, 255, 255, 0.4), rgba(21, 38, 36, 0.03));
  border: 1px solid rgba(21, 38, 36, 0.08);
}

.slot-empty__label {
  margin-top: 0.26rem;
  font-size: 0.54rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(21, 38, 36, 0.5);
}

.reveal-overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(12, 30, 28, 0.54);
  backdrop-filter: blur(10px);
  z-index: 30;
}

.reveal-card {
  width: min(440px, calc(100% - 2rem));
  border-radius: 30px;
  background: var(--paper-strong);
  padding: 1.35rem;
  box-shadow: 0 28px 80px rgba(16, 33, 31, 0.24);
}

.reveal-card h3 {
  margin: 0.45rem 0 0.55rem;
  font-size: 2rem;
}

.reveal-visual {
  min-height: 174px;
  display: grid;
  place-items: center;
  margin: 0.7rem 0;
}

.reveal-double {
  display: flex;
  gap: 0.9rem;
  flex-wrap: wrap;
  justify-content: center;
}

.playing-card--attempted {
  transform: scale(1.02);
  box-shadow:
    0 0 0 5px rgba(226, 94, 50, 0.92),
    0 0 24px rgba(226, 94, 50, 0.28),
    0 20px 34px rgba(21, 38, 36, 0.18);
}

.motion-arrow {
  position: absolute;
  left: var(--motion-x);
  top: var(--motion-y);
  width: var(--motion-length);
  height: 0;
  transform: rotate(var(--motion-angle));
  transform-origin: 0 50%;
  opacity: 0;
  animation: motion-arrow-travel 880ms ease forwards;
}

.motion-arrow__trail {
  position: absolute;
  left: 0;
  top: -2px;
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(220, 255, 109, 0.7), rgba(240, 173, 44, 0.98));
  box-shadow:
    0 0 12px rgba(220, 255, 109, 0.6),
    0 0 20px rgba(240, 173, 44, 0.24);
}

.motion-arrow--warning .motion-arrow__trail {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(226, 94, 50, 0.7), rgba(255, 216, 120, 0.98));
  box-shadow:
    0 0 12px rgba(226, 94, 50, 0.55),
    0 0 20px rgba(255, 216, 120, 0.24);
}

.motion-arrow__head {
  position: absolute;
  right: -2px;
  top: -6px;
  width: 0;
  height: 0;
  border-top: 8px solid transparent;
  border-bottom: 8px solid transparent;
  border-left: 14px solid rgba(240, 173, 44, 0.98);
  filter: drop-shadow(0 0 10px rgba(240, 173, 44, 0.42));
}

.motion-arrow--warning .motion-arrow__head {
  border-left-color: rgba(226, 94, 50, 0.98);
  filter: drop-shadow(0 0 10px rgba(226, 94, 50, 0.38));
}

.motion-pulse {
  position: absolute;
  left: calc(var(--motion-end-x) - 15px);
  top: calc(var(--motion-end-y) - 15px);
  width: 30px;
  height: 30px;
  border-radius: 999px;
  border: 3px solid rgba(220, 255, 109, 0.75);
  box-shadow: 0 0 18px rgba(220, 255, 109, 0.34);
  animation: motion-pulse-ring 640ms ease-out forwards;
}

.motion-pulse--warning {
  border-color: rgba(226, 94, 50, 0.72);
  box-shadow: 0 0 18px rgba(226, 94, 50, 0.34);
}

@keyframes sweep {
  from {
    transform: translateX(-100%);
  }

  to {
    transform: translateX(100%);
  }
}

@keyframes motion-arrow-travel {
  0% {
    opacity: 0;
    transform: rotate(var(--motion-angle)) scaleX(0.16);
  }

  15% {
    opacity: 1;
  }

  80% {
    opacity: 1;
    transform: rotate(var(--motion-angle)) scaleX(1);
  }

  100% {
    opacity: 0;
    transform: rotate(var(--motion-angle)) scaleX(1.02);
  }
}

@keyframes motion-pulse-ring {
  0% {
    opacity: 0.8;
    transform: scale(0.35);
  }

  100% {
    opacity: 0;
    transform: scale(1.5);
  }
}

@media (max-width: 1300px) {
  .player-seat {
    width: clamp(174px, 20vw, 220px);
  }

  .player-seat--self {
    width: clamp(246px, 34vw, 316px);
  }

  .table-felt-shell {
    min-height: clamp(620px, 80vh, 860px);
  }

  .body--active-table .table-felt-shell {
    min-height: clamp(660px, calc(100vh - 5.4rem), 920px);
  }
}

@media (max-width: 1100px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .sidebar {
    order: 2;
  }

  .table-panel {
    order: 1;
  }

  .body--in-room .hero-copy {
    display: none;
  }

  .body--in-room .layout {
    grid-template-columns: 1fr;
  }

  .body--in-room .table-felt-shell,
  .players-board[data-player-count="2"] .table-felt-shell {
    min-height: clamp(680px, calc(100vh - 8.2rem), 980px);
  }
}

@media (max-width: 920px) {
  .table-felt-shell {
    min-height: auto;
    padding: 0.85rem;
  }

  .table-felt-shell::before {
    display: none;
  }

  .center-row {
    position: static;
    transform: none;
    justify-content: center;
    grid-template-columns: repeat(2, minmax(0, 148px));
    gap: 0.7rem;
    margin-bottom: 0.85rem;
  }

  .seat-orbit {
    position: static;
    display: grid;
    gap: 0.85rem;
    inset: auto;
  }

  .empty-board-copy {
    position: static;
    transform: none;
    padding: 2rem 0;
  }

  .player-seat,
  .player-seat--self {
    position: static;
    width: 100%;
    transform: none;
  }

  .player-panel {
    padding: 0.8rem;
  }
}

@media (max-width: 720px) {
  .shell {
    width: min(100%, calc(100% - 0.7rem));
    padding-top: 0.5rem;
  }

  .hero {
    flex-direction: column;
  }

  .hero-actions {
    width: 100%;
    justify-content: space-between;
  }

  .hero h1,
  .body--in-room .hero h1 {
    font-size: 1.08rem;
  }

  .body--in-room .hero {
    align-items: flex-start;
  }

  .hero-chip {
    font-size: 0.8rem;
    padding: 0.55rem 0.72rem;
  }

  .room-code-row,
  .table-banner,
  .player-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .center-row {
    grid-template-columns: 1fr;
  }

  .players-board[data-player-count="2"] .seat-orbit {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
  }

  .players-board[data-player-count="2"] .center-row {
    gap: 0.55rem;
  }

  .players-board[data-player-count="2"] .player-seat {
    width: 100%;
  }

  .players-board[data-player-count="2"] .player-panel {
    border-radius: 22px;
  }

  .card-grid {
    gap: 0.38rem;
  }

  .player-seat--self .card-grid {
    gap: 0.45rem;
  }

  .player-name {
    font-size: 1rem;
  }

  .player-seat--self .player-name {
    font-size: 1.1rem;
  }

  .active-badge {
    font-size: 0.68rem;
    padding: 0.42rem 0.62rem;
  }

  .playing-card--center,
  .playing-card-stack,
  .discard-placeholder {
    width: 88px;
  }

  .playing-card--drawn {
    width: 106px;
  }

  .playing-card--reveal {
    width: 122px;
  }

  .card-face {
    min-height: 118px;
  }

  .table-banner h2 {
    font-size: 1.35rem;
  }
}
