* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: sans-serif, serif;
    background-color: #222;
    padding: 16px;
}

h1 {
    color: #ffffff;
    margin-bottom: 4px;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 16px;
    justify-content: center;
    margin-bottom: 16px;
}

.sound-button {
    position: relative;
    cursor: pointer;
    overflow: hidden;
    aspect-ratio: 1/1;
    border: 2px solid #404040;
    align-content: center;
    justify-content: center;
    border-radius: 8px;
    transition: transform 0.2s;
}

.sound-button:hover {
    transform: scale(1.05);
}

.sound-button video,
.sound-button img {
    width: 100%;
    height: auto;
    display: block;
}

.sound-button .sound-text-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.6);
    color: #ffffff;
    padding: 8px;
    text-align: center;
    font-size: 1em;
}

@media (max-width: 800px) {
    .grid-container {
        grid-template-columns: repeat(auto-fit, minmax(175px, 1fr));
    }

    .sound-text-overlay {
        font-size: 0.875em !important;
    }
}

@media (max-width: 600px) {
    .grid-container {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }

    .sound-text-overlay {
        font-size: 0.75em !important;
    }
}

footer {
    margin-top: 24px;
    color: #ffffff;
    text-align: center;
}
