/* ============================================================
   MYSUGARDADDY – Premium Luxury Matchmaking Platform
   animations.css – Keyframes & Motion Styles
   ============================================================ */

/* -- Keyframe Definitions ---------------------------------- */

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

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

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

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

@keyframes fadeInRight {
  from { opacity: 0; transform: translateX(32px); }
  to   { opacity: 1; transform: translateX(0); }
}

@keyframes scaleIn {
  from { opacity: 0; transform: scale(0.88); }
  to   { opacity: 1; transform: scale(1); }
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

/* Gold shimmer sweep */
@keyframes goldShimmer {
  0%   { background-position: -200% center; }
  100% { background-position:  200% center; }
}

/* Subtle pulse glow */
@keyframes goldPulse {
  0%, 100% { box-shadow: 0 0 20px rgba(212,175,55,0.15); }
  50%       { box-shadow: 0 0 36px rgba(212,175,55,0.40); }
}

/* Floating bob */
@keyframes floatBob {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-10px); }
}

/* Counter count-up (visual feedback only) */
@keyframes countUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Spinner */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* Dot blink */
@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.2; }
}

/* Hero badge line grow */
@keyframes lineGrow {
  from { width: 0; }
  to   { width: 24px; }
}

/* Scroll indicator */
@keyframes scrollBounce {
  0%, 100% { transform: translateY(0);  opacity: 1; }
  50%       { transform: translateY(8px); opacity: 0.5; }
}

/* Diagonal light sweep on buttons */
@keyframes btnSweep {
  from { left: -100%; }
  to   { left: 110%; }
}

/* -- Animation Utility Classes ----------------------------- */

/* Base class – applies the animation */
.anim-fade-in      { animation: fadeIn      0.55s ease both; }
.anim-fade-in-up   { animation: fadeInUp    0.65s ease both; }
.anim-fade-in-down { animation: fadeInDown  0.55s ease both; }
.anim-fade-in-left { animation: fadeInLeft  0.65s ease both; }
.anim-fade-in-right{ animation: fadeInRight 0.65s ease both; }
.anim-scale-in     { animation: scaleIn     0.50s ease both; }
.anim-slide-up     { animation: slideUp     0.60s cubic-bezier(0.23,1,0.32,1) both; }
.anim-float        { animation: floatBob    4s ease-in-out infinite; }
.anim-pulse-gold   { animation: goldPulse   2.8s ease-in-out infinite; }

/* Delay helpers */
.delay-100 { animation-delay: 0.10s; }
.delay-200 { animation-delay: 0.20s; }
.delay-300 { animation-delay: 0.30s; }
.delay-400 { animation-delay: 0.40s; }
.delay-500 { animation-delay: 0.50s; }
.delay-600 { animation-delay: 0.60s; }
.delay-700 { animation-delay: 0.70s; }
.delay-800 { animation-delay: 0.80s; }

/* -- Button Sweep Effect ----------------------------------- */
.btn--gold {
  overflow: hidden;
}
.btn--gold::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 60%;
  height: 100%;
  background: linear-gradient(
    120deg,
    transparent 0%,
    rgba(255,255,255,0.22) 50%,
    transparent 100%
  );
  transform: skewX(-20deg);
  transition: none;
}
.btn--gold:hover::after {
  animation: btnSweep 0.55s ease forwards;
}

/* -- Gold Shimmer Text -------------------------------------- */
.shimmer-text {
  background: linear-gradient(
    120deg,
    var(--gold-dark) 0%,
    var(--gold-light) 40%,
    var(--gold)       60%,
    var(--gold-dark)  100%
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: goldShimmer 3s linear infinite;
}

/* -- Hero Scroll Indicator --------------------------------- */
.scroll-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
}
.scroll-indicator span {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
}
.scroll-mouse {
  width: 22px;
  height: 36px;
  border: 1.5px solid rgba(212,175,55,0.35);
  border-radius: 11px;
  display: flex;
  justify-content: center;
  padding-top: 6px;
}
.scroll-mouse-dot {
  width: 4px;
  height: 8px;
  background: var(--gold);
  border-radius: 2px;
  animation: scrollBounce 1.5s ease-in-out infinite;
}

/* -- Online dot pulse -------------------------------------- */
.online-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  display: inline-block;
  position: relative;
}
.online-dot::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid rgba(34,197,94,0.4);
  animation: goldPulse 1.8s ease-in-out infinite;
}

/* -- Loading Spinner --------------------------------------- */
.spinner {
  width: 24px;
  height: 24px;
  border: 2.5px solid rgba(212,175,55,0.25);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.75s linear infinite;
  display: inline-block;
}

/* -- Reveal on scroll – enhanced -------------------------- */
.reveal-left  { opacity: 0; transform: translateX(-28px); transition: opacity 0.65s ease, transform 0.65s ease; }
.reveal-right { opacity: 0; transform: translateX( 28px); transition: opacity 0.65s ease, transform 0.65s ease; }
.reveal-scale { opacity: 0; transform: scale(0.93);       transition: opacity 0.55s ease, transform 0.55s ease; }
.reveal-left.visible, .reveal-right.visible, .reveal-scale.visible {
  opacity: 1;
  transform: none;
}

/* -- Section transition lines ------------------------------ */
.section-line-enter {
  animation: lineGrow 0.6s ease forwards;
}

/* -- Stagger children -------------------------------------- */
.stagger-children > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.stagger-children.visible > *:nth-child(1) { opacity: 1; transform: none; transition-delay: 0.05s; }
.stagger-children.visible > *:nth-child(2) { opacity: 1; transform: none; transition-delay: 0.15s; }
.stagger-children.visible > *:nth-child(3) { opacity: 1; transform: none; transition-delay: 0.25s; }
.stagger-children.visible > *:nth-child(4) { opacity: 1; transform: none; transition-delay: 0.35s; }
.stagger-children.visible > *:nth-child(5) { opacity: 1; transform: none; transition-delay: 0.45s; }
.stagger-children.visible > *:nth-child(6) { opacity: 1; transform: none; transition-delay: 0.55s; }

/* -- Page Loader ------------------------------------------- */
.page-loader {
  position: fixed;
  inset: 0;
  background: var(--bg-primary);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 24px;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.page-loader.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
.page-loader-logo {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--gold);
  animation: goldPulse 1.5s ease-in-out infinite;
  letter-spacing: 0.08em;
}
.page-loader-bar {
  width: 160px;
  height: 2px;
  background: var(--bg-card);
  border-radius: 2px;
  overflow: hidden;
}
.page-loader-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold-dark), var(--gold-light));
  border-radius: 2px;
  animation: loadBarFill 1.6s ease forwards;
}
@keyframes loadBarFill {
  from { width: 0%; }
  to   { width: 100%; }
}
