@use 'settings' as *;
@use 'mixins' as *;

/* General */

html[dir="rtl"] {
    body, p, ul:not(.slick-dots):not(.slides), li, input, select {
        text-align: right;
    }
    .text-center *, .corpboot-price-content ul li {
        text-align: center;
    }
    .team-social p {
        text-align: center;
    }
    .blockquote {
        border-left: 0;
        border-right: 4px solid #f2f1ef;
        text-align: right;
    }
    .pagination>.page-item:first-child>a {
        @include border-radius(0 4px 4px 0 !important);
    }
    .pagination>.page-item:last-child>a {
        @include border-radius(4px 0 0 4px !important);
    }
    ul {
        &.listicon-check li {
            padding-right: 1em;
            padding-left: 0;
            &:before {
                margin-right: -2.5em;
                margin-left: 0;
            }
        }
        &.listicon-times li {
            padding-right: 1em;
            padding-left: 0;
            &:before {
                margin-right: -2.5em;
                margin-left: 0;
            }
        }
        &.listicon-chevron-right li {
            padding-right: 1em;
            padding-left: 0;
            &:before {
                margin-right: -2.5em;
                margin-left: 0;
                content:"\f053";
            }
        }
    }
    .breadcrumb {
        > {
            li {
                i {
                    margin-top: 2px;
                    float: left;
                }
                + li:before {
                    display: none;
                }
                + li:after {
                    font-family: 'FontAwesome';
                    content:"\f104";
                    padding: 0 10px;
                    color: rgba(#fff,0.7);
                    font-weight: normal;
                }
            }
            .active {
                color: #fff;
                font-weight: 600;
            }
        }
    }
    .checkbox input[type=checkbox], .checkbox-inline input[type=checkbox],
    .radio input[type=radio], .radio-inline input[type=radio] {
        margin-right: -20px;
        margin-left: 0;
    }
    .checkbox label, .radio label {
        padding-right: 20px;
        padding-left: 0;
    }
    .bootstrap-select .dropdown-toggle .filter-option {
        text-align: right;
    }
    .alert-dismissible {
        padding-left: 4rem;
        .btn-close {
            right: auto;
            left: 0;
        }
    }
}

/* Home slider button */

html[dir="rtl"] {
    .btn-transparent {
        i {
            margin-right: 0;
            margin-left: 5px;
        }
    }
    .btn-transparent-sm {
        i {
            margin-right: 0;
            margin-left: 2px;
        }
    }
    .main-slider-button-prev.swiper-button-prev {
        margin-right: 15px;
        right: 0;
    }
    .main-slider-button-next.swiper-button-next {
        margin-left: 15px;
        left: 0;
    }
}

/* Lightbox */

html[dir="rtl"] {
    .vnbx-close {
        right: auto;
        left: 30px;
    }
    .vnbx-title {
        text-align: right;
    }
    .vnbx-close-button-enabled .vnbx-title {
        padding-right: 8px;
    }

    .glightbox-clean .gclose {
        right: auto;
        left: 30px;
    }
}

/* Pricing */

html[dir="rtl"] {
    span.popular-tag {
        right: auto;
        left: -6px;
    }
}

/* Contact */

html[dir="rtl"] {
    .cinfo address i {
        margin: 0 8px 8px 4px;
    }
    .bootstrap-select.btn-group .dropdown-toggle .filter-option {
        text-align: right;
        float: right;
    }
    .bootstrap-select.btn-group .dropdown-toggle .caret {
        left: 12px;
        right: auto;
    }
    @media (min-width: 1025px) {
        .row-lg .col-lg-5 {
            padding-left: 10px !important;
            padding-right: 0 !important;
        }
    }
}

/* Blog */

html[dir="rtl"] {
    .post_content {
        h1, h2, h3, h4, h5, h6 {
            text-align: right;
        }
    }
    #wp-calendar tfoot tr td#next {
        text-align: left;
    }
    .sidebar-right > .widget {
        float: left;
    }
    .sidebar-left > .widget {
        float: right;
    }
    .widget ul li a:after {
        font-family: "FontAwesome";
        content: '\f104';
        margin-left: 5px;
    }
    .widget ul li a:before {
        display: none;
    }
    @media (min-width: 841px) {
        .avatar img {
            float: right;
            margin: 0 0 15px 15px;
        }
    }
}

/* Accordion */

html[dir="rtl"] {
    .accordion .accordion-item .accordion-header .btn:after, .accordion .accordion-item .accordion-header .submit:after {
        right: auto;
        left: 15px;
    }
    .panel-group .panel-heading a {
        text-align: right;
        &::after {
            right: auto;
            left: 15px;
        }
    }
}

/* Nav-wizard */

html[dir="rtl"] {
    .nav-wizard {
        >li {
            float: left;
            >a {
                .badge {
                    margin-right: 3px;
                    margin-left: 0;
                }
            }
            &:not(:first-child)>a {
                padding-right: 34px;
                padding-left: 15px;
                &:before {
                    border-top: 20px inset transparent;
                    border-bottom: 20px inset transparent;
                    border-right: 20px solid #f2f4f5;
                    border-left: 0;
                    top: 0;
                    right: 0;
                    left: auto;
                }
            }
            &:not(:last-child)>a {
                margin-right: 0;
                margin-left: 6px;
                &:after {
                    border-top: 20px inset transparent;
                    border-bottom: 20px inset transparent;
                    border-right: 20px solid $body-bg-color;
                    border-left: 0;
                    top: 0;
                    left: -20px;
                    right: auto;
                }
            }
            &:first-child>a {
                border-top-right-radius: 4px;
                border-bottom-right-radius: 4px;
                border-top-left-radius: 0;
                border-bottom-left-radius: 0;
            }
            &:last-child>a {
                border-top-right-radius: 0;
                border-bottom-right-radius: 0;
                border-top-left-radius: 4px;
                border-bottom-left-radius: 4px;
            }
            &:hover>a {
                background-color: $color_4;
                color: #fff;
            }
            &:hover>a:before {
                border-right-color: $body-bg-color;
                border-left-color: $color_4;
            }
            &:hover>a:after {
                border-right-color: $color_4;
                border-left-color: $body-bg-color;
            }
            &>a.active {
                &:after {
                    border-right-color: $color_3;
                    border-left-color: $body-bg-color;
                }
            }
            &>a.active:hover {
                &:after {
                    border-right-color: $color_4;
                }
            }
            &.disabled>a {
                &:before {
                    border-right-color: $color_3;
                    border-left-color: $body-bg-color;
                }
                &:after {
                    border-right-color: $body-bg-color;
                    border-left-color: $color_3;
                }
            }
        }
        &.nav-justified>li {
            float: none;

            >a {
                padding: 10px 15px;
            }
        }
    }
}

/* Navbar */

html[dir="rtl"] {
    .nav {
        padding-right: 0;
    }
    .navbar {
        .navbar-nav {
            text-align: right;
            padding-left: 0;
            padding-right: 0;
            .dropdown-menu {
                text-align: right;
            }
        }
    }

    @media (min-width: 841px) {
        .navbar {
            .navbar-header {
                float: right;
            }
            .navbar-nav>li {
                float: right;
            }
            .navbar-right {
                float: left!important;
                margin-left: -15px;
            }
        }
    }

    @media (max-width: 840px) {
        .navbar {
            .navbar-header {
                .navbar-brand {
                   float: right!important;
                   margin-right: -15px;
                }
                .navbar-toggle {
                   float: left!important;
                   margin-left: -15px;
                }
            }
            .navbar-right {
                float: none!important;
                margin-left: 0;
            }
            .navbar-collapse {
                &.collapse {
                    padding-left: 0;
                }
                &.collapsing {
                    padding-left: 0;
                }
            }
        }
    }

    @media (max-width: 767px) {
        .navbar {
            .navbar-header {
                .navbar-brand {
                   margin-right: 0;
                }
                .navbar-toggle {
                   margin-left: 0;
                }
            }
        }
    }

    @media (max-width: 991.98px) {
        .navbar-collapse {
            margin-left: 0px;
        }
    }
}

/* Footer */

html[dir="rtl"] {
    .footer-top .footer-widget ul li i {
        margin-right: 0;
        margin-left: 4px;
    }
    .list-unstyled {
        padding-right: 0;
    }
    .newsletter, .search-form {
        .form-control {
            @include border-radius(0 3px 3px 0 !important);
        }
        .input-group-btn button {
            @include border-radius(3px 0 0 3px !important);
        }
    }
    .credits, .credits p {
        text-align: left;
    }
    .scrollToTop, .whatsappButton {
        right: auto;
        left: 15px;
    }
}
