
.mozaic-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: #353535;
    color: #fff;
    box-shadow: rgba(3, 8, 20, 0.1) 0px 0.15rem 0.5rem, rgba(2, 8, 20, 0.1) 0px 0.075rem 0.175rem;
    height: 100%;
    width: 100%;
    transition: all 500ms;
    overflow: hidden;

    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;

    cursor: pointer;
}
.mozaic-card p {
    font-size: 3rem;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.mozaic-card:hover,.mozaic-card:focus {
    box-shadow: rgba(80, 93, 117, 0.1) 0px 0.35em 1.175em, rgba(2, 8, 20, 0.08) 0px 0.175em 0.5em;
    transform: translateY(-3px) scale(1.1);
    border-radius: 4px;
 }

 .mozaic-card:hover p,.mozaic-card:focus p {
    opacity: 1;
 }

.mozaic-grid {
    margin-bottom: 40px;
    display: grid;
    /*grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));*/
    grid-auto-rows: minmax(240px, 300px);
    max-width: 960px;
}

/* For mobile devices */
@media screen and (max-width: 767px) {
    .mozaic-grid {
        grid-template-columns: repeat(2, minmax(120px, 1fr));
    }
    .mozaic-card p {
        font-size: 2rem;
    }
}
/* For desktop devices */
@media screen and (min-width: 768px) {
    .mozaic-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }
}

@media screen and (min-width: 961px) {
    .mozaic-grid {
        grid-template-columns: repeat(4, minmax(240px, 1fr));
    }
    .mozaic-box{
        display: flex;
        justify-content: center;
        align-items: center;
    }
}

