
.center {
  position: relative;
  }
.checkbox{
  position: relative;

}
input[type='checkbox'] {
  position: relative;

  width: 80px;
  height: 40px;
  translate: transform(0, 0);
  -webkit-appearance: none;
  -ms-appearance: none;
  outline: none;
  border-radius: 20px;
  background: #3DD9D9;
  box-shadow: inset 0 0 5px rgba(0,0,0,0.3) ;
  transition: 0.5s ease-out;
}
input:checked[type='checkbox'] {
  background: #D50345;
}
input[type='checkbox']:before {
  content:'';
  position: absolute;
  width: 40px;
  height: 40px;
  border-radius: 20px;
  top: 0;
  left: 0;
  background: #ffffff;
  transform: scale(1.1);
  box-shadow: 0 2px 5px rgba(0,0,0,.2); 
  transition: .5s;
}
input:checked[type='checkbox']:before {
  left: 40px;
}

.light {
  text-align: center;
  font-size: 30px;
  font-family: helvetica;
  letter-spacing: 2px;
  font-weight: bold;
  color: #333;
}
.off{
  color: #efefef;
}
