/* 资源下载阶段与 React 初始化共用，不依赖应用 JS 或 Ant 样式注入。 */
.fly-app-loading {
  position: fixed;
  z-index: 1000;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--ant-color-bg-container, #fff);
  color: var(--ant-color-primary, #2d8cf0);
}

.fly-app-loading-dots {
  position: relative;
  display: block;
  width: 32px;
  height: 32px;
  transform: rotate(45deg);
  animation: fly-app-loading-rotate 1.4s linear infinite;
}

.fly-app-loading-dot {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.35;
  animation: fly-app-loading-pulse 1s ease-in-out infinite alternate;
}

.fly-app-loading-dot:nth-child(1) {
  top: 0;
  left: 0;
}

.fly-app-loading-dot:nth-child(2) {
  top: 0;
  right: 0;
  animation-delay: -0.25s;
}

.fly-app-loading-dot:nth-child(3) {
  right: 0;
  bottom: 0;
  animation-delay: -0.5s;
}

.fly-app-loading-dot:nth-child(4) {
  bottom: 0;
  left: 0;
  animation-delay: -0.75s;
}

@keyframes fly-app-loading-rotate {
  to {
    transform: rotate(405deg);
  }
}

@keyframes fly-app-loading-pulse {
  to {
    opacity: 1;
  }
}

html[data-theme='dark'] .fly-app-loading {
  background: #141414;
}

@media (prefers-reduced-motion: reduce) {
  .fly-app-loading-dots,
  .fly-app-loading-dot {
    animation: none;
  }

  .fly-app-loading-dot {
    opacity: 0.7;
  }
}
