/* ═══ Premium Animations ═══ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes fadeInUp {
  from {
    opacity  : 0;
    transform: translateY(40px);
  }

  to {
    opacity  : 1;
    transform: translateY(0);
  }
}

@keyframes fadeInDown {
  from {
    opacity  : 0;
    transform: translateY(-30px);
  }

  to {
    opacity  : 1;
    transform: translateY(0);
  }
}

@keyframes fadeInLeft {
  from {
    opacity  : 0;
    transform: translateX(-40px);
  }

  to {
    opacity  : 1;
    transform: translateX(0);
  }
}

@keyframes fadeInRight {
  from {
    opacity  : 0;
    transform: translateX(40px);
  }

  to {
    opacity  : 1;
    transform: translateX(0);
  }
}

@keyframes scaleIn {
  from {
    opacity  : 0;
    transform: scale(0.9);
  }

  to {
    opacity  : 1;
    transform: scale(1);
  }
}

@keyframes bounceIn {
  0% {
    opacity  : 0;
    transform: scale(0.5);
  }

  60% {
    transform: scale(1.08);
  }

  100% {
    opacity  : 1;
    transform: scale(1);
  }
}

@keyframes float {

  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(20px, -20px);
  }
}

@keyframes shimmer {
  0% {
    background-position: -200% 0;
  }

  100% {
    background-position: 200% 0;
  }
}

@keyframes gradientShift {
  0% {
    background-position: 0% 50%;
  }

  50% {
    background-position: 100% 50%;
  }

  100% {
    background-position: 0% 50%;
  }
}

@keyframes rotateSlow {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes wave {

  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-12px);
  }
}

/* Hero */
.hero-section::after {
  content       : "";
  position      : absolute;
  bottom        : 0;
  left          : 0;
  right         : 0;
  height        : 120px;
  /* background    : linear-gradient(transparent, var(--white)); */
  z-index       : 2;
  pointer-events: none;
}

.hero-particles {
  position      : absolute;
  inset         : 0;
  z-index       : 2;
  overflow      : hidden;
  pointer-events: none;
}

.hero-particles span {
  position     : absolute;
  border-radius: 50%;
  background   : rgba(255, 255, 255, 0.15);
  animation    : float 12s ease-in-out infinite;
}

.hero-particles span:nth-child(1) {
  width          : 8px;
  height         : 8px;
  left           : 15%;
  top            : 25%;
  animation-delay: 0s;
}

.hero-particles span:nth-child(2) {
  width          : 12px;
  height         : 12px;
  left           : 75%;
  top            : 35%;
  animation-delay: -2s;
}

.hero-particles span:nth-child(3) {
  width          : 6px;
  height         : 6px;
  left           : 45%;
  top            : 65%;
  animation-delay: -4s;
}

.hero-particles span:nth-child(4) {
  width          : 10px;
  height         : 10px;
  left           : 85%;
  top            : 70%;
  animation-delay: -1s;
}

.hero-particles span:nth-child(5) {
  width          : 14px;
  height         : 14px;
  left           : 25%;
  top            : 75%;
  animation-delay: -3s;
}

.hero-particles span:nth-child(6) {
  width          : 8px;
  height         : 8px;
  left           : 55%;
  top            : 20%;
  animation-delay: -5s;
}

.hero-particles span:nth-child(7) {
  width          : 6px;
  height         : 6px;
  left           : 5%;
  top            : 50%;
  animation-delay: -2.5s;
}

.hero-particles span:nth-child(8) {
  width          : 10px;
  height         : 10px;
  left           : 92%;
  top            : 55%;
  animation-delay: -4.5s;
}

.hero-orb {
  position     : absolute;
  border-radius: 50%;
  filter       : blur(60px);
  opacity      : 0.4;
  z-index      : 1;
  animation    : float 10s ease-in-out infinite;
}

.hero-orb-1 {
  width          : 300px;
  height         : 300px;
  background     : var(--primary);
  top            : -100px;
  right          : -50px;
  animation-delay: 0s;
}

.hero-orb-2 {
  width          : 200px;
  height         : 200px;
  background     : var(--accent);
  bottom         : -50px;
  left           : -50px;
  animation-delay: -3s;
}

.hero-badge {
  animation: fadeInDown 0.8s var(--ease) 0.2s both;
}

.hero-title {
  animation: fadeInUp 1s var(--ease) 0.3s both;
}

.hero-subtitle {
  animation: fadeInUp 1s var(--ease) 0.45s both;
}

.search-box {
  animation: scaleIn 0.9s var(--ease) 0.55s both;
}

.search-tags {
  animation: fadeInUp 0.8s var(--ease) 0.7s both;
}

.counselling-btn {
  animation: fadeInUp 0.8s var(--ease) 0.85s both;
}

/* Scroll reveal */
.reveal {
  opacity   : 0;
  transform : translateY(50px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

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

.reveal-left {
  opacity   : 0;
  transform : translateX(-50px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal-left.is-visible {
  opacity  : 1;
  transform: translateX(0);
}

.reveal-right {
  opacity   : 0;
  transform : translateX(50px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.reveal-right.is-visible {
  opacity  : 1;
  transform: translateX(0);
}

.reveal-scale {
  opacity   : 0;
  transform : scale(0.92);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal-scale.is-visible {
  opacity  : 1;
  transform: scale(1);
}

/* Stagger */
.stagger-children>* {
  opacity   : 0;
  transform : translateY(30px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

.stagger-children.is-visible>*:nth-child(1) {
  transition-delay: 0.05s;
}

.stagger-children.is-visible>*:nth-child(2) {
  transition-delay: 0.1s;
}

.stagger-children.is-visible>*:nth-child(3) {
  transition-delay: 0.15s;
}

.stagger-children.is-visible>*:nth-child(4) {
  transition-delay: 0.2s;
}

.stagger-children.is-visible>*:nth-child(5) {
  transition-delay: 0.25s;
}

.stagger-children.is-visible>*:nth-child(6) {
  transition-delay: 0.3s;
}

.stagger-children.is-visible>*:nth-child(7) {
  transition-delay: 0.35s;
}

.stagger-children.is-visible>*:nth-child(8) {
  transition-delay: 0.4s;
}

.stagger-children.is-visible>* {
  opacity  : 1;
  transform: translateY(0);
}

/* Hover lift */
.hover-lift {
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease);
}

/* Card tilt prep */
.tilt-card {
  transform-style: preserve-3d;
  transition     : transform 0.15s ease-out;
}

/* Button shine */
.btn-shine {
  position: relative;
  overflow: hidden;
}

.btn-shine::before {
  content   : "";
  position  : absolute;
  top       : 0;
  left      : -100%;
  width     : 50%;
  height    : 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
  transition: left 0.6s ease;
}

.btn-shine:hover::before {
  left: 150%;
}

.pulse-cta {
  animation: pulseGlow 2.5s ease-in-out infinite;
}

@keyframes pulseGlow {

  0%,
  100% {
    box-shadow: 0 4px 20px rgba(255, 107, 0, 0.35);
  }

  50% {
    box-shadow: 0 4px 35px rgba(255, 107, 0, 0.6);
  }
}

/* Section title underline */
.section-title-animated {
  position: relative;
  display : inline-block;
}

.section-title-animated::after {
  content      : "";
  position     : absolute;
  left         : 0;
  bottom       : -8px;
  height       : 4px;
  width        : 0;
  background   : linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: 4px;
  transition   : width 0.8s var(--ease);
}

.reveal.is-visible .section-title-animated::after,
.section-header.is-visible .section-title-animated::after {
  width: 80px;
}

/* Stats counter glow */
.stat-item {
  animation: fadeInUp 0.6s var(--ease) both;
}

.stat-item:nth-child(1) {
  animation-delay: 0.1s;
}

.stat-item:nth-child(2) {
  animation-delay: 0.2s;
}

.stat-item:nth-child(3) {
  animation-delay: 0.3s;
}

.stat-item:nth-child(4) {
  animation-delay: 0.4s;
}

/* Table row animate */
.ranking-table tbody tr {
  animation: fadeIn 0.5s var(--ease) both;
}

.ranking-table tbody tr:nth-child(1) {
  animation-delay: 0.05s;
}

.ranking-table tbody tr:nth-child(2) {
  animation-delay: 0.1s;
}

.ranking-table tbody tr:nth-child(3) {
  animation-delay: 0.15s;
}

.ranking-table tbody tr:nth-child(4) {
  animation-delay: 0.2s;
}

.ranking-table tbody tr:nth-child(5) {
  animation-delay: 0.25s;
}

/* News fade on tab */
#newsContainer {
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}

#newsContainer.news-fade {
  opacity  : 0;
  transform: translateY(12px);
}

/* Mega panel items */
.mega-menu-panel.is-active .col-lg-3,
.mega-menu-panel.is-active .col-lg-4,
.mega-menu-panel.is-active .col-md-6 {
  animation: fadeInUp 0.4s var(--ease) both;
}

.mega-menu-panel.is-active .col-lg-3:nth-child(1),
.mega-menu-panel.is-active .col-md-6:nth-child(1) {
  animation-delay: 0.05s;
}

.mega-menu-panel.is-active .col-lg-3:nth-child(2),
.mega-menu-panel.is-active .col-md-6:nth-child(2) {
  animation-delay: 0.1s;
}

.mega-menu-panel.is-active .col-lg-3:nth-child(3),
.mega-menu-panel.is-active .col-md-6:nth-child(3) {
  animation-delay: 0.15s;
}

.mega-menu-panel.is-active .col-lg-3:nth-child(4),
.mega-menu-panel.is-active .col-md-6:nth-child(4) {
  animation-delay: 0.2s;
}

/* Floating icons on feature cards */
.feature-card .icon {
  animation: wave 3s ease-in-out infinite;
}

.feature-card:nth-child(2) .icon {
  animation-delay: -1s;
}

.feature-card:nth-child(3) .icon {
  animation-delay: -2s;
}

/* Gradient border animation on goal cards */
.goal-card::after {
  content        : "";
  position       : absolute;
  inset          : -2px;
  border-radius  : calc(var(--radius) + 2px);
  /* background  : linear-gradient(135deg, var(--primary), var(--accent), var(--primary)); */
  background-size: 200% 200%;
  animation      : gradientShift 4s ease infinite;
  z-index        : -1;
  opacity        : 0;
  transition     : opacity 0.4s;
}

.goal-card:hover::after {
  opacity: 1;
}

/* Tab content transition */
.tab-content-animated {
  animation: fadeInUp 0.5s var(--ease);
}

/* Compare bar slide */
.compare-bar.show {
  animation: slideUpBar 0.45s var(--ease);
}

@keyframes slideUpBar {
  from {
    transform: translateY(100%);
  }

  to {
    transform: translateY(0);
  }
}

/* Toast slide */
.toast.showing {
  animation: toastIn 0.4s var(--ease);
}

@keyframes toastIn {
  from {
    transform: translateX(100%);
    opacity  : 0;
  }

  to {
    transform: translateX(0);
    opacity  : 1;
  }
}

/* Loading state */
body.page-loading .reveal,
body.page-loading .stagger-children>* {
  opacity: 0 !important;
}

/* Marquee optional - skip */

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration       : 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration      : 0.01ms !important;
  }

  .reveal,
  .reveal-left,
  .reveal-right,
  .reveal-scale,
  .stagger-children>* {
    opacity  : 1 !important;
    transform: none !important;
  }
}

.actions {

  display  : flex;
  flex-wrap: wrap;
  gap      : 10px;

}