/* The gambling table (plugins/nfgamble.js): neon-edged green felt, dice with pips, cards with suits. */
.ngb-wrap { position: fixed; inset: 0; z-index: 1145; display: flex; align-items: center; justify-content: center; padding: 16px;
    background: rgba(2, 4, 10, 0.65); }
.ngb-table { width: min(560px, 100%); max-height: 100%; display: flex; flex-direction: column; overflow: hidden; border-radius: 14px;
    background: #0b0f14; border: 1px solid #2b3a2f; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.75), 0 0 30px rgba(255, 62, 165, 0.12);
    color: #e9f1ea; font-family: "Rajdhani", "Segoe UI", system-ui, sans-serif; }
.ngb-top { display: flex; align-items: center; gap: 10px; padding: 9px 12px; background: #10161c; border-bottom: 1px solid #1e2a22; }
.ngb-title { flex: 1; font: bold 14px "Consolas", monospace; letter-spacing: 2px; color: #ff3ea5; text-shadow: 0 0 8px rgba(255, 62, 165, 0.6); }
.ngb-bal { font: 13px "Consolas", monospace; color: #ffd166; }
.ngb-tabs { display: flex; }
.ngb-tabs .ngb-btn { flex: 1; border: 0; border-radius: 0; border-bottom: 2px solid transparent; background: #0d1217; color: #7d8f84; padding: 8px; }
.ngb-tabs .ngb-btn.on { color: #fff; border-bottom-color: #ff3ea5; background: #121a16; }
.ngb-body { padding: 12px; overflow-y: auto; }
.ngb-empty { color: #8a9a8f; text-align: center; padding: 30px 0; }
.ngb-result { display: flex; gap: 10px; align-items: baseline; margin-bottom: 10px; padding: 8px 10px; border-radius: 8px; font-size: 15px; }
.ngb-result b { font: bold 18px "Consolas", monospace; white-space: nowrap; }
.ngb-result.win { background: rgba(109, 255, 168, 0.1); color: #b8ffd4; }
.ngb-result.win b { color: #6dffa8; text-shadow: 0 0 10px rgba(109, 255, 168, 0.6); }
.ngb-result.lose { background: rgba(255, 107, 92, 0.1); color: #ffc4bd; }
.ngb-result.lose b { color: #ff6b5c; }
.ngb-result.push { background: rgba(255, 209, 102, 0.08); color: #ffe6ad; }
.ngb-result.push b { color: #ffd166; }
.ngb-result.bad { background: rgba(255, 107, 92, 0.12); color: #ff8f84; }
.ngb-felt { position: relative; padding: 14px 10px; border-radius: 90px / 40px; background: radial-gradient(ellipse at center, #1f6b3f, #0f3b22 70%, #0a2817);
    border: 3px solid #3b2414; box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.6), 0 0 0 2px #ff3ea533, 0 0 18px rgba(255, 62, 165, 0.15); }
.ngb-lane { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.ngb-who { font: 11px "Consolas", monospace; letter-spacing: 2px; color: #cfe8d6; text-transform: uppercase; }
.ngb-total { min-height: 22px; font: bold 18px "Consolas", monospace; color: #fff; text-shadow: 0 0 6px #000; }
.ngb-rule { margin: 8px 0; text-align: center; font: 10px "Consolas", monospace; letter-spacing: 1px; color: #9fd1af; opacity: 0.8; }
.ngb-dice { display: flex; gap: 12px; }
.ngb-die { width: 46px; height: 46px; display: grid; grid-template-columns: repeat(3, 1fr); grid-template-rows: repeat(3, 1fr); padding: 6px;
    box-sizing: border-box; border-radius: 9px; background: linear-gradient(145deg, #e9fff3, #b9e9cf); box-shadow: 0 3px 0 #7fb196, 0 0 12px rgba(109, 255, 168, 0.4); }
.ngb-die span { width: 8px; height: 8px; margin: auto; border-radius: 50%; }
.ngb-die span.pip { background: #12351f; }
.ngb-die.tumble { animation: ngb-tumble 0.17s linear infinite; }
@keyframes ngb-tumble { 0% { transform: rotate(0) translateY(0); } 50% { transform: rotate(18deg) translateY(-6px); } 100% { transform: rotate(-12deg) translateY(0); } }
.ngb-hand { display: flex; gap: 6px; min-height: 76px; }
.ngb-card { position: relative; width: 52px; height: 74px; border-radius: 6px; background: #fdfdf8; color: #15181c; box-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
    font: bold 13px "Consolas", monospace; animation: ngb-deal 0.25s ease-out both; }
.ngb-card.red { color: #d0263c; }
.ngb-card .tl { position: absolute; left: 4px; top: 3px; }
.ngb-card .br { position: absolute; right: 4px; bottom: 3px; transform: rotate(180deg); }
.ngb-card .mid { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-size: 26px; }
.ngb-card.back { background: repeating-linear-gradient(45deg, #ff3ea5 0 4px, #5a1240 4px 8px); border: 2px solid #fdfdf8; box-sizing: border-box; }
.ngb-card.empty { background: none; border: 1px dashed #9fd1af55; box-shadow: none; animation: none; }
@keyframes ngb-deal { from { transform: translateY(-18px) rotate(-6deg); opacity: 0; } to { transform: none; opacity: 1; } }
.ngb-bet { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin: 12px 0 6px; }
.ngb-label { font: 11px "Consolas", monospace; letter-spacing: 2px; color: #7d8f84; }
.ngb-bet-in { width: 80px; padding: 6px 8px; border-radius: 6px; border: 1px solid #2b3a2f; background: #0f1519; color: #fff; font: 15px "Consolas", monospace; }
.ngb-btn { padding: 7px 14px; border-radius: 8px; border: 1px solid #2b3a2f; background: #121a16; color: #e9f1ea; cursor: pointer;
    font: bold 14px "Rajdhani", "Segoe UI", sans-serif; letter-spacing: 1px; }
.ngb-btn:disabled { opacity: 0.4; cursor: default; }
.ngb-btn.chip { padding: 4px 9px; border-radius: 14px; font-size: 12px; border-color: #ffd16666; color: #ffd166; }
.ngb-btn.chip:hover:not(:disabled) { background: #ffd166; color: #1a1406; }
.ngb-btn.x { padding: 2px 9px; font-size: 13px; }
.ngb-acts { display: flex; gap: 8px; margin-top: 6px; }
.ngb-acts .ngb-btn { flex: 1; padding: 10px; font-size: 16px; }
.ngb-btn.go:not(:disabled) { background: #ff3ea5; border-color: #ff3ea5; color: #fff; box-shadow: 0 0 12px rgba(255, 62, 165, 0.45); }
.ngb-btn.go.alt:not(:disabled) { background: #5ee7ff; border-color: #5ee7ff; color: #06121a; box-shadow: 0 0 12px rgba(94, 231, 255, 0.4); }
@media (max-width: 500px) {
    .ngb-wrap { padding: 0; }
    .ngb-table { border-radius: 0; height: 100%; }
    .ngb-card { width: 44px; height: 64px; }
}
@media (prefers-reduced-motion: reduce) {
    .ngb-die.tumble, .ngb-card { animation: none; }
}

/* ---- the games added later: high-low, the wheel, shells, liar's dice, poker, rat races */
.ngb-tabs { flex-wrap: wrap; }
.ngb-tabs .ngb-btn { flex: 1 1 auto; min-width: 84px; font-size: 12px; padding: 7px 6px; }
.ngb-center { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.ngb-hand.small .ngb-card { width: 30px; height: 42px; font-size: 9px; }
.ngb-hand.small .ngb-card .mid { font-size: 14px; }
.ngb-hand.small { min-height: 44px; }
.ngb-card.big { width: 78px; height: 110px; font-size: 17px; }
.ngb-card.big .mid { font-size: 40px; }
.ngb-total.small { font-size: 13px; font-weight: normal; color: #cfe8d6; }
.ngb-acts.wrap { flex-wrap: wrap; }
.ngb-challenge { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 10px; padding: 8px 10px; border-radius: 8px;
    background: rgba(94, 231, 255, 0.1); border: 1px solid #5ee7ff55; color: #cdf6ff; }
.ngb-challenge span { flex: 1; }
/* the wheel */
.ngb-wheel-stage { position: relative; width: 200px; height: 200px; margin: 4px auto; }
.ngb-pointer { position: absolute; left: 50%; top: -6px; transform: translateX(-50%); z-index: 2; color: #fff; font-size: 18px; text-shadow: 0 0 6px #000; }
.ngb-wheel { position: absolute; inset: 0; border-radius: 50%; border: 4px solid #1b1f24; box-shadow: 0 0 18px rgba(255, 62, 165, 0.45), inset 0 0 20px rgba(0, 0, 0, 0.45); }
.ngb-wlabel { position: absolute; left: 50%; top: 50%; width: 22px; margin: -9px 0 0 -11px; text-align: center; font: bold 12px "Consolas", monospace;
    color: #0b0f14; transform-origin: 50% 50%; }
.ngb-hub { position: absolute; left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px 0 0 -28px; border-radius: 50%; display: flex;
    align-items: center; justify-content: center; background: #0b0f14; color: #ff3ea5; font: bold 11px "Consolas", monospace; letter-spacing: 2px;
    box-shadow: 0 0 10px #ff3ea5; }
.ngb-picks { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 10px; }
.ngb-btn.pick { flex: 1; }
.ngb-btn.pick.pink { border-color: #ff3ea5; color: #ff8cc8; }
.ngb-btn.pick.cyan { border-color: #2fd8f0; color: #8beeff; }
.ngb-btn.num { padding: 4px 0; width: 34px; font-size: 12px; }
.ngb-btn.on { background: #e9f1ea; color: #0b0f14; }
/* the shell game */
.ngb-cups { display: flex; gap: 26px; justify-content: center; padding: 18px 0 6px; }
.ngb-cup { position: relative; width: 70px; height: 80px; padding: 0; border: 0; background: none; cursor: pointer; }
.ngb-cup-body { position: absolute; left: 6px; right: 6px; bottom: 0; height: 66px; border-radius: 10px 10px 4px 4px;
    background: linear-gradient(90deg, #6b3a1c, #a8653a 45%, #6b3a1c); box-shadow: 0 4px 0 #3b2414; transition: transform 0.35s; }
.ngb-cup:hover .ngb-cup-body { transform: translateY(-4px); }
.ngb-cup.lifted .ngb-cup-body { transform: translateY(-34px); }
.ngb-cup.picked .ngb-cup-body { box-shadow: 0 4px 0 #3b2414, 0 0 14px #5ee7ff; }
.ngb-ball { position: absolute; left: 50%; bottom: 2px; width: 18px; height: 18px; margin-left: -9px; border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #fff, #ff3ea5); box-shadow: 0 0 10px #ff3ea5; }
.ngb-cup-num { position: absolute; left: 0; right: 0; bottom: 24px; text-align: center; font: bold 15px "Consolas", monospace; color: #f5d6b8; }
/* liar's dice */
.ngb-dice.small .ngb-die { width: 32px; height: 32px; padding: 4px; }
.ngb-dice.small .ngb-die span { width: 6px; height: 6px; }
.ngb-dice.small { gap: 6px; }
.ngb-die.hidden { display: flex; align-items: center; justify-content: center; background: linear-gradient(145deg, #3a1a2e, #1a0c16);
    color: #ff3ea5; font: bold 15px "Consolas", monospace; box-shadow: 0 3px 0 #0d060b; }
.ngb-bids { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; margin: 10px 0; min-height: 22px; }
.ngb-bid { padding: 2px 8px; border-radius: 10px; font: 12px "Consolas", monospace; background: rgba(0, 0, 0, 0.35); }
.ngb-bid.you { color: #8beeff; }
.ngb-bid.dealer { color: #ff8cc8; }
.ngb-bidctl { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; width: 100%; }
.ngb-qty { min-width: 40px; text-align: center; font: bold 15px "Consolas", monospace; }
.ngb-facebtn { padding: 2px; border: 2px solid transparent; border-radius: 8px; background: none; cursor: pointer; }
.ngb-facebtn .ngb-die { width: 28px; height: 28px; padding: 3px; }
.ngb-facebtn .ngb-die span { width: 5px; height: 5px; }
.ngb-facebtn.on { border-color: #ff3ea5; }
/* poker */
.ngb-card.pickable { cursor: pointer; transition: transform 0.15s; }
.ngb-card.pickable:hover { transform: translateY(-3px); }
.ngb-card.swap { transform: translateY(-10px); box-shadow: 0 0 0 2px #ff3ea5, 0 6px 12px rgba(0, 0, 0, 0.5); opacity: 0.75; }
/* rat races */
.ngb-track { border-radius: 14px; }
.ngb-ratlane { display: grid; grid-template-columns: 130px 1fr 110px; align-items: center; gap: 8px; width: 100%; margin: 3px 0; padding: 4px 6px;
    border: 1px solid transparent; border-radius: 6px; background: rgba(0, 0, 0, 0.25); color: #e9f1ea; cursor: pointer; font: 13px "Rajdhani", sans-serif; text-align: left; }
.ngb-ratlane.on { border-color: #ff3ea5; }
.ngb-ratlane.winner { border-color: #ffd166; background: rgba(255, 209, 102, 0.15); }
.ngb-ratname { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ngb-ratbar { position: relative; height: 18px; border-radius: 9px; background: repeating-linear-gradient(90deg, #2b4a35 0 10px, #24402e 10px 20px);
    border-right: 3px solid #fff; }
.ngb-rat { position: absolute; top: -1px; font-size: 16px; transition: left 2.8s linear; transform: scaleX(-1); }
.ngb-ratodds { font: 12px "Consolas", monospace; color: #ffd166; text-align: right; }
@media (max-width: 500px) {
    .ngb-ratlane { grid-template-columns: 90px 1fr 70px; font-size: 12px; }
    .ngb-wheel-stage { width: 170px; height: 170px; }
}
.ngb-tabs { display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)); }
.ngb-tabs .ngb-btn { min-width: 0; }
.ngb-acts .ngb-bidctl .ngb-btn { flex: none; padding: 4px 12px; font-size: 15px; }
