.material-switch {
    display: inline-block;
    margin-left: 15px;
}

.material-switch > input[type="checkbox"] {
    display: none;
}

.material-switch > label.title {
    margin-left: 5px;
    display: inline-flex;
}

.material-switch > label {
    cursor: pointer;
}

.material-switch > label.label {
    height: 0;
    position: relative;
    width: 40px;
    top: 4px;
}

.material-switch > label.label::before {
    background: #c4c4c4;
    border-radius: 8px;
    content: '';
    height: 20px;
    margin-top: -8px;
    position: absolute;
    opacity: 0.3;
    transition: all 0.4s ease-in-out;
    width: 40px;
}

.material-switch > label.label::after {
    background: #b3b3b3;
    border-radius: 16px;
    content: '';
    left: 24px;
    top: 1px;
    margin-top: -8px;
    position: absolute;
    transition: all 0.3s ease-in-out;
    height: 18px;
    width: 18px;
    -webkit-box-shadow: 0px 0px 3px 0px rgba(0,0,0,0.75);
    -moz-box-shadow: 0px 0px 3px 0px rgba(0,0,0,0.75);
    box-shadow: 0px 0px 3px 0px rgba(0,0,0,0.75);
}

.material-switch > input[type="checkbox"]:checked + label.label::before {
    background: #c4c4c4;
    opacity: 0.5;
}

.material-switch > input[type="checkbox"]:checked + label.label::after {
    background: #fff;
    left: -4px;
}


