/* --- Loader 基础设置（只影响加载层） --- */
body.is-loading {
  overflow: hidden; /* 加载时禁止滚动 */
}

.font-orbitron { font-family: 'Orbitron', sans-serif; }

/* --- 1. Loader 容器 (全屏居中) --- */
#loader {
  position: fixed;
  inset: 0;
  background-color: #0a0a0a;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.8s ease-out, visibility 0.8s ease-out;
}

#loader.hidden {
  opacity: 0;
  visibility: hidden;
}

/* --- 2. 银灰色发光特效 (用于上下小字) --- */
.text-silver-glow {
  color: #e2e8f0; /* Slate-200 */
  text-shadow: 0 0 5px rgba(226, 232, 240, 0.3), 0 0 10px rgba(148, 163, 184, 0.2);
}

/* --- 3. 打字机光标闪烁 --- */
.typing-cursor::after {
  content: '_';
  animation: blink 1s step-start infinite;
  color: #cbd5e1;
  margin-left: 2px;
}
@keyframes blink { 50% { opacity: 0; } }

/* --- 4. 故障 LOGO 特效 --- */
.neon-text-cyan {
  text-shadow: 0 0 5px rgba(0, 255, 255, 0.8), 0 0 10px rgba(0, 255, 255, 0.6);
}

#loader-text {
  position: relative;
  animation: glitch 3s infinite;
}

/* 故障红蓝偏移层 */
#loader-text::before, #loader-text::after {
  content: attr(data-text);
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: #0a0a0a;
  overflow: hidden;
}
#loader-text::before {
  left: 2px; text-shadow: -2px 0 #ff0080;
  animation: glitch-top 2s linear infinite reverse;
}
#loader-text::after {
  left: -2px; text-shadow: -2px 0 #00ffff;
  animation: glitch-bottom 3s linear infinite reverse;
}

/* 故障动画关键帧 */
@keyframes glitch {
  2%, 64% { transform: translate(2px,0) skew(0deg); }
  4%, 60% { transform: translate(-2px,0) skew(0deg); }
  62% { transform: translate(0,0) skew(5deg); }
}
@keyframes glitch-top {
  0%, 100% { clip-path: inset(0 0 55% 0); }
  50% { clip-path: inset(80% 0 5% 0); }
}
@keyframes glitch-bottom {
  0%, 100% { clip-path: inset(50% 0 0 0); }
  50% { clip-path: inset(5% 0 20% 0); }
}

/* --- 5. 扫描线特效 --- */
.scanline {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 4px;
  background: rgba(0, 255, 255, 0.7);
  box-shadow: 0 0 15px #00ffff;
  animation: scan 1.5s linear infinite;
  opacity: 0.5;
}
@keyframes scan {
  0% { top: -10%; opacity: 0; }
  50% { opacity: 1; }
  100% { top: 110%; opacity: 0; }
}