/* Minimal CSS Reset */
button {
    margin: 0;
    padding: 0;
    border: none;
    box-sizing: border-box;
    font-family: inherit;
}

/* Base Styles */
body {
    font-family: 'IBM Plex Sans Thai Looped', sans-serif;
    padding: 20px;
    background-color: #1a1a1a;
    color: #f0f0f0;
    margin: 0 auto;
    min-height: 100vh;
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Sound Button Grid */
#fileList {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0;
}

/* Sound Button Styles */
.sound-button {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 25px 15px;
    border-radius: 8px;
    background-color: #333;
    color: rgba(255, 255, 255, 0.9); /* Soft white text */
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    text-align: center;
    line-height: 1.4;
    min-height: 80px;
}

.sound-button:hover {
    background-color: #3a3a3a;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.sound-button.playing {
    background-color: #ff8c42;
    color: white; /* Pure white when playing */
    box-shadow: 0 0 0 3px rgba(255,140,66,0.3);
}

/* Footer */
footer {
    text-align: center;
    margin-top: 40px;
    color: #666;
    font-size: 14px;
}

footer a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s ease;
}

footer a:hover {
    color: #ff8c42;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    #fileList {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 10px;
    }
    
    .sound-button {
        padding: 20px 10px;
        font-size: 15px;
        min-height: 70px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 15px;
    }
    
    #fileList {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    }
}