/* ============================================================
   WILDSTAR NETWORKS — SITE-WIDE ANIMATION SYSTEM
   Single source of truth. Applied on every page via main.js.
   ============================================================ */

/* ── Respect reduced-motion preference ─────────────────────── */

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

/* ============================================================
   SCROLL-REVEAL BASE
   Elements start invisible; JS adds .ws-visible when in view.
   ============================================================ */

.ws-reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}

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

/* Slide from left */

.ws-reveal--left {
  transform: translateX(-32px);
}

.ws-reveal--left.ws-visible {
  transform: translateX(0);
}

/* Slide from right */

.ws-reveal--right {
  transform: translateX(32px);
}

.ws-reveal--right.ws-visible {
  transform: translateX(0);
}

/* Scale up (for icons, badges) */

.ws-reveal--scale {
  transform: scale(0.88) translateY(12px);
}

.ws-reveal--scale.ws-visible {
  transform: scale(1) translateY(0);
}

/* Stagger delays for grid children */

.ws-stagger > *:nth-child(1) {
  transition-delay: 0ms;
}

.ws-stagger > *:nth-child(2) {
  transition-delay: 80ms;
}

.ws-stagger > *:nth-child(3) {
  transition-delay: 160ms;
}

.ws-stagger > *:nth-child(4) {
  transition-delay: 240ms;
}

.ws-stagger > *:nth-child(5) {
  transition-delay: 320ms;
}

.ws-stagger > *:nth-child(6) {
  transition-delay: 400ms;
}

/* ============================================================
   HERO ENTRANCE ANIMATIONS
   Applied immediately on page load (no scroll needed).
   ============================================================ */

@keyframes ws-hero-fade-up {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes ws-hero-fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.ws-hero-eyebrow {
  animation: ws-hero-fade-up 0.55s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;
}

.ws-hero-title {
  animation: ws-hero-fade-up 0.65s cubic-bezier(0.22, 1, 0.36, 1) 0.18s both;
}

.ws-hero-lead {
  animation: ws-hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.32s both;
}

.ws-hero-stats {
  animation: ws-hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.44s both;
}

.ws-hero-actions {
  animation: ws-hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.54s both;
}

/* ============================================================
   NAVBAR — scroll glass effect
   ============================================================ */

.site-nav {
  transition: background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1), backdrop-filter 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.site-nav.ws-nav-scrolled {
  background-color: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  box-shadow: 0 1px 24px rgba(0, 0, 0, 0.08);
  border-bottom-color: rgba(229, 231, 235, 0.6);
}

/* ============================================================
   CARD HOVER — unified lift + glow
   Targets any card-like element across the site.
   ============================================================ */

.home-benefit, .home-testimonial, .home-county, .about-value, .about-team-teaser__card, .team-member, .contact-card, .services-included__card, .services-commercial__grid .plan-card, .coverage-plans-grid .plan-card, .outages-help__card, .contact-steps__step, .home-how__step, .faq-item {
  transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.28s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

/* ============================================================
   BUTTON HOVER — consistent across all pages
   ============================================================ */

.btn {
  transition: background-color 0.2s cubic-bezier(0.4, 0, 0.2, 1), border-color 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s cubic-bezier(0.4, 0, 0.2, 1), transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.btn:hover:not(:disabled) {
  transform: translateY(-2px) scale(1.015);
}

.btn:active:not(:disabled) {
  transform: translateY(0) scale(0.99);
  transition-duration: 0.1s !important;
}

/* ============================================================
   SOCIAL ICONS
   ============================================================ */

.social-icon {
  transition: background-color 0.22s cubic-bezier(0.4, 0, 0.2, 1), color 0.22s cubic-bezier(0.4, 0, 0.2, 1), transform 0.22s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

.social-icon:hover {
  transform: translateY(-3px) scale(1.08) !important;
}

/* ============================================================
   STATS BAND — counter animation target
   ============================================================ */

.home-stats-band__value {
  transition: opacity 0.4s ease;
}

/* ============================================================
   NAV LINK underline slide effect
   ============================================================ */

.site-nav__links .nav-link {
  position: relative;
}

.site-nav__links .nav-link::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  right: 50%;
  height: 2px;
  border-radius: 2px;
  background: var(--color-primary);
  opacity: 0;
  transition: left 0.2s cubic-bezier(0.4, 0, 0.2, 1), right 0.2s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.2s ease;
}

.site-nav__links .nav-link:hover::after, .site-nav__links .nav-link.active::after {
  left: var(--spacing-3, 0.75rem);
  right: var(--spacing-3, 0.75rem);
  opacity: 1;
}

/* ============================================================
   FAQ — smooth expand/collapse
   ============================================================ */

.faq-answer {
  transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.faq-icon {
  transition: background 0.2s ease, transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

/* ============================================================
   HERO SCROLL INDICATOR — gentle float
   ============================================================ */

@keyframes ws-float {
  0%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(7px);
  }
}

.home-hero__scroll {
  animation: ws-float 2.2s ease-in-out infinite !important;
}

/* ============================================================
   INNER-PAGE HERO — content entrance via .ws-hero-* classes
   ============================================================ */

.inner-hero__eyebrow {
  animation: ws-hero-fade-up 0.55s cubic-bezier(0.22, 1, 0.36, 1) 0.05s both;
}

.inner-hero__title {
  animation: ws-hero-fade-up 0.65s cubic-bezier(0.22, 1, 0.36, 1) 0.18s both;
}

.inner-hero__lead {
  animation: ws-hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.32s both;
}

.inner-hero__actions {
  animation: ws-hero-fade-up 0.6s cubic-bezier(0.22, 1, 0.36, 1) 0.44s both;
}

/* ============================================================
   ANNOUNCEMENT BANNER — subtle entrance
   ============================================================ */

@keyframes ws-banner-slide-down {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.site-banner:not([hidden]) {
  animation: ws-banner-slide-down 0.4s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ============================================================
   PAGE TRANSITION — subtle fade-in on load
   ============================================================ */

@keyframes ws-page-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

body {
  animation: ws-page-in 0.35s ease both;
}

/* ============================================================
   OUTAGES LIVE DOT — pulse
   ============================================================ */

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

.outages-live-badge__dot {
  animation: ws-live-pulse 1.6s ease-in-out infinite !important;
}

/* ============================================================
   TEAM MEMBER PHOTO — subtle zoom on hover
   ============================================================ */

.team-member__photo img {
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.team-member:hover .team-member__photo img {
  transform: scale(1.06);
}

/* ============================================================
   SECTION HEADER EYEBROW — animated underline accent
   ============================================================ */

.section-header__eyebrow, .home-section-header__eyebrow, .faq-category__eyebrow {
  position: relative;
  display: inline-block;
}

