$prefix-size-circle: var(
  --wds-stepper-prefix-size-circle,
  var(--wds-space-550, 22px)
);
$prefix-size-circle-small: var(--wds-space-475, 18px);
$prefix-size-number: var(
  --wds-stepper-prefix-size-number,
  var(--wds-space-475, 18px)
);
$color-ink: var(--wds-color-fill-dark-primary, #151414);
$color-text: var(--wds-color-text-standard-primary, #151414);
$color-text-light: var(--wds-color-text-standard-primary-light, #ffffff);
$color-disabled-fill: var(--wds-color-text-disabled, #a8a6a5);
$color-disabled-text: var(--wds-color-text-standard-secondary-light, #767574);
$color-destructive: var(--wds-color-fill-destructive-primary, #df3336);
$color-destructive-hover: var(
  --wds-color-fill-destructive-primary-hover,
  #be2b2e
);
$color-chevron: var(--wds-color-text-placeholder, #525150);
$color-hover-fill: var(--wds-color-fill-dark-primary-active, #525150);
$color-hover-text: var(--wds-color-text-placeholder, #525150);
$arrow-spacing: var(--wds-space-100, 4px);

.stepper {
  &__marker--style-type-circle {
    width: $prefix-size-circle;
    height: $prefix-size-circle;
    border: 1px solid $color-ink;
    color: $color-text;
  }

  &__step--size-small &__marker--style-type-circle {
    width: $prefix-size-circle-small;
    height: $prefix-size-circle-small;
  }

  &__marker--style-type-text {
    min-width: $prefix-size-number;
    color: $color-text;
  }

  &__marker--type-completed#{&}__marker--style-type-text {
    color: $color-text;
  }

  &__marker--style-type-circle#{&}__marker--hovered {
    background-color: $color-hover-fill;
    color: $color-text-light;
    border: none;
  }

  &__marker--style-type-text#{&}__marker--hovered {
    color: $color-hover-text;
  }

  &__marker--style-type-circle#{&}__marker--selected {
    background-color: $color-ink;
    color: $color-text-light;
    border: none;
  }

  &__marker--style-type-text#{&}__marker--selected {
    color: $color-ink;
  }

  &__marker--type-error {
    color: $color-destructive;
  }

  &__marker--type-error#{&}__marker--style-type-circle {
    border-color: $color-destructive;
  }

  &__marker--type-error#{&}__marker--style-type-circle#{&}__marker--selected {
    background-color: $color-destructive;
    color: $color-text-light;
    border: none;
  }

  &__marker--type-error#{&}__marker--style-type-text#{&}__marker--selected {
    color: $color-destructive;
  }

  &__marker--type-error#{&}__marker--style-type-circle#{&}__marker--hovered:not(
      #{&}__marker--selected
    ) {
    background-color: $color-destructive-hover;
    color: $color-text-light;
    border: none;
  }

  &__marker--type-error#{&}__marker--style-type-text#{&}__marker--hovered:not(
      #{&}__marker--selected
    ) {
    color: $color-destructive-hover;
  }

  &__marker--type-disabled#{&}__marker--style-type-circle {
    background-color: $color-disabled-fill;
    color: $color-text-light;
    border: none;
  }

  &__marker--type-disabled#{&}__marker--style-type-text {
    color: $color-disabled-text;
  }

  &__step--size-small &__marker {
    font-size: var(--wds-font-size-body-tiny, 12px);
    font-weight: var(--wds-font-weight-medium, 500);
    line-height: var(--wds-font-line-height-body-tiny, 16px);
  }

  &__step--size-medium &__marker {
    font-size: var(--wds-font-size-body-small, 14px);
    font-weight: var(--wds-font-weight-medium, 500);
    line-height: var(--wds-font-line-height-body-small, 18px);
  }

  &__step--density-default#{&}__step--size-medium &__marker--style-type-circle {
    font-size: var(--wds-font-size-body-tiny, 12px);
    line-height: var(--wds-font-line-height-body-tiny, 16px);
  }

  &__step &__marker--style-type-text#{&}__marker--selected {
    font-weight: var(--wds-font-weight-bold, 600);
  }

  &__step#{&}__step--style-type-circle &__text {
    color: $color-text;
  }

  &__step#{&}__step--style-type-text#{&}__step--selected &__text {
    font-weight: var(--wds-font-weight-bold, 600);
  }

  &__step#{&}__step--style-type-text &__text {
    color: $color-text;
  }

  &__step#{&}__step--type-disabled#{&}__step--style-type-circle &__text {
    color: $color-disabled-text;
  }

  &__step#{&}__step--type-disabled#{&}__step--style-type-text &__text {
    color: $color-disabled-text;
  }

  &__step#{&}__step--selected &__text {
    color: $color-ink;
  }

  &__step#{&}__step--hovered#{&}__step--clickable &__text {
    color: $color-hover-text;
  }

  &__step#{&}__step--type-error &__text {
    color: $color-destructive;
  }

  &__step#{&}__step--type-error#{&}__step--selected &__text {
    color: $color-destructive;
  }

  &__step--type-error#{&}__step--hovered#{&}__step--clickable &__text {
    color: $color-destructive-hover;
  }

  &__arrow {
    color: $color-chevron;
    margin-right: $arrow-spacing;
    margin-left: $arrow-spacing;
  }

  &__step--style-type-text &__arrow {
    margin-right: $arrow-spacing;
  }

  :global([dir='rtl']) &__step--style-type-text &__arrow {
    margin-right: $arrow-spacing;
    margin-left: $arrow-spacing;
  }

}
