﻿/*
    Toggle switch in basic form credits
    Designed by Álvaro :
    https://codepen.io/alvarotrigo/pen/YzEdrKj
*/

.toggle {
    cursor: pointer;
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
}

.toggle-switch {
    display: inline-block;
    background: #2f3335;
    border-radius: 16px;
    width: 58px;
    height: 32px;
    position: relative;
    vertical-align: middle;
    transition: background 0.25s;
}

.toggle-switch:before, .toggle-switch:after {
    content: "";
}

.toggle-switch:before {
    display: block;
    background: #393e40;
    border-radius: 50%;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
    width: 24px;
    height: 24px;
    position: absolute;
    top: 4px;
    left: 4px;
    transition: left 0.25s;

}

.toggle:hover .toggle-switch:before {
    background: linear-gradient(to bottom, #121212 0%, #121212 100%);
    box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5);
}

.toggle-checkbox:checked + .toggle-switch {
    background: #56c080;
}

.toggle-checkbox:checked + .toggle-switch:before {
    left: 30px;
}

.toggle-checkbox {
    position: absolute;
    visibility: hidden;
}

.toggle-label {
    padding-left: 0.5rem;
    margin-left: 5px;
    position: relative;
    top: 2px;
    font-size: 1rem;
    color: rgb(196, 196, 196);
}
