/* 组态风格科技感加载动画 */
.loading {
  display: flex;
  width: 100%;
  height: 100%;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  background: linear-gradient(135deg, #0a0e17 0%, #151a26 50%, #0d1320 100%);
  position: relative;
  overflow: hidden;
}

/* 背景网格 */
.loading::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image:
    linear-gradient(rgba(0, 168, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 168, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
  animation: gridMove 20s linear infinite;
}

/* 背景扫描线 */
.loading::after {
  content: '';
  position: absolute;
  top: -100%;
  left: 0;
  width: 100%;
  height: 200%;
  background: linear-gradient(180deg,
      transparent 0%,
      transparent 45%,
      rgba(0, 168, 255, 0.08) 50%,
      transparent 55%,
      transparent 100%);
  animation: scanLine 3s ease-in-out infinite;
}

@keyframes gridMove {
  0% {
    transform: translate(0, 0);
  }

  100% {
    transform: translate(50px, 50px);
  }
}

@keyframes scanLine {
  0% {
    transform: translateY(0);
  }

  100% {
    transform: translateY(50%);
  }
}

.loading .loading-wrap {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  z-index: 10;
}

/* 核心装置容器 */
.loading .dots {
  position: relative;
  width: 200px;
  height: 200px;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* 外环 - 旋转边框 */
.loading .dots::before {
  content: '';
  position: absolute;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top: 2px solid #00a8ff;
  border-right: 2px solid #00a8ff;
  animation: rotateRing 2s linear infinite;
  box-shadow:
    0 0 20px rgba(0, 168, 255, 0.3),
    inset 0 0 20px rgba(0, 168, 255, 0.1);
}

/* 内环 - 反向旋转 */
.loading .dots::after {
  content: '';
  position: absolute;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-bottom: 2px solid #00d4ff;
  border-left: 2px solid #00d4ff;
  animation: rotateRingReverse 1.5s linear infinite;
  box-shadow:
    0 0 15px rgba(0, 212, 255, 0.3),
    inset 0 0 15px rgba(0, 212, 255, 0.1);
}

@keyframes rotateRing {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

@keyframes rotateRingReverse {
  0% {
    transform: rotate(360deg);
  }

  100% {
    transform: rotate(0deg);
  }
}

/* 核心六边形 */
.dot {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  justify-content: center;
  align-items: center;
  animation: none;
  transform: none;
  margin-top: 0;
}

.dot::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(0, 168, 255, 0.2) 0%, rgba(0, 212, 255, 0.1) 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  animation: hexPulse 2s ease-in-out infinite;
  box-shadow: 0 0 30px rgba(0, 168, 255, 0.5);
}

.dot::after {
  content: '';
  position: absolute;
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #00a8ff 0%, #00d4ff 100%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  animation: hexPulseInner 2s ease-in-out infinite;
  box-shadow:
    0 0 40px rgba(0, 168, 255, 0.8),
    0 0 60px rgba(0, 212, 255, 0.4);
}

@keyframes hexPulse {

  0%,
  100% {
    transform: scale(1);
    opacity: 0.8;
  }

  50% {
    transform: scale(1.1);
    opacity: 1;
  }
}

@keyframes hexPulseInner {

  0%,
  100% {
    transform: scale(1);
    filter: brightness(1);
  }

  50% {
    transform: scale(0.9);
    filter: brightness(1.3);
  }
}

/* 数据点 - 围绕核心旋转 */
.dot i {
  position: absolute;
  width: 8px;
  height: 8px;
  background: #00d4ff;
  border-radius: 50%;
  box-shadow:
    0 0 10px #00d4ff,
    0 0 20px #00d4ff,
    0 0 30px rgba(0, 212, 255, 0.5);
  animation: orbitData 3s linear infinite;
  transform-origin: center;
}

.dot i::before {
  content: '';
  position: absolute;
  width: 30px;
  height: 2px;
  background: linear-gradient(90deg, #00d4ff, transparent);
  top: 50%;
  right: 100%;
  transform: translateY(-50%);
}

.dot i:nth-child(1) {
  top: -60px;
  left: calc(50% - 4px);
  animation-delay: 0s;
}

.dot i:nth-child(2) {
  top: calc(50% - 4px);
  right: -60px;
  left: auto;
  animation-delay: 0.75s;
}

.dot i:nth-child(3) {
  bottom: -60px;
  top: auto;
  left: calc(50% - 4px);
  animation-delay: 1.5s;
}

.dot i:nth-child(4) {
  top: calc(50% - 4px);
  left: -60px;
  animation-delay: 2.25s;
}

@keyframes orbitData {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  25% {
    opacity: 0.5;
    transform: scale(0.8);
  }

  50% {
    opacity: 1;
    transform: scale(1.2);
  }

  75% {
    opacity: 0.5;
    transform: scale(0.8);
  }
}

/* 标题样式 */
.loading .loading-title {
  display: flex;
  font-weight: 600;
  margin-top: 50px;
  font-size: 28px;
  color: #fff;
  justify-content: center;
  align-items: center;
  letter-spacing: 4px;
  text-shadow: 0 0 20px rgba(0, 168, 255, 0.8);
  position: relative;
}

.loading .loading-title::before {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #00a8ff, transparent);
  animation: titleLine 2s ease-in-out infinite;
}

@keyframes titleLine {

  0%,
  100% {
    width: 60%;
    opacity: 0.5;
  }

  50% {
    width: 100%;
    opacity: 1;
  }
}

/* 加载状态条 */
.loading .loading-subtitle {
  margin-top: 30px;
  font-size: 14px;
  color: #5a7a9a;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.loading .loading-subtitle::before,
.loading .loading-subtitle::after {
  content: '';
  width: 40px;
  height: 1px;
  background: linear-gradient(90deg, transparent, #2a4a6a);
}

.loading .loading-subtitle::after {
  background: linear-gradient(90deg, #2a4a6a, transparent);
}

/* 角落装饰 */
.loading .corner-decoration {
  position: absolute;
  width: 60px;
  height: 60px;
  border: 2px solid transparent;
}

.loading .corner-decoration.top-left {
  top: 30px;
  left: 30px;
  border-top-color: rgba(0, 168, 255, 0.3);
  border-left-color: rgba(0, 168, 255, 0.3);
}

.loading .corner-decoration.top-right {
  top: 30px;
  right: 30px;
  border-top-color: rgba(0, 168, 255, 0.3);
  border-right-color: rgba(0, 168, 255, 0.3);
}

.loading .corner-decoration.bottom-left {
  bottom: 30px;
  left: 30px;
  border-bottom-color: rgba(0, 168, 255, 0.3);
  border-left-color: rgba(0, 168, 255, 0.3);
}

.loading .corner-decoration.bottom-right {
  bottom: 30px;
  right: 30px;
  border-bottom-color: rgba(0, 168, 255, 0.3);
  border-right-color: rgba(0, 168, 255, 0.3);
}

/* 数据流粒子 */
.loading .data-particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: #00d4ff;
  border-radius: 50%;
  opacity: 0.6;
  animation: floatParticle 8s linear infinite;
}

@keyframes floatParticle {
  0% {
    transform: translateY(100vh) translateX(0);
    opacity: 0;
  }

  10% {
    opacity: 0.6;
  }

  90% {
    opacity: 0.6;
  }

  100% {
    transform: translateY(-100vh) translateX(50px);
    opacity: 0;
  }
}

/* 进度条 */
.loading .progress-bar {
  position: absolute;
  bottom: 60px;
  width: 300px;
  height: 4px;
  background: rgba(0, 168, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.loading .progress-bar::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 30%;
  background: linear-gradient(90deg, transparent, #00a8ff, #00d4ff, transparent);
  animation: progressScan 2s ease-in-out infinite;
}

@keyframes progressScan {
  0% {
    left: -30%;
  }

  100% {
    left: 100%;
  }
}