/* 5LUCK · 全息赛博太极星盘首页 —— 自定义动画与星盘样式 */

:root {
  --void: #0B0F19;
  --cyan: #22d3ee;
  --violet: #a855f7;
  --gold: #fbbf24;
  --threshold-danger: 40%;
  --threshold-balance: 60%;
  --threshold-overflow: 80%;
}

@keyframes spin-slow {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@keyframes spin-slow-reverse {
  from { transform: rotate(360deg); }
  to { transform: rotate(0deg); }
}
@keyframes hub-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
@keyframes core-pulse {
  0%, 100% { box-shadow: 0 0 40px 8px rgba(34, 211, 238, 0.35), 0 0 90px 20px rgba(168, 85, 247, 0.18); }
  50% { box-shadow: 0 0 60px 16px rgba(34, 211, 238, 0.55), 0 0 120px 30px rgba(168, 85, 247, 0.30); }
}
@keyframes starfield-drift {
  from { background-position: 0 0; }
  to { background-position: 1000px 500px; }
}
@keyframes taichi-breathe {
  0%, 100% { opacity: 0.72; transform: scale(1); }
  50% { opacity: 0.92; transform: scale(1.02); }
}
@keyframes star-twinkle {
  0%, 100% { opacity: 0.25; }
  50% { opacity: 0.95; }
}

.brand-mark {
  font-family: Orbitron, "Noto Serif SC", sans-serif;
  text-shadow: 0 0 24px rgba(34, 211, 238, 0.35);
}

.taichi-stage {
  filter: drop-shadow(0 0 28px rgba(34, 211, 238, 0.12));
}
.taichi-ring-outer { animation: spin-slow 26s linear infinite; }
.taichi-ring-inner { animation: spin-slow-reverse 18s linear infinite; }
.taichi-glyph { animation: taichi-breathe 8s ease-in-out infinite; }
.energy-ray {
  position: absolute;
  inset: 10%;
  border-radius: 50%;
  border: 1px solid rgba(34, 211, 238, 0.08);
  pointer-events: none;
  animation: spin-slow 40s linear infinite;
}

.core-glow { animation: core-pulse 4.5s ease-in-out infinite; }

.fortune-node {
  position: absolute;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 700;
  color: #ecfeff;
  background: rgba(11, 15, 25, 0.85);
  border: 1px solid rgba(34, 211, 238, 0.45);
  box-shadow: 0 0 12px rgba(34, 211, 238, 0.25);
  z-index: 12;
  pointer-events: none;
  font-family: Orbitron, sans-serif;
}

.starfield {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}
.starfield span {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.75);
  box-shadow: 0 0 6px rgba(34, 211, 238, 0.45);
  animation: star-twinkle 3.2s ease-in-out infinite;
}

#cosmos-stage {
  background-image:
    radial-gradient(1px 1px at 20% 30%, rgba(34,211,238,0.6) 50%, transparent 100%),
    radial-gradient(1px 1px at 70% 60%, rgba(168,85,247,0.6) 50%, transparent 100%),
    radial-gradient(1px 1px at 40% 80%, rgba(220,38,38,0.5) 50%, transparent 100%),
    radial-gradient(1px 1px at 85% 15%, rgba(34,211,238,0.5) 50%, transparent 100%),
    radial-gradient(1px 1px at 10% 90%, rgba(168,85,247,0.5) 50%, transparent 100%),
    radial-gradient(2px 2px at 55% 40%, rgba(255,255,255,0.4) 50%, transparent 100%);
  background-size: 1000px 500px;
  animation: starfield-drift 90s linear infinite;
}

.core-locate-btn {
  min-width: 42px;
  border-radius: 8px;
  border: 1px solid rgba(168, 85, 247, 0.45);
  background: rgba(168, 85, 247, 0.12);
  color: #e9d5ff;
  font-size: 0.85rem;
  cursor: pointer;
}

/* 进度条 40 / 60 / 80 阈值刻度 */
.holo-bar-track {
  position: relative;
  overflow: visible !important;
}
.holo-threshold-marks {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.holo-threshold-marks::before,
.holo-threshold-marks::after,
.holo-bar-track::after {
  content: "";
  position: absolute;
  top: -2px;
  bottom: -2px;
  width: 1px;
  background: rgba(251, 191, 36, 0.55);
  box-shadow: 0 0 4px rgba(251, 191, 36, 0.4);
}
.holo-threshold-marks::before { left: var(--threshold-danger); }
.holo-threshold-marks::after { left: var(--threshold-balance); }
.holo-bar-track::after { left: var(--threshold-overflow); }

.hub-node { animation: hub-float 6s ease-in-out infinite; }
.hub-node[data-delay="1"] { animation-delay: 0.4s; }
.hub-node[data-delay="2"] { animation-delay: 1.1s; }
.hub-node[data-delay="3"] { animation-delay: 1.8s; }

.hub-link:hover .hub-orb {
  filter: brightness(1.3);
  transform: scale(1.08);
}

.rune-input {
  background: rgba(11, 15, 25, 0.6);
  border-bottom: 1px solid rgba(34, 211, 238, 0.35);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.rune-input:focus {
  outline: none;
  border-color: rgba(34, 211, 238, 0.9);
  box-shadow: 0 4px 12px -6px rgba(34, 211, 238, 0.6);
}

@media (prefers-reduced-motion: reduce) {
  .taichi-ring-outer,
  .taichi-ring-inner,
  .hub-node,
  .core-glow,
  .taichi-glyph,
  .energy-ray,
  .starfield span,
  #cosmos-stage {
    animation: none !important;
  }
}

/* 八敬神能量殿 */
body.palace-red-alert #palace-red-flash {
  opacity: 0.22;
  background: radial-gradient(ellipse at center, rgba(220, 38, 38, 0.45), transparent 70%);
  animation: palace-alert-pulse 1.2s ease-in-out infinite;
}
@keyframes palace-alert-pulse {
  0%, 100% { opacity: 0.12; }
  50% { opacity: 0.28; }
}
.holo-bar-row.palace-low-pulse .holo-bar-fill {
  box-shadow: 0 0 12px rgba(239, 68, 68, 0.8);
  background: linear-gradient(90deg, #7f1d1d, #ef4444) !important;
  animation: low-bar-blink 1s ease-in-out infinite;
}
@keyframes low-bar-blink {
  0%, 100% { filter: brightness(1); }
  50% { filter: brightness(1.35); }
}
.seat-cat-btn,
.seat-preset-btn,
.ritual-btn {
  border-radius: 0.5rem;
  border: 1px solid rgba(34, 211, 238, 0.25);
  background: rgba(15, 23, 42, 0.9);
  color: #e2e8f0;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
}
.seat-cat-btn:hover,
.ritual-btn:hover,
.seat-preset-btn:hover {
  border-color: #22d3ee;
  color: #22d3ee;
}
#palace-canvas {
  touch-action: none;
}

/* guest chat collapsed — 收起后缩小占位，避免挡住枢纽点击 */
#guest-chat.guest-chat-collapsed #guest-chat-body {
  display: none;
}
#guest-chat.guest-chat-collapsed {
  width: auto;
  min-width: 0;
  max-width: min(220px, 70vw);
}

/* apex-build 20260720124420 */
