/* ============================================================
   SCD 西迪自动化 — animations.css  动效 / 滚动揭示
   ============================================================ */

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 198, 255, .7); }
  70% { box-shadow: 0 0 0 12px rgba(0, 198, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 198, 255, 0); }
}
@keyframes scrolldot { 0% { top: 7px; opacity: 1; } 80% { top: 20px; opacity: 0; } 100% { top: 7px; opacity: 0; } }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }

/* 滚动揭示 */
.reveal { opacity: 0; transform: translateY(36px); transition: opacity .8s var(--ease), transform .8s var(--ease); will-change: transform, opacity; }
.reveal.in { opacity: 1; transform: none; }
.reveal.from-left { transform: translateX(-44px); }
.reveal.from-right { transform: translateX(44px); }
.reveal.from-left.in, .reveal.from-right.in { transform: none; }
.reveal.zoom { transform: scale(.92); }
.reveal.zoom.in { transform: scale(1); }

/* 子元素逐个延迟 */
.stagger > * { opacity: 0; transform: translateY(30px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.stagger.in > * { opacity: 1; transform: none; }
.stagger.in > *:nth-child(1) { transition-delay: .05s; }
.stagger.in > *:nth-child(2) { transition-delay: .14s; }
.stagger.in > *:nth-child(3) { transition-delay: .23s; }
.stagger.in > *:nth-child(4) { transition-delay: .32s; }
.stagger.in > *:nth-child(5) { transition-delay: .41s; }
.stagger.in > *:nth-child(6) { transition-delay: .50s; }
.stagger.in > *:nth-child(7) { transition-delay: .59s; }
.stagger.in > *:nth-child(8) { transition-delay: .68s; }

/* hero 文案进入 */
.hero-copy .tag, .hero-copy h1, .hero-copy .sub, .hero-actions { animation: heroIn .9s var(--ease) both; }
.hero-copy h1 { animation-delay: .12s; }
.hero-copy .sub { animation-delay: .26s; }
.hero-actions { animation-delay: .4s; }
@keyframes heroIn { from { opacity: 0; transform: translateY(28px); } to { opacity: 1; transform: none; } }

/* 顶部进度条 */
.scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; background: var(--grad); z-index: 1100; transition: width .1s linear; }

/* 回到顶部 */
.to-top {
  position: fixed; right: 26px; bottom: 26px; width: 48px; height: 48px; border-radius: 50%; border: 0;
  background: var(--grad); color: #fff; cursor: pointer; display: grid; place-items: center; z-index: 900;
  box-shadow: var(--shadow-md); opacity: 0; transform: translateY(20px) scale(.8); pointer-events: none;
  transition: opacity .35s var(--ease), transform .35s var(--ease);
}
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { transform: translateY(-4px); }

/* 浮动装饰 */
.floaty { animation: floaty 6s ease-in-out infinite; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .reveal, .stagger > * { opacity: 1 !important; transform: none !important; }
}
