.tod-toggle-text-wrapper {
  display: inline-block;
}

.tod-toggle-text {
  position: relative;
  display: inline-block;
  box-sizing: border-box;
  width: 365px;
  min-width: 200px;
  height: 32px;
  padding: 0;
  cursor: pointer;
  transition: all 0.2s;
}

.tod-toggle-text-track {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: 4px;
  background-color: var(--color-lightest);
  border: 1px solid var(--color-light);
  transition: all 0.2s;
}

.tod-toggle-text-track-inner {
  position: relative;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tod-toggle-text-option {
  color: var(--color-gray);
  font-size: 12px;
  transition: all 0.2s;
  z-index: 1;
  white-space: nowrap;
  position: relative;
  padding: 0 8px;
}

.tod-toggle-text-option.active {
  color: white;
  font-weight: 500;
}

.tod-toggle-text-handle {
  position: absolute;
  top: 2px;
  left: 2px;
  width: calc(50% - 4px);
  height: calc(100% - 4px);
  background-color: var(--color-accent);
  border-radius: 4px;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
}

.tod-toggle-text.checked .tod-toggle-text-handle {
  transform: translateX(calc(100% + 4px));
}

/* Hover states */
.tod-toggle-text:hover .tod-toggle-text-handle {
  background-color: var(--color-accent);
  opacity: 0.9;
}

/* Active states */
.tod-toggle-text:active .tod-toggle-text-handle {
  background-color: var(--color-accent);
  opacity: 0.8;
}
