/**
 * Toggle button
 */
aui-toggle {
  box-sizing: border-box;
  cursor: pointer;
  display: inline-block;
  font-size: 12px;
  height: 2.16666667em;
  padding: 6px 8px;
  position: relative;
  vertical-align: baseline;
  width: 58px;
}
aui-toggle::before {
  content: "\00a0";
}
aui-toggle::after {
  background-color: transparent;
  border-radius: 3em;
  bottom: 0;
  content: '';
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
  top: 0;
}
aui-toggle:not([disabled]):not([busy]):hover .aui-toggle-input + .aui-toggle-view {
  background-color: #a5adba;
}
aui-toggle:not([disabled]):not([busy]):hover .aui-toggle-input:checked + .aui-toggle-view {
  background-color: #36b37e;
}
aui-toggle[disabled],
aui-toggle[busy] {
  cursor: auto;
}
aui-toggle[disabled] .aui-toggle-input,
aui-toggle[busy] .aui-toggle-input {
  cursor: auto;
  pointer-events: none;
}
aui-toggle[busy] .aui-toggle-tick::before,
aui-toggle[busy] .aui-toggle-cross::before {
  opacity: 0;
  transition: auto;
}
aui-toggle[busy]::after {
  background-color: rgba(255, 255, 255, 0.5);
}
aui-toggle[busy] aui-spinner[size="small"] {
  color: inherit;
  position: relative;
  top: -2px;
}
aui-toggle[disabled] .aui-toggle-view {
  background-color: #f4f5f7;
}
aui-toggle[disabled] .aui-toggle-tick,
aui-toggle[disabled] .aui-toggle-cross {
  color: #a5adba;
}
.aui-toggle-input {
  -webkit-appearance: button;
  -moz-appearance: radio-container;
  border-radius: 3em;
  bottom: 0;
  cursor: pointer;
  height: 100%;
  left: 0;
  margin: 0;
  padding: 0;
  position: absolute;
  right: 0;
  top: 0;
  width: 100%;
}
.aui-toggle-view {
  background-color: #6b778c;
  border-radius: 3em;
  bottom: 0;
  box-sizing: border-box;
  display: block;
  left: 0;
  pointer-events: none;
  position: absolute;
  right: 0;
  transition: background-color 100ms linear;
  top: 0;
}
.aui-toggle-view::after {
  background-color: #ffffff;
  border-radius: 3em;
  bottom: 1px;
  content: '';
  display: block;
  left: 1px;
  position: absolute;
  top: 1px;
  -webkit-transition: -webkit-transform 150ms ease-in-out;
  transition: transform 150ms ease-in-out;
  width: 24px;
}
.aui-toggle-tick,
.aui-toggle-cross {
  position: absolute;
  top: 5px;
}
.aui-toggle-tick::before,
.aui-toggle-cross::before {
  left: 50%;
  -ms-transform: translateX(-50%);
  -webkit-transform: translateX(-50%);
  transform: translateX(-50%);
  transition: opacity 250ms ease-in-out;
}
.aui-toggle-tick {
  color: #ffffff;
  left: 8px;
}
.aui-toggle-cross {
  color: #ffffff;
  right: 8px;
}
.aui-toggle-input:checked:enabled + .aui-toggle-view,
.aui-toggle-input.indeterminate-checked + .aui-toggle-view {
  background-color: #00875a;
}
.aui-toggle-input:checked + .aui-toggle-view::after,
.aui-toggle-input.indeterminate-checked + .aui-toggle-view::after {
  -ms-transform: translateX(32px);
  -webkit-transform: translateX(32px);
  transform: translateX(32px);
}
