/*
Copyright 2022 New Vector Ltd

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/

.toggle {
  align-items: center;
  margin-bottom: 20px;
}

.button {
  position: relative;
  padding: 0;
  transition: background-color 0.2s ease-out 0.1s;
  width: 44px;
  height: 24px;
  border: none;
  border-radius: 21px;
  background-color: var(--quaternary-content);
  cursor: pointer;
  margin-right: 8px;
}

.ball {
  transition: left 0.15s ease-out 0.1s;
  position: absolute;
  width: 20px;
  height: 20px;
  border-radius: 21px;
  background-color: var(--background);
  left: 2px;
  top: 2px;
}

.label {
  padding: 10px 8px;
  line-height: 24px;
  color: var(--quaternary-content);
}

.toggle.on .button {
  background-color: var(--accent);
}

.toggle.on .ball {
  left: 22px;
}

.toggle.on .label {
  color: var(--primary-content);
}
