.processing-state {
  @include processing-animation("foreground-branding");
  min-height: calc(#{font-size($typography-h1-fontsize)} * 2);

  &::after {
    top: .5em;
    font-size: font-size($typography-h1-fontsize);
  }

  &--updating {
    min-height: 0; //no min height when stuff is updating and will have a natural height from the element that is being updated

    &::after {
      animation-name: animation-delay-spinner, animation-processing;
      animation-delay: 0ms, 3000ms;
      z-index: $z-index-processing-state + 1;
    }

    &::before {
      content: "";
      display: block;
      position: absolute;
      background-color: color("background");
      opacity: .7;
      top: 0;
      right: 0;
      bottom: 0;
      left: 0;
      z-index: $z-index-processing-state;
    }
  }

  @keyframes animation-delay-spinner {
    from {
      background-color: transparent;
    }

    99% {
      background-color: transparent;
    }

    to {
      background-color: var(--processing-color);
    }
  }

  &--init {
    &-table {
      border-top: $width-border solid color("border");
      border-bottom: $width-border solid color("border");
      box-sizing: content-box; //exclude border-widths from the min-height, to ensure spinner is centred
    }

    &-box {
      background-color: color("background-secondary");
    }

    &-cards {
      position: relative;
      border-top: $width-border-utility solid color("border-theme");
      border-bottom: $width-border-utility solid color("background-secondary");
      background-color: color("background-secondary");

      &::before {
        @include breakpoint("medium") {
          content: "";
          display: block;
          position: absolute;
          top: $width-border-utility * -1;
          right: 0;
          bottom: $width-border-utility * -1;
          left: 0;
          background-image: linear-gradient(color("background"), color("background"));
          background-size: spacing($card-container-spacing) 100%;
          background-position: 50% center;
          background-repeat: no-repeat;
        }

        @include breakpoint("wide"){
          background-image: linear-gradient(to right, color("background") 0, color("background") spacing($card-container-spacing), transparent spacing($card-container-spacing), transparent 100%);
          background-size: spacing($card-container-spacing, $times: .25, $add: 25%) 100%;
          background-position: right center;
          background-repeat: repeat-x;
        }
      }  
    }
  }

  &--constrain-width {
    max-width: $line-width-max;
  }
}
