/* ============================================================
   HOTSHOT BASKETBALL — ANIMATIONS
   ============================================================ */

/* ── Initial hidden state for animated elements ──────────────── */
[data-animate] {
  opacity: 0;
  transition: opacity .6s ease, transform .6s cubic-bezier(0.22, 1, 0.36, 1);
}

[data-animate="fade-up"]    { transform: translateY(30px); }
[data-animate="fade-down"]  { transform: translateY(-30px); }
[data-animate="fade-left"]  { transform: translateX(40px); }
[data-animate="fade-right"] { transform: translateX(-40px); }
[data-animate="zoom-in"]    { transform: scale(.9); }
[data-animate="zoom-out"]   { transform: scale(1.1); }

[data-animate].is-visible {
  opacity: 1;
  transform: none;
}

/* ── Delay utility classes ───────────────────────────────────── */
[data-delay="50"]  { transition-delay: .05s; }
[data-delay="100"] { transition-delay: .1s; }
[data-delay="150"] { transition-delay: .15s; }
[data-delay="200"] { transition-delay: .2s; }
[data-delay="250"] { transition-delay: .25s; }
[data-delay="300"] { transition-delay: .3s; }
[data-delay="350"] { transition-delay: .35s; }
[data-delay="400"] { transition-delay: .4s; }

/* ── Specific animations ─────────────────────────────────────── */

@keyframes shimmer {
  0%   { background-position: -200% 0; }
  100% { background-position: 200%  0; }
}
.hb-shimmer {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes orange-pulse {
  0%,100% { box-shadow: 0 0 0 0 rgba(255,107,0,.4); }
  50%      { box-shadow: 0 0 0 12px rgba(255,107,0,0); }
}
.hb-pulse { animation: orange-pulse 2.5s infinite; }

@keyframes float {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(-10px); }
}
.hb-float { animation: float 4s ease-in-out infinite; }

@keyframes ball-spin {
  to { transform: rotate(360deg); }
}
.hb-spin { animation: ball-spin 8s linear infinite; }

@keyframes fade-in-up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes bounce-arrow {
  0%,100% { transform: translateY(0); }
  50%     { transform: translateY(6px); }
}
.hb-bounce { animation: bounce-arrow 1.5s ease-in-out infinite; }

/* Button hover ripple */
.hb-btn--primary {
  position: relative;
  overflow: hidden;
}
.hb-btn--primary::after {
  content: '';
  position: absolute; top: 50%; left: 50%;
  width: 0; height: 0;
  background: rgba(255,255,255,.2);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  transition: width .5s ease, height .5s ease, opacity .5s ease;
  pointer-events: none;
}
.hb-btn--primary:active::after {
  width: 300px; height: 300px; opacity: 0;
}

/* Nav item underline slide */
.hb-nav__list li a {
  position: relative;
}
.hb-nav__list li a::after {
  content: '';
  position: absolute; bottom: 0; left: .85rem; right: .85rem;
  height: 2px; background: var(--color-orange);
  transform: scaleX(0); transform-origin: right;
  transition: transform .3s ease;
}
.hb-nav__list li a:hover::after,
.hb-nav__list li.current-menu-item > a::after,
.hb-nav__list li.current_page_item > a::after {
  transform: scaleX(1); transform-origin: left;
}

/* Counter number animation */
.hb-hero__stat-number {
  display: inline-block;
  transition: opacity .3s;
}

/* Section label line animation */
@keyframes line-expand {
  from { width: 0; }
  to   { width: .75rem; }
}
.hb-section__label.is-visible::before {
  animation: line-expand .4s ease forwards;
}

/* Card hover lift */
.hb-program-card,
.hb-coach-card,
.hb-blog-card,
.hb-about-why__card {
  will-change: transform;
}

/* Underline link hover */
.hb-blog-card__title a,
.hb-program-card__title a,
.hb-coach-card__name a {
  background: linear-gradient(var(--color-orange), var(--color-orange)) no-repeat right bottom / 0 2px;
  transition: background-size .3s ease, color var(--transition);
}
.hb-blog-card__title a:hover,
.hb-program-card__title a:hover,
.hb-coach-card__name a:hover {
  background-position: left bottom;
  background-size: 100% 2px;
  color: var(--color-orange);
}

/* Page transitions */
.hb-main {
  animation: fade-in-up .5s ease forwards;
}

/* Accordion smooth open */
.hb-accordion__body {
  transition: max-height .35s ease, padding .35s ease;
  max-height: 0;
  overflow: hidden;
  padding-bottom: 0;
}
.hb-accordion__body:not([hidden]) {
  max-height: 400px;
  padding-bottom: 1.25rem;
}

/* Mobile menu slide */
.hb-nav {
  transition: right 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reduce motion preference */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  [data-animate] {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hb-main { animation: none; }
}
