@import '../functions.less';
@import '../../../../files/config/colors.less';


.drs-grid-01 {
    .grid {
        .grid(1fr 1fr 1fr; 10px; stretch);
        grid-template-areas: "a1 a1 a2" "a1 a1 a3" "a4 a5 a6";
        * { .fx(); }
        a {
            &:nth-child(1){ grid-area: a1; }
            &:nth-child(2){ grid-area: a2; }
            &:nth-child(3){ grid-area: a3; }
            &:nth-child(4){ grid-area: a4; }
            &:nth-child(5){ grid-area: a5; }
            &:nth-child(6){ grid-area: a6; }
            background: #000;
            position: relative;
            overflow: hidden;
            border-radius: 5px;
            color: #FFF;
            img {
                display: block;
                width: 100%;
                height: 100%;
                filter: brightness(70%);
            }
            &:hover {
                img {
                    filter: brightness(80%);
                    transform: scale(104%);
                }
                > div div {
                    text-decoration: underline;
                }
            }
            > div {
                position: absolute;
                width: 100%;
                bottom: 0px;
                background: linear-gradient(#0000, #0009);
                padding: 30% 25px 20px 25px;
                span {
                    display: inline-block;
                    background: #EEE;
                    color: #123;
                    margin-bottom: 10px;
                    padding: 3px 20px;
                    font-size: 12px;
                    border-radius: 3px;
                    opacity: 90%;
                }
                div {
                    display: block;
                    margin-bottom: 5px;
                    font-size: 1.2em;
                }
            
            }
            &:first-child {
                > div {
                    padding: 30% 30px 25px 30px;
                    div {
                        font-size: 1.8em;
                    }
                    p {
                        font-size: 1.2em;
                        opacity: 70%;
                    }
                }
            }
            &:not(:first-child) {
                > div {
                    p {
                        display: none;
                        opacity: 70%;
                    }
                }
            }
            &:nth-child(1n + 4) {
                background: none;
                img {
                    display: none;
                }
                > div {
                    position: relative;
                    padding: 15px;
                    color: #123;
                    background: #5671;
                    height: 100%;
                    span {
                        background: #1232;
                    }
                    p {
                        display: block;
                        font-size: .9em;
                    }
                }
                &:hover {
                    box-shadow: 0 4px 4px -4px #444;
                    > div {
                        background: #1231;
                    }
                }
            }
        }
    }
}

@media screen and ( max-width: 1200px ){
    .drs-grid-01 .grid {
        .grid(1fr 1fr; 10px; stretch);
        grid-template-areas: "a1 a1" "a2 a3" "a4 a5";
        a {
            &:not(:first-child) {
                > div {
                    p {
                        display: block;
                    }
                }
            }
            &:last-child {
                display: none;
            }
        }
    }
}

@media screen and ( max-width: 1000px ){
    .drs-grid-01 .grid {
        .grid(1fr 1fr; 20px);
        grid-template-areas: "a1 a1" "a2 a2" "a3 a3" "a4 a5";
        a {
            border-radius: 5px;
            &:not(:first-child) {
                .grid(1fr 1fr; 20px);
                background: #5671;
                > div {
                    position: relative;
                    padding: 5px;
                    background: none;
                    color: @textoHtml;
                    span {
                        background: #1238;
                        color: #FFF;
                    }
                    div {
                        font-size: 1.4em;
                    }
                    p {
                        font-size: 1em;
                        opacity: 60%;
                    }
                }
            }
            &:nth-child(1n + 4) {
                display: block;
                height: 100%;
            }
            &:last-child {
                display: none;
            }
        }
    }
}

@media screen and ( max-width: 800px ){
    .drs-grid-01 .grid {
        .grid(1fr; 10px);
        grid-template-areas: "a1" "a2" "a3" "a4" "a5" "a6";
        a, a:not(:first-child) {
            .grid(1fr; 10px);
            &:not(:nth-child(1n + 4)) > div {
                position: absolute;
                color: #FFF;
                background: linear-gradient(#0000, #0009);
                padding: 30% 25px 20px 25px;
                span {
                    background: #EEE;
                    color: #123;
                }
            }
            &:nth-child(1n + 4) > div {
                padding: 15px;
                div {
                    font-size: 1.3em;
                }
            }
        }
    }
}

@media screen and ( max-width: 600px ){
    .drs-grid-01 .grid {
        a, a:not(:first-child){
            .grid(1fr; 0px);
            background: none;
            color: #123;
            text-decoration: none;
            > div, > div:not(:first-child) {
                position: relative;
                padding: 15px;
                background: #5671;
                color: #123;
                div {
                    font-size: 1.3em;
                }
                p {
                    font-size: .9em;
                    margin-top: 0;
                }
            }
        }
        a:not(:nth-child(1n + 4)) > div {
            span {
                position: absolute;
                margin-top: -50px;
            }
        }
    }
}