/* ==========================================================================
   Animations
   ========================================================================== */

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

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@keyframes scroll-hint-move {
  0% { transform: translateY(0); opacity: 1; }
  70% { opacity: 0.4; }
  100% { transform: translateY(14px); opacity: 0; }
}

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

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

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* stagger children within a grid/list once parent is visible */
.project-grid .reveal:nth-child(2) { transition-delay: 0.06s; }
.project-grid .reveal:nth-child(3) { transition-delay: 0.12s; }
.project-grid .reveal:nth-child(4) { transition-delay: 0.18s; }

.site-grid .reveal:nth-child(2) { transition-delay: 0.08s; }
.site-grid .reveal:nth-child(3) { transition-delay: 0.16s; }

.skills-grid .reveal:nth-child(2) { transition-delay: 0.06s; }
.skills-grid .reveal:nth-child(3) { transition-delay: 0.12s; }
.skills-grid .reveal:nth-child(4) { transition-delay: 0.18s; }

.achievement-grid .reveal:nth-child(2) { transition-delay: 0.06s; }
.achievement-grid .reveal:nth-child(3) { transition-delay: 0.12s; }
.achievement-grid .reveal:nth-child(4) { transition-delay: 0.18s; }

.service-grid .reveal:nth-child(2) { transition-delay: 0.06s; }
.service-grid .reveal:nth-child(3) { transition-delay: 0.12s; }
.service-grid .reveal:nth-child(4) { transition-delay: 0.18s; }
.service-grid .reveal:nth-child(5) { transition-delay: 0.24s; }
.service-grid .reveal:nth-child(6) { transition-delay: 0.3s; }

.contact-grid .reveal:nth-child(2) { transition-delay: 0.06s; }
.contact-grid .reveal:nth-child(3) { transition-delay: 0.12s; }
.contact-grid .reveal:nth-child(4) { transition-delay: 0.18s; }

/* ---------- Magnetic buttons ---------- */
.magnetic {
  will-change: transform;
  transition: transform 0.25s var(--ease), box-shadow var(--transition-fast), border-color var(--transition-fast);
}

/* ---------- Floating glow blobs ---------- */
.hero__glow--1 {
  animation: float-y 9s ease-in-out infinite;
}

.hero__glow--2 {
  animation: float-y 11s ease-in-out infinite reverse;
}

/* ---------- Achievement / service icon hover pulse ---------- */
.achievement-card:hover .achievement-card__icon {
  animation: float-y 1.4s ease-in-out infinite;
}
