/* GLOBAL */
body {
    margin: 0;
    padding: 0;
    height: 100vh;
    background: linear-gradient(135deg, #0a0a0f, #181824, #0f0f18);
    background-attachment: fixed;
    font-family: Poppins, sans-serif;
    color: white;
}

body,
html {
    overflow-x: hidden;
}

/* TITLE */
.title {
    position: absolute;
    top: 20px;
    left: 25px;
    font-size: 28px;
    font-weight: 700;
}

/* RIGHT SIDE PLAYER PANEL */
.player-panel {
    position: absolute;
    right: 40px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* PLAYER ROW */
.player {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 8px 10px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;

    /* SMOOTH SLIDING ANIMATION */
    transition: all 0.45s cubic-bezier(0.25, 1, 0.3, 1);
}

/* ICONS */
.pfp {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

/* NAME WIDTH */
.player .name {
    width: 90px;
    font-size: 20px;
    font-weight: 600;
}

/* BUTTONS */
.btn-group {
    display: flex;
    gap: 12px;
}

.plus,
.minus {
    width: 32px;
    height: 32px;
    border: none;
    border-radius: 8px;
    background: #2c2c3a;
    color: white;
    font-size: 20px;
    cursor: pointer;
    transition: 0.25s;
}

.plus:hover,
.minus:hover {
    background: #47475a;
}
.plus.score-input-locked,
.minus.score-input-locked,
.plus.score-input-locked:hover,
.minus.score-input-locked:hover {
    cursor: not-allowed !important;
    background: #2a2a33 !important;
    color: #9a9aaa !important;
    opacity: 0.72;
    filter: saturate(0.75);
}

/* GOLD GLOW ON SCORE */
.gold-card {
    animation: goldGlow 0.9s ease-out;
}

@keyframes goldGlow {
    0% {
        box-shadow: 0 0 0px gold;
    }

    50% {
        box-shadow: 0 0 18px gold;
    }

    100% {
        box-shadow: 0 0 0px gold;
    }
}

/* GOLD GLOW FOR TOP PLAYER ONLY */
.top-player {
    border: 2px solid gold !important;
    box-shadow: 0 0 14px gold;
}

/* BOTTOM SCORE SECTION */
.score-section {
    position: fixed;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 90px;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(6px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);

    display: flex;
    justify-content: center;
    align-items: center;
}

.tmdb-inline-note {
    position: absolute;
    left: 24px;
    top: 50%;
    transform: translateY(-50%);
    max-width: 520px;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.35;
    color: inherit;
}

.score-panel {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 28px;
}

.score-box {
    display: flex;
    align-items: center;
    gap: 10px;

    padding: 8px 14px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 12px;
    backdrop-filter: blur(3px);
    height: 42px;
}

.pfp.small {
    width: 32px;
    height: 32px;
}

.name.small {
    font-size: 16px;
    font-weight: 600;
    width: 55px;
}

.score {
    font-size: 18px;
    font-weight: 700;
    width: 26px;
    text-align: center;
}

/* SCORE POP ANIMATION */
@keyframes pop {
    0% {
        transform: scale(1);
    }

    40% {
        transform: scale(1.3);
    }

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

.pop {
    animation: pop 0.3s ease-out;
}

/* KING ICON */
.crown {
    margin-left: 6px;
    font-size: 20px;
    filter: drop-shadow(0 0 4px gold);
}

/* SECTION DOTS (BIG) */
.section-progress {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 24px;
}

.section-dot {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

/* Current section */
.section-dot.active {
    background: #ffffff;
    box-shadow: 0 0 10px #ffffff;
}

/* Completed sections */
.section-dot.completed {
    background: #4da3ff;
    box-shadow: 0 0 12px #4da3ff;
}

/* Upcoming section */
.section-dot.upcoming {
    background: rgba(255, 255, 255, 0.1);
}


/* ROUND DOTS (SMALL) */
.round-progress {
    position: absolute;
    top: 55px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.round-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

/* Current round */
.round-dot.active {
    background: #ffffff;
    box-shadow: 0 0 8px #ffffff;
}

/* Completed rounds */
.round-dot.completed {
    background: #4da3ff;
    box-shadow: 0 0 10px #4da3ff;
}

/* Upcoming rounds */
.round-dot.upcoming {
    background: rgba(255, 255, 255, 0.1);
}

/* Round 15 tiny video overlay */
.round15-video-overlay {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: 220px;
    max-width: 60vw;
    z-index: 50;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.round15-video-overlay.show {
    opacity: 1;
}

.round15-video-overlay .round15-video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    background: #000;
}

.round15-video-overlay video::-webkit-media-controls,
.round15-video-overlay video::-webkit-media-controls-enclosure,
.round15-video-overlay video::-webkit-media-controls-panel,
.round15-video-overlay video::-webkit-media-controls-play-button,
.round15-video-overlay video::-webkit-media-controls-start-playback-button {
    display: none !important;
    opacity: 0 !important;
}

/* ROUND SYSTEM LAYOUT */
.round-system {
    position: absolute;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 40px;
}

.round-block {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.round-label {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #fff;
}

.round-dots {
    display: flex;
    gap: 6px;
}

/* Dots */
.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: 0.3s ease;
}

/* Active dot */
.dot.active {
    background: #fff;
    box-shadow: 0 0 8px #fff;
}

/* Completed dot */
.dot.completed {
    background: #4da3ff;
    box-shadow: 0 0 8px #4da3ff;
}

/* Upcoming dot */
.dot.upcoming {
    opacity: 0.3;
}

/* IMAGE CANVAS AREA */
.canvas-area {
    position: absolute;
    top: 180px;
    left: 50%;
    transform: translateX(-50%);
    width: 70%;
    height: 350px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.canvas-area img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 14px;
}

/* NEXT BUTTON */
.next-btn-container {
    position: absolute;
    top: 550px;
    left: 50%;
    transform: translateX(-50%);
}

#nextBtn {
    padding: 12px 30px;
    background: #5c5cff;
    border: none;
    color: white;
    font-size: 20px;
    border-radius: 12px;
    cursor: pointer;
    transition: 0.3s;
}

#nextBtn:hover {
    background: #3d3dff;
}

/* lock icon hidden by default */
.round-label .lock {
    opacity: 0.25;
    margin-left: 6px;
    font-size: 16px;
    transition: 0.2s;
}

/* upcoming sections */
.round-block.upcoming .round-label {
    opacity: 0.3;
}

.round-block.upcoming .lock {
    opacity: 1;
    /* lock visible */
}

/* completed sections */
.round-block.completed .round-label {
    opacity: 0.4;
}

.round-block.completed .lock {
    opacity: 0;
    /* hide lock on completed */
}

/* active section */
.round-block.active .round-label {
    opacity: 1;
}

.round-block.active .lock {
    opacity: 0;
    /* no lock for active */
}

/* WINNER POPUP BACKDROP */
.winner-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.65);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* WINNER CARD */
.winner-card {
    width: 380px;
    background: rgba(255, 255, 255, 0.06);
    padding: 30px 25px;
    border-radius: 18px;
    text-align: center;
    color: #fff;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.15);
    animation: popIn 0.4s ease;
}

/* WINNER IMAGE */
.winner-img {
    width: 160px;
    height: 160px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid gold;
    box-shadow: 0 0 20px gold;
    margin-bottom: 20px;
}

/* WINNER NAME */
.winner-name {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 10px;
}

/* WINNER SCORE */
.winner-score {
    font-size: 20px;
    opacity: 0.8;
    margin-bottom: 25px;
}

/* CLOSE BUTTON */
.close-btn {
    padding: 10px 20px;
    background: gold;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    color: #000;
    transition: 0.2s;
}

.close-btn:hover {
    filter: brightness(1.2);
}

@keyframes popIn {
    0% {
        transform: scale(0.7);
        opacity: 0;
    }

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

/* FULLSCREEN CONFETTI CANVAS */
#confettiCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9998;
}

/* CINEMATIC FADE */
.winner-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(14px);
    background: rgba(0, 0, 0, 0.75);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* WINNER CARD */
.winner-card {
    width: 420px;
    background: rgba(255, 255, 255, 0.07);
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    color: #fff;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.15);
    animation: cardFadeIn 0.6s ease-out forwards;
    opacity: 0;
    transform: translateY(40px);
}

/* WINNER IMAGE: glowing pulsing ring */
.winner-img {
    width: 180px;
    height: 180px;
    object-fit: cover;
    border-radius: 50%;
    border: 5px solid gold;
    box-shadow: 0 0 25px gold;
    animation: winnerPulse 2s infinite ease-in-out;
}

/* WINNER NAME */
.winner-name {
    font-size: 34px;
    font-weight: 800;
    margin-top: 16px;
    text-shadow: 0 0 14px gold;
    animation: textPop 0.5s ease-out forwards;
}

/* WINNER SCORE (animated count-up) */
.winner-score {
    font-size: 22px;
    margin-top: 8px;
    opacity: 0.85;
}

/* FINAL RESULTS HEADER */
.final-heading {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 12px;
    animation: headingSlide 0.8s ease-out forwards;
    opacity: 0;
}

/* CROWN DROP ANIMATION */
#winnerCrown {
    font-size: 42px;
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    animation: crownDrop 0.7s ease forwards;
    opacity: 0;
}

/* CLOSE BUTTON */
.close-btn {
    padding: 10px 26px;
    margin-top: 22px;
    background: gold;
    border: none;
    border-radius: 12px;
    font-size: 17px;
    font-weight: bold;
    cursor: pointer;
    color: #000;
    transition: 0.2s;
}

.close-btn:hover {
    filter: brightness(1.2);
}

/* ANIMATIONS */
@keyframes winnerPulse {
    0% {
        box-shadow: 0 0 20px gold;
    }

    50% {
        box-shadow: 0 0 40px gold;
    }

    100% {
        box-shadow: 0 0 20px gold;
    }
}

@keyframes cardFadeIn {
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes headingSlide {
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes textPop {
    0% {
        transform: scale(0.5);
        opacity: 0;
    }

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

@keyframes crownDrop {
    0% {
        transform: translate(-50%, -50px);
        opacity: 0;
    }

    100% {
        transform: translate(-50%, 10px);
        opacity: 1;
    }
}

/* LEADERBOARD CARD */
.leaderboard-card {
    width: 340px;
    background: rgba(255, 255, 255, 0.08);
    padding: 25px 20px;
    margin-left: 40px;
    border-radius: 16px;
    opacity: 0;
    transform: translateX(40px);
    transition: all 0.6s ease;
}

.leaderboard-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 18px;
    text-align: center;
}

.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* EACH ROW */
.lb-row {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.06);
    padding: 10px 14px;
    border-radius: 10px;
}

.lb-img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

.lb-name {
    font-size: 18px;
    font-weight: 600;
    flex: 1;
}

.lb-score {
    font-size: 20px;
    font-weight: bold;
}

/* SHOW ANIMATION */
.leaderboard-card.show {
    opacity: 1;
    transform: translateX(0);
}

/* WINNER POPUP BACKGROUND */
.winner-popup {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(14px);
    background: rgba(0, 0, 0, 0.75);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* WINNER CARD */
.winner-card {
    width: 420px;
    background: rgba(255, 255, 255, 0.07);
    padding: 40px 30px;
    border-radius: 20px;
    text-align: center;
    color: #fff;
    box-shadow: 0 0 25px rgba(255, 255, 255, 0.15);
    animation: cardFadeIn 0.6s ease-out forwards;
    opacity: 0;
    transform: translateY(40px);
}

/* LEADERBOARD — hidden at start */
.leaderboard-card {
    margin-top: 26px;
    background: rgba(255, 255, 255, 0.08);
    padding: 20px 18px;
    border-radius: 14px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease;
}

.leaderboard-card.show {
    opacity: 1;
    transform: translateY(0);
}

.leaderboard-title {
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 14px;
}

.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lb-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.06);
    padding: 10px 14px;
    border-radius: 10px;
}

.lb-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

.lb-name {
    flex: 1;
    font-size: 18px;
    font-weight: 600;
}

.lb-score {
    font-size: 18px;
    font-weight: 700;
}

/* Smaller Leaderboard Card */
.leaderboard-card {
    width: 260px;
    /* smaller width */
    background: rgba(255, 255, 255, 0.08);
    padding: 16px 14px;
    /* tighter padding */
    margin-top: 22px;
    border-radius: 12px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
}

.leaderboard-card.show {
    opacity: 1;
    transform: translateY(0);
}

/* Smaller title */
.leaderboard-title {
    font-size: 18px;
    /* smaller font */
    font-weight: 700;
    margin-bottom: 12px;
}

/* Smaller rows */
.leaderboard-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.lb-row {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.06);
    padding: 8px 10px;
    /* smaller padding */
    border-radius: 10px;
}

/* Smaller images */
.lb-img {
    width: 38px;
    /* smaller */
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid white;
}

/* Smaller text */
.lb-name {
    flex: 1;
    font-size: 16px;
    /* smaller font */
    font-weight: 600;
}

.lb-score {
    font-size: 16px;
    /* smaller font */
    font-weight: 700;
}

/* BLUR OVERLAY */
.blur-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(20px);
    background: rgba(0, 0, 0, 0.4);
    border-radius: 14px;
    transition: 0.4s ease;
    z-index: 3;
}

/* REVEAL BUTTON */
.reveal-btn {
    margin-top: 15px;
    padding: 12px 25px;
    background: #6a5cff;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: 0.25s ease;
}

.reveal-btn:hover {
    background: #5147ff;
}

/* TIMER */
.timer {
    margin-top: 10px;
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 0 10px #fff;
}

.canvas-area {
    position: relative;
    /* required so absolute children (blurOverlay) are positioned correctly */
}

.blur-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 14px;
    pointer-events: none;
    z-index: 3;
}

.canvas-area img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.canvas-area {
    position: relative;
    width: 100%;
    height: 450px;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* IMAGE */
.canvas-area img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    z-index: 1;
}

/* BLUR ONLY ON IMAGE */
.blur-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    backdrop-filter: blur(20px);
    background: rgba(0, 0, 0, 0.4);
    z-index: 2;
    /* above image, below reveal button */
    border-radius: 12px;
}

/* CENTER REVEAL BUTTON */
.reveal-btn {
    position: absolute;
    z-index: 3;
    /* highest: above blur */
    padding: 12px 25px;
    background: #6a5cff;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: 0.25s ease;
}

.reveal-btn:hover {
    background: #5147ff;
}

/* TIMER TOP-LEFT */
.timer {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 3;
    /* above blur */
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    text-shadow: 0 0 8px #000;
}

.canvas-area {
    position: relative;
    width: 100%;
    height: 500px;
}

.center-buttons {
    position: absolute;
    z-index: 4;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -30%);
    /* adjust vertical centering */
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

/* REVEAL button */
.reveal-btn {
    padding: 12px 25px;
    background: #6a5cff;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 18px;
    cursor: pointer;
    transition: 0.25s ease;
    z-index: 4;
}

.reveal-btn:hover {
    background: #5147ff;
}

/* NEXT button */
.next-btn {
    padding: 12px 35px;
    background: #8256ff;
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 20px;
    cursor: pointer;
    transition: 0.25s ease;
    z-index: 4;
}

.next-btn:hover {
    background: #6d45ff;
}

.next-top {
    position: absolute;
    right: -132px;
    top: 18px;
    padding: 10px 25px;
    background: #6c63ff;
    color: #fff;
    font-size: 18px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    z-index: 20;
    transition: 0.3s ease;
}

.next-top:hover {
    background: #5a52ff;
}

.timer {
    position: absolute;
    top: 15px;
    left: 15px;
    padding: 6px 14px;
    background: rgba(0, 0, 0, 0.55);
    border-radius: 8px;
    font-size: 22px;
    font-weight: 700;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(4px);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.3);
    z-index: 10;
    animation: timerPulse 1s infinite ease-in-out;
}

@keyframes timerPulse {
    0% {
        box-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
    }

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

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

/* TIMER turns red when finished */
.timer.red {
    color: #ff4b4b;
    border-color: rgba(255, 80, 80, 0.5);
    box-shadow: 0 0 14px rgba(255, 80, 80, 0.9);
    animation: timerEndPulse 0.8s infinite;
}

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

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

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



/* When timer ends */
.timer.red {
    color: #ff3b3b;
    border-color: rgba(255, 80, 80, 0.4);
    box-shadow: 0 0 10px rgba(255, 60, 60, 0.9);
    animation: timerEndPulse 0.8s infinite ease-in-out;
}

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

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

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

/* ===============================
   BLUR OVERLAY (IMAGE ONLY)
   =============================== */

#blurOverlay {
    position: absolute;
    inset: 0;
    backdrop-filter: blur(14px);
    background: rgba(0, 0, 0, 0.45);

    z-index: 2;
    /* BELOW timer */
    pointer-events: none;
}

/* FADE-OFF BLUR USED ON REVEAL */
.blur-overlay.fade-off {
    transition: backdrop-filter 110s ease, background 10s ease;
    backdrop-filter: blur(0px);
    background: rgba(0, 0, 0, 0);
}

.round-message {
    position: absolute;
    top: 80%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    width: min(90vw, 760px);
    padding: 14px 18px;
    border-radius: 18px;
    border: 2px solid rgba(255, 255, 255, 0.28);
    background: #000 !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    font-size: clamp(22px, 2.4vw, 34px);
    font-weight: 800;
    line-height: 1.15;
    text-align: center;
    color: #ffffff;
    text-shadow: 0 0 24px rgba(255, 255, 255, 0.82);
    box-shadow: 0 14px 44px rgba(0, 0, 0, 0.55);
    opacity: 0;
    z-index: 5;
    pointer-events: none;
    transition: opacity 0.35s ease, transform 0.35s ease;
}

.round-message.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* Guess the Dialogues: prompt + answer centered on canvas (not bottom “answer strip”) */
.round-message.dialogue-canvas-center {
    top: 50%;
    width: min(94vw, 880px);
    max-height: min(70vh, 520px);
    overflow: auto;
    padding: 22px 26px;
    transform: translate(-50%, -50%) scale(0.96);
}

.round-message.dialogue-canvas-center.show {
    transform: translate(-50%, -50%) scale(1);
}

.canvas-area.dialogue-round-active #frameImage {
    visibility: hidden;
    pointer-events: none;
}

/* Guess the Dialogues only: pin timer top-left so it isn’t centered when #frameImage is hidden */
.canvas-area.dialogue-round-active .timer-circle {
    position: absolute;
    top: 12px;
    left: 12px;
    z-index: 8;
    transform: none;
}

.round-status-strip {
    position: relative;
    width: fit-content;
    min-width: 190px;
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 204px auto 0;
    padding: 12px 26px;
    border-radius: 16px;
    border: 1px solid rgba(255, 213, 106, 0.3);
    background:
        radial-gradient(circle at top, rgba(255, 220, 120, 0.18), transparent 58%),
        linear-gradient(145deg, rgba(23, 12, 2, 0.95), rgba(10, 6, 1, 0.94));
    box-shadow:
        0 18px 40px rgba(0, 0, 0, 0.28),
        0 0 20px rgba(255, 190, 70, 0.08),
        inset 0 1px 0 rgba(255, 247, 216, 0.12);
    z-index: 8;
    pointer-events: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(22px) scale(0.9);
}

.round-status-strip::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(120deg, transparent 0%, rgba(255, 255, 255, 0.08) 48%, transparent 100%);
    transform: rotate(12deg);
    opacity: 0.65;
    pointer-events: none;
}

.round-status-strip::after {
    content: "";
    position: absolute;
    inset: 1px;
    border-radius: inherit;
    border: 1px solid rgba(255, 224, 150, 0.12);
    pointer-events: none;
}

.round-status-text {
    position: relative;
    z-index: 2;
    font-family: "Sora", sans-serif;
    font-size: clamp(18px, 1.7vw, 22px);
    font-weight: 800;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #ffd467;
    text-shadow: 0 0 18px rgba(255, 191, 56, 0.22);
    transition:
        transform 0.45s cubic-bezier(.22, 1, .36, 1),
        filter 0.45s ease,
        opacity 0.32s ease;
}

.round-status-tick {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 64px;
    height: 64px;
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.72);
    filter: drop-shadow(0 0 18px rgba(255, 213, 106, 0.4));
    z-index: 3;
}

.round-status-tick-ring,
.round-status-tick-path {
    fill: none;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.round-status-tick-ring {
    stroke: rgba(255, 226, 149, 0.34);
    stroke-width: 3;
    stroke-dasharray: 132;
    stroke-dashoffset: 132;
}

.round-status-tick-path {
    stroke: #ffd978;
    stroke-width: 4.5;
    stroke-dasharray: 32;
    stroke-dashoffset: 32;
}

.round-status-strip.is-visible {
    visibility: visible;
    animation: roundStatusEntrance 0.72s cubic-bezier(.2, .9, .22, 1) forwards;
}

.round-status-strip.is-complete {
    visibility: visible;
}

.round-status-strip.is-complete .round-status-text {
    opacity: 0;
    transform: scale(0.92);
    filter: blur(4px) brightness(1.05);
}

.round-status-strip.is-complete .round-status-tick {
    animation: roundStatusTickReveal 0.48s cubic-bezier(.22, 1, .36, 1) forwards;
}

.round-status-strip.is-complete .round-status-tick-ring {
    animation: roundStatusRingDraw 0.52s cubic-bezier(.65, 0, .35, 1) forwards;
}

.round-status-strip.is-complete .round-status-tick-path {
    animation:
        roundStatusTickDraw 0.48s cubic-bezier(.65, 0, .35, 1) 0.2s forwards,
        roundStatusTickPulse 0.62s cubic-bezier(.22, 1, .36, 1) 0.62s forwards;
}

.round-status-strip.is-exit .round-status-text {
    opacity: 0;
    transform: scale(0.92);
    filter: blur(4px) brightness(1.05);
}

.round-status-strip.is-exit .round-status-tick {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

.round-status-strip.is-exit {
    animation: roundStatusExit 0.52s cubic-bezier(.55, .06, .68, .19) forwards;
}

@keyframes roundStatusEntrance {
    0% {
        opacity: 0;
        visibility: visible;
        transform: translateY(30px) scale(0.86);
        filter: blur(10px);
    }

    60% {
        opacity: 1;
        transform: translateY(-6px) scale(1.04);
        filter: blur(0);
    }

    100% {
        opacity: 1;
        visibility: visible;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}


@keyframes roundStatusTickReveal {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.38) rotate(-10deg);
        filter: drop-shadow(0 0 0 rgba(255, 213, 106, 0));
    }

    58% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1.12) rotate(2deg);
        filter: drop-shadow(0 0 18px rgba(255, 213, 106, 0.52));
    }

    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
        filter: drop-shadow(0 0 18px rgba(255, 213, 106, 0.4));
    }
}

@keyframes roundStatusRingDraw {
    from {
        stroke-dashoffset: 132;
        opacity: 0.4;
    }

    to {
        stroke-dashoffset: 0;
        opacity: 1;
    }
}

@keyframes roundStatusTickDraw {
    from {
        stroke-dashoffset: 32;
    }

    to {
        stroke-dashoffset: 0;
    }
}

@keyframes roundStatusTickPulse {
    0% {
        filter: drop-shadow(0 0 14px rgba(255, 213, 106, 0.34));
    }

    50% {
        filter: drop-shadow(0 0 24px rgba(255, 213, 106, 0.72));
    }

    100% {
        filter: drop-shadow(0 0 18px rgba(255, 213, 106, 0.4));
    }
}

@keyframes roundStatusExit {
    0% {
        opacity: 1;
        visibility: visible;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }

    100% {
        opacity: 0;
        visibility: hidden;
        transform: translateY(-12px) scale(0.96);
        filter: blur(5px);
    }
}



.round-block.upcoming .round-label {
    letter-spacing: 0.5px;
}

.round-block.upcoming .lock {
    opacity: 1;
    filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.2));
}

.round-block.upcoming .dot {
    background: rgba(255, 255, 255, 0.08);
    box-shadow: none;
}

.round-block.active {
    opacity: 1;
    filter: none;
}

.round-block.active .round-label {
    color: #ffffff;
    text-shadow: 0 0 12px rgba(255, 255, 255, 0.8);
}

.round-block.active .dot.active {
    background: #ffffff;
    box-shadow: 0 0 14px #ffffff;
    animation: activePulse 1.2s infinite ease-in-out;
}

@keyframes activePulse {
    0% {
        box-shadow: 0 0 8px #fff;
    }

    50% {
        box-shadow: 0 0 18px #fff;
    }

    100% {
        box-shadow: 0 0 8px #fff;
    }
}

.round-block.completed {
    opacity: 0.75;
    filter: none;
}

.round-block.completed .round-label {
    color: #7fb7ff;
}

.round-block.completed .dot.completed {
    background: linear-gradient(135deg, #4da3ff, #7fd0ff);
    box-shadow: 0 0 10px rgba(100, 180, 255, 0.8);
}

.round-label .lock {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.round-block.active .lock,
.round-block.completed .lock {
    opacity: 0;
    transform: scale(0.7);
}



.round-block.upcoming .round-label,
.round-block.upcoming .round-dots {
    opacity: 0.35;
    filter: grayscale(0.6);
}

/* ===========================
   REFEREE HIGHLIGHT
   =========================== */
.referee-active {
    border: 2px solid gold !important;
    box-shadow: 0 0 18px gold !important;
    transform: scale(1.05);
    z-index: 5;
}

.referee-active .name {
    color: gold;
    font-weight: 800;
}

/* ===========================
   REFEREE LABEL (BOTTOM CARD)
   =========================== */
.referee-label {
    font-size: 12px;
    font-weight: 800;
    color: #ff3b3b;
    margin-left: 6px;
    letter-spacing: 0.8px;
    text-shadow: 0 0 6px rgba(255, 60, 60, 0.7);
}

/* ===============================
   MAIN FRAME IMAGE – FIXED RATIO
   =============================== */

.frame-container {
    width: 100%;
    max-width: 1100px;
    /* adjust if needed */
    aspect-ratio: 16 / 9;
    /* 🔥 cinematic ratio */
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background: #000;
}

#frameImage {
    width: 50%;
    height: 100%;
    object-fit: cover;
    /* 🔥 KEY LINE */
    object-position: center;
    /* always center subject */
    display: block;
}

/* Rounds 21-30: soft blur plus dark square grid like CCTV glass */
#frameImage.round-distort-soft {
    filter: blur(1.6px) brightness(0.94) contrast(1.03) saturate(0.97);
    animation: none;
}

@keyframes frameDistortSoft {
    0%, 100% {
        filter: blur(1.2px) brightness(0.95) contrast(1.02) saturate(0.98);
    }

    50% {
        filter: blur(2px) brightness(0.92) contrast(1.04) saturate(0.96);
    }
}

.canvas-area.round-21-30-glitch::before,
.canvas-area.round-21-30-glitch::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 32;
    border-radius: inherit;
}

.canvas-area.round-21-30-glitch::before {
    background:
        repeating-linear-gradient(0deg, rgba(8, 8, 12, 0.48) 0 3px, rgba(0, 0, 0, 0) 3px 24px),
        repeating-linear-gradient(90deg, rgba(8, 8, 12, 0.48) 0 3px, rgba(0, 0, 0, 0) 3px 24px),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.03) 0 1px, rgba(0, 0, 0, 0) 1px 12px),
        linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.05));
    mix-blend-mode: normal;
    animation: round2130Scan 3.8s ease-in-out infinite;
    opacity: 1;
}

.canvas-area.round-21-30-glitch::after {
    display: block;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0) 14%, rgba(0, 0, 0, 0.06) 100%),
        linear-gradient(90deg, rgba(90, 170, 255, 0.035), rgba(0, 0, 0, 0) 28%, rgba(255, 120, 120, 0.025) 72%, rgba(0, 0, 0, 0));
    mix-blend-mode: soft-light;
    opacity: 0.42;
    animation: round2130Flicker 4.6s steps(1, end) infinite;
}

@keyframes round2130Scan {
    0% {
        opacity: 0.55;
        transform: translateY(-1px);
    }
    50% {
        opacity: 0.82;
        transform: translateY(1px);
    }
    100% {
        opacity: 0.55;
        transform: translateY(-1px);
    }
}

@keyframes round2130Jitter {
    0% {
        transform: translate(0, 0);
    }
    25% {
        transform: translate(-1px, 0);
    }
    50% {
        transform: translate(1px, -1px);
    }
    75% {
        transform: translate(0, 1px);
    }
    100% {
        transform: translate(0, 0);
    }
}

@keyframes round2130Flicker {
    0%, 100% {
        opacity: 0.42;
    }
    48% {
        opacity: 0.42;
    }
    50% {
        opacity: 0.34;
    }
    52% {
        opacity: 0.46;
    }
    78% {
        opacity: 0.4;
    }
    80% {
        opacity: 0.32;
    }
    82% {
        opacity: 0.44;
    }
}

/* ===============================
   DISABLE TEXT SELECTION
   =============================== */

* {
    -webkit-user-select: none;
    /* Chrome, Safari */
    -moz-user-select: none;
    /* Firefox */
    -ms-user-select: none;
    /* Edge */
    user-select: none;
    /* Standard */
}

/* ===============================
   NEXT BUTTON IMAGE ANIMATION
   =============================== */

#frameImage {
    transition:
        transform 0.6s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.45s ease;
}

/* outgoing image */
.frame-animate-out {
    transform: scale(1.08);
    opacity: 0;
}

/* incoming image */
.frame-animate-in {
    transform: scale(0.96);
    opacity: 0;
}

/* ===============================
   SLIDE TRANSITION FOR FRAME IMAGE
   =============================== */

#frameImage {
    transition:
        transform 0.6s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.45s ease;
}

/* Smooth swipe left animation on NEXT */
#frameImage.swipe-out {
    animation: frameSwipeOut 450ms cubic-bezier(0.25, 1, 0.3, 1) forwards;
}

#frameImage.swipe-in {
    animation: frameSwipeIn 450ms cubic-bezier(0.25, 1, 0.3, 1) forwards;
}

@keyframes frameSwipeOut {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(-120px);
        opacity: 0;
    }
}

@keyframes frameSwipeIn {
    from {
        transform: translateX(120px);
        opacity: 0;
    }

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

/* ===============================
   TIMER CIRCULAR PROGRESS
   =============================== */

.timer-circle {
    position: relative;
    z-index: 5;
    /* above #blurOverlay (z-index 2); dialogue rounds override position below */
    width: 80px;
    height: 80px;
    --timer-accent: #d8b4ff;
    --timer-danger: #ff4747;
    border-radius: 50%;
    display: grid;
    place-items: center;
    border: 1.5px solid rgba(214, 174, 255, 0.45);
    background:
        radial-gradient(115% 100% at 28% 22%, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0) 52%),
        linear-gradient(155deg, rgba(50, 40, 70, 0.98), rgba(27, 20, 44, 0.98));
    box-shadow:
        0 10px 22px rgba(0, 0, 0, 0.34),
        0 0 0 1px rgba(222, 197, 255, 0.22) inset,
        0 1px 0 rgba(255, 255, 255, 0.08) inset;
    isolation: isolate;
}

.timer-circle::before {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 50%;
    background:
        conic-gradient(from 160deg, rgba(255, 255, 255, 0.28), rgba(255, 255, 255, 0) 38%, rgba(216, 180, 255, 0.38) 72%, rgba(255, 255, 255, 0.2));
    opacity: 0.44;
    mask: radial-gradient(circle, transparent 35px, #000 36px);
    -webkit-mask: radial-gradient(circle, transparent 35px, #000 36px);
    pointer-events: none;
}

.timer-circle::after {
    content: "";
    position: absolute;
    inset: 10px;
    border-radius: 50%;
    background:
        radial-gradient(120% 120% at 50% 36%, rgba(200, 224, 248, 0.18), rgba(200, 224, 248, 0.02) 48%, rgba(0, 0, 0, 0) 100%);
    opacity: 0.8;
    pointer-events: none;
}

.timer-ring {
    transform: rotate(-90deg);
    overflow: visible;
}

.timer-ring-bg {
    fill: none;
    stroke: rgba(214, 190, 246, 0.34);
    stroke-width: 7;
    opacity: 0.9;
}

.timer-ring-progress {
    fill: none;
    stroke: var(--timer-accent);
    stroke-width: 7;
    stroke-linecap: round;

    stroke-dasharray: 226;
    stroke-dashoffset: 0;

    transition: stroke-dashoffset 1s linear, stroke 0.3s ease, filter 0.25s ease;
    filter: drop-shadow(0 0 6px rgba(216, 180, 255, 0.35));
}

.timer-text {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    font-size: 27px;
    font-weight: 900;
    color: #f5ecff;
    text-shadow:
        0 1px 0 rgba(255, 255, 255, 0.2),
        0 2px 5px rgba(0, 0, 0, 0.4);
    letter-spacing: 0.1px;
    font-variant-numeric: tabular-nums;
    overflow: hidden;
}

.timer-num {
    position: absolute;
    inset: 0;
    display: grid;
    place-items: center;
    will-change: transform, opacity;
}

.timer-num-out {
    animation: timerNumOut 0.32s ease-in forwards;
}

.timer-num-in {
    animation: timerNumIn 0.32s ease-out forwards;
}

@keyframes timerNumOut {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(18px); opacity: 0; }
}

@keyframes timerNumIn {
    0% { transform: translateY(-18px); opacity: 0; }
    100% { transform: translateY(0); opacity: 1; }
}

.timer-circle.timeout .timer-ring-progress {
    stroke: var(--timer-danger);
    filter: drop-shadow(0 0 6px rgba(255, 84, 84, 0.4));
}

.timer-circle.timeout .timer-text {
    color: #ffd6d6;
    text-shadow:
        0 1px 0 rgba(255, 220, 220, 0.2),
        0 2px 6px rgba(0, 0, 0, 0.46);
    animation: timerCriticalPulse 0.8s ease-in-out infinite;
}

.timer-circle.timeout::before {
    background: conic-gradient(from 160deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0) 38%, rgba(255, 103, 103, 0.45) 72%, rgba(255, 255, 255, 0.16));
}

@keyframes timerCriticalPulse {
    0%, 100% { transform: scale(1); filter: saturate(1); }
    50% { transform: scale(1.06); filter: saturate(1.25); }
}

/* ===============================
   TIMER ALWAYS ABOVE BLUR
   =============================== */
/* ===============================
   BLUR OVERLAY (IMAGE ONLY)
   =============================== */

#blurOverlay {
    position: absolute;
    inset: 0;
    backdrop-filter: blur(14px);
    background: rgba(0, 0, 0, 0.45);

    z-index: 2;
    /* BELOW timer */
    pointer-events: none;
}

/* ===============================
   FULLSCREEN LEADERBOARD VIEW
   =============================== */

.winner-popup {
    position: fixed;
    inset: 0;
    background: #0a0a0f;
    /* blank screen */
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
}

/* Center card but allow breathing space */
.winner-card {
    width: 100%;
    max-width: 520px;
    background: transparent;
    /* remove card feel */
    box-shadow: none;
    padding: 0;
    text-align: center;
}

/* Final heading */
.final-heading {
    font-size: 34px;
    margin-bottom: 20px;
}

/* Winner image */
.winner-img {
    width: 180px;
    height: 180px;
    margin-bottom: 10px;
}

/* Leaderboard = main focus */
.leaderboard-card {
    width: 100%;
    max-width: 420px;
    margin: 30px auto 0;
    opacity: 1;
    transform: none;
}

/* Close button at bottom */
.close-btn {
    margin-top: 40px;
}

/* ===============================
   ZOOM OUT LEADERBOARD BY 20%
   =============================== */

.winner-popup {
    display: none;
    justify-content: center;
    align-items: center;
}

.winner-popup.show {
    display: flex;
}

/* Scale everything inside */
.winner-card {
    transform: scale(0.8);
    /* 🔥 20% zoom out */
    transform-origin: center center;
}

/* ===============================
   FORCE ZOOM OUT FINAL RESULTS
   =============================== */

/* Fullscreen takeover */
#winnerPopup {
    position: fixed !important;
    inset: 0 !important;
    display: none;
    justify-content: center;
    align-items: center;
    background: #0a0a0f !important;
    z-index: 999999 !important;
}

/* Nuclear scale force */
#winnerPopup .winner-card {
    transform: scale(0.8) !important;
    /* 🔥 HARD 20% ZOOM OUT */
    transform-origin: center center !important;
}

/* Prevent parent scaling conflicts */
#winnerPopup * {
    transform-style: flat !important;
}

/* ===============================
   LEFT SUPPORT BLOCK (NO SHIFT)
   =============================== */

.support-block {
    position: fixed;
    left: -570px;
    top: 50%;
    transform: translateY(-50%);
    width: 260px;

    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;

    z-index: 999998;
    /* below popup, above bg */
    pointer-events: auto;
}

/* Top text */
.support-text {
    font-size: 22px;
    font-weight: 700;
    color: #ffffff;
    text-align: center;
    opacity: 0.9;
}

/* QR Image */
.support-qr {
    width: 220px;
    height: auto;
    border-radius: 14px;
    background: #fff;
    padding: 10px;

    box-shadow:
        0 0 20px rgba(255, 215, 0, 0.25),
        0 0 40px rgba(255, 215, 0, 0.15);
}

/* Bottom text */
.support-footer {
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    color: #ffd700;
    line-height: 1.4;
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
}

/* ===============================
   TEXT-ONLY ROUND CARD (21–30)
   =============================== */
.text-card {
    display: none;
    max-width: 80%;
    padding: 40px 50px;
    margin-top: 20px;
    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(12px);
    border-radius: 18px;

    font-size: 34px;
    font-weight: 700;
    text-align: center;
    line-height: 1.4;

    color: #fff;
    text-shadow: 0 0 18px rgba(255, 255, 255, 0.35);

    box-shadow: 0 0 35px rgba(0, 0, 0, 0.6);
    animation: textPopIn 0.4s ease;
    z-index: 4;
}

@keyframes textPopIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }

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

/* ===============================
   TEXT-ONLY ROUND CARD (21–30)
   =============================== */
.text-card {
    display: none;
    width: 100%;
    max-width: 100%;
    padding: 36px 60px;
    margin-top: 20px;

    background: rgba(255, 255, 255, 0.06);
    backdrop-filter: blur(14px);
    border-radius: 18px;

    font-size: 32px;
    font-weight: 700;
    line-height: 1.5;
    text-align: center;

    color: #ffffff;
    text-shadow: 0 0 16px rgba(255, 255, 255, 0.35);

    box-shadow: 0 0 40px rgba(0, 0, 0, 0.65);
    z-index: 4;

    /* 🔥 IMPORTANT */
    white-space: normal;
    word-break: break-word;
}

/* Text blurred before reveal */
.text-card.blurred {
    filter: blur(10px);
    opacity: 0.6;
}

/* Referee will answer special style */
.round-message.referee-call {
    color: #ffbb00;
    /* yellow */
    border: 2px solid rgba(180, 180, 180, 0.32);
    /* grey @ 32% */
    padding: 12px 16px;
    border-radius: 12px;
    background: #000 !important;
    box-shadow: 0 0 22px rgba(255, 215, 0, 0.18);
}

/* Keep in-canvas status text (including REFEREE'S TURN) above reveal filters */
#roundMessage,
.round-message,
.round-message.referee-call {
    z-index: 100020 !important;
    position: absolute;
}

.next-top {
    position: absolute;
    right: -140px;
    top: 14px;

    padding: 12px 34px;
    font-size: 18px;
    font-weight: 700;
    letter-spacing: 1px;

    color: #ffffff;
    background: linear-gradient(135deg, #7b5cff, #4f46ff, #6f8bff);
    background-size: 200% 200%;

    border: none;
    border-radius: 14px;
    cursor: pointer;
    z-index: 20;

    box-shadow:
        0 8px 25px rgba(111, 91, 255, 0.45),
        inset 0 0 0 1px rgba(255, 255, 255, 0.15);

    backdrop-filter: blur(6px);
    transition: all 0.35s cubic-bezier(0.25, 1, 0.3, 1);

    position: relative;
    overflow: hidden;
}

/* glossy light sweep */
.next-top::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 120%;
    height: 100%;
    background: linear-gradient(120deg,
            transparent,
            rgba(255, 255, 255, 0.35),
            transparent);
    transition: 0.6s;
}

/* glow ring */
.next-top::after {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 16px;
    background: linear-gradient(135deg, #9f8cff, #4f46ff, #9f8cff);
    opacity: 0.6;
    filter: blur(14px);
    z-index: -1;
    transition: 0.4s;
}

.next-top:hover {
    transform: translateY(-2px) scale(1.04);
    background-position: 100% 50%;
    box-shadow:
        0 14px 40px rgba(111, 91, 255, 0.7),
        inset 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.next-top:hover::before {
    left: 120%;
}

.next-top {
    display: none;
    opacity: 0;
    pointer-events: none;
    color: #2d1700;
    background: linear-gradient(135deg, #fff3ba, #ffc848 34%, #ffb117 62%, #ffe6a1 100%);
    box-shadow:
        0 16px 34px rgba(255, 182, 43, 0.36),
        0 0 24px rgba(255, 200, 90, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.next-top::after {
    background: linear-gradient(135deg, rgba(255, 234, 165, 0.88), rgba(255, 183, 28, 0.72), rgba(255, 241, 198, 0.86));
    opacity: 0.72;
}

.next-top::before {
    background: linear-gradient(120deg, transparent, rgba(255, 255, 255, 0.8), transparent);
}

.next-top.is-visible {
    display: block;
    pointer-events: auto;
    opacity: 1;
}

.next-top.next-enter {
    animation: nextButtonEnterModern 0.55s cubic-bezier(.22, 1, .36, 1) both;
}

.next-top.next-exit {
    animation: nextButtonExitModern 0.38s cubic-bezier(.55, .05, .67, .19) both;
}

@keyframes nextButtonEnterModern {
    0% {
        opacity: 0;
        transform: translate3d(24px, 10px, 0) scale(0.88);
        filter: blur(4px);
    }

    62% {
        opacity: 1;
        transform: translate3d(-6px, -2px, 0) scale(1.04);
        filter: blur(0);
    }

    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
        filter: blur(0);
    }
}

@keyframes nextButtonExitModern {
    0% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
        filter: blur(0);
    }

    100% {
        opacity: 0;
        transform: translate3d(22px, -6px, 0) scale(0.82);
        filter: blur(5px);
    }
}

@media (max-width: 900px) {
    .round-status-strip {
        min-width: 160px;
        margin-top: 108px;
        padding: 10px 18px;
    }

    .round-status-text {
        font-size: clamp(15px, 4.2vw, 19px);
        letter-spacing: 0.8px;
    }

    .round-status-tick {
        width: 54px;
        height: 54px;
    }
}

.next-top:hover::after {
    opacity: 1;
    filter: blur(18px);
}

.next-top:active {
    transform: translateY(0) scale(0.98);
    box-shadow:
        0 6px 18px rgba(111, 91, 255, 0.5),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.next-top {
    position: absolute;
    right: -240px;
    top: -6px;
    /* 🔥 THIS moves it up cleanly */

    padding: 12px 36px;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 1.2px;

    color: #ffffff;
    background: linear-gradient(135deg, #7b5cff, #4f46ff, #6f8bff);
    background-size: 200% 200%;

    border: none;
    border-radius: 16px;
    cursor: pointer;
    z-index: 50;

    box-shadow:
        0 10px 28px rgba(111, 91, 255, 0.6),
        inset 0 0 0 1px rgba(255, 255, 255, 0.18);

    backdrop-filter: blur(8px);
    transition: all 0.35s cubic-bezier(0.25, 1, 0.3, 1);

    overflow: hidden;
}

.next-top::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 120%;
    height: 100%;
    background: linear-gradient(120deg,
            transparent,
            rgba(255, 255, 255, 0.45),
            transparent);
    transition: 0.6s;
}

.next-top:hover::before {
    left: 120%;
}

.reveal-btn {
    position: absolute;
    z-index: 4;

    padding: 14px 44px;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 1.4px;

    color: #ffffff;
    background: linear-gradient(135deg, #ff5c8a, #ff2f6d, #ff7aa2);
    background-size: 200% 200%;

    border: none;
    border-radius: 18px;
    cursor: pointer;

    box-shadow:
        0 10px 30px rgba(255, 60, 120, 0.6),
        inset 0 0 0 1px rgba(255, 255, 255, 0.22);

    backdrop-filter: blur(8px);
    transition: all 0.35s cubic-bezier(0.25, 1, 0.3, 1);

    overflow: hidden;
    text-transform: uppercase;
}

.reveal-btn::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 120%;
    height: 100%;
    background: linear-gradient(120deg,
            transparent,
            rgba(255, 255, 255, 0.5),
            transparent);
    transition: 0.6s;
}

.reveal-btn:hover {
    transform: translateY(-2px) scale(1.05);
    background-position: 100% 50%;
    box-shadow:
        0 16px 44px rgba(255, 60, 120, 0.85),
        inset 0 0 0 1px rgba(255, 255, 255, 0.3);
}

.reveal-btn:active {
    transform: scale(0.96);
    box-shadow:
        0 6px 18px rgba(255, 60, 120, 0.5),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.reveal-btn.dissolve-out {
    animation: revealDissolveOut 420ms cubic-bezier(.2, .82, .3, 1) forwards;
}

@keyframes revealDissolveOut {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }

    60% {
        opacity: 0.55;
        transform: translateY(-5px) scale(1.03);
        filter: blur(1.4px);
    }

    100% {
        opacity: 0;
        transform: translateY(-12px) scale(0.88);
        filter: blur(4px);
    }
}

/* BLUE REVEAL FLASH */
#revealFlashOverlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(80, 120, 255, 0.45), rgba(0, 0, 0, 0.9));
    opacity: 0;
    pointer-events: none;
    z-index: 5;
    transition: opacity 0.35s ease;
}

#revealFlashOverlay.show {
    opacity: 1;
}



/* ===============================
   TIMER SCREEN SYNC EFFECTS
   =============================== */

/* darken overlay */
#timerScreenDim {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.0);
    pointer-events: none;
    z-index: 9990;
    transition: background 0.25s ease;
}

/* red edge glow */
#timerEdgeGlow {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9991;
    box-shadow: inset 0 0 0 rgba(255, 0, 0, 0);
    transition: box-shadow 0.25s ease;
}

/* active states */
#timerScreenDim.active {
    background: rgba(0, 0, 0, 0.35);
}

#timerEdgeGlow.active {
    box-shadow:
        inset 0 0 60px rgba(255, 60, 60, 0.45),
        inset 0 0 120px rgba(255, 60, 60, 0.25);
}

/* canvas countdown 3..2..1 */
#timerCanvasCountdown {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%) scale(0.72);
    opacity: 0;
    z-index: 12;
    pointer-events: none;
    font-size: clamp(64px, 8.2vw, 108px);
    font-weight: 900;
    letter-spacing: 2px;
    color: #ffffff;
    text-shadow:
        0 0 20px rgba(255, 255, 255, 0.55),
        0 0 46px rgba(136, 193, 255, 0.42);
    transition: opacity 0.15s ease;
}

#timerCanvasCountdown.show {
    opacity: 1;
}

#timerCanvasCountdown.pulse {
    animation: canvasCountdownIn 0.62s cubic-bezier(.2, .9, .3, 1) forwards;
}

#timerCanvasCountdown.danger {
    color: #ff2f2f;
    text-shadow:
        0 0 18px rgba(255, 80, 80, 0.95),
        0 0 40px rgba(255, 20, 20, 0.6);
}

#timerCanvasCountdown.danger.shake-out {
    animation: canvasCountdownOne 0.72s cubic-bezier(.2, .85, .35, 1) forwards;
}

@keyframes canvasCountdownIn {
    0% {
        transform: translate(-50%, -50%) scale(0.6);
        opacity: 0;
    }

    45% {
        transform: translate(-50%, -50%) scale(1.03);
        opacity: 1;
    }

    100% {
        transform: translate(-50%, -50%) scale(0.96);
        opacity: 0;
    }
}

/* Vault shutter transition on NEXT */
.frame-build-overlay {
    position: fixed;
    inset: 0;
    z-index: 100400;
    pointer-events: none;
    opacity: 0;
    overflow: hidden;
}

.frame-build-overlay.show {
    opacity: 1;
}

.frame-build-overlay.fade-out {
    opacity: 0;
    transition: opacity 300ms ease;
}

.frame-build-backdrop {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(130% 90% at 50% 0%, rgba(207, 62, 62, 0.2), rgba(18, 12, 20, 0.96) 52%, #060609 100%);
    animation: vaultBackdropPulse 980ms ease forwards;
}

.frame-build-door {
    position: absolute;
    top: 0;
    width: 52%;
    height: 100%;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0) 18%, rgba(0, 0, 0, 0.6) 100%),
        linear-gradient(160deg, #2d2f38 0%, #171922 54%, #090a10 100%);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12), inset 0 0 45px rgba(0, 0, 0, 0.5);
}

.frame-build-door::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 190, 138, 0.7), rgba(255, 255, 255, 0.05));
    box-shadow: 0 0 18px rgba(255, 176, 124, 0.6);
}

.frame-build-door-left {
    left: -54%;
    transform: skewX(-2deg);
    animation: vaultDoorLeft 980ms cubic-bezier(.2, .9, .2, 1) forwards;
}

.frame-build-door-left::after {
    right: 0;
}

.frame-build-door-right {
    right: -54%;
    transform: skewX(2deg);
    animation: vaultDoorRight 980ms cubic-bezier(.2, .9, .2, 1) forwards;
}

.frame-build-door-right::after {
    left: 0;
}

.frame-build-core {
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(36vw, 500px);
    height: min(36vw, 500px);
    transform: translate(-50%, -50%) scale(.42);
    border-radius: 50%;
    border: 2px solid rgba(255, 206, 154, 0.55);
    box-shadow:
        0 0 45px rgba(255, 170, 120, 0.35),
        inset 0 0 30px rgba(255, 160, 106, 0.3);
    opacity: 0;
    animation: vaultCorePulse 980ms cubic-bezier(.2, .9, .2, 1) forwards;
}

.frame-build-scan {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(90deg, transparent 0%, rgba(255, 232, 205, 0.38) 48%, transparent 100%);
    opacity: 0;
    transform: translateX(-120%) skewX(-15deg);
    animation: vaultScanPass 980ms cubic-bezier(.2, .9, .2, 1) forwards;
}

.frame-build-grain {
    position: absolute;
    inset: -20%;
    background:
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.06) 0 2px, transparent 2px),
        radial-gradient(circle at 80% 70%, rgba(255, 255, 255, 0.04) 0 2px, transparent 2px);
    background-size: 28px 28px, 34px 34px;
    mix-blend-mode: soft-light;
    opacity: 0;
    animation: vaultGrainFlicker 980ms steps(2, end) forwards;
}

@keyframes vaultDoorLeft {
    0% { left: -54%; }
    35% { left: 0; }
    58% { left: 0; }
    100% { left: -54%; }
}

@keyframes vaultDoorRight {
    0% { right: -54%; }
    35% { right: 0; }
    58% { right: 0; }
    100% { right: -54%; }
}

@keyframes vaultCorePulse {
    0% { opacity: 0; transform: translate(-50%, -50%) scale(.42); }
    40% { opacity: .95; transform: translate(-50%, -50%) scale(1); }
    65% { opacity: .8; transform: translate(-50%, -50%) scale(.92); }
    100% { opacity: 0; transform: translate(-50%, -50%) scale(1.1); }
}

@keyframes vaultScanPass {
    0% { opacity: 0; transform: translateX(-120%) skewX(-15deg); }
    28% { opacity: .75; }
    62% { opacity: .5; }
    100% { opacity: 0; transform: translateX(130%) skewX(-15deg); }
}

@keyframes vaultBackdropPulse {
    0% { filter: brightness(.7) saturate(.85); }
    45% { filter: brightness(1.05) saturate(1.1); }
    100% { filter: brightness(.86) saturate(.9); }
}

@keyframes vaultGrainFlicker {
    0% { opacity: 0; transform: translate3d(0, 0, 0); }
    25% { opacity: .24; transform: translate3d(1.6%, -1.2%, 0); }
    50% { opacity: .16; transform: translate3d(-1.3%, .9%, 0); }
    75% { opacity: .22; transform: translate3d(.8%, 1.1%, 0); }
    100% { opacity: 0; transform: translate3d(0, 0, 0); }
}

@keyframes canvasCountdownOne {
    0% {
        transform: translate(-50%, -50%) scale(1.02);
        opacity: 1;
    }

    40% {
        transform: translate(calc(-50% - 4px), -50%) scale(1.07) rotate(-1deg);
        opacity: 1;
    }

    55% {
        transform: translate(calc(-50% + 5px), -50%) scale(1.04) rotate(1deg);
    }

    72% {
        transform: translate(calc(-50% - 3px), -50%) scale(0.97) rotate(-0.6deg);
    }

    100% {
        transform: translate(-50%, -50%) scale(0.8);
        opacity: 0;
    }
}

/* micro zoom */
.screen-zoom {
    animation: screenZoomPulse 0.35s ease;
}

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

    50% {
        transform: scale(1.025);
    }

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

/* subtle shake */
.screen-shake {
    animation: screenShake 0.25s linear;
}

@keyframes screenShake {
    0% {
        transform: translate(0, 0);
    }

    25% {
        transform: translate(-2px, 1px);
    }

    50% {
        transform: translate(2px, -1px);
    }

    75% {
        transform: translate(-1px, 2px);
    }

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

/* DIAGONAL SLIDE OFF BLUR */
.blur-overlay.slide-off {
    animation: blurSlideOff 111s cubic-bezier(0.25, 1, 0.3, 1) forwards;
}

@keyframes blurSlideOff {
    0% {
        clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
        opacity: 1;
        backdrop-filter: blur(14px);
        background: rgba(0, 0, 0, 0.45);
    }

    100% {
        clip-path: polygon(0 0, 0 0, 0 0, 0 0);
        opacity: 0;
        backdrop-filter: blur(0px);
        background: rgba(0, 0, 0, 0);
    }
}

/* GRADIENT BLUR SLIDE OFF */
.blur-overlay.gradient-off {
    animation: blurGradientOff 111s cubic-bezier(0.25, 1, 0.3, 1) forwards;
    -webkit-mask-image: linear-gradient(135deg, #000 40%, transparent 70%);
    mask-image: linear-gradient(135deg, #000 40%, transparent 70%);
}

@keyframes blurGradientOff {
    0% {
        -webkit-mask-position: 0% 0%;
        mask-position: 0% 0%;
        backdrop-filter: blur(14px);
        background: rgba(0, 0, 0, 0.45);
        opacity: 1;
    }

    100% {
        -webkit-mask-position: 120% 120%;
        mask-position: 120% 120%;
        backdrop-filter: blur(0px);
        background: rgba(0, 0, 0, 0);
        opacity: 0;
    }
}

/* ===============================
   UI THEME SWITCHER
   =============================== */

.ui-switcher {
    position: fixed;
    top: 16px;
    right: 18px;
    display: flex;
    gap: 8px;
    align-items: center;
    z-index: 100000;
}

.ui-btn {
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.8px;
    border-radius: 8px;
    border: none;
    cursor: pointer;

    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
    backdrop-filter: blur(6px);

    transition: 0.25s ease;
}

.ui-btn:hover {
    background: rgba(255, 255, 255, 0.18);
    transform: translateY(-1px);
}

.ui-btn.active {
    background: #6f8bff;
    color: #fff;
    box-shadow: 0 0 12px rgba(111, 139, 255, 0.7);
}

/* tip bubble */
.ui-tip {
    position: absolute;
    top: 38px;
    right: 0;
    padding: 6px 10px;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    font-size: 11px;
    border-radius: 8px;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(-6px);
    transition: 0.3s ease;
    pointer-events: none;
}

.ui-tip.show {
    opacity: 1;
    transform: translateY(0);
}

/* ===============================
   NEON THEME
   =============================== */
body.neon {
    background: radial-gradient(circle at top, #0500ff, #000);
}

body.neon .canvas-area,
body.neon .player,
body.neon .score-box {
    box-shadow: 0 0 18px rgba(80, 120, 255, 0.6);
    border: 1px solid rgba(80, 120, 255, 0.4);
}

body.neon .reveal-btn,
body.neon .next-top {
    box-shadow: 0 0 22px rgba(111, 139, 255, 0.9);
}

/* ===============================
   PIXEL THEME
   =============================== */
body.pixel {
    background: #0a0a0a;
    image-rendering: pixelated;
}

body.pixel * {
    font-family: 'Press Start 2P', monospace !important;
    letter-spacing: 1px;
}

body.pixel .canvas-area,
body.pixel .player,
body.pixel .score-box {
    border: 2px solid #ffffff;
    border-radius: 0 !important;
    box-shadow: none !important;
}

body.pixel .reveal-btn,
body.pixel .next-top {
    border-radius: 0 !important;
    background: #ffffff;
    color: #000;
}

.ui-tip {
    position: absolute;
    top: 42px;
    right: 0;

    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.75);
    color: #fff;
    font-size: 11px;
    border-radius: 10px;
    white-space: nowrap;

    opacity: 0;
    transform: translateY(-10px) scale(0.95);
    transition:
        opacity 0.35s ease,
        transform 0.35s cubic-bezier(0.25, 1, 0.3, 1);

    pointer-events: none;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
}

.ui-tip.show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ===============================
   UI TIP BACKDROP BLUR
   =============================== */
#uiBackdrop {
    position: fixed;
    inset: 0;
    backdrop-filter: blur(100px);
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    pointer-events: none;
    z-index: 99950;
    transition: opacity 0.35s ease;
}

#uiBackdrop.show {
    opacity: 1;
}

.ui-switcher {
    position: fixed;
    top: 16px;
    right: 18px;
    display: flex;
    gap: 8px;
    align-items: center;
    z-index: 100000;
    /* ABOVE blur */
}

.ui-tip {
    position: absolute;
    top: 52px;
    right: 0;

    padding: 14px 20px;
    background: rgba(0, 0, 0, 0.8);
    color: #ffffff;

    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.4px;

    border-radius: 14px;
    white-space: nowrap;

    opacity: 0;
    transform: translateY(-12px) scale(0.9);
    transition:
        opacity 0.35s ease,
        transform 0.35s cubic-bezier(0.25, 1, 0.3, 1);

    pointer-events: none;

    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.45),
        inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.ui-tip.show {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ===============================
   UI ONBOARDING ARROW
   =============================== */

#uiArrow {
    position: fixed;
    top: 50%;
    right: 140px;
    /* aligns toward buttons */
    transform: translateY(-50%) rotate(-20deg);

    font-size: 64px;
    font-weight: 900;
    color: #ffffff;

    opacity: 0;
    pointer-events: none;
    z-index: 100001;

    text-shadow:
        0 0 12px rgba(255, 255, 255, 0.6),
        0 0 24px rgba(111, 139, 255, 0.8);

    animation: arrowBounce 1s infinite ease-in-out;
    transition: opacity 0.3s ease;
}

#uiArrow.show {
    opacity: 1;
}

@keyframes arrowBounce {
    0% {
        transform: translateY(-50%) translateX(0) rotate(-20deg);
    }

    50% {
        transform: translateY(-50%) translateX(-12px) rotate(-20deg);
    }

    100% {
        transform: translateY(-50%) translateX(0) rotate(-20deg);
    }
}

#uiArrow {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg);

    font-size: 72px;
    font-weight: 900;
    color: #ffffff;

    opacity: 0;
    pointer-events: none;
    z-index: 100001;

    text-shadow:
        0 0 12px rgba(255, 255, 255, 0.7),
        0 0 26px rgba(111, 139, 255, 0.9);

    animation: arrowBounce 1s infinite ease-in-out;
    transition: opacity 0.3s ease;
}

.show-answer-btn {
    width: 100%;
    margin-bottom: 12px;
    padding: 10px 0;
    border-radius: 12px;
    border: none;
    cursor: pointer;
    font-weight: 800;
    letter-spacing: 1px;
    background: linear-gradient(135deg, #00f5ff, #00c2ff);
    color: #000;
    box-shadow: 0 6px 20px rgba(0, 200, 255, 0.35);
    transition: transform .15s ease, box-shadow .15s ease;
}

.show-answer-btn:hover {
    transform: translateY(-1px) scale(1.02);
    box-shadow: 0 10px 26px rgba(0, 200, 255, 0.5);
}

.update-popup {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(10px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 200000;
}

.update-card {
    width: 100vw;
    height: 100vh;
    padding: 6vh 6vw;
    border-radius: 0;
    background: radial-gradient(circle at 50% 30%, rgba(0, 245, 255, 0.16), rgba(7, 10, 22, 0.95) 58%);
    text-align: center;
    box-shadow: none;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2.2vh;
    animation: popIn .4s cubic-bezier(.2, .9, .3, 1);
}

.update-title {
    font-size: clamp(46px, 7vw, 120px);
    font-weight: 900;
    letter-spacing: 3px;
    line-height: 1.05;
    margin-bottom: 0;
    color: #00f5ff;
    text-shadow: 0 0 30px rgba(0, 245, 255, 0.55);
}

.update-date {
    font-size: clamp(28px, 3.8vw, 64px);
    font-weight: 800;
    line-height: 1.15;
    opacity: 0.96;
    margin-bottom: 1.2vh;
    color: #ffffff;
    text-shadow: 0 0 22px rgba(255, 255, 255, 0.34);
}

.update-ok {
    min-width: min(52vw, 420px);
    min-height: clamp(74px, 10vh, 120px);
    padding: 14px 40px;
    border-radius: 18px;
    border: none;
    background: linear-gradient(135deg, #00f5ff, #00c2ff);
    color: #000;
    font-weight: 800;
    font-size: clamp(28px, 2.4vw, 46px);
    letter-spacing: 1.2px;
    cursor: pointer;
    box-shadow: 0 18px 46px rgba(0, 194, 255, 0.45);
}

@keyframes popIn {
    from {
        transform: translateY(20px) scale(.95);
        opacity: 0;
    }

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

.show-answer-btn {
    position: absolute;
    right: 32px;
    bottom: -122px;

    width: 220px;
    height: 48px;

    border-radius: 14px;
    border: none;
    cursor: pointer;
    font-weight: 900;
    letter-spacing: 1px;

    background: linear-gradient(135deg, #00f5ff, #00c2ff);
    color: #000;

    box-shadow: 0 10px 30px rgba(0, 200, 255, 0.45);
    z-index: 9999;

    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.show-answer-btn:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 14px 40px rgba(0, 200, 255, 0.6);
}

body {
    position: relative;
}

#clickBlocker {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: transparent;
    display: none;
    pointer-events: all;
    cursor: wait;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(1200px 600px at 20% 20%, rgba(255, 80, 80, 0.18), transparent 60%),
        radial-gradient(900px 500px at 80% 30%, rgba(255, 120, 80, 0.14), transparent 65%),
        radial-gradient(700px 400px at 50% 80%, rgba(180, 40, 40, 0.18), transparent 70%),
        linear-gradient(135deg, #140606 0%, #1b0707 35%, #220808 60%, #0b0202 100%);
    background-attachment: fixed;
    background-repeat: no-repeat;
    color: #fff;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at 30% 40%, rgba(255, 90, 90, 0.05), transparent 40%),
        radial-gradient(circle at 70% 60%, rgba(255, 140, 90, 0.04), transparent 45%);
    pointer-events: none;
    z-index: -1;
}

#glitchBoot {
    position: fixed;
    inset: 0;
    background: black;
    z-index: 1000000;
    display: flex;
    align-items: center;
    justify-content: center;
}

#glitchVideo {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.frame-small-31 {
    width: 25% !important;
    height: auto !important;
    max-width: 25% !important;
    object-fit: contain !important;
    display: block;
    margin: auto;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
    transition: all 0.25s ease;
}

.canvas-area.small-frame-border-only {
    box-shadow: none;
    background: transparent;
}



/* active state */
#revealRedFlash.show {
    opacity: 1;
}

#topTimerBarWrap {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: rgba(255, 255, 255, 0.08);
    z-index: 100000;
    overflow: hidden;
}

#topTimerBar {
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #ffd400, #ff9f00);
    transition: width 0.2s linear;
}

#winnerBgVideo {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

#winnerPopup {
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: black;
}

#winnerPopup .winner-card {
    position: relative;
    z-index: 2;
    /* keep UI above video */
}

.removed-text {
    color: #ff2b2b;
    font-weight: 800;
    margin-right: 6px;
}

.added-text {
    color: #00e676;
    font-weight: 800;
    margin-right: 6px;
}

.answer-fit-31 {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    /* no crop */
    object-position: center center !important;
    background: #000;
    /* clean letterbox */
}

.canvas-area {
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.08),
        0 0 30px rgba(120, 100, 255, 0.15),
        inset 0 0 40px rgba(0, 0, 0, 0.6);
}

.dot.active {
    animation: dotBreath 1.4s infinite ease-in-out;
}

@keyframes dotBreath {
    0% {
        box-shadow: 0 0 6px #fff;
    }

    50% {
        box-shadow: 0 0 16px #fff;
    }

    100% {
        box-shadow: 0 0 6px #fff;
    }
}

.player {
    transition: all 0.35s cubic-bezier(.2, .9, .3, 1);
}

.player:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.top-celebrate-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
    overflow: hidden;
}

.top-celebrate-overlay.show {
    opacity: 1;
}

.top-celebrate-overlay::before,
.top-celebrate-overlay::after {
    content: "";
    position: absolute;
    inset: -10%;
    background:
        radial-gradient(circle at 12% 18%, rgba(255, 210, 90, 0.6), transparent 35%),
        radial-gradient(circle at 88% 22%, rgba(255, 120, 90, 0.55), transparent 35%),
        radial-gradient(circle at 25% 80%, rgba(120, 200, 255, 0.5), transparent 35%),
        radial-gradient(circle at 78% 78%, rgba(180, 120, 255, 0.5), transparent 35%);
    filter: blur(8px);
    opacity: 0;
    animation: bgBurst 3s ease-out forwards;
    pointer-events: none;
}

.top-celebrate-overlay::after {
    background:
        radial-gradient(circle at 50% 10%, rgba(255, 230, 160, 0.5), transparent 40%),
        radial-gradient(circle at 10% 50%, rgba(255, 140, 90, 0.45), transparent 40%),
        radial-gradient(circle at 90% 55%, rgba(120, 220, 255, 0.45), transparent 40%),
        radial-gradient(circle at 50% 90%, rgba(255, 120, 200, 0.45), transparent 40%);
    animation-delay: 150ms;
}

.top-celebrate-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(120px 120px at 10% 20%, rgba(255, 220, 120, 0.6), transparent 60%),
        radial-gradient(160px 160px at 85% 18%, rgba(255, 120, 90, 0.55), transparent 60%),
        radial-gradient(180px 180px at 20% 80%, rgba(120, 200, 255, 0.5), transparent 60%),
        radial-gradient(200px 200px at 80% 78%, rgba(180, 120, 255, 0.5), transparent 60%),
        radial-gradient(140px 140px at 50% 50%, rgba(255, 200, 80, 0.35), transparent 60%);
    opacity: 0;
    animation: bgBurst 3s ease-out forwards;
    pointer-events: none;
}

.top-celebrate-card {
    position: relative;
    transform: scale(0.6);
    animation: topCardPop 1.4s cubic-bezier(0.2, 0.9, 0.2, 1) forwards,
        topCardShake 1.4s ease-in-out;
    box-shadow:
        0 0 30px rgba(255, 210, 90, 0.85),
        0 0 90px rgba(255, 140, 70, 0.6);
    pointer-events: none;
}

.top-celebrate-card::before {
    content: "";
    position: absolute;
    inset: -30px;
    border-radius: 24px;
    z-index: -1;
    background:
        radial-gradient(circle at 18% 22%, rgba(255, 220, 120, 0.95), transparent 35%),
        radial-gradient(circle at 82% 25%, rgba(255, 120, 90, 0.9), transparent 35%),
        radial-gradient(circle at 30% 78%, rgba(255, 160, 255, 0.85), transparent 35%),
        radial-gradient(circle at 75% 75%, rgba(120, 200, 255, 0.9), transparent 35%);
    filter: blur(2px);
    animation: crackerBurst 1.4s ease-out forwards;
    opacity: 0;
}

.top-celebrate-king {
    position: absolute;
    top: 12%;
    font-size: 64px;
    filter: drop-shadow(0 6px 18px rgba(255, 215, 0, 0.75));
    animation: kingFloat 3s ease-in-out forwards;
    pointer-events: none;
    z-index: 2;
}

@keyframes kingFloat {
    0% { transform: translateY(-10px) scale(0.9); opacity: 0; }
    20% { transform: translateY(0) scale(1); opacity: 1; }
    100% { transform: translateY(6px) scale(1.02); opacity: 0; }
}

@keyframes topCardPop {
    0% { transform: scale(0.6); }
    25% { transform: scale(1.18); }
    60% { transform: scale(1.06); }
    100% { transform: scale(1); }
}

@keyframes topCardShake {
    0% { transform: translateX(0) scale(0.6); }
    15% { transform: translateX(-2px) scale(1.12); }
    30% { transform: translateX(2px) scale(1.08); }
    45% { transform: translateX(-3px) scale(1.06); }
    60% { transform: translateX(3px) scale(1.04); }
    75% { transform: translateX(-2px) scale(1.02); }
    100% { transform: translateX(0) scale(1); }
}

@keyframes crackerBurst {
    0% { opacity: 0; transform: scale(0.6); }
    20% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1.25); }
}

@keyframes bgBurst {
    0% { opacity: 0; transform: scale(0.98); }
    20% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(1.08); }
}

.pfp-drop-ghost {
    position: fixed;
    z-index: 99999;
    border-radius: 50%;
    pointer-events: none;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.35);
    transition: transform 800ms cubic-bezier(0.2, 0.9, 0.2, 1), opacity 800ms ease;
    transform-origin: center center;
    will-change: transform, opacity;
}

.referee-active {
    background: linear-gradient(135deg, rgb(255, 153, 0), rgba(255, 0, 0, 0.02));
    box-shadow: 0 0 20px rgb(255, 187, 0);
}

.score-section {
    box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.6);
}

.winner-card {
    box-shadow:
        0 0 30px rgba(255, 215, 0, 0.4),
        0 0 80px rgba(255, 215, 0, 0.15);
}

.ui-btn {
    background: linear-gradient(135deg, #222, #111);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}

.ui-btn:hover {
    background: linear-gradient(135deg, #6a5cff, #9a8bff);
    color: #fff;
    box-shadow: 0 0 18px rgba(106, 92, 255, 0.8);
}

/* TYPEWRITER EFFECT */
.round-message.typewriter::after {
    content: "▌";
    margin-left: 4px;
    animation: blink 1s infinite;
}

@keyframes blink {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

.round-message {
    letter-spacing: 1px;
    text-shadow: 0 0 18px rgba(255, 255, 255, 0.8);
}

.backend-btn {
    background: linear-gradient(135deg, #1e90ff, #00bfff);
    color: #fff;
    border: none;
    padding: 8px 14px;
    border-radius: 10px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 0 12px rgba(0, 191, 255, 0.4);
    transition: all .2s ease;
}

.backend-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 0 18px rgba(0, 191, 255, 0.7);
}

/* MODAL */
.backend-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 100000;
}

.backend-card {
    background: #0b1220;
    padding: 24px;
    width: 320px;
    border-radius: 16px;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.6);
    text-align: center;
    animation: popIn .25s ease;
}

@keyframes popIn {
    from {
        transform: scale(.9);
        opacity: 0;
    }

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

.backend-title {
    color: #fff;
    font-size: 18px;
    font-weight: 800;
    margin-bottom: 12px;
}

.backend-card input {
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: none;
    outline: none;
    margin-bottom: 14px;
    background: #111827;
    color: #fff;
}

.backend-actions {
    display: flex;
    gap: 10px;
    justify-content: space-between;
}

.backend-cancel {
    flex: 1;
    background: #333;
    color: #fff;
    border: none;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
}

.backend-ok {
    flex: 1;
    background: linear-gradient(135deg, #00ffcc, #00ffaa);
    color: #000;
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-weight: 800;
    cursor: pointer;
}

.backend-btn {
    position: absolute;
    top: 58px;
    /* adjust if needed */
    left: 24px;
    /* moves it into that empty left space */
    z-index: 1000;
}

.glass-title {
    display: inline-block;
    padding: 14px 28px;
    border-radius: 16px;
    font-size: 28px;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 1px;

    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);

    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.25),
        inset 0 0 20px rgba(255, 255, 255, 0.05);

    pointer-events: none;
    /* 🔒 makes it non-clickable */
    user-select: none;
}

/* ============================
   🔥 ULTRA PREMIUM WINNER UI
   ONLY AFFECTS WINNER SCREEN
============================ */

.winner-popup {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at top, rgba(255, 0, 80, 0.15), transparent 40%),
        radial-gradient(circle at bottom, rgba(0, 200, 255, 0.12), transparent 45%),
        linear-gradient(180deg, rgba(0, 0, 0, 0.85), rgba(0, 0, 0, 0.95));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    animation: winnerFadeIn 0.8s ease forwards;
}

@keyframes winnerFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Main card */
.winner-card {
    position: relative;
    width: 420px;
    padding: 34px 26px 30px;
    border-radius: 28px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02));
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow:
        0 0 40px rgba(255, 0, 80, 0.25),
        0 0 80px rgba(0, 150, 255, 0.15),
        inset 0 0 20px rgba(255, 255, 255, 0.05);
    text-align: center;
    overflow: hidden;
    animation: cardPop 0.9s cubic-bezier(.2, 1.4, .4, 1) forwards;
}

@keyframes cardPop {
    0% {
        transform: scale(0.7) translateY(60px);
        opacity: 0;
    }

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

/* glowing border sweep */
.winner-card::before {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 30px;
    background: linear-gradient(120deg, transparent 30%, rgba(255, 0, 80, 0.6), rgba(0, 200, 255, 0.6), transparent 70%);
    opacity: 0.6;
    animation: borderSweep 3s linear infinite;
}

@keyframes borderSweep {
    0% {
        transform: translateX(-100%);
    }

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

/* crown */
#winnerCrown {
    font-size: 42px;
    margin-bottom: 8px;
    filter: drop-shadow(0 0 12px gold);
    animation: crownFloat 2.5s ease-in-out infinite;
}

@keyframes crownFloat {

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

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

/* heading */
.final-heading {
    font-size: 20px;
    letter-spacing: 2px;
    color: #ffffff;
    opacity: 0.9;
    margin-bottom: 14px;
}

/* winner image */
.winner-img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow:
        0 0 20px rgba(255, 0, 80, 0.4),
        0 0 40px rgba(0, 150, 255, 0.3);
    margin: 10px auto 12px;
}

/* name */
.winner-name {
    font-size: 26px;
    font-weight: 700;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #ff005c, #00d4ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 6px;
}

/* score */
.winner-score {
    font-size: 18px;
    color: #ffffff;
    opacity: 0.85;
    margin-bottom: 18px;
}

/* leaderboard */
.leaderboard-card {
    margin-top: 14px;
    padding: 14px 12px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    box-shadow: inset 0 0 15px rgba(255, 255, 255, 0.05);
}

.leaderboard-title {
    font-size: 14px;
    letter-spacing: 1px;
    margin-bottom: 8px;
    color: #ffffff;
    opacity: 0.9;
}

/* close button */
.close-btn {
    margin-top: 18px;
    padding: 10px 24px;
    border-radius: 20px;
    background: linear-gradient(135deg, #ff005c, #ff7a00);
    border: none;
    color: #fff;
    font-size: 14px;
    letter-spacing: 1px;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(255, 0, 80, 0.5);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.close-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 30px rgba(255, 0, 80, 0.8);
}

/* support block */
.support-block {
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.support-text {
    font-size: 12px;
    opacity: 0.8;
    margin-bottom: 8px;
}

.support-qr {
    width: 120px;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(0, 150, 255, 0.3);
}

.support-footer {
    margin-top: 10px;
    font-size: 11px;
    opacity: 0.7;
    letter-spacing: 1px;
}

/* ===============================
   FORCE QR BACK INTO VIEW
=============================== */

.support-block {
    left: -320px !important;
    /* bring it inside screen */
    top: 50% !important;
    transform: translateY(-50%) !important;
    z-index: 9999999 !important;
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
}

.support-qr {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;
    z-index: 9999999 !important;
}

/* ===============================
   RIP QR OUT OF WINNER CARD
=============================== */

/* Detach support block from card flow */
.winner-card .support-block {
    position: fixed !important;
    left: -312px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;

    width: 260px !important;
    z-index: 9999999 !important;

    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    gap: 16px !important;

    pointer-events: auto !important;
}

/* Force QR visibility */
.winner-card .support-qr {
    display: block !important;
    opacity: 1 !important;
    visibility: visible !important;

    width: 220px !important;
    height: auto !important;

    background: #ffffff !important;
    padding: 10px !important;
    border-radius: 14px !important;

    z-index: 9999999 !important;

    box-shadow:
        0 0 25px rgba(0, 200, 255, 0.7),
        0 0 45px rgba(255, 0, 80, 0.6) !important;
}

.winner-intro-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    z-index: 2147483645;
    background:
        radial-gradient(circle at 20% 20%, rgba(255, 216, 122, 0.22), transparent 28%),
        radial-gradient(circle at 80% 18%, rgba(255, 255, 255, 0.12), transparent 22%),
        radial-gradient(circle at 50% 78%, rgba(255, 169, 65, 0.18), transparent 30%),
        linear-gradient(145deg, rgba(8, 5, 1, 0.96), rgba(18, 8, 1, 0.98) 42%, rgba(6, 4, 1, 0.99));
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.winner-intro-overlay.show {
    display: flex;
    animation: winnerIntroFadeIn .35s ease both;
}

.winner-intro-card {
    position: relative;
    width: min(560px, 90vw);
    padding: 34px 30px 32px;
    border-radius: 30px;
    border: 1px solid rgba(255, 224, 142, 0.34);
    background:
        radial-gradient(circle at top, rgba(255, 232, 162, 0.24), transparent 52%),
        linear-gradient(160deg, rgba(44, 24, 3, 0.94), rgba(15, 8, 2, 0.96) 68%);
    box-shadow:
        0 34px 90px rgba(0, 0, 0, 0.6),
        0 0 46px rgba(255, 193, 67, 0.18),
        inset 0 1px 0 rgba(255, 247, 212, 0.24);
    text-align: center;
    overflow: hidden;
    animation: winnerIntroCardIn 4s cubic-bezier(.22, 1, .36, 1) both;
}

.winner-intro-card::before {
    content: "";
    position: absolute;
    inset: -20% auto -20% -30%;
    width: 40%;
    background: linear-gradient(115deg, transparent 0%, rgba(255, 255, 255, 0.52) 50%, transparent 100%);
    transform: rotate(14deg);
    animation: winnerIntroSweep 2.8s ease-in-out .35s infinite;
    pointer-events: none;
}

.winner-intro-kicker {
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 3.8px;
    text-transform: uppercase;
    color: rgba(255, 230, 168, 0.82);
    margin-bottom: 10px;
}

.winner-intro-crown {
    width: 70px;
    height: 70px;
    margin: 0 auto 16px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 240, 183, 0.95), rgba(255, 193, 61, 0.9) 46%, rgba(166, 97, 8, 0.95) 100%);
    color: #4a2600;
    font-size: 34px;
    box-shadow:
        0 0 32px rgba(255, 201, 84, 0.44),
        0 0 72px rgba(255, 201, 84, 0.2);
    animation: winnerIntroPulse 1.8s ease-in-out infinite;
}

.winner-intro-img {
    width: 132px;
    height: 132px;
    object-fit: cover;
    border-radius: 50%;
    border: 4px solid rgba(255, 226, 148, 0.95);
    box-shadow:
        0 0 0 8px rgba(255, 212, 105, 0.08),
        0 0 34px rgba(255, 203, 87, 0.32);
    margin-bottom: 18px;
}

.winner-intro-name {
    font-family: "Sora", sans-serif;
    font-size: clamp(34px, 5vw, 54px);
    font-weight: 800;
    line-height: 1;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    background: linear-gradient(110deg, #fff8dc 0%, #ffd86f 30%, #ffbf2f 52%, #fff4c0 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 0 24px rgba(255, 202, 72, 0.18);
    animation: winnerIntroTextShine 2.6s ease-in-out infinite;
}

.winner-intro-score,
.winner-intro-sub {
    position: relative;
    z-index: 1;
}

.winner-intro-score {
    margin-top: 12px;
    font-size: clamp(18px, 2.2vw, 24px);
    font-weight: 800;
    color: #ffe7ad;
    letter-spacing: 1px;
}

.winner-intro-sub {
    margin-top: 12px;
    font-size: 14px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 239, 194, 0.72);
}

.winner-intro-burst,
.winner-intro-spark {
    position: absolute;
    border-radius: 999px;
    pointer-events: none;
}

.winner-intro-burst {
    width: 56vmax;
    height: 56vmax;
    border: 1px solid rgba(255, 223, 145, 0.12);
    background: radial-gradient(circle, rgba(255, 215, 110, 0.18) 0%, rgba(255, 215, 110, 0.04) 34%, transparent 62%);
    animation: winnerIntroBurst 4s ease-out infinite;
}

.winner-intro-burst-a {
    left: -12vmax;
    top: -14vmax;
}

.winner-intro-burst-b {
    right: -12vmax;
    bottom: -14vmax;
    animation-delay: .7s;
}

.winner-intro-spark {
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(255, 250, 223, 0.62), rgba(255, 208, 95, 0.16) 34%, transparent 68%);
    mix-blend-mode: screen;
    opacity: .7;
}

.winner-intro-spark-a {
    top: 12%;
    left: 18%;
    animation: winnerIntroFloat 3.8s ease-in-out infinite;
}

.winner-intro-spark-b {
    right: 14%;
    bottom: 16%;
    animation: winnerIntroFloat 3.8s ease-in-out -1.6s infinite;
}

@keyframes winnerIntroFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes winnerIntroCardIn {
    0% {
        opacity: 0;
        transform: translateY(34px) scale(.86);
        filter: blur(8px);
    }

    18% {
        opacity: 1;
        transform: translateY(-6px) scale(1.03);
        filter: blur(0);
    }

    82% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }

    100% {
        opacity: 0;
        transform: translateY(-16px) scale(.98);
        filter: blur(4px);
    }
}

@keyframes winnerIntroSweep {
    0%, 18% {
        transform: translateX(0) rotate(14deg);
        opacity: 0;
    }

    36% {
        opacity: .75;
    }

    64%, 100% {
        transform: translateX(340%) rotate(14deg);
        opacity: 0;
    }
}

@keyframes winnerIntroPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.08); }
}

@keyframes winnerIntroTextShine {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

@keyframes winnerIntroBurst {
    0% {
        transform: scale(.42);
        opacity: 0;
    }

    22% {
        opacity: .55;
    }

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

@keyframes winnerIntroFloat {
    0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
    50% { transform: translate3d(12px, -18px, 0) scale(1.08); }
}

/* Ensure no parent can clip it */
.winner-card,
.winner-popup {
    overflow: visible !important;
}

/* ===============================
   KILL SHINY PATCH – CLEAN WINNER UI
=============================== */

/* Hard solid background – no bleed */
#winnerPopup .winner-card {
    background: rgba(10, 10, 15, 0.92) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;

    box-shadow:
        0 0 30px rgba(0, 0, 0, 0.8),
        0 0 60px rgba(0, 0, 0, 0.6) !important;

    border-radius: 22px !important;
}

/* Kill all glow / shine layers */
#winnerPopup .winner-card::before,
#winnerPopup .winner-card::after {
    display: none !important;
    content: none !important;
}

/* Prevent background gradients bleeding in */
#winnerPopup {
    background: radial-gradient(circle at center, #050508 0%, #000 70%) !important;
}

/* Remove gold haze glow */
#winnerPopup .winner-card {
    filter: none !important;
}

/* Also clean leaderboard panel */
#winnerPopup .leaderboard-card {
    background: rgba(20, 20, 25, 0.85) !important;
    box-shadow: none !important;
}

/* ===============================
   PERFECT LEADERBOARD ALIGNMENT
=============================== */

#winnerPopup .leaderboard-card {
    width: 100% !important;
    max-width: 420px !important;
    margin: 24px auto 0 auto !important;
    /* perfectly centered */
    padding: 18px 18px !important;

    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;

    border-radius: 18px !important;
    box-sizing: border-box !important;
}

/* Each row – full width, aligned */
#winnerPopup .lb-row {
    width: 100% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;

    padding: 12px 16px !important;
    border-radius: 12px !important;
    box-sizing: border-box !important;
}

/* Name + image alignment fix */
#winnerPopup .lb-row .lb-name {
    margin-left: 2px !important;
}

/* Score always right aligned */
#winnerPopup .lb-score {
    min-width: 40px !important;
    text-align: right !important;
}


/* ===============================
   ULTRA BRIGHT YELLOW GLOW (WINNER)
=============================== */
#winnerPopup .winner-name {
    color: #ffe600 !important;
    text-shadow:
        0 0 6px #ffee00,
        0 0 14px #ffae00,
        0 0 30px rgb(255, 174, 0),
        0 0 60px rgb(255, 187, 0) !important;
}

#winnerPopup .winner-img {
    border: 4px solid #FFD700 !important;
    box-shadow:
        0 0 12px #FFD700,
        0 0 28px #FFD700,
        0 0 55px rgba(255, 215, 0, 0.95),
        0 0 95px rgba(0, 0, 0, 0.75) !important;
}


/* Final score also yellow punch */
#winnerPopup .winner-score {
    color: #FFD700 !important;
    text-shadow:
        0 0 6px #FFD700,
        0 0 14px rgba(255, 215, 0, 0.9) !important;
}

/* Leaderboard title glow */
#winnerPopup .leaderboard-title {
    color: #FFD700 !important;
    text-shadow:
        0 0 6px #FFD700,
        0 0 14px rgba(255, 215, 0, 0.9) !important;
}

@keyframes popIn {
    0% {
        transform: scale(0.9);
        opacity: 0;
    }

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

.player {
    /* animate only transform for smooth GPU-accelerated movement */
    transition: transform 450ms cubic-bezier(0.25, 1, 0.3, 1), box-shadow 220ms ease;
    will-change: transform;
}

/* ===============================
   RANK BADGE ON PLAYER CARD
=============================== */

.player {
    position: relative;
    /* needed for badge positioning */
}

.player .rank-badge {
    position: absolute;
    left: -44px;
    top: 50%;
    transform: translateY(-50%);
    padding: 6px 11px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 900;
    background: linear-gradient(135deg, #1a0a0a, #2b0f0f);
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(255, 0, 60, 0.35);
    letter-spacing: 0.5px;
    z-index: 5;
    pointer-events: none;
}

.player.rank-1 .rank-badge {
    background: linear-gradient(135deg, #ff003c, #b3002a);
    color: #ffffff;
    box-shadow: 0 0 18px rgba(255, 0, 60, 0.9);
}

/* #1 fire icon: no pink pill — just the GIF; shifted left so 72px doesn’t crowd the card */
.player.rank-1 .rank-badge.rank-badge--first {
    left: -65px;
    padding: 0;
    border: none;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    line-height: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateY(-50%);
}

.player.rank-1 .rank-badge-fire-gif {
    width: 72px;
    height: 72px;
    object-fit: contain;
    display: block;
}

.winner-bg-video {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: 99998;
    opacity: 0;
    transition: opacity 0.6s ease;
    pointer-events: none;
}

#winnerBgVideo {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    z-index: 9999;
    background: black;
    display: none;
}

/* ===============================
   BOTTOM SCORE CARD HIT EFFECT
   Neon energy sweep + pulse + shake
   =============================== */

.score-box {
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

/* ENERGY SWEEP */
.score-box::before {
    content: "";
    position: absolute;
    inset: -40%;
    background: linear-gradient(110deg,
            transparent 30%,
            rgba(0, 255, 255, 0.9) 45%,
            rgba(255, 255, 0, 0.9) 55%,
            transparent 70%);
    transform: translateX(-120%) rotate(10deg);
    opacity: 0;
    pointer-events: none;
    z-index: 0;
}

/* GLOW PULSE */
.score-box::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(255, 255, 0, 0.35), transparent 65%);
    opacity: 0;
    pointer-events: none;
    z-index: 0;
}

/* keep content above */
.score-box>* {
    position: relative;
    z-index: 1;
}

/* ANIMATIONS */
@keyframes energySweep {
    0% {
        transform: translateX(-120%) rotate(10deg);
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    60% {
        opacity: 1;
    }

    100% {
        transform: translateX(120%) rotate(10deg);
        opacity: 0;
    }
}

@keyframes glowPulse {
    0% {
        opacity: 0;
    }

    30% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

@keyframes microShake {
    0% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-2px);
    }

    50% {
        transform: translateX(2px);
    }

    75% {
        transform: translateX(-1px);
    }

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

/* TRIGGER CLASS */
.score-box.score-hit {
    animation: microShake 0.25s linear;
    box-shadow:
        0 0 18px rgb(255, 238, 0),
        0 0 32px rgb(255, 238, 0);
}

.score-box.score-hit::before {
    animation: energySweep 0.9s cubic-bezier(.2, .8, .2, 1) forwards;
}

.score-box.score-hit::after {
    animation: glowPulse 0.9s ease-out forwards;
}

.dot.active {
    animation: dotPop 0.6s ease;
}

@keyframes dotPop {
    0% {
        transform: scale(0.6);
        opacity: 0.5;
    }

    60% {
        transform: scale(1.3);
    }

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

/* HARD REMOVE top player glow + border */
.top-player {
    border: none !important;
    box-shadow: none !important;
    filter: none !important;
}

/* Also kill any pseudo glow if present */
.top-player::before,
.top-player::after {
    display: none !important;
}

/* ===============================
   GOLD ROYALE THEME
   =============================== */
body.gold {
    background: linear-gradient(180deg, #0b0710 0%, #140f13 60%, #0a0608 100%);
    color: #fff;
}

/* title */
body.gold .title {
    color: #ffd85b;
    text-shadow: 0 0 14px rgba(255, 216, 91, 0.15);
}

/* canvas / glass */
body.gold .canvas-area {
    background: rgba(255, 244, 220, 0.03);
    border: 1px solid rgba(255, 206, 87, 0.12);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6), 0 0 36px rgba(255, 200, 0, 0.04) inset;
}

/* blur overlay */
body.gold .blur-overlay {
    background: rgba(6, 4, 3, 0.5);
    backdrop-filter: blur(18px);
}

/* player cards */
body.gold .player {
    background: linear-gradient(180deg, rgba(255, 240, 210, 0.02), rgba(0, 0, 0, 0.05));
    border: 1px solid rgba(255, 206, 87, 0.08);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.55);
}

/* player hover */
body.gold .player:hover {
    box-shadow: 0 14px 38px rgba(0, 0, 0, 0.6), 0 0 22px rgba(255, 200, 50, 0.08);
}

/* bottom score boxes */
body.gold .score-box {
    background: rgba(255, 245, 210, 0.02);
    border: 1px solid rgba(255, 206, 87, 0.08);
}

/* buttons */
body.gold .reveal-btn,
body.gold .next-top,
body.gold .ui-btn {
    background: linear-gradient(135deg, #ffd96b, #d49f00);
    color: #1b1206;
    border: 1px solid rgba(255, 220, 110, 0.2);
    box-shadow: 0 8px 28px rgba(209, 159, 0, 0.12);
}

/* active UI button */
body.gold .ui-btn.active {
    box-shadow: 0 0 20px rgba(255, 210, 90, 0.9), 0 2px 8px rgba(0, 0, 0, 0.45);
}

/* timer */
body.gold .timer {
    border-color: rgba(255, 215, 90, 0.18);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.5);
}

/* active/completed dots */
body.gold .dot.active {
    background: #ffd85b;
    box-shadow: 0 0 14px rgba(255, 216, 91, 0.7);
}

body.gold .dot.completed {
    background: linear-gradient(135deg, #ffd85b, #ffb84b);
    box-shadow: 0 0 10px rgba(255, 185, 60, 0.6);
}

/* winner card */
body.gold .winner-card {
    background: linear-gradient(180deg, #1a1412, #0f0a08);
    border: 1px solid rgba(255, 207, 90, 0.12);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.75), 0 0 40px rgba(255, 200, 50, 0.06) inset;
}

body.gold .winner-img {
    border-color: rgba(255, 215, 90, 0.9);
    box-shadow: 0 0 26px rgba(255, 200, 50, 0.25);
}

/* round message */
body.gold .round-message {
    color: #ffd88a;
    text-shadow: 0 0 12px rgba(255, 200, 80, 0.45);
}

/* ===============================
   ICE GLASS THEME – frosted blue
   =============================== */

body.ice {
    background: radial-gradient(circle at top, #e9f6ff, #b6ddff 40%, #7bbcff 100%);
    color: #00345f;
}

/* Title */
body.ice .title {
    color: #ffffff;
    text-shadow: 0 0 14px rgba(180, 230, 255, 0.9);
}

/* Canvas */
body.ice .canvas-area {
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid rgba(180, 230, 255, 0.6);
    box-shadow: 0 0 40px rgba(120, 200, 255, 0.6);
    backdrop-filter: blur(18px);
}

/* Blur overlay */
body.ice .blur-overlay {
    background: rgba(200, 235, 255, 0.55);
    backdrop-filter: blur(22px);
}

/* Player cards */
body.ice .player {
    background: rgba(255, 255, 255, 0.45);
    border: 1px solid rgba(150, 210, 255, 0.6);
    box-shadow: 0 10px 28px rgba(100, 180, 255, 0.5);
}

/* Bottom score boxes */
body.ice .score-box {
    background: rgba(255, 255, 255, 0.45);
    border: 1px solid rgba(150, 210, 255, 0.6);
}

/* Buttons */
body.ice .reveal-btn,
body.ice .next-top,
body.ice .ui-btn {
    background: linear-gradient(135deg, #d9f2ff, #8ecbff);
    color: #00345f;
    border: 1px solid rgba(120, 190, 255, 0.8);
    box-shadow: 0 0 22px rgba(120, 200, 255, 0.9);
}

body.ice .ui-btn.active {
    box-shadow: 0 0 30px rgba(120, 200, 255, 1);
}

/* Timer */
body.ice .timer {
    box-shadow: 0 0 22px rgba(120, 200, 255, 1);
    border-color: rgba(120, 200, 255, 0.9);
}

/* Dots */
body.ice .dot.active {
    background: #5fbfff;
    box-shadow: 0 0 14px #5fbfff;
}

body.ice .dot.completed {
    background: linear-gradient(135deg, #5fbfff, #aee3ff);
}

/* Winner */
body.ice .winner-card {
    background: linear-gradient(180deg, #ffffff, #dff3ff);
    border: 1px solid rgba(120, 200, 255, 0.6);
    box-shadow: 0 0 50px rgba(120, 200, 255, 0.9);
}

body.ice .winner-img {
    border-color: #5fbfff;
    box-shadow: 0 0 26px #5fbfff;
}

/* Round text */
body.ice .round-message {
    color: #005fa3;
    text-shadow: 0 0 14px rgba(120, 200, 255, 0.9);
}

/* ===============================
   ICE GLASS VISIBILITY FIX
   =============================== */

/* Global text fix */
body.ice {
    color: #0a2a45;
}

/* Title */
body.ice .title {
    color: #ffffff;
    text-shadow: 0 2px 8px rgba(0, 60, 120, 0.6);
}

/* Round labels (FOREIGN, INDIAN, etc.) */
body.ice .round-label {
    color: #0a2a45 !important;
    font-weight: 800;
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.6);
}

/* Locked text */
body.ice .round-block.upcoming .round-label {
    color: rgba(10, 42, 69, 0.5) !important;
}

/* Lock icon */
body.ice .round-label .lock {
    color: #0a2a45;
    filter: drop-shadow(0 1px 2px rgba(255, 255, 255, 0.6));
}

/* Player names */
body.ice .player .name {
    color: #0a2a45;
    font-weight: 700;
}

/* Bottom score names */
body.ice .score-box .name.small {
    color: #0a2a45;
    font-weight: 700;
}

/* Scores */
body.ice .score {
    color: #003a66;
    font-weight: 800;
}

/* Buttons text */
body.ice .reveal-btn,
body.ice .next-top,
body.ice .show-answer-btn,
body.ice .ui-btn {
    color: #003a66 !important;
    font-weight: 800;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.6);
}

/* Active UI button */
body.ice .ui-btn.active {
    color: #002b4d !important;
}

/* Timer text */
body.ice .timer,
body.ice #timerDisplay {
    color: #003a66 !important;
    font-weight: 800;
    text-shadow: 0 1px 3px rgba(255, 255, 255, 0.8);
}

/* NEXT button */
body.ice .next-top {
    color: #003a66 !important;
}

/* Show Answer button */
body.ice .show-answer-btn {
    color: #003a66 !important;
}

/* Referee label */
body.ice .referee-label {
    color: #b30000 !important;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.7);
}

/* Winner text */
body.ice .final-heading,
body.ice .winner-name,
body.ice .winner-score {
    color: #003a66;
    text-shadow: 0 2px 6px rgba(255, 255, 255, 0.7);
}

/* Round message text */
body.ice .round-message {
    color: #003a66;
    text-shadow: 0 2px 8px rgba(255, 255, 255, 0.9);
}

/* ===============================
   FILMMAKER THEME – cinematic, film-strip feel
   =============================== */
body.filmmaker {
    background: radial-gradient(circle at 20% 10%, #151515 0%, #0b0b0b 45%, #050505 100%);
    color: #e8e1d8;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* subtle warm tint */
body.filmmaker .canvas-area {
    background: linear-gradient(180deg, rgba(20, 16, 12, 0.45), rgba(6, 6, 6, 0.6));
    border: 1px solid rgba(255, 210, 120, 0.06);
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.75);
}

/* film grain overlay (subtle) */
body.filmmaker::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(transparent 92%, rgba(255, 255, 255, 0.01) 92%),
        repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.02) 0 1px, transparent 1px 3px);
    opacity: 0.06;
    mix-blend-mode: overlay;
    z-index: 99999;
}

/* title */
body.filmmaker .title {
    color: #ffdca3;
    text-shadow: 0 6px 28px rgba(0, 0, 0, 0.75);
    font-weight: 800;
}

/* buttons & UI controls */
body.filmmaker .reveal-btn,
body.filmmaker .next-top,
body.filmmaker .ui-btn,
body.filmmaker .show-answer-btn {
    background: linear-gradient(180deg, #3b2f25, #221b15);
    color: #ffdca3;
    border: 1px solid rgba(255, 215, 140, 0.08);
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.6), 0 0 18px rgba(255, 180, 80, 0.04) inset;
    font-weight: 800;
}

/* button hover */
body.filmmaker .ui-btn.active,
body.filmmaker .ui-btn:hover,
body.filmmaker .reveal-btn:hover {
    filter: brightness(1.1);
    box-shadow: 0 16px 44px rgba(0, 0, 0, 0.7), 0 0 30px rgba(255, 160, 60, 0.06) inset;
}

/* round labels */
body.filmmaker .round-label {
    color: #f2e6cf;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.7);
    letter-spacing: 0.6px;
    font-weight: 800;
}

/* dot active/completed */
body.filmmaker .dot.active {
    background: #ffdca3;
    box-shadow: 0 0 12px rgba(255, 215, 160, 0.12);
}

body.filmmaker .dot.completed {
    background: linear-gradient(135deg, #ffdca3, #f2b46e);
}

/* player cards */
body.filmmaker .player {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(0, 0, 0, 0.06));
    border: 1px solid rgba(255, 220, 120, 0.05);
    color: #efe7d8;
}

body.filmmaker .player .name {
    color: #ffdca3;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6);
}

/* score boxes (bottom) */
body.filmmaker .score-box {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 210, 120, 0.06);
}

body.filmmaker .score {
    color: #ffe7b3;
    font-weight: 800;
}

/* winner card */
body.filmmaker .winner-card {
    background: linear-gradient(180deg, #16100c, #0b0706);
    border: 1px solid rgba(255, 210, 120, 0.06);
    box-shadow: 0 26px 80px rgba(0, 0, 0, 0.85);
}

body.filmmaker .winner-name {
    color: #ffdca3;
}

/* timer */
body.filmmaker .timer,
body.filmmaker #timerDisplay {
    color: #ffdca3;
    font-weight: 900;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.6);
}

/* keep text readable: force darker overlays where needed */
body.filmmaker .blur-overlay {
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(16px);
}

/* subtle film-strip edge on canvas */
body.filmmaker .canvas-area {
    border-radius: 10px;
    box-shadow: 0 18px 60px rgba(0, 0, 0, 0.8), 0 0 0 2px rgba(0, 0, 0, 0.06) inset;
}

/* optional cinematic letterbox (thin) */
body.filmmaker .canvas-area::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    height: 26px;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0.45), transparent);
    pointer-events: none;
    z-index: 40;
}

body.filmmaker .canvas-area::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 26px;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.45), transparent);
    pointer-events: none;
    z-index: 40;
}

/* ===============================
   CANDEY THEME – candy crush inspired (pastel, glossy)
   =============================== */
body.candey {
    background: linear-gradient(180deg, #ffedf7 0%, #fff2df 40%, #e6f7ff 100%);
    color: #0b2540;
    --cand-primary: #ff6fb5;
    /* pink */
    --cand-accent: #ffd166;
    /* yellow */
    --cand-blue: #6fd3ff;
    /* blue */
    --cand-green: #7ef6c1;
    /* mint */
    font-weight: 700;
}

/* UI switcher / buttons */
body.candey .ui-btn,
body.candey .reveal-btn,
body.candey .next-top,
body.candey .show-answer-btn {
    background: linear-gradient(135deg, var(--cand-primary), var(--cand-blue));
    color: white;
    border: none;
    border-radius: 28px;
    padding: 10px 16px;
    box-shadow: 0 12px 30px rgba(255, 111, 181, 0.18), 0 6px 18px rgba(0, 0, 0, 0.08);
    text-transform: uppercase;
    letter-spacing: 1.6px;
}

/* glossy shine */
body.candey .ui-btn::after,
body.candey .reveal-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.35), rgba(255, 255, 255, 0.08));
    mix-blend-mode: overlay;
    border-radius: 28px;
}

/* title */
body.candey .title {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.8));
    color: #1a2b3a;
    padding: 16px 28px;
    border-radius: 16px;
    box-shadow: 0 18px 50px rgba(255, 111, 181, 0.1);
}

/* canvas */
body.candey .canvas-area {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(250, 245, 255, 0.9));
    border: 1px solid rgba(10, 37, 64, 0.04);
    box-shadow: 0 12px 36px rgba(13, 34, 62, 0.06);
    border-radius: 18px;
}

/* round labels */
body.candey .round-label {
    color: #133048;
    font-weight: 800;
    text-shadow: none;
}

/* dots */
body.candey .dot.active {
    background: var(--cand-primary);
    box-shadow: 0 0 18px rgba(255, 111, 181, 0.22);
}

body.candey .dot.completed {
    background: linear-gradient(135deg, var(--cand-blue), var(--cand-green));
    box-shadow: 0 0 12px rgba(111, 211, 255, 0.18);
}

/* player cards */
body.candey .player {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(250, 250, 255, 0.95));
    border: 1px solid rgba(20, 40, 60, 0.04);
    border-radius: 14px;
    box-shadow: 0 10px 26px rgba(13, 34, 62, 0.06);
}

body.candey .player .name {
    color: #133048;
    font-weight: 800;
}

/* bottom score */
body.candey .score-box {
    background: linear-gradient(180deg, #ffffff, #fff7fb);
    border-radius: 12px;
    border: 1px solid rgba(10, 37, 64, 0.04);
}

body.candey .score {
    color: #133048;
    font-weight: 900;
}

/* timer */
body.candey .timer,
body.candey #timerDisplay {
    color: #133048;
    font-weight: 900;
    background: linear-gradient(135deg, var(--cand-accent), var(--cand-blue));
    border-radius: 50%;
    padding: 10px;
    box-shadow: 0 8px 26px rgba(255, 200, 100, 0.14);
}

/* small candy-like badges for #1 #2 etc */
body.candey .player .rank-badge,
body.candey .score-box .king {
    background: linear-gradient(135deg, var(--cand-primary), var(--cand-blue));
    color: white;
    box-shadow: 0 6px 18px rgba(255, 111, 181, 0.16);
}

body.candey .player.rank-1 .rank-badge.rank-badge--first {
    background: transparent !important;
    box-shadow: none !important;
}

/* round message */
body.candey .round-message {
    color: #0b2540;
    text-shadow: 0 2px 8px rgba(255, 255, 255, 0.8);
}

/* keep contrast strong (force darker text in bright areas) */
body.candey .title,
body.candey .round-label,
body.candey .player .name,
body.candey .score,
body.candey .reveal-btn,
body.candey .ui-btn {
    color: #0b2540 !important;
}

/* small bounce on reveal to feel playful */
body.candey .reveal-btn {
    transition: transform .28s cubic-bezier(.22, .9, .3, 1);
}

body.candey .reveal-btn:active {
    transform: translateY(2px) scale(.995);
}

/* MINI referee preload UI (minimal & clear) */
#refPreloadUI {
    position: fixed;
    left: 12px;
    bottom: 12px;
    z-index: 100002;
    width: 240px;
    background: rgba(0, 0, 0, 0.65);
    color: #fff;
    font-size: 13px;
    border-radius: 10px;
    padding: 10px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    pointer-events: none;
    /* non-interactive */
}

#refPreloadUI .ref-title {
    font-weight: 700;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    gap: 8px;
    align-items: center;
}

#refPreloadUI .ref-title .count {
    font-weight: 800;
    color: #ffd400
}

#refPreloadUI .ref-bar {
    height: 6px;
    width: 100%;
    background: rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 8px;
}

#refPreloadUI .ref-bar>div {
    height: 100%;
    width: 0%;
    transition: width .22s linear;
    background: linear-gradient(90deg, #ffd400, #ff9f00);
}

#refPreloadUI .ref-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 96px;
    overflow: auto;
    padding-right: 6px;
}

.ref-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.ref-item .name {
    opacity: .95
}

.ref-item .status {
    width: 28px;
    text-align: right;
    font-weight: 700
}

.ref-item.loading .status::after {
    content: "…";
    opacity: 0.9
}

.ref-item.ready .status::after {
    content: "✓";
    color: #7af27a
}

.ref-item.error .status::after {
    content: "✕";
    color: #ff6b6b
}

.play-winner-btn {
    position: absolute;
    right: 80px;
    /* adjust if needed */
    top: 50%;
    transform: translateY(-50%);
    padding: 14px 26px;
    font-size: 16px;
    font-weight: 800;
    border-radius: 14px;
    border: none;
    cursor: pointer;
    color: #000;
    background: linear-gradient(135deg, #ffd700, #ffb700);
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.6);
    transition: transform .2s ease, box-shadow .2s ease;
    z-index: 50;
}

.play-winner-btn:hover {
    transform: translateY(-50%) scale(1.06);
    box-shadow: 0 0 40px rgba(255, 215, 0, 0.9);
}

.winner-full-video {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    object-fit: cover;
    background: black;
    z-index: 999999;
    display: none;
}

.play-winner-btn {
    position: fixed;
    right: 120px;
    /* push into empty right area */
    top: 50%;
    transform: translateY(-50%);
    padding: 16px 32px;
    font-size: 18px;
    font-weight: 900;
    border-radius: 16px;
    border: none;
    cursor: pointer;
    color: #000;
    background: linear-gradient(135deg, #ffd700, #ffb700);
    box-shadow: 0 0 35px rgba(255, 215, 0, 0.7);
    transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
    z-index: 100001;
    display: none;
    /* IMPORTANT: hidden by default */
}

.play-winner-btn:hover {
    transform: translateY(-50%) scale(1.08);
    box-shadow: 0 0 55px rgba(255, 215, 0, 1);
    filter: brightness(1.1);
}

/* ===============================
   GOLDEN ROUND POPUP – PREMIUM
   =============================== */

#goldenRulesPopup {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at top,
            rgba(255, 200, 80, 0.12),
            rgba(0, 0, 0, 0.85) 70%);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2147483000;
    animation: goldenFadeIn 0.35s ease;
}

@keyframes goldenFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

#goldenRulesPopup>div {
    width: 520px;
    padding: 28px;
    border-radius: 18px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
        radial-gradient(circle at top, rgba(255, 215, 0, 0.18), transparent 70%);
    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.8),
        inset 0 0 30px rgba(255, 215, 0, 0.15);
    text-align: center;
    color: #fff;
    animation: goldenPop 0.4s cubic-bezier(.2, .9, .3, 1);
}

@keyframes goldenPop {
    from {
        transform: scale(0.92) translateY(10px);
        opacity: 0;
    }

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

/* TITLE */
#goldenRulesPopup .golden-title {
    font-size: 22px;
    font-weight: 900;
    letter-spacing: 2px;
    margin-bottom: 14px;
    color: #ffd54a;
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.6);
}

/* RULE TEXT */
#goldenRulesPopup .golden-rules {
    font-size: 14px;
    line-height: 1.6;
    color: #e9e9e9;
    margin-bottom: 22px;
}

/* BUTTONS */
#goldenRulesPopup button {
    padding: 12px 18px;
    min-width: 120px;
    border-radius: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

#goldenRulesPopup .golden-ok {
    background: linear-gradient(135deg, #ffd700, #ffae00);
    color: #000;
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.6);
}

#goldenRulesPopup .golden-ok:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 35px rgba(255, 215, 0, 0.9);
}

#goldenRulesPopup .golden-cancel {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

#goldenRulesPopup .golden-cancel:hover {
    background: rgba(255, 255, 255, 0.16);
}

/* ===============================
   GOLDEN ROUND POPUP – PREMIUM
   =============================== */

#goldenRulesPopup {
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at top,
            rgba(255, 200, 80, 0.15),
            rgba(0, 0, 0, 0.85) 70%);
    backdrop-filter: blur(14px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2147483000;
}

.golden-card {
    width: 520px;
    padding: 28px;
    border-radius: 20px;
    text-align: center;
    color: #fff;

    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
        radial-gradient(circle at top, rgba(255, 215, 0, 0.22), transparent 70%);

    box-shadow:
        0 35px 90px rgba(0, 0, 0, 0.85),
        inset 0 0 35px rgba(255, 215, 0, 0.2);

    animation: goldenPop 0.45s cubic-bezier(.2, .9, .3, 1);
}

@keyframes goldenPop {
    from {
        opacity: 0;
        transform: scale(0.92) translateY(14px);
    }

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

.golden-title {
    font-size: 22px;
    font-weight: 900;
    letter-spacing: 2px;
    margin-bottom: 16px;
    color: #ffd54a;
    text-shadow: 0 0 14px rgba(255, 215, 0, 0.8);
}

.golden-rules {
    font-size: 14px;
    line-height: 1.7;
    color: #eaeaea;
    margin-bottom: 26px;
}

.golden-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.golden-actions button {
    padding: 12px 20px;
    min-width: 120px;
    border-radius: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
}

.golden-ok {
    background: linear-gradient(135deg, #ffd700, #ffae00);
    color: #000;
    box-shadow: 0 0 28px rgba(255, 215, 0, 0.7);
}

.golden-ok:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 40px rgba(255, 215, 0, 1);
}

.golden-cancel {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.golden-cancel:hover {
    background: rgba(255, 255, 255, 0.18);
}

/* ===============================
   GOLDEN ROUND POPUP – CINEMATIC
   =============================== */

#goldenRulesPopup {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at center,
            rgba(255, 200, 80, 0.18),
            rgba(0, 0, 0, 0.88) 70%);
    backdrop-filter: blur(16px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2147483000;
}

.golden-card {
    width: 540px;
    padding: 34px 36px;
    border-radius: 26px;
    text-align: center;
    color: #fff;
    position: relative;

    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.02)),
        radial-gradient(circle at top, rgba(255, 215, 0, 0.28), transparent 70%);

    box-shadow:
        0 40px 120px rgba(0, 0, 0, 0.9),
        inset 0 0 40px rgba(255, 215, 0, 0.25);

    animation: goldenEntry .5s cubic-bezier(.2, .9, .3, 1);
}

@keyframes goldenEntry {
    from {
        opacity: 0;
        transform: scale(.92) translateY(20px);
    }

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

/* GOLD TITLE */
.golden-title {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 3px;
    margin-bottom: 18px;
    color: #ffd84d;
    text-shadow:
        0 0 18px rgba(255, 215, 0, 0.9),
        0 0 40px rgba(255, 215, 0, 0.4);
}

/* RULE TEXT */
.golden-rules {
    font-size: 15px;
    line-height: 1.8;
    color: #f0f0f0;
    margin-bottom: 30px;
}

/* BUTTON ROW */
.golden-actions {
    display: flex;
    gap: 18px;
    justify-content: center;
}

/* BUTTONS */
.golden-actions button {
    padding: 14px 26px;
    min-width: 140px;
    border-radius: 16px;
    font-weight: 900;
    letter-spacing: 0.6px;
    cursor: pointer;
    border: none;
    transition: all 0.25s ease;
}

/* OK */
.golden-ok {
    background: linear-gradient(135deg, #ffd700, #ff9f00);
    color: #000;
    box-shadow:
        0 0 35px rgba(255, 215, 0, 0.8),
        inset 0 0 6px rgba(255, 255, 255, 0.6);
}

.golden-ok:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow:
        0 0 55px rgba(255, 215, 0, 1);
}

/* CANCEL */
.golden-cancel {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.golden-cancel:hover {
    background: rgba(255, 255, 255, 0.22);
}

/* SUBTLE GOLD EDGE */
.golden-card::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 26px;
    pointer-events: none;
    box-shadow: inset 0 0 0 1px rgba(255, 215, 0, 0.35);
}

.golden-title {
    position: relative;
    font-size: 24px;
    font-weight: 900;
    letter-spacing: 3px;
    margin-bottom: 18px;
    color: #ffd84d;
    text-align: center;
    overflow: hidden;

    text-shadow:
        0 0 14px rgba(255, 215, 0, 0.9),
        0 0 32px rgba(255, 200, 0, 0.5);
}

/* SHINING SLIDE */
.golden-title::after {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 120%;
    height: 100%;

    background: linear-gradient(120deg,
            transparent 30%,
            rgba(255, 255, 255, 0.85) 50%,
            transparent 70%);

    animation: goldenShine 2.8s linear infinite;
}

@keyframes goldenShine {
    from {
        left: -120%;
    }

    to {
        left: 120%;
    }
}

.golden-rules {
    font-size: 15px;
    line-height: 1.8;
    color: rgba(255, 255, 255, 0.95);

    padding: 16px 18px;
    margin-bottom: 26px;

    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    border-radius: 14px;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.15),
        0 8px 30px rgba(0, 0, 0, 0.35);

    pointer-events: none;
    /* 🔒 NOT CLICKABLE */
    user-select: none;
    /* 🔒 NOT SELECTABLE */
}

/* BIGGER RULE TEXT */
.golden-rules {
    font-size: 17px;
    /* was ~15px */
    line-height: 1.9;
    padding: 18px 22px;
}

/* RED HIGHLIGHT FOR 5 SECONDS */
.golden-danger {
    color: #b11226;
    font-weight: 900;
    text-shadow:
        0 0 6px rgba(255, 75, 75, 0.9),
        0 0 14px rgba(255, 75, 75, 0.5);
}

/* OPTIONAL: slightly bigger GOLDEN title */
.golden-title {
    font-size: 26px;
}

/* ===============================
   GOLDEN RULES – CINEMATIC UI
   =============================== */

.golden-rules {
    margin-top: 14px;
    padding: 22px 24px;

    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    border-radius: 18px;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.18),
        0 14px 40px rgba(0, 0, 0, 0.45);

    display: flex;
    flex-direction: column;
    gap: 14px;

    pointer-events: none;
    user-select: none;
}

/* EACH LINE */
.rule-line {
    display: flex;
    align-items: center;
    gap: 12px;

    font-size: 17px;
    color: rgba(255, 255, 255, 0.95);
}

/* ICONS */
.rule-icon {
    font-size: 18px;
    opacity: 0.9;
}

/* HIGHLIGHT WORD (missing) */
.golden-focus {
    color: #ffd84d;
    font-weight: 900;
    text-shadow: 0 0 12px rgba(255, 215, 0, 0.7);
}

/* DANGER LINE */
.rule-line.danger {
    margin-top: 6px;
    padding: 10px 14px;

    background: linear-gradient(90deg,
            rgba(177, 18, 38, 0.25),
            rgba(177, 18, 38, 0.05));

    border-radius: 12px;
}

/* DARK RED TIME */
.golden-danger {
    color: #b11226;
    font-weight: 900;
    margin: 0 4px;

    text-shadow:
        0 0 6px rgba(177, 18, 38, 0.9),
        0 0 14px rgba(177, 18, 38, 0.5);
}


/* REWARD SECTION */
.rule-reward {
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: center;
}

/* +20 BADGE */
.reward-badge {
    padding: 6px 14px;
    border-radius: 999px;

    background: linear-gradient(135deg, #ffd700, #ff9f00);
    color: #000;
    font-weight: 900;
    font-size: 16px;

    box-shadow:
        0 0 22px rgba(255, 215, 0, 0.8);
}

/* TEXT */
.reward-text {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.9);
}

#goldenRulesPopup .golden-focus {
    color: #ff3b3b;
}

#goldenRulesPopup .golden-focus {
    color: #ffd700;
    /* gold restored */
}

#goldenRulesPopup .golden-rules .rule-line:nth-of-type(5) .golden-focus {
    color: #B31B1B;
    /* red penalty text */
}


/* ===============================
   BLUE RECTANGLE REVEAL (CSS ONLY)
   =============================== */

#revealFlashOverlay {
    position: absolute;
    inset: 0;
    background: rgba(70, 120, 255, 0.45);
    backdrop-filter: blur(6px);
    opacity: 0;
    pointer-events: none;
    z-index: 6;
}

/* Trigger flash on REVEAL click */
#revealBtn:active~#revealFlashOverlay {
    animation: blueRevealFlash 0.55s ease-out forwards;
}

/* Animation */
@keyframes blueRevealFlash {
    0% {
        opacity: 0;
    }

    20% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

/* ===============================
   ORANGE CINEMATIC REVEAL OVERLAY
   =============================== */

#revealFlashOverlay {
    position: absolute;
    inset: 0;
    z-index: 6;
    pointer-events: none;

    /* ORANGE CINEMATIC LOOK */
    background:
        linear-gradient(to bottom,
            rgba(255, 140, 40, 0.45),
            rgba(120, 40, 10, 0.55));

    backdrop-filter: blur(10px);
    opacity: 0;
}

/* Trigger on REVEAL click (CSS only) */
#revealBtn:active~#revealFlashOverlay {
    animation: orangeBlurFade 0.8s ease forwards;
}

/* Fade-off animation */
@keyframes orangeBlurFade {
    0% {
        opacity: 0;
        backdrop-filter: blur(14px);
    }

    25% {
        opacity: 1;
        backdrop-filter: blur(18px);
    }

    100% {
        opacity: 0;
        backdrop-filter: blur(0px);
    }
}

/* Gradient burn reveal overlay (image-aligned rectangle) */
.reveal-overlay {
    position: absolute;
    left: 0;
    top: 0;
    width: 0;
    height: 0;
    background:
        radial-gradient(120% 95% at 20% 18%, rgba(255, 244, 195, 0.95) 0%, rgba(255, 185, 95, 0.8) 28%, rgba(255, 94, 43, 0.58) 55%, rgba(120, 18, 8, 0.18) 82%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(135deg, rgba(255, 236, 184, 0.55) 0%, rgba(255, 151, 75, 0.42) 36%, rgba(255, 77, 24, 0.34) 64%, rgba(0, 0, 0, 0) 100%);
    background-blend-mode: screen, soft-light;
    mix-blend-mode: overlay;
    backdrop-filter: blur(6px) saturate(1.08);
    -webkit-backdrop-filter: blur(6px) saturate(1.08);
    border-radius: 14px;
    pointer-events: none;
    z-index: 25;
    opacity: 0;
    will-change: opacity, filter, transform;
}

.reveal-overlay.animate-reveal {
    animation: revealGradientBurnFade 5s ease-out forwards;
}

/* Burn look variants (cycled from JS) */
.reveal-overlay.burn-soft-light-film {
    background:
        radial-gradient(120% 95% at 20% 18%, rgba(255, 244, 195, 0.95) 0%, rgba(255, 185, 95, 0.8) 28%, rgba(255, 94, 43, 0.58) 55%, rgba(120, 18, 8, 0.18) 82%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(135deg, rgba(255, 236, 184, 0.55) 0%, rgba(255, 151, 75, 0.42) 36%, rgba(255, 77, 24, 0.34) 64%, rgba(0, 0, 0, 0) 100%);
    background-blend-mode: screen, soft-light;
    mix-blend-mode: overlay;
}

.reveal-overlay.burn-screen-glow {
    background:
        radial-gradient(135% 100% at 50% 22%, rgba(255, 236, 180, 0.98) 0%, rgba(255, 167, 66, 0.82) 36%, rgba(255, 86, 30, 0.56) 66%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(180deg, rgba(255, 214, 138, 0.45), rgba(255, 110, 36, 0.24));
    background-blend-mode: screen, screen;
    mix-blend-mode: screen;
}

.reveal-overlay.burn-color-dodge-ember {
    background:
        radial-gradient(128% 94% at 28% 16%, rgba(255, 250, 225, 0.95) 0%, rgba(255, 188, 98, 0.8) 26%, rgba(255, 72, 22, 0.62) 60%, rgba(66, 5, 2, 0.18) 86%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(125deg, rgba(255, 210, 120, 0.52), rgba(255, 74, 25, 0.36));
    background-blend-mode: screen, soft-light;
    mix-blend-mode: color-dodge;
}

.reveal-overlay.burn-multiply-smoke {
    background:
        radial-gradient(130% 96% at 28% 18%, rgba(255, 184, 115, 0.74) 0%, rgba(168, 71, 35, 0.58) 36%, rgba(44, 16, 12, 0.5) 72%, rgba(0, 0, 0, 0.02) 100%),
        linear-gradient(145deg, rgba(26, 14, 10, 0.42), rgba(112, 43, 26, 0.24));
    background-blend-mode: multiply, multiply;
    mix-blend-mode: multiply;
}

.reveal-overlay.burn-overlay-heat-haze {
    background:
        radial-gradient(120% 90% at 18% 22%, rgba(255, 240, 192, 0.88) 0%, rgba(255, 168, 92, 0.74) 30%, rgba(255, 98, 44, 0.52) 60%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(140deg, rgba(255, 220, 144, 0.35), rgba(255, 108, 62, 0.28));
    background-blend-mode: screen, soft-light;
    mix-blend-mode: overlay;
}

.reveal-overlay.burn-hard-light-flash {
    background:
        radial-gradient(122% 88% at 32% 18%, rgba(255, 252, 230, 0.98) 0%, rgba(255, 199, 118, 0.88) 24%, rgba(255, 89, 28, 0.65) 56%, rgba(88, 12, 8, 0.14) 84%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(125deg, rgba(255, 240, 180, 0.48), rgba(255, 78, 34, 0.4));
    background-blend-mode: screen, soft-light;
    mix-blend-mode: hard-light;
}

.reveal-overlay.burn-difference-neon {
    background:
        radial-gradient(124% 92% at 30% 20%, rgba(255, 199, 120, 0.92) 0%, rgba(255, 116, 62, 0.68) 34%, rgba(255, 47, 0, 0.52) 62%, rgba(0, 0, 0, 0) 100%),
        linear-gradient(140deg, rgba(255, 223, 163, 0.36), rgba(255, 95, 42, 0.3));
    background-blend-mode: screen, soft-light;
    mix-blend-mode: difference;
}

.reveal-overlay.burn-layered-grain {
    background:
        radial-gradient(126% 96% at 22% 18%, rgba(255, 244, 205, 0.92) 0%, rgba(255, 182, 98, 0.78) 30%, rgba(255, 96, 44, 0.56) 58%, rgba(88, 13, 7, 0.18) 86%, rgba(0, 0, 0, 0) 100%),
        repeating-radial-gradient(circle at 30% 32%, rgba(255, 244, 220, 0.08) 0 1px, rgba(0, 0, 0, 0) 1px 3px),
        linear-gradient(130deg, rgba(255, 232, 175, 0.42), rgba(255, 92, 36, 0.32));
    background-blend-mode: screen, overlay, soft-light;
    mix-blend-mode: overlay;
}

.reveal-overlay.reveal-black-splashes {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.reveal-overlay .splash-blur-circle {
    position: absolute;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    background: rgba(0, 0, 0, var(--circle-a, 0.92));
    filter: blur(var(--circle-blur, 12px));
    -webkit-filter: blur(var(--circle-blur, 12px));
    box-shadow: 0 0 calc(var(--circle-blur, 12px) * 1.15) rgba(0, 0, 0, 0.88);
    pointer-events: none;
}

.reveal-overlay .round-red-tint-layer {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: rgba(210, 0, 0, 0.28);
    mix-blend-mode: multiply;
    pointer-events: none;
    z-index: 0;
}

.dizzy-half-overlay {
    display: none !important;
    position: absolute;
    pointer-events: none;
    z-index: 100007;
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    opacity: 0.95;
    mix-blend-mode: hard-light;
    filter: blur(1.8px) contrast(1.55) saturate(1.7) hue-rotate(-10deg);
    will-change: transform, filter, clip-path, opacity;
    animation: none !important;
}

.dizzy-half-overlay.side-left {
    display: none !important;
    clip-path: polygon(0 0,
            var(--tear-x1, 54%) 0,
            var(--tear-x2, 48%) 18%,
            var(--tear-x3, 56%) 38%,
            var(--tear-x4, 46%) 58%,
            var(--tear-x5, 55%) 78%,
            var(--tear-x6, 47%) 100%,
            0 100%);
}

.dizzy-half-overlay.side-right {
    display: none !important;
    clip-path: polygon(100% 0,
            var(--tear-x1, 54%) 0,
            var(--tear-x2, 48%) 18%,
            var(--tear-x3, 56%) 38%,
            var(--tear-x4, 46%) 58%,
            var(--tear-x5, 55%) 78%,
            var(--tear-x6, 47%) 100%,
            100% 100%);
}

.dizzy-half-overlay::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.12) 0 2px, rgba(0, 0, 0, 0) 2px 5px),
        linear-gradient(115deg, rgba(255, 255, 255, 0.14), rgba(0, 0, 0, 0.18));
    mix-blend-mode: overlay;
    opacity: 0.8;
}

.reveal-overlay.reveal-black-splashes.animate-reveal {
    animation: revealBlackSplashFade 1.9s ease-out forwards;
}

@keyframes revealGradientBurnFade {
    0% {
        opacity: 0.95;
        transform: scale(1);
        filter: brightness(1.08) saturate(1.1);
        backdrop-filter: blur(6px) saturate(1.08);
        -webkit-backdrop-filter: blur(6px) saturate(1.08);
    }

    45% {
        opacity: 0.48;
        transform: scale(1.005);
        filter: brightness(1.03) saturate(1.04);
        backdrop-filter: blur(3px) saturate(1.03);
        -webkit-backdrop-filter: blur(3px) saturate(1.03);
    }

    100% {
        opacity: 0;
        transform: scale(1.01);
        filter: brightness(1) saturate(1);
        backdrop-filter: blur(0px);
        -webkit-backdrop-filter: blur(0px);
    }
}

@keyframes revealBlackSplashFade {
    0% {
        opacity: 1;
        transform: scale(1);
        filter: saturate(0.7);
    }

    45% {
        opacity: 0.45;
        transform: scale(1.004);
        filter: saturate(0.66);
    }

    100% {
        opacity: 0;
        transform: scale(1.008);
        filter: saturate(0.62);
    }
}

@keyframes dizzyHalfJitter {
    0% {
        transform: translate(0, 0) skewX(0deg);
        filter: blur(1.8px) contrast(1.55) saturate(1.7) hue-rotate(-10deg);
    }

    25% {
        transform: translate(-5px, 2px) skewX(-2.5deg);
        filter: blur(2.4px) contrast(1.7) saturate(1.85) hue-rotate(-24deg);
    }

    50% {
        transform: translate(4px, -2px) skewX(2deg);
        filter: blur(1.9px) contrast(1.62) saturate(1.78) hue-rotate(8deg);
    }

    75% {
        transform: translate(-3px, -1px) skewX(-1.8deg);
        filter: blur(2.2px) contrast(1.68) saturate(1.82) hue-rotate(-18deg);
    }

    100% {
        transform: translate(0, 0) skewX(0deg);
        filter: blur(1.8px) contrast(1.55) saturate(1.7) hue-rotate(-10deg);
    }
}

@keyframes dizzyHalfSkew {
    0% {
        opacity: 0.92;
    }

    100% {
        opacity: 1;
    }
}

/* Reveal surprise FX */
.reveal-shock-fx {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 32;
    opacity: 0;
    --fx-cx: 50%;
    --fx-cy: 50%;
}
.reveal-shock-fx.show {
    opacity: 1;
}
.reveal-shock-core,
.reveal-shock-ring {
    position: absolute;
    left: var(--fx-cx);
    top: var(--fx-cy);
    transform: translate(-50%, -50%);
    border-radius: 999px;
}
.reveal-shock-core {
    width: 86px;
    height: 86px;
    background: radial-gradient(circle, rgba(255, 90, 90, 0.9) 0%, rgba(255, 30, 30, 0.36) 45%, rgba(255, 0, 0, 0) 72%);
    filter: blur(0.5px);
    opacity: 0;
}
.reveal-shock-ring {
    width: 40px;
    height: 40px;
    border: 2px solid rgba(255, 130, 130, 0.92);
    box-shadow: 0 0 24px rgba(255, 60, 60, 0.62), inset 0 0 12px rgba(255, 220, 220, 0.38);
    opacity: 0;
}
.reveal-shock-vignette {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at var(--fx-cx) var(--fx-cy), rgba(255, 55, 55, 0.22), rgba(0, 0, 0, 0) 36%),
        radial-gradient(circle at 18% 16%, rgba(255, 45, 45, 0.2), transparent 34%),
        radial-gradient(circle at 84% 78%, rgba(255, 0, 0, 0.14), transparent 30%);
    opacity: 0;
}
.reveal-shock-particles {
    position: absolute;
    inset: 0;
}
.reveal-shock-particles span {
    position: absolute;
    left: var(--fx-cx);
    top: var(--fx-cy);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 35%, #fff7f7, #ff5858 62%, #7a0505 100%);
    box-shadow: 0 0 10px rgba(255, 65, 65, 0.8);
    transform: translate(-50%, -50%) rotate(var(--a)) translateX(0);
    opacity: 0;
}
.reveal-shock-fx.show .reveal-shock-core {
    animation: revealShockCore 0.62s cubic-bezier(.18, .85, .32, 1) forwards;
}
.reveal-shock-fx.show .reveal-shock-ring {
    animation: revealShockRing 0.72s cubic-bezier(.2, .9, .2, 1) forwards;
}
.reveal-shock-fx.show .reveal-shock-vignette {
    animation: revealShockVignette 0.95s ease-out forwards;
}
.reveal-shock-fx.show .reveal-shock-particles span {
    animation: revealShockParticle 0.9s cubic-bezier(.15, .72, .26, 1) forwards;
    animation-delay: var(--delay, 0ms);
}
@keyframes revealShockCore {
    0% { transform: translate(-50%, -50%) scale(0.2); opacity: 0; }
    30% { opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(2.15); opacity: 0; }
}
@keyframes revealShockRing {
    0% { transform: translate(-50%, -50%) scale(0.3); opacity: 0; }
    25% { opacity: 1; }
    100% { transform: translate(-50%, -50%) scale(8.8); opacity: 0; }
}
@keyframes revealShockVignette {
    0% { opacity: 0; }
    18% { opacity: 1; }
    100% { opacity: 0; }
}
@keyframes revealShockParticle {
    0% {
        transform: translate(-50%, -50%) rotate(var(--a)) translateX(0) scale(0.4);
        opacity: 0;
    }
    20% { opacity: 1; }
    100% {
        transform: translate(-50%, -50%) rotate(var(--a)) translateX(var(--d)) scale(0.1);
        opacity: 0;
    }
}

/* ===============================
   ROUND INTRO CINEMATIC SCREEN
   =============================== */

#roundIntroOverlay {
    position: fixed;
    inset: 0;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100500;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

#roundIntroOverlay.show {
    opacity: 1;
    pointer-events: all;
}

.round-intro-inner {
    text-align: center;
}

.round-intro-text {
    font-size: 56px;
    font-weight: 900;
    letter-spacing: 2px;
    color: #fff;
    opacity: 0;
    transform: translateY(20px) scale(0.96);
    animation: roundTextIn 1.2s cubic-bezier(.2, .9, .3, 1) forwards;
    text-shadow:
        0 0 20px rgba(255, 255, 255, 0.25),
        0 0 60px rgba(255, 255, 255, 0.08);
}

@keyframes roundTextIn {
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ===============================
   ROUND INTRO — PREMIUM TYPE STYLE
   =============================== */

#roundIntroOverlay {
    position: fixed;
    inset: 0;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100500;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s ease;
}

#roundIntroOverlay.show {
    opacity: 1;
    pointer-events: all;
}

.round-intro-inner {
    text-align: center;
    color: #fff;
    transform: translateY(6px);
}

.round-intro-icon {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    margin: 0 auto 18px;
    background: radial-gradient(circle at center, #8b5cf6, #3b0764);
    box-shadow: 0 0 24px rgba(139, 92, 246, 0.6);
    opacity: 0;
    animation: fadeUp 0.8s ease forwards;
}

.round-intro-title {
    font-size: 44px;
    font-weight: 800;
    letter-spacing: 1.2px;
    margin-bottom: 10px;
    min-height: 1.2em;
}

.round-intro-sub {
    font-size: 18px;
    font-weight: 500;
    opacity: 0.85;
    margin-bottom: 22px;
    min-height: 1.2em;
}

.round-intro-count {
    font-size: 13px;
    opacity: 0.6;
    letter-spacing: 0.4px;
    min-height: 1.2em;
}

/* subtle rise */
@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

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

.round-intro-title,
.round-intro-sub,
.round-intro-count {
    white-space: pre-wrap;
    /* 🔥 PRESERVE SPACES */
}

/* Bigger round title */
.round-intro-title {
    font-size: 64px;
    /* 🔥 increased */
    font-weight: 900;
    letter-spacing: 1.5px;
    margin-bottom: 14px;
    white-space: pre-wrap;
}

/* Subtitle stays elegant */
.round-intro-sub {
    font-size: 22px;
    font-weight: 500;
    opacity: 0.9;
    white-space: pre-wrap;
}

/* Remove count text visually (kept empty in JS) */
.round-intro-count {
    display: none;
}

/* Round intro: premium text choreography */
#roundIntroOverlay .round-intro-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

#roundIntroOverlay .round-intro-title {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(40px, 5vw, 76px);
    font-weight: 900;
    letter-spacing: 1.6px;
    margin: 0;
    padding: 10px 30px;
    border-radius: 999px;
    border: 1px solid rgba(255, 223, 142, 0.58);
    background:
        linear-gradient(140deg, rgba(255, 236, 175, 0.32), rgba(175, 115, 18, 0.2) 55%, rgba(255, 213, 110, 0.22)),
        radial-gradient(160% 160% at 18% 0%, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #ffe7a8;
    transform: translateY(16px) scale(0.94);
    opacity: 0;
    text-shadow:
        0 10px 28px rgba(0, 0, 0, 0.58),
        0 0 24px rgba(255, 214, 120, 0.24);
    box-shadow:
        0 12px 34px rgba(0, 0, 0, 0.42),
        inset 0 0 0 1px rgba(255, 241, 197, 0.15);
}

#roundIntroOverlay .round-intro-title::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(110deg, transparent 8%, rgba(255, 255, 255, 0.25) 46%, transparent 72%);
    transform: translateX(-120%);
    animation: roundGoldShine 2.5s ease-in-out infinite;
    pointer-events: none;
}

#roundIntroOverlay .round-intro-sub {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 9px 20px;
    border-radius: 999px;
    border: 1px solid rgba(255, 221, 136, 0.52);
    background:
        linear-gradient(145deg, rgba(255, 224, 137, 0.22), rgba(122, 78, 16, 0.2)),
        radial-gradient(120% 120% at 20% 10%, rgba(255, 255, 255, 0.18), rgba(255, 255, 255, 0));
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #ffe7ad;
    font-size: clamp(16px, 2vw, 24px);
    font-weight: 700;
    letter-spacing: 0.35px;
    min-height: 0;
    opacity: 0;
    transform: translateY(12px) scale(0.92);
    box-shadow:
        0 12px 34px rgba(0, 0, 0, 0.42),
        inset 0 0 0 1px rgba(255, 244, 204, 0.12);
}

#roundIntroOverlay.show .round-intro-title {
    animation: roundTitlePremiumIn 0.9s cubic-bezier(.16, .86, .28, 1) forwards;
}

#roundIntroOverlay.show .round-intro-sub {
    animation: roundTagPremiumIn 0.85s cubic-bezier(.2, .85, .3, 1) forwards;
    animation-delay: 0.18s;
}

@keyframes roundTitlePremiumIn {
    0% {
        opacity: 0;
        transform: translateY(18px) scale(0.9);
        filter: blur(6px);
    }

    55% {
        opacity: 1;
        transform: translateY(0) scale(1.03);
        filter: blur(0);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes roundTagPremiumIn {
    0% {
        opacity: 0;
        transform: translateY(12px) scale(0.9);
        filter: blur(4px);
    }

    60% {
        opacity: 1;
        transform: translateY(0) scale(1.04);
        filter: blur(0);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes roundGoldShine {
    0%,
    70%,
    100% {
        transform: translateX(-120%);
        opacity: 0;
    }

    20% {
        transform: translateX(140%);
        opacity: 0.7;
    }
}

/* ROUND INTRO: cinematic premium scene (round-reactive palette) */
#roundIntroOverlay {
    --ri-c1: #2c0f58;
    --ri-c2: #4d1243;
    --ri-c3: #0b2149;
    --ri-c4: #5d1f1f;
    --ri-accent: #9f7cff;
    background: #020205;
    overflow: hidden;
    isolation: isolate;
}

#roundIntroOverlay::before,
#roundIntroOverlay::after {
    content: "";
    position: absolute;
    inset: -24%;
    pointer-events: none;
}

#roundIntroOverlay::before {
    background:
        radial-gradient(46% 54% at 14% 22%, color-mix(in srgb, var(--ri-c1) 84%, transparent), transparent 72%),
        radial-gradient(42% 52% at 86% 26%, color-mix(in srgb, var(--ri-c2) 82%, transparent), transparent 74%),
        radial-gradient(52% 58% at 48% 84%, color-mix(in srgb, var(--ri-c3) 80%, transparent), transparent 76%),
        linear-gradient(130deg, #020205 0%, color-mix(in srgb, var(--ri-c4) 38%, #040509) 100%);
    opacity: 0.96;
    transform-origin: 50% 50%;
    animation: roundGradientFlow 12s cubic-bezier(.35, .08, .26, .98) infinite alternate;
    animation-play-state: paused;
}

#roundIntroOverlay::after {
    background:
        conic-gradient(from 0deg at 50% 50%, transparent 0 24%, color-mix(in srgb, var(--ri-accent) 46%, transparent) 34%, transparent 45% 62%, color-mix(in srgb, #fff 16%, transparent) 72%, transparent 84%),
        radial-gradient(38% 28% at 50% 52%, color-mix(in srgb, var(--ri-accent) 52%, transparent), transparent 74%);
    mix-blend-mode: screen;
    opacity: 0.55;
    filter: blur(24px);
    transform: scale(1.06);
    animation: roundAuraSpin 11s linear infinite;
    animation-play-state: paused;
}

#roundIntroOverlay.show::before,
#roundIntroOverlay.show::after {
    animation-play-state: running;
}

/* Referee turn intro: blacked-out premium screen */
#roundIntroOverlay.referee-turn-intro {
    background: #000 !important;
}

#roundIntroOverlay.referee-turn-intro::before,
#roundIntroOverlay.referee-turn-intro::after {
    opacity: 0 !important;
    animation: none !important;
}

#roundIntroOverlay.referee-turn-intro .round-intro-inner {
    transform: translateY(0) scale(1) !important;
    opacity: 1 !important;
}

#roundIntroOverlay.referee-turn-intro .round-intro-inner::before,
#roundIntroOverlay.referee-turn-intro .round-intro-inner::after {
    opacity: 0 !important;
    animation: none !important;
}

#roundIntroOverlay.referee-turn-intro .round-intro-title {
    font-size: clamp(44px, 6.2vw, 112px) !important;
    letter-spacing: 2.5px !important;
    color: #ffffff !important;
    text-shadow: 0 0 34px rgba(255, 255, 255, 0.35), 0 0 80px rgba(120, 170, 255, 0.22) !important;
}

#roundIntroOverlay.referee-turn-intro .round-intro-title::before {
    content: none !important;
}

#roundIntroOverlay.referee-turn-intro .round-intro-sub {
    margin-top: 14px;
    font-size: clamp(16px, 1.6vw, 26px) !important;
    letter-spacing: 1.4px !important;
    color: rgba(230, 238, 255, 0.86) !important;
    text-transform: uppercase;
}

#roundIntroOverlay.referee-turn-intro .round-intro-count {
    display: none !important;
}

.round-intro-inner {
    position: relative;
    z-index: 2;
    isolation: isolate;
}

.round-intro-inner::before,
.round-intro-inner::after {
    content: "";
    position: absolute;
    left: 50%;
    top: 50%;
    pointer-events: none;
}

.round-intro-inner::before {
    width: min(72vw, 860px);
    height: min(40vw, 470px);
    transform: translate(-50%, -50%);
    background:
        radial-gradient(68% 70% at 50% 56%, color-mix(in srgb, var(--ri-accent) 28%, transparent), transparent 76%),
        radial-gradient(56% 64% at 50% 52%, rgba(255, 255, 255, 0.12), transparent 76%);
    filter: blur(14px);
    opacity: .9;
    animation: roundHaloBreathe 4.8s ease-in-out infinite;
}

.round-intro-inner::after {
    width: min(54vw, 640px);
    height: min(54vw, 640px);
    transform: translate(-50%, -52%);
    border-radius: 50%;
    border: 1px solid color-mix(in srgb, var(--ri-accent) 46%, rgba(255, 255, 255, 0.2));
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.05) inset,
        0 0 44px color-mix(in srgb, var(--ri-accent) 30%, transparent);
    opacity: 0;
    animation: roundRingPulse 2.6s cubic-bezier(.2, .8, .2, 1) infinite;
}

.round-intro-icon {
    background: radial-gradient(circle at 35% 35%, #fff, var(--ri-accent));
    box-shadow: 0 0 28px color-mix(in srgb, var(--ri-accent) 60%, transparent);
    transform: translateZ(0);
    animation: roundIconFloat 2.8s ease-in-out infinite;
}

.round-intro-title {
    color: #fff;
    padding: .26em .9em;
    border-radius: 999px;
    border: 1px solid color-mix(in srgb, var(--ri-accent) 30%, rgba(255, 255, 255, 0.18));
    background:
        linear-gradient(130deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05) 52%, rgba(255, 255, 255, 0.14)),
        linear-gradient(140deg, color-mix(in srgb, var(--ri-c1) 52%, #08090f), color-mix(in srgb, var(--ri-c2) 42%, #07080e));
    backdrop-filter: blur(8px) saturate(120%);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.52),
        inset 0 1px 0 rgba(255, 255, 255, 0.35);
    text-shadow:
        0 8px 28px rgba(0, 0, 0, 0.62),
        0 0 20px color-mix(in srgb, var(--ri-accent) 38%, transparent);
}

.round-intro-sub {
    color: color-mix(in srgb, #fff 92%, var(--ri-accent) 8%);
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.48);
}

@keyframes roundGradientFlow {
    0% {
        transform: translate3d(-2%, -1.2%, 0) scale(1.03) rotate(-2deg);
    }

    50% {
        transform: translate3d(2.2%, 1.6%, 0) scale(1.08) rotate(2deg);
    }

    100% {
        transform: translate3d(-1.2%, 1.6%, 0) scale(1.06) rotate(-1deg);
    }
}

@keyframes roundAuraSpin {
    0% {
        opacity: 0.3;
        transform: scale(1.02) rotate(0deg);
    }

    50% {
        opacity: 0.66;
        transform: scale(1.08) rotate(180deg);
    }

    100% {
        opacity: 0.3;
        transform: scale(1.02) rotate(360deg);
    }
}

@keyframes roundHaloBreathe {
    0%,
    100% {
        opacity: .68;
        transform: translate(-50%, -50%) scale(.95);
    }

    50% {
        opacity: .94;
        transform: translate(-50%, -50%) scale(1.04);
    }
}

@keyframes roundRingPulse {
    0% {
        opacity: 0;
        transform: translate(-50%, -52%) scale(.62);
    }

    35% {
        opacity: .62;
    }

    100% {
        opacity: 0;
        transform: translate(-50%, -52%) scale(1.18);
    }
}

@keyframes roundIconFloat {
    0%,
    100% {
        transform: translateY(0);
        filter: drop-shadow(0 0 16px color-mix(in srgb, var(--ri-accent) 42%, transparent));
    }

    50% {
        transform: translateY(-6px) scale(1.04);
        filter: drop-shadow(0 0 26px color-mix(in srgb, var(--ri-accent) 62%, transparent));
    }
}

/* WIN PREDICTOR UI */
.prediction-container {
    position: fixed;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 1000px;
    background: rgba(15, 15, 25, 0.7);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px 20px;
    z-index: 9999;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.prediction-header {
    font-size: 10px;
    font-weight: 800;
    color: #8b5cf6;
    margin-bottom: 10px;
    text-align: center;
    letter-spacing: 2px;
}

.live-indicator {
    animation: blink 1.5s infinite;
}

@keyframes blink {
    50% {
        opacity: 0.3;
    }
}

.round-score-container {
    position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    width: 88%;
    max-width: 900px;
    background: rgba(12, 12, 18, 0.78);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 8px 12px 10px;
    z-index: 9999;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
}

.round-score-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 6px;
}

.round-score-title {
    font-weight: 800;
    color: #9ae6ff;
}

.round-score-sub {
    font-weight: 700;
    color: rgba(255, 255, 255, 0.65);
}

.round-score-grid {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.round-score-axis,
.round-score-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.rs-name {
    width: 56px;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    color: #ffffff;
}

.rs-name.axis-label {
    font-size: 9px;
    color: rgba(255, 255, 255, 0.55);
    letter-spacing: 1px;
}

.rs-boxes {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    gap: 4px;
}

.rs-axis {
    font-size: 9px;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
}

.rs-axis.is-current {
    color: #ffffff;
    font-weight: 800;
}

.rs-axis.is-empty {
    opacity: 0.2;
}

.rs-box {
    height: 10px;
    border-radius: 3px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.rs-box.is-miss {
    background: #ff2d2d;
    border-color: #ff2d2d;
    box-shadow: 0 0 8px rgba(255, 45, 45, 0.6);
}

.rs-box.is-hit {
    background: #22c55e;
    border-color: rgba(34, 197, 94, 0.8);
    box-shadow: 0 0 8px rgba(34, 197, 94, 0.6);
}

.rs-box.is-current {
    outline: 1px solid rgba(255, 255, 255, 0.8);
    outline-offset: 1px;
}

.rs-box.is-empty {
    opacity: 0.2;
}

@media (max-width: 720px) {
    .round-score-container {
        width: 94%;
        padding: 8px 10px 10px;
    }

    .rs-name {
        width: 46px;
        font-size: 10px;
    }

    .rs-box {
        height: 8px;
    }
}

.prediction-grid {
    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.predict-card {
    flex: 1;
    position: relative;
    transition: all 0.4s ease;
}

.predict-info {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 5px;
}

.p-name {
    font-size: 14px;
    font-weight: 700;
    color: #fff;
}

.p-votes {
    font-size: 9px;
    color: #00ffa3;
    background: rgba(0, 255, 163, 0.1);
    padding: 2px 6px;
    border-radius: 4px;
}

.progress-bg {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 4px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #8b5cf6, #d946ef);
    transition: width 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.5);
}

.p-percent {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
}

/* Winner Highlight */
.is-winning {
    transform: scale(1.05);
}

.is-winning .progress-fill {
    background: linear-gradient(90deg, #00ffa3, #00d1ff);
    box-shadow: 0 0 15px rgba(0, 255, 163, 0.6);
}

.is-winning .p-name {
    color: #00ffa3;
}

/* ===============================
   LIVE VOTES – BIG & BOLD
   =============================== */

[id^="votes-"] {
    font-size: 15px;
    /* ⬆️ increase size (try 14–16 if needed) */
    font-weight: 800;
    /* 🔥 bold */
    letter-spacing: 0.6px;
    /* premium broadcast feel */
    color: #00E676;
    /* readable + modern (optional) */
    text-shadow: 0 0 6px rgba(156, 255, 234, 0.35);
}

/* CINEMATIC REVEAL TILES */
.cinematic-reveal {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 6px;
    pointer-events: none;
    z-index: 6;
    opacity: 0;
}

.cinematic-reveal.show {
    opacity: 1;
}

.cinematic-tile {
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(10px);
    animation: tileReveal 600ms cubic-bezier(0.2, 0.9, 0.2, 1) forwards;
    border-radius: 8px;
}

@keyframes tileReveal {
    0% { opacity: 1; transform: scale(1); }
    100% { opacity: 0; transform: scale(0.98); }
}

/* ===========================
   Lucky Card UI
   =========================== */
.lucky-card-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100001;
    background: rgba(0, 0, 0, 0);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, background 0.35s ease;
}
.lucky-card-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    background: radial-gradient(circle at 20% 20%, rgba(255, 190, 64, 0.22), rgba(0, 0, 0, 0.95) 50%);
}
.lucky-card-panel {
    width: min(920px, 92vw);
    padding: 30px 28px 24px;
    border-radius: 24px;
    background:
        radial-gradient(140% 120% at 50% 0%, rgba(255, 205, 97, 0.28), rgba(14, 12, 18, 0.96) 60%),
        linear-gradient(135deg, rgba(24, 20, 34, 0.98), rgba(9, 8, 12, 1));
    border: 1px solid rgba(255, 204, 99, 0.45);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.8), 0 0 35px rgba(255, 196, 79, 0.25);
    text-align: center;
    animation: luckyPop 0.45s cubic-bezier(.2, .9, .3, 1);
}
.lucky-card-title {
    font-size: 22px;
    letter-spacing: 1px;
    font-weight: 900;
    color: #ffe0a1;
    text-transform: uppercase;
    text-shadow: 0 0 16px rgba(255, 204, 102, 0.35);
}
.lucky-card-sub {
    margin-top: 6px;
    font-size: 12px;
    letter-spacing: 1px;
    color: rgba(255, 245, 220, 0.72);
    text-transform: uppercase;
}
.lucky-card-stage {
    position: relative;
    margin-top: 18px;
    display: flex;
    justify-content: center;
}
.lucky-card-focus {
    position: absolute;
    inset: 0;
    z-index: 18;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 16px;
    letter-spacing: 0.9px;
    color: #fff3c8;
    text-transform: uppercase;
    font-weight: 900;
    line-height: 1.25;
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid rgba(255, 221, 140, 0.55);
    background: linear-gradient(135deg, rgba(255, 207, 116, 0.24), rgba(70, 45, 8, 0.62));
    backdrop-filter: blur(3px);
    box-shadow: 0 0 20px rgba(255, 195, 90, 0.2), inset 0 0 0 1px rgba(255, 240, 200, 0.08);
    transition: opacity .2s ease, transform .2s ease, color .18s ease, text-shadow .18s ease, border-color .18s ease, background .18s ease;
    animation: luckyFocusPulse 1.8s ease-in-out infinite;
    pointer-events: none;
}
.lucky-card-stage:not(.is-locked) .lucky-card-focus {
    opacity: 0;
    transform: scale(0.98);
}
@keyframes luckyFocusPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 20px rgba(255, 195, 90, 0.2), inset 0 0 0 1px rgba(255, 240, 200, 0.08);
    }
    50% {
        transform: scale(1.015);
        box-shadow: 0 0 28px rgba(255, 205, 110, 0.36), inset 0 0 0 1px rgba(255, 245, 212, 0.14);
    }
}
.lucky-card-grid {
    margin-top: 0;
    display: grid;
    width: 100%;
    max-width: 908px;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 10px;
}
.lucky-card-grid.is-locked {
    pointer-events: none;
}
.lucky-card-grid.is-locked .lucky-card {
    position: relative;
}
.lucky-card-grid.is-locked .lucky-card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 6;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.45);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
    pointer-events: none;
}
.lucky-card-grid.is-locked .lucky-card::after {
    content: "🔒";
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 7;
    font-size: 30px;
    text-shadow: 0 0 16px rgba(255, 220, 140, 0.7);
    pointer-events: none;
}
.lucky-card-actions {
    margin-top: 18px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.lucky-card-shuffle,
.monster-card-shuffle {
    min-width: 140px;
    padding: 12px 18px;
    border-radius: 14px;
    border: 1px solid rgba(255,255,255,0.18);
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 0.7px;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease, opacity .18s ease;
}
.lucky-card-shuffle {
    background: linear-gradient(135deg, #ffe38a 0%, #ffbf3c 48%, #ff9f00 100%);
    color: #2b1800;
    border-color: rgba(255, 233, 170, 0.95);
    box-shadow: 0 16px 36px rgba(0,0,0,0.32), 0 0 28px rgba(255,205,90,0.38);
    text-shadow: 0 1px 0 rgba(255, 248, 221, 0.45);
}
.monster-card-shuffle {
    background: linear-gradient(135deg, rgba(255, 99, 99, 0.28), rgba(85, 10, 10, 0.8));
    color: #ffe0e0;
    box-shadow: 0 14px 34px rgba(0,0,0,0.34), 0 0 20px rgba(255,80,80,0.18);
}
.lucky-card-shuffle:hover,
.monster-card-shuffle:hover {
    transform: translateY(-2px);
}
.lucky-card-shuffle:hover {
    box-shadow: 0 20px 40px rgba(0,0,0,0.36), 0 0 34px rgba(255, 210, 100, 0.55);
}
.lucky-card-shuffle:disabled,
.monster-card-shuffle:disabled {
    opacity: 0.45;
    cursor: default;
    transform: none;
}
.lucky-card {
    cursor: pointer;
    perspective: 900px;
    height: 140px;
}
.lucky-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(.2, .7, .3, 1), filter 0.25s ease;
}
.lucky-card.selected .lucky-card-inner {
    transform: rotateY(180deg);
}
.lucky-card-face {
    position: absolute;
    inset: 0;
    border-radius: 10px;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border: 1px solid rgba(255, 214, 128, 0.4);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.4);
}
.lucky-card-back {
    background:
        radial-gradient(120px 80px at 20% 20%, rgba(255, 225, 130, 0.35), transparent 60%),
        linear-gradient(145deg, #2b243a, #14111d);
}
.lucky-card-back-label {
    max-width: 68%;
    max-height: 48%;
    width: auto;
    height: auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}
.lucky-card-front {
    transform: rotateY(180deg);
    background:
        radial-gradient(120px 80px at 80% 20%, rgba(255, 255, 255, 0.1), transparent 60%),
        linear-gradient(145deg, #201c2d, #100f17);
    color: #fff;
    position: relative;
    overflow: hidden;
}
.lucky-card-name {
    margin-top: 7px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.4px;
}
.lucky-card-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 215, 130, 0.95);
    box-shadow: 0 0 12px rgba(255, 210, 110, 0.35);
}
.lucky-card-bonus {
    position: absolute;
    right: 7px;
    top: 7px;
    padding: 3px 7px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 900;
    letter-spacing: 0.3px;
    color: #201300;
    background: linear-gradient(135deg, #fff0be, #ffbe4d);
    box-shadow: 0 8px 18px rgba(255, 179, 67, 0.45);
    opacity: 0;
    transform: translateY(8px) scale(0.85);
}
.lucky-card-bonus.burst {
    animation: luckyBonusBurst 0.7s cubic-bezier(.2, .9, .3, 1) forwards;
}
.lucky-card:not(.selected):hover .lucky-card-inner {
    filter: brightness(1.08);
    transform: translateY(-2px);
}
.lucky-card.illusion {
    cursor: pointer;
}
.lucky-card.illusion .lucky-card-inner {
    filter: grayscale(0.25) brightness(0.92);
}
.lucky-card.illusion .lucky-card-front {
    background:
        radial-gradient(120px 80px at 80% 20%, rgba(255, 255, 255, 0.06), transparent 60%),
        linear-gradient(145deg, #1a1922, #100f16);
}
.lucky-card.illusion .lucky-card-name,
.lucky-card.illusion .lucky-card-bonus {
    display: none;
}
.lucky-card.illusion.illusion-hit .lucky-card-inner {
    animation: luckyIllusionPulse 0.4s ease;
}
.lucky-card.lucky-winner .lucky-card-front {
    border-color: rgba(80, 255, 145, 0.75);
    box-shadow: 0 0 26px rgba(60, 220, 120, 0.55), inset 0 0 24px rgba(50, 190, 100, 0.25);
}
.lucky-card.lucky-winner .lucky-card-img {
    border-color: rgba(110, 255, 160, 0.95);
    box-shadow: 0 0 22px rgba(70, 235, 130, 0.7);
}
.lucky-card.lucky-winner .lucky-card-bonus {
    background: linear-gradient(135deg, #dbffe8, #57e38e);
    color: #08331b;
    box-shadow: 0 10px 22px rgba(56, 210, 122, 0.55);
}
.lucky-card.dimmed {
    opacity: 0.04;
    filter: grayscale(1) blur(1.5px);
    transform: scale(0.9);
    transition: opacity .35s ease, filter .35s ease, transform .35s ease;
    pointer-events: none;
}
.lucky-card-ok {
    margin-top: 20px;
    padding: 10px 18px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #ffd778, #d59a21);
    color: #241806;
    font-weight: 900;
    letter-spacing: 1px;
    cursor: pointer;
    opacity: 0.6;
    box-shadow: 0 8px 24px rgba(160, 106, 10, 0.35);
}
.lucky-card-ok:enabled {
    opacity: 1;
}
.lucky-card-ok:enabled:hover {
    filter: brightness(0.96);
    transform: translateY(-1px);
}
@keyframes luckyPop {
    0% {
        transform: translateY(10px) scale(0.98);
        opacity: 0;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}
@keyframes luckyBonusBurst {
    0% {
        opacity: 0;
        transform: translateY(10px) scale(0.75);
    }
    30% {
        opacity: 1;
        transform: translateY(0) scale(1.08);
    }
    100% {
        opacity: 0.95;
        transform: translateY(0) scale(1);
    }
}
@keyframes luckyIllusionPulse {
    0% { transform: scale(1); }
    50% { transform: scale(0.95); }
    100% { transform: scale(1); }
}

/* ===========================
   Power Card UI
   =========================== */
.power-card-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100002;
    background: rgba(0, 0, 0, 0);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, background 0.35s ease;
}
.power-card-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    background: rgba(0, 0, 0, 0.95);
}
.power-card-panel {
    width: min(920px, 92vw);
    padding: 28px 28px 22px;
    border-radius: 22px;
    background: rgba(14, 14, 18, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.7);
    text-align: center;
    animation: powerPop 0.45s cubic-bezier(.2, .9, .3, 1);
}
.power-card-title {
    font-size: 22px;
    letter-spacing: 1px;
    font-weight: 900;
    color: #f5d56a;
    text-transform: uppercase;
}
.power-card-sub {
    margin-top: 6px;
    font-size: 12px;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.7);
    text-transform: uppercase;
}
.power-card-grid {
    margin-top: 18px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 16px;
}
.power-card {
    cursor: pointer;
    perspective: 900px;
    height: 200px;
}
.power-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(.2, .7, .3, 1);
}
.power-card.revealed .power-card-inner {
    transform: rotateY(180deg);
}
.power-card-face {
    position: absolute;
    inset: 0;
    border-radius: 16px;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.35);
}
.power-card-back {
    background:
        radial-gradient(120px 80px at 20% 20%, rgba(255, 217, 120, 0.35), transparent 60%),
        linear-gradient(145deg, #1d1d25, #0e0e12);
    color: #f3d26c;
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
}
.power-card-front {
    transform: rotateY(180deg);
    background:
        radial-gradient(120px 80px at 80% 20%, rgba(255, 255, 255, 0.12), transparent 60%),
        linear-gradient(145deg, #11121a, #1f2330);
    color: #fff;
}
.power-card-img {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid rgba(255, 215, 100, 0.9);
    box-shadow: 0 0 18px rgba(255, 215, 100, 0.35);
}
.power-card-name {
    margin-top: 10px;
    font-size: 16px;
    font-weight: 800;
    letter-spacing: 1px;
}
.power-card.dimmed {
    opacity: 0.4;
    transform: scale(0.98);
    filter: grayscale(0.5);
    pointer-events: none;
}
.power-card-ok {
    margin-top: 20px;
    padding: 10px 18px;
    border-radius: 12px;
    border: none;
    background: #f5d56a;
    color: #1b1b1b;
    font-weight: 800;
    letter-spacing: 1px;
    cursor: pointer;
    opacity: 0.6;
}
.power-card-ok:enabled {
    opacity: 1;
}
.power-card-ok:enabled:hover {
    filter: brightness(0.95);
    transform: translateY(-1px);
}
.power-card-activate {
    position: fixed;
    left: 18px;
    bottom: 18px;
    z-index: 100003;
    display: none;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 14px;
    border: 1px solid rgba(255, 215, 100, 0.7);
    background: rgba(20, 18, 10, 0.85);
    color: #f7e39a;
    font-weight: 800;
    letter-spacing: 0.6px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
    cursor: pointer;
}
.power-card-activate.show {
    display: flex;
}
.power-card-activate.armed {
    border-color: rgba(173, 110, 255, 0.9);
    color: #ead6ff;
    background: rgba(70, 24, 110, 0.9);
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.45);
}
.power-card-activate.armed .power-card-icon {
    background: radial-gradient(circle at 40% 40%, #f0e6ff, #b68cff 60%, #7c3aed 100%);
    box-shadow: 0 0 14px rgba(167, 116, 255, 0.8);
}
.power-card-activate.expired {
    border-color: rgba(255, 80, 80, 0.9);
    color: #ff6b6b;
    background: rgba(35, 35, 35, 0.9);
    box-shadow: 0 10px 30px rgba(255, 80, 80, 0.25);
    cursor: not-allowed;
    filter: grayscale(0.6);
}
.power-card-activate.expired .power-card-icon {
    background: radial-gradient(circle at 40% 40%, #ffe2e2, #ff7a7a 60%, #b91c1c 100%);
    box-shadow: 0 0 10px rgba(255, 80, 80, 0.55);
}
.power-card-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: radial-gradient(circle at 40% 40%, #fff7d1, #f5c954 60%, #c98918 100%);
    box-shadow: 0 0 14px rgba(245, 201, 84, 0.7);
}
.power-card-activate:hover {
    filter: brightness(1.05);
    transform: translateY(-1px);
}
@keyframes powerPop {
    0% {
        transform: translateY(8px) scale(0.98);
        opacity: 0;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* White outline that traces the image area on reveal */
.reveal-outline {
    position: absolute;
    left: 0;
    top: 0;
    width: 0;
    height: 0;
    opacity: 0;
    pointer-events: none;
    z-index: 30;
}

.reveal-outline svg {
    width: 100%;
    height: 100%;
    display: block;
}

.reveal-outline-rect {
    fill: none;
    stroke: rgba(255, 255, 255, 0.95);
    stroke-width: 4;
    stroke-linecap: round;
    stroke-linejoin: round;
    filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.55));
}

.reveal-outline.animate-outline {
    opacity: 1;
}

.reveal-outline.animate-outline .reveal-outline-rect {
    animation: outlineDraw 2.6s cubic-bezier(0.2, 0.75, 0.2, 1) forwards;
}

@keyframes outlineDraw {
    0% {
        stroke-dashoffset: var(--outline-length, 0);
        opacity: 0.2;
    }
    20% {
        opacity: 1;
    }
    100% {
        stroke-dashoffset: 0;
        opacity: 0.9;
    }
}

.power-card-message {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100004;
    background: rgba(0, 0, 0, 0.0);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, background 0.35s ease;
}
.power-card-message.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    background: rgba(0, 0, 0, 0.85);
}
.power-card-message-text {
    max-width: min(900px, 90vw);
    font-size: 32px;
    font-weight: 900;
    letter-spacing: 1px;
    text-align: center;
    color: #f5d56a;
    text-shadow: 0 0 18px rgba(245, 213, 106, 0.3);
}

/* ===========================
   Monster Card UI
   =========================== */
.monster-card-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 100005;
    background: rgba(0, 0, 0, 0);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.35s ease, background 0.35s ease;
}
.monster-card-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    background: rgba(0, 0, 0, 0.95);
}
.monster-card-panel {
    width: min(920px, 92vw);
    padding: 30px 28px 24px;
    border-radius: 24px;
    background:
        radial-gradient(140% 120% at 50% 0%, rgba(150, 0, 0, 0.75), rgba(10, 0, 0, 0.95) 60%),
        linear-gradient(135deg, rgba(40, 0, 0, 0.95), rgba(5, 0, 0, 0.98));
    border: 1px solid rgba(255, 80, 80, 0.45);
    box-shadow: 0 25px 70px rgba(0, 0, 0, 0.8), 0 0 35px rgba(255, 30, 30, 0.25);
    text-align: center;
    position: relative;
    overflow: hidden;
    animation: monsterPop 0.45s cubic-bezier(.2, .9, .3, 1);
}
.monster-card-panel::before,
.monster-card-panel::after {
    content: "";
    position: absolute;
    top: -18px;
    width: 36px;
    height: 36px;
    background: linear-gradient(135deg, #ff3b3b, #4b0505);
    clip-path: polygon(50% 0, 0 100%, 100% 100%);
    filter: drop-shadow(0 6px 8px rgba(0, 0, 0, 0.6));
}
.monster-card-panel::before {
    left: 20px;
}
.monster-card-panel::after {
    right: 20px;
    transform: scaleX(-1);
}
.monster-card-title {
    font-size: 22px;
    letter-spacing: 1px;
    font-weight: 900;
    color: #ffb0b0;
    text-transform: uppercase;
    text-shadow: 0 0 12px rgba(255, 40, 40, 0.5);
}
.monster-card-sub {
    margin-top: 6px;
    font-size: 12px;
    letter-spacing: 1px;
    color: rgba(255, 200, 200, 0.7);
    text-transform: uppercase;
}
.monster-card-grid {
    margin-top: 18px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 10px;
}
.monster-card-actions {
    margin-top: 18px;
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}
.monster-card-grid.is-shuffling {
    animation: monsterGridPulse 1.6s ease-in-out infinite;
}
.lucky-card-grid.is-shuffling {
    animation: monsterGridPulse 1.6s ease-in-out infinite;
}
.lucky-card-grid.is-shuffling .lucky-card,
.monster-card-grid.is-shuffling .monster-card {
    z-index: 2;
}
.lucky-card-grid.is-shuffling .lucky-card .lucky-card-inner,
.monster-card-grid.is-shuffling .monster-card .monster-card-inner {
    animation: cardShuffleSpin .6s ease-in-out infinite alternate;
}
.monster-card {
    cursor: pointer;
    perspective: 900px;
    height: 140px;
}
.monster-card-grid.is-shuffling .monster-card {
    filter: saturate(1.15) drop-shadow(0 0 8px rgba(255, 70, 70, 0.18));
    pointer-events: none;
}
.monster-card-grid.is-shuffling .monster-card .monster-card-inner {
    animation: monsterCardTilt 0.34s ease-in-out infinite alternate;
}
.monster-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(.2, .7, .3, 1);
}
.monster-card-peek {
    position: absolute;
    inset: 0;
    z-index: 4;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border-radius: 10px;
    border: 1px solid rgba(255, 92, 92, 0.45);
    background:
        radial-gradient(120px 80px at 80% 20%, rgba(255, 255, 255, 0.1), transparent 60%),
        linear-gradient(145deg, rgba(36, 0, 0, 0.92), rgba(75, 15, 15, 0.96));
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 1s ease, visibility 1s ease;
}
.monster-card-grid.show-peek .monster-card-peek {
    opacity: 1;
    visibility: visible;
}
.monster-card-grid.show-peek.fade-peek .monster-card-peek {
    opacity: 0;
    visibility: hidden;
}
.monster-card-peek-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 95, 95, 0.95);
    box-shadow: 0 0 12px rgba(255, 60, 60, 0.35);
}
.monster-card-peek-name {
    margin-top: 7px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.4px;
    color: #fff;
}
.monster-card.revealed .monster-card-inner {
    transform: rotateY(180deg);
}
.monster-card-face {
    position: absolute;
    inset: 0;
    border-radius: 10px;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border: 1px solid rgba(255, 80, 80, 0.35);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.45);
}
.monster-card-back {
    background:
        radial-gradient(120px 80px at 20% 20%, rgba(255, 0, 0, 0.35), transparent 60%),
        linear-gradient(145deg, #1a0000, #0b0000);
}
.monster-card-back-icon {
    max-width: 68%;
    max-height: 42%;
    width: auto;
    height: auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}
.monster-card-front {
    transform: rotateY(180deg);
    background:
        radial-gradient(120px 80px at 80% 20%, rgba(255, 255, 255, 0.08), transparent 60%),
        linear-gradient(145deg, #1c0000, #2a0b0b);
    color: #fff;
    position: relative;
    overflow: hidden;
}
.monster-card-front::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(180px 120px at 50% 20%, rgba(255, 30, 30, 0.55), rgba(120, 0, 0, 0.1) 60%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}
.monster-card-img {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 80, 80, 0.9);
    box-shadow: 0 0 12px rgba(255, 60, 60, 0.35);
}
.monster-card-name {
    margin-top: 7px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0.4px;
}
.monster-card-score {
    margin-top: 5px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.2px;
    color: #ffb3b3;
    opacity: 0;
    transition: opacity 0.2s ease;
}
.monster-card.revealed .monster-card-score {
    opacity: 1;
}
.monster-card.dimmed {
    opacity: 0.4;
    transform: scale(0.98);
    filter: grayscale(0.6);
    pointer-events: none;
}
.monster-card.hit {
    animation: monsterShake 0.55s linear;
}
.monster-card.hit .monster-card-front {
    box-shadow: 0 0 26px rgba(255, 0, 0, 0.65);
}
.monster-card.hit .monster-card-front::after {
    opacity: 1;
    animation: monsterPulse 0.6s ease;
}
.monster-card-ok {
    margin-top: 20px;
    padding: 10px 18px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #ff4b4b, #b00000);
    color: #fff;
    font-weight: 800;
    letter-spacing: 1px;
    cursor: pointer;
    opacity: 0.6;
    box-shadow: 0 8px 24px rgba(120, 0, 0, 0.45);
}
.monster-card-ok:enabled {
    opacity: 1;
}
.monster-card-ok:enabled:hover {
    filter: brightness(0.95);
    transform: translateY(-1px);
}
@keyframes monsterPop {
    0% {
        transform: translateY(10px) scale(0.98);
        opacity: 0;
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}
@keyframes monsterShake {
    0% { transform: translateX(0); }
    20% { transform: translateX(-6px); }
    40% { transform: translateX(6px); }
    60% { transform: translateX(-4px); }
    80% { transform: translateX(4px); }
    100% { transform: translateX(0); }
}
@keyframes monsterPulse {
    0% { opacity: 0.2; }
    40% { opacity: 0.8; }
    100% { opacity: 0.2; }
}
@keyframes monsterGridPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.01); }
    100% { transform: scale(1); }
}

@keyframes cardShuffleSpin {
    from {
        transform: rotate(-5deg) scale(0.98);
    }
    to {
        transform: rotate(5deg) scale(1.02);
    }
}
@keyframes monsterCardTilt {
    0% { filter: brightness(0.95); }
    100% { filter: brightness(1.08); }
}

/* ===========================
   Monster Pick Alert
   =========================== */
.monster-pick-alert {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100050;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background: rgba(0, 0, 0, 0.85);
    transition: opacity 0.3s ease;
}

/* ===========================
   Reveal Button: New Look
   =========================== */
#revealBtn.reveal-btn {
    position: absolute;
    z-index: 100030;
    min-width: 200px;
    padding: 13px 26px;
    border: 1px solid rgba(120, 228, 255, 0.7);
    border-radius: 999px;
    color: #e9fbff;
    font-size: 17px;
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
    background:
        linear-gradient(140deg, rgba(4, 24, 36, 0.92), rgba(5, 51, 72, 0.9)),
        radial-gradient(120% 180% at 20% 10%, rgba(71, 214, 255, 0.24), rgba(0, 0, 0, 0));
    box-shadow:
        0 10px 28px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(180, 246, 255, 0.3) inset,
        0 0 22px rgba(64, 226, 255, 0.4);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
}

#revealBtn.reveal-btn::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 20%, rgba(190, 250, 255, 0.5) 50%, transparent 80%);
    transform: translateX(-140%);
    transition: transform 0.55s ease;
}

#revealBtn.reveal-btn::after {
    content: "";
    position: absolute;
    inset: 2px;
    border-radius: inherit;
    border: 1px solid rgba(125, 232, 255, 0.24);
    pointer-events: none;
}

#revealBtn.reveal-btn:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow:
        0 16px 36px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(189, 251, 255, 0.4) inset,
        0 0 30px rgba(95, 232, 255, 0.6);
    filter: saturate(1.1);
}

#revealBtn.reveal-btn:hover::before {
    transform: translateX(140%);
}

#revealBtn.reveal-btn:active {
    transform: translateY(0) scale(0.98);
    filter: saturate(0.95);
}

/* NEXT button styled to match the new REVEAL button look */
#nextBtn.next-top {
    position: absolute;
    z-index: 100030;
    right: -275px;
    min-width: 200px;
    padding: 13px 26px;
    border: 1px solid rgba(120, 228, 255, 0.7);
    border-radius: 999px;
    color: #e9fbff;
    font-size: 17px;
    font-weight: 900;
    letter-spacing: 2px;
    text-transform: uppercase;
    background:
        linear-gradient(140deg, rgba(4, 24, 36, 0.92), rgba(5, 51, 72, 0.9)),
        radial-gradient(120% 180% at 20% 10%, rgba(71, 214, 255, 0.24), rgba(0, 0, 0, 0));
    box-shadow:
        0 10px 28px rgba(0, 0, 0, 0.55),
        0 0 0 1px rgba(180, 246, 255, 0.3) inset,
        0 0 22px rgba(64, 226, 255, 0.4);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
    overflow: hidden;
    transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
}

#nextBtn.next-top::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(110deg, transparent 20%, rgba(190, 250, 255, 0.5) 50%, transparent 80%);
    transform: translateX(-140%);
    transition: transform 0.55s ease;
}

#nextBtn.next-top::after {
    content: "";
    position: absolute;
    inset: 2px;
    border-radius: inherit;
    border: 1px solid rgba(125, 232, 255, 0.24);
    pointer-events: none;
}

#nextBtn.next-top:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow:
        0 16px 36px rgba(0, 0, 0, 0.6),
        0 0 0 1px rgba(189, 251, 255, 0.4) inset,
        0 0 30px rgba(95, 232, 255, 0.6);
    filter: saturate(1.1);
}

#nextBtn.next-top:hover::before {
    transform: translateX(140%);
}

#nextBtn.next-top:active {
    transform: translateY(0) scale(0.98);
    filter: saturate(0.95);
}

/* ===========================
   Round 33 Prompt
   =========================== */
.round33-prompt {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 22px;
    z-index: 100110;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background:
        radial-gradient(55% 45% at 18% 15%, rgba(0, 220, 255, 0.18), transparent 70%),
        radial-gradient(40% 35% at 82% 85%, rgba(255, 180, 20, 0.16), transparent 72%),
        rgba(4, 9, 20, 0.86);
    backdrop-filter: blur(12px);
    transition: opacity .3s ease, visibility .3s ease;
}
.round33-prompt.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.round33-prompt-card {
    width: min(560px, 94vw);
    border-radius: 24px;
    padding: 28px 26px 24px;
    text-align: center;
    border: 1px solid rgba(126, 206, 255, 0.38);
    background:
        linear-gradient(170deg, rgba(255, 255, 255, 0.12), rgba(255, 255, 255, 0.02) 42%),
        linear-gradient(140deg, rgba(16, 44, 76, 0.95), rgba(8, 17, 33, 0.96));
    box-shadow:
        0 28px 70px rgba(0, 0, 0, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.24),
        0 0 40px rgba(65, 178, 255, 0.16);
    transform: translateY(12px) scale(0.97);
    opacity: 0;
    animation: round33PromptIn .42s cubic-bezier(.2, .9, .3, 1) forwards;
}
.round33-prompt-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 28px;
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.2px;
    color: #b7ebff;
    border: 1px solid rgba(153, 224, 255, 0.4);
    background: rgba(31, 110, 156, 0.35);
}
.round33-prompt-title {
    margin-top: 14px;
    font-size: clamp(32px, 6.5vw, 56px);
    font-weight: 900;
    letter-spacing: 1.4px;
    color: #f6fbff;
    text-shadow: 0 10px 34px rgba(43, 186, 255, 0.34);
}
.round33-prompt-text {
    margin-top: 8px;
    font-size: clamp(15px, 2.8vw, 22px);
    font-weight: 700;
    letter-spacing: 1.1px;
    color: #9fe7ff;
}
.round33-prompt-ok {
    margin-top: 22px;
    border: 0;
    border-radius: 12px;
    min-width: 132px;
    padding: 11px 18px;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 1px;
    color: #032338;
    background: linear-gradient(135deg, #7ce8ff, #49c4ff);
    cursor: pointer;
    box-shadow: 0 12px 24px rgba(30, 148, 210, 0.35);
    transition: transform .18s ease, filter .18s ease, box-shadow .18s ease;
}
.round33-prompt-ok:hover {
    filter: brightness(1.03);
    transform: translateY(-1px);
    box-shadow: 0 16px 26px rgba(30, 148, 210, 0.44);
}
@keyframes round33PromptIn {
    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

/* ===========================
   Round 23 Team-up UI
   =========================== */
.round23-team-overlay,
.round23-award-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 100115;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background:
        radial-gradient(58% 50% at 18% 16%, rgba(255, 198, 64, 0.24), transparent 72%),
        radial-gradient(42% 38% at 84% 82%, rgba(88, 255, 168, 0.2), transparent 74%),
        rgba(6, 10, 20, 0.88);
    backdrop-filter: blur(12px);
    transition: opacity .28s ease, visibility .28s ease;
}
.round23-team-overlay.show,
.round23-award-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.round23-team-card,
.round23-award-card {
    width: min(960px, 94vw);
    border-radius: 24px;
    border: 1px solid rgba(244, 209, 118, 0.45);
    background:
        linear-gradient(155deg, rgba(34, 24, 8, 0.95), rgba(18, 14, 8, 0.96)),
        radial-gradient(140% 120% at 50% 0%, rgba(255, 224, 132, 0.15), transparent 70%);
    box-shadow:
        0 26px 68px rgba(0, 0, 0, 0.62),
        0 0 42px rgba(255, 201, 95, 0.16);
    padding: 26px 24px 22px;
}
.round23-team-chip,
.round23-award-chip {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 5px 13px;
    border: 1px solid rgba(255, 221, 138, 0.45);
    color: #ffe9b0;
    background: rgba(120, 84, 16, 0.4);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.1px;
}
.round23-team-title,
.round23-award-title {
    margin-top: 12px;
    font-size: clamp(28px, 5.4vw, 50px);
    font-weight: 900;
    letter-spacing: 1.2px;
    color: #fff6d8;
    text-shadow: 0 0 24px rgba(255, 212, 118, 0.35);
}
.round23-team-sub,
.round23-award-sub {
    margin-top: 6px;
    color: rgba(255, 240, 202, 0.9);
    font-size: 14px;
    letter-spacing: 0.4px;
}
.round23-team-pairs {
    margin-top: 18px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}
.round23-team-pair {
    border-radius: 16px;
    border: 1px solid rgba(255, 213, 126, 0.28);
    background: rgba(18, 12, 3, 0.78);
    padding: 12px 10px 10px;
    position: relative;
}
.round23-link-line {
    position: absolute;
    left: 50%;
    top: 44%;
    width: 78px;
    height: 4px;
    transform: translate(-50%, -50%);
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(255, 205, 110, 0.2), rgba(255, 205, 110, 0.88), rgba(255, 205, 110, 0.2));
    box-shadow: 0 0 16px rgba(255, 201, 92, 0.32);
}
.round23-team-cards {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}
.round23-select-card {
    border: 0;
    background: transparent;
    padding: 0;
    cursor: pointer;
    perspective: 900px;
    height: 170px;
}
.round23-select-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    transition: transform .52s cubic-bezier(.2, .8, .3, 1);
}
.round23-select-card.selected .round23-select-inner {
    transform: rotateY(180deg);
}
.round23-select-face {
    position: absolute;
    inset: 0;
    border-radius: 12px;
    backface-visibility: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    border: 1px solid rgba(255, 213, 126, 0.4);
}
.round23-select-back {
    color: #ffd788;
    font-size: 11px;
    font-weight: 900;
    letter-spacing: 1px;
    background:
        radial-gradient(90px 65px at 18% 22%, rgba(255, 194, 74, 0.25), transparent 65%),
        linear-gradient(145deg, #1d1305, #2a1706);
}
.round23-select-front {
    transform: rotateY(180deg);
    background:
        radial-gradient(95px 70px at 78% 20%, rgba(255, 255, 255, 0.1), transparent 60%),
        linear-gradient(145deg, #2a1a05, #3b2108);
}
.round23-select-img {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 220, 134, 0.92);
    box-shadow: 0 0 14px rgba(255, 206, 84, 0.36);
}
.round23-select-name {
    margin-top: 8px;
    color: #fff3d3;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.5px;
}
.round23-team-tag {
    margin-top: 10px;
    min-height: 20px;
    text-align: center;
    color: #ffd866;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 0.8px;
    opacity: 0;
    transition: opacity .25s ease;
}
.round23-team-pair.complete .round23-team-tag {
    opacity: 1;
}
.round23-team-confirm,
.round23-award-done {
    margin-top: 16px;
    border: 0;
    border-radius: 12px;
    padding: 11px 20px;
    min-width: 160px;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 1px;
    color: #2e1f00;
    background: linear-gradient(135deg, #ffe493, #f6b93a);
    box-shadow: 0 12px 24px rgba(255, 188, 58, 0.26);
    cursor: pointer;
}
.round23-award-actions {
    margin-top: 16px;
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
}
.round23-award-actions .round23-award-done {
    margin-top: 0;
}
.round23-award-close {
    margin-top: 0;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 12px;
    padding: 11px 20px;
    min-width: 130px;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 1px;
    color: #eef4ff;
    background: linear-gradient(135deg, rgba(52, 61, 82, 0.95), rgba(33, 40, 56, 0.95));
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.28);
    cursor: pointer;
}
.round23-award-close:hover {
    filter: brightness(1.06);
}
.round23-team-confirm:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}
.round23-award-teams {
    margin-top: 16px;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}
.round23-award-team {
    border: 1px solid rgba(156, 250, 187, 0.42);
    border-radius: 16px;
    background: rgba(15, 36, 25, 0.55);
    padding: 14px 12px;
    position: relative;
    overflow: hidden;
    color: #dfffe9;
    cursor: pointer;
    transition: background .22s ease, transform .2s ease, border-color .2s ease;
}
.round23-award-team:hover {
    background: rgba(14, 138, 68, 0.95);
    border-color: rgba(166, 255, 195, 0.9);
    transform: translateY(-2px);
}
.round23-award-members {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}
.round23-award-player {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    letter-spacing: 0.3px;
}
.round23-award-player img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(166, 255, 195, 0.72);
}
.round23-award-plus {
    font-size: 20px;
    font-weight: 900;
    color: #b8ffd1;
}
.round23-award-tag {
    margin-top: 10px;
    text-align: center;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 1px;
    color: #b8ffd1;
}
.round23-award-tick {
    position: absolute;
    right: 10px;
    top: 10px;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 35% 30%, #fff, #bfffd7 45%, #31c46d 100%);
    color: #08371c;
    font-size: 19px;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0 0 0 0 rgba(95, 245, 146, 0.55);
    opacity: 0;
    transform: scale(0.4) rotate(-18deg);
    pointer-events: none;
}
.round23-award-team.awarded {
    opacity: 0.9;
    filter: saturate(1.1);
    cursor: default;
}
.round23-award-team.awarded .round23-award-tick {
    opacity: 1;
    transform: scale(1) rotate(0deg);
    animation: round23TickPop .52s cubic-bezier(.15, .9, .25, 1), round23TickPulse 1.05s ease-out .1s 1;
}

@keyframes round23TickPop {
    0% { opacity: 0; transform: scale(0.35) rotate(-22deg); }
    55% { opacity: 1; transform: scale(1.16) rotate(4deg); }
    100% { opacity: 1; transform: scale(1) rotate(0deg); }
}

@keyframes round23TickPulse {
    0% { box-shadow: 0 0 0 0 rgba(95, 245, 146, 0.55); }
    100% { box-shadow: 0 0 0 14px rgba(95, 245, 146, 0); }
}

.round23-noref-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    z-index: 100116;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    background:
        radial-gradient(55% 45% at 22% 18%, rgba(255, 88, 88, 0.26), transparent 74%),
        radial-gradient(45% 40% at 82% 84%, rgba(92, 185, 255, 0.2), transparent 72%),
        rgba(6, 10, 20, 0.88);
    backdrop-filter: blur(12px);
    transition: opacity .26s ease, visibility .26s ease;
}
.round23-noref-overlay.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.round23-noref-card {
    width: min(700px, 92vw);
    border-radius: 24px;
    border: 1px solid rgba(255, 143, 143, 0.46);
    background:
        radial-gradient(145% 130% at 50% 0%, rgba(255, 149, 149, 0.2), transparent 62%),
        linear-gradient(150deg, rgba(42, 14, 14, 0.96), rgba(18, 10, 22, 0.95));
    box-shadow:
        0 24px 62px rgba(0, 0, 0, 0.62),
        0 0 38px rgba(255, 92, 92, 0.2);
    padding: 26px 24px 22px;
    text-align: center;
}
.round23-noref-chip {
    display: inline-flex;
    min-height: 28px;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    padding: 5px 13px;
    border: 1px solid rgba(255, 173, 173, 0.52);
    color: #ffd1d1;
    background: rgba(120, 36, 36, 0.45);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1px;
}
.round23-noref-icons {
    margin-top: 12px;
    display: flex;
    justify-content: center;
    gap: 12px;
}
.round23-noref-icon {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 28px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 185, 185, 0.4);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.round23-noref-title {
    margin-top: 12px;
    font-size: clamp(28px, 5vw, 46px);
    font-weight: 900;
    letter-spacing: 1px;
    color: #ffe2e2;
    text-shadow: 0 0 22px rgba(255, 120, 120, 0.34);
}
.round23-noref-sub {
    margin-top: 10px;
    display: grid;
    gap: 6px;
    color: rgba(255, 229, 229, 0.94);
    font-size: 15px;
    letter-spacing: 0.3px;
}
.round23-noref-ok {
    margin-top: 16px;
    border: 0;
    border-radius: 12px;
    padding: 11px 20px;
    min-width: 152px;
    font-size: 14px;
    font-weight: 900;
    letter-spacing: 1px;
    color: #2f0e12;
    background: linear-gradient(135deg, #ffd1d1, #ff8f8f);
    box-shadow: 0 12px 24px rgba(255, 121, 121, 0.28);
    cursor: pointer;
}
@media (max-width: 900px) {
    .round23-team-pairs,
    .round23-award-teams {
        grid-template-columns: 1fr;
    }
    .round23-select-card {
        height: 156px;
    }
}

/* ===========================
   Section Completion Gate
   =========================== */
.section-complete-gate {
    position: absolute;
    inset: 0;
    z-index: 100040;
    display: flex;
    align-items: center;
    justify-content: center;
    background:
        radial-gradient(circle at 20% 20%, rgba(50, 180, 255, 0.14), transparent 40%),
        radial-gradient(circle at 80% 80%, rgba(130, 220, 255, 0.12), transparent 42%),
        rgba(6, 10, 18, 0.78);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.section-complete-card {
    width: min(520px, 86%);
    border-radius: 20px;
    padding: 26px 24px 22px;
    border: 1px solid rgba(145, 235, 255, 0.35);
    background:
        linear-gradient(155deg, rgba(7, 22, 36, 0.92), rgba(7, 40, 58, 0.86));
    box-shadow:
        0 20px 54px rgba(0, 0, 0, 0.56),
        inset 0 0 0 1px rgba(210, 250, 255, 0.14);
}

.section-complete-title {
    text-align: center;
    font-size: 30px;
    line-height: 1.05;
    font-weight: 900;
    letter-spacing: 1.8px;
    color: #e9fbff;
    text-shadow: 0 0 24px rgba(102, 232, 255, 0.4);
    margin-bottom: 6px;
}

.section-complete-sub {
    text-align: center;
    font-size: 13px;
    letter-spacing: 0.8px;
    color: rgba(224, 246, 255, 0.8);
    margin-bottom: 18px;
}

.section-slide-track {
    position: relative;
    height: 62px;
    border-radius: 999px;
    border: 1px solid rgba(147, 236, 255, 0.42);
    background: linear-gradient(160deg, rgba(4, 19, 31, 0.95), rgba(9, 52, 72, 0.9));
    overflow: hidden;
    user-select: none;
    touch-action: none;
    box-shadow:
        inset 0 0 0 1px rgba(211, 251, 255, 0.12),
        inset 0 -18px 30px rgba(0, 0, 0, 0.25);
}

.section-slide-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0%;
    border-radius: inherit;
    background:
        linear-gradient(90deg, rgba(27, 170, 255, 0.78), rgba(97, 239, 255, 0.9));
    box-shadow: 0 0 24px rgba(80, 220, 255, 0.5);
}

.section-slide-label {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 1.2px;
    color: rgba(223, 250, 255, 0.92);
    text-transform: uppercase;
    pointer-events: none;
}

.section-slide-knob {
    position: absolute;
    top: 6px;
    left: 0%;
    transform: translateX(0);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 1px solid rgba(182, 243, 255, 0.6);
    background:
        radial-gradient(circle at 35% 30%, #ffffff, #c1f2ff 40%, #6ad8ff 100%);
    color: #06354a;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 30px;
    font-weight: 900;
    line-height: 1;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.7);
    box-shadow:
        0 8px 20px rgba(0, 0, 0, 0.45),
        0 0 16px rgba(117, 234, 255, 0.65);
    pointer-events: none;
}

.section-complete-gate.done .section-slide-label {
    color: #06212f;
}

#nextBtn.section-gate-locked,
#nextBtn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    filter: grayscale(0.35) saturate(0.6);
}
.monster-pick-alert.show {
    opacity: 1;
    visibility: visible;
}
.monster-pick-alert::before,
.monster-pick-alert::after {
    content: "";
    position: absolute;
    inset: -15%;
    pointer-events: none;
}
.monster-pick-alert::before {
    background:
        radial-gradient(38% 34% at 18% 20%, rgba(255, 40, 40, 0.35), transparent 70%),
        radial-gradient(40% 36% at 84% 18%, rgba(200, 0, 0, 0.3), transparent 72%),
        radial-gradient(52% 44% at 52% 84%, rgba(140, 0, 0, 0.35), transparent 74%);
    filter: blur(26px);
    animation: monsterAlertBgShift 5.8s ease-in-out infinite;
}
.monster-pick-alert::after {
    background: linear-gradient(110deg, transparent 18%, rgba(255, 130, 130, 0.16) 48%, transparent 82%);
    transform: translateX(-120%) skewX(-18deg);
    animation: monsterAlertSweep 2.2s ease-in-out infinite;
}
.monster-pick-alert-inner {
    width: min(760px, 90vw);
    position: relative;
    text-align: center;
    padding: 34px 26px 30px;
    border-radius: 20px;
    background:
        radial-gradient(120% 140% at 50% 0%, rgba(255, 42, 42, 0.26), rgba(16, 4, 4, 0.96) 62%),
        linear-gradient(145deg, rgba(32, 8, 8, 0.96), rgba(8, 2, 2, 0.98));
    border: 1px solid rgba(255, 105, 105, 0.45);
    box-shadow: 0 22px 60px rgba(0, 0, 0, 0.78), 0 0 34px rgba(255, 40, 40, 0.35);
    transform: translateY(18px) scale(0.94);
    opacity: 0;
}
.monster-pick-alert.show .monster-pick-alert-inner {
    animation: monsterAlertIn 0.55s cubic-bezier(.16, .9, .24, 1) forwards;
}
.monster-pick-alert-title {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0;
}
.monster-pick-alert-title-gif {
    max-width: min(92%, 340px);
    max-height: clamp(64px, 16vw, 118px);
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 0 18px rgba(255, 72, 72, 0.4));
}
.monster-pick-alert-name {
    margin-top: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 20px;
    border-radius: 999px;
    border: 1px solid rgba(255, 150, 150, 0.52);
    background: linear-gradient(130deg, rgba(255, 96, 96, 0.34), rgba(120, 0, 0, 0.26));
    color: #fff2f2;
    font-size: clamp(20px, 3vw, 34px);
    font-weight: 900;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    box-shadow: 0 12px 34px rgba(0, 0, 0, 0.48), inset 0 0 0 1px rgba(255, 255, 255, 0.1);
}
.monster-pick-alert-sub {
    margin-top: 12px;
    color: rgba(255, 224, 224, 0.88);
    font-size: clamp(14px, 2vw, 20px);
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
@keyframes monsterAlertIn {
    0% {
        transform: translateY(18px) scale(0.94);
        opacity: 0;
        filter: blur(3px);
    }
    60% {
        transform: translateY(-2px) scale(1.02);
        opacity: 1;
        filter: blur(0);
    }
    100% {
        transform: translateY(0) scale(1);
        opacity: 1;
        filter: blur(0);
    }
}
@keyframes monsterAlertBgShift {
    0%, 100% { transform: translate3d(-1%, -1%, 0) scale(1); }
    50% { transform: translate3d(1.4%, 1.2%, 0) scale(1.04); }
}
@keyframes monsterAlertSweep {
    0%, 22% { transform: translateX(-120%) skewX(-18deg); opacity: 0; }
    42% { opacity: 0.85; }
    70%, 100% { transform: translateX(220%) skewX(-18deg); opacity: 0; }
}

/* ===============================
   NEON -> PURPLE PREMIUM OVERRIDE
   (UI only, logic untouched)
=============================== */
body.neon {
    background: linear-gradient(180deg, #2b0f52 0%, #1a0a36 38%, #120726 68%, #0a0416 100%) !important;
}

body.neon::before {
    content: none !important;
    display: none !important;
}

body.neon .title,
body.neon .glass-title {
    color: #d1a7ff !important;
    text-shadow: 0 0 14px rgba(168, 96, 255, 0.62), 0 0 34px rgba(108, 56, 210, 0.45) !important;
}

body.neon .ui-btn {
    border: 1px solid rgba(166, 94, 255, 0.38) !important;
    background: linear-gradient(145deg, rgba(26, 14, 46, 0.94), rgba(34, 18, 56, 0.88)) !important;
    color: #cfadff !important;
    box-shadow: 0 8px 20px rgba(12, 6, 24, 0.45) !important;
}

body.neon .ui-btn:hover {
    border-color: rgba(182, 116, 255, 0.7) !important;
    box-shadow: 0 10px 24px rgba(132, 86, 255, 0.28) !important;
}

body.neon .ui-btn.active {
    background: linear-gradient(135deg, #8f46ff, #622bc8) !important;
    border-color: rgba(199, 127, 255, 0.72) !important;
    box-shadow: 0 0 18px rgba(163, 102, 255, 0.78), 0 0 34px rgba(121, 73, 255, 0.46) !important;
    color: #eed0ff !important;
}

body.neon .round-system,
body.neon .round-score-container,
body.neon .canvas-area,
body.neon .player,
body.neon .score-box,
body.neon .score-section {
    border-color: rgba(171, 114, 255, 0.38) !important;
    box-shadow:
        0 0 0 1px rgba(140, 82, 222, 0.24) inset,
        0 0 24px rgba(125, 78, 255, 0.34) !important;
}

body.neon .round-system,
body.neon .round-score-container,
body.neon .score-section {
    background: linear-gradient(145deg, rgba(28, 12, 56, 0.96), rgba(16, 8, 34, 0.96)) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
}

body.neon .dot.active,
body.neon .round-dot.active,
body.neon .section-dot.active {
    background: #a35bff !important;
    box-shadow: 0 0 10px rgba(167, 96, 255, 0.88), 0 0 24px rgba(117, 62, 214, 0.72) !important;
}

body.neon .dot.completed,
body.neon .round-dot.completed,
body.neon .section-dot.completed {
    background: #9b63ff !important;
    box-shadow: 0 0 12px rgba(155, 99, 255, 0.7) !important;
}

body.neon .timer-circle {
    filter: drop-shadow(0 0 8px rgba(174, 114, 255, 0.75));
}

body.neon #revealBtn.reveal-btn,
body.neon #nextBtn.next-top,
body.neon .show-answer-btn {
    border-color: rgba(175, 102, 255, 0.82) !important;
    color: #ddbbff !important;
    background: linear-gradient(140deg, rgba(70, 32, 122, 0.98), rgba(94, 42, 158, 0.98)) !important;
    box-shadow:
        0 12px 28px rgba(10, 5, 18, 0.55),
        0 0 0 1px rgba(136, 72, 224, 0.38) inset,
        0 0 26px rgba(145, 83, 255, 0.52) !important;
}

body.neon #revealBtn.reveal-btn::before,
body.neon #nextBtn.next-top::before {
    display: none !important;
    content: none !important;
}

body.neon #revealBtn.reveal-btn::after,
body.neon #nextBtn.next-top::after {
    display: none !important;
    content: none !important;
}

body.neon #revealBtn.reveal-btn:hover,
body.neon #nextBtn.next-top:hover,
body.neon .show-answer-btn:hover {
    box-shadow:
        0 16px 34px rgba(8, 4, 18, 0.62),
        0 0 0 1px rgba(174, 108, 255, 0.48) inset,
        0 0 34px rgba(173, 110, 255, 0.66) !important;
}

/* ==========================================
   PROFESSIONAL LAYOUT OVERRIDE (FINAL LAYER)
   ========================================== */
/*
body.neon {
    --pro-bg-1: #081321;
    --pro-bg-2: #0d1b2e;
    --pro-bg-3: #111f33;
    --pro-card: rgba(11, 24, 40, 0.82);
    --pro-border: rgba(149, 182, 219, 0.28);
    --pro-title: #e8f2ff;
    --pro-text: #c2d6ef;
    --pro-accent: #3d8bfd;
    --pro-accent-2: #57b2ff;
    --pro-warm: #ef9f2c;
    font-family: "Manrope", "Segoe UI", sans-serif !important;
    color: var(--pro-title) !important;
    background:
        radial-gradient(1200px 420px at 82% -8%, rgba(87, 178, 255, 0.14), transparent 64%),
        radial-gradient(1000px 360px at 16% 12%, rgba(61, 139, 253, 0.16), transparent 68%),
        linear-gradient(165deg, var(--pro-bg-1) 0%, var(--pro-bg-2) 42%, var(--pro-bg-3) 100%) !important;
}

body.neon .title,
body.neon .glass-title {
    top: 20px !important;
    left: 24px !important;
    padding: 12px 18px !important;
    border-radius: 14px !important;
    border: 1px solid var(--pro-border) !important;
    font-family: "Sora", "Manrope", sans-serif !important;
    font-size: clamp(1.2rem, 2vw, 1.95rem) !important;
    letter-spacing: 0.03em !important;
    color: var(--pro-title) !important;
    background: linear-gradient(145deg, rgba(16, 30, 50, 0.86), rgba(12, 22, 37, 0.78)) !important;
    text-shadow: none !important;
    box-shadow: 0 10px 30px rgba(5, 10, 18, 0.4) !important;
}

body.neon .ui-switcher {
    position: absolute !important;
    top: 18px !important;
    right: 24px !important;
    left: auto !important;
    width: auto !important;
    max-width: min(58vw, 800px) !important;
    display: flex !important;
    justify-content: flex-end !important;
    gap: 8px !important;
    padding: 8px 10px !important;
    border: 1px solid var(--pro-border) !important;
    border-radius: 14px !important;
    background: linear-gradient(145deg, rgba(12, 24, 40, 0.72), rgba(8, 18, 32, 0.72)) !important;
    backdrop-filter: blur(10px) !important;
}

body.neon .ui-btn {
    border: 1px solid rgba(128, 170, 214, 0.34) !important;
    border-radius: 10px !important;
    background: rgba(10, 28, 45, 0.9) !important;
    color: var(--pro-text) !important;
    font-family: "Sora", "Manrope", sans-serif !important;
    font-size: 11px !important;
    letter-spacing: 0.05em !important;
    box-shadow: none !important;
}

body.neon .ui-btn.active {
    border-color: rgba(95, 176, 255, 0.84) !important;
    color: #f4faff !important;
    background: linear-gradient(135deg, var(--pro-accent), var(--pro-accent-2)) !important;
    box-shadow: 0 8px 24px rgba(66, 149, 255, 0.35) !important;
}

body.neon .round-system {
    top: 82px !important;
    left: 24px !important;
    right: 24px !important;
    width: auto !important;
    margin: 0 !important;
    padding: 10px 14px !important;
    border-radius: 16px !important;
    border: 1px solid var(--pro-border) !important;
    background: linear-gradient(145deg, rgba(11, 23, 38, 0.9), rgba(8, 16, 28, 0.88)) !important;
    box-shadow: 0 14px 34px rgba(4, 10, 18, 0.42) !important;
}

body.neon .round-score-container {
    top: 92px !important;
    left: min(38vw, 460px) !important;
    width: min(35vw, 670px) !important;
    border: 1px solid var(--pro-border) !important;
    border-radius: 14px !important;
    background: linear-gradient(145deg, rgba(13, 27, 44, 0.88), rgba(9, 19, 31, 0.82)) !important;
    box-shadow: 0 10px 30px rgba(4, 10, 20, 0.35) !important;
}

body.neon .canvas-area {
    top: 205px !important;
    left: 24px !important;
    right: 24px !important;
    width: auto !important;
    height: calc(100vh - 320px) !important;
    min-height: 430px !important;
    margin: 0 !important;
    border: 1px solid var(--pro-border) !important;
    border-radius: 18px !important;
    overflow: hidden !important;
    background:
        radial-gradient(700px 260px at 75% -5%, rgba(93, 170, 255, 0.11), transparent 64%),
        linear-gradient(145deg, rgba(10, 22, 36, 0.93), rgba(7, 17, 30, 0.95)) !important;
    box-shadow:
        0 24px 50px rgba(4, 8, 16, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.05) !important;
}

body.neon #frameImage {
    width: min(73%, 960px) !important;
    max-height: 90% !important;
    border-radius: 12px !important;
}

body.neon .timer-circle {
    top: 50% !important;
    left: 26% !important;
    transform: translate(-50%, -50%) !important;
    filter: drop-shadow(0 8px 22px rgba(72, 152, 255, 0.45)) !important;
}

body.neon #revealBtn.reveal-btn {
    top: 50% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
}

body.neon .player-panel {
    position: absolute !important;
    top: 50% !important;
    right: 32px !important;
    transform: translateY(-50%) !important;
    width: min(264px, 24vw) !important;
    display: flex !important;
    gap: 12px !important;
}

body.neon .player {
    border: 1px solid var(--pro-border) !important;
    border-radius: 14px !important;
    padding: 10px 12px !important;
    background: linear-gradient(140deg, rgba(13, 28, 46, 0.9), rgba(10, 19, 34, 0.85)) !important;
    box-shadow: 0 10px 24px rgba(4, 8, 16, 0.3) !important;
}

body.neon .player .name {
    color: #e6f2ff !important;
    font-size: 1.55rem !important;
}

body.neon .plus,
body.neon .minus {
    background: #19334f !important;
    color: #dbeeff !important;
    border: 1px solid rgba(125, 172, 221, 0.28) !important;
    border-radius: 8px !important;
}

body.neon .plus:hover,
body.neon .minus:hover {
    background: #244a72 !important;
}

body.neon .show-answer-btn {
    position: absolute !important;
    right: 0 !important;
    top: calc(100% + 14px) !important;
    width: 220px !important;
    border: 1px solid rgba(137, 187, 235, 0.46) !important;
    border-radius: 12px !important;
    font-family: "Sora", "Manrope", sans-serif !important;
    color: #eef7ff !important;
    background: linear-gradient(135deg, #246fc8, #315b9e) !important;
    box-shadow: 0 10px 26px rgba(15, 45, 82, 0.45) !important;
}

body.neon #nextBtn.next-top {
    border-color: rgba(137, 187, 235, 0.48) !important;
    background: linear-gradient(135deg, #225f9f, #2f4f7f) !important;
}

body.neon .score-section {
    height: 86px !important;
    border-top: 1px solid var(--pro-border) !important;
    background: linear-gradient(145deg, rgba(10, 22, 35, 0.94), rgba(8, 16, 27, 0.95)) !important;
    box-shadow: 0 -10px 32px rgba(4, 8, 16, 0.4) !important;
}

body.neon .score-panel {
    width: min(1000px, calc(100vw - 60px)) !important;
    justify-content: space-evenly !important;
    gap: 16px !important;
}

body.neon .score-box {
    min-width: 170px !important;
    height: 50px !important;
    border: 1px solid rgba(138, 177, 214, 0.32) !important;
    border-radius: 12px !important;
    background: linear-gradient(145deg, rgba(14, 30, 50, 0.9), rgba(10, 20, 36, 0.88)) !important;
    box-shadow: 0 10px 22px rgba(5, 10, 18, 0.32) !important;
}

body.neon .score,
body.neon .name.small {
    color: #e6f2ff !important;
}

body.neon .player.rank-1,
body.neon .score-box.top-player {
    border-color: rgba(239, 159, 44, 0.7) !important;
    box-shadow: 0 0 0 1px rgba(239, 159, 44, 0.32) inset, 0 12px 26px rgba(109, 75, 18, 0.34) !important;
}

@media (max-width: 1280px) {
    body.neon .round-score-container {
        display: none !important;
    }

    body.neon .canvas-area {
        top: 192px !important;
        height: calc(100vh - 306px) !important;
    }

    body.neon .player-panel {
        width: 250px !important;
    }
}

@media (max-width: 980px) {
    body.neon .ui-switcher {
        left: 24px !important;
        right: 24px !important;
        max-width: none !important;
        justify-content: flex-start !important;
        overflow-x: auto !important;
        scrollbar-width: thin !important;
    }

    body.neon .round-system {
        top: 134px !important;
    }

    body.neon .canvas-area {
        top: 250px !important;
        height: calc(100vh - 394px) !important;
        min-height: 330px !important;
    }

    body.neon .timer-circle {
        left: 22% !important;
    }

    body.neon .player-panel {
        right: 14px !important;
        width: 212px !important;
    }

    body.neon .player .name {
        width: 74px !important;
        font-size: 1.15rem !important;
    }

    body.neon .show-answer-btn {
        width: 184px !important;
    }

    body.neon .score-box {
        min-width: 144px !important;
    }
}

@media (max-width: 768px) {
    body.neon {
        min-height: 100dvh !important;
        overflow-y: auto !important;
    }

    body.neon .title,
    body.neon .glass-title {
        left: 14px !important;
        right: 14px !important;
        top: 12px !important;
        width: auto !important;
        text-align: center !important;
    }

    body.neon .ui-switcher {
        top: 74px !important;
        left: 14px !important;
        right: 14px !important;
        padding: 8px !important;
    }

    body.neon .round-system {
        top: 126px !important;
        left: 14px !important;
        right: 14px !important;
        padding-bottom: 66px !important;
    }

    body.neon #nextBtn.next-top {
        position: absolute !important;
        right: 14px !important;
        bottom: 12px !important;
        top: auto !important;
        transform: none !important;
        width: 136px !important;
    }

    body.neon .canvas-area {
        top: 294px !important;
        left: 14px !important;
        right: 14px !important;
        height: 370px !important;
        min-height: 370px !important;
    }

    body.neon #frameImage {
        width: calc(100% - 28px) !important;
        max-height: 84% !important;
        object-fit: contain !important;
    }

    body.neon .timer-circle {
        left: 20% !important;
    }

    body.neon .player-panel {
        position: static !important;
        transform: none !important;
        width: auto !important;
        margin: 16px 14px 0 !important;
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
    }

    body.neon .player {
        min-height: 62px !important;
    }

    body.neon .player .name {
        width: auto !important;
        font-size: 1rem !important;
    }

    body.neon .show-answer-btn {
        grid-column: 1 / -1 !important;
        position: static !important;
        width: 100% !important;
        margin: 0 !important;
    }

    body.neon .score-section {
        position: static !important;
        width: calc(100% - 28px) !important;
        margin: 14px !important;
        border-radius: 14px !important;
        height: auto !important;
        padding: 12px 10px !important;
    }

    body.neon .score-panel {
        width: 100% !important;
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 10px !important;
    }

    body.neon .score-box {
        min-width: 0 !important;
        width: 100% !important;
        height: 48px !important;
        justify-content: space-between !important;
    }
}
*/

/* ==========================================
   NEON UI RESKIN (VISUAL ONLY, NO LAYOUT)
   ========================================== */
body.neon {
    --ui-bg-1: #140a24;
    --ui-bg-2: #1c1033;
    --ui-bg-3: #251543;
    --ui-surface-1: rgba(33, 19, 56, 0.82);
    --ui-surface-2: rgba(24, 14, 42, 0.9);
    --ui-border: rgba(174, 132, 238, 0.34);
    --ui-text-1: #f0e7ff;
    --ui-text-2: #d4bfff;
    --ui-accent: #a868ff;
    --ui-accent-2: #c08cff;
    --ui-gold: #f7b53a;
    background:
        radial-gradient(920px 520px at 12% 6%, rgba(160, 98, 255, 0.28), transparent 62%),
        radial-gradient(780px 440px at 88% 0%, rgba(201, 123, 255, 0.2), transparent 60%),
        linear-gradient(150deg, var(--ui-bg-1) 0%, var(--ui-bg-2) 52%, var(--ui-bg-3) 100%) !important;
    color: var(--ui-text-1) !important;
    font-family: "Manrope", "Segoe UI", sans-serif !important;
}

body.neon .title,
body.neon .glass-title {
    color: var(--ui-text-1) !important;
    border: 1px solid var(--ui-border) !important;
    background: linear-gradient(145deg, rgba(56, 33, 92, 0.84), rgba(38, 22, 66, 0.9)) !important;
    text-shadow: 0 3px 14px rgba(184, 140, 255, 0.35) !important;
    box-shadow:
        0 10px 28px rgba(12, 6, 24, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.08) !important;
}

body.neon .ui-btn {
    border: 1px solid var(--ui-border) !important;
    background: linear-gradient(135deg, rgba(52, 30, 88, 0.92), rgba(37, 21, 65, 0.94)) !important;
    color: var(--ui-text-2) !important;
    font-family: "Sora", "Manrope", sans-serif !important;
    letter-spacing: 0.04em !important;
    text-shadow: none !important;
    box-shadow: 0 8px 22px rgba(10, 6, 22, 0.4) !important;
}

body.neon .ui-btn:hover {
    border-color: rgba(188, 148, 246, 0.72) !important;
    color: #f8f0ff !important;
    box-shadow: 0 10px 24px rgba(122, 72, 198, 0.32) !important;
}

body.neon .ui-btn.active {
    border-color: rgba(206, 168, 255, 0.92) !important;
    color: #ffffff !important;
    background: linear-gradient(135deg, var(--ui-accent), var(--ui-accent-2)) !important;
    box-shadow:
        0 12px 28px rgba(96, 48, 170, 0.44),
        0 0 0 1px rgba(255, 255, 255, 0.18) inset !important;
}

body.neon .round-system,
body.neon .round-score-container,
body.neon .canvas-area,
body.neon .player,
body.neon .score-box,
body.neon .score-section {
    border: 1px solid var(--ui-border) !important;
    background: linear-gradient(145deg, var(--ui-surface-1), var(--ui-surface-2)) !important;
    box-shadow:
        0 14px 32px rgba(8, 5, 18, 0.52),
        inset 0 1px 0 rgba(255, 255, 255, 0.07) !important;
}

body.neon .round-label,
body.neon .round-score-title,
body.neon .round-score-sub,
body.neon .rs-name,
body.neon .rs-axis,
body.neon .name,
body.neon .name.small,
body.neon .score {
    color: var(--ui-text-1) !important;
}

body.neon .dot.active,
body.neon .round-dot.active,
body.neon .section-dot.active {
    background: var(--ui-accent-2) !important;
    box-shadow: 0 0 14px rgba(181, 130, 255, 0.76) !important;
}

body.neon .dot.completed,
body.neon .round-dot.completed,
body.neon .section-dot.completed {
    background: #b084f6 !important;
    box-shadow: 0 0 12px rgba(176, 132, 246, 0.62) !important;
}

body.neon .timer-circle {
    filter: drop-shadow(0 0 14px rgba(195, 141, 255, 0.5)) !important;
}

body.neon .timer-ring-bg {
    stroke: rgba(206, 168, 255, 0.24) !important;
}

body.neon .timer-ring-progress {
    stroke: #c793ff !important;
}

body.neon #timerDisplay,
body.neon .timer-text {
    color: #f0e5ff !important;
}

body.neon #revealBtn.reveal-btn,
body.neon #nextBtn.next-top,
body.neon .show-answer-btn {
    border: 1px solid rgba(200, 156, 255, 0.78) !important;
    color: #ffffff !important;
    text-shadow: none !important;
    background: linear-gradient(135deg, #a566ff, #7a45d8) !important;
    box-shadow:
        0 12px 30px rgba(62, 30, 114, 0.5),
        0 0 0 1px rgba(255, 255, 255, 0.18) inset !important;
}

body.neon #revealBtn.reveal-btn:hover,
body.neon #nextBtn.next-top:hover,
body.neon .show-answer-btn:hover {
    filter: saturate(1.07) brightness(1.05) !important;
    box-shadow:
        0 15px 34px rgba(74, 36, 136, 0.56),
        0 0 0 1px rgba(255, 255, 255, 0.22) inset !important;
}

body.neon .plus,
body.neon .minus {
    border: 1px solid rgba(194, 146, 255, 0.42) !important;
    color: #ffffff !important;
    background: linear-gradient(140deg, rgba(132, 82, 210, 0.94), rgba(102, 60, 176, 0.95)) !important;
}

body.neon .plus:hover,
body.neon .minus:hover {
    background: linear-gradient(140deg, rgba(150, 99, 230, 0.98), rgba(118, 75, 194, 0.98)) !important;
}

body.neon .player.rank-1,
body.neon .score-box.top-player {
    border-color: rgba(247, 181, 58, 0.76) !important;
    box-shadow:
        0 0 0 1px rgba(247, 181, 58, 0.28) inset,
        0 12px 28px rgba(92, 60, 14, 0.4) !important;
}

body.neon .player .rank-badge {
    color: #fff5d8 !important;
    background: linear-gradient(135deg, #ff3f76, #b4083d) !important;
    box-shadow: 0 8px 18px rgba(129, 10, 48, 0.45) !important;
}

body.neon .player.rank-1 .rank-badge.rank-badge--first {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

body.neon .score-box.referee-active {
    border-color: rgba(255, 206, 92, 0.9) !important;
    background: linear-gradient(145deg, rgba(255, 193, 58, 0.9), rgba(176, 110, 22, 0.92)) !important;
    box-shadow:
        0 0 0 1px rgba(255, 229, 159, 0.36) inset,
        0 14px 28px rgba(96, 60, 8, 0.46),
        0 0 20px rgba(255, 196, 70, 0.42) !important;
}

body.neon .score-box.referee-active .name.small,
body.neon .score-box.referee-active .score,
body.neon .score-box.referee-active .referee-label {
    color: #fff4d8 !important;
}

body.neon .blur-overlay {
    background: rgba(38, 20, 68, 0.32) !important;
}

body.neon .winner-card {
    border: 1px solid var(--ui-border) !important;
    background: linear-gradient(145deg, rgba(46, 27, 80, 0.92), rgba(31, 18, 54, 0.94)) !important;
    box-shadow:
        0 20px 44px rgba(10, 6, 20, 0.62),
        inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

/* ==========================================
   Right Panel Round Entry Build Animation
   ========================================== */
.player-panel.cards-build-seq .player {
    position: relative;
    /* Badges sit at left: -44px; hidden overflow clipped them until build cleanup (~2s). */
    overflow: visible;
}

.player-panel.cards-build-pending .player {
    opacity: 0 !important;
    filter: blur(5px);
    clip-path: inset(0 100% 0 0 round 14px);
}

.player-panel.cards-build-seq .player.round-build-in {
    animation: roundCardBuildIn 760ms cubic-bezier(0.2, 0.9, 0.2, 1) both;
    animation-delay: var(--build-stagger, 0ms);
}

.player-panel.cards-build-seq .player.round-build-in::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background:
        linear-gradient(112deg,
            rgba(10, 16, 28, 0.96) 0%,
            rgba(23, 40, 64, 0.92) 58%,
            rgba(164, 210, 255, 0.2) 100%);
    animation: roundCardMaskSweep 960ms cubic-bezier(0.22, 0.78, 0.32, 1) both;
    animation-delay: calc(var(--build-stagger, 0ms) + 60ms);
}

.player-panel.cards-build-seq .player.round-build-in::after {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -38%;
    width: 38%;
    pointer-events: none;
    border-radius: inherit;
    background: linear-gradient(90deg,
            rgba(255, 255, 255, 0) 0%,
            rgba(205, 235, 255, 0.18) 45%,
            rgba(255, 255, 255, 0) 100%);
    mix-blend-mode: screen;
    animation: roundCardShimmer 620ms ease-out both;
    animation-delay: calc(var(--build-stagger, 0ms) + 180ms);
}

@keyframes roundCardBuildIn {
    0% {
        opacity: 0.05;
        filter: blur(6px) saturate(0.8);
        clip-path: inset(0 100% 0 0 round 14px);
    }

    60% {
        opacity: 0.88;
        filter: blur(1.4px) saturate(1.05);
        clip-path: inset(0 14% 0 0 round 14px);
    }

    100% {
        opacity: 1;
        filter: blur(0) saturate(1);
        clip-path: inset(0 0 0 0 round 14px);
    }
}

@keyframes roundCardMaskSweep {
    0% {
        opacity: 0.9;
        clip-path: inset(0 0 0 0 round 14px);
    }

    100% {
        opacity: 0;
        clip-path: inset(0 0 0 100% round 14px);
    }
}

@keyframes roundCardShimmer {
    0% {
        left: -38%;
        opacity: 0;
    }

    25% {
        opacity: 0.95;
    }

    100% {
        left: 118%;
        opacity: 0;
    }
}
#luckyCardGrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 10px;
  max-height: none;
  overflow: visible;
}
#luckyCardGrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
  gap: 10px;
  width: 100%;
  height: auto;
  overflow: visible;
}
.lucky-card {
  width: 100%;
  max-width: 100%;
  aspect-ratio: auto;
  transform: none;
  font-size: inherit;
}
#luckyCardOverlay {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px;
}

#luckyCardStage {
  width: 100%;
  max-width: 908px;
  height: auto;
  max-height: none;
  display: flex;
  justify-content: center;
  overflow: visible;
}
