//
//  Common
//  _____________________________________________

& when (@media-common = true) {
    .amasty-xlanding-page-view {
        .page-title {
            margin-top: 2rem;
        }
        .amasty-xlanding-top-image {
            margin-bottom: 1.1rem;
        }
        .amasty-xlanding-top-description {
            margin-bottom: 1.1rem;
        }
        .amasty-xlanding-top-static {
            margin-bottom: 1.1rem;
        }
        .columns {
            position: relative;
            z-index: 1;
        }
        .column.main {
            padding-bottom: 0;
        }
        .sorter {
            z-index: 1;
        }
        .sorter-label {
            .lib-visually-hidden();
        }
        .limiter {
            .label {
                .lib-visually-hidden();
            }
        }
        .limiter-text {
            .lib-visually-hidden();
        }
        .products-grid {
            .product-item {
                margin-left: 0;
                margin-right: 0;
                width: 100%;
            }
        }
        .amasty-xlanding-bottom-description {
            padding-bottom: 1.1rem;
            &:last-child {
                padding-bottom: 31px;
            }
        }
        .amasty-xlanding-bottom-static {
            padding-bottom: 1.1rem;
            &:last-child {
                padding-bottom: 31px;
            }
        }
        &.page-layout-1column {
            .filter.block {
                display: none;
            }
        }
    }
}


//
//  Mobile
//  _____________________________________________

.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__s) {
    .amasty-xlanding-page-view {
        .page-title {
            .lib-font-size(36);
            text-align: center;
        }
    }
}

.media-width(@extremum, @break) when (@extremum = 'max') and (@break = @screen__m) {
    .amasty-xlanding-page-view {
        .column.main {
            display: table-footer-group;
            .products {
                margin-top: 0;
            }
        }
        .sorter {
            float: none;
            position: absolute;
            top: 0;
            right: 5%;
            width: 40%;
            .sorter-options {
                opacity: .5;
                width: 100%;
            }
        }
        .sorter-action {
            display: none;
        }
        .limiter {
            display: none;
        }
    }
}


//
//  Desktop
//  _____________________________________________

.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__s) {
    .amasty-xlanding-page-view {
        &.page-layout-2columns-left {
            .products-grid {
                .product-item {
                    box-sizing: border-box;
                    padding: 20px;
                    width: 50%;
                }
            }
        }
        .page-title {
            .lib-font-size(48);
            text-align: left;
        }
    }
}

.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__m) {
    .amasty-xlanding-page-view {
        &.page-layout-2columns-left {
            .column.main {
                float: right;
                width: 73.5%;
            }
            .sidebar {
                display: block;
                padding-right: 0;
                width: 26.5%;
            }
            .limiter {
                right: 29px;
            }
        }
        &.amasty-xlanding-columns3 {
            .products-grid {
                .product-item {
                    width: 50%;
                }
            }
        }
        &.amasty-xlanding-columns4 {
            .products-grid {
                .product-item {
                    width: 50%;
                }
            }
        }
        &.amasty-xlanding-columns5 {
            .products-grid {
                .product-item {
                    width: 50%;
                }
            }
        }
        .sorter {
            float: none;
            position: absolute;
            right: 205px;
            top: 21px;
        }
        .limiter {
            position: absolute;
            right: 0;
            top: 21px;
        }
        .amasty-xlanding-bottom-description {
            border-left: 1px solid #dbdfe1;
            padding-left: 31px;
        }
        .amasty-xlanding-bottom-static {
            border-left: 1px solid #dbdfe1;
            padding-left: 31px;
        }
    }
}

.media-width(@extremum, @break) when (@extremum = 'min') and (@break = @screen__l) {
    .amasty-xlanding-page-view {
        &.amasty-xlanding-columns3 {
            .products-grid {
                .product-item {
                    width: 33.3333%;
                }
            }
        }
        &.amasty-xlanding-columns4 {
            .products-grid {
                .product-item {
                    width: 25%;
                }
            }
        }
        &.amasty-xlanding-columns5 {
            .products-grid {
                .product-item {
                    width: 20%;
                }
            }
        }
        .sorter {
            right: 278px;
        }
        .products-grid {
            .product-item {
                padding: 0;
            }
        }
    }
}
