/* SkillSync Infinity: enhancement layer, loaded after site.css.
   Adds motion and depth to the existing design without changing its fonts,
   colours or layout. Ported ideas: Aceternity UI (spotlight, moving border,
   glowing card edges, background beams, tracing beam), 21st.dev (dithered
   wordmark, spotlight comparison), Codrops-style clip-path image reveals.
   Everything is decoration: the page reads the same with it switched off. */

:root {
  --fx-orange: var(--orange, #ff8c1a);
  --fx-magenta: var(--magenta, #e0408f);
  --fx-violet: var(--violet, #8b3dff);
  --fx-brand: linear-gradient(90deg, var(--fx-orange), var(--fx-magenta), var(--fx-violet));
  --fx-ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* ---------- Hero: spotlight beams and the infinity ribbon ---------- */
.hero .fx-spot {
  position: absolute;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}
.hero .fx-spot span {
  position: absolute;
  top: -40%;
  width: 46%;
  height: 160%;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
  animation: fx-sway 9s ease-in-out infinite alternate;
}
.hero .fx-spot span:nth-child(1) {
  left: -8%;
  transform: rotate(-28deg);
  background: radial-gradient(closest-side, rgb(255 140 26 / 0.22), transparent);
}
.hero .fx-spot span:nth-child(2) {
  right: -6%;
  transform: rotate(28deg);
  background: radial-gradient(closest-side, rgb(139 61 255 / 0.28), transparent);
  animation-delay: -4s;
}
.hero .fx-spot span:nth-child(3) {
  left: 34%;
  width: 30%;
  background: radial-gradient(closest-side, rgb(224 64 143 / 0.16), transparent);
  animation-duration: 12s;
}
@keyframes fx-sway {
  to {
    translate: 6% 0;
  }
}
.hero .fx-ribbon {
  position: absolute;
  left: 50%;
  bottom: -26%;
  z-index: -1;
  width: min(1500px, 140%);
  translate: -50% 0;
  pointer-events: none;
  opacity: 0.9;
}
.fx-ribbon .base {
  opacity: 0.18;
}
.fx-ribbon .spark {
  opacity: 0.65;
  stroke-dasharray: 110 3110;
  animation: fx-travel 9s linear infinite;
}
@keyframes fx-travel {
  from {
    stroke-dashoffset: 3220;
  }
  to {
    stroke-dashoffset: 0;
  }
}

/* Moving border on the hero's primary button (a light runs round its edge). */
@property --fx-angle {
  syntax: '<angle>';
  initial-value: 0deg;
  inherits: false;
}
.hero .btn-primary.fx-border {
  position: relative;
  isolation: isolate;
}
.hero .btn-primary.fx-border::before {
  content: '';
  position: absolute;
  inset: -2px;
  z-index: -1;
  border-radius: inherit;
  background: conic-gradient(from var(--fx-angle), transparent 0 70%, var(--fx-orange) 80%, #fff 85%, transparent 92%);
  animation: fx-spin 3.6s linear infinite;
}
@keyframes fx-spin {
  to {
    --fx-angle: 360deg;
  }
}

/* ---------- Cards: a light that follows the pointer along the edge ---------- */
.fx-glow {
  position: relative;
}
.fx-glow::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.5px;
  background: radial-gradient(220px circle at var(--fx-x, 50%) var(--fx-y, 0%), var(--fx-orange), var(--fx-magenta) 35%, var(--fx-violet) 55%, transparent 70%);
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.fx-glow:hover::after,
.fx-glow:focus-visible::after {
  opacity: 1;
}

/* ---------- Dark sections: slow background beams ---------- */
.bg-ink {
  position: relative;
  isolation: isolate;
  overflow: hidden;
}
.bg-ink > .fx-beams {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
  opacity: 0.55;
}
.fx-beams path {
  fill: none;
  stroke-width: 1;
}
.fx-beams .track {
  stroke: rgb(255 255 255 / 0.05);
}
.fx-beams .beam {
  stroke: url(#fx-beam-g);
  stroke-width: 1.4;
  stroke-dasharray: 140 1400;
  animation: fx-beam 11s linear infinite;
}
.fx-beams .beam:nth-of-type(2n) {
  animation-duration: 14s;
  animation-delay: -5s;
}
.fx-beams .beam:nth-of-type(3n) {
  animation-duration: 17s;
  animation-delay: -9s;
}
@keyframes fx-beam {
  from {
    stroke-dashoffset: 1540;
  }
  to {
    stroke-dashoffset: 0;
  }
}

/* ---------- How the programs work: a beam fills as you scroll ---------- */
.steps.fx-traced {
  position: relative;
}
.fx-trace {
  position: absolute;
  left: 0;
  right: 0;
  top: -18px;
  height: 2px;
  border-radius: 2px;
  background: rgb(255 255 255 / 0.1);
  overflow: hidden;
}
.fx-trace i {
  position: absolute;
  inset: 0;
  background: var(--fx-brand);
  transform-origin: left;
  transform: scaleX(1);
}

/* ---------- Proof: certificates and the team ---------- */
.fx-proof .cert-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.fx-proof .cert-row a {
  display: block;
  color: #fff;
  text-decoration: none;
}
.fx-proof .cert-row figure {
  margin: 0;
  overflow: hidden;
  border-radius: var(--radius-sm, 12px);
  background: #fff;
  box-shadow: 0 24px 48px -28px rgb(0 0 0 / 0.7);
}
.fx-proof .cert-row img {
  aspect-ratio: 1.414;
  width: 100%;
  object-fit: cover;
}
.fx-proof .cert-row b {
  display: block;
  margin-top: 12px;
  font-weight: 600;
}
.fx-proof .cert-row small {
  color: #b9b2cf;
  font-variant-numeric: tabular-nums;
}
.fx-proof .proof-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}
.fx-team {
  margin-top: clamp(40px, 6vw, 64px);
  padding-top: clamp(28px, 4vw, 40px);
  border-top: 1px solid rgb(255 255 255 / 0.1);
}
.fx-team ul {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px 28px;
}
.fx-team li {
  display: flex;
  align-items: center;
  gap: 14px;
}
.fx-team img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 0 0 2px rgb(255 255 255 / 0.12);
}
.fx-team b {
  display: block;
  color: #fff;
  white-space: nowrap;
}
.fx-team span {
  color: #b9b2cf;
  font-size: 0.92rem;
}
@media (max-width: 900px) {
  .fx-proof .proof-grid {
    grid-template-columns: 1fr;
  }
  .fx-team ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 560px) {
  .fx-proof .cert-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .fx-proof .cert-row a:nth-child(3) {
    display: none;
  }
  .fx-team ul {
    grid-template-columns: 1fr;
  }
}

/* ---------- Comparison table: the hovered or chosen program column lights up ---------- */
.table.fx-compare td,
.table.fx-compare th {
  transition: background-color 0.3s var(--fx-ease);
}
.table.fx-compare .fx-col {
  background: var(--violet-soft, #f1eaff);
}
.table.fx-compare thead .fx-col {
  box-shadow: inset 0 3px 0 0 var(--fx-violet);
}

/* ---------- Footer: brand name cut out of a field of gradient dots ---------- */
.fx-wordmark {
  position: relative;
  height: clamp(120px, 18vw, 230px);
  margin-top: 28px;
  overflow: hidden;
}
.fx-wordmark .dots {
  position: absolute;
  inset: 0 -360px 0 0;
  background: var(--fx-brand);
  -webkit-mask-image: radial-gradient(circle, #000 0.9px, transparent 1.3px), linear-gradient(180deg, transparent 0%, #000 100%);
  mask-image: radial-gradient(circle, #000 0.9px, transparent 1.3px), linear-gradient(180deg, transparent 0%, #000 100%);
  -webkit-mask-size: 5px 5px, 100% 100%;
  mask-size: 5px 5px, 100% 100%;
  -webkit-mask-composite: source-in;
  mask-composite: intersect;
  opacity: 0.7;
  animation: fx-drift 40s linear infinite;
}
@keyframes fx-drift {
  to {
    translate: -360px 0;
  }
}
.fx-wordmark .mark {
  position: absolute;
  left: 0;
  bottom: -0.08em;
  margin: 0;
  font-family: var(--serif);
  font-weight: 700;
  font-size: clamp(4.5rem, 17vw, 13rem);
  line-height: 0.85;
  letter-spacing: -0.03em;
  color: var(--ink, #0e0b1f);
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}

/* ---------- Photos uncover as they scroll in (set by enhance.js) ---------- */
.fx-clip {
  will-change: clip-path;
}

/* ---------- Reduced motion: keep every final state, drop the movement ---------- */
@media (prefers-reduced-motion: reduce) {
  .hero .fx-spot span,
  .fx-ribbon .spark,
  .hero .btn-primary.fx-border::before,
  .fx-beams .beam,
  .fx-wordmark .dots {
    animation: none !important;
  }
  .fx-ribbon .spark,
  .fx-beams .beam {
    display: none;
  }
  .fx-clip {
    will-change: auto;
  }
}

/* ---------- Logo lockup ---------- */
.brand .brand-logo { height: 48px; width: auto; }
.foot-brand .foot-logo { width: auto; height: 52px; background: none; padding: 0; border-radius: 0; }
@media (max-width: 680px) { .brand .brand-logo { height: 40px; } }

/* ---------- Tools chips, FAQ, blog and audience cards ---------- */
.tools span { transition: transform 0.25s var(--fx-ease), box-shadow 0.25s var(--fx-ease), border-color 0.25s, color 0.25s; }
.tools span:hover { transform: translateY(-3px); border-color: transparent; color: var(--fx-violet);
  box-shadow: 0 0 0 1.5px var(--fx-violet), 0 12px 24px -12px rgb(139 61 255 / 0.5); }
.acc summary { transition: color 0.2s; }
.acc summary:hover { color: var(--fx-violet); }
.acc summary::after { transition: transform 0.35s var(--fx-ease), background 0.25s, color 0.25s; }
.acc details[open] summary::after { transform: translateY(-50%) rotate(180deg); }
.acc details { transition: background-color 0.3s; border-radius: 12px; }
.acc details[open] { background: color-mix(in srgb, var(--violet-soft, #f1eaff) 45%, transparent); }
.acc .a { overflow: hidden; }
.post-card, .persona { transition: transform 0.3s var(--fx-ease), box-shadow 0.3s var(--fx-ease); }
.post-card img, .persona img { transition: transform 0.8s var(--fx-ease); }
.post-card:hover, .persona:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.post-card:hover img, .persona:hover img { transform: scale(1.05); }
.post-card, .persona { overflow: hidden; }
.link-arrow { transition: gap 0.25s var(--fx-ease); }
@media (prefers-reduced-motion: reduce) {
  .tools span, .tools span:hover, .post-card, .persona, .post-card:hover, .persona:hover,
  .post-card img, .persona img, .post-card:hover img, .persona:hover img, .acc summary::after { transform: none !important; transition: none !important; }
}

/* ---------- Programs menu: nested dropdown by category ---------- */
.has-mega {
  position: relative;
}
.menu .mega-link {
  display: flex;
  align-items: center;
  gap: 6px;
}
.has-mega .chev {
  width: 16px;
  height: 16px;
  flex: none;
  transition: transform 0.25s var(--fx-ease);
}
.mega-cats,
.mega-sub {
  list-style: none;
  margin: 0;
  padding: 0;
}
.mega-cat-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 0;
  border-radius: 12px;
  background: none;
  font: 600 0.96rem/1.3 var(--sans);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.mega-cat-btn:hover,
.mega-cat.is-open > .mega-cat-btn {
  background: var(--violet-soft);
  color: var(--violet);
}
.menu .mega-sub a {
  display: block;
  padding: 12px 14px;
  border-radius: 12px;
  background: none;
  color: var(--text);
  font-weight: 400;
}
.menu .mega-sub a:hover,
.menu .mega-sub a:focus-visible {
  background: var(--cream);
  color: var(--text);
}
.mega-sub b {
  display: block;
  font-weight: 600;
  font-size: 0.96rem;
}
.mega-sub a:hover b {
  color: var(--violet);
}
.mega-sub small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 0.85rem;
}
.menu .mega-all {
  display: block;
  margin-top: 8px;
  padding: 14px;
  border-top: 1px solid var(--line);
  border-radius: 0 0 12px 12px;
  color: var(--violet);
  font-weight: 600;
  background: none;
}
.menu .mega-all:hover {
  background: var(--violet-soft);
}

/* Desktop: hover, focus or a click opens the panel; categories fly out to the right. */
@media (min-width: 1081px) {
  .mega {
    position: absolute;
    top: calc(100% + 12px);
    left: -16px;
    z-index: 60;
    width: 620px;
    min-height: 280px;
    padding: 12px;
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    align-content: start;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 20px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    translate: 0 8px;
    transition:
      opacity 0.2s ease,
      translate 0.25s var(--fx-ease),
      visibility 0s linear 0.2s;
  }
  /* Bridge the gap so the panel stays open while the pointer travels to it. */
  .mega::before {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    top: -14px;
    height: 14px;
  }
  .has-mega:hover > .mega,
  .has-mega:focus-within > .mega,
  .has-mega.open > .mega {
    opacity: 1;
    visibility: visible;
    translate: 0 0;
    transition:
      opacity 0.2s ease,
      translate 0.25s var(--fx-ease),
      visibility 0s;
  }
  /* Escape closes the panel while keeping focus on Programs. */
  .has-mega.hush > .mega {
    opacity: 0 !important;
    visibility: hidden !important;
  }
  .has-mega:hover > .mega-link .chev,
  .has-mega:focus-within > .mega-link .chev,
  .has-mega.open > .mega-link .chev {
    transform: rotate(180deg);
  }
  .mega-cats {
    grid-column: 1;
  }
  .mega-cat-btn .chev {
    transform: rotate(-90deg);
  }
  .mega-sub {
    position: absolute;
    top: 12px;
    left: 244px;
    right: 12px;
    padding-left: 16px;
    border-left: 1px solid var(--line);
    display: none;
  }
  .mega-cat.is-open > .mega-sub,
  .mega-cat:hover > .mega-sub,
  .mega-cat:focus-within > .mega-sub {
    display: block;
    animation: fx-sub-in 0.25s var(--fx-ease);
  }
  .mega-cats:hover > .mega-cat.is-open:not(:hover) > .mega-sub {
    display: none;
  }
  /* Long lists (Weekend Skill Sprints) sit in two columns so the panel stays compact. */
  .mega:has(.mega-sub > li:nth-child(6)) {
    width: 760px;
  }
  .mega-cat.is-open > .mega-sub:has(> li:nth-child(6)),
  .mega-cat:hover > .mega-sub:has(> li:nth-child(6)) {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 4px;
  }
  .mega-all {
    grid-column: 1 / -1;
    align-self: end;
  }
}
@keyframes fx-sub-in {
  from {
    opacity: 0;
    translate: 6px 0;
  }
}

/* Phones and tablets: inside the menu panel, Programs and each category expand in place. */
@media (max-width: 1080px) {
  .nav-open .menu {
    max-height: calc(100vh - 66px);
    overflow-y: auto;
  }
  .mega {
    display: none;
    padding: 4px 0 8px 10px;
  }
  .has-mega.open > .mega {
    display: block;
  }
  .has-mega.open > .mega-link .chev {
    transform: rotate(180deg);
  }
  .menu .mega-link {
    justify-content: space-between;
  }
  .mega-cat-btn {
    padding: 14px 16px;
    font-size: 1rem;
  }
  .mega-cat.is-open > .mega-cat-btn .chev {
    transform: rotate(180deg);
  }
  .mega-sub {
    display: none;
    padding-left: 10px;
  }
  .mega-cat.is-open > .mega-sub {
    display: block;
  }
}
@media (prefers-reduced-motion: reduce) {
  .mega,
  .has-mega .chev {
    transition: none !important;
  }
  .mega-sub {
    animation: none !important;
  }
}

/* ---------- Weekend Skill Sprints cards ---------- */
a.sprint-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  transition: transform 0.3s var(--fx-ease), box-shadow 0.3s var(--fx-ease);
}
a.sprint-card h3 {
  margin: 0;
}
a.sprint-card p {
  margin: 0;
  color: var(--muted);
}
a.sprint-card .meta-row {
  flex-wrap: wrap;
}
a.sprint-card .link-arrow {
  margin-top: auto;
  padding-top: 6px;
}
a.sprint-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}
.sprint-grid {
  align-items: stretch;
}
@media (prefers-reduced-motion: reduce) {
  a.sprint-card,
  a.sprint-card:hover {
    transform: none !important;
    transition: none !important;
  }
}

/* ---------- Typeset: even heading lines, no lone last words, aligned figures ---------- */
h1,
h2,
h3 {
  text-wrap: balance;
}
p,
li {
  text-wrap: pretty;
}
.price b,
.facts b,
.price-card .big,
.sprint-from b {
  font-variant-numeric: tabular-nums;
}

/* ---------- Polish: hover text meets 4.5:1 on the light violet surface ---------- */
.mega-cat-btn:hover,
.mega-cat.is-open > .mega-cat-btn,
.menu .mega-all,
.mega-sub a:hover b,
.tools span:hover {
  color: var(--violet-ink, #6a2be0);
}
.tools span:hover {
  box-shadow: 0 0 0 1.5px var(--violet-ink, #6a2be0), 0 12px 24px -12px rgb(106 43 224 / 0.5);
}
/* Harden: long program names wrap instead of overflowing the panel. */
.mega-sub b,
.mega-sub small {
  white-space: normal;
  overflow-wrap: anywhere;
}

/* ---------- Colorize: each sprint group carries one brand hue ---------- */
.sprint-card .icon {
  flex: none;
  align-self: flex-start;
  width: 48px;
  height: 48px;
  margin-bottom: 6px;
  border-radius: 14px;
}
.sprint-grid > .sprint-card:nth-child(4n + 1) .icon {
  background: #fff1e4;
  color: #c95a06;
}
.sprint-grid > .sprint-card:nth-child(4n + 2) .icon {
  background: #fde8f2;
  color: #b8266e;
}
.sprint-grid > .sprint-card:nth-child(4n + 3) .icon {
  background: var(--violet-soft, #f1eaff);
  color: var(--violet-ink, #6a2be0);
}
.sprint-grid > .sprint-card:nth-child(4n + 4) .icon {
  background: #e8efff;
  color: #2a5bd7;
}
/* The eighth slot: a help card on ink, so the grid reads complete. */
a.sprint-card.sprint-ask {
  background: var(--ink, #0e0b1f);
  border-color: transparent;
  color: #fff;
}
a.sprint-card.sprint-ask p {
  color: #cfc8e4;
}
a.sprint-card.sprint-ask .icon {
  background: rgb(255 255 255 / 0.1) !important;
  color: #ffa94d !important;
}
a.sprint-card.sprint-ask .link-arrow {
  color: #ffa94d;
}

/* ---------- Bolder: the starting fee as a badge ---------- */
.fx-sprints .head-row {
  align-items: flex-end;
}
.sprint-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
}
.sprint-from {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.sprint-from b {
  font-family: var(--serif);
  font-size: 1.6rem;
  line-height: 1;
  color: var(--ink, #0e0b1f);
}
.sprint-from small {
  color: var(--muted);
  font-size: 0.85rem;
}
@media (max-width: 900px) {
  .sprint-side {
    align-items: flex-start;
  }
}

/* ---------- Onboard: a second, lighter first step on the student card ---------- */
.persona .persona-alt {
  display: block;
  margin-top: 8px;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--muted);
}

/* ---------- Delight: button arrows nudge, the WhatsApp button eases in ---------- */
.btn svg {
  transition: transform 0.25s var(--fx-ease);
}
.btn:hover svg {
  transform: translateX(3px);
}
@media (prefers-reduced-motion: no-preference) {
  .wa-float {
    animation: fx-pop-in 0.6s var(--fx-ease) 1.2s both;
  }
}
@keyframes fx-pop-in {
  from {
    opacity: 0;
    scale: 0.6;
  }
}
@media (prefers-reduced-motion: reduce) {
  .btn:hover svg {
    transform: none;
  }
}

/* Icon sits beside the group name rather than stacked above it. */
a.sprint-card {
  display: grid;
  grid-template-columns: 48px minmax(0, 1fr);
  column-gap: 14px;
  row-gap: 10px;
  grid-template-rows: auto auto auto 1fr;
}
a.sprint-card > .icon {
  grid-column: 1;
  align-self: center;
  margin: 0;
}
a.sprint-card > h3 {
  grid-column: 2;
  align-self: center;
}
a.sprint-card > p,
a.sprint-card > .meta-row,
a.sprint-card > .link-arrow {
  grid-column: 1 / -1;
}
a.sprint-card > .link-arrow {
  align-self: end;
}

/* ---------- Arrow links: one arrow, sized, and a drawn underline on hover ---------- */
.link-arrow {
  position: relative;
  text-decoration: none;
  background-image: linear-gradient(currentColor, currentColor);
  background-repeat: no-repeat;
  background-position: 0 100%;
  background-size: 0% 1.5px;
  padding-bottom: 2px;
  transition:
    background-size 0.35s var(--fx-ease),
    color 0.2s ease;
}
.link-arrow:hover,
.link-arrow:focus-visible {
  background-size: 100% 1.5px;
}
.link-arrow svg {
  width: 18px;
  height: 18px;
  flex: none;
  transition: transform 0.35s var(--fx-ease);
}
/* A link that already carries an arrow icon does not get a second one. */
.link-arrow:has(svg)::after {
  content: none;
}
.link-arrow::after {
  transition: transform 0.35s var(--fx-ease);
}
.link-arrow:hover::after,
.link-arrow:hover svg {
  transform: translateX(5px);
}

/* ---------- Buttons and cards: press feedback and one shared easing ---------- */
.btn {
  transition:
    transform 0.25s var(--fx-ease),
    box-shadow 0.25s var(--fx-ease),
    background-position 0.5s ease,
    background-color 0.2s ease,
    color 0.2s ease;
}
.btn:hover {
  transform: translateY(-2px);
}
.btn:active {
  transform: translateY(0) scale(0.97);
  transition-duration: 0.08s;
}
.btn-primary {
  background-size: 200% 100%;
}
.btn-primary:hover {
  background-position: 100% 0;
}
.course,
.card,
.post-card,
.persona,
.step {
  transition:
    transform 0.35s var(--fx-ease),
    box-shadow 0.35s var(--fx-ease),
    border-color 0.25s ease;
}
.course:active,
a.card:active,
.post-card:active,
a.sprint-card:active {
  transform: scale(0.985);
  transition-duration: 0.08s;
}

/* ---------- Page transitions: pages cross-fade, the header stays put ---------- */
@view-transition {
  navigation: auto;
}
.site-header {
  view-transition-name: site-header;
}
.topbar {
  view-transition-name: site-topbar;
}
::view-transition-old(root) {
  animation: fx-page-out 0.22s ease both;
}
::view-transition-new(root) {
  animation: fx-page-in 0.38s var(--fx-ease) both;
}
@keyframes fx-page-out {
  to {
    opacity: 0;
    translate: 0 -8px;
  }
}
@keyframes fx-page-in {
  from {
    opacity: 0;
    translate: 0 12px;
  }
}

@media (prefers-reduced-motion: reduce) {
  @view-transition {
    navigation: none;
  }
  .link-arrow,
  .link-arrow svg,
  .link-arrow::after,
  .btn,
  .course,
  .card,
  .post-card,
  .persona,
  .step {
    transition: none !important;
  }
  .link-arrow:hover::after,
  .link-arrow:hover svg,
  .btn:hover,
  .btn:active,
  .course:active,
  a.card:active,
  .post-card:active,
  a.sprint-card:active {
    transform: none !important;
  }
}
