Coder Wrap provides free to use snippets Coder Wrap provides free to use snippets

Back to CSS3
Preview Source Code
Download
HTML
CSS
/**Typeo CSS Start**/
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,400;0,500;0,600;0,700;1,400&display=swap');
*{ box-sizing: border-box;}

body {
  font-family: "Poppins", sans-serif;
  color: #444;
  box-sizing: border-box;
  background-color: #f5f5f5;
}
.exp {
      display: flex;
    width: 100%;
    background-color: #1790b5;
    max-width: 600px !important;
    margin: auto;
    height: 300px !important;
    flex-flow: row wrap;
    align-items: center;
    justify-content: center;
}
/**Typeo CSS End**/


.exp .checkbox label {
  display: inline-block;
  color: #fff;
  cursor: pointer;
  position: relative;
}
.exp .checkbox label span {
  display: inline-block;
  position: relative;
  background-color: transparent;
  width: 25px;
  height: 25px;
  transform-origin: center;
  border: 2px solid #fff;
  border-radius: 50%;
  vertical-align: -6px;
  margin-right: 10px;
  transition: background-color 150ms 200ms, transform 350ms cubic-bezier(0.78, -1.22, 0.17, 1.89);
}
.exp .checkbox label span:before {
  content: "";
  width: 0px;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  position: absolute;
  transform: rotate(45deg);
  top: 10px;
  left: 6px;
  transition: width 50ms ease 50ms;
  transform-origin: 0% 0%;
}
.exp .checkbox label span:after {
  content: "";
  width: 0;
  height: 2px;
  border-radius: 2px;
  background: #fff;
  position: absolute;
  transform: rotate(305deg);
  top: 14px;
  left: 9px;
  transition: width 50ms ease;
  transform-origin: 0% 0%;
}
.exp .checkbox label:hover span:before {
  width: 7px;
  transition: width 100ms ease;
}
.exp .checkbox label:hover span:after {
  width: 10px;
  transition: width 150ms ease 100ms;
}

.exp .checkbox input[type=checkbox] {
  display: none;
}
.exp .checkbox input[type=checkbox]:checked + label span {
  background-color: #fff;
  transform: scale(1.25);
}
.exp .checkbox input[type=checkbox]:checked + label span:after {
  width: 10px;
  background: #1790b5;
  transition: width 150ms ease 100ms;
}
.exp .checkbox input[type=checkbox]:checked + label span:before {
  width: 5px;
  background: #1790b5;
  transition: width 150ms ease 100ms;
}
.exp .checkbox input[type=checkbox]:checked + label:hover span {
  background-color: #fff;
  transform: scale(1.25);
}
.exp .checkbox input[type=checkbox]:checked + label:hover span:after {
  width: 10px;
  background: #1790b5;
  transition: width 150ms ease 100ms;
}
.exp .checkbox input[type=checkbox]:checked + label:hover span:before {
  width: 7px;
  background: #1790b5;
  transition: width 150ms ease 100ms;
}

/**Checkbox CSS**/

Related Snippets

Leave a comment

Your email address will not be published. Required fields are marked *