/* === Sound Playground Styles === */

.game-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.game-header h1 {
    margin-bottom: 0.25rem;
}

.game-header p {
    color: var(--text-secondary);
}

.game-controls {
    display: flex;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.difficulty-selector {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.difficulty-btn {
    padding: 0.5rem 1.25rem;
    font-size: 0.9rem;
}

.difficulty-btn.active {
    background-color: var(--accent);
    color: var(--accent-contrast);
    border-color: var(--accent);
}

/* Sound Grid */
.soundboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.sound-btn {
    aspect-ratio: 1;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    font-size: 2.5rem;
    color: #fff;
    transition: transform 0.1s, box-shadow 0.2s;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    position: relative;
    overflow: hidden;
}

.sound-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
}

.sound-btn:active {
    transform: scale(0.92);
}

.sound-btn.playing {
    animation: sound-pulse 0.3s ease-out;
}

.sound-btn-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

@keyframes sound-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.5);
    }

    100% {
        box-shadow: 0 0 0 20px rgba(255, 255, 255, 0);
    }
}

/* Record Controls */
.record-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.record-status {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--accent);
}

.record-status.recording {
    animation: blink 0.8s ease-in-out infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.3;
    }
}

/* Responsive */
@media (max-width: 480px) {
    .soundboard-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.75rem;
    }

    .sound-btn {
        font-size: 2rem;
    }

    .sound-btn-label {
        font-size: 0.65rem;
    }
}