/* Mass Pro Films — motion & polish layer.
   Loaded after styles.css. Everything here switches off under
   prefers-reduced-motion (see the bottom of the file). */

@keyframes fadeUp    { from { opacity: 0; transform: translateY(26px); } to { opacity: 1; transform: none; } }
@keyframes popIn     { 0% { opacity: 0; transform: scale(.86); } 60% { transform: scale(1.04); } 100% { opacity: 1; transform: scale(1); } }
@keyframes floaty    { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes drift     { 0% { transform: translate(0,0) scale(1); } 33% { transform: translate(40px,-30px) scale(1.08); } 66% { transform: translate(-30px,20px) scale(.95); } 100% { transform: translate(0,0) scale(1); } }
@keyframes shimmer   { 0% { background-position: -300% 0; } 100% { background-position: 300% 0; } }
@keyframes ring      { 0% { box-shadow: 0 0 0 0 rgba(37,211,102,.55); } 70% { box-shadow: 0 0 0 16px rgba(37,211,102,0); } 100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); } }
@keyframes glowPulse { 0%, 100% { box-shadow: 0 24px 60px rgba(227,30,36,.16); } 50% { box-shadow: 0 24px 80px rgba(227,30,36,.3); } }
@keyframes underline { from { transform: scaleX(0); } to { transform: scaleX(1); } }

/* ---------------------------------------------------------- scroll reveal */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .75s cubic-bezier(.22,1,.36,1), transform .75s cubic-bezier(.22,1,.36,1);
  will-change: opacity, transform;
}
.reveal.in { opacity: 1; transform: none; }

/* ------------------------------------------------------------ hero motion */

.hero { position: relative; overflow: hidden; }
.hero::before, .hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: .5;
  pointer-events: none;
  z-index: 0;
}
.hero::before {
  width: 460px; height: 460px; top: -170px; left: -130px;
  background: radial-gradient(circle, #bae6fd 0%, transparent 70%);
  animation: drift 22s ease-in-out infinite;
}
.hero::after {
  width: 520px; height: 520px; top: -210px; right: -170px;
  background: radial-gradient(circle, #fecaca 0%, transparent 70%);
  animation: drift 26s ease-in-out infinite reverse;
}
.hero .wrap { position: relative; z-index: 1; }

.hero .eyebrow, .hero h1, .hero .lead, .hero-cta, .hero-stats, .hero .video-frame {
  animation: fadeUp .8s cubic-bezier(.22,1,.36,1) both;
}
.hero .eyebrow     { animation-delay: .02s; }
.hero h1           { animation-delay: .06s; }
.hero .lead        { animation-delay: .16s; }
.hero-cta          { animation-delay: .26s; }
.hero-stats        { animation-delay: .36s; }
.hero .video-frame { animation-delay: .46s; }

/* Closing words of the headline, in brand colour. */
.grad {
  background: linear-gradient(100deg, var(--red) 0%, #ff6b4a 50%, var(--red) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 6s linear infinite;
}

.hero-stats > div { transition: transform .25s ease; }
.hero-stats > div:hover { transform: translateY(-4px); }
.hero-stats b { font-variant-numeric: tabular-nums; }

/* ----------------------------------------------------------------- header */

.site-header { transition: box-shadow .25s ease, background .25s ease; }
.site-header.scrolled { box-shadow: 0 6px 24px rgba(15,23,42,.07); background: rgba(255,255,255,.94); }

.logo-img { transition: transform .3s cubic-bezier(.34,1.56,.64,1); transform-origin: left center; }
.logo:hover .logo-img { transform: scale(1.06); }
.footer-logo { transition: opacity .25s ease; }
.footer-logo:hover { opacity: 1; }

.nav a.navlink { position: relative; }
.nav a.navlink::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: -4px; height: 2px;
  background: var(--red); border-radius: 2px;
  transform: scaleX(0); transform-origin: left;
  transition: transform .25s cubic-bezier(.22,1,.36,1);
}
.nav a.navlink:hover::after { transform: scaleX(1); }
@media (max-width: 900px) { .nav a.navlink::after { display: none; } }

/* Reading-progress line under the header. */
.scroll-progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; pointer-events: none; }
.scroll-progress i {
  display: block; height: 100%; width: 0;
  background: linear-gradient(90deg, var(--red), #ff8a5c);
  transition: width .1s linear;
}

/* ---------------------------------------------------------------- buttons */

.btn { position: relative; overflow: hidden; }
.btn::after {
  content: "";
  position: absolute; top: 0; left: -120%; width: 60%; height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255,255,255,.38), transparent);
  transform: skewX(-20deg);
  transition: left .6s ease;
}
.btn:hover::after { left: 140%; }
.btn-ghost:hover::after { background: linear-gradient(100deg, transparent, rgba(15,23,42,.06), transparent); }
.btn:active { transform: translateY(1px) scale(.99); }
.btn-primary:hover { box-shadow: 0 10px 28px rgba(227,30,36,.38); }

/* ------------------------------------------------------------------ cards */

.card { position: relative; overflow: hidden; }
.card::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0; height: 3px;
  background: linear-gradient(90deg, var(--red), #ff8a5c);
  transform: scaleX(0); transform-origin: left;
  transition: transform .4s cubic-bezier(.22,1,.36,1);
}
.card:hover::before { transform: scaleX(1); }
.card:hover { transform: translateY(-6px); border-color: #fecaca; box-shadow: 0 18px 44px rgba(15,23,42,.1); }

.icon-badge { transition: transform .35s cubic-bezier(.34,1.56,.64,1), background .25s ease, color .25s ease; }
.card:hover .icon-badge { transform: translateY(-2px) rotate(-6deg) scale(1.08); background: var(--red); color: #fff; }

/* --------------------------------------------------------- pills, titles */

.pill { transition: transform .22s cubic-bezier(.34,1.56,.64,1), border-color .2s, color .2s, box-shadow .2s; }
.pill:hover { transform: translateY(-3px) scale(1.04); box-shadow: 0 8px 20px rgba(227,30,36,.14); }

.section .center h2 { position: relative; }
.section .center .eyebrow { display: block; }
.section .center h2::after {
  content: "";
  position: absolute; left: 50%; bottom: -10px; width: 56px; height: 3px;
  margin-left: -28px; border-radius: 3px;
  background: linear-gradient(90deg, var(--red), #ff8a5c);
  transform: scaleX(0);
}
.section .center.in h2::after { animation: underline .6s cubic-bezier(.22,1,.36,1) .2s forwards; }

.eyebrow::before {
  content: "";
  display: inline-block; width: 6px; height: 6px; border-radius: 50%;
  background: var(--red); margin-right: .5rem; vertical-align: middle;
}

/* ---------------------------------------------------- pricing & packages */

.price-card { animation: glowPulse 4.5s ease-in-out infinite; }
.price-card:hover { animation-play-state: paused; }
.price-badge, .pkg-tag { animation: popIn .5s cubic-bezier(.34,1.56,.64,1) both; }
.price-now { transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.price-card:hover .price-now { transform: scale(1.05); }
.pkg.best { transform: translateY(-6px); }
.pkg.best:hover { transform: translateY(-12px); }

/* ---------------------------------------------------------------- reviews */

.stars, .avatar { display: inline-block; transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.review:hover .stars { transform: scale(1.08); }
.review:hover .avatar { transform: rotate(-6deg) scale(1.08); }

/* ------------------------------------------------------------ video frame */

.video-frame { transition: transform .4s cubic-bezier(.22,1,.36,1), box-shadow .4s ease; }
.video-frame:hover { transform: translateY(-4px); box-shadow: 0 32px 80px rgba(15,23,42,.2); }

/* ------------------------------------------------------------------ forms */

.form-card { animation: fadeUp .6s cubic-bezier(.22,1,.36,1) both; }
.field input, .field select, .field textarea { transition: border-color .18s, box-shadow .18s, transform .18s; }
.field input:focus, .field select:focus, .field textarea:focus { transform: translateY(-1px); }
.alert.show { animation: fadeUp .4s cubic-bezier(.22,1,.36,1) both; }

/* -------------------------------------------------- dashboard & admin */

.lesson { transition: background .18s, color .18s, padding-left .22s cubic-bezier(.22,1,.36,1); }
.lesson:hover { padding-left: 1.9rem; }
.lesson.active { position: relative; }
.lesson.active::before {
  content: "";
  position: absolute; left: .4rem; top: 50%; width: 3px; height: 60%;
  transform: translateY(-50%);
  background: var(--red); border-radius: 3px;
  animation: popIn .35s cubic-bezier(.34,1.56,.64,1) both;
}
.lesson .tick { transition: background .25s, border-color .25s, transform .3s cubic-bezier(.34,1.56,.64,1); }
.lesson.done .tick { transform: scale(1.1); }
.progress-bar i { transition: width .6s cubic-bezier(.22,1,.36,1); }

.stat-card { transition: transform .25s ease, box-shadow .25s ease, border-color .25s; }
.stat-card:hover { transform: translateY(-4px); border-color: #fecaca; box-shadow: 0 14px 34px rgba(15,23,42,.08); }

tbody tr { transition: background .15s ease; }
tbody tr:hover { background: var(--bg-soft); }

/* --------------------------------------------------------------- floating */

.wa-float { animation: ring 2.8s ease-out infinite; transition: transform .3s cubic-bezier(.34,1.56,.64,1); }
.wa-float:hover { transform: scale(1.12) rotate(-6deg); }

.to-top {
  position: fixed; right: 20px; bottom: 88px; width: 44px; height: 44px;
  border-radius: 50%; border: 1px solid var(--line); background: #fff; color: var(--ink);
  display: grid; place-items: center; cursor: pointer; z-index: 70;
  box-shadow: var(--shadow); font-size: 1.1rem; font-family: inherit; line-height: 1;
  opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .3s, transform .3s, visibility .3s, color .2s, border-color .2s;
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { color: var(--red); border-color: var(--red); transform: translateY(-3px); }

#socials .card:hover { animation: floaty 2.4s ease-in-out infinite; }

/* --------------------------------------------------------- reduced motion */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
}
