/*
 * Versa premium motion layer
 * Progressive enhancement only: content remains visible without JavaScript.
 */

:root {
  --premium-ease: cubic-bezier(.16, 1, .3, 1);
  --premium-soft-ease: cubic-bezier(.22, 1, .36, 1);
  --premium-mint: #3dffc2;
  --premium-blue: #4d8aff;
  --premium-violet: #9b6dff;
}

/*
 * Keep navigation attached to the top of the document, not the viewport.
 * The menu is available on the first screen and naturally scrolls away with
 * the page, matching the calmer case-study navigation pattern.
 */
nav {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
}

/* A more refined glass transition when the navigation leaves the hero. */
nav.sc {
  box-shadow:
    0 14px 38px rgba(0, 0, 0, .24),
    0 1px 0 rgba(61, 255, 194, .035) !important;
  transition:
    background-color .55s var(--premium-soft-ease),
    border-color .55s var(--premium-soft-ease),
    box-shadow .55s var(--premium-soft-ease),
    backdrop-filter .55s var(--premium-soft-ease) !important;
}

/*
 * The original site marked many individual cards with data-r. Keep those
 * elements fully visible and reveal only the larger content groups assembled
 * by premium-motion.js. This makes the page feel continuous instead of making
 * every card perform its own entrance.
 */
@media (prefers-reduced-motion: no-preference) {
  html.premium-motion-ready body [data-r]:not(.premium-reveal-group) {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    animation: none !important;
    transition: none !important;
  }

  html.premium-motion-ready body .premium-reveal-group {
    opacity: .82 !important;
    transform: translate3d(0, 10px, 0) !important;
    filter: none !important;
    animation: none !important;
    transition:
      opacity .66s var(--premium-soft-ease),
      transform .78s var(--premium-ease) !important;
    will-change: opacity, transform;
  }

  html.premium-motion-ready body .premium-reveal-group.premium-visible {
    opacity: 1 !important;
    transform: none !important;
    filter: blur(0) !important;
  }

  /* The hero already has its own choreography. Never hide it behind a reveal. */
  html.premium-motion-ready body .hero [data-r],
  html.premium-motion-ready body .hero .hl > *,
  html.premium-motion-ready body .hero .hr {
    opacity: 1 !important;
    filter: none !important;
  }
}

/*
 * Pointer light follows the visitor inside interactive cards. It adds depth
 * without tilting the layout or making text harder to read.
 */
.premium-card {
  position: relative;
  isolation: isolate;
}

.premium-card-light {
  position: absolute !important;
  inset: 1px !important;
  z-index: 0 !important;
  display: block !important;
  border-radius: inherit !important;
  pointer-events: none !important;
  opacity: 0;
  background:
    radial-gradient(
      360px circle at var(--premium-x, 50%) var(--premium-y, 50%),
      rgba(61, 255, 194, .105),
      rgba(77, 138, 255, .038) 36%,
      transparent 68%
    );
  transition: opacity .55s var(--premium-soft-ease);
}

.premium-card > :not(.premium-card-light):not(.pr-pop):not(.coming-soon-pop) {
  position: relative;
  z-index: 1;
}

@media (hover: hover) and (pointer: fine) {
  html.premium-motion-ready body .premium-card:not(.premium-reveal-group) {
    transition:
      transform .62s var(--premium-ease),
      border-color .62s var(--premium-ease),
      box-shadow .62s var(--premium-ease) !important;
  }

  html.premium-motion-ready body .premium-card.premium-reveal-group {
    transition:
      opacity .66s var(--premium-soft-ease),
      transform .78s var(--premium-ease),
      border-color .62s var(--premium-ease),
      box-shadow .62s var(--premium-ease) !important;
  }

  .premium-card:hover .premium-card-light {
    opacity: 1;
  }

  .premium-card:hover {
    box-shadow:
      0 22px 58px rgba(0, 0, 0, .33),
      0 0 0 1px rgba(61, 255, 194, .045),
      0 0 34px rgba(61, 255, 194, .035);
  }
}

/* Buttons keep their original colors but gain a tighter premium response. */
.btn,
button,
[role="button"] {
  backface-visibility: hidden;
  -webkit-font-smoothing: antialiased;
}

@media (hover: hover) and (pointer: fine) {
  .btn:hover {
    transform: translate3d(0, -2px, 0) !important;
    filter: saturate(1.05) brightness(1.025);
  }

  .btn:active {
    transform: translate3d(0, -1px, 0) scale(.985) !important;
    transition-duration: .12s !important;
  }
}

/* Mobile motion is shorter and never pushes content sideways. */
@media (max-width: 640px) and (prefers-reduced-motion: no-preference) {
  html.premium-motion-ready body .premium-reveal-group {
    opacity: .88 !important;
    transform: translate3d(0, 7px, 0) !important;
    transition-duration: .52s, .66s !important;
  }

  html.premium-motion-ready body .premium-reveal-group.premium-visible {
    transform: none !important;
    filter: none !important;
  }
}

/* Calm layout rhythm shared by the full public site. */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  line-height: 1.65;
}

.mobile-flow-label {
  display: none;
}

h1, h2, h3, .pr-title, .ct-title, .res-title {
  text-wrap: balance;
}

p, li {
  text-wrap: pretty;
}

.sd,
.sec > p,
.sec > .sd,
.pr-sub,
.ct-sub,
.res-sub {
  line-height: 1.72 !important;
}

@media (min-width: 769px) {
  .sec {
    padding-top: clamp(76px, 7.4vw, 104px) !important;
    padding-bottom: clamp(76px, 7.4vw, 104px) !important;
  }

  .sec[style*="padding-top:30px"] {
    padding-top: 58px !important;
  }

  .sec > .sd,
  .sec > p:not(.eyebrow) {
    max-width: 680px;
    margin-left: auto;
    margin-right: auto;
  }

  .prob,
  .diff,
  .mc,
  .af,
  .ti,
  .step,
  .qa,
  .pc,
  .pr-card,
  .resource-card,
  .aeo-guide {
    line-height: 1.68;
  }
}

@media (hover: hover) and (pointer: fine) {
  html.premium-motion-ready body .prob:hover,
  html.premium-motion-ready body .diff:hover,
  html.premium-motion-ready body .mc:hover,
  html.premium-motion-ready body .af:hover,
  html.premium-motion-ready body .ti:hover,
  html.premium-motion-ready body .step:hover,
  html.premium-motion-ready body .resource-card:hover,
  html.premium-motion-ready body .pr-card:not(.feat):hover {
    transform: translate3d(0, -3px, 0) !important;
  }

  /* Growth is gently raised at rest and moves only three more pixels on hover. */
  html.premium-motion-ready body .pr-card.feat {
    transform: translate3d(0, -6px, 0) !important;
  }

  html.premium-motion-ready body .pr-card.feat:hover {
    transform: translate3d(0, -9px, 0) !important;
  }
}

@media (max-width: 768px) {
  html {
    scroll-padding-top: 74px;
  }

  .sec {
    padding-top: 68px !important;
    padding-bottom: 68px !important;
  }

  .sd,
  .sec > p,
  .pr-sub,
  .ct-sub,
  .res-sub {
    line-height: 1.68 !important;
  }
}

/*
 * The desktop intake map is intentionally wide. On a phone it becomes a
 * calm, readable sequence instead of a compressed imitation of that map.
 */
@media (max-width: 640px) {
  .hr {
    margin-top: 34px !important;
    padding: 12px 10px 4px !important;
    border: 1px solid rgba(255, 255, 255, .065);
    border-radius: 24px;
    background:
      linear-gradient(180deg, rgba(61, 255, 194, .025), transparent 38%),
      rgba(8, 8, 13, .42);
    box-shadow:
      inset 0 1px 0 rgba(255, 255, 255, .025),
      0 24px 64px rgba(0, 0, 0, .2);
  }

  .hr::before {
    width: 300px !important;
    height: 300px !important;
    opacity: .72;
  }

  .hr::after {
    inset: 0 !important;
    opacity: .24 !important;
    border-radius: inherit;
  }

  .fv {
    gap: 0 !important;
  }

  .fcol {
    width: min(100%, 320px) !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    gap: 9px !important;
    padding-top: 31px;
    position: relative;
  }

  .fcol .fn {
    width: 100% !important;
    max-width: none !important;
    min-height: 66px;
    flex: 0 0 auto !important;
    padding: 12px 14px !important;
    border-radius: 13px;
    background: rgba(12, 12, 20, .76);
    backdrop-filter: blur(12px);
    animation: none !important;
    transform: none !important;
  }

  .fcol .fn:hover {
    transform: none !important;
  }

  .mobile-flow-label {
    display: block;
    width: 100%;
    margin: 0 0 3px;
    color: var(--text3);
    font-size: .58rem;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 1.8px;
    text-align: center;
    text-transform: uppercase;
    white-space: nowrap;
  }

  .fcol-in::after,
  .fcol-out::before {
    width: 1px !important;
    height: 34px !important;
    margin: 4px auto !important;
    background: linear-gradient(
      180deg,
      rgba(61, 255, 194, .12),
      rgba(61, 255, 194, .72),
      rgba(77, 138, 255, .18)
    ) !important;
    box-shadow: 0 0 12px rgba(61, 255, 194, .18);
  }

  .fcol-out::before {
    margin-top: 2px !important;
    margin-bottom: 8px !important;
  }

  .fhub {
    width: 164px !important;
    height: 164px !important;
    margin: 0 !important;
  }

  .fhub-core {
    width: 126px !important;
    height: 126px !important;
    box-shadow:
      0 0 34px rgba(61, 255, 194, .23),
      inset 0 0 18px rgba(61, 255, 194, .09) !important;
  }

  .fhub-ring.r3 {
    display: none;
  }

  .fhub-logo {
    font-size: 2.2rem !important;
  }

  .fhub-label {
    font-size: .52rem !important;
    letter-spacing: 1.8px !important;
  }

  .fhub-stat {
    font-size: .48rem !important;
  }

  .fi {
    width: 38px !important;
    height: 38px !important;
    min-width: 38px !important;
  }

  .ft {
    font-size: .8rem !important;
  }

  .fs2 {
    font-size: .64rem !important;
  }
}

/* The home hero keeps moving almost imperceptibly after its entrance. */
@keyframes premium-home-ambient {
  0%, 100% {
    opacity: .84;
    transform: translate3d(-7px, -2px, 0) scale(.99);
  }
  50% {
    opacity: .96;
    transform: translate3d(11px, 7px, 0) scale(1.025);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .home-page .hero::before {
    animation: premium-home-ambient 18s ease-in-out infinite !important;
    will-change: transform, opacity;
  }
}

/* Premium editorial treatment for the About page. */
.about-page {
  position: relative;
  background:
    radial-gradient(circle at 18% 8%, rgba(61, 255, 194, .025), transparent 28%),
    radial-gradient(circle at 84% 26%, rgba(77, 138, 255, .022), transparent 25%),
    var(--bg);
}

.about-page .wrap {
  max-width: 1180px;
}

.about-page .hero {
  max-width: 1040px;
  margin: 0 auto 78px;
  padding: 30px 34px 34px;
  isolation: isolate;
}

.about-page .hero::before {
  content: '';
  position: absolute;
  z-index: -1;
  top: -110px !important;
  left: 50% !important;
  width: min(860px, 90vw) !important;
  height: 560px !important;
  background:
    radial-gradient(circle at 50% 36%, rgba(61, 255, 194, .095), rgba(77, 138, 255, .035) 42%, transparent 70%) !important;
  filter: blur(34px) !important;
  opacity: .8 !important;
  transform: translateX(-50%) !important;
  animation: none !important;
  pointer-events: none;
}

.about-page .hero::after {
  content: '';
  position: absolute;
  z-index: -1;
  inset: auto 14% 0 !important;
  width: auto !important;
  height: 1px !important;
  background: linear-gradient(90deg, transparent, rgba(61, 255, 194, .55), rgba(77, 138, 255, .32), transparent) !important;
  filter: none !important;
  opacity: .7 !important;
  transform: none !important;
  animation: none !important;
  pointer-events: none;
}

.about-page .hero h1 {
  max-width: 940px;
  margin-left: auto;
  margin-right: auto;
  text-shadow: 0 18px 54px rgba(0, 0, 0, .42);
}

.about-page .hero .lede:first-of-type {
  max-width: 690px;
}

.about-page .hero .lede[data-d="3"] {
  max-width: 760px !important;
  margin: 28px auto 0 !important;
  padding: 17px 20px 17px 24px !important;
  border: 1px solid rgba(255, 255, 255, .075) !important;
  border-left: 2px solid rgba(61, 255, 194, .7) !important;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255, 255, 255, .03), rgba(61, 255, 194, .016));
  box-shadow: inset 0 1px rgba(255, 255, 255, .025), 0 18px 54px rgba(0, 0, 0, .18);
}

.about-page .fcard {
  max-width: 1020px;
  margin: 0 auto 34px;
  padding: 52px 48px;
  border-color: rgba(255, 255, 255, .095);
  background:
    radial-gradient(circle at 88% 8%, rgba(61, 255, 194, .07), transparent 28%),
    radial-gradient(circle at 10% 94%, rgba(77, 138, 255, .045), transparent 26%),
    linear-gradient(145deg, rgba(13, 13, 20, .98), rgba(7, 7, 11, .98));
  box-shadow:
    0 38px 110px rgba(0, 0, 0, .34),
    inset 0 1px rgba(255, 255, 255, .035);
}

.about-page .fcard::after {
  top: -150px;
  right: -110px;
  width: 430px;
  height: 430px;
  opacity: .8;
}

.about-page .favatar {
  width: 108px;
  height: 108px;
  min-width: 108px;
}

.about-page .fstats {
  gap: 10px;
  padding-top: 0;
  border-top: 0;
}

.about-page .fstat {
  min-height: 94px;
  padding: 17px 16px;
  border: 1px solid rgba(255, 255, 255, .065);
  border-radius: 12px;
  background: rgba(255, 255, 255, .018);
}

.about-page .fcard .fnote:last-child {
  padding: 18px 20px !important;
  border: 1px solid rgba(255, 255, 255, .055) !important;
  border-radius: 12px;
  background: rgba(255, 255, 255, .016);
}

.about-page .sec {
  max-width: 980px;
  margin: 0 auto !important;
  padding: 76px 0 !important;
}

.about-page .problem-section {
  max-width: 1020px;
  padding-top: 88px !important;
}

.about-page .problem-section .sec-h {
  max-width: 820px;
}

.about-page .vfig {
  margin-top: 44px;
  padding: 28px 26px 20px;
  border-color: rgba(255, 255, 255, .085);
  background:
    linear-gradient(160deg, rgba(255, 255, 255, .035), rgba(255, 255, 255, .008)),
    radial-gradient(circle at 50% 100%, rgba(61, 255, 194, .035), transparent 45%);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .22), inset 0 1px rgba(255, 255, 255, .025);
}

.about-page .pq {
  max-width: 860px;
  margin: 10px auto;
  padding: 62px 44px 58px;
  border-top: 1px solid rgba(255, 255, 255, .085);
  border-bottom: 1px solid rgba(255, 255, 255, .085);
}

.about-page .story-section,
.about-page .results-section {
  display: grid;
  grid-template-columns: minmax(0, .88fr) minmax(0, 1.12fr);
  gap: clamp(42px, 6vw, 76px);
  align-items: start;
}

.about-page .editorial-head .sec-h {
  margin-bottom: 0;
}

.about-page .editorial-copy {
  padding: 3px 0 3px 30px;
  border-left: 1px solid rgba(61, 255, 194, .18);
}

.about-page .editorial-copy p {
  color: var(--text2);
  font-size: .95rem;
  line-height: 1.78;
}

.about-page .editorial-copy p + p {
  margin-top: 18px;
}

.about-page .editorial-copy a {
  color: var(--mint);
  text-underline-offset: 3px;
}

.about-page .principles-section .sec-h,
.about-page .delivery-section .sec-h {
  max-width: 740px;
}

.about-page .princ {
  gap: 16px;
}

.about-page .princ-card {
  position: relative;
  overflow: hidden;
  min-height: 190px;
  padding: 28px 26px;
  border-color: rgba(255, 255, 255, .075);
  background: linear-gradient(155deg, rgba(14, 14, 21, .98), rgba(8, 8, 12, .98));
  box-shadow: inset 0 1px rgba(255, 255, 255, .025);
}

.about-page .princ-card::after {
  content: '';
  position: absolute;
  width: 170px;
  height: 170px;
  right: -80px;
  bottom: -100px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(61, 255, 194, .08), transparent 68%);
  opacity: 0;
  transition: opacity .5s var(--premium-soft-ease);
  pointer-events: none;
}

@media (hover: hover) and (pointer: fine) {
  .about-page .princ-card:hover::after {
    opacity: 1;
  }
}

.about-page .wyg {
  padding: 18px 30px;
  border-radius: 20px;
  border-color: rgba(255, 255, 255, .085);
  background:
    linear-gradient(145deg, rgba(13, 13, 20, .98), rgba(7, 7, 11, .98)),
    radial-gradient(circle at 100% 0%, rgba(77, 138, 255, .04), transparent 28%);
  box-shadow: 0 30px 82px rgba(0, 0, 0, .22), inset 0 1px rgba(255, 255, 255, .025);
}

.about-page .wyg-item {
  padding: 19px 10px;
  transition: background-color .4s var(--premium-soft-ease), padding .4s var(--premium-soft-ease);
}

.about-page .wyg-item:last-child {
  padding-bottom: 19px;
}

@media (hover: hover) and (pointer: fine) {
  .about-page .wyg-item:hover {
    padding-left: 16px;
    padding-right: 16px;
    border-radius: 12px;
    background: rgba(255, 255, 255, .018);
  }
}

.about-page .wnot {
  max-width: 900px;
  margin-top: 30px !important;
  padding: 34px 36px !important;
  border-color: rgba(255, 178, 55, .18);
  background: linear-gradient(145deg, rgba(255, 178, 55, .055), rgba(255, 178, 55, .018));
  box-shadow: 0 24px 70px rgba(0, 0, 0, .2);
}

.about-page .cta-box {
  max-width: 980px;
  margin: 66px auto 0;
  padding: 58px 40px;
  border-color: rgba(255, 255, 255, .095);
  background:
    radial-gradient(circle at 50% 0%, rgba(61, 255, 194, .08), transparent 42%),
    linear-gradient(145deg, rgba(13, 13, 20, .98), rgba(7, 7, 11, .98));
  box-shadow: 0 36px 100px rgba(0, 0, 0, .28), inset 0 1px rgba(255, 255, 255, .035);
}

@media (max-width: 768px) {
  .about-page .wrap {
    padding-left: 20px;
    padding-right: 20px;
  }

  .about-page .hero {
    margin-bottom: 52px;
    padding: 8px 0 30px;
  }

  .about-page .hero::after {
    inset-inline: 8% !important;
  }

  .about-page .hero .lede[data-d="3"] {
    padding: 16px 17px 16px 19px !important;
    font-size: .86rem !important;
  }

  .about-page .fcard {
    padding: 32px 22px;
    border-radius: 18px;
  }

  .about-page .favatar {
    width: 76px;
    height: 76px;
    min-width: 76px;
  }

  .about-page .fname {
    font-size: clamp(1.75rem, 9vw, 2.25rem);
  }

  .about-page .fstat {
    min-height: 88px;
    padding: 15px 13px;
  }

  .about-page .sec {
    padding: 58px 0 !important;
  }

  .about-page .problem-section {
    padding-top: 68px !important;
  }

  .about-page .story-section,
  .about-page .results-section {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .about-page .editorial-copy {
    padding: 26px 0 0;
    border-left: 0;
    border-top: 1px solid rgba(61, 255, 194, .16);
  }

  .about-page .pq {
    padding: 52px 18px 46px;
  }

  .about-page .princ-card {
    min-height: 0;
    padding: 24px 22px;
  }

  .about-page .wyg {
    padding: 10px 18px;
  }

  .about-page .wyg-item,
  .about-page .wyg-item:last-child {
    padding: 18px 0;
  }

  .about-page .wnot {
    padding: 28px 24px !important;
  }

  .about-page .cta-box {
    padding: 44px 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-page .hero::before {
    animation: none !important;
  }

  html body [data-r],
  html body .premium-reveal-group {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    animation: none !important;
    transition: none !important;
  }

  .premium-card-light {
    display: none !important;
  }
}
