coupon.scss 3.95 KB
Newer Older
xuzhenghua committed
1 2 3
$bg_voucher: #FE6161;
$bg_free: #E0B97B;
$bg_expand: #8361FE;
zhanghaozhe committed
4 5 6
.coupon {
    position: relative;
    margin-bottom: 15px;
zhanghaozhe committed
7
    box-shadow: 0px 2px 12px -8px;
xuzhenghua committed
8
    border-radius: 3px;
zhanghaozhe committed
9 10 11 12 13 14

    .coupon-info {
        position: relative;
        height: 95px;
        padding: 10px 15px;
        color: $white;
xuzhenghua committed
15
        border-radius: 3px;
zhanghaozhe committed
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30

        .type {
            font-size: $font_14;
        }

        .denomination {
            font-size: $font_26;
            line-height: $font_26;
            text-align: center;

            span {
                font-size: $font_12;
            }
        }

xuzhenghua committed
31
        .course-title {
zhanghaozhe committed
32 33 34 35 36 37
            width: 68.37%;
            margin: 0 auto 4px;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            font-size: $font_16;
xuzhenghua committed
38
            text-align: center;
zhanghaozhe committed
39 40
        }

zhanghaozhe committed
41 42 43 44 45 46 47
        .expire {
            text-align: center;
            font-size: $font_12;
            line-height: $font_16;
        }

        &.coupon-type1 {
xuzhenghua committed
48
            background: $bg_voucher;
zhanghaozhe committed
49
        }
zhanghaozhe committed
50

zhanghaozhe committed
51 52 53
        &.coupon-type2 {
            background: $E0B97B;
        }
xuzhenghua committed
54

xuzhenghua committed
55 56 57 58 59
        &.coupon-type4 {
            background: $bg_expand;
        }

        &.invalid {
zhanghaozhe committed
60 61
            background: $color_999;
        }
zhanghaozhe committed
62 63


zhanghaozhe committed
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78
        & > .iconfont {
            $size: 22px;
            position: absolute;
            top: 50%;
            right: 20px;
            transform: translateY(-50%);
            width: $size;
            height: $size;
            display: none;
        }

        .check {
            display: block;
        }

zhanghaozhe committed
79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
        ul {
            position: absolute;
            bottom: 0;
            left: 0;
            width: 100%;
            display: flex;
            justify-content: space-around;

            li {
                $dot_width: 10px;
                width: $dot_width;
                height: $dot_width;
                border-radius: 50%;
                background: $white;
                transform: translateY(50%);
            }
        }
xuzhenghua committed
96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133


        .progress-container {
            width: 299px;
            margin: 0 auto;

            .denomination {
                font-size: 15px;
                line-height: 1.3em;
                color: #F8E71C;
                span{
                    transform: scale(0.9);
                }
            }

            .progress-bar-container {
                position: relative;
                height: 7px;
                background: #5C2FFF;
                border-radius: 4px;
                overflow: hidden;
                margin-bottom: 6px;
                .progress-bar {
                    position: absolute;
                    left: 0;
                    top: 0;
                    height: 100%;
                    background: #F8E71C;
                    border-radius: 4px;
                }
            }

            .money {
                display: flex;
                justify-content: space-between;
            }
        }

zhanghaozhe committed
134 135 136 137 138 139 140 141
    }

    .coupon-des {
        padding: 10px 15px;
        background: $white;
        display: flex;
        justify-content: space-between;
        align-items: center;
xuzhenghua committed
142
        border-radius: 0 0 3px 3px;
zhanghaozhe committed
143 144

        .limit {
zhanghaozhe committed
145
            width: 63.81%;
zhanghaozhe committed
146 147 148
            font-size: $font_12;
            vertical-align: middle;
            color: $color_666;
zhanghaozhe committed
149 150 151
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
zhanghaozhe committed
152 153 154 155 156 157 158
        }

        .use {
            display: inline-block;
            padding: 3px 8px;
            font-size: $font_12;
            color: $border_f31;
zhanghaozhe committed
159 160
            border: 1px solid $border_f31;
            border-radius: 10px;
zhanghaozhe committed
161 162 163
            background: transparent;
            -webkit-appearance: none;
        }
xuzhenghua committed
164 165 166 167 168 169 170 171 172 173

        .stop-expanding {
            padding: 3px 8px;
            border: 1px solid #FF3131;
            border-radius: 10px;
            -webkit-appearance: none;
            background: transparent;
            color: #FF3131;
            font-size: 10px;
        }
zhanghaozhe committed
174
    }
xuzhenghua committed
175
}