/* =============================================
   ANIMATIONS & MICRO-INTERACTIONS
   ============================================= */

/* ─── PAGE LOAD ENTRANCE ─────────────────────*/
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(28px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-24px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.94);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ─── FLOATING ANIMATION ─────────────────────
   Profile card and featured panel gentle float.
   ──────────────────────────────────────────── */
@keyframes float {
  0%, 100% { transform: translateY(0px); }
  50%       { transform: translateY(-6px); }
}

.animate-float {
  animation: float 5s ease-in-out infinite;
}

.animate-float:hover {
  animation-play-state: paused;
}

/* ─── BACKGROUND SHIMMER ─────────────────────
   Subtle light movement on glass surfaces.
   ──────────────────────────────────────────── */
@keyframes shimmer {
  0%   { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}

.glass-shimmer::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(255, 255, 255, 0.025) 50%,
    transparent 100%
  );
  background-size: 400px 100%;
  animation: shimmer 6s ease-in-out infinite;
  border-radius: inherit;
  pointer-events: none;
}

/* ─── ENTRANCE ANIMATIONS ────────────────────*/
.animate-in {
  opacity: 0;
  transform: translate3d(0, 22px, 0);
  transition:
    opacity 0.65s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.animate-in.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
  will-change: auto;
}

.animate-in-delay-1 { transition-delay: 0.08s; }
.animate-in-delay-2 { transition-delay: 0.16s; }
.animate-in-delay-3 { transition-delay: 0.24s; }
.animate-in-delay-4 { transition-delay: 0.32s; }
.animate-in-delay-5 { transition-delay: 0.40s; }
.animate-in-delay-6 { transition-delay: 0.48s; }

/* ─── COUNTER ANIMATION ──────────────────────*/
.count-up {
  display: inline-block;
  will-change: transform;
}

/* ─── NAV ENTRANCE ───────────────────────────*/
.site-nav {
  animation: slideInLeft 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.15s both;
  will-change: transform, opacity;
}

/* Subtle parallax hint on mouse move */
.site-bg__photo {
  transition: transform 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: transform;
  transform: scale(1.05) translate3d(0, 0, 0);
}


/* ─── TYPING CURSOR ──────────────────────────*/
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

.cursor-blink {
  display: inline-block;
  width: 3px;
  height: 1.1em;
  background: var(--accent);
  margin-left: 2px;
  vertical-align: text-bottom;
  border-radius: 2px;
  animation: blink 1.1s step-end infinite;
}

/* ─── SCROLL INDICATOR ───────────────────────*/
@keyframes scrollBounce {
  0%, 100% { transform: translateY(0); opacity: 0.7; }
  50%       { transform: translateY(4px); opacity: 1; }
}

.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-tertiary);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-top: var(--space-10);
}

.scroll-indicator svg {
  animation: scrollBounce 1.8s ease-in-out infinite;
}

/* ─── ACTIVE NAV TRANSITION ──────────────────*/
.nav-item {
  transition:
    color       var(--duration-normal) var(--ease-out),
    background  var(--duration-normal) var(--ease-out),
    border-color var(--duration-normal) var(--ease-out),
    box-shadow  var(--duration-normal) var(--ease-out),
    transform   var(--duration-fast)   var(--ease-spring);
}

/* ─── HERO TITLE GLOW ────────────────────────*/
.hero-title {
  text-shadow:
    0 0 60px rgba(255, 255, 255, 0.04),
    0 2px 4px rgba(0, 0, 0, 0.40);
}

/* ─── GLASS AMBIENT ──────────────────────────
   The orange ambient light peeking through.
   ──────────────────────────────────────────── */
.glass-primary {
  position: relative;
}

/* Subtle warm ambient at bottom-right of major panels */
.glass-ambient::after {
  content: '';
  position: absolute;
  bottom: -40px;
  right: -40px;
  width: 200px;
  height: 200px;
  border-radius: var(--radius-full);
  background: radial-gradient(
    circle,
    rgba(232, 130, 58, 0.06) 0%,
    transparent 70%
  );
  pointer-events: none;
  z-index: -1;
}

/* ─── SECTION TRANSITION ─────────────────────*/
.section {
  position: relative;
}

/* ─── LOADING SKELETON ───────────────────────*/
@keyframes skeleton-shimmer {
  0%   { background-position: -400px 0; }
  100% { background-position: 400px 0; }
}

.skeleton {
  background: linear-gradient(
    90deg,
    rgba(255,255,255,0.04) 0%,
    rgba(255,255,255,0.08) 50%,
    rgba(255,255,255,0.04) 100%
  );
  background-size: 400px 100%;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
  border-radius: var(--radius-md);
}
