*,
*:before,
*:after {
  box-sizing: border-box;
}


.toggle {
  cursor: pointer;
  display: inline-block;
}

.toggle-switch {
  display: inline-block;
  background: #ccc;
  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: linear-gradient(to bottom, #fff 0%, #eee 100%);
  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-checkbox:checked + .toggle-switch {
  background: #56c080;
}
.toggle-checkbox:checked + .toggle-switch:before {
  left: 30px;
}

.toggle-checkbox {
  position: absolute;
  visibility: hidden;
}

.toggle-label {
  margin-left: 5px;
  position: relative;
  top: 0px;
}


/* 
Small
*/

.toggle-switch-sm:before, .toggle-switch-sm:after {
  content: "";
}
.toggle-switch-sm {
  display: inline-block;
  background: #ccc;
  border-radius: 8px;
  width: 29px;
  height: 16px;
  position: relative;
  vertical-align: middle;
  transition: background 0.25s;
}
.toggle-switch-sm:before, .toggle-switch-sm:after {
  content: "";
}
.toggle-switch-sm:before {
  display: block;
  background: linear-gradient(to bottom, #fff 0%, #eee 100%);
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.25);
  width: 12px;
  height: 12px;
  position: absolute;
  top: 2px;
  left: 2px;
  transition: left 0.25s;
}
.toggle-sm:hover .toggle-switch-sm:before {
  background: linear-gradient(to bottom, #fff 0%, #fff 100%);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.5);
}
.toggle-checkbox:checked + .toggle-switch-sm {
  background: #56c080;
}

.toggle-checkbox:checked + .toggle-switch-sm:before {
  left: 15px;
}