@import "_theme.scss";

.checkbox {
  display: block;
  position: relative;
  padding-left: 45px;
  margin-bottom: 0;
  font-size: var(--text-size-label);
  color: var(--text-color-medium);
}

/* Hide the browser's default checkbox */
.checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* Create a custom checkbox */
.checkmark {
  position: absolute;
  top: -3px;
  left: 0;
  height: 30px;
  width: 30px;
  background-color: white;
  border: 1px solid var(--color-line);
  border-radius: 5px;
}

/* Create the checkmark/indicator (hidden when not checked) */
.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

/* Show the checkmark when checked */
.checkbox input:checked ~ .checkmark:after {
  display: block;
}

.checkbox input:checked ~ .checkmark {
  border-color: var(--color-highlight);
}

.checkmark:hover {
  border-color: var(--color-highlight);
}

/* Style the checkmark/indicator */
.checkbox .checkmark:after {
  left: 11px;
  top: 6px;
  width: 7px;
  height: 14px;
  border: solid var(--color-highlight);
  border-width: 0 2px 2px 0;
  -webkit-transform: rotate(45deg);
  -ms-transform: rotate(45deg);
  transform: rotate(45deg);
}
