﻿.switch {
    cursor: pointer;
    position: relative;
    height: 30px;
    line-height: 30px;
}
    .switch input {
        position: absolute;
        opacity: 0;
    }
    .switch input:checked + .pic {
        background-color: #118dcf;
    }
    .switch input:checked + .pic:after {
        right: 21px;
    }
    .switch .pic {
        position: relative;
        width: 50px;
        height: 30px;
        -moz-border-radius: 30px;
        -webkit-border-radius: 30px;
        border-radius: 30px;
        background-color: #89898C;
        border: 1px solid #E5E5E5;
        display: inline-block;
        -webkit-transition: all 200ms ease;
        -moz-transition: all 200ms ease;
        -ms-transition: all 200ms ease;
        -o-transition: all 200ms ease;
        transition: all 200ms ease;
        border-color: rgba(0, 0, 0, 0.1);
        right: 0px;
    }
    .switch .pic:after {
        content: "";
        position: absolute;
        background-color: #fff;
        width: 26px;
        top: 1px;
        bottom: 1px;
        right: 1px;
        -moz-border-radius: 30px;
        -webkit-border-radius: 30px;
        border-radius: 30px;
        -moz-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.25);
        -webkit-box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.25);
        box-shadow: 1px 1px 3px rgba(0, 0, 0, 0.25);
        -webkit-transition: all 200ms ease;
        -moz-transition: all 200ms ease;
        -ms-transition: all 200ms ease;
        -o-transition: all 200ms ease;
        transition: all 200ms ease;
    }
    .switch span:last-child {
        vertical-align: inherit;
        margin-right: 5px;
    }

.switch.switch-middle {
    margin: 10px 0px 4px;
    height: 25px;
    line-height: 25px;
}
.switch.switch-middle .pic {
    width: 40px;
    height: 25px;
    -moz-border-radius: 25px;
    -webkit-border-radius: 25px;
    border-radius: 25px;
}
.switch.switch-middle input:checked + .pic:after {
    right: 16px;
}
.switch.switch-middle .pic:after {
    width: 21px;
}

.switch.switch-small {
    margin: 6px 0px 4px;
    height: 20px;
    line-height: 20px;
}
.switch.switch-small .pic {
    width: 30px;
    height: 20px;
    -moz-border-radius: 20px;
    -webkit-border-radius: 20px;
    border-radius: 20px;
}
.switch.switch-small input:checked + .pic:after {
    right: 11px;
}
.switch.switch-small .pic:after {
    width: 16px;
}
