/* Front door effects (T38): "Quote explode" and the "Quote-card strip".
   Every rule is namespaced .fx-*. Colours come from the site tokens in styles.css (the fallbacks keep it
   readable on its own). Motion is transform and opacity only, and nothing moves with
   prefers-reduced-motion: both effects have static layouts that need no script.

   Layout modes (effects.js picks the same ones with matchMedia):
     explode  stacked under 900px wide; a static exploded diagram from 900px; pinned and scroll-driven
              from 900 x 600 when scripts run (html.js) and motion is allowed.
     strip    a wrapped grid by default; one slow moving row when scripts run and motion is allowed. */

:root {
  --fx-s-a: #EEF3FD; --fx-s-b: #F3EFFB; --fx-s-c: #FDF1E9; --fx-s-d: #EAF7F0; /* strip panel gradient */
  --fx-card: var(--surface, #FFFFFF);
  --fx-card-shadow: 0 1px 2px rgba(11, 15, 25, .05), 0 18px 40px -18px rgba(11, 15, 25, .30);
  --fx-ring-a: #16A34A; --fx-ring-b: #4ADE80; --fx-ring-c: #2DD4BF;
  --fx-ring-base: rgba(22, 163, 74, .30);
  --fx-glow: .5;
  --fx-veil: rgba(8, 9, 12, 0);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-mode="light"]) {
    --fx-s-a: #111A27; --fx-s-b: #17152A; --fx-s-c: #1E1712; --fx-s-d: #0F1C16;
    --fx-card: var(--surface-2, #181C23);
    --fx-card-shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 18px 40px -18px rgba(0, 0, 0, .85);
    --fx-ring-base: rgba(74, 222, 128, .28);
    --fx-glow: .62;
    --fx-veil: rgba(8, 9, 12, .14);
  }
}
:root[data-mode="dark"] {
  --fx-s-a: #111A27; --fx-s-b: #17152A; --fx-s-c: #1E1712; --fx-s-d: #0F1C16;
  --fx-card: var(--surface-2, #181C23);
  --fx-card-shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 18px 40px -18px rgba(0, 0, 0, .85);
  --fx-ring-base: rgba(74, 222, 128, .28);
  --fx-glow: .62;
  --fx-veil: rgba(8, 9, 12, .14);
}

.fx-sr {
  position: absolute !important;
  width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Status pills (same colours as the site's chips) */
.fx-pill {
  display: inline-flex; align-items: center; gap: 6px; flex: none;
  min-height: 24px; padding: 2px 10px;
  border-radius: 999px;
  font-size: .75rem; font-weight: 650; line-height: 1.2; white-space: nowrap;
}
.fx-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.fx-pill-sent { background: var(--c-sent-bg, #EAF1FF); color: var(--c-sent, #1D4ED8); }
.fx-pill-opened { background: var(--c-opened-bg, #FEF3C7); color: var(--c-opened, #92400E); }
.fx-pill-accepted { background: var(--c-accepted-bg, #DCFCE7); color: var(--c-accepted, #166534); }
.fx-pill-sched { background: var(--c-sched-bg, #EFEDFB); color: var(--c-sched, #5B44B8); }


/* ======================================================================================
   1. Quote explode
   ====================================================================================== */

.fx-explode {
  --fx-pw: min(272px, 74vw);
  --fx-ph: calc(var(--fx-pw) * 2.04);
  padding: 6px var(--gutter, 16px);
  scroll-margin-top: 96px;
}
.fx-x-panel {
  max-width: calc(var(--wrap, 1160px) + 160px);
  margin: 0 auto;
  padding: 72px 20px 80px;
  border-radius: var(--radius-panel, 32px);
  background: var(--surface, #FFFFFF);
  border: 1px solid var(--hairline, rgba(11, 15, 25, .08));
}
.fx-x-head { max-width: 760px; margin: 0 auto; text-align: center; }
.fx-x-title { margin-top: 20px; }
.fx-x-intro { margin: 20px auto 0; max-width: 600px; color: var(--muted, #555D6B); font-size: 1.125rem; line-height: 1.6; }
.fx-x-caps, .fx-x-progress { display: none; }

.fx-x-stage { position: relative; display: grid; justify-items: center; margin-top: 48px; }
.fx-x-glow {
  position: absolute; z-index: 0; pointer-events: none;
  left: 50%; top: 0; width: calc(var(--fx-pw) * 2.6); max-width: 100vw; height: calc(var(--fx-ph) + 40px);
  transform: translateX(-50%);
  background:
    radial-gradient(closest-side at 40% 42%, rgba(59, 130, 246, .10), transparent),
    radial-gradient(closest-side at 62% 60%, rgba(20, 184, 166, .10), transparent),
    radial-gradient(closest-side at 50% 28%, rgba(139, 92, 246, .08), transparent);
}

/* ---------- The phone (decorative; the real content is the list of parts) ---------- */

.fx-phone {
  position: relative; z-index: 1;
  width: var(--fx-pw); height: var(--fx-ph);
  padding: calc(var(--fx-ph) * .016);
  border-radius: calc(var(--fx-ph) * .074);
  background: #0B0F19;
  box-shadow: var(--shadow-lg, 0 40px 80px -24px rgba(11, 15, 25, .22)), inset 0 0 0 1px #2A3340, 0 0 0 1px rgba(255, 255, 255, .06);
}
.fx-phone-badge { position: absolute; top: -12px; right: -10px; z-index: 3; box-shadow: var(--shadow-sm, 0 2px 8px rgba(11, 15, 25, .06)); }
.fx-screen {
  position: relative;
  height: 100%;
  display: flex; flex-direction: column; gap: .62em;
  padding: 1em .95em .7em;
  border-radius: calc(var(--fx-ph) * .06);
  background: var(--surface, #FFFFFF);
  color: var(--ink, #0B0F19);
  font-size: calc(var(--fx-ph) / 40.5);
  line-height: 1.3;
  overflow: hidden;
}
.fx-screen p { margin: 0; }
.fx-sbar { display: flex; justify-content: space-between; align-items: center; padding: 0 .5em; font-size: .9em; font-weight: 700; }
.fx-sbar-i { display: inline-flex; gap: .3em; align-items: flex-end; }
.fx-sbar-i i { display: block; width: .9em; height: .55em; border-radius: .15em; background: currentColor; opacity: .85; }
.fx-sbar-i i:nth-child(1) { width: .3em; height: .45em; }
.fx-sbar-i i:nth-child(2) { width: .3em; height: .7em; }
.fx-app-bar { display: flex; align-items: center; justify-content: space-between; gap: .5em; min-height: 2em; }
.fx-back { display: inline-flex; align-items: center; gap: .25em; color: var(--brand, #1F3A5F); font-weight: 650; font-size: .95em; }
.fx-back svg { width: .9em; height: .9em; }
.fx-q-chips { position: relative; display: grid; justify-items: end; }
.fx-q-chips > .fx-pill { grid-area: 1 / 1; font-size: .82em; min-height: 1.9em; padding: .1em .75em; opacity: 0; }
.fx-q-chips > .is-on { opacity: 1; }
.fx-q-head { display: flex; align-items: center; gap: .65em; }
.fx-q-logo {
  flex: none; width: 2.5em; height: 2.5em; border-radius: .75em;
  display: grid; place-items: center;
  background: var(--brand, #1F3A5F); color: var(--on-brand, #FFFFFF);
  font-size: .85em; font-weight: 800; letter-spacing: .02em;
}
.fx-q-who { min-width: 0; display: grid; }
.fx-q-who b { font-size: 1.05em; letter-spacing: -0.01em; }
.fx-q-who span { color: var(--muted, #555D6B); font-size: .85em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fx-q-job { font-size: 1.45em; font-weight: 750; letter-spacing: -0.025em; line-height: 1.1; }

.fx-src { position: relative; border-radius: .9em; }
.fx-src-body { padding: .55em .75em; border-radius: inherit; background: var(--inset, #F7F8FA); border: 1px solid var(--hairline, rgba(11, 15, 25, .08)); }
.fx-ghost {
  position: absolute; inset: 0;
  border-radius: inherit;
  border: 1.5px dashed var(--hairline-strong, rgba(11, 15, 25, .15));
  opacity: 0;
  pointer-events: none;
}
.fx-src-label { color: var(--muted, #555D6B); font-size: .78em; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; padding: .1em 0 .2em; }
.fx-src-row { display: flex; justify-content: space-between; align-items: center; gap: .5em; padding: .22em 0; font-size: .9em; }
.fx-src-row > span { min-width: 0; display: inline-flex; align-items: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fx-src-row b { font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.fx-src-row em { font-style: normal; color: var(--muted, #555D6B); white-space: nowrap; }
.fx-src-row.is-total { margin-top: .2em; padding-top: .4em; border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08)); font-weight: 700; }
.fx-src-row.is-total b { font-weight: 800; }
.fx-dot { flex: none; width: .55em; height: .55em; margin-right: .5em; border-radius: 50%; background: var(--c-sent, #1D4ED8); }
.fx-dot.is-sched { background: var(--c-sched, #5B44B8); }
.fx-dot.is-opened { background: var(--c-opened, #92400E); }
.fx-src-wait { display: flex; align-items: center; gap: .5em; font-size: .9em; font-weight: 600; }
.fx-src-wait em { margin-left: auto; font-style: normal; font-weight: 500; color: var(--muted, #555D6B); font-size: .92em; }
.fx-tabbar { margin-top: auto; display: flex; justify-content: space-around; padding: .55em .4em .1em; border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08)); }
.fx-tabbar i { display: block; width: 1.5em; height: 1.5em; border-radius: .45em; background: var(--hairline-strong, rgba(11, 15, 25, .15)); }
.fx-tabbar i:nth-child(2) { background: var(--brand, #1F3A5F); }

/* ---------- The parts (cards) ---------- */

.fx-x-parts { position: relative; z-index: 2; list-style: none; width: 100%; max-width: 460px; margin: 44px 0 0; padding: 0; display: grid; gap: 36px; }
.fx-part { display: grid; gap: 10px; align-content: start; }
.fx-part-title {
  display: flex; align-items: center; gap: 10px;
  margin: 0;
  color: var(--muted, #555D6B);
  font-size: .8125rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.2;
}
.fx-num {
  flex: none; width: 26px; height: 26px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--brand-soft, #E5EAF1); color: var(--brand, #1F3A5F);
  font-size: .8125rem; font-weight: 800; letter-spacing: 0;
}
.fx-part-cap { margin: 0; font-size: 1.25rem; font-weight: 650; line-height: 1.3; letter-spacing: -0.02em; color: var(--ink, #0B0F19); }
.fx-card {
  position: relative;
  margin-top: 6px;
  padding: 16px 18px;
  border-radius: 20px;
  background: var(--fx-card);
  border: 1px solid var(--hairline, rgba(11, 15, 25, .08));
  box-shadow: var(--fx-card-shadow);
  font-size: .875rem; line-height: 1.45;
  text-align: left;
}
.fx-card p { margin: 0; }
.fx-card small { display: block; color: var(--muted, #555D6B); font-size: .8125rem; font-weight: 500; }

.fx-lines { list-style: none; margin: 0; padding: 0; }
.fx-lines li { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; padding: 9px 0; border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08)); }
.fx-lines li:first-child { border-top: 0; padding-top: 2px; }
.fx-lines span { font-weight: 600; }
.fx-lines b, .fx-total b { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 650; }
.fx-total { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; padding-top: 11px; border-top: 1px solid var(--hairline-strong, rgba(11, 15, 25, .15)); font-weight: 650; }
.fx-total b { font-size: 1.125rem; font-weight: 750; letter-spacing: -0.01em; }

.fx-chain { list-style: none; margin: 0; padding: 0; }
.fx-chain li { display: grid; grid-template-columns: 50px minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 9px 0; border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08)); }
.fx-chain li:first-child { border-top: 0; padding-top: 2px; }
.fx-day { color: var(--brand, #1F3A5F); font-weight: 750; font-size: .8125rem; padding-top: 1px; }
.fx-chain strong { font-weight: 650; }
@media (max-width: 599px) {
  .fx-chain li { grid-template-columns: 46px minmax(0, 1fr); row-gap: 6px; }
  .fx-chain .fx-pill { grid-column: 2; justify-self: start; }
}

.fx-log { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: center; }
.fx-log-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin-top: 5px; color: var(--muted, #555D6B); font-size: .8125rem; }
.fx-log-ic { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; background: var(--c-opened-bg, #FEF3C7); color: var(--c-opened, #92400E); }
.fx-log-ic svg { width: 18px; height: 18px; }
.fx-log strong { font-weight: 650; }

/* The one animated border on the site: a slowly turning conic ring with a soft glow behind it.
   Both layers turn with transform only; with reduced motion the ring stays still. */
.fx-card-accepted { padding: 2px; border: 0; background: transparent; isolation: isolate; box-shadow: none; border-radius: 22px; }
.fx-ring, .fx-ring-glow { position: absolute; border-radius: inherit; overflow: hidden; pointer-events: none; }
.fx-ring { inset: 0; z-index: -1; background: var(--fx-ring-base); }
.fx-ring-glow { inset: -6px; z-index: -2; border-radius: 28px; filter: blur(14px); opacity: var(--fx-glow); }
.fx-ring::before, .fx-ring-glow::before {
  content: "";
  position: absolute; left: 50%; top: 50%;
  width: 200%; aspect-ratio: 1;
  translate: -50% -50%;
  background: conic-gradient(from 0deg, transparent 0turn, transparent .52turn, var(--fx-ring-c) .66turn, var(--fx-ring-b) .76turn, var(--fx-ring-a) .86turn, transparent 1turn);
  transform: rotate(35deg);
}
@media (prefers-reduced-motion: no-preference) {
  .fx-ring::before, .fx-ring-glow::before { animation: fx-ring-turn 7s linear infinite; }
  .fx-explode.is-armed:not(.is-visible) .fx-ring::before,
  .fx-explode.is-armed:not(.is-visible) .fx-ring-glow::before { animation-play-state: paused; }
}
@keyframes fx-ring-turn {
  from { transform: rotate(35deg); }
  to { transform: rotate(395deg); }
}
.fx-acc { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: center; padding: 16px 18px; border-radius: 20px; background: var(--fx-card); }
.fx-acc-ic { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--c-accepted-bg, #DCFCE7); color: var(--c-accepted, #166534); }
.fx-acc-ic svg { width: 22px; height: 22px; }
.fx-acc-title { font-size: 1.375rem; font-weight: 750; letter-spacing: -0.025em; line-height: 1.15; }
.fx-acc-meta { margin-top: 2px; font-weight: 600; }

/* ---------- 900px and up: the exploded diagram (static: reduced motion, no JS, short screens) ---------- */

@media (min-width: 900px) {
  .fx-explode { --fx-ph: 560px; --fx-pw: 274px; }
  .fx-x-panel { padding: 104px 48px 112px; }
  .fx-x-stage { grid-template-columns: minmax(0, 1fr); align-items: center; margin-top: 64px; }
  .fx-phone { grid-area: 1 / 1; }
  .fx-x-glow { top: 50%; transform: translate(-50%, -50%); }
  .fx-x-parts {
    grid-area: 1 / 1;
    max-width: none; margin: 0;
    grid-template-columns: minmax(0, 1fr) var(--fx-pw) minmax(0, 1fr);
    grid-template-rows: auto auto;
    column-gap: clamp(28px, 4vw, 64px);
    row-gap: 32px;
    align-content: center;
  }
  .fx-part { width: min(360px, 100%); }
  .fx-part[data-part="items"] { grid-column: 1; grid-row: 1; justify-self: end; align-self: end; }
  .fx-part[data-part="log"] { grid-column: 1; grid-row: 2; justify-self: end; }
  .fx-part[data-part="chain"] { grid-column: 3; grid-row: 1; justify-self: start; align-self: end; }
  .fx-part[data-part="accepted"] { grid-column: 3; grid-row: 2; justify-self: start; }
  .fx-part-cap { font-size: 1.0625rem; }

  /* The diagram shows the quote already taken apart. */
  .fx-explode:not(.is-pinned) .fx-src-body { opacity: 0; }
  .fx-explode:not(.is-pinned) .fx-ghost { opacity: 1; }
  .fx-explode:not(.is-pinned) .fx-q-chips > .fx-pill { opacity: 0; }
  .fx-explode:not(.is-pinned) .fx-q-chips > [data-from="4"] { opacity: 1; }
}

/* ---------- Pinned, scroll-driven (900 x 600 and up, JS, motion allowed) ---------- */

@media (min-width: 900px) and (min-height: 600px) and (prefers-reduced-motion: no-preference) {
  .js .fx-explode { --fx-ph: clamp(340px, calc(100vh - 272px), 600px); --fx-pw: calc(var(--fx-ph) * .49); --fx-run: 230vh; }
  .js .fx-x-panel { padding: 0 40px; }
  .js .fx-x-track { height: calc(100vh + var(--fx-run)); }
  .js .fx-x-pin {
    position: sticky; top: 0;
    height: 100vh;
    display: grid; grid-template-rows: auto minmax(0, 1fr) auto;
    padding: 100px 0 18px;
  }
  .js .fx-x-head .pill-eyebrow { display: none; }
  .js .fx-x-title { margin-top: 0; font-size: clamp(1.75rem, .9rem + 1.7vw, 2.625rem); }
  .js .fx-x-intro, .js .fx-part-cap {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
  }
  .js .fx-x-caps {
    display: grid;
    max-width: 640px; height: 3em; margin: 12px auto 0;
    font-size: 1.0625rem; line-height: 1.5; color: var(--muted, #555D6B);
  }
  .js .fx-x-stage { margin: 14px 0 0; min-height: 0; }
  .js .fx-x-glow { height: var(--fx-ph); }
  .js .fx-x-parts { row-gap: 18px; }
  .js .fx-part { gap: 8px; }
  .js .fx-card { margin-top: 0; }
  .js .fx-part-title { font-size: .75rem; }
  .js .fx-num { width: 22px; height: 22px; font-size: .75rem; }
  .js .fx-x-progress { position: relative; z-index: 2; display: flex; justify-content: center; gap: 10px; padding-top: 14px; } /* above the phone's shadow */
}
@media (min-width: 900px) and (min-height: 820px) and (prefers-reduced-motion: no-preference) {
  .js .fx-x-head .pill-eyebrow { display: inline-flex; }
  .js .fx-x-title { margin-top: 14px; }
  .js .fx-explode { --fx-ph: clamp(340px, calc(100vh - 328px), 620px); }
}

/* Built by effects.js (decorative copies; screen readers get the captions in the list). */
.fx-x-cap {
  grid-area: 1 / 1;
  margin: 0;
  opacity: 0;
  transform: translateY(8px);
}
.fx-x-cap.is-on { opacity: 1; transform: none; }
.fx-x-step { color: var(--ink, #0B0F19); font-weight: 700; }
.fx-x-seg { display: grid; gap: 6px; justify-items: center; width: 96px; }
.fx-x-bar { position: relative; display: block; width: 100%; height: 4px; border-radius: 4px; overflow: hidden; background: var(--hairline-strong, rgba(11, 15, 25, .15)); }
.fx-x-bar i { position: absolute; inset: 0; border-radius: inherit; background: var(--brand, #1F3A5F); transform: scaleX(0); transform-origin: 0 50%; }
.fx-x-seg-label { color: var(--muted, #555D6B); font-size: .75rem; font-weight: 600; white-space: nowrap; }

/* JS sizes the flying cards from their measured spots; this resets them while it measures. */
.fx-measure .fx-card { transform: none !important; }

@media (prefers-reduced-motion: no-preference) {
  .fx-x-cap { transition: opacity .45s ease, transform .45s ease; }
  .fx-q-chips > .fx-pill { transition: opacity .35s ease; }

  /* Stacked (narrow) mode: each part drops out of the phone as it scrolls in. */
  .fx-explode.is-stacked .fx-part > * { transition: opacity .6s ease, transform .75s cubic-bezier(.2, .8, .2, 1); }
  .fx-explode.is-stacked .fx-part > .fx-card { transition-delay: .08s; }
  .fx-explode.is-stacked .fx-part:not(.is-in) > * { opacity: 0; transform: translateY(14px); }
  .fx-explode.is-stacked .fx-part:not(.is-in) > .fx-card { transform: translateY(-40px) scale(.94) rotate(-2deg); }
  .fx-explode.is-stacked .fx-part:nth-child(even):not(.is-in) > .fx-card { transform: translateY(-40px) scale(.94) rotate(2deg); }
}


/* ======================================================================================
   2. Quote-card strip
   ====================================================================================== */

.fx-strip { padding: 6px var(--gutter, 16px); scroll-margin-top: 96px; }
.fx-s-panel {
  --fx-s-inset: 20px;
  position: relative;
  max-width: calc(var(--wrap, 1160px) + 160px);
  margin: 0 auto;
  padding: 72px 0 44px;
  border-radius: var(--radius-panel, 32px);
  border: 1px solid var(--hairline, rgba(11, 15, 25, .08));
  background: linear-gradient(125deg, var(--fx-s-a), var(--fx-s-b) 36%, var(--fx-s-c) 68%, var(--fx-s-d));
  overflow: hidden;
}
.fx-s-head { max-width: 760px; margin: 0 auto; padding: 0 20px; text-align: center; }
.fx-s-head .h2 { margin-top: 20px; }
.fx-s-head .body-lg { margin-left: auto; margin-right: auto; }
.fx-s-bar { display: flex; justify-content: center; align-items: center; gap: 8px; min-height: 44px; margin-top: 18px; }
.fx-s-toggle {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border: 1px solid var(--hairline, rgba(11, 15, 25, .08)); border-radius: 999px;
  background: var(--fx-card); color: var(--ink, #0B0F19);
  cursor: pointer;
}
.fx-s-toggle:hover { border-color: var(--hairline-strong, rgba(11, 15, 25, .15)); }
.fx-s-toggle svg { width: 16px; height: 16px; }
.fx-s-toggle .fx-i-play { display: none; }
.fx-s-toggle[aria-pressed="true"] .fx-i-play { display: block; }
.fx-s-toggle[aria-pressed="true"] .fx-i-pause { display: none; }

.fx-s-viewport { margin-top: 36px; }
.fx-s-list {
  list-style: none; margin: 0; padding: 0 var(--fx-s-inset);
  display: grid; gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 296px), 1fr));
}
.fx-s-item { display: flex; }
.fx-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- Job card ---------- */

.fx-job {
  position: relative;
  flex: 1;
  display: flex; flex-direction: column; gap: 16px;
  padding: 18px 18px 16px;
  border-radius: 24px;
  background: var(--fx-card);
  border: 1px solid var(--hairline, rgba(11, 15, 25, .08));
  box-shadow: var(--fx-card-shadow);
}
.fx-job-top { order: -1; display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; } /* first on screen, after the title for screen readers */
.fx-job { --fx-tw: 80px; --fx-th: 60px; --fx-step: 54px; min-width: 0; }
.fx-stack { position: relative; flex: none; width: calc(var(--fx-tw) + var(--fx-step) * 2 + 6px); height: calc(var(--fx-th) + 12px); isolation: isolate; }
.fx-thumb {
  position: absolute; left: 3px; top: 5px;
  width: var(--fx-tw); height: var(--fx-th);
  border-radius: 12px;
  overflow: hidden;
  background: #DCEBFB;
  box-shadow: 0 0 0 3px var(--fx-card), 0 8px 18px -8px rgba(11, 15, 25, .5);
  transform-origin: 50% 90%;
  transform: translate(var(--x, 0px), var(--y, 0px)) rotate(var(--r, 0deg));
}
.fx-thumb::after { content: ""; position: absolute; inset: 0; background: var(--fx-veil); }
.fx-thumb svg { display: block; width: 100%; height: 100%; }
.fx-thumb:nth-child(1) { z-index: 3; --x: 0px; --y: 3px; --r: -4deg; }
.fx-thumb:nth-child(2) { z-index: 2; --x: 13px; --y: 1px; --r: 5deg; }
.fx-thumb:nth-child(3) { z-index: 1; --x: 26px; --y: 4px; --r: 12deg; }

/* Spread: tap or click (is-open), keyboard focus, or a mouse hover. */
.fx-job.is-open .fx-thumb:nth-child(1), .fx-job:has(.fx-job-btn:focus-visible) .fx-thumb:nth-child(1) { --x: 0px; --y: 3px; --r: -5deg; }
.fx-job.is-open .fx-thumb:nth-child(2), .fx-job:has(.fx-job-btn:focus-visible) .fx-thumb:nth-child(2) { --x: var(--fx-step); --y: -2px; --r: 0deg; }
.fx-job.is-open .fx-thumb:nth-child(3), .fx-job:has(.fx-job-btn:focus-visible) .fx-thumb:nth-child(3) { --x: calc(var(--fx-step) * 2); --y: 2px; --r: 5deg; }
@media (hover: hover) {
  .fx-job:hover .fx-thumb:nth-child(1) { --x: 0px; --y: 3px; --r: -5deg; }
  .fx-job:hover .fx-thumb:nth-child(2) { --x: var(--fx-step); --y: -2px; --r: 0deg; }
  .fx-job:hover .fx-thumb:nth-child(3) { --x: calc(var(--fx-step) * 2); --y: 2px; --r: 5deg; }
}

.fx-job-title { margin: 0; font-size: 1.5rem; line-height: 1.08; letter-spacing: -0.03em; font-weight: 750; }
.fx-job-title, .fx-job-btn > span:first-child, .fx-yours-text { min-width: 0; overflow-wrap: anywhere; }
.fx-job-btn {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
  width: 100%; margin: 0; padding: 0;
  border: 0; background: none; color: inherit;
  font: inherit; letter-spacing: inherit; text-align: left;
  cursor: pointer;
}
.fx-job-btn::after { content: ""; position: absolute; inset: 0; z-index: 4; border-radius: 24px; } /* the whole card is the tap target */
.fx-arrow {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--ink, #0B0F19); color: var(--bg, #F3F4F6);
}
.fx-arrow svg { width: 16px; height: 16px; }
@supports selector(:has(*)) {
  .fx-job-btn:focus-visible { outline: none; }
  .fx-job:has(.fx-job-btn:focus-visible) { outline: 2px solid var(--brand, #1F3A5F); outline-offset: 3px; }
}

.fx-facts {
  list-style: none;
  display: flex; flex-wrap: wrap; gap: 6px 11px;
  margin: auto 0 0; padding: 13px 0 0;
  border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08));
  color: var(--muted, #555D6B);
  font-size: .8125rem; font-weight: 550; line-height: 1.3;
}
.fx-facts li { display: inline-flex; align-items: center; gap: 6px; min-width: 0; max-width: 100%; overflow-wrap: anywhere; }
.fx-facts li:first-child { color: var(--ink, #0B0F19); font-weight: 700; }
.fx-facts svg { flex: none; width: 15px; height: 15px; }

/* "Your trade too": the last card in the row, an open invitation rather than a quote. */
.fx-job-yours { background: transparent; border: 1.5px dashed var(--hairline-strong, rgba(11, 15, 25, .15)); box-shadow: none; }
.fx-yours-ic {
  width: 72px; height: 72px; display: grid; place-items: center;
  border-radius: 18px; background: var(--brand-soft, #EEF3FD); color: var(--brand, #1F3A5F);
}
.fx-yours-ic svg { width: 28px; height: 28px; }
.fx-yours-text {
  margin: auto 0 0; padding: 13px 0 0;
  border-top: 1px solid var(--hairline, rgba(11, 15, 25, .08));
  color: var(--muted, #555D6B); font-size: .9375rem; line-height: 1.45;
}

/* ---------- One slow row: JS running, motion allowed ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js .fx-s-viewport {
    margin-top: 28px;
    padding: 12px 0 30px;
    overflow-x: auto; overflow-y: hidden;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
    mask-image: linear-gradient(90deg, transparent, #000 5%, #000 95%, transparent);
  }
  .js .fx-s-viewport::-webkit-scrollbar { display: none; }
  .js .fx-s-track { display: flex; gap: 20px; width: max-content; }
  .js .fx-s-list { display: flex; gap: 20px; padding: 0 var(--fx-s-inset); }
  .js .fx-s-item { flex: none; width: 360px; }
  .js .fx-strip.is-live .fx-s-viewport { overflow: hidden; }
  .js .fx-strip.is-live .fx-s-list { padding: 0; }

  .fx-thumb { transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
  .fx-arrow { transition: transform .3s ease; }
  .fx-job { transition: transform .35s ease; }
  @media (hover: hover) {
    .fx-job:hover { transform: translateY(-4px); }
    .fx-job:hover .fx-arrow { transform: translateX(3px); }
  }
}

@media (min-width: 600px) {
  .fx-x-panel { padding-left: 40px; padding-right: 40px; }
  .fx-s-panel { --fx-s-inset: 40px; padding: 88px 0 64px; }
  .fx-s-head { padding: 0 40px; }
}
@media (min-width: 900px) {
  .fx-s-panel { padding: 112px 0 80px; }
}
@media (max-width: 419px) {
  .fx-job { --fx-tw: 70px; --fx-th: 53px; --fx-step: 46px; }
  .fx-job-title { font-size: 1.375rem; }
}
@media (max-width: 419px) and (prefers-reduced-motion: no-preference) {
  .js .fx-s-item { width: 306px; }
}
