@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;500;700;900&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Dancing+Script:wght@400;500;600;700&display=swap');

*, ::after, ::before {
    margin: 0;
    padding: 0;
    list-style: none;
    text-decoration: none;
    color: antiquewhite;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    background: #29282c;
}

/* --------------- GRID GALERIE --------------- */
.grid-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-auto-rows: 250px;
    grid-auto-flow: row dense;
    gap: 5px;
    padding: 75px 5px 5px;
    min-height: 100vh;
}

.gallery-item {
    display: block;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.gallery-item.portrait {
    grid-row: span 2;
}

.gallery-item.paysage {
    grid-column: span 2;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
    display: block;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

.img-title {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.75));
    padding: 30px 14px 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.15);
}

.img-title span {
    color: antiquewhite;
    font-family: 'Dancing Script', sans-serif;
    font-size: 2rem;
    font-weight: 600;
}

/* responsive */
@media (max-width: 750px) {
    .grid-gallery {
        grid-template-columns: repeat(2, 1fr);
        grid-auto-rows: 200px;
        padding: 70px 4px 4px;
        gap: 4px;
    }
}

@media (max-width: 750px) {
    .img-title span {
        font-size: 1.8rem;
    }
}

@media (max-width: 450px) {
    .grid-gallery {
        grid-template-columns: 1fr;
        grid-auto-rows: 250px;
        padding: 65px 3px 3px;
        gap: 3px;
    }
    .gallery-item.portrait,
    .gallery-item.paysage {
        grid-column: span 1;
        grid-row: span 1;
    }
    .img-title span {
        font-size: 1.6rem;
    }
}
