@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@600;700;800;900&family=Outfit:wght@300;400;500;600;700;800&display=swap');

:root {
    --bg-dark: #0a0e14;
    --table-green: #0d5435;
    --table-green-light: #15794d;
    --table-rim: #2d180b;
    --table-border-gold: #e5b358;
    --table-border-gold-dark: #8c6320;
    --gold: #f9ca24;
    --gold-glow: rgba(249, 202, 36, 0.4);
    --crimson: #eb2f06;
    --crimson-hover: #b71540;
    --emerald: #10ac84;
    --emerald-hover: #1dd1a1;
    --navy: #1e3799;
    --royal-purple: #4a235a;
    --text-white: #f5f6fa;
    --text-muted: #95a5a6;
    --glass-bg: rgba(18, 24, 38, 0.85);
    --glass-border: rgba(249, 202, 36, 0.25);
    --card-shadow: 0 10px 25px rgba(0, 0, 0, 0.6);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
    -webkit-user-select: none;
}

body {
    font-family: 'Outfit', sans-serif;
    background: radial-gradient(circle at center, #151d2a 0%, #080c12 100%);
    color: var(--text-white);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* TOP NAVBAR */
.navbar {
    height: 60px;
    background: rgba(10, 14, 20, 0.95);
    border-bottom: 1px solid rgba(249, 202, 36, 0.2);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    z-index: 100;
    backdrop-filter: blur(10px);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo {
    font-size: 26px;
    filter: drop-shadow(0 0 8px rgba(249, 202, 36, 0.6));
}

.brand-title {
    font-family: 'Cinzel', serif;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 1.5px;
    background: linear-gradient(135deg, #fff 0%, #f9ca24 50%, #d48b12 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-badge {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 12px;
    background: rgba(249, 202, 36, 0.15);
    border: 1px solid var(--gold);
    color: var(--gold);
    font-weight: 700;
    letter-spacing: 0.5px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.status-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e74c3c;
    box-shadow: 0 0 6px #e74c3c;
    transition: all 0.3s;
}

.status-pill.online .status-dot {
    background: #2ecc71;
    box-shadow: 0 0 8px #2ecc71;
}

.btn-icon {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-white);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 15px;
    transition: all 0.2s ease;
}

.btn-icon:hover {
    background: var(--gold);
    color: #111;
    border-color: var(--gold);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px var(--gold-glow);
}

.btn-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-white);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-nav:hover {
    background: rgba(249, 202, 36, 0.15);
    border-color: var(--gold);
    color: var(--gold);
}

/* MAIN ARENA */
.game-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 20px;
}

/* CASINO TABLE */
.poker-table-wrapper {
    position: relative;
    width: 100%;
    max-width: 1040px;
    height: 520px;
    margin: 0 auto;
}

.poker-table {
    position: absolute;
    inset: 40px;
    background: radial-gradient(ellipse at center, var(--table-green-light) 0%, var(--table-green) 70%, #062b1a 100%);
    border-radius: 260px;
    border: 18px solid var(--table-rim);
    box-shadow: 
        0 0 0 3px var(--table-border-gold),
        0 0 0 6px var(--table-border-gold-dark),
        0 25px 60px rgba(0, 0, 0, 0.9),
        inset 0 0 80px rgba(0, 0, 0, 0.6);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.table-felt-pattern {
    position: absolute;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 20px 20px;
    pointer-events: none;
}

.table-logo-watermark {
    position: absolute;
    font-family: 'Cinzel', serif;
    font-size: 28px;
    font-weight: 900;
    letter-spacing: 6px;
    color: rgba(249, 202, 36, 0.12);
    text-transform: uppercase;
    pointer-events: none;
}

/* POT & DEALER CHIP TRAY */
.table-center {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: 0;
    pointer-events: auto;
}

.pot-badge {
    background: linear-gradient(135deg, rgba(20, 24, 30, 0.9) 0%, rgba(10, 12, 16, 0.95) 100%);
    border: 2px solid var(--gold);
    border-radius: 30px;
    padding: 8px 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.7), 0 0 15px var(--gold-glow);
    animation: pulseGlow 3s infinite alternate;
}

@keyframes pulseGlow {
    0% { box-shadow: 0 8px 25px rgba(0, 0, 0, 0.7), 0 0 10px rgba(249, 202, 36, 0.3); }
    100% { box-shadow: 0 8px 25px rgba(0, 0, 0, 0.7), 0 0 25px rgba(249, 202, 36, 0.7); }
}

.pot-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--gold);
    font-weight: 700;
}

.pot-amount {
    font-family: 'Cinzel', serif;
    font-size: 24px;
    font-weight: 800;
    color: #fff;
    text-shadow: 0 2px 8px rgba(0,0,0,0.8);
}

.table-stakes-info {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
    background: rgba(0, 0, 0, 0.35);
    padding: 3px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

/* SEATS POSITIONING AROUND TABLE */
.seat {
    position: absolute;
    width: 170px;
    height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 20;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* 6 Seats Coordinates Around Table Perimeter */
.seat-0 { bottom: -20px; left: 50%; transform: translateX(-50%); } /* User Seat (Bottom Center) */
.seat-1 { bottom: 60px; left: 10px; } /* Bottom Left */
.seat-2 { top: 60px; left: 10px; } /* Top Left */
.seat-3 { top: -20px; left: 50%; transform: translateX(-50%); } /* Top Center */
.seat-4 { top: 60px; right: 10px; } /* Top Right */
.seat-5 { bottom: 60px; right: 10px; } /* Bottom Right */

/* SEAT BOX */
.seat-card {
    position: relative;
    background: var(--glass-bg);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 8px 12px;
    width: 155px;
    display: flex;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    transition: all 0.3s;
}

.seat.active-turn .seat-card {
    border-color: var(--gold);
    box-shadow: 0 0 20px var(--gold-glow), 0 8px 24px rgba(0, 0, 0, 0.8);
    transform: scale(1.04);
}

.seat.folded .seat-card {
    opacity: 0.45;
    filter: grayscale(0.8);
}

.seat-avatar-wrap {
    position: relative;
    width: 48px;
    height: 48px;
    margin-bottom: 4px;
}

.seat-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    overflow: hidden;
}

.dealer-button {
    position: absolute;
    bottom: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    color: #111;
    font-weight: 900;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #111;
    box-shadow: 0 2px 6px rgba(0,0,0,0.5);
}

/* TURN TIMER RING */
.turn-timer-ring {
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 3px solid transparent;
    pointer-events: none;
}

.seat.active-turn .turn-timer-ring {
    border-color: var(--gold);
    animation: timerPulse 1s infinite alternate;
}

@keyframes timerPulse {
    0% { box-shadow: 0 0 6px var(--gold); }
    100% { box-shadow: 0 0 16px var(--gold); }
}

.seat-name {
    font-size: 13px;
    font-weight: 700;
    max-width: 135px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-align: center;
}

.seat-chips {
    font-size: 12px;
    font-weight: 700;
    color: var(--gold);
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 1px;
}

.seat-status-tag {
    position: absolute;
    top: -10px;
    right: 8px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    padding: 2px 8px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.seat-status-tag.seen {
    background: #0984e3;
    border-color: #74b9ff;
    color: #fff;
}

.seat-status-tag.blind {
    background: #6c5ce7;
    border-color: #a29bfe;
    color: #fff;
}

.seat-status-tag.winner {
    background: var(--gold);
    color: #111;
    border-color: #fff;
    box-shadow: 0 0 10px var(--gold);
}

/* PLAYER CARDS */
.seat-cards {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 6px;
    height: 60px;
    position: relative;
    width: 110px;
}

.card {
    position: absolute;
    width: 44px;
    height: 62px;
    border-radius: 6px;
    background: #fff;
    color: #111;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 4px;
    font-weight: 800;
    transition: transform 0.25s ease, filter 0.25s ease;
}

.card:nth-child(1) { left: 0; transform: rotate(-8deg); }
.card:nth-child(2) { left: 30px; transform: translateY(-4px); z-index: 2; }
.card:nth-child(3) { left: 60px; transform: rotate(8deg); z-index: 3; }

.seat-0 .card:hover {
    transform: translateY(-10px) scale(1.08) !important;
    z-index: 10;
}

.card.card-back {
    background: linear-gradient(135deg, #b71540 0%, #eb2f06 50%, #7d0a27 100%);
    border: 2px solid #fff;
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-back-pattern {
    width: 85%;
    height: 85%;
    border: 1px dashed rgba(255, 255, 255, 0.4);
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
}

.card.red { color: #d63031; }
.card.black { color: #2d3436; }

.card-top {
    font-size: 12px;
    line-height: 1;
}

.card-suit {
    font-size: 11px;
}

.card-center-symbol {
    align-self: center;
    font-size: 18px;
    line-height: 1;
}

.card-bottom {
    font-size: 12px;
    align-self: flex-end;
    line-height: 1;
    transform: rotate(180deg);
}

/* BET CHIP IN FRONT OF SEAT */
.seat-bet-chip {
    position: absolute;
    background: linear-gradient(135deg, #e67e22 0%, #d35400 100%);
    border: 2px dashed #fff;
    border-radius: 20px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 800;
    color: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    white-space: nowrap;
    z-index: 25;
}

.seat-0 .seat-bet-chip { top: -28px; }
.seat-1 .seat-bet-chip { right: -30px; top: 15px; }
.seat-2 .seat-bet-chip { right: -30px; bottom: 15px; }
.seat-3 .seat-bet-chip { bottom: -28px; }
.seat-4 .seat-bet-chip { left: -30px; bottom: 15px; }
.seat-5 .seat-bet-chip { left: -30px; top: 15px; }

/* EMPTY SEAT BUTTON */
.btn-sit-here {
    background: rgba(255, 255, 255, 0.06);
    border: 2px dashed rgba(255, 255, 255, 0.25);
    border-radius: 16px;
    padding: 16px;
    width: 130px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-sit-here:hover {
    background: rgba(249, 202, 36, 0.15);
    border-color: var(--gold);
    color: var(--gold);
    transform: scale(1.05);
}

/* EMPTY SEAT PLACEHOLDER (WHEN MATCH IS PLAYING) */
.empty-seat-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 130px;
    height: 80px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px dashed rgba(255, 255, 255, 0.12);
    border-radius: 16px;
    color: rgba(255, 255, 255, 0.35);
    pointer-events: none;
    user-select: none;
    gap: 4px;
}

/* ACTION CONTROLS PANEL AT BOTTOM */
.action-panel {
    width: 100%;
    max-width: 900px;
    background: rgba(12, 17, 26, 0.95);
    border: 1px solid rgba(249, 202, 36, 0.25);
    border-radius: 20px;
    padding: 14px 24px;
    margin-top: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    backdrop-filter: blur(12px);
    z-index: 50;
}

.action-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.action-center {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    flex: 1;
    max-width: 380px;
}

.action-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-action {
    padding: 12px 22px;
    border-radius: 14px;
    font-weight: 800;
    font-size: 14px;
    letter-spacing: 0.5px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    transition: all 0.2s ease;
    text-transform: uppercase;
}

.btn-action:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.btn-pack {
    background: linear-gradient(135deg, #c0392b 0%, #962d22 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(192, 57, 43, 0.4);
}

.btn-pack:hover:not(:disabled) {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    box-shadow: 0 6px 20px rgba(231, 76, 60, 0.6);
    transform: translateY(-2px);
}

.btn-see {
    background: linear-gradient(135deg, #2980b9 0%, #1f618d 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(41, 128, 185, 0.4);
}

.btn-see:hover:not(:disabled) {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.6);
    transform: translateY(-2px);
}

.btn-chaal {
    background: linear-gradient(135deg, #27ae60 0%, #1e8449 100%);
    color: #fff;
    box-shadow: 0 4px 20px rgba(39, 174, 96, 0.4);
    min-width: 140px;
}

.btn-chaal:hover:not(:disabled) {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
    box-shadow: 0 6px 25px rgba(46, 204, 113, 0.7);
    transform: translateY(-2px);
}

.btn-sideshow {
    background: linear-gradient(135deg, #8e44ad 0%, #6c3483 100%);
    color: #fff;
    box-shadow: 0 4px 15px rgba(142, 68, 173, 0.4);
}

.btn-sideshow:hover:not(:disabled) {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
    box-shadow: 0 6px 20px rgba(155, 89, 182, 0.6);
    transform: translateY(-2px);
}

.btn-show {
    background: linear-gradient(135deg, #f39c12 0%, #d68910 100%);
    color: #111;
    box-shadow: 0 4px 20px rgba(243, 156, 18, 0.4);
}

.btn-show:hover:not(:disabled) {
    background: linear-gradient(135deg, #f1c40f 0%, #f39c12 100%);
    box-shadow: 0 6px 25px rgba(241, 196, 15, 0.7);
    transform: translateY(-2px);
}

.btn-next-turn {
    background: linear-gradient(135deg, #00b894 0%, #00cec9 100%);
    color: #111;
    font-weight: 800;
    box-shadow: 0 4px 20px rgba(0, 206, 201, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.4);
    animation: bounceIndicator 1.5s infinite alternate;
}

.btn-next-turn:hover:not(:disabled) {
    background: linear-gradient(135deg, #55efc4 0%, #00b894 100%);
    box-shadow: 0 6px 25px rgba(85, 239, 196, 0.8);
    transform: translateY(-2px);
}

/* ADD POINTS QUICK BUTTONS */
.add-pts-quick {
    background: rgba(249, 202, 36, 0.12);
    border: 1.5px solid rgba(249, 202, 36, 0.45);
    color: var(--gold);
    border-radius: 12px;
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
}

.add-pts-quick:hover,
.add-pts-quick.selected {
    background: var(--gold);
    color: #111;
    border-color: var(--gold);
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(249, 202, 36, 0.5);
}

/* LOBBY ADD CHIPS BUTTON */
.btn-quick-add-sm {
    background: linear-gradient(135deg, #27ae60, #1e8449);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 4px 12px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-quick-add-sm:hover {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(46, 204, 113, 0.5);
}

/* OUT OF POINTS IN-GAME BANNER */
.out-of-points-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.95), rgba(192, 57, 43, 0.95));
    border: 1px solid rgba(255, 118, 117, 0.8);
    box-shadow: 0 4px 20px rgba(231, 76, 60, 0.4);
    border-radius: 12px;
    padding: 10px 18px;
    margin-bottom: 12px;
    color: #fff;
    animation: bannerPulse 2s infinite ease-in-out;
}

@keyframes bannerPulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(231, 76, 60, 0.4); }
    50% { box-shadow: 0 4px 28px rgba(231, 76, 60, 0.85); }
}

.oop-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.oop-icon {
    font-size: 24px;
    animation: oopShake 1.5s infinite ease-in-out;
}

@keyframes oopShake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-8deg); }
    75% { transform: rotate(8deg); }
}

.oop-title {
    font-weight: 800;
    font-size: 14px;
    letter-spacing: 0.5px;
}

.oop-sub {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 2px;
}

.btn-oop-add {
    background: #fff;
    color: #c0392b;
    border: none;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.btn-oop-add:hover {
    background: var(--gold);
    color: #111;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(249, 202, 36, 0.6);
}

/* NO POINTS STATUS TAG ON SEAT */
.seat-status-tag.no-points {
    background: #c0392b !important;
    border-color: #ff7675 !important;
    color: #fff !important;
    font-weight: 900 !important;
}

/* SEAT REFILL BUTTON */
.seat-refill-btn {
    margin-top: 5px;
    background: linear-gradient(135deg, #27ae60, #1e8449);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 12px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s;
    font-family: inherit;
    box-shadow: 0 2px 6px rgba(0,0,0,0.4);
    display: inline-block;
}

.seat-refill-btn:hover {
    background: linear-gradient(135deg, #2ecc71, #27ae60);
    transform: scale(1.06);
    box-shadow: 0 3px 10px rgba(46, 204, 113, 0.6);
}

.seat-refill-btn.seat-refill-friend {
    background: linear-gradient(135deg, #e67e22, #d35400);
}

.seat-refill-btn.seat-refill-friend:hover {
    background: linear-gradient(135deg, #f39c12, #e67e22);
}

/* BET SLIDER & QUICK MULTIPLIERS */
.bet-controls-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.bet-quick-btn {
    flex: 1;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.bet-quick-btn:hover {
    background: var(--gold);
    color: #111;
    border-color: var(--gold);
}

.bet-quick-btn.active {
    background: var(--gold);
    color: #111;
    border-color: var(--gold);
}

/* MODALS */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.75);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: #141b24;
    border: 2px solid var(--gold);
    border-radius: 20px;
    padding: 24px;
    max-width: 520px;
    width: 90%;
    box-shadow: 0 15px 50px rgba(0,0,0,0.8), 0 0 25px var(--gold-glow);
    position: relative;
    max-height: 85vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.modal-title {
    font-family: 'Cinzel', serif;
    font-size: 22px;
    color: var(--gold);
    font-weight: 800;
}

.modal-close {
    background: none;
    border: none;
    color: #aaa;
    font-size: 24px;
    cursor: pointer;
}

.modal-close:hover {
    color: #fff;
}

/* WINNER OVERLAY POPUP - DRAGGABLE & MOVABLE */
.winner-banner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    background: linear-gradient(135deg, rgba(20, 24, 33, 0.96) 0%, rgba(10, 12, 16, 0.98) 100%);
    border: 3px solid var(--gold);
    border-radius: 20px;
    padding: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    box-shadow: 0 20px 60px rgba(0,0,0,0.9), 0 0 35px var(--gold-glow);
    z-index: 500;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    user-select: none;
    max-width: 440px;
    width: 90%;
    touch-action: none;
}

.winner-banner.show {
    display: flex !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

.winner-banner.is-dragging {
    transition: none !important;
    cursor: grabbing !important;
    box-shadow: 0 25px 70px rgba(0,0,0,0.95), 0 0 50px rgba(249, 202, 36, 0.6);
}

/* Drag bar header */
.winner-drag-bar {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 9px 16px;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid rgba(249, 202, 36, 0.25);
    border-top-left-radius: 17px;
    border-top-right-radius: 17px;
    cursor: grab;
    touch-action: none;
}

.winner-drag-bar:active {
    cursor: grabbing;
}

.winner-drag-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.7);
    letter-spacing: 0.3px;
}

.winner-drag-indicator span {
    color: var(--gold);
    font-size: 13px;
}

.btn-winner-minimize {
    background: rgba(249, 202, 36, 0.15);
    border: 1px solid rgba(249, 202, 36, 0.4);
    color: var(--gold);
    border-radius: 12px;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: all 0.2s ease;
}

.btn-winner-minimize:hover {
    background: rgba(249, 202, 36, 0.3);
    color: #fff;
    transform: scale(1.04);
}

/* Content inside banner */
.winner-banner-content {
    padding: 16px 28px 22px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
    transition: all 0.25s ease;
}

/* Peek / Semi-transparent mode so cards behind it are crystal clear */
.winner-banner.peek-mode {
    opacity: 0.2 !important;
    transform: scale(0.9);
}

.winner-banner.peek-mode:hover {
    opacity: 0.85 !important;
}

.winner-trophy {
    font-size: 48px;
    filter: drop-shadow(0 0 15px rgba(249, 202, 36, 0.8));
    animation: bounce 1s infinite alternate;
}

@keyframes bounce {
    0% { transform: translateY(0); }
    100% { transform: translateY(-8px); }
}

.winner-title {
    font-family: 'Cinzel', serif;
    font-size: 24px;
    font-weight: 900;
    color: var(--gold);
    text-align: center;
}

.winner-desc {
    font-size: 14px;
    color: #eee;
    text-align: center;
}

/* HAND RULES TABLE */
.rules-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.rule-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.rule-name {
    font-weight: 700;
    font-size: 14px;
    color: var(--gold);
}

.rule-cards-demo {
    display: flex;
    gap: 4px;
}

.mini-card {
    background: #fff;
    color: #111;
    font-size: 11px;
    font-weight: 800;
    padding: 2px 6px;
    border-radius: 4px;
}

.mini-card.red { color: #d63031; }

/* CHAT DRAWER */
.chat-drawer {
    position: fixed;
    right: 20px;
    bottom: 0px;
    width: 290px;
    height: 250px;
    background: rgba(12, 16, 23, 0.96);
    border: 1px solid rgba(249, 202, 36, 0.3);
    border-bottom: none;
    border-radius: 16px 16px 0 0;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -5px 30px rgba(0,0,0,0.85);
    z-index: 100;
    transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.chat-drawer.collapsed {
    transform: translateY(calc(100% - 32px));
}

/* VOICE DRAWER (BOTTOM LEFT - LIKE LIVE CHAT) */
.voice-drawer {
    position: fixed;
    left: 20px;
    bottom: 0px;
    width: 320px;
    max-height: 420px;
    background: rgba(12, 16, 23, 0.96);
    border: 1px solid rgba(46, 204, 113, 0.4);
    border-bottom: none;
    border-radius: 16px 16px 0 0;
    display: flex;
    flex-direction: column;
    box-shadow: 0 -5px 30px rgba(0,0,0,0.85);
    z-index: 100;
    transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.voice-drawer.collapsed {
    transform: translateY(calc(100% - 32px));
}

.voice-drawer-header {
    height: 32px;
    padding: 0 14px;
    border-bottom: 1px solid rgba(46, 204, 113, 0.25);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    background: rgba(46, 204, 113, 0.12);
    color: #2ecc71;
    border-radius: 16px 16px 0 0;
    user-select: none;
    -webkit-user-select: none;
    transition: background 0.2s;
}

.voice-drawer-header:hover {
    background: rgba(46, 204, 113, 0.22);
}

.voice-drawer-body {
    padding: 10px 14px 14px;
    overflow-y: auto;
    max-height: 380px;
    display: flex;
    flex-direction: column;
}

.chat-header {
    height: 32px;
    padding: 0 14px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    background: rgba(255,255,255,0.06);
    border-radius: 16px 16px 0 0;
    color: var(--gold);
    user-select: none;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 12px;
}

.chat-msg {
    line-height: 1.3;
}

.chat-sender {
    font-weight: 700;
    color: var(--gold);
}

.chat-input-row {
    display: flex;
    padding: 6px 8px;
    gap: 6px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.chat-input {
    flex: 1;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 8px;
    padding: 6px 10px;
    color: #fff;
    font-size: 12px;
    outline: none;
}

.chat-input:focus {
    border-color: var(--gold);
}

/* RESPONSIVE DESIGN */
@media (max-width: 900px) {
    .poker-table-wrapper {
        height: 480px;
    }
    .seat {
        width: 140px;
        height: 120px;
    }
    .seat-card {
        width: 130px;
        padding: 6px 8px;
    }
    .action-panel {
        flex-direction: column;
        gap: 10px;
        padding: 10px 14px;
    }
    .action-left, .action-right {
        width: 100%;
        justify-content: center;
    }
}

/* USER PLAYER IDENTIFICATION */
.seat.is-user-seat .seat-card {
    border: 2px solid var(--gold) !important;
    background: linear-gradient(135deg, rgba(28, 38, 56, 0.95) 0%, rgba(18, 24, 38, 0.95) 100%) !important;
    box-shadow: 0 0 25px rgba(249, 202, 36, 0.45), 0 8px 30px rgba(0, 0, 0, 0.8) !important;
}

.seat-user-indicator {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: #111;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 1px;
    padding: 2px 10px;
    border-radius: 12px;
    border: 1px solid #fff;
    box-shadow: 0 2px 10px rgba(243, 156, 18, 0.7);
    white-space: nowrap;
    z-index: 30;
    animation: bounceIndicator 1.5s infinite alternate;
}

@keyframes bounceIndicator {
    0% { transform: translateX(-50%) translateY(0); }
    100% { transform: translateX(-50%) translateY(-3px); }
}

.your-turn-banner {
    position: absolute;
    top: 5px;
    background: linear-gradient(135deg, #f9ca24 0%, #f0932b 100%);
    color: #111;
    font-weight: 900;
    font-size: 14px;
    letter-spacing: 1px;
    padding: 6px 22px;
    border-radius: 30px;
    box-shadow: 0 0 25px rgba(249, 202, 36, 0.9), 0 4px 15px rgba(0,0,0,0.6);
    z-index: 100;
    animation: pulseTurn 0.8s infinite alternate;
    border: 2px solid #fff;
}

.your-turn-banner.is-bot-turn {
    background: linear-gradient(135deg, #0984e3 0%, #00cec9 100%);
    color: #fff;
    box-shadow: 0 0 25px rgba(0, 206, 201, 0.8), 0 4px 15px rgba(0,0,0,0.6);
    cursor: pointer;
    border: 2px solid rgba(255, 255, 255, 0.8);
}

@keyframes pulseTurn {
    0% { transform: scale(1); filter: drop-shadow(0 0 5px #f9ca24); }
    100% { transform: scale(1.06); filter: drop-shadow(0 0 15px #f9ca24); }
}

/* NAVBAR USER BADGE & ROOM BADGE */
.room-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    background: rgba(249, 202, 36, 0.1);
    border: 1px solid rgba(249, 202, 36, 0.3);
    color: var(--gold);
}

.user-profile-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 14px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(249, 202, 36, 0.4);
    cursor: pointer;
    transition: all 0.2s;
}

.user-profile-badge:hover {
    background: rgba(249, 202, 36, 0.2);
    border-color: var(--gold);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px var(--gold-glow);
}

.user-profile-avatar {
    font-size: 18px;
    line-height: 1;
}

.user-profile-name {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    max-width: 100px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.btn-invite-nav {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%) !important;
    border-color: #be2edd !important;
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(155, 89, 182, 0.4);
}

.btn-invite-nav:hover {
    background: linear-gradient(135deg, #be2edd 0%, #9b59b6 100%) !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(190, 46, 221, 0.6);
}

/* AVATAR GRID */
.avatar-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin: 14px 0;
}

.avatar-choice {
    font-size: 28px;
    padding: 10px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.06);
    border: 2px solid transparent;
    cursor: pointer;
    text-align: center;
    transition: all 0.2s;
}

.avatar-choice:hover {
    background: rgba(249, 202, 36, 0.15);
    border-color: rgba(249, 202, 36, 0.5);
    transform: scale(1.1);
}

.avatar-choice.selected {
    background: rgba(249, 202, 36, 0.25);
    border-color: var(--gold);
    box-shadow: 0 0 15px var(--gold-glow);
    transform: scale(1.1);
}

/* FORM CONTROLS */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
    text-align: left;
}

.form-label {
    font-size: 12px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-input {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 10px 14px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

.form-input:focus {
    border-color: var(--gold);
    box-shadow: 0 0 10px var(--gold-glow);
}

/* INVITE BOX */
.invite-link-row {
    display: flex;
    gap: 8px;
    margin: 12px 0 16px 0;
}

.invite-input {
    flex: 1;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 8px 12px;
    color: var(--gold);
    font-size: 13px;
    font-family: monospace;
    outline: none;
}

.kick-bot-btn {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(231, 76, 60, 0.25);
    border: 1px solid rgba(231, 76, 60, 0.6);
    color: #e74c3c;
    font-size: 11px;
    font-weight: 900;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 25;
}

.kick-bot-btn:hover {
    background: #e74c3c;
    color: #fff;
    transform: scale(1.15);
}

/* ─────────────────────────────────────
   LOBBY SCREEN
   ───────────────────────────────────── */

.lobby-screen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(ellipse at 30% 40%, #0d2137 0%, #080c12 60%, #030508 100%);
    z-index: 9999;
    padding: 16px;
}

.lobby-card {
    background: rgba(12, 20, 35, 0.95);
    border: 1px solid rgba(249, 202, 36, 0.35);
    border-radius: 24px;
    padding: 40px 36px;
    max-width: 480px;
    width: 100%;
    box-shadow: 0 0 60px rgba(249, 202, 36, 0.12), 0 30px 80px rgba(0,0,0,0.7);
    text-align: center;
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to   { opacity: 1; transform: translateY(0); }
}

.lobby-logo {
    font-size: 64px;
    margin-bottom: 8px;
    filter: drop-shadow(0 0 20px rgba(249,202,36,0.7));
    animation: pulseGlow 2s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
    from { filter: drop-shadow(0 0 12px rgba(249,202,36,0.5)); }
    to   { filter: drop-shadow(0 0 28px rgba(249,202,36,0.9)); }
}

.lobby-title {
    font-family: 'Cinzel', serif;
    font-size: 28px;
    font-weight: 900;
    letter-spacing: 2px;
    background: linear-gradient(135deg, #fff 0%, #f9ca24 50%, #d48b12 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 6px;
}

.lobby-subtitle {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 28px;
    letter-spacing: 0.5px;
}

.lobby-form {
    text-align: left;
}

.lobby-bots-row {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-white);
    margin-bottom: 20px;
    padding: 12px 16px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    border-radius: 12px;
}

/* Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
    flex-shrink: 0;
}
.toggle-switch input { opacity: 0; width: 0; height: 0; }
.toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #374151;
    border-radius: 24px;
    transition: 0.3s;
}
.toggle-slider:before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: 0.3s;
}
.toggle-switch input:checked + .toggle-slider { background: #10ac84; }
.toggle-switch input:checked + .toggle-slider:before { transform: translateX(20px); }

.btn-join-lobby {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 800;
    font-family: 'Cinzel', serif;
    letter-spacing: 1px;
    color: #111;
    background: linear-gradient(135deg, #f9ca24 0%, #d4a017 100%);
    border: none;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.25s;
    box-shadow: 0 4px 20px rgba(249,202,36,0.4);
    margin-bottom: 16px;
}
.btn-join-lobby:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(249,202,36,0.6);
}
.btn-join-lobby:active { transform: translateY(0); }

.lobby-invite-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--gold);
    background: rgba(249,202,36,0.08);
    border: 1px dashed rgba(249,202,36,0.3);
    border-radius: 10px;
    padding: 10px 14px;
    word-break: break-all;
}

.btn-small-copy {
    flex-shrink: 0;
    background: rgba(249,202,36,0.2);
    border: 1px solid rgba(249,202,36,0.5);
    border-radius: 6px;
    color: var(--gold);
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    cursor: pointer;
    transition: all 0.2s;
}
.btn-small-copy:hover { background: rgba(249,202,36,0.35); }

/* Input error animation */
@keyframes shakeInput {
    0%,100% { transform: translateX(0); }
    20%,60%  { transform: translateX(-8px); }
    40%,80%  { transform: translateX(8px); }
}
.input-error {
    animation: shakeInput 0.4s ease;
    border-color: #e74c3c !important;
    box-shadow: 0 0 0 3px rgba(231,76,60,0.3) !important;
}

/* Game screen should fill viewport */
#game-screen {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* ========================================================= */
/* LOGIN & LOBBY SCREENS                                     */
/* ========================================================= */
.lobby-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    background: radial-gradient(circle at center, #134633 0%, #082117 60%, #030d09 100%);
    padding: 20px;
    z-index: 999;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.lobby-screen::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: 
        radial-gradient(rgba(249, 202, 36, 0.08) 1px, transparent 1px),
        radial-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px);
    background-size: 30px 30px;
    background-position: 0 0, 15px 15px;
    pointer-events: none;
}

.lobby-card {
    position: relative;
    max-width: 480px;
    width: 100%;
    background: rgba(12, 28, 22, 0.94);
    border: 1px solid rgba(249, 202, 36, 0.35);
    border-radius: 24px;
    box-shadow: 
        0 25px 70px rgba(0, 0, 0, 0.75),
        0 0 35px rgba(249, 202, 36, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 34px 28px;
    text-align: center;
    color: #fff;
    animation: fadeInLobby 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 10;
}

@keyframes fadeInLobby {
    from {
        opacity: 0;
        transform: translateY(18px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.lobby-logo {
    font-size: 58px;
    line-height: 1;
    color: var(--gold);
    filter: drop-shadow(0 0 20px rgba(249, 202, 36, 0.65));
    margin-bottom: 8px;
    animation: pulseLogo 3s infinite alternate ease-in-out;
}

@keyframes pulseLogo {
    0%   { transform: scale(1); filter: drop-shadow(0 0 15px rgba(249,202,36,0.5)); }
    100% { transform: scale(1.06); filter: drop-shadow(0 0 28px rgba(249,202,36,0.85)); }
}

.lobby-title {
    font-size: 26px;
    font-weight: 900;
    letter-spacing: 3px;
    color: var(--gold);
    text-transform: uppercase;
    text-shadow: 0 2px 12px rgba(0,0,0,0.8);
    margin: 0;
}

.lobby-subtitle {
    font-size: 13px;
    color: #9cb3a5;
    margin: 6px 0 24px;
    letter-spacing: 0.5px;
}

.login-section {
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
}

.google-btn-wrap {
    min-height: 44px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

/* Login Tabs */
.login-tabs {
    display: flex;
    gap: 8px;
    background: rgba(0, 0, 0, 0.4);
    padding: 4px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.login-tab {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    background: transparent;
    border: none;
    border-radius: 9px;
    color: #9cb3a5;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.login-tab:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.05);
}

.login-tab.active {
    background: rgba(249, 202, 36, 0.18);
    color: var(--gold);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(249, 202, 36, 0.4);
}

/* Input with icon */
.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 12px;
    font-size: 15px;
    pointer-events: none;
    opacity: 0.8;
}

.input-with-icon .form-input {
    padding-left: 38px;
    width: 100%;
}

/* Google / Gmail Login Button */
.btn-google-login {
    background: #ffffff;
    border: none;
    color: #1f2937;
    font-size: 15px;
    font-weight: 800;
    padding: 12px 20px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    transition: all 0.2s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.35);
    width: 100%;
    margin-top: 4px;
}

.btn-google-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 255, 255, 0.25);
    background: #f9fafb;
}

.btn-google-login:active {
    transform: translateY(0);
}

/* OAuth Help Box */
.oauth-help-box {
    margin-top: 14px;
    border-top: 1px dashed rgba(255, 255, 255, 0.12);
    padding-top: 10px;
}

.oauth-help-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 11px;
    font-weight: 700;
    color: #9cb3a5;
    cursor: pointer;
    user-select: none;
    padding: 4px 0;
    transition: color 0.2s;
}

.oauth-help-toggle:hover {
    color: var(--gold);
}

.oauth-help-content {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(249, 202, 36, 0.25);
    border-radius: 10px;
    padding: 12px 14px;
    margin-top: 8px;
    font-size: 11px;
    line-height: 1.6;
    color: #cbd5e1;
    text-align: left;
}

.oauth-help-content ol {
    margin: 6px 0;
    padding-left: 18px;
}

.oauth-help-content li {
    margin-bottom: 3px;
}

.oauth-help-content code {
    background: rgba(255, 255, 255, 0.1);
    color: var(--gold);
    padding: 1px 5px;
    border-radius: 4px;
    font-family: monospace;
}

.btn-guest-login {
    background: linear-gradient(135deg, #27ae60, #1e8449);
    border: none;
    color: #ffffff;
    font-size: 15px;
    font-weight: 800;
    padding: 13px 20px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.2s ease;
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.35);
    width: 100%;
}

.btn-guest-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(39, 174, 96, 0.5);
    filter: brightness(1.08);
}

.btn-guest-login:active {
    transform: translateY(0);
}

.login-status {
    font-size: 13px;
    font-weight: 700;
    min-height: 22px;
    text-align: center;
    margin-top: 14px;
}

/* Lobby User Header Row */
.lobby-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
    margin-bottom: 20px;
}

.lobby-user-info {
    display: flex;
    align-items: center;
    gap: 14px;
    text-align: left;
}

.lobby-user-photo {
    width: 58px;
    height: 58px;
    border-radius: 50%;
    border: 2px solid var(--gold);
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 15px rgba(249, 202, 36, 0.35);
    font-size: 28px;
    flex-shrink: 0;
}

.lobby-user-name {
    font-size: 18px;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.2;
}

.lobby-user-email {
    font-size: 12px;
    color: #9cb3a5;
    margin-top: 2px;
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.lobby-user-chips {
    font-size: 14px;
    font-weight: 800;
    color: var(--gold);
    margin-top: 4px;
}

.btn-logout {
    background: rgba(231, 76, 60, 0.15);
    border: 1px solid rgba(231, 76, 60, 0.45);
    color: #e74c3c;
    padding: 7px 14px;
    border-radius: 9px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-logout:hover {
    background: rgba(231, 76, 60, 0.3);
    border-color: rgba(231, 76, 60, 0.7);
    color: #ff6b6b;
}

/* Lobby Form */
.lobby-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    text-align: left;
}

.photo-upload-row {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.03);
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.07);
}

.photo-preview {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    border: 2px dashed rgba(249, 202, 36, 0.6);
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
    font-size: 24px;
}

.file-input-hidden {
    display: none;
}

.btn-upload-photo {
    background: rgba(249, 202, 36, 0.15);
    border: 1px solid rgba(249, 202, 36, 0.5);
    color: var(--gold);
    padding: 9px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-upload-photo:hover {
    background: rgba(249, 202, 36, 0.28);
    border-color: var(--gold);
}

.photo-hint {
    font-size: 11px;
    color: #9cb3a5;
    margin-top: 5px;
}

.lobby-bots-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: rgba(255, 255, 255, 0.04);
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-size: 13px;
    font-weight: 600;
    color: #e2e8f0;
}

.btn-join-lobby {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    border: none;
    color: #111111;
    font-size: 17px;
    font-weight: 900;
    padding: 14px 24px;
    border-radius: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 6px 22px rgba(243, 156, 18, 0.45);
    transition: all 0.2s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 6px;
    width: 100%;
}

.btn-join-lobby:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(243, 156, 18, 0.6);
    filter: brightness(1.08);
}

.btn-join-lobby:active {
    transform: translateY(0);
}

/* Quit Button in Nav */
.btn-quit-nav {
    background: rgba(231, 76, 60, 0.16) !important;
    border: 1px solid rgba(231, 76, 60, 0.5) !important;
    color: #e74c3c !important;
    font-weight: 700;
    transition: all 0.2s ease;
}

.btn-quit-nav:hover {
    background: rgba(231, 76, 60, 0.32) !important;
    border-color: rgba(231, 76, 60, 0.8) !important;
    color: #ff6b6b !important;
}

/* Responsive tweaks for mobile */
@media (max-width: 600px) {
    .lobby-card {
        padding: 24px 18px;
        border-radius: 18px;
    }
    .lobby-logo {
        font-size: 46px;
    }
    .lobby-title {
        font-size: 22px;
    }
}

/* ========================================================= */
/* DASHBOARD LAYOUT & LIVE ONLINE PLAYERS PANEL              */
/* ========================================================= */

.dashboard-container {
    display: flex;
    gap: 28px;
    max-width: 1040px;
    width: 100%;
    margin: 0 auto;
    justify-content: center;
    align-items: flex-start;
    z-index: 10;
}

@media (max-width: 900px) {
    .dashboard-container {
        flex-direction: column;
        align-items: center;
        max-width: 500px;
        gap: 20px;
    }
}

.dashboard-container .lobby-card {
    flex: 1;
    max-width: 490px;
    margin: 0;
}

.online-players-card {
    flex: 1;
    max-width: 500px;
    width: 100%;
    background: rgba(12, 28, 22, 0.94);
    border: 1px solid rgba(249, 202, 36, 0.35);
    border-radius: 24px;
    box-shadow: 
        0 25px 70px rgba(0, 0, 0, 0.75),
        0 0 35px rgba(249, 202, 36, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 26px 24px;
    display: flex;
    flex-direction: column;
    min-height: 480px;
    position: relative;
    animation: fadeInLobby 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.online-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    margin-bottom: 14px;
}

.online-title-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.online-card-title {
    font-family: 'Cinzel', serif;
    font-size: 19px;
    font-weight: 800;
    letter-spacing: 1px;
    color: var(--gold);
}

.online-badge-count {
    font-size: 11px;
    font-weight: 800;
    padding: 2px 8px;
    background: rgba(46, 204, 113, 0.15);
    border: 1px solid #2ecc71;
    color: #2ecc71;
    border-radius: 20px;
    letter-spacing: 0.5px;
}

.live-pulse-dot {
    width: 9px;
    height: 9px;
    background-color: #2ecc71;
    border-radius: 50%;
    display: inline-block;
    position: relative;
    box-shadow: 0 0 8px #2ecc71;
    flex-shrink: 0;
}

.live-pulse-dot::after {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    border: 1.5px solid #2ecc71;
    animation: pulseRing 1.8s infinite cubic-bezier(0.215, 0.61, 0.355, 1);
}

@keyframes pulseRing {
    0% { transform: scale(0.8); opacity: 1; }
    100% { transform: scale(2.4); opacity: 0; }
}

.btn-refresh-online {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.14);
    color: #cbd5e1;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-refresh-online:hover {
    background: rgba(249, 202, 36, 0.18);
    border-color: var(--gold);
    color: var(--gold);
    transform: translateY(-1px);
}

.online-filter-bar {
    position: relative;
    display: flex;
    align-items: center;
    margin-bottom: 14px;
}

.online-filter-bar .search-icon {
    position: absolute;
    left: 12px;
    font-size: 14px;
    color: #888;
    pointer-events: none;
}

.online-search-box {
    width: 100%;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    padding: 8px 12px 8px 36px;
    font-size: 13px;
    color: #fff;
    outline: none;
    transition: all 0.2s;
}

.online-search-box:focus {
    border-color: var(--gold);
    box-shadow: 0 0 10px rgba(249, 202, 36, 0.2);
}

/* Online List Container */
.online-list-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
    max-height: 420px;
    padding-right: 4px;
}

.online-list-container::-webkit-scrollbar {
    width: 5px;
}
.online-list-container::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}
.online-list-container::-webkit-scrollbar-thumb {
    background: rgba(249, 202, 36, 0.3);
    border-radius: 4px;
}

/* Online Player Item */
.online-player-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.07);
    border-radius: 14px;
    padding: 10px 14px;
    transition: all 0.2s ease;
}

.online-player-item:hover {
    background: rgba(249, 202, 36, 0.06);
    border-color: rgba(249, 202, 36, 0.3);
    transform: translateX(2px);
}

.online-player-item-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.online-item-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid var(--gold);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 10px rgba(249, 202, 36, 0.25);
    flex-shrink: 0;
    font-size: 20px;
    overflow: hidden;
}

.online-item-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.item-online-dot {
    position: absolute;
    bottom: 0px;
    right: 0px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #2ecc71;
    border: 2px solid #0d281a;
    box-shadow: 0 0 6px #2ecc71;
}

.item-online-dot.playing {
    background: #f1c40f;
    box-shadow: 0 0 6px #f1c40f;
}

.online-item-details {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.online-item-name-row {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.online-item-name {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 130px;
}

.online-item-status-tag {
    font-size: 10px;
    font-weight: 700;
    padding: 1px 6px;
    border-radius: 10px;
}

.tag-lobby {
    background: rgba(46, 204, 113, 0.15);
    color: #2ecc71;
    border: 1px solid rgba(46, 204, 113, 0.35);
}

.tag-game {
    background: rgba(243, 156, 18, 0.15);
    color: #f39c12;
    border: 1px solid rgba(243, 156, 18, 0.35);
}

.online-item-chips {
    font-size: 12px;
    font-weight: 700;
    color: var(--gold);
    margin-top: 2px;
}

/* Challenge Button */
.btn-challenge-player {
    background: linear-gradient(135deg, #e67e22, #d35400);
    border: 1px solid rgba(249, 202, 36, 0.4);
    color: #fff;
    padding: 7px 14px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(211, 84, 0, 0.35);
    transition: all 0.2s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.btn-challenge-player:hover {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(243, 156, 18, 0.55);
    border-color: var(--gold);
}

.btn-challenge-player:active {
    transform: translateY(0);
}

.btn-challenge-player.sent {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    color: #aaa;
    cursor: default;
    box-shadow: none;
}

/* Loading & Empty state */
.online-loading-spinner, .online-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 10px;
    color: #8fa397;
    font-size: 13px;
    gap: 10px;
    text-align: center;
}

.spinner-dot {
    width: 24px;
    height: 24px;
    border: 3px solid rgba(249, 202, 36, 0.2);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Outgoing challenge floating bar */
.outgoing-challenge-bar {
    margin-top: 14px;
    background: linear-gradient(135deg, rgba(230, 126, 34, 0.2), rgba(211, 84, 0, 0.25));
    border: 1px solid rgba(249, 202, 36, 0.45);
    border-radius: 12px;
    padding: 10px 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    animation: pulseGlow 2.5s infinite alternate;
}

.outgoing-challenge-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.challenge-pulse-icon {
    font-size: 18px;
    animation: pulseIcon 1.2s infinite alternate;
}

@keyframes pulseIcon {
    from { transform: scale(1); }
    to { transform: scale(1.25); }
}

.outgoing-challenge-text {
    font-size: 12px;
    font-weight: 800;
    color: var(--gold);
}

.outgoing-challenge-sub {
    font-size: 10px;
    color: #cbd5e1;
}

.btn-cancel-challenge {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #e74c3c;
    padding: 4px 10px;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-cancel-challenge:hover {
    background: rgba(231, 76, 60, 0.4);
    color: #ff6b6b;
}

/* ========================================================= */
/* INCOMING CHALLENGE MODAL (Royale Pop-up)                   */
/* ========================================================= */

.challenge-modal-card {
    max-width: 440px;
    text-align: center;
    background: linear-gradient(145deg, #12281e 0%, #081710 100%) !important;
    border: 2px solid var(--gold) !important;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.85),
        0 0 40px rgba(249, 202, 36, 0.4) !important;
    position: relative;
    overflow: hidden;
    padding: 30px 24px !important;
}

.challenge-ribbon {
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: #fff;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 2px;
    padding: 5px 0;
    margin: -30px -24px 20px -24px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.challenge-avatar-wrap {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    border: 3px solid var(--gold);
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 20px rgba(249, 202, 36, 0.5);
    overflow: hidden;
}

.challenge-avatar-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.challenge-title {
    font-size: 20px;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 6px;
}

.challenge-subtitle {
    font-size: 13px;
    color: #cbd5e1;
    margin-bottom: 18px;
    line-height: 1.4;
}

.challenge-room-info {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 22px;
}

.info-pill {
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(249, 202, 36, 0.25);
    border-radius: 10px;
    padding: 8px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
}

.pill-label {
    font-size: 10px;
    color: #9cb3a5;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.pill-value {
    font-size: 14px;
    font-weight: 800;
    color: var(--gold);
    margin-top: 2px;
}

.countdown-txt {
    color: #e74c3c !important;
    animation: pulseIcon 1s infinite alternate;
}

.challenge-actions {
    display: flex;
    gap: 12px;
}

.btn-challenge-decline {
    flex: 1;
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.5);
    color: #ff6b6b;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.2s;
}

.btn-challenge-decline:hover {
    background: rgba(231, 76, 60, 0.35);
    border-color: #e74c3c;
    color: #fff;
}

.btn-challenge-accept {
    flex: 1.4;
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    border: 1px solid #2ecc71;
    color: #fff;
    padding: 12px 16px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 900;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 4px 18px rgba(46, 204, 113, 0.45);
    transition: all 0.2s;
}

.btn-challenge-accept:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 24px rgba(46, 204, 113, 0.65);
    filter: brightness(1.1);
}

.btn-challenge-accept:active {
    transform: translateY(0);
}

/* Nav Online button highlight */
.btn-online-nav {
    border-color: rgba(46, 204, 113, 0.4) !important;
    color: #2ecc71 !important;
}

.btn-online-nav:hover {
    background: rgba(46, 204, 113, 0.15) !important;
    border-color: #2ecc71 !important;
    color: #2ecc71 !important;
}

/* ========================================================= */
/* COMPLETE MOBILE UI SYSTEM (SMARTPHONES <= 600px)          */
/* ========================================================= */
@media (max-width: 600px) {
    /* Anti-Flicker & Mobile GPU Stability Fix (Vivo, Oppo, Realme, Xiaomi) */
    *, *::before, *::after {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }

    .poker-table-wrapper, .poker-table, .seat, .table-center, .action-panel, .card {
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
        -webkit-backface-visibility: hidden;
        backface-visibility: hidden;
    }

    /* Disable heavy continuous GPU repaints on mobile */
    .pot-badge {
        animation: none !important;
    }
    .turn-timer-ring {
        animation: none !important;
    }

    /* Base Body & Containers */
    body {
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
    }

    #game-screen {
        min-height: 100vh;
        height: auto;
        overflow-x: hidden;
    }

    .game-container {
        padding: 0 4px;
        flex: 1;
        width: 100%;
        overflow-x: hidden;
    }

    /* 1. COMPACT MOBILE NAVBAR */
    .navbar {
        height: 48px;
        padding: 0 8px;
        gap: 6px;
    }

    .brand {
        gap: 6px;
    }

    .brand-logo {
        font-size: 20px;
    }

    .brand-title {
        display: none; /* Hide long TEEN PATTI CLUB on mobile */
    }

    .brand-badge {
        font-size: 9px;
        padding: 1px 5px;
    }

    .room-badge {
        font-size: 10px;
        padding: 2px 7px;
    }

    .nav-actions {
        display: flex;
        align-items: center;
        gap: 4px;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        flex-shrink: 1;
        max-width: 72vw;
    }

    .nav-actions::-webkit-scrollbar {
        display: none;
    }

    /* Hide standalone mode pill on mobile to free up space */
    .status-pill {
        display: none !important;
    }

    .user-profile-badge {
        padding: 2px 6px;
        max-width: 90px;
        font-size: 11px;
    }

    .user-profile-avatar {
        font-size: 14px;
    }

    .user-profile-name {
        max-width: 55px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        font-size: 11px;
    }

    #nav-chips-badge {
        padding: 2px 6px !important;
        font-size: 11px;
    }

    #nav-chips-display {
        font-size: 11px !important;
    }

    #btn-add-points {
        padding: 2px 6px !important;
        font-size: 10px !important;
    }

    .btn-nav {
        padding: 3px 8px;
        font-size: 11px;
        height: 28px;
        white-space: nowrap;
    }

    .btn-icon {
        width: 28px;
        height: 28px;
        font-size: 13px;
    }

    /* 2. POKER TABLE & WRAPPER FOR MOBILE PORTRAIT */
    .poker-table-wrapper {
        width: 100%;
        height: 380px;
        min-height: 340px;
        max-height: 52vh;
        margin: 4px auto 0;
        position: relative;
    }

    .poker-table {
        position: absolute;
        inset: 12px 6px;
        border: 7px solid var(--table-rim);
        border-radius: 110px;
        box-shadow: inset 0 0 35px rgba(0, 0, 0, 0.85), 0 0 0 2px var(--gold), 0 10px 25px rgba(0, 0, 0, 0.8);
        overflow: visible;
    }

    .table-logo-watermark {
        font-size: 13px;
        letter-spacing: 2px;
        opacity: 0.12;
    }

    /* 3. CENTER POT & DEAL CARDS BUTTON */
    .table-center {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        z-index: 10;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        margin: 0;
        width: max-content;
        pointer-events: auto;
    }

    .pot-badge {
        padding: 4px 14px;
        min-width: 110px;
        border-radius: 16px;
        border-width: 1.5px;
        gap: 6px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.7), 0 0 10px var(--gold-glow);
    }

    .pot-badge span {
        font-size: 15px !important;
    }

    .pot-label {
        font-size: 8px;
        letter-spacing: 0.5px;
    }

    .pot-amount {
        font-size: 13px;
        font-weight: 800;
    }

    .table-stakes-info {
        font-size: 8.5px;
        margin-top: 2px;
        color: rgba(255, 255, 255, 0.7);
    }

    #btn-deal-cards {
        padding: 5px 12px !important;
        font-size: 11px !important;
        margin-top: 4px !important;
        border-radius: 14px !important;
    }

    /* 4. SEATS POSITIONING & SIZING (6 SEATS AROUND MOBILE TABLE) */
    .seat {
        width: 96px;
        height: 90px;
    }

    /* Mobile coordinates */
    .seat-0 {
        bottom: 2px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 25;
        width: 108px;
    }

    .seat-3 {
        top: 2px;
        left: 50%;
        transform: translateX(-50%);
        z-index: 20;
    }

    .seat-1 {
        bottom: 27%;
        left: 4px;
        z-index: 20;
    }

    .seat-2 {
        top: 13%;
        left: 4px;
        z-index: 20;
    }

    .seat-4 {
        top: 13%;
        right: 4px;
        z-index: 20;
    }

    .seat-5 {
        bottom: 27%;
        right: 4px;
        z-index: 20;
    }

    /* Seat Card Boxes */
    .seat-card {
        width: 92px;
        padding: 3px 4px;
        border-radius: 10px;
    }

    .seat.is-user-seat .seat-card {
        width: 106px;
        padding: 4px 6px;
    }

    .seat-avatar-wrap {
        width: 30px;
        height: 30px;
        margin-bottom: 1px;
    }

    .seat-avatar {
        font-size: 15px;
    }

    .seat-name {
        font-size: 10px;
        max-width: 80px;
        line-height: 1.2;
    }

    .seat-chips {
        font-size: 9px;
    }

    .seat-user-indicator {
        font-size: 8px;
        padding: 1px 6px;
        top: -9px;
    }

    .seat-status-tag {
        font-size: 8px;
        padding: 1px 4px;
        top: -7px;
        right: 2px;
    }

    .seat-dealer-chip {
        width: 15px;
        height: 15px;
        font-size: 8px;
        top: -4px;
        left: -4px;
    }

    .seat-bet-chip {
        font-size: 8px;
        padding: 1px 5px;
        border-width: 1px;
    }

    .seat-0 .seat-bet-chip { top: -20px; }
    .seat-1 .seat-bet-chip { right: -12px; top: 12px; }
    .seat-2 .seat-bet-chip { right: -12px; bottom: 12px; }
    .seat-3 .seat-bet-chip { bottom: -20px; }
    .seat-4 .seat-bet-chip { left: -12px; bottom: 12px; }
    .seat-5 .seat-bet-chip { left: -12px; top: 12px; }

    .btn-sit-here {
        width: 76px;
        height: 56px;
        border-radius: 8px;
        padding: 4px;
    }

    .empty-seat-placeholder {
        width: 76px;
        height: 56px;
        border-radius: 8px;
    }

    .btn-sit-here span:first-child {
        font-size: 14px;
    }

    .btn-sit-here span:last-child {
        font-size: 9px;
    }

    .seat-refill-btn {
        font-size: 9px;
        padding: 2px 6px;
        margin-top: 2px;
    }

    /* 5. CARDS ON MOBILE (OPPONENTS vs USER) */
    /* Opponents Cards */
    .seat:not(.is-user-seat) .seat-cards {
        width: 66px;
        height: 34px;
        margin-top: 2px;
    }

    .seat:not(.is-user-seat) .card {
        width: 24px;
        height: 34px;
        border-radius: 3px;
        padding: 1px 2px;
    }

    .seat:not(.is-user-seat) .card:nth-child(1) { left: 0; }
    .seat:not(.is-user-seat) .card:nth-child(2) { left: 16px; }
    .seat:not(.is-user-seat) .card:nth-child(3) { left: 32px; }

    .seat:not(.is-user-seat) .card-value {
        font-size: 7px;
    }

    .seat:not(.is-user-seat) .card-suit-center {
        font-size: 11px;
    }

    .seat:not(.is-user-seat) .card-bottom {
        display: none;
    }

    /* User Seat Cards - Bigger and Clear */
    .seat.is-user-seat .seat-cards {
        width: 98px;
        height: 52px;
        margin-top: 2px;
    }

    .seat.is-user-seat .card {
        width: 36px;
        height: 52px;
        border-radius: 4px;
        padding: 2px 3px;
    }

    .seat.is-user-seat .card:nth-child(1) { left: 0; }
    .seat.is-user-seat .card:nth-child(2) { left: 24px; }
    .seat.is-user-seat .card:nth-child(3) { left: 48px; }

    .seat.is-user-seat .card-value {
        font-size: 9.5px;
    }

    .seat.is-user-seat .card-suit-center {
        font-size: 15px;
    }

    .seat.is-user-seat .card-bottom {
        font-size: 8px;
    }

    /* 6. ACTION CONTROLS PANEL (ERGONOMIC MOBILE THUMB BAR) */
    .action-panel {
        width: 100%;
        max-width: 100%;
        border-radius: 16px 16px 0 0;
        margin-bottom: 0;
        padding: 8px 10px 12px;
        background: rgba(10, 14, 22, 0.98);
        border: 1px solid rgba(249, 202, 36, 0.35);
        border-bottom: none;
        box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.7);
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

    .action-center {
        width: 100%;
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

    .bet-controls-bar {
        display: flex;
        width: 100%;
        gap: 6px;
        justify-content: center;
        background: rgba(255, 255, 255, 0.04);
        padding: 3px 6px;
        border-radius: 10px;
    }

    .bet-quick-btn {
        flex: 1;
        height: 32px;
        font-size: 12px;
        font-weight: 800;
        border-radius: 8px;
    }

    .btn-chaal {
        width: 100%;
        height: 44px;
        font-size: 14px;
        font-weight: 800;
        border-radius: 12px;
    }

    .action-left, .action-right {
        width: 100%;
        display: flex;
        gap: 6px;
        justify-content: space-between;
    }

    .action-left .btn-action, .action-right .btn-action {
        flex: 1;
        height: 38px;
        font-size: 12px;
        font-weight: 700;
        border-radius: 10px;
        padding: 0 6px;
        min-width: 0;
    }

    /* 7. POPUPS & BANNERS ON MOBILE */
    .winner-banner {
        width: 92vw;
        max-width: 340px;
        border-radius: 16px;
        display: none;
    }

    .winner-banner.show {
        display: flex !important;
    }

    .winner-drag-bar {
        padding: 7px 12px;
    }

    .winner-drag-indicator {
        font-size: 10px;
    }

    .btn-winner-minimize {
        font-size: 10px;
        padding: 2px 8px;
    }

    .winner-banner-content {
        padding: 10px 16px 14px;
        gap: 6px;
    }

    .winner-trophy {
        font-size: 32px;
    }

    .winner-title {
        font-size: 17px;
    }

    .winner-desc {
        font-size: 11px;
    }

    #winner-amount {
        font-size: 20px !important;
    }

    #btn-winner-continue {
        font-size: 12px !important;
        padding: 7px 16px !important;
        border-radius: 12px !important;
    }

    .your-turn-banner {
        font-size: 11px;
        padding: 4px 12px;
        top: 2px;
    }

    .out-of-points-banner {
        font-size: 11px;
        padding: 6px 10px;
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
    }

    .btn-oop-add {
        width: 100%;
        text-align: center;
        padding: 6px 10px;
        font-size: 11px;
    }

    /* 8. CHAT DRAWER ON MOBILE (Sits at very bottom, slides UP when tapped) */
    .chat-drawer {
        right: 8px;
        bottom: 0px !important;
        width: 250px;
        max-width: 90vw;
        height: 250px;
        max-height: 52vh;
        z-index: 250;
        border-radius: 14px 14px 0 0;
        border-bottom: none;
        background: rgba(10, 14, 22, 0.98);
        box-shadow: 0 -4px 25px rgba(0, 0, 0, 0.85);
        transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), width 0.25s ease;
    }

    .chat-drawer.collapsed {
        transform: translateY(calc(100% - 26px)) !important;
        width: 135px; /* Compact pill at bottom-right so action buttons stay completely free */
    }

    .chat-header {
        height: 26px;
        padding: 0 10px;
        font-size: 11px;
        color: var(--gold);
        background: rgba(249, 202, 36, 0.12);
        border-radius: 14px 14px 0 0;
    }

    /* VOICE DRAWER ON MOBILE (Sits at very bottom LEFT, slides UP when tapped) */
    .voice-drawer {
        left: 8px;
        bottom: 0px !important;
        width: 290px;
        max-width: 90vw;
        height: 380px;
        max-height: 58vh;
        z-index: 250;
        border-radius: 14px 14px 0 0;
        border-bottom: none;
        background: rgba(10, 14, 22, 0.98);
        box-shadow: 0 -4px 25px rgba(0, 0, 0, 0.85);
        transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275), width 0.25s ease;
    }

    .voice-drawer.collapsed {
        transform: translateY(calc(100% - 26px)) !important;
        width: 135px; /* Compact pill at bottom-left so action buttons stay completely free */
    }

    .voice-drawer-header {
        height: 26px;
        padding: 0 10px;
        font-size: 11px;
        color: #2ecc71;
        background: rgba(46, 204, 113, 0.15);
        border-radius: 14px 14px 0 0;
    }

    /* 9. MODALS ON MOBILE */
    .modal-content {
        width: 94%;
        padding: 18px 14px;
        border-radius: 16px;
    }

    /* 10. COMPACT LOBBY ON MOBILE (No Clipping, Everything Fits in View) */
    .lobby-screen {
        align-items: flex-start !important;
        padding: 10px 8px 30px !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
    }

    .dashboard-container {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        gap: 14px !important;
        padding-bottom: 24px;
    }

    .dashboard-container .lobby-card {
        padding: 14px 12px !important;
        border-radius: 18px !important;
        max-width: 100% !important;
        width: 100% !important;
    }

    .lobby-header-row {
        padding-bottom: 8px !important;
        margin-bottom: 8px !important;
    }

    .lobby-user-photo {
        width: 42px !important;
        height: 42px !important;
        font-size: 18px !important;
    }

    .lobby-user-name {
        font-size: 14px !important;
    }

    .lobby-user-chips {
        font-size: 12px !important;
    }

    .btn-quick-add-sm {
        padding: 2px 7px !important;
        font-size: 10px !important;
    }

    .btn-logout {
        padding: 3px 8px !important;
        font-size: 10px !important;
    }

    .photo-upload-row {
        padding: 6px 8px !important;
        gap: 8px !important;
    }

    .photo-preview {
        width: 36px !important;
        height: 36px !important;
    }

    .btn-upload-photo {
        padding: 5px 8px !important;
        font-size: 11px !important;
    }

    .photo-hint {
        font-size: 9px !important;
        margin-top: 2px !important;
    }

    .lobby-card .form-group {
        margin-bottom: 8px !important;
    }

    .lobby-card .form-label {
        font-size: 11px !important;
        margin-bottom: 3px !important;
    }

    .lobby-card .form-input {
        height: 36px !important;
        font-size: 13px !important;
        padding: 0 10px !important;
    }

    .avatar-grid {
        grid-template-columns: repeat(5, 1fr) !important;
        gap: 6px !important;
        margin: 6px 0 !important;
    }

    .avatar-choice {
        width: 38px !important;
        height: 38px !important;
        font-size: 18px !important;
        border-radius: 10px !important;
    }

    .lobby-bots-row {
        padding: 6px 10px !important;
        margin: 6px 0 10px !important;
        font-size: 11px !important;
    }

    .btn-join-lobby {
        height: 46px !important;
        padding: 0 16px !important;
        font-size: 15px !important;
        font-weight: 800 !important;
        border-radius: 14px !important;
        margin-top: 6px !important;
    }

    .online-players-card {
        padding: 14px 12px !important;
        border-radius: 18px !important;
        max-width: 100% !important;
        width: 100% !important;
    }

    .online-list-container {
        max-height: 220px !important;
    }
}

/* ========================================================= */
/* ULTRA-NARROW SCREENS (<= 380px e.g. iPhone SE)            */
/* ========================================================= */
@media (max-width: 380px) {
    .poker-table-wrapper {
        height: 360px;
    }

    .seat {
        width: 88px;
        height: 82px;
    }

    .seat-card {
        width: 84px;
        padding: 2px 3px;
    }

    .seat.is-user-seat .seat-card {
        width: 98px;
    }

    .seat-avatar-wrap {
        width: 26px;
        height: 26px;
    }

    .seat-name {
        font-size: 9px;
        max-width: 72px;
    }

    .seat:not(.is-user-seat) .seat-cards {
        width: 58px;
    }

    .seat:not(.is-user-seat) .card {
        width: 21px;
        height: 30px;
    }

    .seat:not(.is-user-seat) .card:nth-child(2) { left: 14px; }
    .seat:not(.is-user-seat) .card:nth-child(3) { left: 28px; }

    .seat.is-user-seat .card {
        width: 32px;
        height: 46px;
    }

    .seat.is-user-seat .card:nth-child(2) { left: 21px; }
    .seat.is-user-seat .card:nth-child(3) { left: 42px; }
}

/* ========================================================= */
/* MOBILE LANDSCAPE VIEW (SCREEN ROTATION)                   */
/* ========================================================= */
@media (max-height: 520px) and (orientation: landscape) {
    .navbar {
        height: 38px;
        padding: 0 8px;
    }

    .brand-title {
        display: none;
    }

    .poker-table-wrapper {
        height: calc(100vh - 84px);
        min-height: 220px;
        max-height: 300px;
        margin: 0 auto;
    }

    .poker-table {
        inset: 4px 16px;
        border: 6px solid var(--table-border-wood);
        border-radius: 120px;
    }

    .table-center {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        z-index: 10;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 3px;
        margin: 0;
        width: max-content;
    }

    .seat {
        width: 90px;
        height: 75px;
    }

    .seat-card {
        width: 86px;
        padding: 2px 4px;
    }

    .seat-avatar-wrap {
        width: 24px;
        height: 24px;
    }

    .seat:not(.is-user-seat) .seat-cards {
        height: 28px;
        margin-top: 1px;
    }

    .seat:not(.is-user-seat) .card {
        width: 20px;
        height: 28px;
    }

    .seat.is-user-seat .card {
        width: 30px;
        height: 42px;
    }

    .action-panel {
        padding: 4px 8px 6px;
        margin-bottom: 0;
        gap: 4px;
    }

    .btn-chaal {
        height: 34px;
        font-size: 12px;
    }

    .action-left .btn-action, .action-right .btn-action {
        height: 30px;
        font-size: 11px;
    }

    .bet-quick-btn {
        height: 26px;
        font-size: 10px;
    }

    .chat-drawer, .voice-drawer {
        display: none; /* Hide chat and voice drawers in short landscape to avoid obstructing play */
    }
}

/* ========================================================= */
/* LIVE VOICE CHAT & AVATAR SPEAKING STYLES                  */
/* ========================================================= */

.btn-voice-nav {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.25), rgba(192, 57, 43, 0.35)) !important;
    border: 1px solid rgba(231, 76, 60, 0.5) !important;
    color: #ff7675 !important;
}

.btn-voice-nav:hover {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.45), rgba(192, 57, 43, 0.65)) !important;
    border-color: #ff7675 !important;
    color: #fff !important;
}

.btn-chat-voice {
    background: rgba(231, 76, 60, 0.2);
    border: 1px solid rgba(231, 76, 60, 0.4);
    color: #fff;
    width: 38px;
    height: 38px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    flex-shrink: 0;
    transition: all 0.2s;
}

.btn-chat-voice:hover {
    background: #e74c3c;
    transform: scale(1.05);
}

.voice-modal-card {
    max-width: 480px;
    width: 95%;
    padding: 20px;
    text-align: center;
}

.voice-https-prompt {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.18), rgba(230, 126, 34, 0.28));
    border: 1.5px solid rgba(243, 156, 18, 0.6);
    border-radius: 12px;
    padding: 12px 14px;
    margin: 12px 0 6px 0;
    text-align: left;
}

.vhp-header {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 8px;
}

.vhp-title {
    font-size: 13px;
    font-weight: 800;
    color: #f39c12;
    margin-bottom: 2px;
}

.vhp-desc {
    font-size: 11px;
    color: #f1f2f6;
    line-height: 1.35;
}

.btn-switch-https-voice {
    background: linear-gradient(135deg, #27ae60, #2ecc71);
    color: #fff;
    border: 1px solid #2ecc71;
    border-radius: 20px;
    padding: 9px 16px;
    font-size: 12px;
    font-weight: 800;
    cursor: pointer;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    box-shadow: 0 4px 12px rgba(46, 204, 113, 0.4);
    transition: all 0.2s;
}

.btn-switch-https-voice:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 16px rgba(46, 204, 113, 0.6);
}

.voice-ptt-section {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    padding: 16px;
    margin: 14px 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.btn-voice-ptt {
    background: linear-gradient(135deg, #2c3e50, #1a252f);
    border: 2px solid rgba(249, 202, 36, 0.4);
    border-radius: 50px;
    padding: 10px 24px;
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    transition: all 0.2s;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    width: 100%;
    max-width: 290px;
}

.btn-voice-ptt:hover {
    border-color: var(--gold);
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(249, 202, 36, 0.25);
}

.btn-voice-ptt.is-recording {
    background: linear-gradient(135deg, #e74c3c, #c0392b) !important;
    border-color: #ff7675 !important;
    box-shadow: 0 0 25px rgba(231, 76, 60, 0.7) !important;
    animation: pttPulse 0.8s infinite alternate ease-in-out;
}

@keyframes pttPulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.04); }
}

.ptt-icon-wrap {
    position: relative;
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
}

.btn-voice-ptt.is-recording .ptt-icon-wrap {
    background: #fff;
}

.ptt-pulse-ring {
    display: none;
    position: absolute;
    inset: -6px;
    border: 2px solid #e74c3c;
    border-radius: 50%;
    animation: ringPulse 1.2s infinite;
}

.btn-voice-ptt.is-recording .ptt-pulse-ring {
    display: block;
}

@keyframes ringPulse {
    0% { transform: scale(0.9); opacity: 1; }
    100% { transform: scale(1.5); opacity: 0; }
}

.ptt-details {
    text-align: left;
}

.ptt-status-text {
    font-size: 15px;
    font-weight: 800;
    color: #fff;
}

.ptt-sub-hint {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.ptt-timer-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    font-size: 13px;
    font-weight: 800;
}

.recording-badge {
    background: #e74c3c;
    color: #fff;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 11px;
    animation: blinkRecording 1s infinite alternate;
}

@keyframes blinkRecording {
    0% { opacity: 0.6; }
    100% { opacity: 1; }
}

.recording-time {
    color: #fff;
    font-family: monospace;
    font-size: 14px;
}

/* Quick Voice Lines Grid */
.voice-presets-section {
    text-align: left;
    margin-top: 12px;
}

.voice-presets-title {
    font-size: 12px;
    font-weight: 800;
    color: var(--gold);
    margin-bottom: 8px;
}

.voice-presets-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
    max-height: 220px;
    overflow-y: auto;
    padding-right: 2px;
}

.voice-preset-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 10px;
    padding: 9px 10px;
    color: #f1f2f6;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 700;
    text-align: left;
    transition: all 0.2s;
}

.voice-preset-btn:hover {
    background: rgba(249, 202, 36, 0.15);
    border-color: var(--gold);
    color: var(--gold);
    transform: translateY(-1px);
}

.voice-preset-btn:active {
    transform: scale(0.96);
    background: rgba(46, 204, 113, 0.2);
    border-color: #2ecc71;
}

.vp-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.vp-text {
    line-height: 1.25;
}

.voice-modal-footer {
    margin-top: 14px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

/* Avatar Speaking Animation & Bubble */
.seat.is-speaking .seat-avatar {
    box-shadow: 0 0 0 3px #2ecc71, 0 0 20px rgba(46, 204, 113, 0.85) !important;
    animation: voiceAvatarPulse 0.5s infinite alternate ease-in-out !important;
}

.seat.is-speaking .seat-avatar-wrap::after {
    content: "🔊";
    position: absolute;
    top: -6px;
    right: -6px;
    font-size: 13px;
    background: #27ae60;
    border: 1.5px solid #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 12;
    animation: bounceIndicator 0.6s infinite alternate;
}

@keyframes voiceAvatarPulse {
    0% { transform: scale(1); box-shadow: 0 0 0 2px #2ecc71, 0 0 10px rgba(46, 204, 113, 0.6); }
    100% { transform: scale(1.1); box-shadow: 0 0 0 5px #27ae60, 0 0 22px rgba(46, 204, 113, 0.95); }
}

.voice-bubble {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #1e824c, #27ae60);
    color: #fff;
    font-size: 11px;
    font-weight: 800;
    padding: 3px 9px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    white-space: nowrap;
    z-index: 25;
    pointer-events: none;
    animation: popBubble 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.voice-bubble::after {
    content: "";
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px 5px 0 5px;
    border-style: solid;
    border-color: #27ae60 transparent transparent transparent;
}

@keyframes popBubble {
    0% { transform: translate(-50%, 6px) scale(0.7); opacity: 0; }
    100% { transform: translate(-50%, 0) scale(1); opacity: 1; }
}

@media (max-width: 768px) {
    .btn-voice-nav span:not(#voice-nav-icon) {
        display: none;
    }
    .voice-presets-grid {
        grid-template-columns: 1fr 1fr;
        gap: 6px;
    }
    .voice-preset-btn {
        padding: 7px 8px;
        font-size: 11px;
    }
}

/* ==========================================================================
   📒 POINT LEDGER & PASSBOOK (HISAB-KITAB) STYLES
   ========================================================================== */
.point-ledger-modal-card {
    max-width: 620px;
    width: 95%;
    background: linear-gradient(180deg, #141b24 0%, #0d1218 100%);
    border: 2px solid rgba(26, 188, 156, 0.5);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.9), 0 0 30px rgba(26, 188, 156, 0.25);
    border-radius: 20px;
    padding: 20px 22px;
}

.ledger-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}

@media (min-width: 580px) {
    .ledger-summary-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.ledger-kpi-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 80px;
    transition: transform 0.2s, border-color 0.2s;
}

.ledger-kpi-card:hover {
    transform: translateY(-2px);
}

.ledger-kpi-card.kpi-balance {
    border-color: rgba(241, 196, 15, 0.4);
    background: linear-gradient(135deg, rgba(241, 196, 15, 0.08), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-card.kpi-won {
    border-color: rgba(46, 204, 113, 0.4);
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.08), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-card.kpi-lost {
    border-color: rgba(231, 76, 60, 0.4);
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.08), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-card.kpi-net {
    border-color: rgba(52, 152, 219, 0.4);
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.08), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-card.kpi-net.profit {
    border-color: rgba(46, 204, 113, 0.5);
    background: linear-gradient(135deg, rgba(46, 204, 113, 0.12), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-card.kpi-net.loss {
    border-color: rgba(231, 76, 60, 0.5);
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.12), rgba(0, 0, 0, 0.2));
}

.ledger-kpi-label {
    font-size: 11px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.ledger-kpi-val {
    font-size: 16px;
    font-weight: 800;
    color: var(--gold);
    line-height: 1.2;
}

.ledger-kpi-val.text-win {
    color: #2ecc71;
}

.ledger-kpi-val.text-loss {
    color: #ff7675;
}

.ledger-kpi-sub {
    font-size: 10px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 4px;
}

.ledger-filter-bar {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 6px;
    margin-bottom: 12px;
    scrollbar-width: thin;
}

.ledger-tab {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.8);
    font-size: 12px;
    font-weight: 700;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.ledger-tab:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.ledger-tab.active {
    background: linear-gradient(135deg, #16a085, #1abc9c);
    border-color: #1abc9c;
    color: #fff;
    box-shadow: 0 4px 12px rgba(26, 188, 156, 0.35);
}

.ledger-list-wrapper {
    max-height: 330px;
    overflow-y: auto;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.06);
    padding: 8px;
    scrollbar-width: thin;
}

.ledger-list-wrapper::-webkit-scrollbar {
    width: 6px;
}

.ledger-list-wrapper::-webkit-scrollbar-thumb {
    background: rgba(26, 188, 156, 0.4);
    border-radius: 3px;
}

.ledger-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    margin-bottom: 6px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: background 0.15s, border-color 0.15s;
}

.ledger-item:last-child {
    margin-bottom: 0;
}

.ledger-item:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.12);
}

.ledger-item.item-win {
    border-left: 3px solid #2ecc71;
}

.ledger-item.item-loss {
    border-left: 3px solid #e74c3c;
}

.ledger-item.item-refill {
    border-left: 3px solid #3498db;
}

.ledger-item-left {
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 0;
}

.ledger-badge-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    flex-shrink: 0;
}

.ledger-badge-icon.badge-win {
    background: rgba(46, 204, 113, 0.18);
    border: 1px solid rgba(46, 204, 113, 0.4);
}

.ledger-badge-icon.badge-loss {
    background: rgba(231, 76, 60, 0.18);
    border: 1px solid rgba(231, 76, 60, 0.4);
}

.ledger-badge-icon.badge-refill {
    background: rgba(52, 152, 219, 0.18);
    border: 1px solid rgba(52, 152, 219, 0.4);
}

.ledger-info-box {
    min-width: 0;
}

.ledger-desc {
    font-size: 13px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ledger-meta {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.55);
    margin-top: 2px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.ledger-item-right {
    text-align: right;
    flex-shrink: 0;
    padding-left: 10px;
}

.ledger-amount {
    font-size: 15px;
    font-weight: 800;
}

.ledger-amount.amount-win {
    color: #2ecc71;
}

.ledger-amount.amount-loss {
    color: #ff7675;
}

.ledger-amount.amount-refill {
    color: #3498db;
}

.ledger-balance-after {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 2px;
    font-weight: 600;
}

.ledger-empty-state {
    text-align: center;
    padding: 30px 16px;
    color: rgba(255, 255, 255, 0.6);
}

.ledger-empty-icon {
    font-size: 38px;
    margin-bottom: 8px;
    opacity: 0.8;
}

.ledger-empty-title {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 4px;
}

.ledger-empty-sub {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.ledger-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 10px;
    gap: 10px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
}

.ledger-spinner {
    width: 26px;
    height: 26px;
    border: 3px solid rgba(26, 188, 156, 0.2);
    border-top-color: #1abc9c;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.ledger-modal-footer {
    display: flex;
    gap: 10px;
    margin-top: 14px;
}

.btn-add-chips-ledger {
    flex: 2;
    background: linear-gradient(135deg, #27ae60, #1e8449);
    color: #fff;
    border: none;
    padding: 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 800;
    cursor: pointer;
}

.btn-refresh-ledger {
    flex: 1;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    padding: 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-refresh-ledger:hover {
    background: rgba(255, 255, 255, 0.15);
}

@media (max-width: 480px) {
    .point-ledger-modal-card {
        padding: 16px 14px;
    }
    .ledger-kpi-val {
        font-size: 14px;
    }
    .ledger-desc {
        font-size: 12px;
    }
    .ledger-amount {
        font-size: 13px;
    }
}

/* ========================================================= */
/* ♠ DEDICATED DIRECT LOGIN SCREEN STYLING                   */
/* ========================================================= */
#login-screen {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at center, #0a1f18 0%, #06110d 60%, #020605 100%) !important;
    padding: 20px 16px;
    z-index: 9999;
    overflow-y: auto;
}

#login-screen .lobby-card {
    background: linear-gradient(180deg, rgba(16, 32, 26, 0.96) 0%, rgba(10, 20, 16, 0.98) 100%) !important;
    border: 2px solid rgba(249, 202, 36, 0.45) !important;
    border-radius: 24px !important;
    padding: 36px 30px !important;
    max-width: 440px !important;
    width: 100% !important;
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.85), 0 0 35px rgba(249, 202, 36, 0.2) !important;
    text-align: center;
    margin: auto !important;
}

#login-screen .lobby-logo {
    font-size: 54px !important;
    color: var(--gold) !important;
    line-height: 1 !important;
    margin-bottom: 8px !important;
    filter: drop-shadow(0 0 16px rgba(249, 202, 36, 0.6)) !important;
    animation: pulseGlow 2.5s ease-in-out infinite alternate !important;
}

#login-screen .lobby-title {
    font-family: 'Cinzel', serif !important;
    font-size: 26px !important;
    font-weight: 900 !important;
    letter-spacing: 2px !important;
    background: linear-gradient(135deg, #ffffff 0%, #f9ca24 60%, #f39c12 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    margin: 0 0 4px !important;
}

#login-screen .lobby-subtitle {
    font-size: 13px !important;
    font-weight: 600 !important;
    color: rgba(255, 255, 255, 0.65) !important;
    margin: 0 0 20px !important;
    letter-spacing: 0.5px !important;
}

.login-info-pill {
    background: rgba(241, 196, 15, 0.08) !important;
    border: 1px solid rgba(241, 196, 15, 0.35) !important;
    border-radius: 12px !important;
    padding: 12px 14px !important;
    margin-bottom: 20px !important;
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    text-align: left !important;
}

.login-info-pill .pill-icon {
    font-size: 26px;
    flex-shrink: 0;
}

.login-info-pill .pill-title {
    font-size: 13px;
    font-weight: 800;
    color: var(--gold);
    margin-bottom: 2px;
}

.login-info-pill .pill-desc {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.35;
}

.login-form-box {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
    text-align: left !important;
}

.login-form-box .form-group {
    margin-bottom: 0 !important;
}

.login-form-box .form-label {
    display: block !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    color: rgba(255, 255, 255, 0.9) !important;
    margin-bottom: 6px !important;
    letter-spacing: 0.3px !important;
}

.login-form-box .input-with-icon .form-input {
    height: 48px !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    background: rgba(0, 0, 0, 0.45) !important;
    border: 1.5px solid rgba(255, 255, 255, 0.15) !important;
    border-radius: 12px !important;
    color: #ffffff !important;
    padding-left: 44px !important;
    padding-right: 14px !important;
    box-sizing: border-box !important;
    transition: all 0.2s ease !important;
    width: 100% !important;
}

.login-form-box .input-with-icon .form-input:focus {
    border-color: var(--gold) !important;
    background: rgba(0, 0, 0, 0.65) !important;
    box-shadow: 0 0 12px rgba(249, 202, 36, 0.3) !important;
    outline: none !important;
}

.login-form-box .input-icon {
    left: 14px !important;
    font-size: 18px !important;
    opacity: 0.9 !important;
    z-index: 2;
}

.login-hint {
    font-size: 11px !important;
    color: rgba(255, 255, 255, 0.55) !important;
    margin-top: 5px !important;
    line-height: 1.35 !important;
}

.btn-enter-game {
    width: 100% !important;
    height: 50px !important;
    background: linear-gradient(135deg, #27ae60 0%, #1e8449 100%) !important;
    border: 1px solid rgba(46, 204, 113, 0.4) !important;
    border-radius: 14px !important;
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: 800 !important;
    cursor: pointer !important;
    box-shadow: 0 6px 20px rgba(39, 174, 96, 0.4) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s !important;
    margin-top: 6px !important;
}

.btn-enter-game:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(39, 174, 96, 0.6) !important;
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%) !important;
}

.btn-enter-game:active {
    transform: translateY(0) !important;
}

@media (max-width: 480px) {
    #login-screen .lobby-card {
        padding: 24px 18px !important;
        border-radius: 20px !important;
    }
    #login-screen .lobby-logo {
        font-size: 44px !important;
    }
    #login-screen .lobby-title {
        font-size: 22px !important;
    }
    .btn-enter-game {
        height: 46px !important;
        font-size: 15px !important;
    }
}




