/* ANIMATION SYSTEM — LumenForge Studios */

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

@keyframes float-x {
  0%, 100% { transform: translateX(0px); }
  50% { transform: translateX(10px); }
}

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

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

@keyframes glow-breathe {
  0%, 100% { box-shadow: 0 0 20px rgba(124, 58, 237, 0.2); }
  50% { box-shadow: 0 0 50px rgba(124, 58, 237, 0.5), 0 0 80px rgba(34, 211, 238, 0.15); }
}

@keyframes glow-pulse-cyan {
  0%, 100% { box-shadow: 0 0 15px rgba(34, 211, 238, 0.2); }
  50% { box-shadow: 0 0 40px rgba(34, 211, 238, 0.5); }
}

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

@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slide-in-right {
  from { opacity: 0; transform: translateX(40px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes slide-in-left {
  from { opacity: 0; transform: translateX(-40px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes scale-in {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

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

@keyframes orbit {
  from { transform: rotate(0deg) translateX(80px) rotate(0deg); }
  to { transform: rotate(360deg) translateX(80px) rotate(-360deg); }
}

@keyframes orbit-reverse {
  from { transform: rotate(0deg) translateX(120px) rotate(0deg); }
  to { transform: rotate(-360deg) translateX(120px) rotate(360deg); }
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}

@keyframes border-flow {
  0% { border-color: rgba(124, 58, 237, 0.3); }
  50% { border-color: rgba(34, 211, 238, 0.5); }
  100% { border-color: rgba(124, 58, 237, 0.3); }
}

@keyframes number-count {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes typewriter {
  from { width: 0; }
  to { width: 100%; }
}

@keyframes blink-cursor {
  0%, 100% { border-right-color: var(--accent-cyan); }
  50% { border-right-color: transparent; }
}

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

/* Utility animation classes */
.anim-float {
  animation: float-y 6s ease-in-out infinite;
}

.anim-float-slow {
  animation: float-y 9s ease-in-out infinite;
}

.anim-glow-breathe {
  animation: glow-breathe 3s ease-in-out infinite;
}

.anim-spin-slow {
  animation: spin-slow 20s linear infinite;
}

.anim-spin-rev {
  animation: spin-slow-rev 30s linear infinite;
}

.anim-fade-in-up {
  animation: fade-in-up 0.7s ease forwards;
}

.anim-fade-in {
  animation: fade-in 0.6s ease forwards;
}

.anim-scale-in {
  animation: scale-in 0.6s ease forwards;
}

.anim-slide-right {
  animation: slide-in-right 0.7s ease forwards;
}

.anim-slide-left {
  animation: slide-in-left 0.7s ease forwards;
}

/* Gradient animated text */
.anim-gradient-text {
  background: linear-gradient(135deg, var(--accent-violet), var(--accent-cyan), var(--accent-gold), var(--accent-violet));
  background-size: 300% 300%;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: gradient-shift 5s ease infinite;
}

/* Loading shimmer */
.anim-shimmer {
  position: relative;
  overflow: hidden;
}

.anim-shimmer::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.05), transparent);
  animation: shimmer 2.5s ease-in-out infinite;
}

/* Stagger delays */
.stagger-1 { animation-delay: 0.05s; }
.stagger-2 { animation-delay: 0.1s; }
.stagger-3 { animation-delay: 0.15s; }
.stagger-4 { animation-delay: 0.2s; }
.stagger-5 { animation-delay: 0.25s; }
.stagger-6 { animation-delay: 0.3s; }

/* HERO VISUAL */
.hero-visual {
  position: relative;
  width: 100%;
  max-width: 520px;
  aspect-ratio: 1;
  margin: 0 auto;
}

.hero-visual-core {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 160px;
  height: 160px;
  border-radius: 40px;
  background: var(--gradient-brand);
  box-shadow: 0 0 80px rgba(124, 58, 237, 0.4), 0 0 160px rgba(34, 211, 238, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3.5rem;
  animation: glow-breathe 3s ease-in-out infinite;
  z-index: 2;
}

.hero-visual-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  border: 1.5px dashed rgba(124, 58, 237, 0.25);
  transform: translate(-50%, -50%);
}

.hero-visual-ring-1 {
  width: 260px;
  height: 260px;
  animation: spin-slow 25s linear infinite;
}

.hero-visual-ring-2 {
  width: 370px;
  height: 370px;
  animation: spin-slow-rev 35s linear infinite;
  border-color: rgba(34, 211, 238, 0.15);
}

.hero-visual-ring-3 {
  width: 480px;
  height: 480px;
  animation: spin-slow 50s linear infinite;
  border-color: rgba(251, 191, 36, 0.08);
}

.hero-visual-node {
  position: absolute;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent-cyan);
  box-shadow: 0 0 16px var(--accent-cyan);
  top: 50%;
  left: 50%;
  margin: -6px 0 0 -6px;
}

.hero-visual-node-gold {
  background: var(--accent-gold);
  box-shadow: 0 0 16px var(--accent-gold);
}

.hero-visual-node-violet {
  background: var(--accent-violet);
  box-shadow: 0 0 16px var(--accent-violet);
}

.orbit-node-1 {
  animation: orbit 25s linear infinite;
}

.orbit-node-2 {
  animation: orbit-reverse 35s linear infinite;
}

.orbit-node-3 {
  animation: orbit 50s linear infinite;
  margin: -5px 0 0 -5px;
  width: 10px;
  height: 10px;
}

/* Floating cards on hero */
.hero-float-card {
  position: absolute;
  background: rgba(11, 16, 32, 0.85);
  border: 1px solid var(--border-subtle);
  border-radius: 14px;
  padding: 12px 16px;
  backdrop-filter: blur(20px);
  font-size: 0.8rem;
  white-space: nowrap;
  z-index: 5;
}

.hero-float-card-1 {
  top: 15%;
  left: 0;
  animation: float-y 7s ease-in-out infinite;
}

.hero-float-card-2 {
  bottom: 20%;
  right: 0;
  animation: float-y 9s ease-in-out infinite 1s;
}

.hero-float-card-3 {
  top: 55%;
  left: -5%;
  animation: float-y 8s ease-in-out infinite 0.5s;
}

.hero-float-card .card-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  margin-right: 6px;
  vertical-align: middle;
}

.hero-float-card .card-value {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-primary);
}

.hero-float-card .card-label {
  color: var(--text-muted);
  font-size: 0.75rem;
}

/* PROGRESS BAR */
.progress-bar-wrap {
  height: 4px;
  background: var(--border-subtle);
  border-radius: 2px;
  overflow: hidden;
  margin-top: 8px;
}

.progress-bar-fill {
  height: 100%;
  background: var(--gradient-brand);
  border-radius: 2px;
  transform-origin: left;
  transform: scaleX(0);
  transition: transform 1.2s cubic-bezier(0.4, 0, 0.2, 1) 0.3s;
}

.progress-bar-fill.animated {
  transform: scaleX(1);
}

/* Step connector */
.step-connector {
  height: 40px;
  width: 1px;
  background: linear-gradient(to bottom, var(--accent-violet), transparent);
  margin: 0 auto;
  opacity: 0.4;
}

/* SECTION BACKGROUND EFFECTS */
.section-glow-left {
  position: absolute;
  top: 50%;
  left: -200px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.08) 0%, transparent 70%);
  pointer-events: none;
  transform: translateY(-50%);
}

.section-glow-right {
  position: absolute;
  top: 50%;
  right: -200px;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(34, 211, 238, 0.06) 0%, transparent 70%);
  pointer-events: none;
  transform: translateY(-50%);
}

/* Animated border card */
.anim-border-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.anim-border-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--accent-violet), var(--accent-cyan), var(--accent-violet));
  background-size: 300% 300%;
  animation: gradient-shift 4s ease infinite;
  z-index: -1;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.anim-border-card:hover::before {
  opacity: 1;
}