#api-progress-bar {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0;
  background: #4f46e5;
  z-index: 99999;
  transition: none;
  pointer-events: none;
}

#api-progress-bar.active {
  animation: fake-progress 8s ease forwards;
}

#api-progress-bar.done {
  width: 100% !important;
  animation: none;
  transition: width 0.2s ease;
}

@keyframes fake-progress {
  0%   { width: 0%; }
  30%  { width: 60%; }
  70%  { width: 80%; }
  100% { width: 90%; }
}

/* Button spinner */
.btn-spinner {
  display: inline-block;
  width: 13px;
  height: 13px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.65s linear infinite;
  vertical-align: middle;
  margin-right: 5px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

button:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}