.dSwitch {
  position: relative;
  width: fit-content; /*TODO: do we really need this*/
}

.wrapper {
  display: flex;
  align-items: center;
  gap: 0.5em;
}

.track {
  display: block;
  position: relative;
  cursor: pointer;
}

.label {
  cursor: pointer;
}

.input {
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  appearance: none;
  cursor: pointer;
}

.label.__disabled,
.track.__disabled {
  cursor: not-allowed;
}

.thumb {
  position: absolute;
  top: 0;
  left: 0;
  background-color: var(--color);
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.thumbInner {
  height: calc(var(--size) / 1.62);
  width: calc(var(--size) / 1.62);
  background-color: var(--background-color);
  scale: 0;
}

.input:checked ~ .thumb {
  left: calc(100% - var(--size));
}

.input:checked ~ .thumb .thumbInner {
  scale: 1;
}


