body {
    font-family: Arial, sans-serif;
    background-color: #000000;
    color: #f0f0f0;
    text-align: center;
    padding: 20px;
    overflow-x: hidden; /* Prevent horizontal scrollbar from confetti */
}
h1 {
    color: #cccccc;
}
.scoreboard-grid {
    display: grid;
    grid-template-columns: repeat(10, 1fr);
    grid-gap: 5px;
    max-width: 800px;
    margin: 20px auto;
    background-color: #222;
    border: 3px solid #555;
    padding: 10px;
    border-radius: 8px;
}
.grid-cell {
    width: 100%;
    padding-bottom: 100%;
    position: relative;
    border: 1px solid #444;
    border-radius: 4px;
    background-color: #333;
}
.grid-cell span {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 2em;
}
.prize-alert {
    color: #28a745;
    animation: pulse 1.5s infinite;
}
.prize-alert.mega {
    color: #dc3545;
    font-size: 2.5em;
}
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}
.controls, .admin-panel {
    margin-top: 30px;
    background-color: #1c1c1c;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    border: 1px solid #444;
}
.question-btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 15px;
    margin: 5px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.2em;
    transition: background-color 0.2s;
}
.question-btn:hover {
    background-color: #0056b3;
}
.hidden {
    display: none !important;
}
.icon-options {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 10px;
    flex-wrap: wrap;
}
#reset-btn {
    background-color: #dc3545;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 5px;
    cursor: pointer;
}
#reset-btn:hover {
    background-color: #c82333;
}
.modal {
    position: fixed;
    z-index: 100;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8);
    display: flex;
    align-items: center;
    justify-content: center;
}
.modal-content {
    background-color: #2b2b2b;
    color: #f0f0f0;
    margin: auto;
    padding: 30px;
    border: 1px solid #555;
    width: 80%;
    max-width: 500px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}
#question-text, #prize-text {
    font-size: 1.8em;
    margin-bottom: 30px;
    color: #ffffff;
}
.modal-buttons button, #prize-ok-btn {
    font-size: 1.4em;
    padding: 15px 30px;
    margin: 0 10px;
    border-radius: 8px;
    border: none;
    color: white;
    cursor: pointer;
    transition: transform 0.2s;
}
.modal-buttons button:hover, #prize-ok-btn:hover {
    transform: scale(1.05);
}
#yes-btn, #prize-ok-btn {
    background-color: #007bff;
}
#no-btn {
    background-color: #6c757d;
}
.grid-cell img {
    width: 90%;
    height: 90%;
    object-fit: contain;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}
.icon-image {
    width: 80px;
    height: 80px;
    object-fit: contain;
    cursor: pointer;
    transition: transform 0.2s;
    border: 2px solid transparent;
    border-radius: 8px;
    background-color: #444;
    padding: 5px;
}
.icon-image:hover {
    transform: scale(1.1);
    border-color: #007bff;
}

/* --- Confetti Styles --- */
.confetti {
    position: fixed;
    top: -20px;
    width: 10px;
    height: 10px;
    opacity: 0;
    animation: fall linear forwards;
    z-index: 110; /* <-- THE FIX: This brings the confetti in front of the modal overlay */
}

@keyframes fall {
    0% {
        transform: translateY(0) rotateZ(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(105vh) rotateZ(720deg);
        opacity: 0;
    }
}