@charset "UTF-8";

/* mixins & extensions */

@keyframes in {
  0% {
    opacity: 0;
  }

  100% {
    opacity: 1;
  }
}

@keyframes in-down {
  0% {
    opacity: 0;
    transform: translate3D(0, -5px, 0);
  }

  100% {
    opacity: 1;
    transform: translate3D(0, 0, 0);
  }
}

@keyframes in-up {
  0% {
    opacity: 0;
    transform: translate3D(0, 5px, 0);
  }

  100% {
    opacity: 1;
    transform: translate3D(0, 0, 0);
  }
}

@keyframes in-scale {
  0% {
    opacity: 0;
    transform: scale3D(0.95, 0.95, 1);
  }

  100% {
    opacity: 1;
    transform: scale3D(1, 1, 1);
  }
}

/**
* Currently only used in Checkbox.
*/

:root {
  --calcite-popper-transition: 150ms ease-in-out;
}

:host([hidden]) {
  display: none;
}

:host {
  display: block;
}

.container {
  display: block;
  padding: 7px 0;
  margin: 7px 0;
  position: relative;
}

:host([disabled]) {
  opacity: var(--calcite-ui-opacity-disabled);
  pointer-events: none;
}

:host([disabled]) .track__range,
:host([disabled]) .tick--active {
  background-color: var(--calcite-ui-text-3);
}

:host([disabled]) .graph .graph-path--highlight {
  fill: var(--calcite-ui-text-3);
}

/*
 * Ensure we have enough space on variants
 * with text elements to prevent overlap
 */

:host([label-handles]) .container,
:host([precise]:not([precise=false])) .container {
  margin-top: 21px;
}

:host([label-ticks]),
:host([precise]:not([precise=false])) .container--range {
  margin-bottom: 21px;
}

:host([precise]:not([precise=false])[label-handles]) .container {
  margin-top: 35px;
}

:host([precise]:not([precise=false])[label-handles]) .container--range {
  margin-bottom: 35px;
}

.thumb {
  position: absolute;
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
  z-index: 2;
  outline: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  transform: translate(7px, -8px);
}

.thumb .handle__label {
  font-size: 0.75rem;
  line-height: 1.5;
  font-weight: 500;
  line-height: 1;
  color: var(--calcite-ui-text-2);
  margin-bottom: 5px;
}

.thumb .handle__label.static, .thumb .handle__label.transformed {
  opacity: 0;
  position: absolute;
  top: 0;
  bottom: 0;
}

.thumb .handle__label--minValue.hyphen::after {
  content: "—";
  display: inline-block;
  width: 1em;
}

.thumb .handle {
  outline-offset: 0;
  outline-color: transparent;
  transition: outline-offset 100ms ease-in-out, outline-color 100ms ease-in-out;
  height: 14px;
  width: 14px;
  box-sizing: border-box;
  border-radius: 100%;
  background-color: var(--calcite-ui-foreground-1);
  box-shadow: 0 0 0 2px var(--calcite-ui-text-3) inset;
  transition: border 0.25s ease, background-color 0.25s ease, box-shadow 0.25s ease;
}

.thumb .handle-extension {
  width: 2px;
  height: 7px;
  background-color: var(--calcite-ui-text-3);
}

.thumb:hover .handle {
  box-shadow: 0 0 0 3px var(--calcite-ui-brand) inset;
}

.thumb:hover .handle-extension {
  background-color: var(--calcite-ui-brand);
}

.thumb:focus .handle {
  outline: 2px solid var(--calcite-ui-brand);
  outline-offset: 2px;
  outline-offset: 2px;
}

.thumb:focus .handle-extension {
  background-color: var(--calcite-ui-brand);
}

.thumb--minValue {
  transform: translate(-7px, -8px);
}

/* uncomment for helpful debugging UI */

:host([label-handles]) .thumb {
  transform: translate(50%, -25px);
}

:host([label-handles]) .thumb--minValue {
  transform: translate(-50%, -25px);
}

:host([has-histogram][label-handles]) .thumb {
  transform: translate(50%, -8px);
}

:host([has-histogram][label-handles]) .thumb .handle__label {
  margin-bottom: unset;
  margin-top: 5px;
}

:host([has-histogram][label-handles]) .thumb--minValue {
  transform: translate(-50%, -8px);
}

:host([precise]:not([precise=false])) .thumb {
  transform: translate(7px, -21px);
}

:host([precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-7px, -2px);
}

:host([precise]:not([precise=false])) .thumb--minValue .handle__label {
  margin-bottom: unset;
  margin-top: 5px;
}

:host([has-histogram][precise]:not([precise=false])) .thumb {
  transform: translate(7px, -2px);
}

:host([has-histogram][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -2px);
}

:host([ticks][precise]:not([precise=false])) .thumb {
  transform: translate(7px, -20px);
}

:host([ticks][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-7px, -3px);
}

:host([has-histogram][ticks][precise]:not([precise=false])) .thumb {
  transform: translate(7px, -3px);
}

:host([has-histogram][ticks][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -3px);
}

:host([label-handles][precise]:not([precise=false])) .thumb {
  transform: translate(50%, -38px);
}

:host([label-handles][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -2px);
}

:host([has-histogram][label-handles][precise]:not([precise=false])) .thumb {
  transform: translate(50%, -2px);
}

:host([has-histogram][label-handles][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -2px);
}

:host([ticks][label-handles][precise]:not([precise=false])) .thumb {
  transform: translate(50%, -37px);
}

:host([ticks][label-handles][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -3px);
}

:host([has-histogram][ticks][label-handles][precise]:not([precise=false])) .thumb {
  transform: translate(50%, -3px);
}

:host([has-histogram][ticks][label-handles][precise]:not([precise=false])) .thumb--minValue {
  transform: translate(-50%, -3px);
}

.thumb:focus,
.thumb--active {
  z-index: 3;
}

.thumb:focus .handle,
.thumb--active .handle {
  background-color: var(--calcite-ui-brand);
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.16);
}

.thumb:hover.thumb--precise:after,
.thumb:focus.thumb--precise:after,
.thumb--active.thumb--precise:after {
  background-color: var(--calcite-ui-brand);
}

.track {
  height: 2px;
  border-radius: 0;
  z-index: 1;
  background-color: var(--calcite-ui-border-2);
  transition: all 250ms ease-in;
  position: relative;
}

.track__range {
  position: absolute;
  top: 0;
  height: 2px;
  background-color: var(--calcite-ui-brand);
}

.container--range .track__range:hover {
  cursor: ew-resize;
}

.container--range .track__range:after {
  content: "";
  position: absolute;
  top: -5px;
  width: 100%;
  height: 14px;
}

.tick {
  position: absolute;
  top: -2px;
  width: 2px;
  height: 4px;
  left: var(--calcite-ui-border-1-offset);
  margin-left: -2px;
  border: 1px solid var(--calcite-ui-foreground-1);
  background-color: var(--calcite-ui-border-1);
}

.tick--active {
  background-color: var(--calcite-ui-brand);
}

.tick__label {
  position: absolute;
  font-size: 0.75rem;
  line-height: 1.5;
  font-weight: 500;
  color: var(--calcite-ui-text-2);
  width: 4em;
  margin: 14px -2em;
  text-align: center;
  display: block;
  pointer-events: none;
}

.tick__label--min {
  left: 0;
  margin: 14px -3px;
  text-align: left;
  transition: opacity 150ms;
}

.tick__label--max {
  left: unset;
  right: 0;
  margin: 14px -3px;
  text-align: right;
  transition: opacity 50ms;
}

:host([has-histogram][label-handles]) .tick__label--min,
:host([has-histogram][label-handles]) .tick__label--max {
  margin: 6px -3px;
  font-weight: 300;
  color: var(--calcite-ui-text-3);
}

:host([has-histogram][precise]:not([precise=false])) .tick__label--min,
:host([has-histogram][precise]:not([precise=false])) .tick__label--max {
  margin: 6px -3px;
  font-weight: 300;
  color: var(--calcite-ui-text-3);
}

.graph {
  width: 100%;
  height: 48px;
  position: relative;
  color: var(--calcite-ui-foreground-2);
}

.graph svg {
  position: absolute;
  width: 100%;
  height: 48px;
}

.graph .graph-path--highlight {
  fill: var(--calcite-ui-brand);
  opacity: 0.25;
}