:root {
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #f3f5ef;
  background: #101812;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --surface: #17231b;
  --surface-raised: #1d2b21;
  --line: #334438;
  --muted: #a7b3a8;
  --green: #94df79;
  --green-dark: #233d2a;
  --red: #f08072;
}

* { box-sizing: border-box; }

body {
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(ellipse at 75% -15%, rgb(56 99 54 / 22%), transparent 48rem),
    #101812;
}

button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .6; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }

.casino-header {
  position: sticky;
  z-index: 3;
  top: 0;
  display: flex;
  min-height: 76px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px clamp(18px, 5vw, 72px);
  border-bottom: 1px solid rgb(255 255 255 / 7%);
  background: rgb(16 24 18 / 93%);
  backdrop-filter: blur(16px);
}

.casino-brand { display: inline-flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; white-space: nowrap; }
.casino-brand b { margin-left: 5px; color: var(--green); font-size: 11px; letter-spacing: .14em; }
.brand-mark { display: grid; width: 35px; height: 35px; place-items: center; border-radius: 11px; background: var(--green-dark); color: var(--green); font-size: 20px; }
.casino-nav { display: flex; align-items: center; gap: clamp(14px, 2.4vw, 34px); color: var(--muted); font-size: 13px; }
.casino-nav a:hover, .casino-nav a.active { color: #fff; }
.casino-nav a.active { color: var(--green); }
.header-account { display: flex; align-items: center; gap: 12px; }
.balance-pill { display: flex; align-items: center; gap: 6px; color: #d7dfd4; font-size: 12px; white-space: nowrap; }
.balance-pill span:nth-child(2) { color: var(--green); font-size: 15px; font-weight: 800; }
.token-icon { color: #e8c66c; }
.account-button, .secondary-button, .leave-button, .computer-button, .primary-button {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid var(--line);
  border-radius: 9px;
  color: #f3f5ef;
  background: var(--surface-raised);
  font-size: 13px;
  font-weight: 700;
  transition: background .16s ease, border-color .16s ease, transform .16s ease;
}
.account-button:hover, .secondary-button:hover { border-color: #708573; background: #283a2d; }
.primary-button { border-color: #a3e68b; color: #112016; background: var(--green); }
.primary-button:hover { border-color: #c3f5b1; background: #a9ed91; transform: translateY(-1px); }
.computer-button { border-color: #74433d; color: #f3c1b9; background: #382522; }
.computer-button:hover { border-color: var(--red); background: #482b27; }
.leave-button { border-color: #69413c; color: #f3a89d; background: #2a1e1c; }
.leave-button:hover { border-color: var(--red); }

main { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }
.poker-hero { display: flex; align-items: flex-end; justify-content: space-between; gap: 32px; padding: 68px 0 52px; }
.eyebrow { margin: 0 0 12px; color: var(--green); font-size: 10px; font-weight: 800; letter-spacing: .17em; }
.status-dot { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 12px var(--green); }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 15px; font-size: clamp(39px, 6vw, 68px); line-height: .99; letter-spacing: -.055em; }
h1 span, h2 span { color: var(--green); }
.hero-description { max-width: 520px; margin-bottom: 0; color: var(--muted); font-size: 15px; line-height: 1.65; }
.daily-card { display: flex; width: min(325px, 100%); align-items: center; gap: 15px; padding: 19px; border: 1px solid #485b3e; border-radius: 14px; background: linear-gradient(135deg, #253927, #1a281e); }
.daily-icon { color: #e9c66c; font-size: 22px; }
.daily-label { margin: 0 0 6px; color: #c9d6c6; font-size: 10px; font-weight: 800; letter-spacing: .14em; }
.daily-copy { margin: 0; color: #f5f7f1; font-size: 13px; line-height: 1.4; }

.slots-section { padding: 28px 0 48px; border-top: 1px solid rgb(255 255 255 / 8%); }
.slots-section .section-heading { align-items: flex-end; margin-bottom: 18px; }
.slots-section .eyebrow { margin-bottom: 6px; }
.slots-rules { margin: 0; color: var(--muted); font-size: 12px; }
.slots-machine { padding: clamp(14px, 4vw, 36px); border: 1px solid #485b3e; border-radius: 18px; background: radial-gradient(ellipse at 50% 35%, #285a38, #183d27 75%, #142e1d); box-shadow: inset 0 0 0 3px #142b1c, 0 18px 40px rgb(0 0 0 / 18%); transition: box-shadow .3s ease, filter .3s ease; }
.slots-machine.combo-stage-small { animation: slot-stage-small 1.15s ease-in-out infinite alternate; }
.slots-machine.combo-stage-medium { animation: slot-stage-medium .9s ease-in-out infinite alternate; }
.slots-machine.combo-stage-large { animation: slot-stage-large .72s ease-in-out infinite alternate; }
.slots-machine.combo-stage-jackpot { animation: slot-stage-jackpot .52s ease-in-out infinite alternate; }
.slot-grid { display: grid; width: min(100%, 620px); grid-template-columns: repeat(5, minmax(0, 1fr)); gap: clamp(4px, 1.4vw, 12px); margin: 0 auto; padding: clamp(8px, 2vw, 16px); border: 2px solid #b89a56; border-radius: 17px; background: linear-gradient(140deg, #14221b, #222b20 52%, #14221b); box-shadow: 0 0 0 4px rgb(239 204 111 / 13%), inset 0 0 25px rgb(0 0 0 / 45%); }
.slot-cell { position: relative; z-index: 0; display: grid; aspect-ratio: 1; min-width: 0; place-items: center; overflow: hidden; border: 2px solid #a48a53; border-radius: clamp(6px, 1.5vw, 13px); background: linear-gradient(145deg, #fffdf3, #dedbce); box-shadow: inset 0 0 0 2px #f4edcf, 0 4px 10px rgb(0 0 0 / 30%); font-size: clamp(22px, 7vw, 58px); line-height: 1; transition: border-color .2s ease, box-shadow .2s ease, background .2s ease; }
.slot-symbol-icon { display: block; width: .86em; height: .86em; object-fit: contain; pointer-events: none; }
.slot-cell.is-spinning { animation: slot-spin .11s linear infinite alternate; filter: saturate(1.7) blur(.65px); }
.slot-cell.is-stopping { animation: slot-stop .32s cubic-bezier(.2, .8, .25, 1); }
.slot-cell.is-winning { z-index: 1; }
.slot-cell.combo-small { border-color: #52f2e7; background: linear-gradient(145deg, #e9fff8, #b6fff1); box-shadow: inset 0 0 0 2px #fff, 0 0 16px #2cf5e5; animation: slot-win-small .85s ease-in-out infinite alternate; }
.slot-cell.combo-medium { border-color: #ffcf38; background: linear-gradient(145deg, #fffbe2, #ffc96a); box-shadow: inset 0 0 0 2px #fff, 0 0 24px #ffae21; animation: slot-win-medium .62s ease-in-out infinite alternate; }
.slot-cell.combo-large { border-color: #ff6adf; background: linear-gradient(145deg, #fff0ff, #ff91d8); box-shadow: inset 0 0 0 3px #fff, 0 0 30px #ff45cb; animation: slot-win-large .42s ease-in-out infinite alternate; }
.slot-cell.combo-jackpot { border-color: #fff76b; background: linear-gradient(145deg, #fff9b0, #ff76aa 50%, #80f5ff); box-shadow: inset 0 0 0 3px #fff, 0 0 38px #fff36a; animation: slot-win-jackpot .42s ease-in-out infinite alternate; }
@keyframes slot-spin { from { transform: translateY(-28%) rotateX(36deg) scale(.9); } to { transform: translateY(28%) rotateX(-36deg) scale(1.04); } }
@keyframes slot-stop { 0% { transform: translateY(-16px) scale(.88); } 65% { transform: translateY(4px) scale(1.06); } 100% { transform: translateY(0) scale(1); } }
@keyframes slot-win-small { to { transform: scale(1.045); box-shadow: inset 0 0 0 2px #fff, 0 0 22px #35fff0; } }
@keyframes slot-win-medium { to { transform: scale(1.075); box-shadow: inset 0 0 0 3px #fff, 0 0 34px #ffad1f; filter: saturate(1.5); } }
@keyframes slot-win-large { to { transform: scale(1.11) rotate(2deg); box-shadow: inset 0 0 0 3px #fff, 0 0 44px #ff45cb; filter: hue-rotate(15deg) saturate(1.7); } }
@keyframes slot-win-jackpot { to { transform: scale(1.16) rotate(-3deg); box-shadow: inset 0 0 0 4px #fff, 0 0 52px #fff36a; filter: hue-rotate(55deg) saturate(2); } }
@keyframes slot-stage-small { to { box-shadow: inset 0 0 0 3px #142b1c, 0 0 25px #35fff0; } }
@keyframes slot-stage-medium { to { box-shadow: inset 0 0 0 3px #142b1c, 0 0 34px #ffad1f; filter: saturate(1.2); } }
@keyframes slot-stage-large { to { box-shadow: inset 0 0 0 3px #142b1c, 0 0 46px #ff45cb; filter: saturate(1.4); } }
@keyframes slot-stage-jackpot { to { box-shadow: inset 0 0 0 3px #142b1c, 0 0 58px #fff36a; filter: hue-rotate(12deg) saturate(1.7); } }
.slots-controls { display: flex; align-items: end; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.slots-controls label { margin: 0 2px 11px 0; }
.slots-bet-control { display: flex; align-items: center; gap: 8px; }
.slots-bet-control input { width: 120px; }
.slots-bet-control span { color: #c3d1c0; font-size: 11px; }
.slots-controls button { min-width: 120px; }
.slots-message { min-height: 22px; margin: 17px 0; color: #e3ede0; text-align: center; font-size: 14px; font-weight: 650; }
.slots-paytable { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; }
.slots-paytable-item { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 3px 7px; padding: 8px 11px; border: 1px solid rgb(230 240 220 / 20%); border-radius: 8px; color: #dce8d9; background: rgb(12 28 17 / 55%); font-size: 11px; }
.slots-paytable-item > .slot-symbol-icon { width: 28px; height: 28px; grid-row: span 2; }
.slots-paytable-item small { grid-column: 1 / -1; color: #f0d47a; font-size: 10px; }
.slots-section .error { color: #ff9a8d; }
.slots-combo-note { margin: 14px 0 0; color: #bcc9b9; text-align: center; font-size: 11px; }

.roulette-section { padding: 28px 0 48px; border-top: 1px solid rgb(255 255 255 / 8%); }
.roulette-section .section-heading { align-items: flex-end; margin-bottom: 18px; }
.roulette-section .eyebrow { margin-bottom: 6px; }
.roulette-rules { margin: 0; color: var(--muted); font-size: 12px; }
.roulette-table { display: grid; justify-items: center; gap: 12px; padding: clamp(18px, 4vw, 36px); border: 1px solid #485b3e; border-radius: 18px; background: radial-gradient(ellipse at 50% 30%, #285a38, #183d27 75%, #142e1d); box-shadow: inset 0 0 0 3px #142b1c, 0 18px 40px rgb(0 0 0 / 18%); }
.roulette-slider-window { position: relative; width: min(100%, 700px); height: 80px; overflow: hidden; border: 2px solid #d5b66b; border-radius: 11px; background: #102017; box-shadow: 0 0 0 4px rgb(213 182 107 / 12%), inset 0 0 16px rgb(0 0 0 / 45%); }
.roulette-slider-window::before, .roulette-slider-window::after { position: absolute; z-index: 1; top: 0; bottom: 0; width: 60px; content: ""; pointer-events: none; }
.roulette-slider-window::before { left: 0; background: linear-gradient(90deg, #102017, transparent); }
.roulette-slider-window::after { right: 0; background: linear-gradient(270deg, #102017, transparent); }
.roulette-slider-track { display: flex; width: max-content; height: 100%; align-items: center; gap: 6px; padding: 0 6px; transition: transform 2.6s cubic-bezier(.08, .72, .12, 1); will-change: transform; }
.roulette-slider-cell { display: grid; width: 54px; height: 56px; flex: 0 0 54px; place-items: center; border: 1px solid rgb(255 255 255 / 24%); border-radius: 7px; color: #fff; font-size: 20px; font-weight: 850; box-shadow: 0 3px 8px rgb(0 0 0 / 25%); }
.roulette-slider-cell.result-red { background: #a83b35; }
.roulette-slider-cell.result-black { background: #151a16; }
.roulette-slider-cell.result-green { background: #16834b; }
.roulette-slider-cell.is-winning { border: 2px solid #fff3a4; box-shadow: 0 0 14px #f0d47a, inset 0 0 0 1px #fff; }
.roulette-slider-marker { position: absolute; z-index: 2; top: 0; bottom: 0; left: 50%; width: 3px; background: #f0d47a; box-shadow: 0 0 8px #f0d47a; transform: translateX(-50%); }
.roulette-result { display: grid; justify-items: center; gap: 4px; min-height: 78px; }
.roulette-result-number { display: grid; width: 52px; height: 52px; place-items: center; border: 2px solid #d5b66b; border-radius: 10px; color: white; background: #26342a; font-size: 25px; font-weight: 850; box-shadow: 0 4px 12px rgb(0 0 0 / 22%); }
.roulette-result-number.result-red { background: #a83b35; }
.roulette-result-number.result-black { background: #151a16; }
.roulette-result-number.result-green { background: #16834b; }
.roulette-result-color { color: #d7e3d5; font-size: 11px; font-weight: 700; }
.roulette-message { min-height: 20px; margin: 0; color: #e3ede0; text-align: center; font-size: 13px; font-weight: 650; }
.roulette-number-board { display: grid; width: min(100%, 630px); grid-template-columns: minmax(38px, .42fr) minmax(0, 3fr); gap: 5px; padding: 8px; border: 1px solid #aa8d51; border-radius: 10px; background: #173a25; }
.roulette-number-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px; }
.roulette-bet-option { min-width: 0; min-height: 32px; border: 1px solid rgb(255 255 255 / 18%); border-radius: 5px; color: #fff; background: #26342a; font-size: 12px; font-weight: 750; transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease; }
.roulette-bet-option:hover:not(:disabled) { transform: translateY(-1px); border-color: #f0d47a; }
.roulette-bet-option.selected { border-color: #fff3a4; box-shadow: 0 0 0 2px #e4c96f, 0 0 12px rgb(240 212 122 / 55%); }
.roulette-bet-option:disabled { cursor: wait; opacity: .8; }
.roulette-bet-option.roulette-red { background: #a83b35; }
.roulette-bet-option.roulette-black { background: #151a16; }
.roulette-bet-option.roulette-zero { min-height: 100%; background: #16834b; }
.roulette-outside-bets { display: grid; width: min(100%, 630px); grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.roulette-outside-bets .roulette-bet-option { min-height: 38px; }
.roulette-controls { display: flex; align-items: end; justify-content: center; flex-wrap: wrap; gap: 10px; margin-top: 7px; }
.roulette-controls label { margin: 0 2px 11px 0; }
.roulette-bet-control { display: flex; align-items: center; gap: 8px; }
.roulette-bet-control input { width: 120px; }
.roulette-bet-control span { color: #c3d1c0; font-size: 11px; }
.roulette-controls button { min-width: 130px; }
.roulette-payout { min-height: 18px; margin: 0; color: #f0d47a; text-align: center; font-size: 12px; font-weight: 700; }
.roulette-section .error { color: #ff9a8d; }

.blackjack-section { padding: 28px 0 48px; border-top: 1px solid rgb(255 255 255 / 8%); }
.blackjack-section .section-heading { align-items: flex-end; margin-bottom: 18px; }
.blackjack-section .eyebrow { margin-bottom: 6px; }
.blackjack-rules { margin: 0; color: var(--muted); font-size: 12px; }
.blackjack-table { padding: clamp(20px, 4vw, 36px); border: 1px solid #485b3e; border-radius: 18px; background: radial-gradient(ellipse at 50% 35%, #285a38, #183d27 75%, #142e1d); box-shadow: inset 0 0 0 3px #142b1c, 0 18px 40px rgb(0 0 0 / 18%); }
.blackjack-table.result-win { animation: blackjack-win-glow 1.05s ease-in-out 2; }
.blackjack-table.result-loss { animation: blackjack-loss-shake .48s ease-in-out 1; }
.blackjack-table.result-push { animation: blackjack-push-glow .8s ease-in-out 1; }
.blackjack-hand { display: grid; justify-items: center; gap: 12px; }
.blackjack-hand-heading { display: flex; min-width: 190px; justify-content: center; gap: 12px; color: #edf4e9; font-size: 13px; }
.blackjack-hand-heading span { color: #f0d47a; font-weight: 800; }
.blackjack-cards { display: flex; min-height: 78px; justify-content: center; gap: 8px; }
.blackjack-cards .playing-card { width: 52px; height: 74px; flex-basis: 52px; }
.blackjack-message { min-height: 22px; margin: 19px 0; color: #e3ede0; text-align: center; font-size: 14px; font-weight: 650; }
.blackjack-controls { display: flex; align-items: end; justify-content: center; flex-wrap: wrap; gap: 9px; margin-top: 16px; }
.blackjack-controls label { margin: 0 3px 11px 0; }
.blackjack-bet-control { display: flex; align-items: center; gap: 8px; }
.blackjack-bet-control input { width: 120px; }
.blackjack-bet-control span { color: #c3d1c0; font-size: 11px; }
.blackjack-payout { min-height: 19px; margin: 12px 0 0; color: #f0d47a; text-align: center; font-size: 12px; font-weight: 700; }

.lobby-section { padding: 30px 0 54px; border-top: 1px solid rgb(255 255 255 / 8%); }
.section-heading, .public-rooms-heading, .room-topbar, .table-info { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.section-heading { margin-bottom: 22px; }
.section-heading .eyebrow { margin-bottom: 6px; }
h2 { margin-bottom: 0; font-size: clamp(27px, 4vw, 37px); letter-spacing: -.04em; }
.lobby-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.lobby-card { padding: 24px; border: 1px solid var(--line); border-radius: 14px; background: linear-gradient(145deg, #1b2a20, #17231b); }
.lobby-card .eyebrow { margin-bottom: 8px; }
.lobby-card h3 { margin-bottom: 22px; font-size: 21px; letter-spacing: -.025em; }
.lobby-card > p:not(.eyebrow) { color: var(--muted); font-size: 13px; line-height: 1.6; }
label { display: block; margin: 15px 0 7px; color: #d6dfd5; font-size: 12px; font-weight: 650; }
input, select { min-width: 0; min-height: 42px; padding: 0 12px; border: 1px solid #405346; border-radius: 8px; outline: none; color: #f3f5ef; background: #101912; }
input:focus, select:focus { border-color: var(--green); box-shadow: 0 0 0 3px rgb(148 223 121 / 12%); }
.lobby-card > input, .lobby-card > select { width: 100%; }
.input-with-suffix { display: flex; align-items: center; gap: 10px; }
.input-with-suffix input { width: 100%; }
.input-with-suffix span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.full-button { width: 100%; margin-top: 18px; }
.computer-button.full-button { margin-top: 9px; }
.join-card { display: flex; flex-direction: column; }
.join-row { display: flex; gap: 9px; margin-top: 16px; }
.join-row input { flex: 1; width: 0; text-transform: uppercase; letter-spacing: .12em; }
.join-row input::placeholder { color: #66746a; }
.lobby-message { min-height: 20px; margin: 10px 0 0 !important; color: var(--green) !important; font-size: 12px !important; }
.error { color: #ff9a8d !important; }
.token-note { margin-top: auto; padding-top: 24px; color: #91a094; font-size: 11px; line-height: 1.6; }
.public-rooms-heading { margin: 36px 0 10px; }
.public-rooms-heading h3 { margin: 0; font-size: 16px; }
.public-rooms-heading span, .rooms-status { color: var(--muted); font-size: 12px; }
.rooms-status { margin-bottom: 12px; }
.room-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.public-room-card { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); }
.public-room-card > div { display: grid; gap: 5px; min-width: 0; }
.public-room-card strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.public-room-card span { color: var(--muted); font-size: 11px; }
.public-room-card button { min-height: 34px; padding: 0 12px; }

.poker-room { padding: 26px 0 60px; border-top: 1px solid rgb(255 255 255 / 8%); }
.room-topbar { margin-bottom: 18px; }
.room-topbar .eyebrow { margin-bottom: 7px; }
.room-topbar h2 { font-size: clamp(22px, 4vw, 30px); }
#room-code-label { padding: 4px 8px; border: 1px solid #50604a; border-radius: 5px; color: #e3cb78; letter-spacing: .1em; }
.room-top-actions { display: flex; gap: 8px; }
.poker-table { position: relative; overflow: hidden; min-height: 320px; padding: 20px; border: 7px solid #46332b; border-radius: 190px; background: radial-gradient(ellipse at center, #245535, #174328 68%, #12361f); box-shadow: inset 0 0 0 2px #8f6c43, 0 18px 40px rgb(0 0 0 / 25%); }
.table-info { position: relative; z-index: 1; width: min(650px, 90%); margin: 0 auto; color: #d4e4d3; font-size: 12px; }
.table-info b { color: #f0d47a; font-size: 17px; }
.community-cards, .hole-cards { display: flex; justify-content: center; gap: 7px; }
.community-cards { min-height: 81px; margin: 28px auto 16px; }
.playing-card { display: flex; width: 48px; height: 68px; flex: 0 0 48px; flex-direction: column; align-items: center; justify-content: center; gap: 0; border-radius: 6px; background: #f7f6ed; box-shadow: 0 3px 8px rgb(0 0 0 / 26%); font-family: Georgia, serif; font-size: 20px; font-weight: 800; line-height: 1.1; }
.blackjack-cards .card-deal-in { animation: blackjack-card-deal .48s cubic-bezier(.2, .8, .25, 1) both; animation-delay: calc(var(--card-order, 0) * 100ms); }
.blackjack-cards .card-flip-in { animation: blackjack-card-flip .58s cubic-bezier(.2, .75, .25, 1) both; }
.playing-card span + span { font-size: 18px; }
.card-red { color: #c93232; }
.card-black { color: #17221a; }
.card-placeholder { color: rgb(255 255 255 / 22%); background: rgb(13 48 27 / 45%); box-shadow: none; font-size: 30px; }
.card-back { border: 2px solid #f4e3bf; color: #f5e1b5; background: repeating-linear-gradient(45deg, #a23c34 0 5px, #872e2b 5px 10px); }
.blackjack-cards .card-back { border-color: #e8c86d; }
@keyframes blackjack-card-deal {
  0% { opacity: 0; transform: translate(-28px, -42px) rotate(-16deg) scale(.8); }
  72% { opacity: 1; transform: translate(3px, 3px) rotate(3deg) scale(1.04); }
  100% { opacity: 1; transform: translate(0) rotate(0) scale(1); }
}
@keyframes blackjack-card-flip {
  0% { opacity: .7; transform: perspective(500px) rotateY(90deg) scale(.94); }
  55% { opacity: 1; transform: perspective(500px) rotateY(-12deg) scale(1.04); }
  100% { transform: perspective(500px) rotateY(0) scale(1); }
}
@keyframes blackjack-win-glow {
  0%, 100% { box-shadow: inset 0 0 0 3px #142b1c, 0 18px 40px rgb(0 0 0 / 18%); }
  50% { box-shadow: inset 0 0 0 3px #b7ff82, 0 0 36px rgb(133 255 111 / 70%); }
}
@keyframes blackjack-loss-shake {
  0%, 100% { transform: translateX(0); }
  18%, 54% { transform: translateX(-7px); }
  36%, 72% { transform: translateX(7px); }
}
@keyframes blackjack-push-glow {
  0%, 100% { box-shadow: inset 0 0 0 3px #142b1c, 0 18px 40px rgb(0 0 0 / 18%); }
  50% { box-shadow: inset 0 0 0 3px #f0d47a, 0 0 25px rgb(240 212 122 / 48%); }
}
.table-message { min-height: 22px; margin: 0 auto 20px; color: #e3ede0; text-align: center; font-size: 13px; }
.seat-list { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; }
.player-seat { position: relative; display: flex; min-width: 180px; flex-direction: column; align-items: center; gap: 10px; padding: 13px; border: 1px solid rgb(230 240 220 / 30%); border-radius: 12px; background: rgb(12 28 17 / 78%); }
.player-seat.is-you { border-color: #c6ec8f; box-shadow: 0 0 0 2px rgb(198 236 143 / 12%); }
.player-seat.is-acting { box-shadow: 0 0 0 2px #f0d47a, 0 0 18px rgb(240 212 122 / 35%); }
.player-seat.is-folded { opacity: .55; }
.seat-header { display: grid; gap: 4px; justify-items: center; }
.seat-header strong { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.seat-header span, .seat-role { color: #bdcdbb; font-size: 10px; }
.seat-role { color: #e0cc7f; font-weight: 800; letter-spacing: .1em; }
.hole-cards { min-height: 48px; gap: 4px; }
.hole-cards .playing-card { width: 34px; height: 48px; flex-basis: 34px; font-size: 15px; }
.hole-cards .playing-card span + span { font-size: 14px; }
.table-controls { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px; margin-top: 18px; }
.turn-actions, .owner-actions { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 9px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.raise-control { display: flex; align-items: center; gap: 8px; }
.raise-control label, .owner-actions label { margin: 0 2px 0 8px; }
.raise-control input { width: 96px; }
.owner-actions select { min-height: 38px; }
.rules-section { display: grid; grid-template-columns: .8fr 1.2fr; gap: 40px; padding: 44px 0 68px; border-top: 1px solid rgb(255 255 255 / 8%); }
.rules-section h2 { font-size: clamp(31px, 5vw, 45px); line-height: 1.06; }
.rules-copy { max-width: 620px; color: var(--muted); font-size: 14px; line-height: 1.75; }
.rules-copy p:last-child { margin-bottom: 0; }
.casino-footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 22px clamp(20px, 5vw, 72px); border-top: 1px solid rgb(255 255 255 / 8%); }
.casino-footer p { margin: 0; color: #87958a; font-size: 11px; }

.account-dialog { width: min(420px, calc(100% - 28px)); padding: 0; overflow: visible; border: 1px solid #405346; border-radius: 16px; color: #f3f5ef; background: #17231b; box-shadow: 0 25px 90px rgb(0 0 0 / 55%); }
.account-dialog::backdrop { background: rgb(5 10 6 / 75%); backdrop-filter: blur(5px); }
.account-form, .account-profile { position: relative; display: flex; flex-direction: column; padding: 30px; }
.account-form h2, .account-profile h2 { margin-bottom: 9px; font-size: 27px; }
.dialog-description { margin-bottom: 12px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.account-form > input { width: 100%; }
.dialog-close { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border: 0; border-radius: 8px; color: #bac6bb; background: transparent; font-size: 24px; }
.dialog-close:hover { background: #283a2d; }
.submit-button { width: 100%; margin-top: 22px; }
.mode-toggle { margin-top: 14px; border: 0; color: var(--green); background: transparent; font-size: 12px; }
.form-error { color: #ff9a8d; font-size: 12px; }
.profile-balance { margin: 7px 0 0; color: var(--green); font-size: 24px; font-weight: 800; }

@media (max-width: 800px) {
  .casino-header { flex-wrap: wrap; gap: 10px 18px; padding: 12px 20px; }
  .casino-nav { order: 3; width: 100%; justify-content: center; padding-top: 7px; }
  .header-account { margin-left: auto; }
  .poker-hero { align-items: flex-start; flex-direction: column; padding-top: 48px; }
  .daily-card { width: min(100%, 400px); }
  .poker-table { border-radius: 70px; }
}

@media (max-width: 580px) {
  main { width: min(100% - 28px, 1120px); }
  .casino-header { padding-inline: 14px; }
  .casino-brand { font-size: 14px; }
  .brand-mark { width: 30px; height: 30px; }
  .balance-pill { gap: 4px; font-size: 10px; }
  .balance-pill span:nth-child(2) { font-size: 13px; }
  .account-button { min-height: 35px; padding-inline: 10px; font-size: 11px; }
  .casino-nav { justify-content: flex-start; gap: 14px; overflow-x: auto; font-size: 11px; scrollbar-width: none; }
  .casino-nav::-webkit-scrollbar { display: none; }
  .casino-nav a { flex: 0 0 auto; }
  .poker-hero { padding: 40px 0 34px; }
  .slots-section .section-heading { align-items: flex-start; flex-direction: column; gap: 8px; }
  .slots-controls { align-items: stretch; }
  .slots-controls label { width: 100%; margin-bottom: 0; }
  .slots-bet-control { flex: 1; }
  .slots-bet-control input { width: 100%; }
  .slots-controls button { flex: 1; }
  .roulette-section .section-heading { align-items: flex-start; flex-direction: column; gap: 8px; }
  .roulette-controls { align-items: stretch; width: 100%; }
  .roulette-controls label { width: 100%; margin-bottom: 0; }
  .roulette-bet-control { flex: 1; }
  .roulette-bet-control input { width: 100%; }
  .roulette-controls button { flex: 1; }
  .roulette-number-board { grid-template-columns: 35px minmax(0, 1fr); gap: 3px; padding: 5px; }
  .roulette-number-grid { gap: 3px; }
  .roulette-bet-option { min-height: 31px; font-size: 11px; }
  .roulette-outside-bets { gap: 4px; }
  .roulette-outside-bets .roulette-bet-option { padding-inline: 3px; font-size: 10px; }
  .blackjack-section .section-heading { align-items: flex-start; flex-direction: column; gap: 8px; }
  .blackjack-controls { align-items: stretch; }
  .blackjack-controls label { width: 100%; margin-bottom: 0; }
  .blackjack-bet-control { flex: 1; }
  .blackjack-bet-control input { width: 100%; }
  .blackjack-controls > button { flex: 1; }
  .lobby-layout, .room-list, .rules-section { grid-template-columns: 1fr; }
  .lobby-card { padding: 19px; }
  .section-heading { align-items: flex-end; }
  .section-heading > button { padding-inline: 9px; font-size: 11px; }
  .room-topbar { align-items: flex-start; flex-direction: column; }
  .room-top-actions { width: 100%; }
  .room-top-actions button { flex: 1; }
  .poker-table { min-height: 300px; padding: 19px 10px; border-width: 5px; border-radius: 38px; }
  .table-info { width: 95%; }
  .community-cards { gap: 4px; }
  .playing-card { width: 40px; height: 58px; flex-basis: 40px; font-size: 17px; }
  .playing-card span + span { font-size: 15px; }
  .player-seat { min-width: 145px; padding: 10px; }
  .turn-actions, .owner-actions { width: 100%; }
  .raise-control { flex-wrap: wrap; justify-content: center; }
  .rules-section { gap: 20px; padding: 36px 0 48px; }
  .casino-footer { align-items: flex-start; flex-direction: column; padding: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
  .blackjack-table.result-win, .blackjack-table.result-loss, .blackjack-table.result-push,
  .blackjack-cards .card-deal-in, .blackjack-cards .card-flip-in {
    animation: none;
  }
  .slot-cell.is-spinning, .slot-cell.is-stopping, .slot-cell.is-winning,
  .slots-machine.combo-stage-small, .slots-machine.combo-stage-medium,
  .slots-machine.combo-stage-large, .slots-machine.combo-stage-jackpot {
    animation: none;
    filter: none;
  }
  .roulette-slider-track {
    transition: none;
    will-change: auto;
  }
}
