body {
  background-color: rgba(255, 255, 255, 0);
}

@keyframes init-load {
  to {
    transform: translateX(-25%);
  }
}

@keyframes full-load {
  0% {
    transform: translateX(-25%);
  }
  100% {
    transform: translateX(0%);
  }
}

@keyframes slideIn {
  from {
    transform: translateY(2rem);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.global-loader {
  display: flex;
  align-items: center;
  justify-content: center;
  position: fixed;
  z-index: 9990;
  inset: 0;
  transition: all 300ms cubic-bezier(1, 0.5, 0.8, 1);
  pointer-events: none;
  overflow: hidden;

  --step-time: 40ms;
  --total-delay: calc(var(--step-time) * 16);
  --init-delay: calc(var(--step-time) * 12);
}

.global-loader__bg {
  content: '';
  position: absolute;
  background-color: transparent;
  backdrop-filter: blur(10px);
  inset: 0;
  z-index: -1;
}

.global-loader__logo {
  position: relative;
  overflow: hidden;
}

.global-loader__logo path {
  opacity: 0;
  transform: translateY(-2rem);
  animation: slideIn calc(var(--step-time) * 8) ease-in-out forwards;
}

.global-loader__logo path:nth-child(1) {
  animation-delay: 0ms !important;
}

.global-loader__logo path:nth-child(2) {
  animation-delay: calc(var(--step-time) * 1) !important;
}

.global-loader__logo path:nth-child(3) {
  animation-delay: calc(var(--step-time) * 2) !important;
}

.global-loader__logo path:nth-child(4) {
  animation-delay: calc(var(--step-time) * 3) !important;
}

.global-loader__logo path:nth-child(5) {
  animation-delay: calc(var(--step-time) * 4) !important;
}

.global-loader__logo path:nth-child(6) {
  animation-delay: calc(var(--step-time) * 5) !important;
}

.global-loader__logo path:nth-child(7) {
  animation-delay: calc(var(--step-time) * 6) !important;
}

.global-loader__logo path:nth-child(8) {
  animation-delay: calc(var(--step-time) * 7) !important;
}

.global-loader__content {
  display: flex;
  flex-direction: column;
  row-gap: 0.75rem;
  transition: all 300ms cubic-bezier(1, 0.5, 0.8, 1);
}

.global-loader__progress,
.global-loader__progress:before {
  height: 0.25rem;
  border-radius: 0.25rem;
}

.global-loader__progress {
  position: relative;
  background-color: rgb(28, 114, 232, 0.3);
  box-shadow:
    0 0 0 0 rgba(0, 0, 0, 0.2),
    0 0 0 0 rgba(0, 0, 0, 0.14),
    0 0 0 0 rgba(0, 0, 0, 0.12);
  overflow: hidden;
  animation: fadeIn 300ms ease forwards;
  animation-delay: var(--init-delay, 600ms);
  opacity: 0;
  transition: all 300ms cubic-bezier(1, 0.5, 0.8, 1);
}

.global-loader__progress:before {
  content: '';
  position: absolute;
  inset: 0;
  background-color: rgb(28, 114, 232);
  transform: translateX(-100%);
  animation: 500ms init-load linear forwards;
  animation-delay: var(--total-delay) !important;
  transition: transform 100ms ease-out;
}

.global-loader--complete {
  opacity: 0;
  transition-delay: 300ms;
  transform: scale(1.75);
  filter: blur(10rem);
}

.global-loader--complete .global-loader__progress:before {
  animation-delay: 0ms !important;
  transform: translateX(-25%);
  animation-name: full-load;
  animation-fill-mode: forwards;
  animation-timing-function: ease-in;
  animation-duration: 200ms;
}
