/* 频谱波纹动画 */
@keyframes spectrumWave {
  0% {
    transform: translateY(0) scaleY(1);
    opacity: 0.8;
  }
  50% {
    transform: translateY(-20px) scaleY(1.2);
    opacity: 1;
  }
  100% {
    transform: translateY(0) scaleY(1);
    opacity: 0.8;
  }
}

.spectrum-wave {
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    45deg,
    transparent 20%,
    rgba(0, 255, 255, 0.1) 40%,
    rgba(0, 255, 255, 0.3) 50%,
    rgba(0, 255, 255, 0.1) 60%,
    transparent 80%
  );
  animation: spectrumWave 3s ease-in-out infinite;
}

.spectrum-wave:nth-child(2) {
  animation-delay: 0.5s;
  background: linear-gradient(
    135deg,
    transparent 20%,
    rgba(204, 51, 51, 0.1) 40%,
    rgba(204, 51, 51, 0.3) 50%,
    rgba(204, 51, 51, 0.1) 60%,
    transparent 80%
  );
}

.spectrum-wave:nth-child(3) {
  animation-delay: 1s;
  background: linear-gradient(
    225deg,
    transparent 20%,
    rgba(0, 102, 204, 0.1) 40%,
    rgba(0, 102, 204, 0.3) 50%,
    rgba(0, 102, 204, 0.1) 60%,
    transparent 80%
  );
}

/* 雷达扫描动画增强 */
@keyframes radarSweepEnhanced {
  0% {
    transform: translate(-50%, -100%) rotate(0deg);
    opacity: 1;
  }
  50% {
    opacity: 0.8;
  }
  100% {
    transform: translate(-50%, -100%) rotate(360deg);
    opacity: 1;
  }
}

.radar-scanner::before {
  animation: radarSweepEnhanced 4s linear infinite;
  box-shadow: 0 0 10px var(--radar-green);
}

.radar-scanner::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 80%;
  height: 80%;
  border: 1px solid var(--radar-green);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.3;
  animation: radarPulse 2s ease-in-out infinite;
}

@keyframes radarPulse {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.3;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.1);
    opacity: 0.6;
  }
}

/* 信号强度指示器动画 */
@keyframes signalStrength {
  0%, 100% {
    height: 10px;
    opacity: 0.3;
  }
  20% {
    height: 25px;
    opacity: 0.6;
  }
  40% {
    height: 40px;
    opacity: 0.8;
  }
  60% {
    height: 55px;
    opacity: 1;
  }
  80% {
    height: 40px;
    opacity: 0.8;
  }
}

.signal-indicator {
  display: flex;
  align-items: end;
  gap: 3px;
  height: 60px;
}

.signal-bar {
  width: 6px;
  background: var(--glow-blue);
  border-radius: 3px;
  animation: signalStrength 2s ease-in-out infinite;
}

.signal-bar:nth-child(1) { animation-delay: 0s; }
.signal-bar:nth-child(2) { animation-delay: 0.1s; }
.signal-bar:nth-child(3) { animation-delay: 0.2s; }
.signal-bar:nth-child(4) { animation-delay: 0.3s; }
.signal-bar:nth-child(5) { animation-delay: 0.4s; }
.signal-bar:nth-child(6) { animation-delay: 0.5s; }

/* 数据流动画 */
@keyframes dataFlow {
  0% {
    transform: translateX(-100%);
    opacity: 0;
  }
  20% {
    opacity: 1;
  }
  80% {
    opacity: 1;
  }
  100% {
    transform: translateX(100%);
    opacity: 0;
  }
}

.data-stream {
  position: relative;
  overflow: hidden;
  background: rgba(0, 255, 255, 0.05);
}

.data-stream::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(0, 255, 255, 0.3),
    transparent
  );
  animation: dataFlow 3s ease-in-out infinite;
}

/* 电路板动画 */
@keyframes circuitPulse {
  0%, 100% {
    opacity: 0.3;
    box-shadow: 0 0 5px var(--glow-blue);
  }
  50% {
    opacity: 1;
    box-shadow: 0 0 20px var(--glow-blue), inset 0 0 10px rgba(0, 255, 255, 0.2);
  }
}

.circuit-element {
  border: 1px solid var(--glow-blue);
  animation: circuitPulse 2s ease-in-out infinite;
}

.circuit-element:nth-child(odd) {
  animation-delay: 0.5s;
}

/* 频谱分析动画 */
@keyframes spectrumAnalysis {
  0% {
    height: 20%;
    background: linear-gradient(to top, var(--glow-blue), transparent);
  }
  25% {
    height: 60%;
    background: linear-gradient(to top, var(--glow-blue), var(--accent-red));
  }
  50% {
    height: 80%;
    background: linear-gradient(to top, var(--accent-red), var(--glow-blue));
  }
  75% {
    height: 40%;
    background: linear-gradient(to top, var(--glow-blue), transparent);
  }
  100% {
    height: 20%;
    background: linear-gradient(to top, var(--glow-blue), transparent);
  }
}

.spectrum-analyzer {
  display: flex;
  align-items: end;
  height: 100px;
  gap: 2px;
  padding: 10px;
}

.spectrum-bar {
  flex: 1;
  min-width: 4px;
  border-radius: 2px;
  animation: spectrumAnalysis 1.5s ease-in-out infinite;
}

.spectrum-bar:nth-child(1) { animation-delay: 0s; }
.spectrum-bar:nth-child(2) { animation-delay: 0.1s; }
.spectrum-bar:nth-child(3) { animation-delay: 0.2s; }
.spectrum-bar:nth-child(4) { animation-delay: 0.3s; }
.spectrum-bar:nth-child(5) { animation-delay: 0.4s; }
.spectrum-bar:nth-child(6) { animation-delay: 0.5s; }
.spectrum-bar:nth-child(7) { animation-delay: 0.6s; }
.spectrum-bar:nth-child(8) { animation-delay: 0.7s; }

/* HUD界面动画 */
@keyframes hudScanline {
  0% {
    top: 0%;
    opacity: 1;
  }
  100% {
    top: 100%;
    opacity: 0;
  }
}

.hud-display {
  position: relative;
  border: 2px solid var(--glow-blue);
  background: rgba(0, 255, 255, 0.02);
  overflow: hidden;
}

.hud-display::before {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--glow-blue), transparent);
  animation: hudScanline 3s linear infinite;
}

/* 全息投影效果 */
@keyframes hologramFlicker {
  0%, 100% {
    opacity: 1;
    filter: brightness(1);
  }
  25% {
    opacity: 0.9;
    filter: brightness(1.2);
  }
  50% {
    opacity: 0.95;
    filter: brightness(0.8);
  }
  75% {
    opacity: 0.92;
    filter: brightness(1.1);
  }
}

.hologram {
  animation: hologramFlicker 4s ease-in-out infinite;
  background: linear-gradient(
    45deg,
    rgba(0, 255, 255, 0.1),
    rgba(0, 255, 255, 0.05),
    rgba(0, 255, 255, 0.1)
  );
  border: 1px solid rgba(0, 255, 255, 0.3);
  box-shadow: 
    inset 0 0 20px rgba(0, 255, 255, 0.1),
    0 0 20px rgba(0, 255, 255, 0.1);
}

/* 进度条动画 */
@keyframes progressLoad {
  0% {
    width: 0%;
  }
  100% {
    width: 100%;
  }
}

.progress-bar {
  position: relative;
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--glow-blue), var(--accent-red));
  border-radius: 2px;
  animation: progressLoad 3s ease-out infinite;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
}

/* 矩阵数字雨效果 */
@keyframes matrixRain {
  0% {
    transform: translateY(-100%);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh);
    opacity: 0;
  }
}

.matrix-container {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.matrix-column {
  position: absolute;
  color: var(--glow-blue);
  font-family: 'Courier New', monospace;
  font-size: 14px;
  line-height: 20px;
  animation: matrixRain 10s linear infinite;
  opacity: 0.6;
}

/* 粒子效果 */
@keyframes particleFloat {
  0%, 100% {
    transform: translate(0, 0) scale(1);
    opacity: 0.3;
  }
  25% {
    transform: translate(10px, -15px) scale(1.2);
    opacity: 0.7;
  }
  50% {
    transform: translate(-5px, -25px) scale(0.8);
    opacity: 1;
  }
  75% {
    transform: translate(-15px, -10px) scale(1.1);
    opacity: 0.5;
  }
}

.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--glow-blue);
  border-radius: 50%;
  animation: particleFloat 8s ease-in-out infinite;
}

.particle:nth-child(odd) {
  background: var(--accent-red);
  animation-delay: -2s;
}

.particle:nth-child(3n) {
  animation-delay: -4s;
  animation-duration: 6s;
}

/* 扫描线效果 */
@keyframes scanLine {
  0% {
    transform: translateY(-100%);
  }
  100% {
    transform: translateY(100vh);
  }
}

.scan-line {
  position: fixed;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--glow-blue), transparent);
  animation: scanLine 4s linear infinite;
  z-index: 10;
  pointer-events: none;
}

/* 能量波动效果 */
@keyframes energyWave {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.5);
    opacity: 0.5;
  }
  100% {
    transform: scale(2);
    opacity: 0;
  }
}

.energy-wave {
  position: absolute;
  border: 2px solid var(--glow-blue);
  border-radius: 50%;
  animation: energyWave 2s ease-out infinite;
}

.energy-wave:nth-child(2) {
  animation-delay: 0.5s;
  border-color: var(--accent-red);
}

.energy-wave:nth-child(3) {
  animation-delay: 1s;
  border-color: var(--glow-blue);
}

/* 加载旋转器 */
@keyframes spinLoader {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.loader {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(255, 255, 255, 0.1);
  border-top: 3px solid var(--glow-blue);
  border-radius: 50%;
  animation: spinLoader 1s linear infinite;
}

/* 文字打字机效果 */
@keyframes typewriter {
  from {
    width: 0;
  }
  to {
    width: 100%;
  }
}

.typewriter {
  overflow: hidden;
  white-space: nowrap;
  animation: typewriter 3s steps(30, end) forwards;
}

/* 按钮悬停效果 */
@keyframes buttonGlow {
  0%, 100% {
    box-shadow: 0 0 5px rgba(0, 255, 255, 0.3);
  }
  50% {
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.8), 0 0 30px rgba(0, 255, 255, 0.4);
  }
}

.btn-glow:hover {
  animation: buttonGlow 1.5s ease-in-out infinite;
}

/* 响应式动画性能优化 */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* GPU加速优化 */
.gpu-accelerated {
  transform: translateZ(0);
  will-change: transform, opacity;
}

/* 视觉效果组合类 */
.military-ui {
  border: 1px solid var(--glow-blue);
  background: rgba(0, 255, 255, 0.05);
  box-shadow: 
    inset 0 0 10px rgba(0, 255, 255, 0.1),
    0 0 10px rgba(0, 255, 255, 0.2);
}

.military-ui::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glow-blue), transparent);
}

.military-ui::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glow-blue), transparent);
} 