/*======= Portfolio =======*/
.portfolio-nav {
    margin-bottom: 40px;

    ul {
        display: flex;
        align-items: center;
        justify-content: center;
        flex-wrap: wrap;
        margin: 0;
        padding: 0;
        list-style: none;

        @include respond-below(md) {
            justify-content: center;
        }

        li {
            cursor: pointer;
            text-transform: uppercase;
            font-size: 16px;
            font-family: $raj;
            font-weight: 700;
            position: relative;
            padding: 12px 22px;
            @include transition(0.3s);
            margin-left: 50px;

            @include respond-below(lg) {
                margin-left: 30px;
                padding: 10px 15px;
            }

            @include respond-below(sm) {
                padding: 10px;
            }

            @include respond-below(xs) {
                margin: 5px 10px;
            }

            &.active,
            &:hover {
                background-color: $primary-color;
            }

            &:not(:first-child) {
                &::before {
                    content: "--";
                    color: $primary-color;
                    position: absolute;
                    left: -25px;
                    top: 50%;
                    transform: translate(-50%, -50%);

                    @include respond-below(lg) {
                        left: -15px;
                    }

                    @include respond-below(sm) {
                        left: -10px;
                        font-size: 12px;
                    }

                    @include respond-below(xs) {
                        display: none;
                    }
                }
            }

            &:first-child {
                @include respond-below(md) {
                    margin-left: 0;
                }
            }
        }
    }
}

.portfolio-items {
    position: relative;

    &.row {
        margin: -5px;

        .grid-item {
            padding: 5px;
        }
    }

    .grid-sizer {
        visibility: hidden;
    }

    .portfolio-item {
        position: relative;
        overflow: hidden;

        .portfolio-thumb {
            overflow: hidden;
            width: 100%;
            height: 280px;

            .thumb {
                width: 100%;
                height: 100%;
                background-size: cover;
                background-position: center;
                background-color: #ddd;
                transition: 0.3s;
            }
        }

        .portfolio-desc {
            position: absolute;
            left: 20px;
            right: 20px;
            bottom: -10px;
            background-color: $white;
            z-index: 2;
            padding: 20px;
            visibility: hidden;
            opacity: 0;
            @include transition(0.3s);

            .cat {
                font-size: 12px;
                letter-spacing: 2px;
                color: $primary-color;
                text-transform: uppercase;
                font-weight: 700;
                padding-bottom: 6px;
            }

            .title {
                text-transform: uppercase;
                font-size: 18px;
                line-height: 1;
                margin-bottom: 0;
            }
        }

        .portfolio-link {
            position: absolute;
            z-index: 3;
            height: 60px;
            width: 60px;
            line-height: 60px;
            background-color: $primary-color;
            color: $secondary-color;
            top: -30px;
            right: 30px;
            font-size: 18px;
            text-align: center;

            &:hover {
                background-color: $secondary-color;
                color: $white;
            }
        }

        &:hover {
            .portfolio-thumb .thumb {
                transform: scale(1.1);
            }

            .portfolio-desc {
                visibility: visible;
                opacity: 1;
                bottom: 0;
            }
        }
    }

    &.portfolio-layout-masonary {
        .grid-big-item {
            .portfolio-thumb {
                @include respond-above(xs) {
                    height: 570px;
                }
            }
        }
    }

    &.portfolio-slider {
        margin: 0 -15px;

        .portfolio-item {
            padding: 0 15px;
            .portfolio-thumb {
                height: 460px;

                @include respond-below(xs) {
                    height: 370px;
                }
            }
        }
    }

    &.layout-center-mode {
        .portfolio-item {
            .portfolio-inner {
                padding: 0 0 80px;
            }

            .portfolio-desc {
                bottom: 0;
                box-shadow: 0px 8px 16px 0px rgba(7, 28, 31, 0.04);
                padding: 30px;
                right: 40px;
                left: 40px;

                @include respond-below(lg) {
                    left: 30px;
                    right: 30px;
                }

                @include respond-below(xs) {
                    left: 20px;
                    right: 20px;
                    padding: 30px 25px;
                }
            }

            .title {
                font-size: 30px;

                @include respond-below(lg) {
                    font-size: 24px;
                }

                @include respond-below(xs) {
                    font-size: 20px;
                }
            }

            &.slick-current.slick-center,
            &:hover {
                .portfolio-desc {
                    visibility: visible;
                    opacity: 1;
                    bottom: 20px;
                }
            }
        }
    }

    &.portfolio-layout-masonary-two {
        &.row {
            margin: -15px;

            .grid-item {
                padding: 15px;
            }
        }

        .portfolio-item {
            .portfolio-thumb {
                height: 370px;
            }
        }
    }
}

.portfolio-list-items {
    .portfolio-list-item {
        &:not(:last-child) {
            margin-bottom: 100px;
        }

        .portfolio-thumb {
            text-align: left;

            @include respond-below(md) {
                text-align: center;
            }
        }

        &:nth-child(even) {
            .row {
                flex-direction: row-reverse;
            }

            .portfolio-thumb {
                text-align: right;

                @include respond-below(md) {
                    text-align: center;
                }
            }
        }

        .portfolio-desc {
            padding: 0 0 0 100px;
            position: relative;

            @include respond-below(md) {
                padding: 0;
                font-size: 15px;
            }

            @include respond-below(sm) {
                margin-top: 40px;
            }

            .count {
                font-family: $raj;
                font-weight: 700;
                font-size: 60px;
                letter-spacing: -0.03em;
                color: $primary-color;
                line-height: 1;
                position: absolute;
                left: 0;
                top: 0;

                @include respond-below(md) {
                    position: relative;
                    margin-bottom: 5px;
                }
            }

            .line {
                background-color: $secondary-color;
                height: 1px;
                width: 170px;
                margin-top: 20px;
                margin-bottom: 40px;
                display: block;

                @include respond-below(md) {
                    display: none;
                }
            }

            .title {
                font-size: 30px;
                letter-spacing: -0.03em;
                margin-bottom: 15px;
                text-transform: capitalize;
            }

            p {
                margin: 0;
            }

            .cat {
                font-family: $raj;
                font-weight: 700;
                text-decoration: underline;
                font-size: 16px;
                line-height: 1;
                margin-bottom: 30px;
            }

            .portfolio-link {
                line-height: 1;
                text-decoration: underline;
                font-size: 16px;
                padding: 20px 40px;
                border: 2px solid #e5e8ea;
                color: $secondary-color;
                font-weight: 700;
                font-family: $raj;
                margin-top: 30px;

                &:hover {
                    background-color: $primary-color;
                    border-color: $primary-color;
                }
            }
        }
    }
}
