﻿:root {
    --bg-color: #0f172a;
    --surface-color: #1e293b;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --brand-red: #ef4444;
    --brand-red-glow: rgba(239, 68, 68, 0.4);
    --brand-green: #22c55e;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Top Bar */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background-color: rgba(30, 41, 59, 0.5);
}

.room-badge {
    background-color: var(--surface-color);
    padding: 0.5rem 1rem;
    border-radius: 99px;
    font-size: 0.875rem;
    font-weight: 600;
    border: 1px solid #334155;
    letter-spacing: 1px;
}

.share-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 0.875rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    padding: 0.5rem;
}

/* Main Game Area */
.main-area {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 1.5rem;
    text-align: center;
}

#statusText {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    min-height: 2.5rem;
    transition: color 0.3s ease;
}

/* Buzzer Button */
.buzzer-wrapper {
    position: relative;
    margin-bottom: 2.5rem;
}

#buzzBtn {
    width: 240px;
    height: 240px;
    border-radius: 50%;
    background: linear-gradient(145deg, #ef4444, #b91c1c);
    border: none;
    color: white;
    font-size: 3.5rem;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 15px 35px var(--brand-red-glow), inset 0 5px 15px rgba(255,255,255,0.2);
    transition: all 0.1s ease;
    -webkit-tap-highlight-color: transparent;
}

    #buzzBtn:active:not(:disabled) {
        transform: scale(0.92);
        box-shadow: 0 5px 15px var(--brand-red-glow), inset 0 10px 20px rgba(0,0,0,0.3);
    }

    #buzzBtn:disabled {
        background: #334155;
        color: #64748b;
        box-shadow: none;
        cursor: not-allowed;
        transform: scale(1);
    }

/* Input & Controls */
#userNameInput {
    background-color: var(--surface-color);
    border: 2px solid #334155;
    color: white;
    padding: 1rem;
    border-radius: 12px;
    font-size: 1.1rem;
    text-align: center;
    width: 100%;
    max-width: 320px;
    outline: none;
    margin-bottom: 1rem;
}

    #userNameInput:focus {
        border-color: var(--brand-red);
    }

/* Noticeable Reset Button */
#resetBtn {
    background-color: transparent;
    border: 2px solid #475569;
    color: var(--text-primary);
    padding: 1rem;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    width: 100%;
    max-width: 320px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}

    #resetBtn:active {
        background-color: #334155;
    }

.countdown-text {
    color: var(--brand-red);
    font-weight: 800;
}

/* Players Footer */
.players-container {
    background-color: var(--surface-color);
    padding: 1.5rem;
    border-top: 1px solid #334155;
    width: 100%;
    text-align: center;
}

.players-header {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.player-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
}

.pill {
    background-color: #0f172a;
    padding: 0.4rem 0.8rem;
    border-radius: 99px;
    font-size: 0.9rem;
    border: 1px solid #334155;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

    .pill .dot {
        width: 8px;
        height: 8px;
        background-color: var(--brand-green);
        border-radius: 50%;
        box-shadow: 0 0 8px var(--brand-green);
    }
