﻿.loader {
  position: fixed;
  top: calc(50vh - 25px);
  left: calc(50vw - 25px);
  z-index: 9999;
  height: 0;
  width: 0;
}

.loader-animation {
  animation: loader-rotate 1s infinite;
  height: 50px;
  width: 50px;
}

.loader-animation:before,
.loader-animation:after {
  border-radius: 50%;
  content: ' ';
  display: block;
  height: 20px;
  width: 20px;
}

.loader-animation:before {
  animation: loader-ball1 1s infinite;
  background-color: #117ecc;
  box-shadow: 30px 0 0 #ff3d00;
  margin-bottom: 10px;
}

.loader-animation:after {
  animation: loader-ball2 1s infinite;
  background-color: #ff3d00;
  box-shadow: 30px 0 0 #117ecc;
}

@keyframes loader-rotate {
  0% {
    transform: rotate(0deg) scale(0.8);
  }

  50% {
    transform: rotate(360deg) scale(1.2);
  }

  100% {
    transform: rotate(720deg) scale(0.8);
  }
}

@keyframes loader-ball1 {
  0% {
    box-shadow: 30px 0 0 #ff3d00;
  }

  50% {
    box-shadow: 0 0 0 #ff3d00;
    margin-bottom: 0;
    transform: translate(15px, 15px);
  }

  100% {
    box-shadow: 30px 0 0 #ff3d00;
    margin-bottom: 10px;
  }
}

@keyframes loader-ball2 {
  0% {
    box-shadow: 30px 0 0 #117ecc;
  }

  50% {
    box-shadow: 0 0 0 #117ecc;
    margin-top: -20px;
    transform: translate(15px, 15px);
  }

  100% {
    box-shadow: 30px 0 0 #117ecc;
    margin-top: 0;
  }
}
