/* ═══════════════════════════════════════════════════════════════
   LANDING.CSS — Motion + micro-interactions for the landing page.
   Borrows all design tokens, fonts, nav, .pill, .hero-tag, .btn-*
   from style.css. Nothing redeclared. Additive only.
   ═══════════════════════════════════════════════════════════════ */

/* ── REDUCED MOTION SAFETY ──
   Respect users who prefer less movement: kill transforms/animations. */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
}

/* ── SCROLL-REVEAL PRIMITIVE ──
   Elements tagged .reveal start hidden + shifted, then animate in
   when IntersectionObserver adds .is-visible. Direction + delay are
   modifier classes so any section can opt into a flavour. */
.reveal {
  opacity: 0;
  transform: translateY(34px);
  transition:
    opacity 0.8s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0) translateX(0);
}

/* directional variants */
.reveal.from-left  { transform: translateX(-44px); }
.reveal.from-right { transform: translateX(44px); }
.reveal.from-scale { transform: scale(0.94); }
.reveal.from-left.is-visible,
.reveal.from-right.is-visible { transform: translateX(0); }
.reveal.from-scale.is-visible { transform: scale(1); }

/* stagger delays */
.reveal.d-1 { transition-delay: 0.08s; }
.reveal.d-2 { transition-delay: 0.16s; }
.reveal.d-3 { transition-delay: 0.24s; }
.reveal.d-4 { transition-delay: 0.32s; }
.reveal.d-5 { transition-delay: 0.40s; }
.reveal.d-6 { transition-delay: 0.48s; }

/* ── HERO: LAYERED FLOATING ORBS ──
   Soft drifting glows behind the hero to add depth + atmosphere.
   Pure CSS, GPU-cheap, sits beneath content (z-index 0). */
.hero { position: relative; }

.hero-orbs {
  position: absolute;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}
.hero-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
}
.hero-orb.orb-1 {
  width: 360px; height: 360px;
  top: 8%; right: 6%;
  background: radial-gradient(circle, rgba(62,200,120,0.28), transparent 70%);
  animation: orbFloat1 16s ease-in-out infinite;
}
.hero-orb.orb-2 {
  width: 280px; height: 280px;
  bottom: 10%; left: 4%;
  background: radial-gradient(circle, rgba(45,158,95,0.22), transparent 70%);
  animation: orbFloat2 20s ease-in-out infinite;
}
.hero-orb.orb-3 {
  width: 200px; height: 200px;
  top: 45%; left: 48%;
  background: radial-gradient(circle, rgba(200,168,75,0.12), transparent 70%);
  animation: orbFloat3 24s ease-in-out infinite;
}

@keyframes orbFloat1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-30px, 40px) scale(1.08); }
}
@keyframes orbFloat2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(40px, -30px) scale(1.12); }
}
@keyframes orbFloat3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33%      { transform: translate(30px, 20px) scale(0.9); }
  66%      { transform: translate(-20px, -25px) scale(1.05); }
}

/* keep hero content above the orbs */
.hero-left, .hero-right { position: relative; z-index: 1; }

/* ── HERO NAME: shimmer sweep on the italic span ── */
.hero-name span {
  background: linear-gradient(
    100deg,
    var(--green-bright) 0%,
    var(--green-glow) 45%,
    var(--cream) 50%,
    var(--green-glow) 55%,
    var(--green-bright) 100%
  );
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: nameShimmer 6s linear infinite;
}
@keyframes nameShimmer {
  to { background-position: -220% center; }
}

/* ── AVAILABILITY: subtle breathing glow around the badge ── */
.availability {
  animation: availPulse 3.2s ease-in-out infinite;
}
@keyframes availPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(61,200,120,0.0); }
  50%      { box-shadow: 0 0 0 4px rgba(61,200,120,0.06); }
}

/* ── STACK PILLS: gentle lift + glow on hover (enhances base) ── */
.stack-card .pill,
.service-pills .pill {
  transition: border-color 0.2s, color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.stack-card .pill:hover,
.service-pills .pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
}

/* ── STAT NUMBERS: count-in pop when revealed ── */
.stat-number {
  display: inline-block;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.reveal.is-visible .stat-number {
  animation: statPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
@keyframes statPop {
  0%   { transform: scale(0.6); opacity: 0; }
  60%  { transform: scale(1.12); }
  100% { transform: scale(1); opacity: 1; }
}

/* ── PROJECT CARD: sheen sweep across on hover ── */
.project-card {
  position: relative;
  overflow: hidden;
}
.project-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: -120%;
  width: 70%;
  height: 100%;
  background: linear-gradient(
    100deg,
    transparent 0%,
    rgba(255,255,255,0.05) 50%,
    transparent 100%
  );
  transform: skewX(-18deg);
  transition: left 0.7s ease;
  pointer-events: none;
}
.project-card:hover::after { left: 130%; }

/* ── SERVICE CARDS: icon lift + accent line grow on hover ── */
.service-card {
  position: relative;
}
.service-card .service-icon {
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), color 0.3s;
}
.service-card:hover .service-icon {
  transform: translateY(-4px) scale(1.08);
  color: var(--green-glow);
}
/* animated underline that grows from the icon side on hover */
.service-card::after {
  content: '';
  position: absolute;
  left: 2rem;
  bottom: 1.4rem;
  height: 2px;
  width: 0;
  background: linear-gradient(to right, var(--green-bright), transparent);
  transition: width 0.4s ease;
}
.service-card:hover::after { width: 40px; }

/* ── SCROLL HINT: smooth fade so it doesn't pop ── */
.scroll-hint { z-index: 2; }

/* ── SECTION DIVIDER: animated gradient line above Services ── */
.section-divider {
  position: relative;
  z-index: 1;
  height: 1px;
  max-width: 1100px;
  margin: 0 auto;
  background: linear-gradient(
    to right,
    transparent,
    rgba(61,200,120,0.4),
    transparent
  );
  overflow: visible;
}
.section-divider::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 0;
  width: 60px;
  height: 5px;
  border-radius: 3px;
  background: var(--green-bright);
  filter: blur(2px);
  opacity: 0.8;
  animation: dividerSweep 5s ease-in-out infinite;
}
@keyframes dividerSweep {
  0%, 100% { left: 0%; }
  50%      { left: calc(100% - 60px); }
}

/* ── BUTTON PRIMARY: arrow nudge already exists; add ripple-glow ── */
.btn-primary {
  position: relative;
  overflow: hidden;
}
.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(255,255,255,0.25), transparent 60%);
  opacity: 0;
  transform: scale(0.4);
  transition: opacity 0.4s, transform 0.5s;
}
.btn-primary:hover::before {
  opacity: 1;
  transform: scale(1.4);
}
.btn-primary svg {
  position: relative;
  z-index: 1;
  transition: transform 0.25s;
}
.btn-primary:hover svg { transform: translateX(4px); }

/* ── RESPONSIVE: tone down heavy effects on small screens ── */
@media (max-width: 900px) {
  .hero-orb.orb-1 { width: 220px; height: 220px; }
  .hero-orb.orb-2 { width: 180px; height: 180px; }
  .hero-orb.orb-3 { display: none; }
  .reveal { transform: translateY(24px); }
  .reveal.from-left,
  .reveal.from-right { transform: translateY(24px); }
}