/* ============================================================
   ANIMATIONS STYLESHEET — rwzf-bj.com
   ============================================================ */

/* --- Keyframes --- */
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.6); }
}

@keyframes bounce-scroll {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(10px); }
}

@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-16px); }
}

@keyframes glow-pulse {
  0%, 100% { box-shadow: 0 0 20px rgba(0, 102, 204, 0.3); }
  50% { box-shadow: 0 0 40px rgba(0, 153, 255, 0.6), 0 0 80px rgba(0, 102, 204, 0.2); }
}

@keyframes shimmer {
  0% { background-position: -1000px 0; }
  100% { background-position: 1000px 0; }
}

@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes count-up {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scan-line {
  0% { transform: translateY(-100%); }
  100% { transform: translateY(100vh); }
}

@keyframes rotate-ring {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes rotate-ring-rev {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

@keyframes particle-rise {
  0% { transform: translateY(0) scale(1); opacity: 0.6; }
  100% { transform: translateY(-120px) scale(0); opacity: 0; }
}

@keyframes gradient-x {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

@keyframes border-glow {
  0%, 100% { border-color: rgba(0, 102, 204, 0.2); }
  50% { border-color: rgba(0, 153, 255, 0.6); }
}

@keyframes typing-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@keyframes slide-up-fade {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes draw-line {
  from { stroke-dashoffset: 1000; }
  to { stroke-dashoffset: 0; }
}

/* --- Hero Animations --- */
.hero-eyebrow { animation: fade-in-up 0.8s ease forwards; }
.hero-title { animation: fade-in-up 0.9s 0.15s ease both; }
.hero-desc { animation: fade-in-up 0.9s 0.3s ease both; }
.hero-actions { animation: fade-in-up 0.9s 0.45s ease both; }

/* Animated gradient text */
.gradient-text {
  background: linear-gradient(90deg, #0099FF, #00CCFF, #0066CC, #0099FF);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-x 4s ease infinite;
}

/* Glowing elements */
.glow-blue { animation: glow-pulse 3s ease-in-out infinite; }
.float-anim { animation: float 4s ease-in-out infinite; }

/* Scan line overlay */
.scan-overlay {
  position: absolute; inset: 0; pointer-events: none; z-index: 1; overflow: hidden;
}
.scan-overlay::after {
  content: ''; position: absolute; width: 100%; height: 2px;
  background: linear-gradient(90deg, transparent, rgba(0

, 153, 255, 0.15), transparent);
  animation: scan-line 6s linear infinite;
  top: 0; left: 0;
}

/* Particle container */
.particles {
  position: absolute; inset: 0; pointer-events: none; overflow: hidden;
}
.particle {
  position: absolute; border-radius: 50%;
  background: rgba(0, 153, 255, 0.5);
  animation: particle-rise linear infinite;
}

/* Circle decorations */
.deco-ring {
  position: absolute; border-radius: 50%;
  border: 1px solid rgba(0, 102, 204, 0.15);
  pointer-events: none;
}
.deco-ring.spin { animation: rotate-ring 30s linear infinite; }
.deco-ring.spin-rev { animation: rotate-ring-rev 20s linear infinite; }

/* Number counter animation */
.counter-value { display: inline-block; transition: all 0.3s; }

/* Shimmer loading effect */
.shimmer-bg {
  background: linear-gradient(90deg, rgba(255,255,255,0.03) 25%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0.03) 75%);
  background-size: 1000px 100%;
  animation: shimmer 2s infinite linear;
}

/* Stagger children reveal */
.stagger-parent > * { opacity: 0; transform: translateY(30px); transition: opacity 0.6s ease, transform 0.6s ease; }
.stagger-parent.visible > *:nth-child(1) { transition-delay: 0.05s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(2) { transition-delay: 0.15s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(3) { transition-delay: 0.25s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(4) { transition-delay: 0.35s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(5) { transition-delay: 0.45s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(6) { transition-delay: 0.55s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(7) { transition-delay: 0.65s; opacity: 1; transform: translateY(0); }
.stagger-parent.visible > *:nth-child(8) { transition-delay: 0.75s; opacity: 1; transform: translateY(0); }

/* Horizontal scroll marquee */
.marquee-track {
  overflow: hidden; position: relative;
  padding: 20px 0; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee-inner {
  display: flex; gap: 32px; align-items: center;
  width: max-content; animation: marquee-scroll 30s linear infinite;
}
.marquee-inner:hover { animation-play-state: paused; }

@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.marquee-item {
  flex-shrink: 0; padding: 10px 24px; border-radius: 8px;
  background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.07);
  font-size: 0.8rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase;
  color: var(--text-muted); white-space: nowrap;
}

/* Animated svg path draw */
.draw-path {
  stroke-dasharray: 1000;
  stroke-dashoffset: 1000;
  transition: stroke-dashoffset 2s ease;
}
.draw-path.drawn { stroke-dashoffset: 0; }

/* Page transition */
.page-fade { animation: fade-in-up 0.5s ease forwards; }

/* Hover card lift with glow */
.hover-lift {
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
}
.hover-lift:hover {
  transform: translateY(-8px);
  box-shadow: 0 24px 80px rgba(0, 102, 204, 0.2);
}

/* Typed cursor */
.typed-cursor {
  display: inline-block; width: 3px; height: 1em;
  background: var(--accent-blue-light); vertical-align: middle;
  animation: typing-cursor 1s step-end infinite;
  margin-left: 4px;
}

/* Blob animated background */
.blob {
  position: absolute; border-radius: 50%;
  filter: blur(80px); opacity: 0.08;
  pointer-events: none;
  animation: float 8s ease-in-out infinite;
}
.blob-1 { width: 400px; height: 400px; background: var(--accent-blue); top: -100px; right: -100px; animation-delay: 0s; }
.blob-2 { width: 300px; height: 300px; background: var(--accent-blue-light); bottom: 0; left: -80px; animation-delay: -3s; }
.blob-3 { width: 250px; height: 250px; background: var(--accent-green); top: 50%; right: 20%; animation-delay: -6s; }

/* Timeline for culture/news */
.timeline { position: relative; padding-left: 48px; }
.timeline::before { content: ''; position: absolute; left: 16px; top: 0; bottom: 0; width: 1px; background: var(--border-color); }
.timeline-item { position: relative; margin-bottom: 48px; }
.timeline-dot {
  position: absolute; left: -40px; top: 4px;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--accent-blue); border: 3px solid var(--bg-primary);
  box-shadow: 0 0 12px rgba(0, 102, 204, 0.5);
}
.timeline-date { font-size: 0.75rem; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; color: var(--text-muted); margin-bottom: 8px; }
.timeline-item h4 { margin-bottom: 8px; }
.timeline-item p { font-size: 0.875rem; }

/* Interactive map placeholder */
.map-placeholder {
  aspect-ratio: 16/7; background: var(--bg-card);
  border: 1px solid var(--border-color); border-radius: var(--radius);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  overflow: hidden; position: relative;
}
.map-grid-overlay {
  position: absolute; inset: 0;
  background-image: 
    linear-gradient(rgba(0, 102, 204, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 102, 204, 0.06) 1px, transparent 1px);
  background-size: 40px 40px;
}
.map-pin { animation: float 3s ease-in-out infinite; }

/* Loading spinner */
@keyframes spin {
  to { transform: rotate(360deg); }
}
.spinner {
  width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid rgba(0, 102, 204, 0.2);
  border-top-color: var(--accent-blue);
  animation: spin 0.8s linear infinite;
}

/* Success checkmark */
@keyframes check-draw {
  from { stroke-dashoffset: 30; }
  to { stroke-dashoffset: 0; }
}
.success-check {
  stroke-dasharray: 30; stroke-dashoffset: 30;
  animation: check-draw 0.5s ease forwards 0.3s;
}

/* Pulse rings */
@keyframes pulse-ring {
  0% { transform: scale(0.9); opacity: 0.8; }
  100% { transform: scale(1.5); opacity: 0; }
}
.pulse-ring {
  position: absolute; inset: -8px; border-radius: 50%;
  border: 2px solid var(--accent-blue);
  animation: pulse-ring 2s ease-out infinite;
}
