/* «Introducing ForceMotion v2» on the homepage (#forcemotion) — the founder, 2026-10-13: a new product with
 * its own page (/forcemotion/, /fa/forcemotion/), announced on both homepages the way a launch is
 * announced. The name is always written in English. Markup: tools/forcemotion/build-forcemotion.mjs;
 * behaviour: sinora-forcemotion.js. Theme root and fa/, equal.
 *
 * V2: the section frame (§7.2), one section one screen ≥1024 landscape (§5.3: a 1280 × 720 composition
 * at --u = 1px that shrinks with the width and the room under the header), the house spring and ease
 * (§6), liquid glass for the instrument only (the pause button, §4). The sample arrives as a material:
 * opacity, a small scale and a blur that clears; transform, opacity and filter only. Reduced motion: no
 * decorative arrival; the founder-requested muted sample still starts and loops automatically.
 *
 * Scoping: the theme sets h1–h6 with `!important` and sinora-redesign.css gives every button a
 * transition at (1,2,0); so the headline goes through the id and the button through `#forcemotion.snx-fm`. */

/* The Persian homepage loads no Inter (the Turkish one has it from Google Fonts): the name takes the page's own
   faces, beside this sheet in both runtimes (forcemotion/assets/fonts/, tools/forcemotion/build-forcemotion.mjs) */
@font-face { font-family: "FM Inter"; src: url("forcemotion/assets/fonts/inter-600.woff2") format("woff2"); font-style: normal; font-weight: 600; font-display: swap; }
@font-face { font-family: "FM Inter"; src: url("forcemotion/assets/fonts/inter-700.woff2") format("woff2"); font-style: normal; font-weight: 700 800; font-display: swap; }

#forcemotion.snx-fm {
  --u: 1px;
  --fm-frame: #0d0e0d;
  container-type: inline-size;
  padding-block: 72px;
  border-top: 1px solid rgba(255, 255, 255, .05);
}
#forcemotion .fm-bloom { position: absolute; z-index: 0; inset-inline-end: -12%; top: 4%; width: min(760px, 90vw); aspect-ratio: 1; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(230, 186, 90, .16), rgba(230, 186, 90, .05) 55%, transparent); filter: blur(20px); }

/* ───────────────────────── one column (phones, tablets, portrait) ───────────────────────── */
#forcemotion .fm__in { display: grid; grid-template-areas: "head" "stage" "body"; row-gap: 28px; }
#forcemotion .fm__head { grid-area: head; text-align: center; }
#forcemotion .fm__stage { grid-area: stage; }
#forcemotion .fm__body { grid-area: body; text-align: center; }
#forcemotion .fm__head .snx-eyebrow { justify-content: center; margin-bottom: 14px !important; }
#forcemotion .fm-new { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: 999px; border: 1px solid rgba(245, 210, 138, .45);
  color: var(--edge); font: 700 11px/1 Inter, system-ui, sans-serif; letter-spacing: .14em; direction: ltr; }

/* «Introducing» / «معرفی», then the name: Inter in the house gold, in every language */
#forcemotion #forcemotion-title { display: grid; gap: 6px; margin: 0; color: var(--ink); line-height: 1.1; }
#forcemotion .fm-intro { font-size: 22px; color: var(--soft); }
#forcemotion .fm-name { display: block; font-family: Inter, system-ui, sans-serif !important; font-weight: 800 !important; font-size: clamp(36px, 12cqw, 64px);
  letter-spacing: -.045em; line-height: 1; white-space: nowrap; direction: ltr; unicode-bidi: isolate;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
#forcemotion .fm-name i { font-style: normal; font-weight: 600; letter-spacing: -.02em; opacity: .9; }
#forcemotion.snx--fa .fm-name { font-family: "FM Inter", Inter, system-ui, sans-serif !important; }
#forcemotion .fm-lead { margin: 18px auto 0; max-width: 34em; font-size: 15px; }

/* the three steps, a row of numbered marks */
#forcemotion .fm-steps { display: grid; gap: 10px; margin: 0 auto; padding: 0; list-style: none; max-width: 420px; text-align: start; }
#forcemotion .fm-steps li { display: grid; grid-template-columns: 34px 1fr; align-items: center; gap: 12px; min-height: 44px; color: var(--ink); font-size: 14.5px; line-height: 1.6; }
#forcemotion .fm-steps b { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1px solid rgba(245, 210, 138, .4); color: var(--edge);
  font: 700 14px/1 Inter, IranSans, system-ui, sans-serif; font-variant-numeric: tabular-nums; }
#forcemotion .fm-facts { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 22px 0 0; padding: 0; list-style: none; }
#forcemotion .fm-facts li { display: inline-flex; align-items: center; gap: 8px; min-height: 36px; padding: 0 14px; border-radius: 999px; color: var(--soft); font-size: 13px; line-height: 1.5;
  background: rgba(255, 255, 255, .045); box-shadow: inset 0 0 0 1px var(--hair); }
#forcemotion .fm-facts li b { color: var(--gold); font-weight: 800; }
#forcemotion .fm-cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 26px; }
#forcemotion .fm-cta__name { font-family: "FM Inter", Inter, system-ui, sans-serif !important; font-weight: 700; line-height: 1.2; letter-spacing: 0; direction: ltr; unicode-bidi: isolate; }

/* the sample: 9:16, a gold hairline, the poster under the video */
#forcemotion .fm-frame { position: relative; width: min(100%, 300px); margin: 0 auto; aspect-ratio: 9 / 16; border-radius: 26px; overflow: hidden; isolation: isolate;
  background: var(--fm-frame); box-shadow: 0 40px 90px rgba(0, 0, 0, .55), 0 0 0 1px rgba(255, 255, 255, .04); -webkit-user-select: none; user-select: none; }
#forcemotion .fm-frame::after { content: ""; position: absolute; inset: 0; z-index: 5; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(145deg, rgba(247, 215, 133, .55), rgba(230, 186, 90, .14) 38%, rgba(230, 186, 90, .05) 62%, rgba(247, 215, 133, .4));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
#forcemotion .fm-frame :is(img, video) { position: absolute; inset: 0; width: 100%; height: 100%; display: block; object-fit: cover; }
#forcemotion .fm-frame video { opacity: 0; transition: opacity .3s ease; }
#forcemotion .fm-frame video.is-ready { opacity: 1; }
#forcemotion .fm-tag { position: absolute; inset-inline: 12px; top: 12px; z-index: 6; display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0; pointer-events: none; }
#forcemotion .fm-tag b, #forcemotion .fm-tag span { display: inline-flex; align-items: center; min-height: 26px; padding: 0 10px; border-radius: 999px; font-size: 11.5px; line-height: 1;
  background: rgba(9, 10, 9, .62); -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
#forcemotion .fm-tag b { color: var(--edge); font: 700 11.5px/1 Inter, system-ui, sans-serif; direction: ltr; }
#forcemotion .fm-tag span { color: var(--ink); }

#forcemotion.snx-fm .fm-play { position: absolute; z-index: 7; inset-inline-end: 12px; bottom: 12px; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, .2); border-radius: 50%; color: var(--ink); background: rgba(9, 10, 9, .5); -webkit-backdrop-filter: blur(14px) saturate(160%); backdrop-filter: blur(14px) saturate(160%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .16); -webkit-tap-highlight-color: transparent; transition: transform .1s ease-out, border-color .2s ease; }
#forcemotion.snx-fm .fm-play:hover { border-color: rgba(232, 212, 168, .4); }
#forcemotion.snx-fm .fm-play:active { transform: scale(.97); }
#forcemotion.snx-fm .fm-play:focus-visible { outline: 2px solid var(--edge); outline-offset: 3px; }
#forcemotion .fm-play svg { width: 18px; height: 18px; fill: currentColor; }
#forcemotion .fm-play .fm-i-play, #forcemotion .fm-play[aria-pressed="true"] .fm-i-pause { display: none; }
#forcemotion .fm-play[aria-pressed="true"] .fm-i-play { display: block; }

/* arrival (only once the script has armed it, so a page without script shows everything) */
#forcemotion.fm-arm .fm__head, #forcemotion.fm-arm .fm__body { opacity: 0; transform: translateY(14px); transition: opacity .5s ease, transform .7s var(--spring); }
#forcemotion.fm-arm .fm-frame { opacity: 0; transform: scale(.965); filter: blur(10px); transition: opacity .45s ease, transform .8s var(--spring), filter .55s ease; }
#forcemotion.fm-arm .fm__body { transition-delay: .08s; }
#forcemotion.fm-arm.is-in .fm__head, #forcemotion.fm-arm.is-in .fm__body { opacity: 1; transform: none; }
#forcemotion.fm-arm.is-in .fm-frame { opacity: 1; transform: none; filter: none; }

@container (max-width: 380px) {
  #forcemotion .fm-frame { border-radius: 22px; }
  #forcemotion .fm-steps li { font-size: 14px; }
}

/* ──────────── a landscape screen ≥1024: the 1280 × 720 composition at --u = 1px ──────────── */
@media (min-width: 1024px) and (min-aspect-ratio: 5/6) {
  #forcemotion.snx-fm {
    --fm-head: calc(max(clamp(128px, 11vw, 176px) * 370 / 1200, 44px) + 29px);
    --u: clamp(.6px, min(calc(100cqw / 1280), calc((100svh - var(--fm-head) - 24px) / 720)), 1px);
    display: grid; align-items: center; min-height: calc(100svh - var(--fm-head)); padding-block: calc(24 * var(--u));
  }
  #forcemotion .fm__in { grid-template-columns: calc(600 * var(--u)) calc(380 * var(--u)); grid-template-rows: 1fr 1fr; grid-template-areas: "head stage" "body stage";
    row-gap: 0; column-gap: calc(140 * var(--u)); justify-content: center; align-items: center; width: auto; margin-inline: auto; }
  #forcemotion .fm__head { align-self: end; text-align: start; }
  #forcemotion .fm__head .snx-eyebrow { justify-content: flex-start; margin-bottom: calc(20 * var(--u)) !important; }
  #forcemotion .fm__body { align-self: start; text-align: start; }
  #forcemotion .fm-intro { font-size: calc(30 * var(--u)); }
  #forcemotion .fm-name { font-size: calc(84 * var(--u)); }   /* about 7em wide: inside its 600 column */
  #forcemotion .fm-lead { margin: calc(22 * var(--u)) 0 0; font-size: max(15px, calc(18.5 * var(--u))); }
  #forcemotion .fm-steps { margin: calc(4 * var(--u)) 0 0; max-width: none; gap: calc(10 * var(--u)); }
  #forcemotion .fm-steps li { font-size: max(14px, calc(16 * var(--u))); }
  #forcemotion .fm-facts { justify-content: flex-start; margin-top: calc(24 * var(--u)); }
  #forcemotion .fm-cta { justify-content: flex-start; margin-top: calc(28 * var(--u)); }
  #forcemotion .fm-frame { width: calc(380 * var(--u)); border-radius: calc(32 * var(--u)); }
  #forcemotion .fm-bloom { inset-inline-end: 4%; top: 50%; transform: translateY(-50%); width: calc(760 * var(--u)); }
}

@media (prefers-reduced-motion: reduce) {
  #forcemotion.fm-arm :is(.fm__head, .fm__body, .fm-frame) { opacity: 1; transform: none; filter: none; transition: none; }
  #forcemotion .fm-frame video { transition: none; }
}
@media (prefers-reduced-transparency: reduce) {
  #forcemotion.snx-fm .fm-play, #forcemotion .fm-tag :is(b, span) { -webkit-backdrop-filter: none; backdrop-filter: none; background: #1a1b1a; }
}
@media (prefers-contrast: more) {
  #forcemotion .fm-facts li { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5); }
  #forcemotion.snx-fm .fm-play { border-color: rgba(255, 255, 255, .6); }
}
@media (forced-colors: active) {
  #forcemotion .fm-name { color: CanvasText; background: none; }
  #forcemotion.snx-fm .fm-play { border: 2px solid ButtonText; }
}
