/* MIAMICLUB / DUSK CLUB
   Optional art-direction layer, loaded after tables-room.css.
   Geometry, reading order, game states and control targets belong to tables-room.css.
   This layer changes materials, colors and ornamental details only.
*/
body.vice-tables {
  --club-cream: #fff1d9;
  --club-peach: #ffc29e;
  --club-coral: #f8a28b;
  --club-sage: #b3d7aa;
  --club-mint: #a2dcc9;
  --club-petrol: #18382f;
  --club-felt: #335d48;
  --club-line: #e6efcb39;
  --room-ink: var(--club-cream);
  --room-reward: var(--club-peach);
  --room-table-one: var(--club-peach);
  --room-table-two: var(--club-mint);
  --room-muted: #c9ddcf;
  --room-border: var(--club-line);
}

/* A calm emerald stage. The sunset is confined to the table headers. */
body.vice-tables.vice-theme:not(.display-mode) {
  background: #102a23;
}
body.vice-tables.vice-theme:not(.display-mode) .topbar {
  border-bottom-color: #e8d7b847;
}
.vice-tables .vice-dock-brand {
  color: var(--club-cream);
  font-style: italic;
  letter-spacing: .7px;
  text-shadow: 1px 1px 0 #ffaf8a45;
}
.vice-tables .vice-dock-brand > span {
  font-style: normal;
  color: #d0dfc7;
  border-left-color: #e9d1b43b;
}
.vice-tables .brand .vice-connection {
  color: #cbded0;
}
.vice-tables.vice-theme .controls .icon-btn {
  background: #244539;
  color: var(--club-cream);
  border-color: #d8e7ca36;
  border-radius: 3px;
}
.vice-tables.vice-theme .controls .icon-btn:hover {
  background: #355c48;
  border-color: var(--club-peach);
}
.vice-tables.vice-theme .controls .ghost {
  background: transparent;
}

/* The jackpot reads like a sunlit club sign, not a second game board. */
body.vice-tables.vice-theme:not(.display-mode) .milestones {
  background: #ead8b9;
  border-color: #ffe8c7;
  border-radius: 4px;
  box-shadow: inset 0 1px 0 #fff1d915;
}
.vice-tables .room-jackpot-label strong {
  color: #254832;
  font-style: italic;
  letter-spacing: 1.5px;
}
.vice-tables .room-jackpot-label span {
  color: #3a5a40;
}
.vice-tables.vice-theme .milestone {
  background: #fff1d4;
  border-color: #36583d30;
  border-radius: 3px;
}
.vice-tables.vice-theme .milestone .milestone-chip {
  color: #274b34;
}
.vice-tables.vice-theme .milestone .milestone-chip.payout,
.vice-tables .milestone .milestone-chip .unit {
  color: #23452f;
}
.vice-tables .milestone-chip:not(.payout)::after {
  color: #3b5b40;
}
.vice-tables .milestone-chip.payout::before {
  color: #4e6d4c;
}
.vice-tables.vice-theme .milestone.tier-3 {
  background: #ffc29e;
  border-color: #fff0d8;
  box-shadow: inset 0 0 0 2px #18382f16;
}
.vice-tables.vice-theme .milestone.tier-3 .milestone-chip,
.vice-tables.vice-theme .milestone.tier-3 .milestone-chip.payout,
.vice-tables .milestone.tier-3 .milestone-chip .unit,
.vice-tables .milestone.tier-3 .milestone-chip:not(.payout)::after,
.vice-tables .milestone.tier-3 .milestone-chip.payout::before {
  color: #213e2d;
}
.vice-tables.vice-theme .milestone.tier-3::before {
  background: linear-gradient(105deg, transparent, #fff7dd8a, transparent);
}

/* Table identity: peach sunset / seafoam coast. Strong opaque reading surfaces. */
body.vice-tables.vice-theme:not(.display-mode) .table-card {
  background: #234634;
  border-color: #edc1a355;
  border-radius: 5px;
  box-shadow: inset 0 0 0 1px #fff1d905;
}
body.vice-tables.vice-theme:not(.display-mode) .table-card:nth-child(2) {
  background: #20483c;
  border-color: #a6d8bd55;
}
.vice-tables.vice-theme .table-card::before {
  background: linear-gradient(90deg, #f5a78f, #ffd4aa 55%, #b1d5a4);
}
.vice-tables.vice-theme .table-card:nth-child(2)::before {
  background: linear-gradient(90deg, #8bd4bf, #c6e2bf 55%, #f2c7a6);
}
.vice-tables.vice-theme .table-card::after {
  content: '';
  position: absolute;
  right: 10px;
  bottom: 10px;
  width: 22px;
  height: 22px;
  border-right: 1px solid #f7dbb15c;
  border-bottom: 1px solid #f7dbb15c;
  pointer-events: none;
}
.vice-tables.vice-theme .table-head {
  position: relative;
  isolation: isolate;
}
.vice-tables.vice-theme .table-head::before {
  content: '';
  position: absolute;
  inset: -12px -12px -7px;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(90deg, #1a3a30f7 0%, #1a3a30c2 42%, #1a3a306b 75%, #1a3a30d9 100%),
    url('assets/club-dusk-panorama-v1.webp'),
    url('assets/vice-sunset-v1.webp');
  background-position: center, 65% 57%, 65% 44%;
  background-size: cover;
  background-repeat: no-repeat;
  border-radius: 3px;
}
.vice-tables.vice-theme .table-name {
  color: var(--club-cream);
  font-style: italic;
  letter-spacing: .8px;
  text-shadow: 0 2px 8px #08271f80;
}
.vice-tables.vice-theme .table-chip,
.vice-tables.vice-theme .table-card:nth-child(2) .table-chip {
  color: #173c2e;
  background: #fff0d3;
  border: 1px solid #fff8e7;
  border-radius: 3px;
  box-shadow: inset 0 0 0 2px #173c2e15;
}
.vice-tables.vice-theme .table-card:nth-child(2) .table-chip {
  background: #fff0d3;
}
.vice-tables.vice-theme .match-timer {
  background: #143c31;
  border-color: #d4e4c747;
  color: var(--club-cream);
  border-radius: 3px;
  box-shadow: none;
}
.vice-tables.vice-theme .table-status.live {
  color: #b6f1d9;
}
.vice-tables .table-status.waiting {
  color: #ffd7ad;
}
.vice-tables .table-status.idle {
  color: #d0dcca;
}

/* The whole player surface stays bright enough for distant reading. */
body.vice-tables.vice-theme:not(.display-mode) .player-slot {
  background: #365f49;
  border-color: #e3dec243;
  border-radius: 4px;
  box-shadow: inset 0 1px 0 #fff1d90d;
}
body.vice-tables.vice-theme:not(.display-mode) .table-card:nth-child(2) .player-slot {
  background: #2e5b4c;
  border-color: #c8e6cb43;
}
body.vice-tables.vice-theme:not(.display-mode) .player-slot.empty {
  background: #2d4d3c;
  border-color: #d5e3c94d;
}
.vice-tables.vice-theme .player-name,
.vice-tables.vice-theme .queue-name {
  color: #fff7e9;
  text-shadow: 0 1px 0 #0f30253d;
}
.vice-tables.vice-theme .stat-chip.win {
  color: var(--club-peach);
}
.vice-tables .stat-chip.win .win-unit,
.vice-tables.vice-theme .player-meta {
  color: #e6efda;
}
.vice-tables.vice-theme .stat-chip.payout {
  color: #ffe0b9;
  background: #1d422f;
  border-color: #ebcea25c;
}
.vice-tables.vice-theme .versus {
  color: #ffc5a7;
  text-shadow: none;
}
.vice-tables.vice-theme .versus > span {
  display: grid;
  place-content: center;
  width: 100%;
  aspect-ratio: 1;
  background: #ffc29e;
  color: #254433;
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
  font-size: .72em;
  letter-spacing: 0;
}
.vice-tables.vice-theme .versus::before,
.vice-tables.vice-theme .versus::after {
  background: linear-gradient(transparent, #f2bb996e, transparent);
}
.vice-tables.vice-theme .player-progress progress {
  background: #e3efcb2e;
}
.vice-tables.vice-theme .player-progress progress::-webkit-progress-value {
  background: linear-gradient(90deg, #f5a78f, #ffd3a8);
}
.vice-tables.vice-theme .player-progress progress::-moz-progress-bar {
  background: #ffc09d;
}
.vice-tables .table-card:nth-child(2) .player-progress progress::-webkit-progress-value {
  background: linear-gradient(90deg, #95d7bc, #d4e8b6);
}

/* Waiting is the next chapter: one clear lead row, quiet rows after it. */
.vice-tables.vice-theme .queue-label {
  color: #f1edda;
}
.vice-tables.vice-theme .queue-count {
  color: var(--club-cream);
  background: #345c46;
  border-color: #d5dec23d;
  border-radius: 3px;
}
.vice-tables.vice-theme .queue-item {
  background: #2a503e;
  border-color: #d1e0c32e;
  border-radius: 3px;
}
.vice-tables.vice-theme .queue-item.next-up {
  background: #3c6044;
  border-color: #efc7a077;
  box-shadow: inset 3px 0 0 #f3bc93;
}
.vice-tables.vice-theme .queue-position {
  color: #cadfbc;
}
.vice-tables.vice-theme .queue-badge {
  color: #ffe1bc;
  background: #264b34;
  border-color: #f4c49b55;
  border-radius: 2px;
}
.vice-tables.vice-theme .queue-empty {
  background: #254b3a;
  color: #e1e9d5;
  border-color: #cadfc239;
}
.vice-tables .queue-empty small {
  color: #cadfc8;
}
.vice-tables.vice-theme .queue-item .icon-btn {
  background: #234734;
  color: #f2eddb;
  border-color: #d4dfc340;
  border-radius: 3px;
}
.vice-tables.vice-theme input[type='text'] {
  background: #193e2d;
  color: #fff4df;
  border-color: #cbdbba4d;
}
.vice-tables.vice-theme .queue-head .input-row button,
.vice-tables.vice-theme .slot-actions button.win {
  background: #ffc29e;
  color: #243b2a;
  border-color: #ffd8b6;
}
.vice-tables.vice-theme .slot-actions button {
  background: #234734;
  color: #f2eddb;
}
.vice-tables .slot-actions::before {
  background: #20412f;
  border-color: #d4dfc340;
}
.vice-tables.vice-theme .queue-list {
  scrollbar-color: #9ac19d77 #173c2b40;
}
.vice-tables .queue-list::-webkit-scrollbar-thumb {
  background: #9ac19d77;
}

/* Decorations remain static; only the existing jackpot has its rare shimmer. */
@media (prefers-reduced-motion: reduce) {
  .vice-tables.vice-theme .milestone.tier-3,
  .vice-tables.vice-theme .milestone.tier-3::before {
    animation: none;
  }
}

/* The same club material continues through staff dialogs and result feedback. */
.vice-tables.vice-theme .settings-panel,
.vice-tables.vice-theme .subscriber-modal-card,
.vice-tables.vice-theme .room-modal-card {
  background: #234735;
  color: var(--club-cream);
  border-color: #e0d2b75c;
  box-shadow: 0 20px 70px #08291f8c;
}
.vice-tables .settings-title,
.vice-tables .subscriber-access-title,
.vice-tables .room-access-title {
  color: var(--club-cream);
}
.vice-tables .subscriber-access-sub,
.vice-tables .subscriber-access-meta,
.vice-tables .room-access-sub,
.vice-tables .settings-label {
  color: #d7e6cc;
}
.vice-tables .room-access-error {
  color: #ffd1bd;
}
.vice-tables .subscriber-modal-backdrop,
.vice-tables .room-modal-backdrop,
.vice-tables .settings-overlay {
  background: #071b13b8;
  backdrop-filter: none;
}
.vice-tables.vice-theme .subscriber-access-form input,
.vice-tables.vice-theme .subscriber-access-form select,
.vice-tables.vice-theme .room-access-form input {
  background: #173b2a;
  color: var(--club-cream);
  border-color: #d6dfc557;
}
.vice-tables.vice-theme .settings-panel button,
.vice-tables.vice-theme .subscriber-modal-card button,
.vice-tables.vice-theme .room-modal-card button {
  background: #365c43;
  color: var(--club-cream);
  border-color: #d6dfc557;
  box-shadow: none;
}
.vice-tables.vice-theme #subscriberJoinBtn,
.vice-tables.vice-theme #roomPasswordSubmit {
  background: var(--club-peach);
  color: #25412e;
  border-color: #ffe0bd;
}
.vice-tables.vice-theme .toast {
  background: #254c37;
  color: var(--club-cream);
  border-color: #d5dbad6b;
  box-shadow: 0 10px 40px #06231560;
}
.vice-tables.vice-theme .win-popup {
  background: #214633;
  border-color: #f2c093;
  box-shadow: 0 0 0 1px #ffe4b940, 0 22px 80px #061f1670;
}
.vice-tables.vice-theme .win-title,
.vice-tables.vice-theme .win-name,
.vice-tables.vice-theme .win-count {
  color: #ffe0b4;
}
.vice-tables .win-sub {
  color: #e0ead0;
}

/* An empty waiting list becomes a quiet club vista; live queues remain plain. */
.vice-tables.vice-theme .queue-empty {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 22px 16px;
  gap: 8px;
  background: #254b3a;
}
.vice-tables.vice-theme .queue-empty::after {
  content: '';
  position: absolute;
  inset: 76px 0 0;
  z-index: -1;
  pointer-events: none;
  background-image: linear-gradient(180deg, #254b3a 0, #254b3a00 36%), url('assets/club-dusk-panorama-v1.webp');
  background-size: cover;
  background-position: center, 45% 55%;
  background-repeat: no-repeat;
}
.vice-tables .table-card:nth-child(2) .queue-empty::after { background-position: center, 70% 55%; }
.vice-tables .queue-empty > span,
.vice-tables .queue-empty > small { position: relative; z-index: 1; }
@media (max-width: 900px) {
  .vice-tables.vice-theme .versus > span {
    clip-path: none;
    background: transparent;
    color: var(--club-peach);
    font-size: 1em;
    aspect-ratio: auto;
  }
  .vice-tables.vice-theme .queue-empty { padding: 14px 10px; min-height: 130px; }
  .vice-tables.vice-theme .queue-empty::after { inset: 72px 0 0; }
}
