/* Ensure the heading stays centered and doesn't wrap */
#image-gallery h2 {
    text-align: center;
    /* font-size: 2rem; */
    /* Default size for larger screens */
    margin-bottom: 30px;
    white-space: nowrap;
    /* Prevent wrapping of text */
}

/* Adjust heading size for tablets */
@media (max-width: 768px) {
    #image-gallery h2 {
        font-size: 1.5rem;
        /* Smaller font size on tablets */
    }
}

/* Further reduce font size for mobile */
@media (max-width: 480px) {
    #image-gallery h2 {
        font-size: 2.0rem;
        margin-left: -2.2rem;
        /* Even smaller on phones */
    }
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
    justify-content: center;
}

.gallery-item {
    display: flex;
    justify-content: center;
    align-items: center;
}

.gallery-item img {
    max-width: 100%;
    max-height: 150px;
    border-radius: 8px;
    object-fit: contain;
}

/* For tablets */
@media (max-width: 768px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

/* For mobile */
@media (max-width: 480px) {
    .gallery-grid {
        grid-template-columns: 1fr;
        row-gap: 50px;
        column-gap: 20px;
    }
}