/* animations.css — 关键帧 / 滚动进场 / 减少动效 */

/* 极光光斑 */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  pointer-events: none;
}
.blob {
  position: absolute;
  width: 42vw;
  height: 42vw;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.5;
  mix-blend-mode: screen;
}
.blob-1 { top: -10%; left: -5%; background: #7c3aed; animation: drift1 18s ease-in-out infinite; }
.blob-2 { top: 30%; right: -10%; background: #06b6d4; animation: drift2 22s ease-in-out infinite; }
.blob-3 { bottom: -15%; left: 30%; background: #db2777; animation: drift3 26s ease-in-out infinite; }

@keyframes drift1 { 50% { transform: translate(18vw, 12vh) scale(1.15); } }
@keyframes drift2 { 50% { transform: translate(-14vw, 10vh) scale(0.9); } }
@keyframes drift3 { 50% { transform: translate(10vw, -12vh) scale(1.1); } }

/* 渐变文字流动 */
.hero__title .grad,
.section-head .grad,
.footer__brand {
  animation: shimmer 8s linear infinite;
}
@keyframes shimmer { to { background-position: 200% center; } }

/* 在线状态呼吸点 */
.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  70% { box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); }
  100% { box-shadow: 0 0 0 0 rgba(52, 211, 153, 0); }
}

/* 滚动进场(仅在 JS 可用时先隐藏,避免关闭 JS 后内容消失) */
.reveal { transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }
.js .reveal { opacity: 0; transform: translateY(28px); }
.reveal.is-visible { opacity: 1; transform: none; }
.js .card { opacity: 0; }
.card.is-visible { opacity: 1; }

/* 尊重"减少动效"偏好 */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
  .js .reveal,
  .js .card { opacity: 1; transform: none; }
}
