.reading-progress {
  position: fixed;
  z-index: 5;
  inset: 0 0 auto;
  height: 2px;
  background: #9da46b;
  transform: scaleX(0);
  transform-origin: left;
  pointer-events: none;
}
.sticky-contact {
  position: fixed;
  z-index: 4;
  inset: auto 14px max(14px, env(safe-area-inset-bottom));
  width: fit-content;
  max-width: calc(100% - 28px);
  margin-inline: auto;
  display: flex;
  align-items: center;
  gap: clamp(7px, 2vw, 17px);
  padding: 7px 8px 7px 15px;
  border: 1px solid #555d39;
  border-radius: 9px;
  background: var(--dark);
  color: var(--white);
  box-shadow: 0 5px 26px #20231428;
  visibility: hidden;
  opacity: 0;
  transform: translateY(12px);
  font-size: .82rem;
  line-height: 1.2;
}
.sticky-contact.is-visible { visibility: visible; opacity: 1; transform: none; }
.sticky-contact a {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  gap: 5px;
  min-height: 36px;
  padding: 7px 10px;
  border-radius: 5px;
  background: var(--lime);
  color: var(--ink);
  font-weight: 730;
  text-decoration: none;
}
.sticky-contact a:hover { background: #f3f4cf; }
.sticky-contact a:focus-visible { outline-color: var(--lime); }
.sticky-contact button {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: inherit;
  cursor: pointer;
  font-size: 1.22rem;
}
.sticky-contact button:hover { background: #ffffff18; }
.count-description {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

@media (prefers-reduced-motion: no-preference) {
  .hero-copy > *, .mentor-figure { animation: arrival .62s cubic-bezier(.18,.75,.32,1) both; }
  .hero-copy h1 { animation-delay: 70ms; }
  .hero-description { animation-delay: 150ms; }
  .hero-actions { animation-delay: 220ms; }
  .mentor-figure { animation-delay: 115ms; }
  .hero-copy h1 span { animation: headline-arrival .69s cubic-bezier(.18,.75,.32,1) 120ms both; }
  @keyframes arrival {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
  }
  @keyframes headline-arrival {
    from { clip-path: inset(0 0 100%); transform: translateY(9px); }
    to { clip-path: inset(0 0 -18%); transform: none; }
  }

  .motion-pending { opacity: 0; transform: translateY(19px); }
  .motion-arrived { animation: arrival .59s cubic-bezier(.18,.75,.32,1) var(--motion-delay, 0ms) both; }
  .motion-pending:focus-within { opacity: 1; transform: none; animation: none; }
  .record { animation: record-highlight .85s ease-out .52s both; }
  @keyframes record-highlight {
    from { box-shadow: 0 0 0 0 #e4e8ad88; }
    to { box-shadow: 0 0 0 9px #e4e8ad00; }
  }
  .is-enhanced .review-viewport { transition: height .28s cubic-bezier(.2,.72,.28,1); }
  .review-details[open] .review-embed { animation: arrival .3s ease-out both; }
  .review-dots button::before { transition: width .24s ease, background .24s ease; }
  .review-arrow, .review-rotation { transition: background .2s, color .2s, border-color .2s, scale .2s; }
  .review-arrow:hover:not([aria-disabled="true"]) { scale: 1.06; }
  .sticky-contact { transition: transform .3s ease, opacity .3s ease, visibility .3s; }
  .demo-panel:not([hidden]) { animation: arrival .25s ease-out both; }

  @media (pointer: coarse) {
    .review-carousel.motion-arrived [data-review-step="1"]:not([aria-disabled="true"]) {
      animation: next-review-hint .65s ease-in-out .65s 2;
    }
    @keyframes next-review-hint { 50% { transform: translateX(4px); } }
  }

  @supports (animation-timeline: view()) {
    .mentor-image img {
      animation: mentor-parallax linear both;
      animation-timeline: view();
      animation-range: entry 0% exit 100%;
    }
    @keyframes mentor-parallax {
      from { object-position: center 20%; }
      to { object-position: center 48%; }
    }
  }

  @media (hover: hover) and (pointer: fine) {
    .button-primary, .button-lime {
      position: relative;
      overflow: hidden;
      transform: translate(var(--magnet-x, 0px), var(--magnet-y, 0px));
      transition: background-color .2s ease, transform .19s ease-out;
    }
    .button-primary::after, .button-lime::after, .review-outcome::after {
      position: absolute;
      inset: 0;
      content: "";
      pointer-events: none;
      background: linear-gradient(110deg, transparent 24%, #fff3 48%, transparent 72%);
      transform: translateX(-105%);
    }
    .button-primary:hover::after, .button-lime:hover::after,
    .review-outcome:hover::after { animation: sweep .64s ease-out; }
    @keyframes sweep { to { transform: translateX(105%); } }
    .review-outcome { position: relative; overflow: hidden; }
    .button span, .text-link span, .review-details summary span span {
      display: inline-block;
      transition: transform .22s ease;
    }
    .button:hover span, .text-link:hover span { transform: translate(2px, -2px); }
    .review-details summary:hover span span { transform: translateY(2px); }
    .review-details[open] summary:hover span span { transform: translateY(-2px); }
    .track { transition: transform .28s ease, box-shadow .28s ease; }
    .track:hover { transform: translateY(-4px); box-shadow: 0 12px 30px #31372214; }
  }
}

/* A brief brand greeting, independent of network requests or JavaScript. */
.brand-intro { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .brand-intro {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    background: var(--paper);
    pointer-events: none;
    animation: intro-away .5s cubic-bezier(.4,0,.2,1) 1s both;
  }
  .brand-intro-lockup { display: grid; justify-items: center; gap: 20px; }
  .intro-mark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 104px;
    border-radius: 20px;
    padding-bottom: 8px;
    font-size: 3.2rem;
    box-shadow: 0 15px 40px #31372212;
    animation: intro-mark-in .65s cubic-bezier(.16,1,.3,1) both;
  }
  .intro-mark span { animation: intro-letter-in .45s cubic-bezier(.16,1,.3,1) .12s both; }
  .intro-mark span + span { animation-delay: .22s; }
  .intro-mark::after {
    inset: auto 25px 18px;
    height: 4px;
    border-radius: 2px;
    background: var(--lime);
    transform-origin: left;
    animation: intro-line .55s cubic-bezier(.65,0,.35,1) .3s both;
  }
  .intro-name {
    color: var(--olive);
    font: 500 .73rem/1.4 var(--mono);
    letter-spacing: .23em;
    animation: intro-letter-in .45s ease-out .3s both;
  }
  @keyframes intro-mark-in {
    from { opacity: 0; transform: translateY(12px) scale(.88); }
    to { opacity: 1; transform: none; }
  }
  @keyframes intro-letter-in {
    from { opacity: 0; transform: translateY(7px); }
    to { opacity: 1; transform: none; }
  }
  @keyframes intro-line { from { transform: scaleX(0); } to { transform: scaleX(1); } }
  @keyframes intro-away {
    to { opacity: 0; visibility: hidden; }
  }
  .hero-copy > *, .mentor-figure { animation-delay: 1.05s; }
  .hero-copy h1 { animation-delay: 1.12s; }
  .hero-copy h1 span { animation-delay: 1.17s; }
  .hero-description { animation-delay: 1.2s; }
  .hero-actions { animation-delay: 1.27s; }
  .record { animation-delay: 1.55s; }
  /* Keyboard navigation always takes precedence over the decorative intro. */
  body:has(:focus-visible) .brand-intro { display: none; }
}
