/* ============================================================================
 * LAS VEGAS — 界面样式:深夜霓虹赌城风
 * ==========================================================================*/

:root {
  --bg0: #06081a;
  --bg1: #0c1130;
  --bg2: #190f33;
  --gold: #ffd166;
  --gold-2: #ffb703;
  --gold-deep: #b8860b;
  --glass: rgba(18, 22, 52, 0.78);
  --glass-2: rgba(26, 31, 66, 0.6);
  --ink: #eef1ff;
  --ink-dim: #a6adcf;
  --neon-pink: #ff2e63;
  --neon-cyan: #2de2e6;
  --ok: #3ddc84;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body { height: 100%; }

body {
  font-family: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(165deg, var(--bg0) 0%, var(--bg1) 45%, var(--bg2) 100%);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ---------------- 夜空背景 ---------------- */

#sky { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }

#stars { position: absolute; inset: 0; }

.star {
  position: absolute;
  border-radius: 50%;
  background: #fff;
  animation: twinkle 3.4s ease-in-out infinite;
}

@keyframes twinkle {
  0%, 100% { opacity: .15; transform: scale(.8); }
  50% { opacity: .95; transform: scale(1.15); }
}

#glow-a, #glow-b {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .5;
}
#glow-a { width: 620px; height: 620px; top: -220px; left: -120px;
  background: radial-gradient(circle, rgba(255, 46, 99, .35), transparent 65%); }
#glow-b { width: 700px; height: 700px; bottom: -280px; right: -180px;
  background: radial-gradient(circle, rgba(45, 226, 230, .28), transparent 65%); }

#skyline {
  position: absolute; left: 0; right: 0; bottom: 0; height: 130px;
  background:
    linear-gradient(180deg, transparent 0%, rgba(4, 5, 16, .55) 100%);
}
#skyline .bld {
  position: absolute; bottom: 0;
  background: linear-gradient(180deg, rgba(9, 11, 30, .85), rgba(5, 6, 18, .95));
  border-top: 1px solid rgba(255, 209, 102, .10);
  box-shadow: inset 0 0 18px rgba(0, 0, 0, .8);
}
#skyline .bld::after {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, transparent,
    rgba(255, 209, 102, var(--hl, .25)), transparent);
  filter: blur(1px);
}

/* ---------------- 布局 ---------------- */

#app {
  position: relative; z-index: 1;
  max-width: 1400px;
  margin: 0 auto;
  padding: 18px 22px 26px;
  display: flex; flex-direction: column; gap: 14px;
  min-height: 100vh;
}

/* ---------------- 霓虹招牌 ---------------- */

#sign {
  text-align: center;
  padding: 6px 0 10px;
  position: relative;
  user-select: none;
}

#bulbs {
  display: flex; justify-content: center; gap: 14px;
  margin-bottom: 2px;
}
#bulbs span {
  width: 9px; height: 9px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff3c4, var(--gold-2) 60%, #8a5a00);
  box-shadow: 0 0 10px rgba(255, 209, 102, .8);
  animation: bulb 2.2s ease-in-out infinite;
}
#bulbs span:nth-child(2n) { animation-delay: .55s; }
#bulbs span:nth-child(3n) { animation-delay: 1.1s; }
@keyframes bulb { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }

#sign-title {
  font-family: "Cinzel", "Times New Roman", serif;
  font-weight: 900;
  font-size: clamp(44px, 6.2vw, 84px);
  letter-spacing: .18em;
  background: linear-gradient(180deg, #fff7d6 8%, #ffd166 42%, #e09b1c 68%, #ffe9a8 96%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 14px rgba(255, 179, 3, .55)) drop-shadow(0 4px 22px rgba(255, 46, 99, .35));
  animation: sign-pulse 4.5s ease-in-out infinite;
}
@keyframes sign-pulse {
  0%, 100% { filter: drop-shadow(0 0 12px rgba(255, 179, 3, .5)) drop-shadow(0 4px 20px rgba(255, 46, 99, .3)); }
  50% { filter: drop-shadow(0 0 22px rgba(255, 179, 3, .85)) drop-shadow(0 4px 34px rgba(255, 46, 99, .55)); }
}

#sign-sub {
  margin-top: 6px;
  color: var(--neon-cyan);
  font-size: 13px; font-weight: 700; letter-spacing: .5em;
  text-shadow: 0 0 10px rgba(45, 226, 230, .9), 0 0 26px rgba(45, 226, 230, .4);
}

/* ---------------- 状态栏 ---------------- */

#status-bar {
  display: flex; align-items: center; gap: 12px;
  flex-wrap: wrap; justify-content: center;
}

.pill {
  background: var(--glass);
  border: 1px solid rgba(255, 255, 255, .10);
  border-radius: 999px;
  padding: 7px 16px;
  font-size: 13px; font-weight: 700;
  color: var(--ink-dim);
  backdrop-filter: blur(8px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
}

.pill-turn {
  color: var(--gold);
  border-color: rgba(255, 209, 102, .35);
  box-shadow: 0 0 16px rgba(255, 209, 102, .15);
  transition: all .3s;
}
.pill-turn.hot { animation: pill-glow 1.6s ease-in-out infinite; }
@keyframes pill-glow {
  0%, 100% { box-shadow: 0 0 10px rgba(255, 209, 102, .2); }
  50% { box-shadow: 0 0 26px rgba(255, 209, 102, .6); }
}

#sound-btn {
  border: 1px solid rgba(255, 255, 255, .12);
  background: var(--glass);
  color: var(--ink);
  width: 34px; height: 34px; border-radius: 50%;
  font-size: 15px; cursor: pointer;
  transition: all .2s;
}
#sound-btn:hover { transform: scale(1.1); border-color: rgba(255, 209, 102, .5); }

/* ---------------- 赌场 ---------------- */

#casino-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.casino {
  position: relative;
  border-radius: 18px;
  padding: 12px 10px 14px;
  display: flex; flex-direction: column; gap: 10px;
  background:
    linear-gradient(180deg, rgba(30, 26, 62, .88), rgba(13, 15, 36, .94));
  border: 1px solid var(--hue-soft);
  box-shadow:
    0 0 24px var(--hue-glow),
    inset 0 0 34px rgba(0, 0, 0, .55),
    inset 0 1px 0 rgba(255, 255, 255, .05);
  transition: transform .25s, box-shadow .25s;
}
.casino:hover { transform: translateY(-3px); }
.casino.active-casino {
  box-shadow:
    0 0 38px var(--hue-glow),
    0 0 60px var(--hue-glow),
    inset 0 0 34px rgba(0, 0, 0, .4);
  animation: casino-breathe 1.8s ease-in-out infinite;
}
@keyframes casino-breathe {
  0%, 100% { box-shadow: 0 0 22px var(--hue-glow), inset 0 0 34px rgba(0,0,0,.55); }
  50% { box-shadow: 0 0 42px var(--hue-glow), 0 0 66px var(--hue-glow), inset 0 0 34px rgba(0,0,0,.4); }
}

.casino-head { display: flex; align-items: center; gap: 8px; justify-content: center; }

.casino-num {
  width: 34px; height: 34px; border-radius: 9px;
  display: flex; align-items: center; justify-content: center;
  font-family: "Cinzel", serif; font-weight: 900; font-size: 19px;
  color: #10122b;
  background: linear-gradient(145deg, #fff3c9, var(--hue) 70%, var(--hue-deep));
  box-shadow: 0 0 14px var(--hue-glow), inset 0 -2px 4px rgba(0, 0, 0, .3), inset 0 2px 3px rgba(255, 255, 255, .5);
}

.casino-name {
  font-family: "Cinzel", "Times New Roman", serif;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: .04em;
  color: var(--hue);
  text-shadow: 0 0 10px var(--hue-glow), 0 0 24px var(--hue-glow);
  white-space: nowrap;
}

.casino-icon { font-size: 15px; filter: drop-shadow(0 0 6px var(--hue-glow)); }

/* 钞票扇形 */
.casino-money {
  position: relative;
  height: 44px;
  display: flex; justify-content: center;
}

.note {
  position: absolute; bottom: 2px;
  width: 42px; height: 27px;
  border-radius: 4px;
  background:
    repeating-linear-gradient(45deg, rgba(255, 255, 255, .045) 0 3px, transparent 3px 7px),
    linear-gradient(150deg, #35b877, #1e8f58 55%, #14703f);
  border: 1.5px solid #e9c46a;
  color: #fff3cf;
  font-size: 9.5px; font-weight: 900;
  font-family: "Cinzel", serif;
  letter-spacing: .03em;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 7px rgba(0, 0, 0, .5), inset 0 0 0 1px rgba(255, 255, 255, .10), 0 0 10px rgba(233, 196, 106, .25);
  text-shadow: 0 1px 2px rgba(0, 0, 0, .6);
  transform-origin: 50% 100%;
  z-index: 1;
}
.note.small { width: 34px; height: 22px; font-size: 8px; border-width: 1px; }

/* 赌场骰子区 */
.casino-dice {
  min-height: 56px;
  display: flex; justify-content: center; align-items: flex-end;
  gap: 12px; flex-wrap: wrap;
  padding-top: 2px;
}

.dice-stack {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
}
.dice-stack .dies { display: flex; flex-direction: row-reverse; justify-content: center; }
.dice-stack .dies .die { margin-left: -7px; box-shadow: 0 2px 4px rgba(0,0,0,.45), 0 0 8px var(--die-glow); }
.dice-stack .dies .die:first-child { margin-left: 0; }

.stack-label {
  font-size: 10px; font-weight: 700;
  color: var(--ink-dim);
  display: flex; align-items: center; gap: 4px;
}
.stack-label .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--dot); box-shadow: 0 0 6px var(--dot); }
.stack-label b { color: var(--ink); font-size: 11px; }

.dice-stack.white-stack .die { --dc: #f6f6f4; --dc-dark: #c9c9c4; --dp: #3a3a44; --die-glow: rgba(255,255,255,.35); }
.dice-stack.white-stack .stack-label .dot { background: #f2f2f0; }

/* ---------------- 骰子(3×3 点阵) ---------------- */

.die {
  --p: 3.4px; --o: 5px;
  --dc: #ff4d5e; --dc-dark: #b3273a; --dp: #fff; --die-glow: rgba(255, 77, 94, .5);
  width: 21px; height: 21px;
  border-radius: 5px;
  position: relative;
  display: flex; align-items: center; justify-content: center;
  background: var(--dc);
  background: radial-gradient(circle at 32% 26%, color-mix(in srgb, var(--dc) 88%, #fff) 0%, var(--dc) 46%, var(--dc-dark) 100%);
  border: 1px solid rgba(0, 0, 0, .35);
  box-shadow: 0 2px 5px rgba(0, 0, 0, .45), inset 0 1px 1px rgba(255, 255, 255, .45), inset 0 -2px 3px rgba(0, 0, 0, .35);
  color: var(--dp);
  flex: none;
}
.die-lg {
  --p: 5.6px; --o: 9.5px;
  width: 38px; height: 38px; border-radius: 9px;
}

.die .pip {
  width: var(--p); height: var(--p);
  border-radius: 50%;
  background: var(--dp);
  box-shadow: 0 0 2px rgba(255, 255, 255, .8);
  position: relative;
  z-index: 1;
}
.die[data-v="2"] .pip { box-shadow: var(--o) var(--o) 0 0, calc(var(--o) * -1) calc(var(--o) * -1) 0 0; }
.die[data-v="3"] .pip { box-shadow: var(--o) calc(var(--o) * -1) 0 0, calc(var(--o) * -1) var(--o) 0 0; }
.die[data-v="4"] .pip { box-shadow: var(--o) var(--o) 0 0, calc(var(--o) * -1) var(--o) 0 0, var(--o) calc(var(--o) * -1) 0 0, calc(var(--o) * -1) calc(var(--o) * -1) 0 0; }
.die[data-v="5"] .pip { box-shadow: var(--o) var(--o) 0 0, calc(var(--o) * -1) var(--o) 0 0, var(--o) calc(var(--o) * -1) 0 0, calc(var(--o) * -1) calc(var(--o) * -1) 0 0; }
.die[data-v="6"] .pip { box-shadow: var(--o) var(--o) 0 0, calc(var(--o) * -1) var(--o) 0 0, var(--o) 0 0 0, calc(var(--o) * -1) 0 0 0, var(--o) calc(var(--o) * -1) 0 0, calc(var(--o) * -1) calc(var(--o) * -1) 0 0; }

/* 掷骰旋转动画 */
@keyframes die-roll {
  0% { transform: rotate(0deg) scale(1); }
  30% { transform: rotate(300deg) scale(1.25); }
  60% { transform: rotate(600deg) scale(.9); }
  100% { transform: rotate(720deg) scale(1); }
}
.die.rolling { animation: die-roll .7s cubic-bezier(.3, .1, .4, 1); }

/* ---------------- 玩家区 ---------------- */

#players {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: auto;
}

.player-card {
  position: relative;
  border-radius: 16px;
  padding: 12px 14px 14px;
  background: var(--glass);
  border: 1px solid rgba(255, 255, 255, .09);
  border-top: 3px solid var(--pc);
  backdrop-filter: blur(10px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05), 0 8px 24px rgba(0, 0, 0, .35);
  transition: all .3s;
}
.player-card.is-current {
  border-color: rgba(255, 255, 255, .2);
  box-shadow: 0 0 26px var(--pc-glow), inset 0 1px 0 rgba(255, 255, 255, .08);
  transform: translateY(-4px);
}
.player-card.muted { opacity: .55; }

.player-top { display: flex; align-items: center; gap: 10px; }

.player-dice {
  width: 34px; height: 34px; border-radius: 9px; flex: none;
  display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 32% 26%, color-mix(in srgb, var(--pc) 85%, #fff), var(--pc) 50%, var(--pc-dark));
  box-shadow: 0 0 12px var(--pc-glow), inset 0 1px 1px rgba(255,255,255,.5), inset 0 -2px 3px rgba(0,0,0,.3);
  color: #fff;
}
.player-dice .pip { width: 5px; height: 5px; background: #fff; border-radius: 50%; box-shadow: 4px 4px 0 0, -4px -4px 0 0; }

.player-name { font-weight: 900; font-size: 15px; letter-spacing: .02em; }
.player-tag {
  font-size: 10px; font-weight: 700;
  color: var(--ink-dim);
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  padding: 1px 8px;
  margin-top: 2px; display: inline-block;
}

.player-left {
  margin-top: 8px;
  font-size: 12px; color: var(--ink-dim);
  display: flex; gap: 10px; align-items: center;
  flex-wrap: wrap;
}
.player-left .chip {
  background: rgba(0, 0, 0, .3);
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 999px; padding: 2px 9px;
  display: inline-flex; align-items: center; gap: 5px;
}
.player-left .chip .w { color: #f2f2f0; }

/* 手牌(掷骰后) */
.player-hand {
  margin-top: 10px;
  display: flex; gap: 8px; flex-wrap: wrap;
  justify-content: center;
  min-height: 66px;
  align-content: flex-start;
}

.choice {
  border: 1px solid rgba(255, 255, 255, .16);
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,.02));
  border-radius: 12px;
  padding: 7px 9px 6px;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  cursor: pointer;
  transition: all .18s;
  color: var(--ink);
  position: relative;
}
.choice:hover { transform: translateY(-3px) scale(1.04); border-color: var(--gold); box-shadow: 0 0 16px rgba(255, 209, 102, .35); }
.choice:active { transform: scale(.96); }
.choice .die { --dc: var(--pc); --dc-dark: var(--pc-dark); --die-glow: var(--pc-glow); }

.choice-count { font-size: 12px; font-weight: 900; }
.choice-count .white-note { color: #e8e8e4; font-size: 10px; font-weight: 700; }
.choice-count .big-note { color: #ff8fc7; font-size: 10px; font-weight: 900; }

/* 掷骰/跳过 操作行 */
.act-row { display: flex; gap: 8px; align-items: stretch; }
.act-row .roll-btn { flex: 1; }

/* Royale 扩展:跳过按钮(花筹码) */
.skip-btn {
  margin-top: 10px;
  padding: 0 12px;
  border: 1px solid rgba(120, 220, 255, .55);
  border-radius: 12px;
  font-family: inherit;
  font-size: 12px; font-weight: 900;
  color: #bfe9ff;
  background: rgba(40, 110, 160, .28);
  box-shadow: 0 0 14px rgba(120, 220, 255, .25), inset 0 1px 0 rgba(255, 255, 255, .25);
  cursor: pointer;
  transition: all .18s;
}
.skip-btn:hover { transform: translateY(-2px); border-color: #7ce4ff; box-shadow: 0 0 22px rgba(120, 220, 255, .5); }
.skip-btn:active { transform: scale(.96); }

/* 扩展玩法选择行 */
.setup-ext {
  display: flex; justify-content: center; align-items: center; gap: 10px;
  margin: 0 0 14px;
}
.setup-ext .ext-label { font-size: 13px; font-weight: 900; color: var(--ink-dim); margin-right: 2px; }
.setup-ext button {
  padding: 6px 16px;
  border: 1px solid rgba(255, 209, 102, .35);
  border-radius: 999px;
  font-family: inherit; font-size: 13px; font-weight: 800;
  color: var(--ink); background: rgba(255, 255, 255, .04);
  cursor: pointer; transition: all .18s;
}
.setup-ext button:hover { transform: translateY(-2px); }
.setup-ext button.sel {
  background: rgba(255, 209, 102, .14); color: var(--gold); border-color: rgba(255, 209, 102, .5);
}

/* 掷骰按钮 */
.roll-btn {
  margin-top: 10px;
  width: 100%;
  padding: 11px 0;
  border: none; border-radius: 12px;
  font-family: inherit;
  font-size: 15px; font-weight: 900; letter-spacing: .2em;
  color: #2a1a02;
  background: linear-gradient(180deg, #ffe9a8 0%, #ffd166 45%, #f5a623 100%);
  box-shadow: 0 0 22px rgba(255, 179, 3, .55), 0 4px 14px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .7), inset 0 -2px 4px rgba(160, 100, 0, .5);
  cursor: pointer;
  transition: all .18s;
  animation: roll-pulse 1.8s ease-in-out infinite;
}
.roll-btn:hover { transform: translateY(-2px); box-shadow: 0 0 34px rgba(255, 179, 3, .8), 0 6px 18px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255,255,255,.7); }
.roll-btn:active { transform: scale(.97); }
@keyframes roll-pulse {
  0%, 100% { box-shadow: 0 0 18px rgba(255, 179, 3, .45), 0 4px 14px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255,255,255,.7); }
  50% { box-shadow: 0 0 30px rgba(255, 179, 3, .75), 0 4px 14px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255,255,255,.7); }
}

/* 玩家钞票堆 */
.player-money {
  margin-top: 10px;
  display: flex; align-items: center; gap: 10px;
}
.won-stack { display: flex; align-items: flex-end; min-height: 26px; }
.won-stack .note.small { position: static; margin-left: -14px; transform: rotate(var(--rot, 0deg)) translateY(var(--off, 0px)); }
.won-stack .note.small:first-child { margin-left: 0; }
.won-more { font-size: 11px; color: var(--ink-dim); font-weight: 700; margin-left: 2px; }

.player-total {
  font-family: "Cinzel", serif;
  font-size: 19px; font-weight: 900;
  color: var(--gold);
  text-shadow: 0 0 12px rgba(255, 209, 102, .5);
  margin-left: auto;
}
.player-total small { font-size: 11px; color: var(--ink-dim); font-weight: 700; margin-right: 3px; }

/* ---------------- 模态框 ---------------- */

.hidden { display: none !important; }

#modal-mask {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(3, 5, 16, .78);
  backdrop-filter: blur(7px);
  display: flex; align-items: center; justify-content: center;
  padding: 18px;
  animation: fade-in .25s ease;
}
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

#modal {
  width: min(600px, 96vw);
  max-height: 90vh;
  overflow-y: auto;
  border-radius: 22px;
  padding: 26px 28px;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(255, 209, 102, .07), transparent 55%),
    linear-gradient(180deg, #1b1f45, #10132e);
  border: 1px solid rgba(255, 209, 102, .3);
  box-shadow: 0 0 70px rgba(255, 209, 102, .14), 0 30px 90px rgba(0, 0, 0, .65), inset 0 1px 0 rgba(255, 255, 255, .06);
  animation: modal-pop .32s cubic-bezier(.2, 1.4, .4, 1);
  color: var(--ink);
}
@keyframes modal-pop { from { transform: scale(.92) translateY(14px); opacity: 0; } to { transform: none; opacity: 1; } }

#modal h2 {
  font-family: "Cinzel", serif;
  text-align: center;
  font-size: 24px;
  color: var(--gold);
  text-shadow: 0 0 16px rgba(255, 209, 102, .6);
  margin-bottom: 6px;
  letter-spacing: .08em;
}
#modal h3 { font-size: 14px; text-align: center; color: var(--ink-dim); font-weight: 500; margin-bottom: 16px; }

.setup-players { display: flex; justify-content: center; gap: 10px; margin: 14px 0 18px; }
.setup-players button {
  width: 56px; height: 56px; border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, .14);
  background: var(--glass-2);
  color: var(--ink);
  font-size: 20px; font-weight: 900;
  cursor: pointer; transition: all .2s;
  font-family: "Cinzel", serif;
}
.setup-players button:hover { transform: translateY(-2px); }
.setup-players button.sel {
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 22px rgba(255, 209, 102, .45);
  background: rgba(255, 209, 102, .08);
}

.setup-seats { display: flex; flex-direction: column; gap: 8px; margin-bottom: 18px; }
.seat-row {
  display: flex; align-items: center; gap: 12px;
  background: rgba(0, 0, 0, .25);
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 12px;
  padding: 8px 12px;
}
.seat-row .seat-dot { width: 14px; height: 14px; border-radius: 50%; box-shadow: 0 0 8px var(--c); background: var(--c); flex: none; }
.seat-row .seat-name { font-weight: 700; flex: 1; }
.seat-row .seat-type { display: flex; gap: 4px; }
.seat-row .seat-type button {
  border: 1px solid rgba(255, 255, 255, .12);
  background: transparent; color: var(--ink-dim);
  font-size: 12px; font-weight: 700;
  padding: 4px 12px; border-radius: 999px; cursor: pointer;
  transition: all .15s;
}
.seat-row .seat-type button.sel { background: rgba(255, 209, 102, .14); color: var(--gold); border-color: rgba(255, 209, 102, .5); }

.big-btn {
  display: block; width: 100%;
  padding: 14px 0;
  border: none; border-radius: 14px;
  font-family: inherit;
  font-size: 17px; font-weight: 900; letter-spacing: .25em;
  color: #2a1a02;
  background: linear-gradient(180deg, #ffe9a8, #ffd166 45%, #f5a623);
  box-shadow: 0 0 26px rgba(255, 179, 3, .5), 0 6px 16px rgba(0, 0, 0, .45), inset 0 1px 0 rgba(255,255,255,.7);
  cursor: pointer; transition: all .18s;
}
.big-btn:hover { transform: translateY(-2px); box-shadow: 0 0 40px rgba(255, 179, 3, .8), 0 8px 20px rgba(0, 0, 0, .45); }
.big-btn:active { transform: scale(.98); }
.big-btn.ghost {
  background: transparent; color: var(--ink-dim);
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow: none; letter-spacing: .1em; font-size: 14px;
}
.big-btn.ghost:hover { color: var(--ink); border-color: rgba(255,255,255,.35); box-shadow: none; }

.rules-box {
  font-size: 12.5px; line-height: 1.85;
  color: var(--ink-dim);
  background: rgba(0, 0, 0, .28);
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 12px;
  padding: 12px 14px;
  margin-bottom: 16px;
}
.rules-box b { color: var(--gold); }

/* 结算结果 */
.settle-list { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 16px; }
.settle-row {
  display: flex; align-items: center; gap: 10px;
  background: rgba(0, 0, 0, .25);
  border: 1px solid rgba(255, 255, 255, .06);
  border-radius: 11px;
  padding: 8px 12px;
  font-size: 13px;
}
.settle-row .s-casino { font-weight: 900; min-width: 120px; display: flex; align-items: center; gap: 7px; }
.settle-row .s-casino .num {
  width: 22px; height: 22px; border-radius: 6px; flex: none;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 900; color: #10122b;
  background: linear-gradient(145deg, #fff3c9, var(--hue) 70%, var(--hue-deep));
}
.settle-row .s-dice { flex: 1; display: flex; flex-wrap: wrap; gap: 8px; }
.settle-row .s-dice .sd { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--ink-dim); font-weight: 700; }
.settle-row .s-dice .sd .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); box-shadow: 0 0 6px var(--c); }
.settle-row .s-dice .sd.tied { text-decoration: line-through; opacity: .5; }
.settle-row .s-win { font-weight: 900; color: var(--gold); font-size: 13px; white-space: nowrap; }
.settle-row .s-win.zero { color: var(--ink-dim); font-weight: 500; }

/* 结束排名 */
.final-list { display: flex; flex-direction: column; gap: 10px; margin: 10px 0 18px; }
.final-row {
  display: flex; align-items: center; gap: 12px;
  background: rgba(0, 0, 0, .28);
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 13px;
  padding: 10px 14px;
}
.final-row.winner {
  border-color: rgba(255, 209, 102, .55);
  background: linear-gradient(90deg, rgba(255, 209, 102, .14), rgba(255, 209, 102, .03));
  box-shadow: 0 0 24px rgba(255, 209, 102, .2);
}
.final-rank { font-size: 20px; width: 30px; text-align: center; }
.final-row .fd { width: 15px; height: 15px; border-radius: 50%; background: var(--c); box-shadow: 0 0 8px var(--c); }
.final-name { font-weight: 900; flex: 1; }
.final-notes { font-size: 12px; color: var(--ink-dim); }
.final-total { font-family: "Cinzel", serif; font-weight: 900; font-size: 18px; color: var(--gold); }
.trophy { font-size: 44px; text-align: center; margin: 2px 0 8px; animation: trophy-bounce 1.6s ease-in-out infinite; }
@keyframes trophy-bounce { 0%, 100% { transform: translateY(0) rotate(-4deg); } 50% { transform: translateY(-8px) rotate(4deg); } }

/* ---------------- Toast & FX ---------------- */

#toast {
  position: fixed; top: 20px; left: 50%;
  transform: translateX(-50%);
  z-index: 60;
  background: rgba(10, 12, 32, .92);
  border: 1px solid rgba(255, 209, 102, .4);
  border-radius: 999px;
  padding: 10px 22px;
  font-size: 14px; font-weight: 700;
  color: var(--gold);
  box-shadow: 0 0 30px rgba(255, 209, 102, .25);
  opacity: 0; pointer-events: none;
  transition: opacity .3s, transform .3s;
  max-width: 90vw; text-align: center;
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(6px); }

#fx-layer { position: fixed; inset: 0; z-index: 45; pointer-events: none; }

.fx-die {
  position: fixed;
  width: 22px; height: 22px; border-radius: 5px;
  pointer-events: none;
  z-index: 46;
  box-shadow: 0 3px 8px rgba(0, 0, 0, .5);
}
.fx-note {
  position: fixed;
  width: 42px; height: 27px;
  border-radius: 4px;
  pointer-events: none;
  z-index: 46;
  background: linear-gradient(150deg, #35b877, #1e8f58 55%, #14703f);
  border: 1.5px solid #e9c46a;
  box-shadow: 0 4px 12px rgba(0, 0, 0, .5);
  display: flex; align-items: center; justify-content: center;
  color: #fff3cf; font-size: 9px; font-weight: 900;
  font-family: "Cinzel", serif;
}

/* ---------------- 响应式 ---------------- */

@media (max-width: 1100px) {
  #casino-row { grid-template-columns: repeat(3, 1fr); }
  #players { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  #casino-row { grid-template-columns: repeat(2, 1fr); }
  #players { grid-template-columns: 1fr; }
}
