/* The scenes in the feature section. Each feature has its own composition
   and its own kind of motion, so the rows never look like one picture
   repeated:

     1 ranked board   a close-up leaderboard that re-ranks as votes arrive
     2 shipped        one big status on a track, and the app's row below it
     3 context        a message whose device details snap into the Context panel
     4 Telegram       a phone on a dark lock screen that buzzes with the alert
     5 no account     a sign-up wall that falls over, leaving the real form
     6 moderation     a "Blocked" stamp on a stack of spam

   The texts are the product's own (internal/hosted, internal/dash,
   internal/notify). Rules that keep the scenes honest and calm:
   - The plain styles are each scene's final frame. That is what people with
     "reduce motion" see (animation: none), so it must make sense alone. The
     keyframes start earlier and play toward it.
   - landing.js adds .run while a scene is on screen (off screen it pauses)
     and scales each 460×340 stage to the space it has.
   - Every loop lasts --T and resets inside its last few percent. */

.fvis {
  --T: 8s; --ease: cubic-bezier(.65, 0, .35, 1); --pop: cubic-bezier(.34, 1.56, .64, 1);
  --ios-hl: #e8f2ff; --ios-warn: #c93400;
  --sys: system-ui, -apple-system, "SF Pro Text", "Segoe UI", Roboto, sans-serif;
  position: relative; height: 164px; margin: -16px -16px 14px; border-radius: 28px;
  background: var(--background); overflow: hidden; display: grid; place-items: center;
  font-size: 12px; line-height: 16px; font-weight: 600; color: var(--foreground);
}
[data-theme="dark"] .fvis { --ios-hl: #0a2540; --ios-warn: #ff9f0a; }
.fvis * { animation-duration: var(--T); animation-iteration-count: infinite; animation-timing-function: var(--ease); animation-fill-mode: both; }
.fx-on .fvis:not(.run) *, .fx-on .fvis:not(.run) *::before, .fx-on .fvis:not(.run) *::after { animation-play-state: paused; }
.fvis em { font-style: normal; }
.fvis p { margin: 0; }

/* ---- the stage -------------------------------------------------------------- */
.fart { padding: 10px; border-radius: var(--radius-panel); background: var(--surface); }
.fart .fvis { height: 380px; margin: 0; }
/* Centred and out of the layout flow: the scale landing.js applies does not
   change layout size, so an in-flow 460px stage would push the row wider
   than a phone screen. */
.fst { position: absolute; left: 50%; top: 50%; width: 460px; height: 340px; margin: -170px 0 0 -230px; }
.sc-cap { position: absolute; left: 0; right: 0; top: 14px; text-align: center; font-size: 11px; font-weight: 600; color: var(--muted-foreground); }

/* Shared iOS pieces, drawn like the web version (internal/hosted/static/web.css). */
.tg { padding: 1px 8px; border-radius: 6px; background: var(--ios-tag); font: 600 11px/16px var(--sys); }
.tg-blue { color: var(--ios-tint); }
.tg-green { color: var(--ios-green); }
.iv { flex: none; width: 42px; height: 46px; border-radius: 11px; background: var(--ios-tag); color: var(--ios-fg);
  display: flex; flex-direction: column; align-items: center; justify-content: center; font: 600 11px/15px var(--sys); }
.iv > span { font-size: 14px; }
.iv.on { background: var(--ios-tint); color: #fff; }
.iph { color: var(--ios-dim); }

/* A rolling number. */
.od { display: inline-block; height: 22px; overflow: hidden; vertical-align: top; }
.rl { display: flex; flex-direction: column; transform: translateY(-110px); }
.rl i { font-style: normal; height: 22px; line-height: 22px; }

/* ---- 1 · a leaderboard that re-ranks --------------------------------------- */
.rk-n { position: absolute; left: 34px; top: 52px; margin: 0; padding: 0; list-style: none; }
.rk-n li { display: flex; align-items: center; height: 76px; font-size: 22px; font-weight: 700; color: var(--ring); }
.rk-list { position: absolute; left: 70px; right: 30px; top: 58px; height: 216px; animation-name: fade-loop; }
.rk-card { position: absolute; left: 0; right: 0; height: 64px; display: flex; align-items: center; justify-content: space-between;
  padding: 0 12px 0 20px; border-radius: 18px; background: var(--surface); }
.rk-t { display: flex; flex-direction: column; font-size: 16px; line-height: 21px; font-weight: 700; }
.rk-t small { font-size: 11px; line-height: 15px; font-weight: 500; color: var(--muted-foreground); }
.rk-v { position: relative; display: flex; align-items: center; gap: 6px; height: 42px; padding: 0 15px; border-radius: 13px;
  background: var(--background); font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rk-dark { top: 0; z-index: 2; animation-name: rk-dark; }
.rk-icloud { top: 76px; animation-name: rk-icloud; }
.rk-widgets { top: 152px; animation-name: rk-widgets; }
.rk-dark .rl { animation-name: rk-roll; }
@keyframes rk-roll { 0%, 9% { transform: none; } 12%, 23% { transform: translateY(-22px); } 26%, 35% { transform: translateY(-44px); } 38%, 47% { transform: translateY(-66px); } 50%, 59% { transform: translateY(-88px); } 62%, 93% { transform: translateY(-110px); } 97%, 100% { transform: none; } }
@keyframes rk-dark {
  0%, 13% { transform: translateY(152px); box-shadow: 0 0 0 0 transparent; }
  19%, 52% { transform: translateY(76px); box-shadow: 0 0 0 0 transparent; }
  58% { transform: none; box-shadow: 0 0 0 0 transparent; }
  63%, 88% { transform: none; box-shadow: 0 0 0 2px var(--logo-accent); }
  93% { transform: none; box-shadow: 0 0 0 0 transparent; }
  97%, 100% { transform: translateY(152px); }
}
@keyframes rk-icloud { 0%, 52% { transform: translateY(-76px); } 58%, 93% { transform: none; } 97%, 100% { transform: translateY(-76px); } }
@keyframes rk-widgets { 0%, 13% { transform: translateY(-76px); } 19%, 93% { transform: none; } 97%, 100% { transform: translateY(-76px); } }
.plus { position: absolute; right: 8px; top: -4px; font-style: normal; font-size: 13px; font-weight: 800; color: var(--logo-accent);
  opacity: 0; animation-name: plus-k; animation-delay: calc(var(--T) * var(--at)); }
@keyframes plus-k { 0% { opacity: 0; transform: translateY(4px); } 2% { opacity: 1; } 11% { opacity: 0; transform: translateY(-28px); } 100% { opacity: 0; transform: translateY(-28px); } }
@keyframes fade-loop { 0% { opacity: 0; } 3%, 93% { opacity: 1; } 97%, 100% { opacity: 0; } }

/* ---- 2 · one big status on a track ---------------------------------------- */
.st-big { position: absolute; left: 0; right: 0; top: 22px; display: grid; justify-items: center; }
.st-big em { grid-area: 1 / 1; display: inline-flex; align-items: center; gap: 9px; height: 46px; padding: 0 24px; border-radius: var(--radius-full);
  background: var(--surface); font-size: 20px; font-weight: 700; opacity: 0; }
.st-big .b3 { background: var(--primary); color: var(--primary-foreground); }
.st-big .b4 { opacity: 1; }
.st-big .b4::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--success); }
.st-big .b1 { animation-name: st-b1; } .st-big .b2 { animation-name: st-b2; } .st-big .b3 { animation-name: st-b3; } .st-big .b4 { animation-name: st-b4; }
@keyframes st-b1 { 0%, 16% { opacity: 1; transform: none; } 19%, 96% { opacity: 0; transform: scale(.9); } 99%, 100% { opacity: 1; transform: none; } }
@keyframes st-b2 { 0%, 16% { opacity: 0; transform: scale(.9); } 20%, 38% { opacity: 1; transform: none; } 41%, 100% { opacity: 0; transform: scale(.9); } }
@keyframes st-b3 { 0%, 41% { opacity: 0; transform: scale(.9); } 45%, 61% { opacity: 1; transform: none; } 64%, 100% { opacity: 0; transform: scale(.9); } }
@keyframes st-b4 { 0%, 64% { opacity: 0; transform: scale(.9); } 68%, 94% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; transform: scale(.9); } }
.st-track { position: absolute; left: 60px; right: 60px; top: 104px; height: 50px; }
.st-line { position: absolute; left: 0; right: 0; top: 9px; height: 4px; border-radius: 2px; background: var(--border); overflow: hidden; }
.st-line i { display: block; height: 100%; background: var(--foreground); transform-origin: left; animation-name: st-fill; }
@keyframes st-fill { 0%, 16% { transform: scaleX(0); } 20%, 38% { transform: scaleX(.3333); } 45%, 61% { transform: scaleX(.6667); } 68%, 94% { transform: scaleX(1); } 98%, 100% { transform: scaleX(0); } }
.st-stop { position: absolute; top: 4px; padding-top: 22px; transform: translateX(-50%); font-size: 11px; font-weight: 600; color: var(--muted-foreground); white-space: nowrap; }
.st-stop::before { content: ""; position: absolute; top: 0; left: 50%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%;
  background: var(--surface); box-shadow: inset 0 0 0 3px var(--border); }
.st-knob { position: absolute; left: 0; top: 0; width: 22px; height: 22px; margin-left: -11px; border-radius: 50%;
  background: var(--success); box-shadow: 0 0 0 5px var(--background); transform: translateX(340px); animation-name: st-knob; }
@keyframes st-knob {
  0%, 16% { transform: none; background: var(--primary); }
  20%, 38% { transform: translateX(113.3px); background: var(--primary); }
  45%, 61% { transform: translateX(226.7px); background: var(--primary); }
  68%, 94% { transform: translateX(340px); background: var(--success); }
  98%, 100% { transform: none; background: var(--primary); }
}
.st-cap { top: 196px; left: 60px; right: auto; text-align: left; }
.st-app { position: absolute; left: 60px; right: 60px; top: 220px; height: 72px; display: flex; align-items: center; gap: 12px;
  padding: 0 13px 0 20px; border-radius: 18px; background: var(--ios-card); color: var(--ios-fg); animation-name: st-flash; }
.st-title { flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 5px; font: 600 16px/20px var(--sys); }
.st-tags { display: grid; min-height: 18px; }
.st-tags .tg { grid-area: 1 / 1; justify-self: start; opacity: 0; }
.st-tags .a4 { opacity: 1; }
.st-tags .a2 { animation-name: st-a2; } .st-tags .a3 { animation-name: st-a3; } .st-tags .a4 { animation-name: st-a4; }
@keyframes st-a2 { 0%, 21% { opacity: 0; } 24%, 41% { opacity: 1; } 44%, 100% { opacity: 0; } }
@keyframes st-a3 { 0%, 46% { opacity: 0; } 49%, 64% { opacity: 1; } 67%, 100% { opacity: 0; } }
@keyframes st-a4 { 0%, 70% { opacity: 0; } 73%, 94% { opacity: 1; } 97%, 100% { opacity: 0; } }
@keyframes st-flash { 0%, 71% { background: var(--ios-card); } 74% { background: var(--ios-hl); } 88%, 100% { background: var(--ios-card); } }

/* ---- 3 · details snap into the Context panel ------------------------------- */
.sn-msg { position: absolute; left: 22px; top: 74px; width: 196px; padding: 16px; border-radius: 18px; background: var(--surface); }
.sn-who { display: block; font-size: 10.5px; color: var(--muted-foreground); }
.sn-msg p { margin-top: 6px; font-size: 15px; line-height: 20px; font-weight: 700; }
.sn-shot { display: block; width: 46px; height: 82px; margin-top: 12px; border-radius: 8px;
  background: linear-gradient(var(--border) 0 16px, var(--background) 16px 28px, var(--border) 28px 33px, var(--background) 33px 44px, var(--border) 44px);
  box-shadow: 0 0 0 1px var(--border); animation-name: sn-shot; }
@keyframes sn-shot { 0%, 64% { opacity: 0; transform: translate(-24px, 40px) rotate(-10deg); } 72% { opacity: 1; transform: none; animation-timing-function: var(--pop); } 92% { opacity: 1; transform: none; } 96%, 100% { opacity: 0; } }
.sn-ctx { position: absolute; right: 22px; top: 40px; width: 200px; padding: 14px 16px 12px; border-radius: 18px; background: var(--surface); }
.sn-ctx > b { font-size: 15px; }
.sn-row { display: flex; align-items: center; justify-content: space-between; height: 36px; border-bottom: 1px solid var(--border); font-size: 11.5px; font-weight: 500; color: var(--muted-foreground); }
/* White with a border, so a detail stays readable while it flies over the
   grey panel, not only once it sits in the white Context card. */
.sn-row em { position: relative; z-index: 2; padding: 3px 10px; border-radius: var(--radius-full); background: var(--surface);
  box-shadow: 0 0 0 1px var(--border), 0 4px 12px rgba(0,0,0,.06); color: var(--foreground); font-size: 12px; font-weight: 700; }
.sn-note { display: block; margin-top: 9px; font-size: 10.5px; color: var(--success); animation-name: ap-74; }
/* Each detail starts somewhere around the message, then snaps into its row. */
.sn-row .c1 { animation-name: sn-c1; } .sn-row .c2 { animation-name: sn-c2; } .sn-row .c3 { animation-name: sn-c3; }
.sn-row .c4 { animation-name: sn-c4; } .sn-row .c5 { animation-name: sn-c5; }
@keyframes sn-c1 { 0% { opacity: 0; transform: translate(-226px, -56px) rotate(-10deg); } 6%, 14% { opacity: 1; transform: translate(-226px, -56px) rotate(-10deg); animation-timing-function: var(--pop); } 22%, 92% { opacity: 1; transform: none; } 94% { opacity: 0; transform: none; } 100% { opacity: 0; transform: translate(-226px, -56px) rotate(-10deg); } }
@keyframes sn-c2 { 0% { opacity: 0; transform: translate(-318px, 150px) rotate(8deg); } 6%, 24% { opacity: 1; transform: translate(-318px, 150px) rotate(8deg); animation-timing-function: var(--pop); } 32%, 92% { opacity: 1; transform: none; } 94% { opacity: 0; transform: none; } 100% { opacity: 0; transform: translate(-318px, 150px) rotate(8deg); } }
@keyframes sn-c3 { 0% { opacity: 0; transform: translate(-150px, 150px) rotate(-6deg); } 6%, 34% { opacity: 1; transform: translate(-150px, 150px) rotate(-6deg); animation-timing-function: var(--pop); } 42%, 92% { opacity: 1; transform: none; } 94% { opacity: 0; transform: none; } 100% { opacity: 0; transform: translate(-150px, 150px) rotate(-6deg); } }
@keyframes sn-c4 { 0% { opacity: 0; transform: translate(-300px, -150px) rotate(9deg); } 6%, 44% { opacity: 1; transform: translate(-300px, -150px) rotate(9deg); animation-timing-function: var(--pop); } 52%, 92% { opacity: 1; transform: none; } 94% { opacity: 0; transform: none; } 100% { opacity: 0; transform: translate(-300px, -150px) rotate(9deg); } }
@keyframes sn-c5 { 0% { opacity: 0; transform: translate(-150px, 68px) rotate(7deg); } 6%, 54% { opacity: 1; transform: translate(-150px, 68px) rotate(7deg); animation-timing-function: var(--pop); } 62%, 92% { opacity: 1; transform: none; } 94% { opacity: 0; transform: none; } 100% { opacity: 0; transform: translate(-150px, 68px) rotate(7deg); } }

/* ---- 4 · a dark lock screen that buzzes ------------------------------------ */
.fvis.is-dark { background: #1f1f1f; }
.lk-phone { position: absolute; left: 140px; top: 0; width: 180px; height: 340px; padding: 7px; border-radius: 38px; background: #0b0b0b;
  box-shadow: 0 0 0 1.5px #4a4a4a; animation-name: lk-buzz; }
@keyframes lk-buzz { 0%, 22% { transform: none; } 23% { transform: translateX(-3px); } 24% { transform: translateX(3px); } 25% { transform: translateX(-3px); } 26% { transform: translateX(3px); } 27%, 100% { transform: none; } }
.lk-scr { position: relative; height: 100%; overflow: hidden; border-radius: 31px; color: #fff; font-family: var(--sys);
  background: radial-gradient(120% 70% at 50% 0%, #6a6a70 0%, #2c2c30 55%, #121214 100%); }
.lk-isl { position: absolute; left: 50%; top: 9px; width: 52px; height: 15px; margin-left: -26px; border-radius: 9px; background: #000; }
.lk-date { margin-top: 40px !important; text-align: center; font-size: 11.5px; font-weight: 600; opacity: .85; }
.lk-time { text-align: center; font-size: 58px; line-height: 64px; font-weight: 300; letter-spacing: -1px; }
.lk-note { position: absolute; left: 8px; right: 8px; top: 136px; display: flex; gap: 8px; padding: 10px; border-radius: 17px;
  background: rgba(240, 240, 240, .92); color: #111; animation-name: lk-drop; }
@keyframes lk-drop { 0%, 18% { opacity: 0; transform: translateY(-150px) scale(.96); } 23% { opacity: 1; transform: translateY(6px); } 26%, 88% { opacity: 1; transform: none; } 94%, 100% { opacity: 0; transform: translateY(-150px); } }
.lk-ic { flex: none; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: #232323; color: #fff; }
.lk-tx { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; font-size: 11px; line-height: 14px; font-weight: 500; }
.lk-tx b { display: flex; justify-content: space-between; font-size: 11.5px; }
.lk-tx small { font-size: 9.5px; font-weight: 500; color: #666; }
.lk-tx u { color: #555; font-size: 9.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lk-vib { position: absolute; top: 120px; width: 22px; height: 70px; border-radius: 50%; border: 2.5px solid transparent; opacity: 0; animation-name: lk-vib; }
.lk-vib.l { left: 104px; border-left-color: #8a8a8a; }
.lk-vib.r { right: 104px; border-right-color: #8a8a8a; }
@keyframes lk-vib { 0%, 22% { opacity: 0; transform: scale(.8); } 24% { opacity: 1; transform: none; } 31%, 100% { opacity: 0; transform: scale(1.25); } }

/* ---- 5 · the sign-up wall falls over ---------------------------------------- */
.s-wall { perspective: 900px; }
.wl-card { position: absolute; left: 110px; top: 6px; width: 240px; height: 278px; padding: 18px 16px; border-radius: 22px;
  font-family: var(--sys); color: var(--ios-fg); }
.wl-form { background: var(--ios-card); }
.wl-wall { background: var(--surface); box-shadow: 0 0 0 1px var(--border), 0 18px 40px rgba(0,0,0,.12); color: var(--foreground);
  transform-origin: 50% 100%; opacity: 0; animation-name: wl-fall; }
@keyframes wl-fall {
  0%, 11% { opacity: 1; transform: none; }
  13% { transform: rotate(-1.5deg); }
  15% { transform: rotate(1.5deg); }
  17% { opacity: 1; transform: none; }
  29%, 94% { opacity: 0; transform: rotateX(86deg) translateY(30px); }
  97%, 100% { opacity: 1; transform: none; }
}
.wl-h { font-size: 19px; line-height: 24px; font-weight: 700; }
.wl-l { display: block; margin: 12px 2px 5px; font-size: 11px; font-weight: 600; }
.wl-l span { color: var(--ios-dim); font-weight: 400; }
.wl-f { height: 38px; margin-top: 8px; display: flex; align-items: center; padding: 0 12px; border-radius: 11px; background: var(--ios-bg); font-size: 13px; }
.wl-l + .wl-f { margin-top: 0; }
.wl-wall .wl-f { background: var(--background); }
.wl-wall .wl-h { margin-bottom: 6px !important; }
.wl-f2 { height: 64px; align-items: flex-start; padding-top: 11px; }
.wl-type { display: inline-block; max-width: 150px; overflow: hidden; white-space: nowrap; animation-name: wl-type; }
@keyframes wl-type { 0%, 34% { max-width: 0; animation-timing-function: steps(15); } 54%, 94% { max-width: 150px; } 97%, 100% { max-width: 0; } }
.wl-btns { display: flex; gap: 8px; margin-top: 16px; }
.wl-submit, .wl-cancel { display: inline-flex; align-items: center; height: 38px; padding: 0 18px; border-radius: 11px; font-size: 13px; font-weight: 600; }
.wl-submit { background: var(--ios-tint); color: #fff; animation-name: wl-press; }
.wl-cancel { background: var(--ios-tag); color: var(--ios-tint); }
@keyframes wl-press { 0%, 60% { transform: none; } 63% { transform: scale(.9); } 66%, 100% { transform: none; } }
.wl-signup { display: flex; align-items: center; justify-content: center; height: 40px; margin-top: 16px; border-radius: 11px;
  background: var(--primary); color: var(--primary-foreground); font-size: 13px; font-weight: 700; }
.wl-small { margin-top: 12px !important; text-align: center; font-size: 10.5px; color: var(--muted-foreground); }
.wl-note { position: absolute; left: 0; right: 0; top: 298px; width: max-content; margin: 0 auto; padding: 7px 12px; border-radius: 12px; border: 1.5px dashed var(--ring);
  background: var(--surface); font-size: 11px; font-weight: 700; rotate: 4deg; animation-name: ap-66; }

/* ---- 6 · a stamp on the spam -------------------------------------------------- */
.sp-stack { position: absolute; left: 90px; top: 40px; width: 280px; height: 150px; animation-name: sp-hit; }
@keyframes sp-hit { 0%, 29% { transform: none; } 30% { transform: translateY(4px); } 32% { transform: translateY(-1px); } 34%, 100% { transform: none; } }
.sp-card { position: absolute; left: 0; right: 0; top: 36px; height: 78px; display: flex; flex-direction: column; justify-content: center;
  padding: 0 18px; border-radius: 18px; background: var(--surface); color: var(--ring); animation-name: sp-dim; }
.sp-card b { font-size: 15px; line-height: 20px; }
.sp-card small { font-size: 11px; font-weight: 500; color: var(--muted-foreground); }
.sp-card.c3 { transform: translateY(-26px) rotate(-5deg) scale(.92); }
.sp-card.c2 { transform: translateY(-13px) rotate(3deg) scale(.96); }
/* The text fades, not the card: a see-through card would show the cards
   behind it. */
@keyframes sp-dim { 0%, 30% { color: var(--foreground); } 36%, 92% { color: var(--ring); } 97%, 100% { color: var(--foreground); } }
.sp-stamp { position: absolute; left: 50%; top: 52px; padding: 6px 18px; border: 3.5px solid var(--destructive); border-radius: 12px;
  color: var(--destructive); background: color-mix(in srgb, var(--surface) 75%, transparent);
  font-size: 26px; line-height: 32px; font-weight: 800; letter-spacing: 3px; text-transform: uppercase;
  transform: translateX(-50%) rotate(-12deg); animation-name: sp-stamp; }
@keyframes sp-stamp {
  0%, 22% { opacity: 0; transform: translateX(-50%) rotate(-12deg) scale(2.4); }
  29% { opacity: 1; transform: translateX(-50%) rotate(-12deg) scale(.92); }
  32%, 92% { opacity: 1; transform: translateX(-50%) rotate(-12deg) scale(1); }
  97%, 100% { opacity: 0; transform: translateX(-50%) rotate(-12deg) scale(1); }
}
.sp-app { position: absolute; left: 70px; right: 70px; top: 218px; animation-name: sp-app; }
.sp-app small { display: block; margin-bottom: 7px; font-size: 11px; font-weight: 600; color: var(--muted-foreground); }
.sp-app p { padding: 14px 16px; border-radius: 14px; border-left: 4px solid var(--ios-warn); background: var(--ios-card); color: var(--ios-fg);
  font: 500 14px/19px var(--sys); }
@keyframes sp-app { 0%, 50% { opacity: 0; transform: translateY(24px); } 57%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }

/* ---- the two small cards ---------------------------------------------------- */
.kd { position: relative; height: 46px; padding: 7px 8px 0; border-radius: 10px; background: var(--surface); }
.kt { display: flex; align-items: flex-start; gap: 6px; font-size: 9px; line-height: 12px; font-weight: 500; }
.vp { flex: none; display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 15px; padding: 0 6px;
  border-radius: var(--radius-full); background: var(--background); font-size: 9px; font-weight: 700; font-variant-numeric: tabular-nums; }
.km { position: absolute; left: 8px; bottom: 6px; font-size: 8px; color: var(--muted-foreground); }
.db { display: inline-flex; align-items: center; height: 22px; padding: 0 10px; border-radius: var(--radius-full); font-size: 9px; font-weight: 700; white-space: nowrap; }
.db-fill { background: var(--primary); color: var(--primary-foreground); }
.db-outline { background: var(--surface); box-shadow: inset 0 0 0 1px var(--border); color: var(--foreground); }
.sb-wrap, .ex-wrap { width: 240px; display: flex; flex-direction: column; gap: 8px; }
.envsw { position: relative; display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: var(--radius-full); background: var(--surface); font-size: 10px; }
.envsw span:not(.ew-thumb) { position: relative; padding: 3px 0; text-align: center; }
.ew-thumb { position: absolute; top: 3px; bottom: 3px; left: 3px; width: calc(50% - 3px); border-radius: var(--radius-full); background: var(--primary); animation-name: ew-slide; }
.ew-a { color: var(--primary-foreground); animation-name: ew-a; }
.ew-b { color: var(--muted-foreground); animation-name: ew-b; }
@keyframes ew-slide { 0%, 42% { transform: none; } 48%, 92% { transform: translateX(100%); } 98%, 100% { transform: none; } }
@keyframes ew-a { 0%, 44% { color: var(--primary-foreground); } 47%, 94% { color: var(--muted-foreground); } 98%, 100% { color: var(--primary-foreground); } }
@keyframes ew-b { 0%, 44% { color: var(--muted-foreground); } 47%, 94% { color: var(--primary-foreground); } 98%, 100% { color: var(--muted-foreground); } }
.sbar { padding: 5px 11px; border-radius: var(--radius-full); background: var(--primary); color: var(--primary-foreground); font-size: 8.5px; line-height: 12px; font-weight: 500; animation-name: dis-44; }
.sbar b { font-weight: 700; }
.sb-cards { position: relative; height: 46px; }
.sb-cards .kd { position: absolute; inset: 0; }
.sb-test { animation-name: dis-44; }
.sb-prod { opacity: 0; animation-name: ap-46; }
.bdg { margin-left: 4px; padding: 0 5px; border-radius: var(--radius-full); background: var(--background); font-size: 7.5px; color: var(--foreground); }
.ex-card { padding: 10px 11px; border-radius: 14px; background: var(--surface); }
.ex-card b { font-size: 10.5px; }
.ex-btns { display: flex; gap: 5px; margin-top: 7px; }
.ex-json { animation-name: press-k; }
@keyframes press-k { 0%, 16% { transform: none; } 19% { transform: scale(.9); } 22%, 100% { transform: none; } }
.ex-file { display: flex; align-items: center; gap: 7px; padding: 8px 10px; border-radius: 12px; background: var(--surface); animation-name: ap-24; }
.ex-name { flex: 1; min-width: 0; font-size: 8.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ex-bar { flex: none; width: 44px; height: 4px; border-radius: 2px; background: var(--border); overflow: hidden; }
.ex-bar i { display: block; height: 100%; background: var(--foreground); transform-origin: left; animation-name: ex-fill; }
@keyframes ex-fill { 0%, 26% { transform: scaleX(0); } 56%, 93% { transform: scaleX(1); } 97%, 100% { transform: scaleX(0); } }
.ex-ok { flex: none; width: 16px; height: 16px; border-radius: 50%; display: grid; place-items: center; background: var(--primary); color: var(--primary-foreground); font-size: 9px; animation-name: ap-56; }

/* ---- appear at N% and stay; or disappear at N% (both reset at the end) --- */
@keyframes ap-24 { 0%, 24% { opacity: 0; transform: translateY(5px); } 28%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }
@keyframes ap-46 { 0%, 46% { opacity: 0; transform: translateY(5px); } 50%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }
@keyframes ap-56 { 0%, 56% { opacity: 0; transform: translateY(5px); } 60%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }
@keyframes ap-66 { 0%, 66% { opacity: 0; transform: translateY(5px); } 70%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }
@keyframes ap-74 { 0%, 74% { opacity: 0; transform: translateY(5px); } 78%, 93% { opacity: 1; transform: none; } 97%, 100% { opacity: 0; } }
@keyframes dis-44 { 0%, 44% { opacity: 1; } 47%, 94% { opacity: 0; } 98%, 100% { opacity: 1; } }

@media (max-width: 900px) {
  .fart .fvis { height: 340px; }
}

@media (prefers-reduced-motion: reduce) {
  .fvis *, .fvis *::before, .fvis *::after { animation: none !important; }
}
