@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(359deg);
  }
}

.status {
  display: flex;
  width: 24px;
  height: 24px;
  border-radius: 50%;

  &-label {
    display: inline-flex;
    align-items: center;
    height: 20px;
    padding: 0 8px;
    font-size: 10px;
    font-weight: bold;
    line-height: 12px;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    border-color: transparent;
    border-style: solid;
    border-width: 1px;
    border-radius: 8px;

    &-success,
    &-running {
      color: var(--color-success-medium);
      background-color: rgba(77, 201, 82, 0.05);
      border-color: var(--color-success-medium);
    }

    &-failure,
    &-killed,
    &-error {
      color: var(--color-error-medium);
      background: rgba(255, 245, 245, 0.5);
      border-color: var(--color-error-medium);
    }

    &-pending {
      color: var(--color-running-medium);
      background-color: lighten(orange, 50%);
      border-color: var(--color-running-medium);
    }
  }

  &-success {
    background: var(--color-success-light);
  }

  &-running,
  &-pending,
  &-blocked,
  &-waiting_on_dependencies {
    svg {
      animation: spin 2s linear infinite;
    }
  }

  &-pending,
  &-blocked,
  &-waiting_on_dependencies {
    background: var(--background-pending);
  }

  &-running {
    background: var(--color-running-light);
  }

  &-failure,
  &-error,
  &-declined,
  &-killed {
    background: var(--color-error-light);
  }

  &-inactive {
    background: var(--background-light);

    svg {
      color: var(--color-inactive) !important;
    }
  }

  &-skipped {
    background: var(--color-inactive);
  }

  svg {
    width: inherit;
    height: inherit;
    color: #fff;
  }
}
