/**
* @author zhixin wen <wenzhixin2010@gmail.com>
* @version 0.0.1
* @blog http://wenzhixin.net.cn
*/

.ms-parent {
    display: inline-block;
    position: relative;
    vertical-align: middle;
    width: 100%;
}

.ms-choice {
    display: block;
    height: 52px;
    padding: 0 20px 0 20px;
    overflow: hidden;
    position: relative;
    width: 100%;
    cursor: pointer;
    white-space: nowrap;
    text-decoration: none;
    background-color: #fff;
    position: relative;
    line-height: 52px;
}

.ms-choice::before,
.ms-choice::after {
    content: '';
    display: inline-block;
    position: absolute;
    top: 0;
    bottom: 0;
    margin: auto;
}

.ms-choice::before {
    background-color: #36c6d7;
    width: 60px;
    height: auto;
    right: 0;
}

@media screen and (max-width:600px) {
    .ms-choice::before {
        width: 40px;
    }
}


.ms-choice::after {
    top: -4px;
    right: 20px;
    width: 16px;
    height: 16px;
    border-top: 2px solid #fff;
    border-right: 2px solid #fff;
    -webkit-transform: rotate(135deg);
    transform: rotate(135deg);
}

@media screen and (max-width:600px) {
    .ms-choice::after {
        top: -4px;
        right: 14px;
        width: 10px;
        height: 10px;
        border-top: 2px solid #fff;
        border-right: 2px solid #fff;
    }
}

.ms-choice.disabled {
    background-color: #f4f4f4;
    background-image: none;
    border: 1px solid #ddd;
    cursor: default;
}

.ms-choice > span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    float: left;
}

.ms-choice > span.placeholder {
    color: #666;
}

.ms-choice > div {
    float: right;
    width: 20px;
    height: 25px;
    background: url('multiple-select.png') right top no-repeat;
}

.ms-choice > div.open {
    background: url('multiple-select.png') left top no-repeat;
}

.ms-drop {
    max-height: 250px;
    overflow: auto;
    display: none;
    margin-top: 2px;
    padding: 20px 20px 14px 20px;
    position: absolute;
    z-index: 1000;
    top: 100%;
    width: 100%;
    background: #fff;
    border: 1px solid #ddd;

    -webkit-box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
    -moz-box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
    box-shadow: 0 4px 5px rgba(0, 0, 0, .15);
}

@media screen and (max-width:600px) {
    .ms-drop {
        padding: 10px 10px 10px 10px;
    }
}

.ms-drop ul {
    margin: 0;
    padding: 5px 0;
    display: -webkit-flex;
    display: -moz-flex;
    display: -ms-flex;
    display: -o-flex;
    display: flex;
    flex-wrap: wrap;
}

.ms-drop li {
    list-style: none;
    display: list-item;
    background-image: none;
    margin-right: 5px;
    margin-bottom: 5px;
}

.ms-drop li span {
    background-color: #f2f0eb;
    border-radius: 5px;
    display: block;
    padding: 8px 20px 8px 36px;
    font-weight: bold;
    position: relative;

}

.ms-drop li span::before,
.ms-drop li span::after {
    content: '';
    display: inline-block;
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    margin: auto;
}

.ms-drop li span::before {
    background-color: #fff;
    width: 16px;
    height: 16px;
    border: 2px solid $cl-base;
    left: 10px;
}


.ms-drop li input[type=checkbox] {
    display: none;
}

.ms-drop li input[type=checkbox]:checked + span {
    background-color: #36c6d7;
    color: #fff;

}

.ms-drop li input[type=checkbox]:checked + span::before {
    background-color: #ffd306;
    border: 2px solid #fff;
}

.ms-drop li.multiple {
    display: block;
    float: left;
}

.ms-drop li.multiple label {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;

}

.ms-drop li label.optgroup {
    font-weight: bold;
}

.ms-drop input[type="checkbox"] {
    float: left;
    margin-right: 5px;
}
