/* ==================================================================
   INTERACTIVE MARKETING ENHANCEMENTS
   Tasteful animations and micro-interactions for marketing pages
   ================================================================== */

/* ============================================
   SMOOTH SCROLL BEHAVIOR
   ============================================ */

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: prefer) {
  html {
    scroll-behavior: auto;
  }
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */

[data-scroll-reveal-target="item"] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-scroll-reveal-target="item"].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Disable animations for reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  [data-scroll-reveal-target="item"] {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

/* ============================================
   24/7 PULSE INDICATOR
   ============================================ */

.pulse-active .proof-icon {
  position: relative;
}

.pulse-active .proof-icon::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 100%;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: rgba(45, 138, 123, 0.2);
  animation: pulse-ring 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulse-ring {
  0% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(1.5);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .pulse-active .proof-icon::before {
    animation: none;
  }
}

/* ============================================
   ENHANCED HOVER STATES
   ============================================ */

.card {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
  transform: translateY(-4px);
}

.serve-item {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.serve-item:hover .serve-icon {
  transform: scale(1.05);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn {
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
  width: 300px;
  height: 300px;
}

.btn--primary:hover {
  box-shadow: 0 8px 20px rgba(45, 138, 123, 0.3);
  transform: translateY(-2px);
}

.btn--outline:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

/* ============================================
   FLOATING CTA BUTTON
   ============================================ */

.floating-cta-button {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  background: #2d8a7b;
  color: white;
  font-weight: 600;
  font-size: var(--text-base);
  border-radius: var(--radius-full);
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(45, 138, 123, 0.4);
  opacity: 0;
  transform: translateY(100px) scale(0.8);
  pointer-events: none;
  transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.floating-cta-button svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.floating-cta-button.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: all;
}

.floating-cta-button:hover {
  background: #247a6c;
  box-shadow: 0 12px 32px rgba(45, 138, 123, 0.5);
  transform: translateY(-2px) scale(1.02);
}

.floating-cta-button:hover svg {
  transform: rotate(12deg) scale(1.1);
}

.floating-cta-button:active {
  transform: translateY(0) scale(0.98);
}

@media (max-width: 768px) {
  .floating-cta-button {
    bottom: 16px;
    right: 16px;
    padding: var(--space-sm) var(--space-lg);
    font-size: var(--text-sm);
  }

  .floating-cta-button svg {
    width: 18px;
    height: 18px;
  }
}

/* Hide on very small screens */
@media (max-width: 480px) {
  .floating-cta-button {
    display: none;
  }
}

/* ============================================
   PROCESS TIMELINE ENHANCEMENTS
   ============================================ */

.process-timeline__content {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.process-timeline__content:hover {
  transform: translateX(8px);
}

.process-timeline__number {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.process-timeline__step:hover .process-timeline__number {
  transform: scale(1.1) rotate(5deg);
}

.process-timeline__icon {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.process-timeline__step:hover .process-timeline__icon {
  background: rgba(45, 138, 123, 0.1);
  border-color: #2d8a7b;
  transform: scale(1.05);
}

/* ============================================
   CARD FEATURE ENHANCEMENTS
   ============================================ */

.card--feature {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card--feature:hover {
  transform: translateY(-6px);
}

.card__icon-wrapper {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.card--feature:hover .card__icon-wrapper {
  transform: scale(1.1);
}

.card__icon-wrapper .card__icon {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.card--feature:hover .card__icon-wrapper .card__icon {
  transform: rotate(5deg);
}

/* ============================================
   FAQ ITEM INTERACTIONS
   ============================================ */

.faq-item {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.faq-item:hover {
  background: var(--surface);
}

.faq-item__icon {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.faq-item:hover .faq-item__icon {
  transform: scale(1.15) rotate(5deg);
}

/* ============================================
   STEP ANIMATIONS
   ============================================ */

.step {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.step__number {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.step:hover .step__number {
  transform: scale(1.1) rotate(-5deg);
  box-shadow: 0 6px 16px rgba(45, 138, 123, 0.3);
}

/* ============================================
   HERO ENTRANCE ANIMATION
   ============================================ */

.landing-hero .container {
  animation: heroFadeIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes heroFadeIn {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.landing-hero h1 {
  animation: heroTitleIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.2s backwards;
}

@keyframes heroTitleIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.landing-hero__sub {
  animation: heroSubIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.3s backwards;
}

@keyframes heroSubIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.landing-hero__actions {
  animation: heroActionsIn 0.8s cubic-bezier(0.4, 0, 0.2, 1) 0.4s backwards;
}

@keyframes heroActionsIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================
   PROOF POINTS ENTRANCE
   ============================================ */

.proof-item {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.proof-item:hover {
  transform: translateY(-4px);
}

.proof-item:hover .proof-icon {
  transform: scale(1.1);
  color: #247a6c;
}

.proof-icon {
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* ============================================
   NAVIGATION HOVER EFFECTS
   ============================================ */

.landing-nav-link {
  position: relative;
}

.landing-nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: #2d8a7b;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.landing-nav-link:hover::after,
.landing-nav-link--active::after {
  width: 100%;
}

.nav-cta {
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-cta:hover {
  box-shadow: 0 4px 12px rgba(45, 138, 123, 0.3);
  transform: translateY(-1px);
}

/* ============================================
   REDUCED MOTION PREFERENCES
   ============================================ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .floating-cta-button,
  .btn,
  .card,
  .serve-item,
  .proof-item,
  .step,
  .faq-item,
  .process-timeline__content,
  .card--feature {
    transition: none !important;
  }

  .floating-cta-button.is-visible {
    opacity: 1;
    transform: none;
  }
}
