/* ==============================================
   Micro-interactions — TheColorCo.
   Jakub-primary (production polish) +
   Jhey-selective (brand delight)
   All transforms/opacity only — GPU-safe.
   prefers-reduced-motion blocks at bottom.
   ============================================== */

/* --------------------------------------------------
   1. HERO SPACING — more breathing room from nav
   -------------------------------------------------- */
.hero-content {
  padding-top: 192px;
}

/* --------------------------------------------------
   2. NAV CTA — subtle idle shimmer so it draws the
      eye without shouting. Plays once, then rests.
   -------------------------------------------------- */
@keyframes cta-shimmer {
  0%   { box-shadow: 0 0 0 0   rgba(196, 83, 106, 0); }
  40%  { box-shadow: 0 0 0 6px rgba(196, 83, 106, 0.22); }
  100% { box-shadow: 0 0 0 12px rgba(196, 83, 106, 0); }
}
.nav-cta .btn-primary {
  animation: cta-shimmer 3.2s ease-out 2.4s 1;
}

/* --------------------------------------------------
   3. TESTIMONIAL CARDS — lift + subtle warm glow
   -------------------------------------------------- */
.testimonial-card {
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 0.28s ease;
}
.testimonial-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 18px 40px rgba(40, 12, 18, 0.22);
}

/* --------------------------------------------------
   4. CHOSEN CARDS — lift + rose underline reveal
   -------------------------------------------------- */
.chosen-card {
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1),
              box-shadow 0.28s ease;
  position: relative;
}
.chosen-card::before {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 0; height: 2px;
  background: var(--rose);
  transition: width 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.chosen-card:hover { transform: translateY(-4px); box-shadow: 0 12px 28px rgba(107, 31, 42, 0.1); }
.chosen-card:hover::before { width: 100%; }

/* --------------------------------------------------
   5. MARQUEE LOGOS — dim others on sibling hover
   -------------------------------------------------- */
.marquee-track:hover .marquee-logo { opacity: 0.45; transition: opacity 0.25s ease; }
.marquee-track .marquee-logo:hover { opacity: 1 !important; transform: scale(1.08); transition: opacity 0.2s ease, transform 0.2s ease; }

/* --------------------------------------------------
   6. HERO "SEE OUR WORK" CTA arrow nudge
   -------------------------------------------------- */
@keyframes arrow-nudge {
  0%, 100% { transform: translateX(0); }
  50%       { transform: translateX(4px); }
}
.btn-rose:hover .btn-arrow,
.hero-ctas .btn-rose:hover {
  /* arrow nudge handled via pseudo-content workaround */
}
/* The "→" in nav CTA nudges on hover */
.nav-cta .btn-primary:hover .nav-arrow { animation: arrow-nudge 0.5s ease infinite; }

/* --------------------------------------------------
   7. HERO DOTS — smoother active state (width spring)
   -------------------------------------------------- */
.hero-dot span {
  transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
              background 0.35s ease;
}

/* --------------------------------------------------
   8. COUNT-UP NUMBERS — targeted via JS class
   -------------------------------------------------- */
.chosen-num[data-countup] { transition: opacity 0.4s ease; }

/* --------------------------------------------------
   9. PRE-LABELS (section eyebrows) — left-bar slide
   -------------------------------------------------- */
.pre-label {
  position: relative;
  display: inline-block;
}
.pre-label::before {
  content: '';
  position: absolute;
  left: -14px; top: 50%;
  transform: translateY(-50%) scaleY(0);
  width: 2px; height: 14px;
  background: var(--rose);
  border-radius: 2px;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  transform-origin: bottom center;
}
.pre-label.is-visible::before { transform: translateY(-50%) scaleY(1); }

/* --------------------------------------------------
   10. CONTACT / FOOTER LINKS — icon nudge on hover
   -------------------------------------------------- */
.footer-contact-link:hover .footer-contact-icon {
  transform: translateX(3px);
  transition: transform 0.22s ease;
}
.footer-contact-icon {
  transition: transform 0.22s ease;
}

/* --------------------------------------------------
   11. HERO TRUST LINE — fade-slide (stagger after sub)
   -------------------------------------------------- */
.hero-trust.hero-anim { animation-delay: 0.9s; }

/* --------------------------------------------------
   12. STACK SECTION CARD — image subtle zoom on enter
   -------------------------------------------------- */
.stack-image {
  transition: transform 8s linear;
}
.stack-card.is-active .stack-image { transform: scale(1.04); }

/* --------------------------------------------------
   13. SECTION ENTRY — stagger reveal for grid children
   -------------------------------------------------- */
.chosen-grid .chosen-card.reveal { transition-delay: calc(var(--i, 0) * 0.08s); }
.cta-cards .reveal             { transition-delay: calc(var(--i, 0) * 0.1s); }

/* --------------------------------------------------
   14. SCROLL INDICATOR TEXT — fade in/out breathing
   -------------------------------------------------- */
@keyframes breathe-text {
  0%, 100% { opacity: 0.45; }
  50%       { opacity: 0.8;  }
}
.scroll-indicator span { animation: breathe-text 2.8s ease-in-out infinite; }

/* --------------------------------------------------
   PREFERS-REDUCED-MOTION — kill all of the above
   -------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .testimonial-card,
  .chosen-card,
  .marquee-logo,
  .marquee-track:hover .marquee-logo,
  .hero-dot span,
  .pre-label::before,
  .footer-contact-icon,
  .stack-image { transition: none !important; animation: none !important; }

  .nav-cta .btn-primary,
  .scroll-indicator span { animation: none !important; }

  .hero-content { padding-top: 192px; } /* spacing still applies */
}
