fav.scss 7.84 KB
.yoho-favorite-page {
    width: 100%;
    height: auto;

    .fav-tab {
        width: 100%;
        height: 88px;
        line-height: 88px;
        border-bottom: 1px solid #e0e0e0;
        color: #b0b0b0;
        font-size: 26px;
    }

    .fav-tab > li {
        width: 50%;
        height: 100%;
        float: left;
        text-align: center;

        &.active {
            color: #444;
        }

        &:nth-last-of-type(1) {
            float: right;
            position: relative;
        }

        &:nth-last-of-type(1):after {
            content: "";
            display: block;
            width: 1px;
            height: 44px;
            position: absolute;
            left: 0;
            top: 22px;
            background: #b0b0b0;
        }
    }

    .fav-content {
        .fav-type {
            display: none;
        }

        .show {
            display: block;
        }

        .go-shopping {
            width: 472px;
            height: 88px;
            line-height: 88px;
            margin: 80px auto 0;
            background: #444;
            text-align: center;
            color: #fff;
            display: block;
            font-size: 26px;
            border-radius: 0.2rem;
        }
    }

    .fav-content .fav-null {
        font-size: 22px;
        color: #444;
        display: block;
        margin-top: 100px;
        text-align: center;

        &:before {
            content: "";
            display: block;
            width: 188px;
            height: 171px;
            background: url("img/home/fav/fav-null.png");
            background-size: 100% 100%;
            margin: 0 auto 45px;
        }
    }

    .fav-content .fav-product-list {
        list-style: none;
        margin-left: 30px;

        li {
            height: auto;
            overflow: hidden;
            margin-top: 20px;
        }

        .fav-img-box {
            width: 90px;
            height: 120px;
            float: left;
            margin-right: 24px;
        }

        .fav-img-box img {
            display: block;
            overflow: hidden;
            width: 100%;
            height: 100%;
        }

        .fav-info-list {
            color: #444;
            font-size: 24px;
            border-bottom: 1px solid #e0e0e0;
            padding-bottom: 20px;
            height: 140px;
            overflow: hidden;
            position: relative;
        }

        .fav-info-list h2 {
            width: 430px;
            text-overflow: ellipsis;
        }

        .fav-info-list .fav-price .new-price {
            color: #d1021c;
        }

        .fav-info-list .fav-price .price-underline {
            text-decoration: line-through;
            margin-left: 15px;
            color: #b0b0b0;
        }

        .fav-info-list .save-price {
            position: absolute;
            bottom: 20px;
            left: 0;
            width: 100%;
            min-height: 24px;
        }

        .fav-info-list .save-price span {
            color: #d1021c;
        }

        .fav-info-list .save-price .sell-out {
            padding: 5px 18px;
            color: #fffefe;
            border-radius: 20px;
            background: #7f7f7f;
            font-size: 22px;
        }

        .fav-info-list .save-price .del-fav {
            width: 2rem;
            height: 1.5rem;
            line-height: 1.5rem;
            position: absolute;
            top: 50%;
            margin-top: -0.75rem;
            right: 0;
            color: #999;
            padding-right: 0.75rem;
            text-align: right;
        }

        .fav-info-list .save-price-number {
            text-indent: 42px;
            color: #b0b0b0;
            padding-top: 3px;
        }

        .fav-info-list .save-price-number:before {
            content: "";
            display: block;
            background: url("img/home/fav/save-price.png");
            background-size: 100%;
            width: 32px;
            height: 32px;
            position: absolute;
            top: 50%;
            left: 0;
            margin-top: -16px;
        }

        .fav-info-list .save-price-number span {
            margin-left: 15px;
        }

        .fav-info-list .save-price-number .del-fav {
            text-indent: 0;
            margin-left: 0;
        }
    }

    .fav-content .fav-brand-swiper {
        border-top: 1px solid #e0e0e0;
        border-bottom: 28px solid #f0f0f0;
        position: relative;

        &:nth-of-type(1) {
            border-top: 0;
        }

        &:after {
            content: "";
            position: absolute;
            left: 0;
            bottom: -2px;
            border-top: 1px solid #e0e0e0;
            display: block;
            width: 100%;
            height: 1px;
        }
    }

    .fav-content .fav-brand-swiper .swiper-header {
        height: 100px;
        padding: 20px 30px;
        display: inline-block;
        position: relative;
        width: 100%;
        box-sizing: border-box;

        .swiper-logo {
            height: 100%;
            display: inline-block;
            float: left;
            margin-right: 45px;
        }

        .swiper-logo > img {
            max-height: 100%;
            vertical-align: middle;
        }

        .brand-info {
            float: left;

            .brand-name {
                font-size: 28px;

                b {
                    color: #b0b0b0;
                    font-weight: normal;
                }
            }

            .brand-update {
                font-size: 22px;

                b {
                    color: #b0b0b0;
                    font-weight: normal;
                }

                .brand-new {
                    color: #86bf4a;
                    margin-right: 24px;
                }

                .brand-discount {
                    color: #d1021c;
                }
            }
        }

        .fav-more {
            width: 2.5rem;
            height: 2.5rem;
            position: absolute;
            top: 0;
            right: 0;

            &:after {
                background: url("img/home/fav/fav-more.png");
                background-size: 100%;
                width: 18px;
                height: 29px;
                position: absolute;
                top: 50%;
                right: 30px;
                margin-top: -15px;
                content: "";
            }
        }
    }

    .fav-content .fav-brand-swiper .swiper-container {
        height: 365px;
        margin: 0 30px;

        .swiper-slide {
            width: 255px;
            height: 100%;
            float: left;
            padding-right: 30px;

            &:nth-last-of-type(1) {
                padding-right: 0;
            }

            img {
                display: block;
                width: 100%;
                height: 300px;
                overflow: hidden;
            }

            .brand-product {
                height: 65px;
                line-height: 65px;
                text-align: center;
                font-size: 22px;

                .price-discount span {
                    color: #d1021c;
                }

                .price-discount b {
                    color: #b0b0b0;
                    text-decoration: line-through;
                    font-weight: normal;
                    margin-left: 13px;
                }
            }
        }
    }

    .fav-load-more,
    .fav-brand-load-more {
        width: 100%;
        height: 2rem;
        line-height: 2rem;
        text-align: center;
        color: #444;

        &.load-background {
            background: url("img/loading.gif") center center no-repeat;
            background-size: auto 40%;
        }
    }

    .fav-content-loading {
        width: 100%;
        height: 2rem;
        background: url("img/loading.gif") center center no-repeat;
        background-size: auto 40%;
        position: absolute;
        top: 50%;
        left: 0;
        margin-top: 9.5rem;
    }
}