/* =====================================
   JACKPOT LIVE - Lottery Drawing Page
   Premium Gaming Theme with Gold & Coins
   ===================================== */

/* CSS Variables */
:root {
    --gold-light: #4dfff3;
    --gold-main: #00c4e0;
    --gold-dark: #0077aa;
    --gold-deep: #00354e;
    --red-main: #FF4757;
    --red-dark: #C0392B;
    --purple-main: #9B59B6;
    --purple-dark: #6C3483;
    /* ── Blue Theme ── */
    --bg-dark: #050d1e;
    --bg-gradient: linear-gradient(180deg, #050d1e 0%, #0a1e4a 40%, #0d2d7a 100%);
    --card-bg: rgba(8, 25, 72, 0.88);
    --card-border: rgba(80, 150, 255, 0.28);
    --text-light: #FFFFFF;
    --text-gold: #4dfff3;
    --blue-light: #7ec8ff;
    --blue-main: #1a7aff;
    --blue-dark: #0a3b8c;
    --blue-glow: rgba(80, 150, 255, 0.45);
    --glow-gold: 0 0 20px rgba(77, 255, 243, 0.5), 0 0 40px rgba(0, 196, 224, 0.3);
    --glow-blue: 0 0 20px rgba(80, 150, 255, 0.5), 0 0 40px rgba(80, 150, 255, 0.3);
    --glow-red: 0 0 20px rgba(255, 71, 87, 0.5), 0 0 40px rgba(255, 71, 87, 0.3);
}

/* ===== CSS Icons (Emoji Replacements) ===== */

/* Slot Machine Icon */
.icon-slot {
    display: inline-block;
    width: 1em;
    height: 1em;
    background: linear-gradient(135deg, var(--gold-light), var(--gold-dark));
    border-radius: 0.15em;
    position: relative;
    box-shadow: inset 0 -0.1em 0.2em rgba(0, 0, 0, 0.3);
}

.icon-slot::before {
    content: '777';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.35em;
    font-weight: 900;
    color: var(--red-main);
    text-shadow: 0.02em 0.02em 0 #fff;
}

.icon-slot.large {
    width: 2em;
    height: 2em;
}

.icon-slot.large::before {
    font-size: 0.6em;
}

/* Trophy Icon */
.icon-trophy {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-trophy::before {
    content: '';
    position: absolute;
    top: 0;
    left: 15%;
    width: 70%;
    height: 60%;
    background: linear-gradient(135deg, var(--gold-light), var(--gold-dark));
    border-radius: 0 0 50% 50%;
}

.icon-trophy::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 25%;
    width: 50%;
    height: 25%;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold-deep));
    border-radius: 0.1em;
}

/* Dice Icon */
.icon-dice {
    display: inline-block;
    width: 1em;
    height: 1em;
    background: linear-gradient(135deg, #fff, #ddd);
    border-radius: 0.15em;
    position: relative;
    box-shadow: 0.05em 0.05em 0.1em rgba(0, 0, 0, 0.3);
}

.icon-dice::before,
.icon-dice::after {
    content: '';
    position: absolute;
    width: 0.15em;
    height: 0.15em;
    background: #333;
    border-radius: 50%;
}

.icon-dice::before {
    top: 25%;
    left: 25%;
    box-shadow: 0.35em 0.35em 0 #333;
}

.icon-dice::after {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Bolt/Lightning Icon */
.icon-bolt {
    display: inline-block;
    width: 0.6em;
    height: 1em;
    position: relative;
}

.icon-bolt::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
    clip-path: polygon(60% 0%, 10% 50%, 40% 50%, 0% 100%, 100% 40%, 60% 40%, 100% 0%);
}

/* Chart/Progress Icon */
.icon-chart {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-chart::before {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(var(--gold-light), var(--gold-light)) 5% 80%/20% 20% no-repeat,
        linear-gradient(var(--gold-main), var(--gold-main)) 40% 50%/20% 50% no-repeat,
        linear-gradient(var(--gold-dark), var(--gold-dark)) 75% 20%/20% 80% no-repeat;
}

/* Gift Icon */
.icon-gift {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-gift::before {
    content: '';
    position: absolute;
    top: 25%;
    left: 10%;
    width: 80%;
    height: 70%;
    background: linear-gradient(135deg, var(--red-main), var(--red-dark));
    border-radius: 0.1em;
}

.icon-gift::after {
    content: '';
    position: absolute;
    top: 0;
    left: 30%;
    width: 40%;
    height: 35%;
    border: 0.1em solid var(--gold-light);
    border-bottom: none;
    border-radius: 50% 50% 0 0;
    background: transparent;
}

/* Star Icon */
.icon-star {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-star::before {
    content: '';
    position: absolute;
    top: 5%;
    left: 5%;
    width: 90%;
    height: 90%;
    background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

/* Medal Icon */
.icon-medal {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-medal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 25%;
    width: 20%;
    height: 35%;
    background: var(--red-main);
}

.icon-medal::after {
    content: '';
    position: absolute;
    top: 0;
    right: 25%;
    width: 20%;
    height: 35%;
    background: var(--red-main);
}

.icon-medal.gold::before,
.icon-medal.gold::after {
    background: var(--red-main);
}

.icon-medal.silver::before,
.icon-medal.silver::after {
    background: #6c757d;
}

.icon-medal.bronze::before,
.icon-medal.bronze::after {
    background: #CD7F32;
}

/* Medal Circle */
.icon-medal span,
.icon-medal {
    display: inline-block;
}

.icon-medal {
    background: radial-gradient(circle at 30% 30%,
            var(--gold-light) 0%,
            var(--gold-main) 50%,
            var(--gold-dark) 100%);
    border-radius: 50%;
    border: 0.08em solid var(--gold-deep);
    margin-top: 0.3em;
}

.icon-medal.silver {
    background: radial-gradient(circle at 30% 30%,
            #e8e8e8 0%,
            #c0c0c0 50%,
            #808080 100%);
    border-color: #606060;
}

.icon-medal.bronze {
    background: radial-gradient(circle at 30% 30%,
            #DDA06D 0%,
            #CD7F32 50%,
            #8B4513 100%);
    border-color: #6B3500;
}

/* List Icon */
.icon-list {
    display: inline-block;
    width: 1em;
    height: 1em;
    position: relative;
}

.icon-list::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 0;
    width: 100%;
    height: 60%;
    background:
        linear-gradient(var(--gold-light), var(--gold-light)) 0% 0%/100% 20% no-repeat,
        linear-gradient(var(--gold-main), var(--gold-main)) 0% 50%/100% 20% no-repeat,
        linear-gradient(var(--gold-dark), var(--gold-dark)) 0% 100%/100% 20% no-repeat;
}


/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    max-width: 100vw;
    min-height: 100vh;
    overflow-x: hidden;
}

body {
    font-family: 'Noto Sans SC', 'Orbitron', sans-serif;
    background: var(--bg-dark);
    background-image: var(--bg-gradient);
    background-attachment: fixed;
    color: var(--text-light);
    position: relative;
    touch-action: manipulation;
    -webkit-text-size-adjust: 100%;
}

/* Three.js Fireworks Canvas */
#fireworksCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

/* Main Container */
.main-container {
    position: relative;
    z-index: 2;
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    padding: 15px;
    box-sizing: border-box;
}

/* Online Count Display */
.online-count-display {
    position: fixed;
    top: 10px;
    right: 15px;
    padding: 5px 12px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 10;
    backdrop-filter: blur(5px);
}

/* Mute Button */
.mute-btn {
    position: fixed;
    top: 10px;
    left: 15px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid rgba(140,180,255,0.3);
    background: rgba(10,16,40,0.75);
    backdrop-filter: blur(6px);
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s, transform 0.15s;
    padding: 0;
    line-height: 1;
}
.mute-btn:hover {
    background: rgba(30,50,100,0.9);
    border-color: rgba(140,180,255,0.7);
    transform: scale(1.1);
}
.mute-btn:active { transform: scale(0.95); }

.online-icon {
    color: #4cd137;
    /* Green dot */
    font-size: 0.8rem;
    animation: blink 2s infinite;
}

.online-text {
    font-size: 0.9rem;
    color: var(--gold-light);
    font-weight: bold;
}


/* Header */
.header {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    background: transparent;
    border: none;
    margin-bottom: 20px;
    box-shadow: none;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    font-size: 3rem;
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.logo-text {
    font-family: 'Orbitron', sans-serif;
    font-size: 3.5rem;
    font-weight: 900;
    background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold-main) 50%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
    filter: drop-shadow(0 0 10px rgba(255, 215, 0, 0.5));
    letter-spacing: 3px;
}

.jackpot-amount {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.jackpot-amount .label {
    font-size: 0.9rem;
    color: var(--gold-light);
    text-transform: uppercase;
    letter-spacing: 2px;
}

.jackpot-amount .amount {
    font-family: 'Orbitron', sans-serif;
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold-light);
    text-shadow: var(--glow-gold);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }
}

/* Prize Display */
.prize-display {
    text-align: center;
    margin-bottom: 20px;
}


.current-prize-type {
    display: inline-flex;
    align-items: center;
    gap: 20px;
    padding: 15px 40px;
    background: linear-gradient(180deg, rgba(20, 20, 20, 0.95) 0%, rgba(40, 40, 40, 0.95) 100%);
    border: 1px solid var(--gold-main);
    border-radius: 50px;
    box-shadow:
        0 0 20px rgba(255, 215, 0, 0.15),
        inset 0 0 20px rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    position: relative;
    overflow: hidden;
}

.current-prize-type::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 50%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, transparent 100%);
    pointer-events: none;
}

.prize-badge {
    background: linear-gradient(135deg, var(--gold-light) 0%, var(--gold-main) 100%);
    color: #000;
    padding: 6px 16px;
    border-radius: 20px;
    font-weight: 800;
    font-size: 0.9rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    text-transform: uppercase;
    letter-spacing: 1px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 32px;
}

@keyframes glow {
    from {
        box-shadow: 0 0 5px var(--gold-light);
    }

    to {
        box-shadow: 0 0 15px var(--gold-light);
    }
}

.prize-name {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--gold-light);
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    letter-spacing: 1px;
}

.prize-count {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    line-height: 1.1;
}

.prize-count-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.prize-count-value {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.2rem;
    color: var(--text-light);
    font-weight: 700;
}

.prize-amount-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 12px;
    padding: 5px 15px;
    min-width: 100px;
}

.prize-amount-label {
    font-size: 0.7rem;
    color: var(--gold-main);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 2px;
}

.prize-amount {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--gold-light);
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.4);
    padding: 0;
    background: none;
    border-radius: 0;
}

/* Slot Machine Wrapper */
.slot-machine-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-bottom: 25px;
    max-width: 100%;
    overflow: hidden;
}

.slot-machine-frame {
    position: relative;
    padding: 25px 30px;
    background: rgba(20, 20, 20, 0.9);
    border: 3px solid var(--gold-main);
    border-radius: 20px;
    box-shadow:
        0 0 30px rgba(255, 215, 0, 0.2),
        inset 0 0 50px rgba(0, 0, 0, 0.5),
        0 20px 60px rgba(0, 0, 0, 0.8);
    max-width: 100%;
    box-sizing: border-box;
}

/* Light Ring */
.light-ring {
    position: absolute;
    top: -15px;
    left: -15px;
    right: -15px;
    bottom: -15px;
    pointer-events: none;
}

.light {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--gold-light);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--gold-light), 0 0 20px var(--gold-main);
    animation: blink 0.5s ease-in-out infinite;
    animation-delay: calc(var(--i) * 0.1s);
}

.light:nth-child(-n+5) {
    top: 0;
    left: calc(var(--i) * 20% - 10%);
}

.light:nth-child(n+6):nth-child(-n+10) {
    right: 0;
    top: calc((var(--i) - 5) * 25%);
}

.light:nth-child(n+11):nth-child(-n+15) {
    bottom: 0;
    right: calc((var(--i) - 10) * 20% - 10%);
}

.light:nth-child(n+16) {
    left: 0;
    bottom: calc((var(--i) - 15) * 25%);
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
        background: var(--gold-light);
    }

    50% {
        opacity: 0.3;
        background: var(--gold-dark);
    }
}

/* Slot Machine */
.slot-machine {
    position: relative;
    z-index: 2;
}

.reels-container {
    display: flex;
    gap: 8px;
    padding: 20px;
    background: linear-gradient(180deg, #0D0D1A 0%, #1A1A2E 50%, #0D0D1A 100%);
    border-radius: 15px;
    border: 3px solid var(--gold-dark);
    box-shadow: inset 0 0 30px rgba(0, 0, 0, 0.8);
    position: relative;
    /* Ensure relative positioning for overlay */
}

.reel-wrapper {
    width: 70px;
    height: 100px;
    overflow: hidden;
    background: linear-gradient(180deg, #000 0%, #1a1a2e 50%, #000 100%);
    border-radius: 10px;
    border: 2px solid var(--gold-main);
    position: relative;
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.8);
}

.reel-wrapper::before,
.reel-wrapper::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    height: 30px;
    z-index: 2;
    pointer-events: none;
}

.reel-wrapper::before {
    top: 0;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.9), transparent);
}

.reel-wrapper::after {
    bottom: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.9), transparent);
}

.reel-wrapper.number-reel {
    background: linear-gradient(180deg, #1a0a0a 0%, #2a1a1a 50%, #1a0a0a 100%);
}

.reel {
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: transform 0.1s ease-out;
}

.symbol {
    width: 70px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-size: 2.5rem;
    font-weight: 900;
    color: var(--gold-light);
    text-shadow: 0 0 10px var(--gold-main), 0 0 20px var(--gold-dark);
}

.reel.spinning .symbol {
    animation: spinSymbol 0.08s linear infinite;
}

@keyframes spinSymbol {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-100px);
    }
}

/* Lever */
.lever-container {
    position: relative;
}

.lever {
    width: 30px;
    height: 150px;
    background: linear-gradient(90deg, #8B4513 0%, #CD853F 50%, #8B4513 100%);
    border-radius: 10px;
    position: relative;
    cursor: pointer;
    transition: transform 0.3s ease;
    box-shadow: 5px 5px 15px rgba(0, 0, 0, 0.5);
}

.lever:hover {
    transform: scale(1.05);
}

.lever.pulled {
    transform: rotate(30deg);
}

.lever-handle {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 100px;
    background: linear-gradient(90deg, #4a4a4a 0%, #8a8a8a 50%, #4a4a4a 100%);
    border-radius: 5px;
}

.lever-ball {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: radial-gradient(circle at 30% 30%, var(--red-main), var(--red-dark));
    border-radius: 50%;
    box-shadow: 0 0 15px var(--red-main), inset -5px -5px 10px rgba(0, 0, 0, 0.3);
}

/* Result Popup Display */
.result-display {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    animation: fadeIn 0.3s ease-out;
}

.result-display.show {
    display: flex;
}

.result-content {
    text-align: center;
    padding: 50px 80px;
    background: linear-gradient(135deg, #151515 0%, #000 100%);
    border: 2px solid var(--gold-main);
    border-radius: 30px;
    box-shadow: 0 0 50px rgba(255, 215, 0, 0.3);
    transform: scale(0.8);
    animation: popupScale 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes popupScale {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.result-icon {
    font-size: 4rem;
    margin-bottom: 15px;
    animation: bounce 1s ease-in-out infinite;
}

.result-code {
    font-family: 'Orbitron', sans-serif;
    font-size: 3.5rem;
    font-weight: 900;
    background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold-main) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 8px;
    margin-bottom: 10px;
    text-shadow: none;
    filter: drop-shadow(0 0 15px rgba(255, 215, 0, 0.8));
}

.result-prize {
    font-size: 1.5rem;
    color: var(--gold-light);
    font-weight: 700;
}

/* Control Panel */
.control-panel {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.spin-button,
.auto-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 40px;
    font-size: 1.1rem;
    font-weight: 700;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.spin-button::before,
.auto-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.spin-button:hover::before,
.auto-button:hover::before {
    left: 100%;
}

.spin-button {
    background: linear-gradient(135deg, #FFD700 0%, #F4A724 50%, #B8860B 100%);
    color: #000;
    box-shadow:
        0 4px 15px rgba(255, 215, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    border: 1px solid rgba(255, 215, 0, 0.5);
}

.spin-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 8px 25px rgba(255, 215, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.spin-button:active {
    transform: translateY(0);
}

.spin-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.auto-button {
    background: linear-gradient(135deg, #9B59B6 0%, #8E44AD 50%, #6C3483 100%);
    color: #fff;
    box-shadow:
        0 4px 15px rgba(155, 89, 182, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(155, 89, 182, 0.5);
}

.auto-button:hover {
    transform: translateY(-2px);
    box-shadow:
        0 8px 25px rgba(155, 89, 182, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.auto-button.active {
    background: linear-gradient(135deg, var(--red-main) 0%, var(--red-dark) 100%);
    animation: pulseButton 1s ease-in-out infinite;
}

@keyframes pulseButton {

    0%,
    100% {
        box-shadow: 0 10px 30px rgba(230, 57, 70, 0.4);
    }

    50% {
        box-shadow: 0 10px 40px rgba(230, 57, 70, 0.7);
    }
}

.button-icon {
    font-size: 1.5rem;
}

/* Progress Section */
.progress-section {
    margin-bottom: 15px;
    padding: 15px;
    background: rgba(15, 15, 15, 0.95);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.progress-stats {
    display: flex;
    align-items: baseline;
    gap: 5px;
    background: rgba(255, 215, 0, 0.1);
    padding: 10px 25px;
    border-radius: 30px;
    border: 1px solid var(--gold-dark);
}

.progress-current {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--gold-light);
    text-shadow: var(--glow-gold);
}

.progress-divider {
    font-size: 1.5rem;
    color: var(--gold-dark);
}

.progress-total {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-light);
}

.progress-label {
    font-size: 0.9rem;
    color: #888;
    margin-left: 10px;
}

/* Main Progress Bar */
.main-progress-container {
    margin-bottom: 15px;
    padding: 0 5px;
}

.main-progress-bar {
    position: relative;
    height: 12px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 6px;
    border: 1px solid var(--gold-dark);
    overflow: visible;
}

.main-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg,
            var(--gold-dark) 0%,
            var(--gold-main) 50%,
            var(--gold-light) 100%);
    border-radius: 8px;
    transition: width 0.5s ease-out;
    box-shadow: 0 0 20px rgba(255, 215, 0, 0.6);
    position: relative;
}

.main-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom,
            rgba(255, 255, 255, 0.3) 0%,
            transparent 50%,
            rgba(0, 0, 0, 0.2) 100%);
    border-radius: 8px;
}

.progress-milestones {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
}

.milestone {
    position: absolute;
    top: 50%;
    transform: translateX(-50%) translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.milestone-dot {
    width: 10px;
    height: 10px;
    background: var(--gold-main);
    border: 2px solid var(--bg-dark);
    border-radius: 50%;
    box-shadow: 0 0 5px var(--gold-light);
}

.milestone-label {
    position: absolute;
    top: 18px;
    white-space: nowrap;
    font-size: 0.65rem;
    color: #888;
    font-weight: 600;
}

/* Prize Progress Cards */
.prize-progress-cards {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
}

.prize-card {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 10px;
    padding: 10px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.prize-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--gold-main), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.prize-card:hover {
    transform: translateY(-3px);
    border-color: var(--gold-main);
}

.prize-card.active {
    border-color: var(--gold-light);
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.4);
    animation: cardPulse 2s ease-in-out infinite;
}

.prize-card.active::before {
    opacity: 1;
}

@keyframes cardPulse {

    0%,
    100% {
        box-shadow: 0 0 25px rgba(255, 215, 0, 0.4);
    }

    50% {
        box-shadow: 0 0 35px rgba(255, 215, 0, 0.6);
    }
}

.prize-card.completed {
    border-color: #28a745;
    background: rgba(40, 167, 69, 0.1);
}

.prize-card.completed::before {
    background: linear-gradient(90deg, transparent, #28a745, transparent);
    opacity: 1;
}

.prize-card.grand {
    border-color: rgba(255, 165, 0, 0.3);
}

.prize-card.jackpot {
    border-color: rgba(255, 215, 0, 0.5);
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1) 0%, rgba(0, 0, 0, 0.3) 100%);
}

.prize-card-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-bottom: 12px;
}

.prize-card-icon {
    font-size: 1.4rem;
}

.prize-card-name {
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-light);
}

/* Prize Amount - Hero Element */
.prize-card-amount-row {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 2px;
    padding: 8px 6px;
    margin-bottom: 8px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.12) 0%, rgba(255, 165, 0, 0.06) 100%);
    border-radius: 8px;
    border: 1px solid rgba(255, 215, 0, 0.15);
}

.prize-card-currency {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    color: var(--gold-main);
}

.prize-card-amount {
    font-family: 'Orbitron', sans-serif;
    font-weight: 900;
    font-size: 1.5rem;
    color: var(--gold-light);
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.5);
    line-height: 1;
}

/* Grand prize cards get bigger amounts */
.prize-card.grand .prize-card-amount {
    font-size: 1.6rem;
    text-shadow: 0 0 15px rgba(255, 215, 0, 0.6);
}

.prize-card.grand .prize-card-amount-row {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.18) 0%, rgba(255, 165, 0, 0.08) 100%);
    border-color: rgba(255, 215, 0, 0.25);
}

.prize-card.active .prize-card-amount-row {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.22) 0%, rgba(255, 165, 0, 0.12) 100%);
    border-color: rgba(255, 215, 0, 0.35);
    animation: amountPulse 2s ease-in-out infinite;
}

@keyframes amountPulse {

    0%,
    100% {
        box-shadow: 0 0 8px rgba(255, 215, 0, 0.15);
    }

    50% {
        box-shadow: 0 0 18px rgba(255, 215, 0, 0.3);
    }
}

.prize-card.completed .prize-card-amount-row {
    background: rgba(40, 167, 69, 0.1);
    border-color: rgba(40, 167, 69, 0.25);
}

.prize-card.completed .prize-card-amount,
.prize-card.completed .prize-card-currency {
    color: #5cb85c;
    text-shadow: 0 0 8px rgba(40, 167, 69, 0.4);
}

.prize-card-progress {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.prize-progress-bar {
    flex: 1;
    height: 8px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 4px;
    overflow: hidden;
}

.prize-progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--gold-dark), var(--gold-light));
    border-radius: 4px;
    transition: width 0.5s ease-out;
}

.prize-progress-text {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--gold-light);
    text-align: right;
}

.prize-card-status {
    font-size: 0.85rem;
    color: #888;
    text-align: center;
    padding: 5px 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
}

.prize-card.active .prize-card-status {
    color: var(--gold-light);
    background: rgba(255, 215, 0, 0.1);
}

.prize-card.completed .prize-card-status {
    color: #28a745;
    background: rgba(40, 167, 69, 0.1);
}

/* Winners Section */
.winners-section {
    margin-bottom: 15px;
    padding: 15px;
    background: rgba(15, 15, 15, 0.95);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
}

/* ── 4D Results Board ── */

/* Row 1: Top 3 grand prizes */
.board-grand-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 8px;
    margin-bottom: 12px;
}

.board-prize-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 16px 6px 12px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.1);
    background: rgba(0,0,0,0.3);
}

.board-first  { border-color: rgba(255,215,0,0.5); background: rgba(80,55,0,0.35); }
.board-second { border-color: rgba(192,192,192,0.5); background: rgba(50,50,60,0.35); }
.board-third  { border-color: rgba(205,127,50,0.5); background: rgba(60,35,10,0.35); }

.board-prize-label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    opacity: 0.75;
}
.board-first  .board-prize-label { color: #FFD700; }
.board-second .board-prize-label { color: #C8C8C8; }
.board-third  .board-prize-label { color: #CD7F32; }

.board-prize-amount {
    font-size: 0.65rem;
    opacity: 0.6;
    color: #aaa;
}

.board-grand-slot {
    font-family: 'Orbitron', monospace;
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: 0.12em;
    color: #fff;
    padding: 6px 4px 2px;
    min-width: 70px;
    text-align: center;
    border-bottom: 2px solid rgba(255,255,255,0.15);
    transition: color 0.3s;
}
.board-first  .board-grand-slot { color: #FFD700; text-shadow: 0 0 18px rgba(255,215,0,0.7); }
.board-second .board-grand-slot { color: #E8E8E8; text-shadow: 0 0 12px rgba(200,200,200,0.5); }
.board-third  .board-grand-slot { color: #E07A30; text-shadow: 0 0 12px rgba(205,127,50,0.5); }

.board-grand-slot.filled {
    animation: boardSlotIn 0.4s cubic-bezier(0.22,1,0.36,1);
}

/* Row 2 & 3: Special / Consolation */
.board-tier-row {
    margin-bottom: 10px;
    border: 1px solid rgba(80,150,255,0.2);
    border-radius: 10px;
    overflow: hidden;
}

.board-tier-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 6px 12px;
    background: rgba(20,50,130,0.5);
    border-bottom: 1px solid rgba(80,150,255,0.2);
}

.board-tier-name {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #7ec8ff;
}

.board-tier-amt {
    font-size: 0.65rem;
    color: #aac4e8;
    opacity: 0.8;
}

.board-numbers-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 4px;
    padding: 8px;
    background: rgba(5,15,50,0.4);
}

.board-num-slot {
    font-family: 'Orbitron', monospace;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-align: center;
    padding: 6px 2px;
    border-radius: 6px;
    color: rgba(180,210,255,0.35);
    background: rgba(10,25,70,0.5);
    border: 1px solid rgba(40,80,180,0.2);
    transition: all 0.3s;
}

.board-num-slot.filled {
    color: #fff;
    background: rgba(20,55,150,0.6);
    border-color: rgba(80,150,255,0.45);
    box-shadow: 0 0 10px rgba(80,150,255,0.25);
    animation: boardSlotIn 0.4s cubic-bezier(0.22,1,0.36,1);
}

@keyframes boardSlotIn {
    0%   { transform: scale(1.35); opacity: 0.4; }
    60%  { transform: scale(0.94); }
    100% { transform: scale(1);    opacity: 1; }
}

.section-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gold-light);
    margin-bottom: 12px;
    text-shadow: 0 0 10px rgba(255, 215, 0, 0.3);
}

.title-icon {
    font-size: 1.5rem;
    animation: swing 2s ease-in-out infinite;
}

@keyframes swing {

    0%,
    100% {
        transform: rotate(-10deg);
    }

    50% {
        transform: rotate(10deg);
    }
}

/* Winners Tabs */
.winners-tabs {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
}

.winner-tab {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 20px;
    color: #888;
    font-size: 0.8rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.winner-tab:hover {
    border-color: var(--gold-main);
    color: var(--text-light);
    background: rgba(255, 215, 0, 0.1);
}

.winner-tab.active {
    background: linear-gradient(135deg, var(--gold-main), var(--gold-dark));
    border-color: var(--gold-light);
    color: var(--bg-dark);
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.3);
}

.tab-icon {
    font-size: 1.1rem;
}

.tab-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 10px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 700;
}

.winner-tab.active .tab-count {
    background: rgba(0, 0, 0, 0.2);
}

/* Winners Container */
.winners-container {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 12px;
    max-height: 500px;
    overflow-y: auto;
}

.winners-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 12px;
}

/* Empty State */
.empty-winners {
    grid-column: 1 / -1;
    text-align: center;
    padding: 30px 15px;
    color: #666;
}

.empty-icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
    opacity: 0.5;
    animation: bounce 2s ease-in-out infinite;
}

.empty-text {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #888;
}

.empty-hint {
    font-size: 0.9rem;
    color: #666;
}

/* Winner Card */
.winner-card {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 15px 18px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.08) 0%, rgba(26, 26, 46, 0.95) 100%);
    border: 2px solid rgba(255, 215, 0, 0.15);
    border-radius: 12px;
    animation: fadeInSlide 0.5s ease-out;
    transition: all 0.3s ease;
}

.winner-card:hover {
    transform: translateY(-2px);
    border-color: var(--gold-main);
    box-shadow: 0 5px 25px rgba(255, 215, 0, 0.2);
}

.winner-card.highlight {
    animation: highlightCard 0.8s ease-out;
    border-color: var(--gold-light);
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.5);
}

@keyframes highlightCard {
    0% {
        transform: scale(0.8);
        opacity: 0;
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes fadeInSlide {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.winner-card .rank {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--gold-main), var(--gold-dark));
    border-radius: 50%;
    font-weight: 700;
    color: var(--bg-dark);
    font-size: 0.95rem;
    flex-shrink: 0;
}

.winner-card .rank.grand-rank {
    background: linear-gradient(135deg, #FFD700, #FF8C00);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.5);
    animation: pulseRank 1.5s ease-in-out infinite;
}

@keyframes pulseRank {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.winner-card .code {
    flex: 1;
    font-family: 'Orbitron', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--gold-light);
    letter-spacing: 2px;
}

.winner-card .prize-tag {
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.winner-card .prize-tag.consolation {
    background: linear-gradient(135deg, #5a6268, #3d4145);
    color: white;
}

.winner-card .prize-tag.special {
    background: linear-gradient(135deg, var(--purple-main), var(--purple-dark));
    color: white;
}

.winner-card .prize-tag.third {
    background: linear-gradient(135deg, #CD7F32, #8B4513);
    color: white;
}

.winner-card .prize-tag.second {
    background: linear-gradient(135deg, #C0C0C0, #A0A0A0);
    color: #333;
}

.winner-card .prize-tag.first {
    background: linear-gradient(135deg, var(--gold-light), var(--gold-main));
    color: #333;
    animation: firstPrizeGlow 1s ease-in-out infinite alternate;
}

.winner-card .winner-amount {
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--gold-light);
    text-shadow: 0 0 6px rgba(255, 215, 0, 0.3);
    white-space: nowrap;
}

@keyframes firstPrizeGlow {
    from {
        box-shadow: 0 0 5px var(--gold-light);
    }

    to {
        box-shadow: 0 0 15px var(--gold-light), 0 0 25px var(--gold-main);
    }
}



/* Celebration Overlay */
.celebration-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease-out;
}

.celebration-overlay.show {
    display: flex;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.celebration-content {
    text-align: center;
    animation: zoomIn 0.5s ease-out;
}

@keyframes zoomIn {
    from {
        opacity: 0;
        transform: scale(0.5);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fireworks {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.firework {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    animation: fireworkExplode 1s ease-out forwards;
}

@keyframes fireworkExplode {
    0% {
        transform: scale(0);
        opacity: 1;
    }

    50% {
        transform: scale(20);
        opacity: 0.8;
    }

    100% {
        transform: scale(30);
        opacity: 0;
    }
}

/* Firework Variations */
.firework.ring {
    background: transparent !important;
    border: 2px solid;
    animation: fireworkRing 1.2s ease-out forwards;
}

.firework.star {
    clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
    animation: fireworkExplode 1.5s ease-out forwards;
}

.firework.sparkle {
    animation: fireworkSparkle 1.5s ease-out forwards;
}

@keyframes fireworkRing {
    0% {
        transform: scale(0);
        opacity: 1;
        border-width: 2px;
    }

    50% {
        transform: scale(25);
        opacity: 0.8;
        border-width: 1px;
    }

    100% {
        transform: scale(40);
        opacity: 0;
        border-width: 0;
    }
}

@keyframes fireworkSparkle {
    0% {
        transform: scale(0) rotate(0deg);
        opacity: 1;
    }

    25% {
        opacity: 0.5;
    }

    50% {
        transform: scale(35) rotate(180deg);
        opacity: 1;
    }

    75% {
        opacity: 0.5;
    }

    100% {
        transform: scale(60) rotate(360deg);
        opacity: 0;
    }
}

.big-win-text {
    font-size: 3rem;
    font-weight: 900;
    color: var(--gold-light);
    text-shadow: var(--glow-gold);
    margin-bottom: 20px;
    animation: shake 0.5s ease-in-out infinite;
}

@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px) rotate(-1deg);
    }

    75% {
        transform: translateX(5px) rotate(1deg);
    }
}

.winner-code {
    font-family: 'Orbitron', sans-serif;
    font-size: 5rem;
    font-weight: 900;
    background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold-main) 50%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 10px;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 20px rgba(255, 215, 0, 0.8));
    animation: pulse 1s ease-in-out infinite;
}

.winner-prize {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-light);
    margin-bottom: 30px;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.5);
}

.close-celebration {
    padding: 15px 50px;
    font-size: 1.2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--gold-main), var(--gold-dark));
    color: var(--bg-dark);
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 10px 30px rgba(244, 167, 36, 0.4);
}

.close-celebration:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 40px rgba(244, 167, 36, 0.6);
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--gold-dark);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gold-main);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }

    .jackpot-amount {
        align-items: center;
    }

    .logo-text {
        font-size: 1.8rem;
    }

    .jackpot-amount .amount {
        font-size: 1.5rem;
    }

    .slot-machine-wrapper {
        flex-direction: column;
    }

    .lever-container {
        transform: rotate(-90deg);
    }

    .reel-wrapper {
        width: 50px;
        height: 70px;
    }

    .symbol {
        width: 50px;
        height: 70px;
        font-size: 1.8rem;
    }

    .control-panel {
        flex-direction: column;
        align-items: center;
    }

    .spin-button,
    .auto-button {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }

    .result-code {
        font-size: 2.5rem;
        letter-spacing: 5px;
    }

    .prize-tiers {
        padding: 15px;
    }

    .tier {
        padding: 15px 20px;
        min-width: 100px;
    }

    .big-win-text {
        font-size: 2rem;
    }

    .winner-code {
        font-size: 3rem;
        letter-spacing: 5px;
    }

    .winner-prize {
        font-size: 1.8rem;
    }
}

/* Final Grand Prize Animation */
.grand-prize-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 999;
}

.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    animation: confettiFall linear forwards;
}

@keyframes confettiFall {
    0% {
        transform: translateY(-100px) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(120vh) rotate(720deg);
        opacity: 0;
    }
}

/* ===== MOBILE RESPONSIVE STYLES ===== */

/* Tablet and below */
@media screen and (max-width: 768px) {
    .main-container {
        padding: 10px;
    }

    .header {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }

    .logo-container {
        flex-direction: column;
        gap: 8px;
    }

    .logo-text {
        font-size: 1.5rem;
    }

    .jackpot-amount .amount {
        font-size: 1.5rem;
    }


    .reels-container {
        gap: 5px;
    }

    .reel-wrapper {
        width: 45px;
        height: 70px;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .reel {
        width: 100%;
        height: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .symbol {
        font-size: 2rem;
        width: 100%;
        height: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        line-height: normal;
        padding: 0;
        margin: 0;
    }

    /* Prize Display */
    .prize-display {
        padding: 8px;
        margin-bottom: 5px;
    }

    .current-prize-type {
        flex-direction: row;
        justify-content: center;
        gap: 10px;
        padding: 8px 15px;
    }

    .prize-badge,
    .prize-name,
    .prize-count {
        font-size: 1.1rem;
    }

    /* Progress Section */
    .progress-section {
        padding: 15px;
    }

    .progress-header {
        flex-direction: column;
        gap: 10px;
    }

    .section-title {
        font-size: 1.2rem;
    }

    .prize-progress-cards {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 8px;
        padding-bottom: 6px;
    }

    .prize-card {
        min-width: 140px;
        flex-shrink: 0;
        scroll-snap-align: start;
    }

    .prize-card {
        padding: 10px;
    }

    .prize-card-name {
        font-size: 0.85rem;
    }

    .prize-card-icon {
        font-size: 1.2rem;
    }

    .prize-card-amount {
        font-size: 1.2rem;
    }

    .prize-card-amount-row {
        padding: 6px 4px;
    }

    /* Winners Section */
    .winners-section {
        padding: 15px;
    }

    .winners-tabs {
        flex-wrap: wrap;
        gap: 8px;
    }

    .winner-tab {
        padding: 8px 12px;
        font-size: 0.8rem;
        flex: 1 1 45%;
    }

    .winners-list {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .winner-card {
        padding: 12px;
    }

    .winner-code {
        font-size: 1rem;
    }

    /* Celebration Overlay */
    .celebration-content {
        padding: 20px 15px;
        width: 85%;
        border-radius: 20px;
    }

    .big-win-text {
        font-size: 1.5rem;
        margin-bottom: 10px;
    }

    .winner-code {
        font-size: 1.8rem;
        letter-spacing: 2px;
        margin-bottom: 15px;
    }

    .winner-prize {
        font-size: 1.1rem;
        margin-bottom: 20px;
    }

    /* Result Popup */
    .result-content {
        padding: 20px 30px;
        width: 85%;
        border-radius: 20px;
    }

    .result-icon {
        font-size: 2.5rem;
        margin-bottom: 10px;
    }

    .result-code {
        font-size: 1.8rem;
        letter-spacing: 3px;
    }

    .result-prize {
        font-size: 1.1rem;
    }
}

/* Mobile phones */
@media screen and (max-width: 480px) {
    .main-container {
        padding: 5px;
        overflow-x: hidden;
        max-width: 100vw;
        box-sizing: border-box;
    }

    .header {
        padding: 10px;
    }

    .logo-text {
        font-size: 1.4rem;
    }

    .jackpot-amount .label {
        font-size: 0.8rem;
    }

    .jackpot-amount .amount {
        font-size: 1.2rem;
    }

    /* Slot Machine - fit within viewport */
    .slot-machine-frame {
        padding: 15px 10px;
    }

    .light-ring {
        display: none;
    }

    .reels-container {
        padding: 10px;
        gap: 4px;
    }

    .reel-wrapper {
        width: 38px;
        height: 60px;
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .symbol {
        font-size: 1.6rem;
        width: 100%;
        height: 100%;
        display: flex;
        justify-content: center;
        align-items: center;
        line-height: normal;
    }

    /* Lever */
    .lever-container {
        display: none;
    }

    /* Prize Display Mobile */
    .prize-display {
        margin-bottom: 12px;
        max-width: 100%;
        overflow: hidden;
    }

    .current-prize-type {
        padding: 8px 12px;
        gap: 8px;
        border-radius: 40px;
        max-width: 100%;
        box-sizing: border-box;
        flex-wrap: wrap;
        justify-content: center;
    }

    .prize-badge {
        font-size: 0.75rem;
        padding: 4px 10px;
        height: 28px;
        white-space: nowrap;
    }

    .prize-name {
        font-size: 1.1rem;
        white-space: nowrap;
    }

    .prize-amount-container {
        padding: 4px 10px;
        min-width: 60px;
        border-radius: 8px;
    }

    .prize-amount {
        font-size: 1.1rem;
    }

    .prize-count-label {
        font-size: 0.6rem;
    }

    .prize-count-value {
        font-size: 1rem;
    }

    /* Control Panel */
    .control-panel {
        padding: 10px;
    }

    .spin-button,
    .auto-button {
        padding: 12px 20px;
        font-size: 0.9rem;
    }

    .button-icon {
        display: none;
    }

    /* Progress Section */
    .progress-section {
        padding: 10px;
        max-width: 100%;
        box-sizing: border-box;
        overflow: hidden;
    }

    .section-title {
        font-size: 1rem;
    }

    .title-icon {
        display: none;
    }

    .prize-progress-cards {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        -webkit-overflow-scrolling: touch;
        gap: 8px;
        padding-bottom: 6px;
    }

    .prize-progress-cards::-webkit-scrollbar {
        height: 3px;
    }

    .prize-progress-cards::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.05);
        border-radius: 3px;
    }

    .prize-progress-cards::-webkit-scrollbar-thumb {
        background: rgba(255, 215, 0, 0.3);
        border-radius: 3px;
    }

    .prize-card {
        min-width: 120px;
        flex-shrink: 0;
        scroll-snap-align: start;
        padding: 8px;
    }

    .prize-card-header {
        gap: 4px;
        margin-bottom: 4px;
    }

    .prize-card-name {
        font-size: 0.8rem;
    }

    .prize-card-icon {
        font-size: 1rem;
    }

    .prize-card-amount {
        font-size: 1.2rem;
    }

    .prize-card.grand .prize-card-amount {
        font-size: 1.3rem;
    }

    .prize-card-currency {
        font-size: 0.8rem;
    }

    .prize-card-amount-row {
        padding: 5px 3px;
        margin-bottom: 6px;
    }

    .prize-progress-text {
        font-size: 0.7rem;
    }

    .prize-card-status {
        font-size: 0.65rem;
    }

    /* Main Progress Bar */
    .main-progress-bar {
        height: 15px;
    }

    .milestone-label {
        font-size: 0.6rem;
    }

    .milestone-dot {
        width: 8px;
        height: 8px;
    }

    /* Winners Section */
    .winners-section {
        padding: 8px;
        max-width: 100%;
        box-sizing: border-box;
        overflow: hidden;
    }

    .winners-tabs {
        gap: 5px;
    }

    .winner-tab {
        padding: 5px 8px;
        font-size: 0.65rem;
    }

    .tab-icon {
        display: none;
    }

    .tab-count {
        padding: 1px 4px;
        font-size: 0.55rem;
    }

    .winner-card {
        padding: 10px;
        max-width: 100%;
        box-sizing: border-box;
        overflow: hidden;
    }

    .winner-code {
        font-size: 0.9rem;
        letter-spacing: 1px;
    }

    .winner-prize-type {
        font-size: 0.75rem;
    }

    /* Empty State */
    .empty-icon {
        font-size: 1.8rem;
    }

    .empty-text {
        font-size: 1rem;
    }

    .empty-hint {
        font-size: 0.8rem;
    }

    /* Celebration Overlay */
    .celebration-content {
        padding: 15px 10px;
        width: 85%;
        border-radius: 20px;
    }

    .big-win-text {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }

    .winner-code {
        font-size: 1.4rem;
        letter-spacing: 1px;
        margin-bottom: 10px;
    }

    .winner-prize {
        font-size: 0.9rem;
        margin-bottom: 15px;
    }

    /* Result Popup */
    .result-content {
        padding: 15px 20px;
        width: 85%;
        border-radius: 20px;
    }

    .result-icon {
        font-size: 2rem;
        margin-bottom: 8px;
    }

    .result-code {
        font-size: 1.4rem;
        letter-spacing: 2px;
    }

    .result-prize {
        font-size: 0.9rem;
    }

    .close-celebration {
        padding: 8px 25px;
        font-size: 0.9rem;
    }
}

/* Extra small phones */
@media screen and (max-width: 360px) {
    .current-prize-type {
        padding: 8px 12px;
        gap: 6px;
    }

    .prize-badge {
        font-size: 0.7rem;
        padding: 3px 8px;
    }

    .prize-name {
        font-size: 1rem;
    }

    .prize-amount-container {
        padding: 3px 8px;
        min-width: 70px;
    }

    .prize-amount {
        font-size: 1rem;
    }

    .slot-machine-wrapper {
        transform: scale(0.52);
        margin: -15px 0;
    }

    .reel-wrapper {
        width: 32px;
        height: 50px;
    }

    .symbol {
        font-size: 1.4rem;
    }

    .prize-progress-cards {
        grid-template-columns: 1fr;
    }

    .winner-tab {
        flex: 1 1 100%;
    }
}

/* Landscape mode on mobile */
@media screen and (max-height: 500px) and (orientation: landscape) {
    .slot-machine-wrapper {
        transform: scale(0.5);
        margin: -60px 0;
    }

    .header {
        padding: 5px 15px;
    }

    .progress-section,
    .winners-section {
        padding: 8px;
    }
}

/* ===== Waiting View Styles ===== */

.view-container {
    width: 100%;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.waiting-content {
    width: 90%;
    max-width: 800px;
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 40px;
    padding: 60px 40px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1s ease-out;
}

.logo-text.large {
    font-size: 3.5rem;
    margin-bottom: 40px;
    letter-spacing: 8px;
    background: linear-gradient(180deg, #fff 0%, #aaa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.waiting-jackpot {
    margin-bottom: 50px;
}

.waiting-label {
    display: block;
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.waiting-amount {
    font-size: 5rem;
    font-weight: 900;
    font-family: 'Orbitron', sans-serif;
    background: linear-gradient(180deg, var(--gold-light) 0%, var(--gold-main) 50%, var(--gold-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(244, 167, 36, 0.3);
    animation: pulseGlow 2s infinite alternate ease-in-out;
}

.countdown-container {
    position: relative;
    padding: 30px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.countdown-label {
    display: block;
    font-size: 1rem;
    color: var(--gold-main);
    margin-bottom: 15px;
    letter-spacing: 3px;
}

.countdown-timer {
    font-size: 4rem;
    font-weight: 700;
    font-family: 'Orbitron', sans-serif;
    color: #fff;
    letter-spacing: 5px;
    margin-bottom: 15px;
}

.countdown-target {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
}

@keyframes pulseGlow {
    from {
        filter: drop-shadow(0 0 10px rgba(244, 167, 36, 0.2));
        transform: scale(1);
    }

    to {
        filter: drop-shadow(0 0 25px rgba(244, 167, 36, 0.5));
        transform: scale(1.02);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive adjustments for Waiting View */
@media screen and (max-width: 768px) {
    .logo-text.large {
        font-size: 2.2rem;
        letter-spacing: 4px;
    }

    .waiting-amount {
        font-size: 3rem;
    }

    .countdown-timer {
        font-size: 2.5rem;
        letter-spacing: 2px;
    }

    .waiting-content {
        padding: 40px 20px;
    }
}

@media screen and (max-width: 480px) {
    .waiting-amount {
        font-size: 2.2rem;
    }

    .countdown-timer {
        font-size: 2rem;
    }
}

/* Countdown Overlay */
/* Countdown Overlay */
.countdown-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 100;
    border-radius: 12px;
    animation: fadeIn 0.3s ease-out;
}

.countdown-overlay.show {
    display: flex;
}

.countdown-content {
    text-align: center;
    background: transparent;
    padding: 0;
    width: auto;
    height: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    animation: pulse 1s infinite alternate;
}

.countdown-number {
    font-family: 'Orbitron', sans-serif;
    font-size: 5rem;
    font-weight: 900;
    color: var(--gold-light);
    text-shadow: 0 0 15px var(--gold-main), 0 0 30px var(--red-main);
    line-height: 1;
}

.countdown-text {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-top: 5px;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: 700;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.8);
}

/* Fairness Verification Entry Point */
.fairness-entry {
    margin: 30px auto;
    max-width: 600px;
    width: 100%;
    padding: 0 15px;
}

.verify-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 25px;
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 15px;
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s ease;
}

.verify-link:hover {
    background: rgba(255, 215, 0, 0.1);
    border-color: var(--gold-main);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.1);
}

.verify-icon {
    font-size: 1.5rem;
}

.verify-text {
    flex: 1;
    font-size: 1rem;
    font-weight: 500;
    color: var(--gold-light);
}

.verify-arrow {
    font-size: 1.2rem;
    color: var(--gold-dark);
    transition: transform 0.3s ease;
}

.verify-link:hover .verify-arrow {
    transform: translateX(5px);
    color: var(--gold-light);
}

@media screen and (max-width: 480px) {
    .verify-text {
        font-size: 0.9rem;
    }

    .verify-link {
        padding: 12px 18px;
    }
}

.fairness-verification {
    margin-top: 25px;
    padding-bottom: 30px;
    display: flex;
    justify-content: center;
    padding-left: 15px;
    padding-right: 15px;
}

.verify-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 20px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.08) 0%, rgba(0, 0, 0, 0.4) 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 16px;
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    width: 100%;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.verify-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 215, 0, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.verify-link:hover {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15) 0%, rgba(0, 0, 0, 0.5) 100%);
    border-color: var(--gold-main);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.15);
}

.verify-link:hover::before {
    transform: translateX(100%);
}

.verify-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.verify-icon {
    font-size: 1.4rem;
}

.verify-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.verify-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--gold-light);
    letter-spacing: 0.5px;
}

.verify-desc {
    font-size: 0.75rem;
    color: #888;
    font-weight: 400;
}

.verify-link:hover .verify-desc {
    color: #aaa;
}

.verify-action {
    display: flex;
    align-items: center;
    justify-content: center;
}

.verify-arrow {
    font-size: 1.2rem;
    color: var(--gold-dark);
    transition: transform 0.3s ease, color 0.3s ease;
}

.verify-link:hover .verify-arrow {
    transform: translateX(5px);
    color: var(--gold-light);
}

/* Navigation Actions Grid */
.nav-actions-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 15px;
    margin-top: 25px;
    padding-bottom: 30px;
    /* padding-left: 15px; */
    /* padding-right: 15px; */
}

@media screen and (max-width: 600px) {
    .nav-actions-grid {
        grid-template-columns: 1fr;
    }
}

/* Reusing verify-link styles for history-link with minor tweaks if needed */
.nav-link-card {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 20px;
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.08) 0%, rgba(0, 0, 0, 0.4) 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
    border-radius: 16px;
    text-decoration: none;
    color: var(--text-light);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.nav-link-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 215, 0, 0.1), transparent);
    transform: translateX(-100%);
    transition: transform 0.6s;
}

.nav-link-card:hover {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.15) 0%, rgba(0, 0, 0, 0.5) 100%);
    border-color: var(--gold-main);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.15);
}

.nav-link-card:hover::before {
    transform: translateX(100%);
}

.nav-icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    border: 1px solid rgba(255, 215, 0, 0.2);
}

.nav-icon {
    font-size: 1.4rem;
}
.nav-icon-svg {
    width: 22px;
    height: 22px;
    color: var(--gold-main);
    transition: color 0.3s ease, filter 0.3s ease;
}
.nav-arrow-svg {
    width: 16px;
    height: 16px;
    color: var(--gold-dark);
    transition: transform 0.3s ease, color 0.3s ease;
    flex-shrink: 0;
}
.nav-link-card:hover .nav-arrow-svg {
    transform: translateX(5px);
    color: var(--gold-light);
}

.nav-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.nav-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--gold-light);
    letter-spacing: 0.5px;
}

.nav-desc {
    font-size: 0.75rem;
    color: #888;
    font-weight: 400;
}

.nav-link-card:hover .nav-desc {
    color: #aaa;
}

.nav-arrow {
    font-size: 1.2rem;
    color: var(--gold-dark);
    transition: transform 0.3s ease, color 0.3s ease;
}

.nav-link-card:hover .nav-arrow {
    transform: translateX(5px);
    color: var(--gold-light);
}

/* Waiting View History Button */
/* Waiting View History Button */
.waiting-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 25px;
}

.history-btn-waiting {
    display: inline-block;
    padding: 10px 25px;
    border: 1px solid var(--gold-dark);
    border-radius: 30px;
    background: rgba(0, 0, 0, 0.4);
    color: var(--gold-light);
    text-decoration: none;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.history-btn-waiting:hover {
    background: rgba(255, 215, 0, 0.1);
    border-color: var(--gold-light);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
    transform: translateY(-2px);
}

/* Audio Control */
.audio-control-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background: rgba(20, 20, 20, 0.8);
    border: 2px solid var(--gold-main);
    color: var(--gold-light);
    padding: 10px 15px;
    border-radius: 30px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    z-index: 1000;
    backdrop-filter: blur(5px);
    transition: all 0.3s ease;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.audio-control-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.4);
}

.audio-icon {
    font-size: 1.2rem;
}

.audio-text {
    font-family: 'Orbitron', sans-serif;
    font-weight: bold;
    font-size: 0.9rem;
    text-transform: uppercase;
}

/* ===== LOTTERY BALL MACHINE (Realistic) ===== */

.lottery-machine-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.lottery-machine {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 420px;
}

/* Top cap */
.machine-top-cap {
    width: 100%;
    background: linear-gradient(180deg, #4a4a4a, #2d2d2d 60%, #1e1e1e);
    border: 1px solid #555;
    border-bottom: none;
    border-radius: 6px 6px 0 0;
    padding: 8px 16px;
    text-align: center;
}
.machine-brand-label {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.58rem;
    letter-spacing: 4px;
    color: rgba(255,255,255,0.32);
    text-transform: uppercase;
}

/* Chamber section */
.chamber-section {
    display: flex;
    width: 100%;
    justify-content: center;
}
.chamber-side-rail {
    width: 13px;
    background: linear-gradient(90deg, #1c1c1c, #3a3a3a 50%, #262626);
    border-top: 1px solid #555;
    border-bottom: 1px solid #444;
    flex-shrink: 0;
}
.chamber-section .chamber-side-rail:first-child { border-left: 1px solid #555; }
.chamber-section .chamber-side-rail:last-child  { border-right: 1px solid #555; }

/* Transparent cylinder */
.lottery-chamber {
    flex: 1;
    height: 300px;
    position: relative;
    background: rgba(4, 10, 28, 0.15);
    border-top: 1px solid #555;
    border-bottom: 1px solid #3a3a3a;
    overflow: hidden;
}
.chamber-glass-left {
    position: absolute;
    top: 0; left: 0;
    width: 16%; height: 100%;
    background: linear-gradient(90deg, rgba(255,255,255,0.04) 0%, transparent 100%);
    pointer-events: none;
    z-index: 5;
}
.chamber-glass-right {
    position: absolute;
    top: 0; right: 0;
    width: 7%; height: 100%;
    background: linear-gradient(270deg, rgba(255,255,255,0.015) 0%, transparent 100%);
    pointer-events: none;
    z-index: 5;
}
.balls-container {
    position: absolute;
    top: 0; left: 0; right: 0;
    bottom: 24px;
    overflow: hidden;
    /* 隔离布局/样式/绘制范围，防止球的位置更新向外传播触发全页重排 */
    contain: layout style paint;
}

/* Air nozzles */
.air-nozzle-row {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 24px;
    background: linear-gradient(180deg, #181818, #0e0e0e);
    border-top: 1px solid #383838;
    display: flex;
    align-items: center;
    justify-content: space-evenly;
    padding: 0 8px;
    z-index: 6;
}
.air-nozzle {
    width: 9px; height: 9px;
    background: radial-gradient(circle, #2e2e2e, #161616);
    border-radius: 50% 50% 2px 2px;
    border: 1px solid #383838;
    transition: all 0.15s;
}
.lottery-chamber.blowing .air-nozzle {
    animation: nozzleActive 0.22s ease-in-out infinite alternate;
}
@keyframes nozzleActive {
    from { background: radial-gradient(circle, #2a2a44, #141420); box-shadow: none; }
    to   { background: radial-gradient(circle, #4455aa, #1e1e44); box-shadow: 0 0 6px rgba(80,120,255,0.6), 0 -3px 8px rgba(80,150,255,0.3); }
}

/* Lottery balls inside chamber */
.lottery-ball {
    position: absolute;
    left: 0; top: 0;
    width: 34px; height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 0.82rem;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
    box-shadow:
        inset -4px -4px 8px rgba(0,0,0,0.5),
        inset 3px 3px 6px rgba(255,255,255,0.28),
        0 3px 8px rgba(0,0,0,0.6);
    user-select: none;
    pointer-events: none;
    z-index: 2;
    /* transform + opacity 均在 will-change 中 → 浏览器提前提升到 GPU 合成层
       两者变化时完全由合成器处理，CPU/绘图线程零参与 */
    will-change: transform, opacity;
    backface-visibility: hidden;
    /* opacity 由 JS 直接设 style.opacity，不走 CSS 变量（变量会触发级联重算） */
}
/* Fixed color per digit (0-9) — same digit = same color everywhere */
.lottery-ball.digit-0, .slot-ball.digit-0 { background: radial-gradient(circle at 36% 32%, #ff8888, #cc0000); } /* Red     */
.lottery-ball.digit-1, .slot-ball.digit-1 { background: radial-gradient(circle at 36% 32%, #ffaa66, #cc4400); } /* Orange  */
.lottery-ball.digit-2, .slot-ball.digit-2 { background: radial-gradient(circle at 36% 32%, #ffee55, #bb8800); } /* Yellow  */
.lottery-ball.digit-3, .slot-ball.digit-3 { background: radial-gradient(circle at 36% 32%, #77ee77, #007722); } /* Green   */
.lottery-ball.digit-4, .slot-ball.digit-4 { background: radial-gradient(circle at 36% 32%, #55ddcc, #007766); } /* Teal    */
.lottery-ball.digit-5, .slot-ball.digit-5 { background: radial-gradient(circle at 36% 32%, #66aaff, #0044cc); } /* Blue    */
.lottery-ball.digit-6, .slot-ball.digit-6 { background: radial-gradient(circle at 36% 32%, #bb88ff, #5500cc); } /* Purple  */
.lottery-ball.digit-7, .slot-ball.digit-7 { background: radial-gradient(circle at 36% 32%, #ff88cc, #cc0077); } /* Pink    */
.lottery-ball.digit-8, .slot-ball.digit-8 { background: radial-gradient(circle at 36% 32%, #cccccc, #777777); } /* Silver  */
.lottery-ball.digit-9, .slot-ball.digit-9 { background: radial-gradient(circle at 36% 32%, #ffdd44, #aa6600); } /* Gold    */

/* ===== OUTPUT TUBES SECTION ===== */

.output-tubes-section {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: #0f0f0f;
    border-left: 1px solid #3a3a3a;
    border-right: 1px solid #3a3a3a;
    box-sizing: border-box;
    padding-bottom: 14px;
}

/* Central exit pipe dropping from chamber floor */
.exit-pipe-wrapper {
    display: flex;
    justify-content: center;
    width: 100%;
}
.exit-pipe {
    width: 28px;
    height: 48px;
    position: relative;
    background: linear-gradient(90deg,
        rgba(140,190,255,0.07) 0%,
        rgba(180,220,255,0.16) 40%,
        rgba(180,220,255,0.16) 60%,
        rgba(140,190,255,0.06) 100%
    );
    border-left:  2px solid rgba(140,190,255,0.35);
    border-right: 2px solid rgba(140,190,255,0.35);
    overflow: hidden;
    transition: border-color 0.1s, box-shadow 0.1s;
}
.exit-pipe.active {
    border-color: rgba(220,240,255,0.9);
    box-shadow: 0 0 18px 4px rgba(var(--pipe-glow-rgb,140,200,255),0.55),
                inset 0 0 8px rgba(200,230,255,0.18);
    background: linear-gradient(90deg,
        rgba(140,190,255,0.20) 0%,
        rgba(210,235,255,0.42) 40%,
        rgba(210,235,255,0.42) 60%,
        rgba(140,190,255,0.18) 100%
    );
    animation: pipeFlash 0.18s ease-out;
}
/* Ball streak — moves down fast，top:0 锚定，走 translateY 动画 */
.exit-pipe.active::after {
    content: '';
    position: absolute;
    left: 3px; right: 3px;
    top: 0;
    height: 22px;
    border-radius: 50%;
    background: var(--ball-color, rgba(200,220,255,0.8));
    box-shadow: 0 0 10px 4px var(--ball-color, rgba(200,220,255,0.4));
    animation: ballThroughPipe 0.22s ease-in forwards;
}
/* Speed streak trail — 移除 filter:blur，改为纯 opacity 动画（GPU 合成） */
.exit-pipe.active::before {
    content: '';
    position: absolute;
    left: 6px; right: 6px;
    top: 0;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(180deg,
        rgba(255,255,255,0) 0%,
        var(--ball-color, rgba(200,230,255,0.5)) 40%,
        rgba(255,255,255,0) 100%
    );
    animation: ballThroughPipe 0.28s ease-in forwards;
}
/* pipeFlash 移除 filter:brightness，改为 opacity — 完全 GPU 合成，零重绘 */
@keyframes pipeFlash {
    0%   { opacity: 0.5; }
    100% { opacity: 1; }
}

/* Horizontal rail + pods row */
.rail-row {
    width: 100%;
    display: flex;
    justify-content: space-evenly;
    align-items: center;
    padding: 0 22px;
    box-sizing: border-box;
    position: relative;
}
.rail-track {
    position: absolute;
    left: 22px; right: 22px;
    height: 4px;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(90deg,
        rgba(140,190,255,0.08),
        rgba(180,220,255,0.22) 30%,
        rgba(180,220,255,0.22) 70%,
        rgba(140,190,255,0.08)
    );
    border-top: 1px solid rgba(140,190,255,0.25);
    border-bottom: 1px solid rgba(140,190,255,0.15);
}

/* Transparent tube pipe connecting chamber to pod */
.tube-pipe {
    width: 22px;
    height: 48px;
    position: relative;
    background: linear-gradient(
        90deg,
        rgba(140,190,255,0.07) 0%,
        rgba(180,220,255,0.13) 35%,
        rgba(180,220,255,0.13) 65%,
        rgba(140,190,255,0.05) 100%
    );
    border-left:  1px solid rgba(140,190,255,0.28);
    border-right: 1px solid rgba(140,190,255,0.28);
    overflow: hidden;
    transition: border-color 0.2s;
}
.tube-pipe.active {
    border-color: rgba(180,220,255,0.55);
    background: linear-gradient(
        90deg,
        rgba(140,190,255,0.12) 0%,
        rgba(200,230,255,0.22) 35%,
        rgba(200,230,255,0.22) 65%,
        rgba(140,190,255,0.1) 100%
    );
}
/* Ball silhouette rolling through pipe (neutral, color set dynamically via JS) */
.tube-pipe.active { border-color: rgba(200,220,255,0.55); }
.tube-pipe.active::after {
    content: '';
    position: absolute;
    left: 2px; right: 2px;
    top: 0; /* 锚定 top:0，用 transform:translateY 替代 top 动画 */
    height: 18px;
    border-radius: 50%;
    background: var(--ball-color, rgba(200,220,255,0.5));
    animation: ballThroughPipe 0.38s ease-in forwards;
}
/* top 属性动画每帧触发 layout，改为 transform:translateY — 纯 GPU 合成 */
@keyframes ballThroughPipe {
    0%   { transform: translateY(-22px); opacity: 1; }
    80%  { opacity: 0.85; }
    100% { transform: translateY(52px);  opacity: 0; }
}

/* Pod — where the ball rests after exiting tube */
.tube-pod {
    width: 54px; height: 54px;
    border-radius: 50%;
    background: rgba(6,10,22,0.85);
    border: 2px solid rgba(130,170,220,0.22);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 0 16px rgba(0,0,0,0.85);
    transition: border-color 0.3s;
    overflow: hidden;
    position: relative;
}
/* Dramatic spinning: pulsing border + rotating halo */
.tube-pod.spinning {
    animation: podWait 0.7s ease-in-out infinite;
    border-color: rgba(120,180,255,0.55) !important;
}
@keyframes podWait {
    0%   { box-shadow: inset 0 0 16px rgba(0,0,0,0.85), 0 0 0px rgba(80,160,255,0);
           border-color: rgba(80,160,255,0.35); }
    35%  { box-shadow: inset 0 0 12px rgba(0,0,0,0.7), 0 0 18px 5px rgba(80,160,255,0.5);
           border-color: rgba(180,220,255,0.8); }
    70%  { box-shadow: inset 0 0 16px rgba(0,0,0,0.85), 0 0 8px 2px rgba(80,140,255,0.25);
           border-color: rgba(100,170,255,0.5); }
    100% { box-shadow: inset 0 0 16px rgba(0,0,0,0.85), 0 0 0px rgba(80,160,255,0);
           border-color: rgba(80,160,255,0.35); }
}
.tube-pod.ball-revealed {
    border: none;
    background: transparent;
    box-shadow: none;
    overflow: visible;
}


/* Pod impact flash when ball lands */
@keyframes podImpact {
    0%   { box-shadow: 0 0 0 0 var(--pod-glow, rgba(255,200,80,0.9)),
                       inset 0 0 20px rgba(255,255,255,0.3);
           transform: scale(1.22); }
    40%  { box-shadow: 0 0 40px 16px var(--pod-glow, rgba(255,200,80,0)),
                       inset 0 0 0px rgba(255,255,255,0);
           transform: scale(1.06); }
    100% { box-shadow: none; transform: scale(1); }
}
.tube-pod.ball-impact {
    animation: podImpact 0.65s cubic-bezier(0.22,1,0.36,1) forwards !important;
}

/* Ball sitting in pod after draw */
.slot-ball {
    width: 54px; height: 54px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', sans-serif;
    font-weight: 700;
    font-size: 1.45rem;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.9);
    box-shadow:
        inset -5px -5px 10px rgba(0,0,0,0.5),
        inset 4px 4px 8px rgba(255,255,255,0.28),
        0 4px 12px rgba(0,0,0,0.7);
    animation: ballSettle 0.25s ease-out;
}
/* ballSettle 移除 filter:brightness — filter 触发合成层重绘，改用 opacity */
@keyframes ballSettle {
    0%   { transform: scale(1.5) translateY(-8px); opacity: 0.7; }
    45%  { transform: scale(0.92) translateY(2px); opacity: 0.92; }
    70%  { transform: scale(1.08) translateY(0);   opacity: 1; }
    100% { transform: scale(1)    translateY(0);   opacity: 1; }
}

/* Per-ball highlight: settle then glow → fade */
@keyframes ballShine {
    0%   { box-shadow: inset -5px -5px 10px rgba(0,0,0,0.5),
                       inset 4px 4px 8px rgba(255,255,255,0.5),
                       0 0 28px 10px rgba(255,255,255,0.7),
                       0 4px 12px rgba(0,0,0,0.6); }
    40%  { box-shadow: inset -5px -5px 10px rgba(0,0,0,0.5),
                       inset 4px 4px 8px rgba(255,255,255,0.35),
                       0 0 16px 6px rgba(255,255,255,0.35),
                       0 4px 12px rgba(0,0,0,0.65); }
    100% { box-shadow: inset -5px -5px 10px rgba(0,0,0,0.5),
                       inset 4px 4px 8px rgba(255,255,255,0.28),
                       0 4px 12px rgba(0,0,0,0.7); }
}
.slot-ball.ball-shine {
    /* settle first, then shine fades over 2s */
    animation: ballSettle 0.3s ease-out,
               ballShine  2s   0.28s ease-out forwards;
}

/* Ball wall-collision squish */
@keyframes squishH {
    0%   { transform: var(--ball-pos) scaleX(var(--sq-a, 0.65)) scaleY(var(--sq-b, 1.25)); }
    55%  { transform: var(--ball-pos) scaleX(calc(1 + (var(--sq-b, 1.25) - 1) * 0.25)) scaleY(calc(1 - (var(--sq-b, 1.25) - 1) * 0.2)); }
    100% { transform: var(--ball-pos) scaleX(1) scaleY(1); }
}
@keyframes squishV {
    0%   { transform: var(--ball-pos) scaleX(var(--sq-b, 1.25)) scaleY(var(--sq-a, 0.65)); }
    55%  { transform: var(--ball-pos) scaleX(calc(1 - (var(--sq-b, 1.25) - 1) * 0.2)) scaleY(calc(1 + (var(--sq-b, 1.25) - 1) * 0.25)); }
    100% { transform: var(--ball-pos) scaleX(1) scaleY(1); }
}
.lottery-ball.squish-h { animation: squishH 0.2s ease-out forwards; }
.lottery-ball.squish-v { animation: squishV 0.2s ease-out forwards; }

/* Wall collision ripple */
/* Ball impact flash — intensity driven by --flash-brightness */
@keyframes impactFlash {
    0%   { filter: brightness(var(--flash-brightness, 2.5)) saturate(0.3); }
    40%  { filter: brightness(calc(var(--flash-brightness, 2.5) * 0.55)) saturate(1.1); }
    100% { filter: brightness(1) saturate(1); }
}
.lottery-ball.impact {
    animation: impactFlash 0.2s ease-out forwards;
}

/* Wind glow — 开奖时改为静态 box-shadow，避免每帧重绘 40 个球 */
/* 动画 box-shadow 会强制每帧对所有球重绘，移动端极耗性能 */
.lottery-chamber.blowing .lottery-ball {
    box-shadow:
        inset -4px -4px 8px rgba(0,0,0,0.45),
        inset 3px 3px 6px rgba(255,255,255,0.32),
        0 3px 8px rgba(0,0,0,0.55),
        0 0 8px rgba(180,220,255,0.35);
    transition: box-shadow 0.4s ease;
}

/* Base bar */
.machine-base-bar {
    width: 100%;
    height: 10px;
    background: linear-gradient(180deg, #1e1e1e, #141414);
    border: 1px solid #383838;
    border-top: none;
}

/* Stand legs */
.machine-stand-legs {
    display: flex;
    justify-content: space-between;
    width: 62%;
}
.machine-leg {
    width: 22px; height: 26px;
    background: linear-gradient(90deg, #1e1e1e, #404040, #242424);
    border: 1px solid #383838;
    border-top: none;
    border-radius: 0 0 5px 5px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.5);
}

/* Responsive */
@media screen and (max-width: 768px) {
    .lottery-machine { width: 360px; }
    .lottery-chamber { height: 250px; }
    .tube-pod  { width: 48px; height: 48px; }
    .slot-ball { width: 48px; height: 48px; font-size: 1.25rem; }
    .output-tubes-section { padding: 0 18px; }
    .tube-pipe { height: 40px; }
}
@media screen and (max-width: 480px) {
    .lottery-machine { width: 300px; }
    .lottery-chamber { height: 220px; }
    .tube-pod  { width: 42px; height: 42px; }
    .slot-ball { width: 42px; height: 42px; font-size: 1.1rem; }
    .output-tubes-section { padding: 0 12px; }
    .tube-pipe { height: 34px; width: 18px; }
}


/* =====================================================
   BLUE THEME OVERRIDES — Glass Sphere Lottery Machine
   ===================================================== */

/* ── CSS Variables: Deep Navy Blue ── */
:root {
    --blue-light: #7ec8ff;
    --blue-main: #1a7aff;
    --blue-dark: #0a3b8c;
    --blue-deep: #050d1e;
    --glass-border: rgba(100, 180, 255, 0.55);
    --glass-glow: rgba(60, 130, 255, 0.30);
}

/* ── Body background ── */
body {
    background: radial-gradient(ellipse at top, #0d2d7a 0%, #0a1e4a 40%, #050d1e 100%) fixed !important;
}

/* ── Logo ── */
.logo-text {
    background: linear-gradient(180deg, #fff 0%, #7ec8ff 50%, #1a7aff 100%) !important;
    -webkit-background-clip: text !important;
    background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    filter: drop-shadow(0 0 14px rgba(80,150,255,0.7)) !important;
}
.header { background: transparent !important; border: none !important; box-shadow: none !important; padding: 0 !important; }
.logo-container { display: none !important; }
.online-text { color: var(--blue-light) !important; }

/* ── Prize Display Banner ── */
.current-prize-type {
    background: linear-gradient(135deg, rgba(8,30,80,0.95) 0%, rgba(14,45,120,0.95) 100%) !important;
    border: 1px solid rgba(80,150,255,0.45) !important;
    box-shadow: 0 0 28px rgba(30,100,255,0.18), inset 0 0 20px rgba(0,0,0,0.5) !important;
}
.prize-name { color: #fff !important; text-shadow: 0 0 12px rgba(120,180,255,0.6) !important; }

/* ── Progress & Winners sections ── */
.progress-section,
.winners-section {
    background: linear-gradient(135deg, rgba(8,25,70,0.92) 0%, rgba(12,35,95,0.92) 100%) !important;
    border: 1px solid rgba(80,150,255,0.22) !important;
    box-shadow: 0 5px 25px rgba(0,20,80,0.5) !important;
    border-radius: 14px;
}
.section-title { color: #c8e0ff !important; font-family: 'Orbitron', sans-serif; letter-spacing: 2px; }
.progress-stats { background: rgba(20,60,160,0.25) !important; border: 1px solid rgba(80,150,255,0.25) !important; }
.progress-current { color: var(--blue-light) !important; }
.progress-divider { color: rgba(80,150,255,0.5) !important; }
.prize-progress-fill,
.main-progress-fill {
    background: linear-gradient(90deg, #0a3b8c 0%, #1a7aff 60%, #7ec8ff 100%) !important;
    box-shadow: 0 0 12px rgba(80,150,255,0.5) !important;
}
.main-progress-bar { border: 1px solid rgba(80,150,255,0.2) !important; }
.milestone-dot { background: var(--blue-main) !important; box-shadow: 0 0 5px var(--blue-light) !important; }
.prize-progress-text { color: rgba(160,200,255,0.7) !important; }

/* Prize cards */
.prize-card {
    background: rgba(8,25,72,0.7) !important;
    border: 1px solid rgba(60,120,220,0.22) !important;
}
.prize-card.grand { border-color: rgba(80,150,255,0.32) !important; }
.prize-card.active { border-color: var(--blue-light) !important; box-shadow: 0 0 22px rgba(80,150,255,0.35) !important; }
.prize-card.completed { border-color: #28a745 !important; background: rgba(20,70,35,0.25) !important; }
.prize-card-amount-row {
    background: linear-gradient(135deg, rgba(20,60,160,0.18) 0%, rgba(10,30,100,0.10) 100%) !important;
    border: 1px solid rgba(80,150,255,0.15) !important;
}
.prize-card-currency { color: var(--blue-light) !important; }
.prize-card-amount { color: #e8f4ff !important; text-shadow: 0 0 10px rgba(80,180,255,0.4) !important; }
.prize-card-status { color: rgba(150,200,255,0.6) !important; font-size: 0.7rem; font-weight: 600; }
@keyframes cardPulse {
    0%, 100% { box-shadow: 0 0 22px rgba(80,150,255,0.35); }
    50%       { box-shadow: 0 0 35px rgba(80,150,255,0.55); }
}

/* Board theme overrides */
.board-tier-row { border-color: rgba(80,150,255,0.25) !important; }
.board-tier-header { background: rgba(15,40,110,0.6) !important; }
.board-num-slot.filled { background: rgba(20,55,150,0.7) !important; border-color: rgba(80,150,255,0.5) !important; box-shadow: 0 0 12px rgba(80,150,255,0.3) !important; }

/* Nav cards */
.nav-link-card {
    background: linear-gradient(135deg, rgba(20,60,160,0.14) 0%, rgba(5,15,55,0.5) 100%) !important;
    border: 1px solid rgba(80,150,255,0.22) !important;
}
.nav-link-card::before { background: linear-gradient(90deg, transparent, rgba(80,150,255,0.10), transparent) !important; }
.nav-link-card:hover { background: linear-gradient(135deg, rgba(30,80,200,0.20) 0%, rgba(5,15,55,0.6) 100%) !important; border-color: var(--blue-main) !important; }
.nav-icon-box { background: rgba(10,30,90,0.5) !important; border: 1px solid rgba(80,150,255,0.18) !important; }
.nav-title { color: var(--blue-light) !important; }
.nav-arrow { color: rgba(80,150,255,0.6) !important; }
.nav-link-card:hover .nav-arrow { color: var(--blue-light) !important; }
.nav-icon-svg { color: var(--blue-light) !important; filter: drop-shadow(0 0 5px rgba(80,150,255,0.5)); }
.nav-link-card:hover .nav-icon-svg { filter: drop-shadow(0 0 10px rgba(80,180,255,0.8)); }
.nav-arrow-svg { color: rgba(80,150,255,0.5) !important; }
.nav-link-card:hover .nav-arrow-svg { color: var(--blue-light) !important; }
/* Waiting small buttons */
.history-btn-waiting { display: inline-flex !important; align-items: center !important; gap: 6px !important; }
.history-btn-waiting svg { flex-shrink: 0; }

/* Waiting view */
.waiting-content { background: rgba(5,15,50,0.6) !important; border: 1px solid rgba(80,150,255,0.18) !important; }
.logo-text.large { background: linear-gradient(180deg, #fff 0%, #7ec8ff 100%) !important; -webkit-background-clip: text !important; background-clip: text !important; -webkit-text-fill-color: transparent !important; }
.countdown-container { background: rgba(5,15,55,0.5) !important; border: 1px solid rgba(80,150,255,0.22) !important; }
.countdown-label { color: var(--blue-light) !important; }
.history-btn-waiting { border-color: rgba(80,150,255,0.38) !important; background: rgba(5,15,55,0.5) !important; color: var(--blue-light) !important; }
.history-btn-waiting:hover { background: rgba(20,60,160,0.22) !important; border-color: var(--blue-light) !important; }

/* Audio btn */
.audio-control-btn { background: rgba(8,25,72,0.85) !important; border-color: rgba(80,150,255,0.45) !important; color: var(--blue-light) !important; }

/* Scrollbar */
::-webkit-scrollbar-thumb { background: var(--blue-dark) !important; }
::-webkit-scrollbar-thumb:hover { background: var(--blue-main) !important; }

/* Result overlay */
.result-display { background: rgba(0,5,30,0.88) !important; }
.result-content { background: linear-gradient(135deg, rgba(8,30,90,0.98) 0%, rgba(4,12,50,0.98) 100%) !important; border: 2px solid rgba(80,150,255,0.45) !important; box-shadow: 0 0 60px rgba(30,100,255,0.3) !important; }
.result-code { background: linear-gradient(180deg, #fff 0%, #7ec8ff 50%, #1a7aff 100%) !important; -webkit-background-clip: text !important; background-clip: text !important; -webkit-text-fill-color: transparent !important; filter: drop-shadow(0 0 15px rgba(80,150,255,0.8)) !important; }
.result-prize { color: var(--blue-light) !important; }

/* Pod ball highlight after draw result */
@keyframes ballHighlight {
    0%   { box-shadow: 0 0 0 0 rgba(120,200,255,0.9); transform: scale(1.12); }
    50%  { box-shadow: 0 0 28px 10px rgba(80,160,255,0.5); transform: scale(1.04); }
    100% { box-shadow: 0 0 12px 4px rgba(80,160,255,0.25); transform: scale(1); }
}
@keyframes ballHighlightGrand {
    0%   { box-shadow: 0 0 0 0 rgba(255,210,60,1); transform: scale(1.18); filter: brightness(1.6); }
    40%  { box-shadow: 0 0 40px 16px rgba(255,160,0,0.55); transform: scale(1.05); filter: brightness(1.2); }
    100% { box-shadow: 0 0 18px 6px rgba(255,180,0,0.35); transform: scale(1); filter: brightness(1); }
}
.tube-pod.result-highlight .slot-ball {
    animation: ballHighlight 0.5s ease-out forwards !important;
}
.tube-pod.result-highlight-grand .slot-ball {
    animation: ballHighlightGrand 0.55s ease-out forwards !important;
}

/* Countdown overlay inside sphere */
.countdown-overlay { background: rgba(0,5,30,0.65) !important; border-radius: 50% !important; }
.countdown-number { font-size: 5rem; text-shadow: 0 0 15px rgba(120,180,255,0.8), 0 0 30px rgba(30,100,255,0.4) !important; color: var(--blue-light) !important; }
.countdown-text { color: rgba(200,220,255,0.9) !important; }

/* =====================================================
   GLASS SPHERE MACHINE
   ===================================================== */

/* Machine wrapper — wide enough for deco elements */
.lottery-machine-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 20px 60px;
    overflow: visible !important;
    margin-bottom: 10px;
}

/* Lottery machine column */
.lottery-machine {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 340px;
    position: relative;
    z-index: 2;
}

/* ── Sphere top mount cap ── */
.sphere-mount-top {
    width: 56px;
    height: 20px;
    background: linear-gradient(180deg, #1a4db0 0%, #0e2f7a 100%);
    border: 1px solid rgba(100,170,255,0.45);
    border-bottom: none;
    border-radius: 10px 10px 0 0;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 -4px 12px rgba(30,80,200,0.2);
    z-index: 3;
}
.sphere-mount-top .machine-brand-label {
    font-family: 'Orbitron', sans-serif;
    font-size: 0.36rem;
    letter-spacing: 2px;
    color: rgba(150,200,255,0.7);
    text-transform: uppercase;
    white-space: nowrap;
}

/* ── GLASS SPHERE CHAMBER ── */
.lottery-chamber {
    /* Perfect circle */
    width: 340px !important;
    height: 340px !important;
    flex: none !important;
    border-radius: 50% !important;
    overflow: hidden;
    position: relative;

    /* Glass background */
    background: radial-gradient(circle at 36% 30%,
        rgba(140,210,255,0.22) 0%,
        rgba(60,120,220,0.12) 35%,
        rgba(10,40,120,0.28) 70%,
        rgba(4,12,60,0.50) 100%) !important;

    /* Border: blue ring with glow */
    border: 3px solid rgba(100,180,255,0.60) !important;

    /* Multi-layer sphere depth */
    box-shadow:
        /* Outer ring aura */
        0 0 0 6px rgba(60,130,255,0.15),
        0 0 0 12px rgba(40,100,220,0.08),
        /* Ambient outer glow */
        0 0 55px rgba(60,130,255,0.35),
        0 0 110px rgba(30,80,200,0.18),
        /* Inner bottom shadow */
        inset 0 -40px 70px rgba(0,8,50,0.50),
        /* Inner top subtle blue */
        inset 0 15px 40px rgba(80,150,255,0.10) !important;
}

/* Primary glass highlight — large soft blob top-left */
.lottery-chamber::before {
    content: '';
    position: absolute;
    top: 6%;
    left: 8%;
    width: 42%;
    height: 30%;
    background: radial-gradient(ellipse at 40% 40%,
        rgba(255,255,255,0.65) 0%,
        rgba(220,240,255,0.30) 45%,
        transparent 80%);
    border-radius: 50%;
    filter: blur(7px);
    pointer-events: none;
    z-index: 20;
}

/* Secondary sharp specular dot */
.lottery-chamber::after {
    content: '';
    position: absolute;
    top: 11%;
    left: 17%;
    width: 12%;
    height: 9%;
    background: radial-gradient(ellipse,
        rgba(255,255,255,0.85) 0%,
        rgba(255,255,255,0.45) 55%,
        transparent 100%);
    border-radius: 50%;
    filter: blur(2px);
    pointer-events: none;
    z-index: 21;
}

/* Air nozzle row — hidden inside sphere, kept for JS .blowing class */
.air-nozzle-row {
    display: none !important;
}

/* Balls fill the full sphere */
.balls-container {
    bottom: 0 !important;
}

/* ── Central hub mechanism ── */
.sphere-hub {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 3;
    pointer-events: none;
    will-change: transform;
}
.hub-spoke {
    position: absolute;
    top: 50%;
    left: 50%;
    background: rgba(100,170,255,0.18);
    border-radius: 2px;
    transform-origin: center;
}
.hub-spoke.spoke-h {
    width: 100px; height: 2px;
    transform: translate(-50%, -50%);
}
.hub-spoke.spoke-v {
    width: 2px; height: 100px;
    transform: translate(-50%, -50%);
}
.hub-spoke.spoke-d1 {
    width: 90px; height: 2px;
    transform: translate(-50%, -50%) rotate(45deg);
}
.hub-spoke.spoke-d2 {
    width: 90px; height: 2px;
    transform: translate(-50%, -50%) rotate(-45deg);
}
.hub-center {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    width: 22px; height: 22px;
    background: radial-gradient(circle at 35% 35%,
        rgba(200,235,255,0.95) 0%,
        rgba(100,180,255,0.80) 45%,
        rgba(30,90,220,0.60) 100%);
    border-radius: 50%;
    border: 1px solid rgba(200,230,255,0.7);
    box-shadow:
        0 0 14px rgba(80,160,255,0.9),
        0 0 28px rgba(50,130,255,0.5),
        inset 0 2px 4px rgba(255,255,255,0.5);
}
@keyframes hubSpin {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to   { transform: translate(-50%, -50%) rotate(360deg); }
}

/* ── Sphere bottom neck ── */
.sphere-neck-bottom {
    width: 70px;
    height: 14px;
    background: linear-gradient(180deg, rgba(20,60,170,0.95) 0%, rgba(12,38,110,0.95) 100%);
    border: 1px solid rgba(80,160,255,0.35);
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 10px rgba(0,12,60,0.45);
    z-index: 3;
}

/* ── Base platform ── */
.sphere-base-platform {
    width: 100%;
    background: linear-gradient(180deg,
        rgba(10,32,100,0.96) 0%,
        rgba(6,20,72,0.98) 100%);
    border: 1px solid rgba(80,160,255,0.28);
    border-top: none;
    border-radius: 0 0 16px 16px;
    padding: 10px 20px 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow:
        0 8px 25px rgba(0,10,60,0.6),
        inset 0 1px 0 rgba(100,160,255,0.12);
}
.base-decor-lights {
    display: flex;
    gap: 10px;
    align-items: center;
}
.base-light {
    display: inline-block;
    width: 8px; height: 8px;
    border-radius: 50%;
    background: rgba(80,160,255,0.5);
    box-shadow: 0 0 6px rgba(80,160,255,0.6);
    animation: baseLightBlink 1.8s ease-in-out infinite;
}
.base-light:nth-child(2) { animation-delay: 0.6s; }
.base-light:nth-child(3) { animation-delay: 1.2s; }
@keyframes baseLightBlink {
    0%, 100% { opacity: 0.4; }
    50%       { opacity: 1; box-shadow: 0 0 10px rgba(80,160,255,0.9); }
}

/* ── Output tubes section (result pods) ── */
.output-tubes-section {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    background: linear-gradient(180deg,
        rgba(6,18,65,0.96) 0%,
        rgba(4,12,48,0.98) 100%) !important;
    border: 1px solid rgba(60,130,220,0.20) !important;
    border-top: none !important;
    border-radius: 0 0 20px 20px;
    padding-bottom: 16px;
    box-shadow: 0 8px 24px rgba(0,8,50,0.55);
}

/* Exit pipe — blue tint override */
.exit-pipe {
    background: linear-gradient(90deg,
        rgba(50,120,255,0.05) 0%,
        rgba(100,170,255,0.14) 40%,
        rgba(100,170,255,0.14) 60%,
        rgba(50,120,255,0.04) 100%) !important;
    border-left:  2px solid rgba(80,160,255,0.40) !important;
    border-right: 2px solid rgba(80,160,255,0.40) !important;
}
.exit-pipe.active {
    border-color: rgba(200,230,255,0.95) !important;
    box-shadow: 0 0 22px 6px rgba(80,160,255,0.65),
                inset 0 0 10px rgba(140,200,255,0.22) !important;
    animation: pipeFlash 0.18s ease-out !important;
}

.rail-track {
    background: linear-gradient(90deg,
        rgba(50,120,255,0.05),
        rgba(100,170,255,0.25) 30%,
        rgba(100,170,255,0.25) 70%,
        rgba(50,120,255,0.05)) !important;
    border-top: 1px solid rgba(80,160,255,0.28) !important;
    border-bottom: 1px solid rgba(60,130,220,0.16) !important;
}

/* Tube pods — blue tint */
.tube-pod {
    width: 62px !important; height: 62px !important;
    background: rgba(4,14,50,0.92) !important;
    border: 2px solid rgba(60,140,240,0.32) !important;
    box-shadow:
        inset 0 0 20px rgba(0,5,40,0.92),
        0 0 10px rgba(40,100,220,0.10) !important;
}
.tube-pod.ball-revealed { border: none !important; background: transparent !important; box-shadow: none !important; overflow: visible !important; }
/* Allow ball-impact animation to override box-shadow */
.tube-pod.ball-impact { animation: podImpact 0.65s cubic-bezier(0.22,1,0.36,1) forwards !important; }

/* Slot ball in pod */
.slot-ball {
    width: 62px !important; height: 62px !important;
    font-size: 1.6rem !important;
    box-shadow:
        inset -6px -6px 12px rgba(0,0,0,0.55),
        inset 5px 5px 10px rgba(255,255,255,0.32),
        0 6px 22px rgba(0,0,0,0.65),
        0 0 18px rgba(80,150,255,0.15) !important;
}

/* ── Floating decorations ── */
.machine-decor {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    pointer-events: none;
    z-index: 1;
}

/* Sparkle stars around sphere */
.deco-spark {
    position: absolute;
    font-weight: 900;
    line-height: 1;
    pointer-events: none;
    animation: sparkTwinkle 2s ease-in-out infinite;
    user-select: none;
}
/* ✦ gold stars */
.spark-1 { top:  8%; left:  7%; font-size: 1.3rem; color: #FFD700; animation-delay: 0s;   text-shadow: 0 0 8px rgba(255,215,0,0.7); }
.spark-2 { top:  6%; right: 8%; font-size: 1.1rem; color: #FFE066; animation-delay: 0.5s; text-shadow: 0 0 8px rgba(255,215,0,0.6); }
.spark-3 { top: 35%; left:  3%; font-size: 0.8rem; color: #FFFFFF; animation-delay: 0.9s; text-shadow: 0 0 6px rgba(180,220,255,0.9); }
.spark-4 { top: 30%; right: 4%; font-size: 0.8rem; color: #c8e8ff; animation-delay: 1.4s; text-shadow: 0 0 6px rgba(120,200,255,0.8); }
.spark-5 { top: 60%; left:  5%; font-size: 0.7rem; color: #FFD700; animation-delay: 1.0s; text-shadow: 0 0 6px rgba(255,215,0,0.6); }
.spark-6 { top: 62%; right: 5%; font-size: 0.7rem; color: #ffffff; animation-delay: 1.8s; text-shadow: 0 0 6px rgba(180,220,255,0.9); }

@keyframes sparkTwinkle {
    0%, 100% { opacity: 0.25; transform: scale(0.75) rotate(-10deg); }
    50%       { opacity: 1.00; transform: scale(1.30) rotate(10deg); }
}

/* ── Result row: pipe/rail removed, 4 large balls ── */
.output-tubes-section {
    background: transparent !important;
    border: none !important;
    padding: 18px 0 4px !important;
}
.rail-row {
    justify-content: center !important;
    gap: 16px !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
    position: static !important;
}
.tube-pod {
    width: 76px !important;
    height: 76px !important;
    background: rgba(4, 10, 40, 0.65) !important;
    border: 2px solid rgba(80, 130, 255, 0.25) !important;
    box-shadow: 0 0 24px rgba(30, 70, 200, 0.18),
                inset 0 0 20px rgba(0, 0, 40, 0.85) !important;
}
.slot-ball {
    width: 76px !important;
    height: 76px !important;
    font-size: 2rem !important;
    box-shadow:
        inset -6px -6px 14px rgba(0,0,0,0.5),
        inset 5px 5px 10px rgba(255,255,255,0.32),
        0 0 0 3px rgba(255,200,50,0.75),
        0 0 22px rgba(255,175,30,0.45),
        0 6px 18px rgba(0,0,0,0.7) !important;
}

/* ── Match slot-ball/lottery-ball digit colors to PIXI palette ── */
.lottery-ball.digit-0, .slot-ball.digit-0 { background: radial-gradient(circle at 36% 32%, #ff7070, #aa1818) !important; }
.lottery-ball.digit-1, .slot-ball.digit-1 { background: radial-gradient(circle at 36% 32%, #60c8ff, #1260b0) !important; }
.lottery-ball.digit-2, .slot-ball.digit-2 { background: radial-gradient(circle at 36% 32%, #60e090, #157740) !important; }
.lottery-ball.digit-3, .slot-ball.digit-3 { background: radial-gradient(circle at 36% 32%, #d080e8, #701898) !important; }
.lottery-ball.digit-4, .slot-ball.digit-4 { background: radial-gradient(circle at 36% 32%, #ffd040, #aa6000) !important; color: #111 !important; }
.lottery-ball.digit-5, .slot-ball.digit-5 { background: radial-gradient(circle at 36% 32%, #ff9940, #aa4000) !important; }
.lottery-ball.digit-6, .slot-ball.digit-6 { background: radial-gradient(circle at 36% 32%, #40ccee, #107590) !important; }
.lottery-ball.digit-7, .slot-ball.digit-7 { background: radial-gradient(circle at 36% 32%, #ff6699, #aa1144) !important; }
.lottery-ball.digit-8, .slot-ball.digit-8 { background: radial-gradient(circle at 36% 32%, #88ee60, #3a8818) !important; color: #111 !important; }
.lottery-ball.digit-9, .slot-ball.digit-9 { background: radial-gradient(circle at 36% 32%, #aaaaff, #4444aa) !important; }

/* ── Responsive ── */
@media screen and (max-width: 768px) {
    .lottery-machine-wrapper { padding: 16px 36px; }
    .lottery-machine { width: 300px; }
    .lottery-chamber { width: 300px !important; height: 300px !important; }
    .tube-pod  { width: 62px !important; height: 62px !important; }
    .slot-ball { width: 62px !important; height: 62px !important; font-size: 1.6rem !important; }
}
@media screen and (max-width: 480px) {
    .lottery-machine-wrapper { padding: 12px 24px; }
    .lottery-machine { width: 260px; }
    .lottery-chamber { width: 260px !important; height: 260px !important; }
    .tube-pod  { width: 52px !important; height: 52px !important; }
    .slot-ball { width: 52px !important; height: 52px !important; font-size: 1.3rem !important; }
    .sphere-mount-top { width: 48px; }
    .deco-spark { font-size: 0.6rem !important; }
}

/* ===== 移动端性能优化 =====
   backdrop-filter 在动画元素上方时，每帧都会重新计算模糊，极耗 GPU
   移动端全部降级为 background 透明叠加 */
@media screen and (max-width: 768px) {
    .current-prize-type,
    .mute-btn,
    .celebration-overlay,
    .result-modal {
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
    }

    /* 禁用持续运行的 pulseButton、cardPulse、amountPulse 动画
       这些动画使用 box-shadow/filter，在移动端造成持续重绘 */
    @keyframes cardPulse {
        0%, 100% { transform: scale(1); }
        50%       { transform: scale(1.01); }
    }
    @keyframes amountPulse {
        0%, 100% { opacity: 1; }
        50%       { opacity: 0.9; }
    }
    @keyframes pulseButton {
        0%, 100% { transform: scale(1); }
        50%       { transform: scale(1.03); }
    }
}

/* ===== RESULT BALL SLOTS — Cosmic Tech ===== */
#result-row {
    display: flex;
    gap: 16px;
    margin-top: 18px;
    justify-content: center;
    padding: 10px 16px 14px;
    background: transparent;
    position: relative;
}

.res-slot {
    width: 78px;
    height: 78px;
    border-radius: 50%;
    border: 2px solid rgba(80, 140, 255, .22);
    background: radial-gradient(circle at 40% 38%, rgba(30,60,160,.7), rgba(4,10,40,.95));
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Orbitron', monospace;
    font-size: 30px;
    font-weight: 900;
    color: rgba(160,200,255,0.35);
    position: relative;
    overflow: visible;
    transition: all .35s ease;
    box-shadow:
        0 0 14px rgba(30,80,220,.18),
        inset 0 0 22px rgba(0,5,30,.6);
}

/* Top-left glass shine */
.res-slot::before {
    content: '';
    position: absolute;
    top: 9%; left: 15%;
    width: 50%; height: 26%;
    background: radial-gradient(ellipse, rgba(255,255,255,.28) 0%, transparent 70%);
    border-radius: 50%;
    transform: rotate(-28deg);
    pointer-events: none;
    z-index: 4;
    border-radius: 50%;
}

/* Outer glow ring */
.res-slot::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid transparent;
    pointer-events: none;
    z-index: 0;
    transition: all .35s ease;
}

/* ── Filled state ── */
.res-slot.filled {
    color: #fff;
    border-color: transparent;
    text-shadow:
        0 0 10px rgba(255,255,255,.7),
        0 0 22px var(--ball-glow-c, rgba(255,255,255,.4)),
        0 2px 5px rgba(0,0,0,.9);
    box-shadow:
        0 0 0 2.5px rgba(255,255,255,.18),
        0 0 22px var(--ball-glow-c, rgba(200,200,255,.4)),
        0 0 50px var(--ball-glow-c, rgba(200,200,255,.15)),
        inset 0 -5px 14px rgba(0,0,0,.45),
        inset 0 4px 12px rgba(255,255,255,.14);
}
.res-slot.filled::after {
    border-color: var(--ball-ring-c, rgba(255,255,255,.3));
    box-shadow: 0 0 16px var(--ball-glow-c, rgba(255,255,255,.25)), 0 0 32px var(--ball-glow-c, rgba(255,255,255,.1));
    animation: ringPulse 2.4s ease-in-out infinite;
}
@keyframes ringPulse {
    0%, 100% { opacity: .7; transform: scale(1); }
    50%       { opacity: 1;  transform: scale(1.06); }
}

/* ── result-highlight — winner glow flash ── */
.res-slot.result-highlight {
    animation: ballWinFlash 0.7s ease-out forwards, resSlotIdle 2.8s 0.7s ease-in-out infinite;
}
@keyframes ballWinFlash {
    0%   { filter: brightness(2.2) saturate(1.5); transform: scale(1.18); }
    50%  { filter: brightness(1.6) saturate(1.3); transform: scale(1.08); }
    100% { filter: brightness(1)   saturate(1);   transform: scale(1); }
}
@keyframes resSlotIdle {
    0%, 100% { filter: brightness(1) drop-shadow(0 0 8px var(--ball-glow-c, rgba(255,255,255,.3))); }
    50%       { filter: brightness(1.15) drop-shadow(0 0 18px var(--ball-glow-c, rgba(255,255,255,.55))); }
}

/* ── digit colors — synced with PIXI PALETTE exactly ── */
.res-slot.filled.d0 {
    background: radial-gradient(circle at 35% 32%, #ff9090 0%, #cc2020 55%, #880000 100%);
    --ball-glow-c: rgba(220,40,40,.55); --ball-ring-c: rgba(255,130,130,.5);
}
.res-slot.filled.d1 {
    background: radial-gradient(circle at 35% 32%, #80d8ff 0%, #1a6adc 55%, #043a80 100%);
    --ball-glow-c: rgba(40,150,240,.6); --ball-ring-c: rgba(130,210,255,.5);
}
.res-slot.filled.d2 {
    background: radial-gradient(circle at 35% 32%, #80f0a8 0%, #18aa48 55%, #065828 100%);
    --ball-glow-c: rgba(30,180,80,.6); --ball-ring-c: rgba(110,240,140,.5);
}
.res-slot.filled.d3 {
    background: radial-gradient(circle at 35% 32%, #e090f8 0%, #9020cc 55%, #4a0880 100%);
    --ball-glow-c: rgba(165,40,220,.6); --ball-ring-c: rgba(215,115,255,.5);
}
.res-slot.filled.d4 {
    background: radial-gradient(circle at 35% 32%, #ffe060 0%, #cc8800 55%, #7a4400 100%);
    --ball-glow-c: rgba(210,160,0,.6); --ball-ring-c: rgba(255,215,70,.5);
}
.res-slot.filled.d5 {
    background: radial-gradient(circle at 35% 32%, #ffb060 0%, #e05500 55%, #882200 100%);
    --ball-glow-c: rgba(225,95,0,.6); --ball-ring-c: rgba(255,165,85,.5);
}
.res-slot.filled.d6 {
    background: radial-gradient(circle at 35% 32%, #60e0f8 0%, #0898c0 55%, #024860 100%);
    --ball-glow-c: rgba(15,165,215,.6); --ball-ring-c: rgba(85,225,248,.5);
}
.res-slot.filled.d7 {
    background: radial-gradient(circle at 35% 32%, #ff88aa 0%, #cc1155 55%, #780030 100%);
    --ball-glow-c: rgba(215,30,90,.6); --ball-ring-c: rgba(255,115,155,.5);
}
.res-slot.filled.d8 {
    background: radial-gradient(circle at 35% 32%, #a0f060 0%, #3aaa10 55%, #185000 100%);
    --ball-glow-c: rgba(65,185,20,.6); --ball-ring-c: rgba(145,245,85,.5);
}
.res-slot.filled.d9 {
    background: radial-gradient(circle at 35% 32%, #c0c0ff 0%, #5555cc 55%, #1a1a88 100%);
    --ball-glow-c: rgba(85,85,225,.6); --ball-ring-c: rgba(165,165,255,.5);
}

/* ── pop-in animation ── */
@keyframes resSlotPopIn {
    0%   { transform: scale(0) rotate(-180deg); opacity: 0;   filter: brightness(2.5); }
    60%  { transform: scale(1.22) rotate(10deg); opacity: 1;  filter: brightness(1.4); }
    80%  { transform: scale(0.94) rotate(-4deg); filter: brightness(1.1); }
    100% { transform: scale(1) rotate(0deg);    filter: brightness(1); }
}
.res-slot.pop { animation: resSlotPopIn .55s cubic-bezier(.175,.885,.32,1.275) forwards; }
.res-slot:not(.filled) { animation: none; }

/* ── Responsive ── */
@media screen and (max-width: 768px) {
    .res-slot { width: 64px; height: 64px; font-size: 25px; }
    #result-row { gap: 12px; }
}
@media screen and (max-width: 480px) {
    .res-slot { width: 54px; height: 54px; font-size: 21px; }
    #result-row { gap: 10px; padding: 8px 10px 12px; }
}

/* Override lottery-chamber background — PIXI provides its own */
#machineDome.lottery-chamber {
    background: transparent !important;
}

/* ── Prize Pool Banner ── */
.prize-pool-banner {
    text-align: center;
    padding: 12px 0 6px;
    animation: poolFadeIn 0.9s ease-out;
}
@keyframes poolFadeIn {
    from { opacity:0; transform: translateY(-6px); }
    to   { opacity:1; transform: translateY(0); }
}
.prize-pool-label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.65rem;
    font-family: 'Orbitron', sans-serif;
    letter-spacing: 3px;
    color: rgba(126,200,255,0.5);
    text-transform: uppercase;
    margin-bottom: 4px;
}
.prize-pool-live-dot {
    display: inline-block;
    width: 6px; height: 6px;
    border-radius: 50%;
    background: #3af;
    box-shadow: 0 0 5px #3af, 0 0 10px #3af;
    animation: liveBlink 1.4s ease-in-out infinite;
    flex-shrink: 0;
}
@keyframes liveBlink {
    0%, 100% { opacity:1; box-shadow: 0 0 5px #3af, 0 0 10px #3af; }
    50%       { opacity:0.25; box-shadow: none; }
}
.prize-pool-amount-row {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 5px;
}
.prize-pool-currency {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: rgba(126,200,255,0.6);
    letter-spacing: 1px;
}
.prize-pool-amount {
    font-family: 'Orbitron', sans-serif;
    font-size: 2.4rem;
    font-weight: 900;
    background: linear-gradient(180deg, #fff 0%, #b8e0ff 35%, #4aaeff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 14px rgba(80,170,255,0.55));
    letter-spacing: 3px;
    animation: poolPulse 3.5s ease-in-out infinite;
}
@keyframes poolPulse {
    0%, 100% { filter: drop-shadow(0 0 10px rgba(80,170,255,0.45)); }
    50%       { filter: drop-shadow(0 0 28px rgba(100,200,255,0.85)); }
}
.prize-pool-amount.tick {
    animation: poolTick 0.5s ease-out forwards;
}
@keyframes poolTick {
    0%   { filter: drop-shadow(0 0 32px rgba(255,230,80,1)) brightness(1.6); }
    100% { filter: drop-shadow(0 0 10px rgba(80,170,255,0.45)); }
}
@media (max-width: 768px) {
    .prize-pool-amount { font-size: 2rem; }
}
@media (max-width: 480px) {
    .prize-pool-amount   { font-size: 1.7rem; letter-spacing: 2px; }
    .prize-pool-currency { font-size: 0.9rem; }
    .prize-pool-label    { font-size: 0.6rem; letter-spacing: 2px; }
}
