*{
    padding: 0;
    margin: 0;
}
body {
    background: linear-gradient(to bottom, #04004d, #304fff);
    height: 100vh;
}

.gallery{
padding: 10px;
max-width: 1100px;
margin: 0 auto;
background: linear-gradient(to bottom, #00d9ff);
display: grid;
grid-gap: 10px;
grid-template-columns: repeat(auto-fit,minmax(250px,1fr));
grid-auto-rows: 250px;
grid-auto-flow: dense;
}
/*-----Stretch vertical ------*/
.v-stretch{
    grid-row: span 2;
}
/*-----Stretch horizontal ------*/
.h-stretch{
    grid-column: span 2;
}


/*-----Stretch vertically and horizontally ------*/
.big-stretch{
    grid-row: span 2;
    grid-column: span 2;
}
.gallery div img{
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer;
}

/*-----Dynamic image modes ------*/
.gallery div img:hover{
    transform: scale(0.8) rotate(-15deg);
    border-radius: 20px;
    box-shadow: 0 32px 75px rgba(0, 0, 0, 0.2);
}
.full-img{
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.9);
    position: fixed;
    top: 0;
    left: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 100;

}
.full-img img{
    width: 90%;
    max-width: 700px;
}
.full-img span{
    position: absolute;
    top: 5%;
    right: 5%;
    font-size: 30px;
    color: #fff;
    cursor: pointer;
}


/*---------------------------Responsive----------------------------------------*/
@media(max-width: 560px)
{
    .v-stretch{
        grid-row: span 1;
    } 
    .h-stretch{
        grid-column: span 1;
    }
    .big-stretch{
        grid-row: span 1;
        grid-column: span 1;
}
}









