/* pmneX landing: the product built as scenes. Look tokens only (tokens.css).
   Each scene shows sample records for the industry chosen (construction: MasterFormat 03 31 00,
   contract SC-014, payment request 3; the other two in the per-industry data in index.html):
   fictional figures that add up, set as the app sets them, so the page shows the product at work.

   A scene is a fixed composition (.sc, data-w × data-h on its .stage, data-w-sm × data-h-sm
   below data-w) scaled up to the width it is given, never down; a chain (data-chain) is laid
   out at true size instead (scenes.js). No scene text is set below 12px. Its actors carry data-a and an animation-name; all of
   them run on one clock (--sec) so nothing drifts. Every actor's BASE style is the final
   frame and its keyframes start from the beginning of the story, so with
   prefers-reduced-motion the animation is removed and the still that remains is the end.
   A scene plays once per page load (scenes.js), about 1.5 s, when it first comes into view, and
   stops on its full picture at data-end of its clock; the keyframes after that point only fade out. */


@property --p{syntax:"<number>";inherits:true;initial-value:1}
@property --f{syntax:"<number>";inherits:true;initial-value:1}
@property --s{syntax:"<number>";inherits:true;initial-value:2}
@property --t{syntax:"<number>";inherits:true;initial-value:1}

/* ---- the stage -------------------------------------------------------------- */
.stage{--sc-enter:cubic-bezier(.16,.8,.3,1);--sc-layout:var(--ease);--sc-exit:cubic-bezier(.5,0,.85,.45);min-width:0}
.stage-frame{position:relative;width:100%;max-width:var(--max,600px);margin:0 auto;aspect-ratio:var(--ar);overflow:hidden;background:var(--surface);border:1px solid var(--line);border-radius:var(--r-md)}
.band.alt .stage-frame{background:var(--surface)}
.sc{position:absolute;left:0;top:0;transform-origin:0 0;transform:scale(var(--k,1));font-family:var(--font-sans);color:var(--ink)}
.sc [data-a],.sc[data-a]{animation-duration:var(--sec,10s);animation-iteration-count:infinite;animation-timing-function:linear;animation-fill-mode:both}
.js .sc [data-a],.js .sc[data-a]{animation-play-state:paused}
.stage-cap{min-height:calc(2 * var(--lh-sm));max-width:var(--max,600px);margin:var(--s-3) auto 0;font-size:var(--fs-sm);line-height:var(--lh-sm);color:var(--ink-2)}
.stage-stack{display:grid;gap:var(--s-7);min-width:0}
@media (prefers-reduced-motion:reduce){
  .sc [data-a],.sc[data-a]{animation:none}
}

/* ---- kit: card, tag, tick, pill, the figures a card holds -------------------------- */
.sc-card{position:absolute;background:var(--surface);border:1px solid var(--line-strong);border-radius:var(--r-sm)}
.sc-tag{display:flex;align-items:center;gap:8px;font-size:12px;line-height:16px;font-weight:var(--fw-semibold);color:var(--ink-2);white-space:nowrap}
.sc-tick{position:absolute;display:grid;place-items:center;width:20px;height:20px;border-radius:50%;background:var(--pos);color:var(--surface)}
.sc-tick svg{width:12px;height:12px;fill:none;stroke:currentColor;stroke-width:3;stroke-linecap:round;stroke-linejoin:round}
.sc-pill{display:inline-flex;align-items:center;gap:4px;height:22px;padding:0 8px;border-radius:var(--r-pill);font-size:12px;font-weight:var(--fw-semibold);white-space:nowrap}
.sc-pill.pos{color:var(--pos);background:var(--pos-soft)}
.sc-pill.warn{color:var(--warn);background:var(--warn-soft)}
.sc-pill svg{width:11px;height:11px;fill:none;stroke:currentColor;stroke-width:3;stroke-linecap:round;stroke-linejoin:round}
.sc .num,.sc-amt{font-family:var(--font-num);font-feature-settings:var(--num-features)}
.sc-l1{display:block;font-size:12px;line-height:16px;font-weight:var(--fw-semibold);color:var(--ink);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.sc-l2{display:block;margin-top:4px;font-size:12px;line-height:16px;color:var(--ink-2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.sc-amt{display:block;font-size:14px;line-height:18px;font-weight:var(--fw-semibold);color:var(--ink);white-space:nowrap}

/* ==== 1 · Chains: one record carried card by card ==========================================
   Laid out at true size by scenes.js (data-chain): it sets the card width --cw, the column step
   --gap, the left edge --x0, the row step --rowh, the moves --n and the last column --c1, and
   each step's column --c and row --r. lg: one row; md: rows of three; sm: a column. A row is 208px; a card 124px.
   --q is the chip's place in moves (0 to --n); --m is its turn from row 1 to row 2 (0 to 1). */
.st-hero{--max:1200px}
.st-hero .sc{animation-name:sc-hero-p;--q:calc(var(--p) * var(--n));--m:clamp(0, var(--q) - var(--c1), 1);--u:clamp(0, (var(--m) - .5) * 1000, 1)}
.st-five .sc{animation-name:sc-five-p}
.h-spine,.h-trail{position:absolute;left:calc(var(--x0) + var(--cw) / 2);top:calc(47px + var(--row) * var(--rowh));width:calc(var(--len) * var(--gap));height:2px;border-radius:1px;background:var(--line-strong)}
.r0{--row:0;--len:var(--c1)}
.r1{--row:1;--len:calc(var(--n) - var(--c1) - 1)}
.st-hero:not([data-layout="md"]) .r1{display:none}
.h-trail{background:var(--accent);transform-origin:0 50%;animation-name:sc-hero-fade}
.h-trail.r0{transform:scaleX(clamp(0, var(--q) / var(--c1), 1))}
.h-trail.r1{transform:scaleX(clamp(0, (var(--q) - var(--c1) - 1) / var(--len), 1))}
.h-step{position:absolute;inset:0;pointer-events:none}
.h-node{position:absolute;left:calc(var(--x0) + var(--c) * var(--gap) + var(--cw) / 2 - 6px);top:calc(42px + var(--r) * var(--rowh));width:12px;height:12px;border-radius:50%;background:var(--bg);border:2px solid var(--line-strong)}
.h-node::after{content:"";position:absolute;inset:-2px;border-radius:50%;background:var(--accent);opacity:clamp(0,calc(var(--f) * 4),1)}
.h-stem{position:absolute;left:calc(var(--x0) + var(--c) * var(--gap) + var(--cw) / 2 - 1px);top:calc(56px + var(--r) * var(--rowh));width:2px;height:28px;background:var(--line)}
.h-card{left:calc(var(--x0) + var(--c) * var(--gap));top:calc(84px + var(--r) * var(--rowh));width:var(--cw);height:124px;padding:12px 12px 0}
.h-card .sc-tag{padding-right:24px}
.h-card .sc-l1{margin-top:12px;opacity:clamp(0,calc(var(--f) * 3 - .5),1)}
.h-card .sc-l2{opacity:clamp(0,calc(var(--f) * 3 - .8),1)}
.h-card .sc-amt{margin-top:12px;padding-top:8px;border-top:1px solid var(--line);overflow:hidden;text-overflow:ellipsis;opacity:clamp(0,calc(var(--f) * 3 - 1.4),1)}
.h-card .sc-tick{right:8px;top:8px;opacity:clamp(0,calc(var(--f) * 3 - 2),1);transform:scale(calc(.7 + .3 * clamp(0,calc(var(--f) * 3 - 2),1)))}
.h-card .sc-tag{color:color-mix(in srgb,var(--accent-ink) calc(clamp(0,var(--f),1) * 100%),var(--ink-3))}
/* the chip: along row 1, then out and back in at the start of row 2 */
.h-chip-pos{position:absolute;left:0;top:0;opacity:max(1 - 2 * var(--m), 2 * var(--m) - 1);transform:translate(calc(var(--x0) + var(--cw) / 2 - 18px + var(--gap) * (clamp(0, var(--q), var(--c1)) * (1 - var(--u)) + clamp(0, var(--q) - var(--c1) - 1, var(--n)) * var(--u))),calc(38px + var(--rowh) * var(--u)))}
/* sm: a column, the node and line on the left of each card */
.st-hero[data-layout="sm"] .h-spine,.st-hero[data-layout="sm"] .h-trail{left:27px;top:48px;width:2px;height:calc(var(--n) * var(--rowh))}
.st-hero[data-layout="sm"] .h-trail{transform-origin:50% 0;transform:scaleY(var(--p))}
.st-hero[data-layout="sm"] .h-node{left:22px}
.st-hero[data-layout="sm"] .h-stem{left:34px;top:calc(47px + var(--r) * var(--rowh));width:22px;height:2px}
.st-hero[data-layout="sm"] .h-card{left:56px;top:calc(16px + var(--r) * var(--rowh));width:calc(100% - 72px);height:64px;padding:12px 40px 0 12px;display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:12px;align-content:start}
.st-hero[data-layout="sm"] .h-card .sc-tag{grid-column:1;padding-right:0}
.st-hero[data-layout="sm"] .h-card .sc-l1{grid-column:1;margin-top:4px}
.st-hero[data-layout="sm"] .h-card .sc-l2{display:none}
.st-hero[data-layout="sm"] .h-card .sc-amt{grid-column:2;grid-row:1 / span 2;align-self:center;margin:0;padding:0;border:0}
.st-hero[data-layout="sm"] .h-card .sc-tick{top:22px;right:12px}
.st-hero[data-layout="sm"] .h-chip-pos{opacity:1;transform:translate(10px,calc(39px + var(--q) * var(--rowh)))}
.h-chip{display:grid;place-items:center;width:36px;height:20px;border-radius:var(--r-pill);background:var(--accent);box-shadow:0 0 0 4px var(--accent-soft);animation-name:sc-hero-chip}
.h-chip::before{content:"";width:14px;height:3px;border-radius:2px;background:var(--on-accent)}
.h-step.s0{animation-name:sc-hero-f0}
.h-step.s1{animation-name:sc-hero-f1}
.h-step.s2{animation-name:sc-hero-f2}
.h-step.s3{animation-name:sc-hero-f3}
.h-step.s4{animation-name:sc-hero-f4}
.h-step.s5{animation-name:sc-hero-f5}

/* ==== 2 · Bid levelling in one currency (lg 480 × 292, sm 340 × 300) ===================== */
.bl-title{position:absolute;left:20px;top:20px;width:440px;font-size:13px;line-height:18px;font-weight:var(--fw-semibold);color:var(--ink)}
/* Each bid reads in three lines: quote, rate, EUR; Incoterm, delivery, landed; technical, verdict */
.bl-head,.bl-row{position:absolute;left:20px;width:440px;display:grid;grid-template-columns:68px minmax(0,1fr) 76px 72px;align-items:start;column-gap:8px;padding:0 8px;font-size:12px;line-height:16px}
.bl-head{top:56px;grid-template-rows:16px 16px;color:var(--ink-3)}
.bl-head .h1{grid-area:1 / 1}.bl-head .h2{grid-area:1 / 2}.bl-head .h3{grid-area:1 / 3}.bl-head .h4{grid-area:1 / 4}
.bl-head .h5{grid-area:2 / 2}.bl-head .h6{grid-area:2 / 3}.bl-head .h7{grid-area:2 / 4}
.bl-head :is(.h4,.h7),.bl-row :is(.usd,.land){text-align:right}
.bl-row{height:78px;padding-top:10px;grid-template-rows:16px 16px 22px;row-gap:4px;border-top:1px solid var(--line);color:var(--ink)}
.bl-row b{grid-area:1 / 1;font-weight:var(--fw-semibold)}
.bl-row .q{grid-area:1 / 2}.bl-row .rate{grid-area:1 / 3;color:var(--ink-2)}.bl-row .usd{grid-area:1 / 4}
.bl-row .inco{grid-area:2 / 2;color:var(--ink-2)}.bl-row .dlv{grid-area:2 / 3;color:var(--ink-2)}
.bl-row .land{grid-area:2 / 4;font-weight:var(--fw-semibold)}
.bl-row .tech{grid-area:3 / 2;display:flex;align-items:center;gap:6px;height:22px}
.bl-row .tl{color:var(--ink-3)}
.bl-row :is(.bl-award,.bl-out){grid-area:3 / 3 / 4 / 5;justify-self:end}
.sc-pill.mute{color:var(--ink-2);background:var(--pill-on)}
.bl-row.ra{top:96px;animation-name:sc-bid-in-a}
.bl-row.rb{top:174px;animation-name:sc-bid-in-b}
.bl-row.rc{top:252px;animation-name:sc-bid-in-c;border-bottom:1px solid var(--line)}
.bl-row.ra :is(.rate,.usd){animation-name:sc-usd-a}
.bl-row.rb :is(.rate,.usd){animation-name:sc-usd-b}
.bl-row.rc :is(.rate,.usd){animation-name:sc-usd-c}
.bl-row.ra :is(.inco,.dlv,.land){animation-name:sc-bl-land-a}
.bl-row.rb :is(.inco,.dlv){animation-name:sc-bl-land-b}
.bl-row.rc :is(.inco,.dlv,.land){animation-name:sc-bl-land-c}
.bl-row.ra .tech{animation-name:sc-bl-tech-a}
.bl-row.rb .tech{animation-name:sc-bl-tech-b}
.bl-row.rc .tech{animation-name:sc-bl-tech-c}
.bl-row.rb .land{color:var(--ink-3);font-weight:var(--fw-regular);text-decoration:line-through;text-decoration-color:currentColor;animation-name:sc-bl-strike}
.bl-out{animation-name:sc-bl-out}
.bl-win{position:absolute;left:20px;top:253px;width:440px;height:77px;background:var(--accent-soft);animation-name:sc-row-win}
.bl-row.rc .land{color:var(--accent-ink)}
.bl-award{animation-name:sc-award}
.bl-note,.bl-dev{position:absolute;left:28px;width:424px;font-size:12px;line-height:16px;color:var(--ink-3)}
.bl-note{top:342px;animation-name:sc-usd-c}
.bl-dev{top:360px;animation-name:sc-bl-out}

/* phone: bidder over its quote; rate and EUR beside them; Incoterm, delivery, landed; technical, verdict */
.st-bids[data-layout="sm"] .bl-title{left:16px;top:16px;width:308px}
.st-bids[data-layout="sm"] :is(.bl-head,.bl-row){left:16px;width:308px;grid-template-columns:minmax(0,1fr) 60px 70px;padding:0 4px}
.st-bids[data-layout="sm"] .bl-head{top:48px;grid-template-rows:16px 16px 16px}
.st-bids[data-layout="sm"] .bl-head .h1{grid-area:1 / 1}
.st-bids[data-layout="sm"] .bl-head .h2{grid-area:2 / 1}
.st-bids[data-layout="sm"] .bl-head .h3{grid-area:1 / 2 / 3 / 3}
.st-bids[data-layout="sm"] .bl-head .h4{grid-area:1 / 3 / 3 / 4}
.st-bids[data-layout="sm"] .bl-head .h5{grid-area:3 / 1}
.st-bids[data-layout="sm"] .bl-head .h6{grid-area:3 / 2}
.st-bids[data-layout="sm"] .bl-head .h7{grid-area:3 / 3}
.st-bids[data-layout="sm"] .bl-row{height:96px;grid-template-rows:16px 16px 16px 22px;row-gap:2px}
.st-bids[data-layout="sm"] .bl-row .q{grid-area:2 / 1;color:var(--ink-2)}
.st-bids[data-layout="sm"] .bl-row .rate{grid-area:1 / 2}
.st-bids[data-layout="sm"] .bl-row .usd{grid-area:1 / 3}
.st-bids[data-layout="sm"] .bl-row .inco{grid-area:3 / 1}
.st-bids[data-layout="sm"] .bl-row .dlv{grid-area:3 / 2}
.st-bids[data-layout="sm"] .bl-row .land{grid-area:3 / 3}
.st-bids[data-layout="sm"] .bl-row .tech{grid-area:4 / 1;margin-top:4px}
.st-bids[data-layout="sm"] .bl-row :is(.bl-award,.bl-out){grid-area:4 / 2 / 5 / 4;margin-top:4px}
.st-bids[data-layout="sm"] .bl-row.ra{top:104px}
.st-bids[data-layout="sm"] .bl-row.rb{top:200px}
.st-bids[data-layout="sm"] .bl-row.rc{top:296px}
.st-bids[data-layout="sm"] .bl-win{left:16px;top:297px;width:308px;height:95px}
.st-bids[data-layout="sm"] :is(.bl-note,.bl-dev){left:20px;width:300px}
.st-bids[data-layout="sm"] .bl-note{top:404px}
.st-bids[data-layout="sm"] .bl-dev{top:422px}

/* ==== 3 · Signed in order (lg 480 × 250, sm 340 × 250) ====================================
   The request sits across the top; the three signers share the width below it in equal
   columns, each name inside its column. */
.sc-sign{--x0:80px;--dx:160px;--doc-x:24px}
.st-sign[data-layout="sm"] .sc-sign{--x0:57px;--dx:113px;--doc-x:16px}
.g-track,.g-line{position:absolute;left:var(--x0);top:157px;width:calc(2 * var(--dx));height:2px;background:var(--line-strong)}
.g-line{background:var(--accent);transform-origin:0 50%;animation-name:sc-sign-line}
.g-who{position:absolute;top:136px;left:calc(var(--x0) + var(--i) * var(--dx) - 22px);width:44px;height:44px}
.g-av{position:absolute;inset:0;display:grid;place-items:center;border-radius:50%;background:var(--surface);border:2px solid var(--line-strong);font-size:13px;font-weight:var(--fw-semibold);letter-spacing:.02em;color:var(--ink-2)}
.g-ring{position:absolute;inset:0;border-radius:50%;border:2px solid var(--accent);box-shadow:0 0 0 4px var(--accent-soft);opacity:clamp(0,var(--s),1)}
.g-who .sc-tick{right:-4px;bottom:-4px;box-shadow:0 0 0 2px var(--bg);opacity:clamp(0,calc(var(--s) - 1),1);transform:scale(calc(.6 + .4 * clamp(0,calc(var(--s) - 1),1)))}
.g-n{position:absolute;left:calc(22px - var(--dx) / 2 + 4px);width:calc(var(--dx) - 8px);top:54px;text-align:center;font-size:12px;line-height:16px;font-weight:var(--fw-medium);color:var(--ink-2)}
.g-who.w0{--i:0;animation-name:sc-sign-s0}
.g-who.w1{--i:1;animation-name:sc-sign-s1}
.g-who.w2{--i:2;animation-name:sc-sign-s2}
.g-doc{left:var(--doc-x);right:var(--doc-x);top:20px;height:88px;padding:12px 16px 0;animation-name:sc-sign-doc}
.g-doc .sc-l1{margin-top:8px;max-width:calc(100% - 120px)}
.g-doc .sc-l2{max-width:calc(100% - 120px)}
.g-doc .sc-amt{position:absolute;right:16px;bottom:14px;font-size:16px;line-height:22px}
.st-sign[data-layout="sm"] .g-doc .sc-amt{font-size:14px;line-height:18px}
.g-state{position:relative;height:22px}
.g-state .sc-pill{position:absolute;left:0;top:0}
.g-state .warn{animation-name:sc-sign-wait;opacity:0}
.g-state .pos{animation-name:sc-sign-ok}

/* ==== 4 · Exchange-rate difference (lg 480 × 290, sm 340 × 290) ========================= */
.fx{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
.st-fx:not([data-layout="sm"]) .fx-sm,.st-fx[data-layout="sm"] .fx-lg{display:none}
.fx .grid{stroke:var(--line);stroke-width:1}
.fx .axis{stroke:var(--line-strong);stroke-width:1.5}
.fx .tick{stroke:var(--line-strong);stroke-width:1.5}
.fx .budget{fill:none;stroke:var(--ink-3);stroke-width:2;stroke-linecap:round;stroke-dasharray:1;animation-name:sc-fx-draw}
.fx .pay{fill:none;stroke:var(--accent);stroke-width:2.5;stroke-linecap:round;stroke-dasharray:1;animation-name:sc-fx-draw}
.fx .area{fill:var(--accent);fill-opacity:.14;animation-name:sc-fx-area}
.fx .start{fill:var(--ink-3);animation-name:sc-fx-start}
.fx .dot{fill:var(--surface);stroke:var(--accent);stroke-width:2;transform-box:fill-box;transform-origin:center}
.fx .d0{animation-name:sc-fx-dot0}
.fx .d1{animation-name:sc-fx-dot1}
.fx .d2{animation-name:sc-fx-dot2}
.fx .d3{animation-name:sc-fx-dot3}
.fx .bracket{fill:none;stroke:var(--accent-ink);stroke-width:1.5;stroke-linecap:round;transform-box:fill-box;transform-origin:center;animation-name:sc-fx-bracket}
.fx .lbl{font-family:var(--font-sans);font-size:12px;font-weight:var(--fw-medium);fill:var(--ink-2);animation-name:sc-fx-label}
.fx .lbl.acc{fill:var(--accent-ink)}
.fx-badge{position:absolute;left:84px;top:20px;padding:8px 12px;border-radius:var(--r-sm);background:var(--surface);border:1px solid var(--accent);transform-origin:0 0;animation-name:sc-fx-badge}
.st-fx[data-layout="sm"] .fx-badge{left:56px}
.fx-badge .sc-amt{margin-top:4px;color:var(--accent-ink)}
.fx .val{font-family:var(--font-num);font-feature-settings:var(--num-features);font-size:12px;font-weight:var(--fw-semibold);fill:var(--ink-2);animation-name:sc-fx-label}
.fx .val.acc{fill:var(--accent-ink)}
.fx .mon{font-family:var(--font-sans);font-size:12px;fill:var(--ink-3);animation-name:sc-fx-label}

/* ==== 5 · A payment request, line by line (lg 480 × 290, sm 340 × 290) ===================
   One clock, --t, runs 0 to 1 on the table; each line arrives when --t * 9 passes its --i. */
.pr{position:absolute;inset:0;--px:24px;animation-name:sc-pay-t}
.st-tot[data-layout="sm"] .pr{--px:16px}
.pr-title{position:absolute;left:var(--px);right:var(--px);top:20px;display:flex;justify-content:space-between;gap:12px;font-size:13px;line-height:18px;font-weight:var(--fw-semibold);color:var(--ink)}
.pr-title span{font-weight:var(--fw-regular);color:var(--ink-3)}
.pr-row{position:absolute;left:var(--px);right:var(--px);top:calc(52px + var(--i) * 27px);height:27px;display:grid;grid-template-columns:16px minmax(0,1fr) auto;align-items:center;column-gap:8px;padding:0 8px;font-size:12px;line-height:16px;color:var(--ink-2);opacity:clamp(0,calc(var(--t) * 9 - var(--i)),1);transform:translateY(calc((1 - clamp(0,calc(var(--t) * 9 - var(--i)),1)) * 6px))}
.pr-row i{font-style:normal;color:var(--ink-3)}
.pr-row b{font-weight:var(--fw-regular);color:var(--ink);font-family:var(--font-num);font-feature-settings:var(--num-features)}
.pr-row.sub{border-top:1px solid var(--line);color:var(--ink)}
.pr-row.sub b{font-weight:var(--fw-semibold)}
.pr-row.due{background:var(--accent-soft);color:var(--accent-ink);border-top:0}
.pr-row.due b{color:var(--accent-ink)}

/* ==== Keyframes (generated from seconds; every scene's base styles are its final frame) ==== */
/* The beats below were written on a 10 to 12 s clock and are kept as fractions of it. Each scene
   now runs on --sec (hero 2.5 s, material 2.9 s, bids 3.2 s, FX 2.5 s, payment 2.7 s, signing 2.3 s)
   and stops at its data-end, so a scene plays in about 1.5 s; the fade-out beats never run. */

/* ---- 1 · Hero, "One figure, end to end" (12 s) ----------------------------------
   0.5 s  the figure (an emerald chip) appears on the Estimate node
   0.8 s  Estimate fills: its lines and amount appear, a tick lands (0.6 s)
   1.35 s the chip moves on; every 1.15 s it reaches the next card, which fills
   6.55 s it reaches the payment
   7.9 s  rest, everything filled
   11.0 s fills and chip fade; 12 s loop */

@keyframes sc-hero-p {
  0% { --p: 0; }
  6.67% { --p: 0; }
  11.25% { --p: 0; animation-timing-function: var(--sc-layout); }
  16.25% { --p: 0.2; }
  20.83% { --p: 0.2; animation-timing-function: var(--sc-layout); }
  25.83% { --p: 0.4; }
  30.42% { --p: 0.4; animation-timing-function: var(--sc-layout); }
  35.42% { --p: 0.6; }
  40% { --p: 0.6; animation-timing-function: var(--sc-layout); }
  45% { --p: 0.8; }
  49.58% { --p: 0.8; animation-timing-function: var(--sc-layout); }
  54.58% { --p: 1; }
  96.25% { --p: 1; }
  96.67% { --p: 0; }
  100% { --p: 0; }
}

/* five-step flow: the same beats as the hero, ending on the fifth card */
@keyframes sc-five-p {
  0% { --p: 0; }
  6.67% { --p: 0; }
  11.25% { --p: 0; animation-timing-function: var(--sc-layout); }
  16.25% { --p: 0.25; }
  20.83% { --p: 0.25; animation-timing-function: var(--sc-layout); }
  25.83% { --p: 0.5; }
  30.42% { --p: 0.5; animation-timing-function: var(--sc-layout); }
  35.42% { --p: 0.75; }
  40% { --p: 0.75; animation-timing-function: var(--sc-layout); }
  45% { --p: 1; }
  96.25% { --p: 1; }
  96.67% { --p: 0; }
  100% { --p: 0; }
}

@keyframes sc-hero-chip {
  0%, 4.17% { opacity: 0; transform: scale(.6); animation-timing-function: var(--sc-enter); }
  7.08% { opacity: 1; transform: scale(1); }
  91.67% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  95.83%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-hero-fade {
  0%, 4.17% { opacity: 0; animation-timing-function: var(--sc-enter); }
  7.08%, 91.67% { opacity: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { opacity: 0; }
}

@keyframes sc-hero-f0 {
  0%, 7.08% { --f: 0; animation-timing-function: var(--sc-enter); }
  12.5%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

@keyframes sc-hero-f1 {
  0%, 16.67% { --f: 0; animation-timing-function: var(--sc-enter); }
  22.08%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

@keyframes sc-hero-f2 {
  0%, 26.25% { --f: 0; animation-timing-function: var(--sc-enter); }
  31.67%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

@keyframes sc-hero-f3 {
  0%, 35.83% { --f: 0; animation-timing-function: var(--sc-enter); }
  41.25%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

@keyframes sc-hero-f4 {
  0%, 45.42% { --f: 0; animation-timing-function: var(--sc-enter); }
  50.83%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

@keyframes sc-hero-f5 {
  0%, 55% { --f: 0; animation-timing-function: var(--sc-enter); }
  60.42%, 91.67% { --f: 1; animation-timing-function: var(--sc-exit); }
  95.83%, 100% { --f: 0; }
}

/* ---- 2 · Bid levelling: price, delivery terms, technical fit (10 s clock) ----------
   0.3 s  three rows slide in, 0.25 s apart, each quoted in its own currency
   2.4 s  the rate and the EUR figure fill in, row by row
   3.4 s  Incoterm, delivery cost and landed figure fill in, row by row
   4.4 s  the technical check lands on each row
   5.2 s  Bidder B, lowest on paper, is struck and marked Excluded, with its deviations below
   5.4 s  the lowest compliant landed row (Bidder C) takes the tint; 5.7 s Awarded
   6.3 s  rest (data-end); 9.2 s fade; 10 s loop */

@keyframes sc-bid-in-a {
  0%, 3% { opacity: 0; transform: translateX(36px); animation-timing-function: var(--sc-enter); }
  10% { opacity: 1; transform: translateX(0); }
  92% { opacity: 1; transform: translateX(0); animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; transform: translateX(0); }
}

@keyframes sc-bid-in-b {
  0%, 5.5% { opacity: 0; transform: translateX(36px); animation-timing-function: var(--sc-enter); }
  12.5% { opacity: 1; transform: translateX(0); }
  92% { opacity: 1; transform: translateX(0); animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; transform: translateX(0); }
}

@keyframes sc-bid-in-c {
  0%, 8% { opacity: 0; transform: translateX(36px); animation-timing-function: var(--sc-enter); }
  15% { opacity: 1; transform: translateX(0); }
  92% { opacity: 1; transform: translateX(0); animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; transform: translateX(0); }
}

@keyframes sc-usd-a {
  0%, 24% { opacity: 0; animation-timing-function: var(--sc-enter); }
  28.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-usd-b {
  0%, 26% { opacity: 0; animation-timing-function: var(--sc-enter); }
  30.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-usd-c {
  0%, 28% { opacity: 0; animation-timing-function: var(--sc-enter); }
  32.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-row-win {
  0%, 54% { opacity: 0; animation-timing-function: var(--sc-layout); }
  59%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-award {
  0%, 57% { opacity: 0; transform: translateY(4px); animation-timing-function: var(--sc-enter); }
  61%, 100% { opacity: 1; transform: translateY(0); }
}

@keyframes sc-bl-land-a {
  0%, 34% { opacity: 0; animation-timing-function: var(--sc-enter); }
  38.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-land-b {
  0%, 36% { opacity: 0; animation-timing-function: var(--sc-enter); }
  40.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-land-c {
  0%, 38% { opacity: 0; animation-timing-function: var(--sc-enter); }
  42.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-tech-a {
  0%, 44% { opacity: 0; animation-timing-function: var(--sc-enter); }
  47.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-tech-b {
  0%, 46% { opacity: 0; animation-timing-function: var(--sc-enter); }
  49.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-tech-c {
  0%, 48% { opacity: 0; animation-timing-function: var(--sc-enter); }
  51.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-out {
  0%, 52% { opacity: 0; animation-timing-function: var(--sc-enter); }
  55.5%, 92% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; }
}

@keyframes sc-bl-strike {
  0%, 36% { opacity: 0; color: var(--ink); text-decoration-color: transparent; animation-timing-function: var(--sc-enter); }
  40.5%, 52% { opacity: 1; color: var(--ink); text-decoration-color: transparent; animation-timing-function: var(--sc-layout); }
  55.5%, 92% { opacity: 1; color: var(--ink-3); text-decoration-color: currentColor; animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; color: var(--ink-3); text-decoration-color: currentColor; }
}

/* ---- 3 · Signed in order (10 s) ----------------------------------------------------
   0.3 s  the request appears across the top, tag Waiting
   1.0 s  signer 1 lights; 1.6 s ✓
   2.1 s  the line to signer 2 fills (0.7 s); 3.0 s / 3.6 s signer 2
   4.1 s  on to signer 3; 5.0 s / 5.6 s
   6.1 s  Waiting turns Approved; rest; 9.2 s fade; 10 s loop */

@keyframes sc-sign-doc {
  0%, 3% { opacity: 0; transform: translateY(8px); animation-timing-function: var(--sc-enter); }
  9% { opacity: 1; transform: translateY(0); }
  92% { opacity: 1; transform: translateY(0); animation-timing-function: var(--sc-exit); }
  97%, 100% { opacity: 0; transform: translateY(0); }
}

@keyframes sc-sign-line {
  0%, 21% { transform: scaleX(0); animation-timing-function: var(--sc-layout); }
  28%, 41% { transform: scaleX(.5); animation-timing-function: var(--sc-layout); }
  48%, 92% { transform: scaleX(1); animation-timing-function: var(--sc-exit); }
  97%, 100% { transform: scaleX(0); }
}

@keyframes sc-sign-s0 {
  0%, 10% { --s: 0; animation-timing-function: var(--sc-enter); }
  13.5%, 16% { --s: 1; animation-timing-function: var(--sc-enter); }
  19.5%, 92% { --s: 2; animation-timing-function: var(--sc-exit); }
  97%, 100% { --s: 0; }
}

@keyframes sc-sign-s1 {
  0%, 30% { --s: 0; animation-timing-function: var(--sc-enter); }
  33.5%, 36% { --s: 1; animation-timing-function: var(--sc-enter); }
  39.5%, 92% { --s: 2; animation-timing-function: var(--sc-exit); }
  97%, 100% { --s: 0; }
}

@keyframes sc-sign-s2 {
  0%, 50% { --s: 0; animation-timing-function: var(--sc-enter); }
  53.5%, 56% { --s: 1; animation-timing-function: var(--sc-enter); }
  59.5%, 92% { --s: 2; animation-timing-function: var(--sc-exit); }
  97%, 100% { --s: 0; }
}

@keyframes sc-sign-wait {
  0%, 61% { opacity: 1; }
  65%, 100% { opacity: 0; }
}

@keyframes sc-sign-ok {
  0%, 61% { opacity: 0; transform: scale(.85); animation-timing-function: var(--sc-enter); }
  66%, 100% { opacity: 1; transform: scale(1); }
}

/* ---- 4 · Exchange-rate difference (11 s) ----------------------------------------
   0.4 s  one point: the rate when the budget was set
   0.9 s  two lines draw from it (4 s): the budget rate stays level, the payment-day
          rate drifts away; a dot marks each payment as the line passes it
   5.0 s  the gap fills with a soft emerald area (0.8 s)
   5.8 s  a bracket spans the gap; 6.1 s the FX difference card
   6.6 s  rest; 10.2 s fade; 11 s loop */

@keyframes sc-fx-start {
  0%, 3.64% { opacity: 0; animation-timing-function: var(--sc-enter); }
  7.27%, 92.73% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; }
}

@keyframes sc-fx-draw {
  0%, 8.18% { stroke-dashoffset: 1; opacity: 1; animation-timing-function: cubic-bezier(.45,.05,.55,.95); }
  44.55%, 92.73% { stroke-dashoffset: 0; opacity: 1; animation-timing-function: var(--sc-exit); }
  97.27%, 100% { stroke-dashoffset: 0; opacity: 0; }
}

@keyframes sc-fx-dot0 {
  0%, 18.84% { opacity: 0; transform: scale(0); animation-timing-function: var(--sc-enter); }
  22.47%, 92.73% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-fx-dot1 {
  0%, 27.93% { opacity: 0; transform: scale(0); animation-timing-function: var(--sc-enter); }
  31.57%, 92.73% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-fx-dot2 {
  0%, 37.02% { opacity: 0; transform: scale(0); animation-timing-function: var(--sc-enter); }
  40.66%, 92.73% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-fx-dot3 {
  0%, 44.09% { opacity: 0; transform: scale(0); animation-timing-function: var(--sc-enter); }
  47.73%, 92.73% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-fx-area {
  0%, 45.45% { opacity: 0; animation-timing-function: var(--sc-layout); }
  52.73%, 92.73% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; }
}

@keyframes sc-fx-bracket {
  0%, 52.73% { opacity: 0; transform: scaleY(0); animation-timing-function: var(--sc-layout); }
  56.36%, 92.73% { opacity: 1; transform: scaleY(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scaleY(1); }
}

@keyframes sc-fx-badge {
  0%, 55.45% { opacity: 0; transform: scale(.7); animation-timing-function: var(--sc-enter); }
  60%, 92.73% { opacity: 1; transform: scale(1); animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; transform: scale(1); }
}

@keyframes sc-fx-label {
  0%, 10.91% { opacity: 0; animation-timing-function: var(--sc-enter); }
  16.36%, 92.73% { opacity: 1; animation-timing-function: var(--sc-exit); }
  97.27%, 100% { opacity: 0; }
}

/* ---- 5 · A payment request, line by line (10 s) ------------------------------------
   0.4 s  the title; 0.6 s to 5.6 s the eight lines arrive in order, a to h;
   5.6 s  the amount due (h) settles on its tinted row; rest; 9.2 s fade; 10 s loop */

@keyframes sc-pay-t {
  0%, 4% { --t: 0; opacity: 1; animation-timing-function: linear; }
  56% { --t: 1; opacity: 1; }
  92% { --t: 1; opacity: 1; animation-timing-function: var(--sc-exit); }
  97%, 100% { --t: 1; opacity: 0; }
}
