/* مِسنَد — home3d.css (الصفحة الرئيسية بس)
   الشعار صور جاهزة مرندرة، والحركة كلها transform وopacity، فما فيه WebGL ولا
   فيديو يشتغل إلا اللي قدام الزائر. خصائص منطقية فقط. */

:root {
  color-scheme: dark;
  --bg: #080b0a;
  --raise: #141c19;
  --line: #1e2926;
  --rule: #2a3a36;
  --fg: #e8efec;
  --muted: #8fa39d;
  --faint: #657872;
  --teal: #2dd4bf;
  --on-teal: #04201c;
  --sans: "IBM Plex Sans Arabic", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  /* طول الشعار في أول شاشة، ومكانه فوق العنوان */
  --logo-h: min(50vh, 640px);
  --logo-h: min(50svh, 640px);
  --logo-ar: 0.3169;
  --slot: clamp(200px, calc(100vh - 580px), 500px);
  --slot: clamp(200px, calc(100svh - 580px), 500px);
  --hero-top: 78px;
}
@media (max-width: 760px) {
  :root {
    --logo-h: min(40vh, 480px);
    --logo-h: min(40svh, 480px);
    --slot: clamp(170px, 26vh, 400px);
    --slot: clamp(170px, 26svh, 400px);
    --hero-top: 66px;
  }
}

* { box-sizing: border-box; margin: 0; padding: 0; }
/* لا overflow-x على html: يعطّل position: sticky للأقسام المثبّتة */
html { background: var(--bg); scroll-behavior: smooth; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  color: var(--fg);
  font-family: var(--sans);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  overflow-x: clip;
}
img, video { display: block; max-inline-size: 100%; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--teal); outline-offset: 3px; border-radius: 6px; }
::selection { background: rgba(45, 212, 191, 0.3); color: #fff; }
.wrap { max-inline-size: 1080px; margin-inline: auto; padding-inline: 24px; }
.sr { position: absolute; inline-size: 1px; block-size: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip {
  position: absolute;
  inset-inline-start: 16px;
  inset-block-start: -100px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--teal);
  color: var(--on-teal);
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { inset-block-start: 12px; }

/* ── النجوم: طبقة واحدة ترتسم مرة وحدة، وبدون سكربت ── */
.sky {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background:
    radial-gradient(1.4px 1.4px at 22px 34px, rgba(232, 239, 236, 0.75) 50%, transparent 51%) 0 0 / 173px 173px,
    radial-gradient(1px 1px at 96px 120px, rgba(232, 239, 236, 0.5) 50%, transparent 51%) 0 0 / 211px 211px,
    radial-gradient(1.2px 1.2px at 140px 40px, rgba(45, 212, 191, 0.6) 50%, transparent 51%) 0 0 / 263px 263px,
    radial-gradient(1px 1px at 60px 200px, rgba(232, 239, 236, 0.35) 50%, transparent 51%) 0 0 / 317px 317px,
    radial-gradient(1.6px 1.6px at 240px 90px, rgba(255, 255, 255, 0.8) 50%, transparent 51%) 0 0 / 389px 389px,
    radial-gradient(1px 1px at 300px 310px, rgba(112, 225, 212, 0.55) 50%, transparent 51%) 0 0 / 449px 449px,
    radial-gradient(1.3px 1.3px at 410px 170px, rgba(232, 239, 236, 0.6) 50%, transparent 51%) 0 0 / 523px 523px;
}

/* ── المشهد الثابت: الشعار والمنيوهات اللي تلف حوله ── */
.scene { position: absolute; inset-block-start: 0; inset-inline: 0; block-size: 100vh; block-size: 100svh; z-index: 0; overflow: hidden; pointer-events: none; }
.m3 .scene { position: fixed; }
.rig {
  position: absolute;
  inset: 0;
  margin: auto;
  block-size: var(--logo-h);
  inline-size: calc(var(--logo-h) * var(--logo-ar));
  z-index: 10;
  /* مكانه قبل ما يوصل السكربت: فوق العنوان، فما يقفز */
  transform: translate3d(0, calc(var(--hero-top) + var(--slot) / 2 - 50vh), 0);
  transform: translate3d(0, calc(var(--hero-top) + var(--slot) / 2 - 50svh), 0);
}
.rig::before {
  content: "";
  position: absolute;
  inset: -8% -70%;
  background: radial-gradient(closest-side, rgba(45, 212, 191, 0.26), rgba(45, 212, 191, 0.09) 55%, transparent);
  pointer-events: none;
}
.rig canvas, .rig img { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: contain; }

/* المنيوهات: مخفية لين يوصلها الزائر، وتترتب مع الشعار بـ z-index */
.orbit { display: none; }
.m3 .orbit { display: block; }
.orbit .look {
  position: absolute;
  inset: 0;
  margin: auto;
  inline-size: var(--look-w);
  block-size: calc(var(--look-w) * 2.165);
  visibility: hidden;
  pointer-events: auto;
  /* السحب يمين ويسار للدوران، وفوق وتحت يبقى للمتصفح يمرّر الصفحة */
  touch-action: pan-y pinch-zoom;
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
  user-select: none;
}
.orbit .look img { -webkit-user-drag: none; }
.orbit .look b, .orbit .look .look-line { display: none; }
.orbit.live .look { will-change: transform, opacity; }
.orbit { --look-w: 120px; }
/* تمسك السحب في أي مكان حول الشعار، مو بس فوق الأشكال */
.orbit-grab { position: absolute; inset: 0; touch-action: pan-y pinch-zoom; }
.orbit.live .orbit-grab { pointer-events: auto; cursor: grab; }
.orbit.dragging .orbit-grab, .orbit.dragging .look { cursor: grabbing; }

/* ── الترويسة ── */
header { position: sticky; top: 14px; z-index: 50; padding-inline: 16px; pointer-events: none; }
header .wrap { padding-inline: 16px 9px; }
.nav {
  position: relative;
  pointer-events: auto;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 14px;
  padding-block: 8px;
  padding-inline: 14px 8px;
  border-radius: 999px;
  /* بدون blur: ضبابية الخلفية فوق شيء يتحرك هي أكبر سبب للتقطيع في الجوال */
  background: linear-gradient(180deg, rgba(15, 26, 23, 0.94), rgba(10, 18, 16, 0.96));
  border: 1px solid rgba(45, 212, 191, 0.15);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.brand { display: flex; align-items: center; gap: 10px; color: var(--fg); text-decoration: none; }
.mark { display: block; inline-size: 34px; block-size: 34px; }
.mark img { inline-size: 100%; block-size: 100%; object-fit: contain; }
.bname { display: flex; flex-direction: column; line-height: 1.2; }
.bname b { font-size: 1.05rem; font-weight: 700; white-space: nowrap; }
.bname i { font: normal 500 0.62rem/1.2 var(--mono); color: var(--faint); letter-spacing: 0.1em; }
/* الصفحة الإنجليزية: الاسم العربي الصغير تحت «Misnad»، بدون تباعد يقطّع الحروف */
.bname i:lang(ar) { font: normal 500 0.7rem/1.2 var(--sans); letter-spacing: 0; }
.dock { display: flex; gap: 2px; }
.dock a {
  padding: 7px 12px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.86rem;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.2s, background 0.2s;
}
.dock a:hover { color: var(--fg); }
.dock a.on { color: var(--teal); background: rgba(45, 212, 191, 0.1); }
.nav-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; }
.nav-login { color: var(--muted); font-size: 0.86rem; text-decoration: none; }
.nav-login:hover { color: var(--fg); }
/* «EN / ع»: the other language's page, always in sight (the phone too) */
.lang {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  min-inline-size: 38px;
  block-size: 38px;
  padding-inline: 10px;
  border: 1px solid rgba(45, 212, 191, 0.2);
  border-radius: 999px;
  background: rgba(10, 22, 19, 0.65);
  color: var(--fg);
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-decoration: none;
}
.lang:lang(ar) { font-size: 1rem; letter-spacing: 0; }
.lang:hover { border-color: var(--teal); color: var(--teal); }
.menu-btn {
  display: none;
  inline-size: 40px;
  block-size: 40px;
  flex: none;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(45, 212, 191, 0.2);
  border-radius: 999px;
  background: rgba(10, 22, 19, 0.65);
  cursor: pointer;
}
.menu-btn i, .menu-btn i::before, .menu-btn i::after {
  display: block;
  inline-size: 17px;
  block-size: 1.5px;
  border-radius: 2px;
  background: var(--fg);
  transition: transform 0.25s, background 0.25s;
}
.menu-btn i { position: relative; }
.menu-btn i::before, .menu-btn i::after { content: ""; position: absolute; inset-inline: 0; }
.menu-btn i::before { transform: translateY(-5.5px); }
.menu-btn i::after { transform: translateY(5.5px); }
.menu-btn[aria-expanded="true"] i { background: transparent; }
.menu-btn[aria-expanded="true"] i::before { transform: rotate(45deg); }
.menu-btn[aria-expanded="true"] i::after { transform: rotate(-45deg); }
.menu-panel {
  position: absolute;
  inset-inline: 0;
  inset-block-start: calc(100% + 10px);
  z-index: 60;
  display: none;
  gap: 2px;
  padding: 10px;
  border-radius: 20px;
  background: #0e1a17;
  border: 1px solid rgba(45, 212, 191, 0.18);
  box-shadow: 0 22px 50px rgba(0, 0, 0, 0.65);
}
.menu-panel.open { display: grid; }
.menu-panel a { display: flex; flex-direction: column; gap: 2px; padding: 12px 16px; border-radius: 13px; color: var(--fg); text-decoration: none; }
.menu-panel a:active, .menu-panel a:hover { background: rgba(45, 212, 191, 0.09); }
.menu-panel b { font-weight: 600; font-size: 0.97rem; }
.menu-panel span { font-size: 0.76rem; color: var(--faint); }
@media (max-width: 860px) {
  header { top: 10px; padding-inline: 12px; }
  .nav { grid-template-columns: 1fr auto; gap: 10px; padding-block: 8px; }
  header .wrap { padding-inline: 12px 8px; }
  .dock, .nav-login { display: none; }
  .menu-btn { display: flex; }
}
@media (max-width: 360px) { .bname i { display: none; } }

/* ── الأزرار ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 24px;
  border-radius: 11px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.16s, box-shadow 0.16s, border-color 0.16s, color 0.16s;
}
.btn-1 { background: var(--teal); color: var(--on-teal); box-shadow: 0 8px 26px rgba(45, 212, 191, 0.2); }
.btn-2 { border: 1px solid var(--rule); color: var(--fg); background: rgba(8, 11, 10, 0.55); }
@media (hover: hover) {
  .btn-1:hover { transform: translateY(-2px); box-shadow: 0 12px 34px rgba(45, 212, 191, 0.3); }
  .btn-2:hover { border-color: var(--teal); color: var(--teal); }
  .btn-nav:hover { border-color: var(--teal); color: var(--teal); }
  .nav .nav-cta:hover { transform: none; box-shadow: 0 4px 16px rgba(45, 212, 191, 0.28); }
}
/* نفس لون القائمة فوق */
.btn-nav {
  border: 1px solid rgba(45, 212, 191, 0.22);
  background: linear-gradient(180deg, rgba(15, 26, 23, 0.94), rgba(10, 18, 16, 0.96));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.07);
  color: var(--fg);
}
/* زر القائمة: داخلها، وطرفه يتبع طرفها */
.nav .nav-cta {
  padding: 9px 18px;
  border-radius: 999px;
  font-size: 0.85rem;
  line-height: 1.45;
  white-space: nowrap;
  box-shadow: 0 2px 10px rgba(45, 212, 191, 0.16);
}
.pill-btn {
  padding: 6px 16px;
  border-radius: 999px;
  font: 600 0.82rem/1.5 var(--sans);
  cursor: pointer;
}

/* ── البطل ── */
main { position: relative; z-index: 1; }
.hero-in { padding: var(--hero-top) 24px 54px; text-align: center; }
.logo-slot { block-size: var(--slot); }
h1 {
  font-size: clamp(2.1rem, 5.6vw, 3.7rem);
  font-weight: 700;
  line-height: 1.16;
  margin-block-end: 14px;
  text-wrap: balance;
  text-shadow: 0 2px 22px var(--bg), 0 0 5px var(--bg);
}
h1 em { font-style: normal; color: var(--teal); }
.tagline { color: var(--teal); font-size: clamp(1.02rem, 2.2vw, 1.28rem); font-weight: 500; margin-block-end: 10px; text-shadow: 0 1px 16px var(--bg); }
.lead { color: var(--muted); font-size: clamp(0.88rem, 1.6vw, 1rem); line-height: 1.7; max-inline-size: 780px; margin-inline: auto; margin-block-end: 22px; text-shadow: 0 1px 14px var(--bg); }
.cta { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.lead span { display: block; text-wrap: balance; }
.lead span + span { margin-block-start: 5px; }
.hero-meta { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 18px; margin-block-start: 18px; color: var(--muted); font-size: 0.85rem; }
.hero-meta li { display: flex; align-items: center; gap: 7px; }
.hero-meta li::before { content: ""; inline-size: 5px; block-size: 5px; border-radius: 50%; background: var(--teal); }

/* ── عناوين الأقسام ── */
.eyebrow { color: var(--teal); font-size: 0.78rem; letter-spacing: 0.04em; margin-block-end: 8px; text-align: center; }
h2 { font-size: clamp(1.5rem, 3.2vw, 2.1rem); font-weight: 700; line-height: 1.3; margin-block-end: 10px; text-align: center; text-wrap: balance; }
.sub { color: var(--muted); max-inline-size: 640px; margin-inline: auto; margin-block-end: 34px; text-align: center; }

/* ── الأقسام المثبّتة ── */
.pin { padding-block: 70px; }
.m3 .pin {
  position: sticky;
  inset-block-start: 0;
  block-size: 100vh;
  block-size: 100svh;
  padding-block: 80px 18px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.pin-head { flex: none; padding-inline: 24px; }
.m3 .reel { block-size: 280vh; block-size: 280svh; }
.m3 .spin { block-size: 320vh; block-size: 320svh; }

/* ── الفيديوهات ── */
.reel-stage { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); max-inline-size: 1080px; margin-inline: auto; padding-inline: 24px; }
.reel-card { display: block; color: var(--fg); text-decoration: none; }
.reel-media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: 18px;
  background: #0d1a17;
  border: 1px solid rgba(45, 212, 191, 0.3);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55);
}
.reel-media img, .reel-media video { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: cover; }
.reel-media video { opacity: 0; transition: opacity 0.35s; }
.reel-media video.on { opacity: 1; }
.reel-text { display: block; padding-block-start: 12px; text-align: center; }
.reel-text b { display: block; font-size: 1.02rem; font-weight: 700; }
.reel-text i { display: block; color: var(--muted); font-style: normal; font-size: 0.82rem; line-height: 1.5; }
/* لما يشتغل الشريط: الصور والفيديو تترسم داخل اللوحة، والرابط والعنوان يبقون فوقها */
.reel-gl { position: absolute; inset-block-start: -70px; inset-inline: 0; inline-size: 100%; block-size: calc(100% + 140px); pointer-events: none; }
.reel-stage.gl .reel-media { background: none; border-color: transparent; box-shadow: none; }
.reel-stage.gl .reel-media img, .reel-stage.gl .reel-media video { opacity: 0; }
.reel-cap, .rail, .spin-cap { display: none; }
.m3 .reel-stage { position: relative; display: block; flex: 1 1 auto; min-block-size: 0; inline-size: 100%; max-inline-size: none; margin: 0; padding: 0; }
.m3 .reel-card {
  position: absolute;
  inset: 0;
  margin: auto;
  inline-size: clamp(230px, 34vw, 470px);
  block-size: fit-content;
  visibility: hidden;
}
/* السحب يمين ويسار يحرك الشريط، وفوق وتحت يبقى للمتصفح يمرّر الصفحة */
.m3 .reel-stage, .m3 .reel-card {
  touch-action: pan-y pinch-zoom;
  -webkit-touch-callout: none;
  -webkit-user-drag: none;
  user-select: none;
}
.m3 .reel-stage { cursor: grab; }
.m3 .reel-stage.dragging, .m3 .reel-stage.dragging .reel-card { cursor: grabbing; }
.m3 .reel-card img { -webkit-user-drag: none; }
html:not(.keys) .reel-card:focus-visible, html:not(.keys) .sheet-x:focus-visible { outline: none; }
.m3 .reel-cap { display: grid; flex: none; justify-items: center; padding-inline: 24px; }
.m3 .rail { display: block; flex: none; inline-size: min(100% - 48px, 1032px); block-size: 2px; margin-block-start: 14px; margin-inline: auto; border-radius: 99px; background: var(--line); overflow: hidden; }
.rail i { display: block; block-size: 100%; background: var(--teal); transform: scaleX(0); transform-origin: right; }
[dir="ltr"] .rail i { transform-origin: left; }
@media (max-width: 760px) {
  .m3 .reel-card { inline-size: 64vw; }
  .reel-text b { font-size: 0.96rem; }
  .reel-text i { font-size: 0.76rem; }
}

/* ── أشكال المنيو ── */
.looks {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-block: 10px 18px;
  padding-inline: 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--rule) transparent;
}
.m3 .looks { display: none; }
main.through { pointer-events: none; }
main.through a, main.through button { pointer-events: auto; }
.look { flex: none; inline-size: 170px; scroll-snap-align: center; color: var(--fg); text-decoration: none; }
.look-phone {
  display: block;
  inline-size: 100%;
  aspect-ratio: 480 / 1039;
  overflow: hidden;
  border-radius: 20px;
  background: var(--raise);
  border: 1px solid rgba(45, 212, 191, 0.28);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.6);
}
.look-phone img { inline-size: 100%; block-size: 100%; object-fit: cover; }
.look b { display: block; margin-block-start: 8px; font-weight: 600; }
.look-line { display: block; color: var(--muted); font-size: 0.78rem; line-height: 1.5; }
.spin-slot { display: none; }
.m3 .spin-slot { display: block; flex: 1 1 auto; min-block-size: 0; }
.m3 .spin-cap { display: grid; flex: none; justify-items: center; gap: 2px; padding-inline: 24px; text-align: center; }
.spin-cap b { font-size: 1.3rem; font-weight: 700; text-shadow: 0 1px 14px var(--bg); }
.spin-cap > span { color: var(--muted); font-size: 0.86rem; text-shadow: 0 1px 10px var(--bg); }
.spin-actions { display: flex; gap: 10px; margin-block-start: 8px; }
.spin-actions .btn { padding: 9px 18px; font-size: 0.88rem; }

/* ── الشاشات في إطار آيفون ── */
.demos { padding-block: 84px 20px; }
.demo {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 40px;
  max-inline-size: 1080px;
  margin-inline: auto;
  padding: 40px 24px;
  content-visibility: auto;
  contain-intrinsic-size: auto 720px;
}
.demo.flip .demo-copy { order: 2; }
.demo-copy .eyebrow { text-align: start; }
.demo-copy h3 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 700; line-height: 1.3; margin-block-end: 10px; text-wrap: balance; }
.demo-lead { color: var(--muted); margin-block-end: 14px; }
.demo-list { list-style: none; display: grid; gap: 9px; margin-block-end: 22px; color: #bccbc6; font-size: 0.94rem; line-height: 1.6; }
.demo-list li { display: flex; gap: 10px; }
.demo-list li::before { content: "✓"; flex: none; color: var(--teal); }
.demo-phones { position: relative; display: flex; justify-content: center; align-items: center; min-block-size: 0; }
.demo-glow {
  position: absolute;
  inset: 4% -6%;
  background: radial-gradient(closest-side, rgba(45, 212, 191, 0.2), rgba(45, 212, 191, 0.06) 60%, transparent);
  pointer-events: none;
}
.demo-phones.two .iphone { --w: min(268px, 56vw); }
.demo-phones.two .iphone.back { --w: min(206px, 40vw); margin-inline-end: -9%; transform: translateY(-4%); }
.demo-phones.two .iphone:not(.back) { transform: translateY(5%); z-index: 1; }
.demo.wait .demo-phones, .demo.wait .demo-copy { opacity: 0; transform: translateY(26px); }
.demo.in .demo-phones, .demo.in .demo-copy { opacity: 1; transform: none; transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.2, 0.7, 0.2, 1); }

/* إطار آيفون: كله CSS، وبدون صور */
.iphone { --w: min(288px, 72vw); --bar: #000; --bar-fg: #fff; --phone-font: -apple-system, "SF Pro Display", "Helvetica Neue", Arial, sans-serif; position: relative; flex: none; inline-size: var(--w); }
.iphone-frame {
  position: relative;
  display: block;
  padding: calc(var(--w) * 0.032);
  border-radius: calc(var(--w) * 0.165);
  background: linear-gradient(145deg, #5d6864 0%, #252b29 22%, #15191a 52%, #2d3331 80%, #6c7773 100%);
  box-shadow:
    0 30px 60px -18px rgba(0, 0, 0, 0.85),
    0 0 0 1px rgba(255, 255, 255, 0.06),
    inset 0 0 0 1.5px rgba(255, 255, 255, 0.14),
    inset 0 0 0 3px #050606;
}
/* الأزرار الجانبية */
.iphone-frame::before, .iphone-frame::after {
  content: "";
  position: absolute;
  inline-size: 3px;
  border-radius: 2px;
  background: linear-gradient(180deg, #4d5653, #2a302e);
}
.iphone-frame::before { inset-inline-start: -2px; inset-block-start: 24%; block-size: 12%; box-shadow: 0 calc(var(--w) * 0.2) 0 #363c3a; }
.iphone-frame::after { inset-inline-end: -2px; inset-block-start: 29%; block-size: 16%; }
.iphone-screen {
  position: relative;
  display: flex;
  flex-direction: column;
  aspect-ratio: 390 / 844;
  overflow: hidden;
  border-radius: calc(var(--w) * 0.135);
  background: var(--bar);
}
/* لمعة زجاج خفيفة */
.iphone-screen::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(118deg, rgba(255, 255, 255, 0.07) 0%, rgba(255, 255, 255, 0) 30%);
  pointer-events: none;
}
.iphone-bar {
  position: relative;
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  block-size: 6.4%;
  padding-inline: 8%;
  color: var(--bar-fg);
  font-size: calc(var(--w) * 0.045);
  background: var(--bar);
}
.iphone-bar b { font-family: var(--phone-font); font-weight: 600; }
.bar-icons { display: flex; align-items: center; gap: 4px; }
.bar-icons svg { block-size: calc(var(--w) * 0.038); inline-size: auto; }
.island {
  position: absolute;
  inset-block-start: 26%;
  inset-inline: 0;
  margin-inline: auto;
  inline-size: 31%;
  block-size: 62%;
  border-radius: 99px;
  background: #000;
}
.iphone-screen > img { display: block; inline-size: 100%; block-size: auto; flex: 1 1 auto; min-block-size: 0; object-fit: cover; object-position: top; }

/* شاشة المحفظة */
.wallet { flex: 1 1 auto; display: block; padding: 7% 4%; background: #000; }
.wallet img { display: block; inline-size: 100%; block-size: auto; border-radius: calc(var(--w) * 0.045); }

/* شاشة القفل: بطاقة الطلب مثل واجهة التطبيق المصغر، وتحتها التنبيه */
.lock {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(var(--w) * 0.024);
  padding: 4% 4% 6%;
  color: #fff;
  background: radial-gradient(110% 60% at 50% 12%, #0f5f55 0%, #0a2f2a 48%, #051412 100%);
}
.lock-date { font-size: calc(var(--w) * 0.05); font-weight: 500; opacity: 0.9; }
.lock-time { font: 600 calc(var(--w) * 0.215)/1.05 var(--phone-font); margin-block-end: auto; }
.live {
  inline-size: 100%;
  padding: calc(var(--w) * 0.044);
  border-radius: calc(var(--w) * 0.075);
  background: #141c19;
  color: #e8efec;
  font-size: calc(var(--w) * 0.04);
  line-height: 1.35;
}
.live-top { display: flex; align-items: center; gap: calc(var(--w) * 0.028); }
.live-tile {
  flex: none;
  display: grid;
  place-items: center;
  inline-size: calc(var(--w) * 0.115);
  block-size: calc(var(--w) * 0.115);
  border-radius: 26%;
  background: var(--teal);
  color: var(--on-teal);
  font-weight: 700;
  font-size: calc(var(--w) * 0.058);
}
.live-name { flex: 1; min-inline-size: 0; display: grid; }
.live-name b { font-weight: 600; font-size: calc(var(--w) * 0.044); }
.live-name span { color: var(--muted); font-size: calc(var(--w) * 0.036); }
.live-time { color: var(--muted); font-weight: 600; font-size: calc(var(--w) * 0.04); }
.live-state { display: flex; align-items: baseline; justify-content: space-between; margin-block-start: calc(var(--w) * 0.024); }
.live-state b { color: var(--teal); font-size: calc(var(--w) * 0.074); font-weight: 700; }
.live-state strong { font: 800 calc(var(--w) * 0.074)/1.2 var(--phone-font); }
.live-detail { display: block; color: var(--muted); font-size: calc(var(--w) * 0.036); }
.live-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: calc(var(--w) * 0.02); margin-block-start: calc(var(--w) * 0.028); font-size: calc(var(--w) * 0.03); text-align: center; }
.live-steps i { display: block; block-size: calc(var(--w) * 0.016); margin-block-end: calc(var(--w) * 0.012); border-radius: 99px; background: var(--teal); }
.lock-note {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: calc(var(--w) * 0.028);
  inline-size: 100%;
  padding: calc(var(--w) * 0.034);
  border-radius: calc(var(--w) * 0.066);
  background: rgba(240, 248, 245, 0.94);
  color: #0d1513;
  font-size: calc(var(--w) * 0.037);
  line-height: 1.35;
}
.lock-icon { flex: none; display: grid; place-items: center; inline-size: calc(var(--w) * 0.1); block-size: calc(var(--w) * 0.1); overflow: hidden; border-radius: 24%; background: #0a1a17; }
.lock-icon img { inline-size: 24%; block-size: auto; }
.lock-text { flex: 1; display: grid; gap: 1px; min-inline-size: 0; }
.lock-text b { font-weight: 700; }
.lock-note em { position: absolute; inset-block-start: calc(var(--w) * 0.034); inset-inline-end: calc(var(--w) * 0.04); font-style: normal; opacity: 0.55; font-size: 0.9em; }

/* تتبع الحملات: شاشة لابتوب */
.camp { max-inline-size: 1280px; margin-inline: auto; padding: 64px 24px 30px; content-visibility: auto; contain-intrinsic-size: auto 1000px; }
.camp-head { max-inline-size: 680px; margin-inline: auto; margin-block-end: 30px; text-align: center; }
.camp-head h3 { font-size: clamp(1.4rem, 3vw, 2rem); font-weight: 700; line-height: 1.3; margin-block-end: 10px; text-wrap: balance; }
.camp .laptop { position: relative; max-inline-size: 1200px; margin-inline: auto; padding-inline: 4%; }
#campDemo { scroll-margin-block-start: 96px; }
.camp-try { margin-block-end: 18px; text-align: center; color: var(--teal); font-size: 0.92rem; line-height: 1.6; text-wrap: balance; }
.laptop .demo-glow { inset: -6% -2%; }
.laptop-lid {
  position: relative;
  display: block;
  padding: 1.5% 1.5% 1.8%;
  border-radius: 14px 14px 4px 4px;
  background: #0a0c0c;
  box-shadow: 0 0 0 1px #3c4543, 0 0 0 2px #171b1a, 0 40px 70px -28px rgba(0, 0, 0, 0.9);
}
.laptop-cam { position: absolute; inset-block-start: 0.55%; inset-inline: 0; margin-inline: auto; inline-size: 5px; block-size: 5px; border-radius: 50%; background: #1d2625; }
.laptop-screen { display: block; aspect-ratio: 16 / 10; overflow: hidden; border-radius: 3px; background: #0a1210; }
.laptop-screen img { inline-size: 100%; block-size: 100%; object-fit: cover; object-position: top; }
.laptop-base {
  position: relative;
  display: block;
  block-size: clamp(9px, 1.9vw, 17px);
  margin-inline: -5%;
  border-radius: 2px 2px 14px 14px;
  background: linear-gradient(180deg, #58625f 0%, #2d3331 45%, #171b1a 100%);
  box-shadow: 0 16px 26px -10px rgba(0, 0, 0, 0.8);
}
.laptop-base::before {
  content: "";
  position: absolute;
  inset-block-start: 0;
  inset-inline: 0;
  margin-inline: auto;
  inline-size: 15%;
  block-size: 46%;
  border-radius: 0 0 8px 8px;
  background: #171b1a;
}
.camp-note { margin-block-start: 10px; text-align: center; color: var(--faint); font-size: 0.78rem; }
.camp-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 9px 22px;
  max-inline-size: 900px;
  margin-inline: auto;
  margin-block-start: 28px;
  color: #bccbc6;
  font-size: 0.94rem;
  line-height: 1.6;
}
.camp-list li { display: flex; gap: 10px; }
.camp-list li::before { content: "✓"; flex: none; color: var(--teal); }
.camp-foot { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-block-start: 26px; text-align: center; }
.camp-pro { font-size: clamp(1.1rem, 2.4vw, 1.35rem); font-weight: 700; color: var(--teal); }

@media (max-width: 760px) {
  .demo { grid-template-columns: minmax(0, 1fr); gap: 26px; padding-block: 34px; contain-intrinsic-size: auto 1000px; }
  .demo.flip .demo-copy { order: 0; }
  .demo-copy { text-align: center; }
  .demo-copy .eyebrow { text-align: center; }
  .demo-list { text-align: start; }
  .camp { padding-inline: 12px; }
  .camp .laptop { padding-inline: 0; }
  .laptop-lid { padding: 6px; border-radius: 12px 12px 3px 3px; }
  .laptop-cam { display: none; }
  .laptop-base { margin-inline: -1.5%; }
}

/* ── الأقسام اللي تحت: ما ترتسم لين تقرب ── */
section.later { padding-block: 76px; content-visibility: auto; contain-intrinsic-size: auto 760px; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(268px, 1fr)); }
.card {
  --glow: 0;
  --mx: 50%;
  --my: 50%;
  position: relative;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(158deg, rgba(18, 32, 28, 0.94), rgba(10, 22, 19, 0.92));
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
@media (hover: hover) and (pointer: fine) {
  .card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(240px circle at var(--mx) var(--my), rgba(45, 212, 191, 0.16), transparent 68%);
    opacity: var(--glow);
    pointer-events: none;
  }
  .card:hover { border-color: rgba(45, 212, 191, 0.35); }
}
.card > * { position: relative; }
.card h3 { font-size: 1.08rem; font-weight: 600; margin-block-end: 8px; display: flex; align-items: center; gap: 8px; }
.card p { color: var(--muted); font-size: 0.93rem; }
.stat { display: block; color: var(--teal); font-size: 1.7rem; line-height: 1.3; }
.steps { list-style: none; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.section-cta { display: flex; justify-content: center; margin-block-start: 26px; }
.feat { display: block; color: inherit; text-decoration: none; }
.feat h3::after { content: "←"; color: var(--teal); margin-inline-start: auto; }
@media (max-width: 980px) {
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .steps .card { padding: 18px; }
}

/* ── الباقات ── */
.toggle { display: flex; inline-size: fit-content; margin-inline: auto; margin-block-end: 26px; padding: 4px; border: 1px solid var(--rule); border-radius: 999px; background: #0b1512; }
.ms-toggle-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 18px; margin-block-end: 26px; }
.ms-toggle-row .toggle { margin: 0; }
.ms-features-link { color: var(--teal); font-size: 0.9rem; text-underline-offset: 4px; }
/* العملة: قائمة صغيرة جنب مفتاح شهري/سنوي (assets/currency.js) */
.ms-cur[hidden] { display: none; }
.ms-cur select { min-block-size: 38px; padding-inline: 12px 30px; border: 1px solid var(--rule); border-radius: 999px; background: #0b1512; color: var(--fg); font: 0.86rem/1.5 var(--sans); cursor: pointer; }
.ms-cur select:focus-visible { outline: 2px solid var(--teal); outline-offset: 2px; }
.ms-cur-note { flex-basis: 100%; margin: 0; text-align: center; color: var(--muted); font-size: 0.82rem; }
.ms-cur-note[hidden] { display: none; }
.plan p.ms-plan-perk { color: var(--teal); font-size: 0.86rem; line-height: 1.6; }
.plan p.ms-plan-perk a { color: inherit; text-underline-offset: 3px; }
.toggle button { padding: 7px 16px; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font: 0.86rem/1.5 var(--sans); cursor: pointer; }
.toggle button[aria-pressed="true"] { background: var(--teal); color: var(--on-teal); font-weight: 600; }
.plans { display: grid; gap: 16px; }
.plans-2 { grid-template-columns: repeat(auto-fit, minmax(290px, 1fr)); }
.plans-3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.plan { display: flex; flex-direction: column; gap: 10px; }
.plan h3 { margin: 0; font-size: 1.2rem; }
.plan .btn { margin-block-start: auto; }
.plan.best { border-color: rgba(45, 212, 191, 0.45); box-shadow: 0 16px 44px rgba(0, 0, 0, 0.3), 0 0 36px rgba(45, 212, 191, 0.1); }
.plan-badge { align-self: flex-start; padding: 3px 11px; border-radius: 99px; background: rgba(45, 212, 191, 0.12); color: var(--teal); font-size: 0.74rem; font-weight: 600; }
.card .price { color: var(--muted); font-size: 0.86rem; display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
.price b { color: var(--fg); font-size: 2.3rem; font-weight: 500; line-height: 1.15; }
.singles-title { margin-block: 34px 16px; text-align: center; font-size: 1.15rem; font-weight: 600; }
.plans-note { margin-block-start: 16px; text-align: center; color: var(--faint); font-size: 0.82rem; }
.plans-note a { color: var(--muted); }
.custom { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 18px; margin-block-start: 24px; color: inherit; text-decoration: none; }
.custom-text { flex: 1 1 280px; min-inline-size: 0; display: grid; gap: 6px; }
.custom-text b { font-size: 1.08rem; font-weight: 600; }
.custom-text > span { color: var(--muted); font-size: 0.93rem; }
.custom-price { color: var(--teal); font-weight: 600; white-space: nowrap; }
.custom-price .mono { font-size: 1.7rem; font-weight: 500; }

/* ── الأسئلة ── */
.faq { display: grid; gap: 10px; max-inline-size: 760px; margin-inline: auto; }
.faq details { padding: 14px 18px; border: 1px solid var(--line); border-radius: 14px; background: rgba(14, 26, 23, 0.92); }
.faq details[open] { border-color: rgba(45, 212, 191, 0.3); }
.faq summary { cursor: pointer; font-weight: 600; }
.faq details p { margin-block-start: 8px; color: var(--muted); font-size: 0.93rem; }
.final { text-align: center; }

/* ── لوحة التفاصيل ── */
.sheet { --sh: 173; --ss: 65%; position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 20px; }
.sheet[hidden] { display: none; }
.sheet-scrim { position: absolute; inset: 0; background: rgba(4, 8, 7, 0.78); }
.sheet-box {
  position: relative;
  inline-size: min(620px, 100%);
  max-block-size: min(90vh, 860px);
  max-block-size: min(90svh, 860px);
  overflow-y: auto;
  border-radius: 24px;
  background: linear-gradient(158deg, hsl(var(--sh) 30% 12%), hsl(var(--sh) 26% 6%));
  border: 1px solid hsl(var(--sh) var(--ss) 62% / 0.42);
  box-shadow: 0 34px 80px rgba(0, 0, 0, 0.6);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.25s, transform 0.25s;
}
.sheet.on .sheet-box { opacity: 1; transform: none; }
.sheet-x {
  position: absolute;
  inset-block-start: 12px;
  inset-inline-start: 12px;
  z-index: 2;
  inline-size: 36px;
  block-size: 36px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  background: rgba(4, 16, 13, 0.75);
  color: #f2fffb;
  font-size: 21px;
  line-height: 1;
  cursor: pointer;
}
.sheet-media { aspect-ratio: 16 / 8; overflow: hidden; background: #0a1613; }
.sheet-media { position: relative; }
.sheet-media img { inline-size: 100%; block-size: 100%; object-fit: cover; }
.sheet-media video { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; object-fit: cover; opacity: 0; transition: opacity 0.25s; }
.sheet-media video.on { opacity: 1; }
.sheet-body { padding: 20px 24px 18px; display: flex; flex-direction: column; }
.sheet-kicker { display: flex; align-items: center; gap: 10px; margin-block-end: 8px; font-size: 0.82rem; }
.sheet-kicker em { font-style: normal; color: var(--muted); }
.sheet-status { padding: 2px 10px; border: 1px solid hsl(var(--sh) var(--ss) 62% / 0.4); border-radius: 99px; color: hsl(var(--sh) var(--ss) 68%); font-weight: 500; }
.sheet-box h3 { font-size: 1.28rem; font-weight: 700; line-height: 1.4; margin-block-end: 8px; }
.sheet-lead { color: #bccbc6; font-size: 0.95rem; margin-block-end: 12px; }
.sheet-list { display: grid; gap: 8px; list-style: none; font-size: 0.9rem; color: #bccbc6; line-height: 1.6; }
.sheet-list li { display: flex; gap: 9px; }
.sheet-list li::before { content: ""; flex: none; inline-size: 6px; block-size: 6px; margin-block-start: 0.55em; border-radius: 50%; background: hsl(var(--sh) var(--ss) 62%); }
.sheet-more {
  margin-block-start: 16px;
  border: 1px solid hsl(var(--sh) var(--ss) 62% / 0.6);
  background: linear-gradient(180deg, hsl(var(--sh) var(--ss) 28%), hsl(var(--sh) var(--ss) 23%));
  box-shadow: 0 8px 24px hsl(var(--sh) var(--ss) 30% / 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12);
  color: #fff;
}
@media (hover: hover) { .sheet-more:hover { border-color: hsl(var(--sh) var(--ss) 72%); } }
.sheet-nav { display: flex; align-items: center; justify-content: center; gap: 12px; margin-block-start: 12px; color: var(--muted); font-size: 0.82rem; }
.sheet-nav button { inline-size: 32px; block-size: 32px; border: 1px solid var(--rule); border-radius: 50%; background: transparent; color: var(--fg); font-size: 1.1rem; line-height: 1; cursor: pointer; }

/* ── التذييل ── */
.ms-footer { position: relative; z-index: 1; border-block-start: 1px solid var(--line); background: rgba(8, 11, 10, 0.92); padding-block: 40px 22px; font-size: 0.88rem; }
.ms-wrap { max-inline-size: 1080px; margin-inline: auto; padding-inline: 24px; }
.ms-footer-grid { display: grid; gap: 26px; grid-template-columns: minmax(0, 1.4fr) repeat(4, minmax(0, 1fr)); }
.ms-footer h2 { font-size: 0.85rem; font-weight: 600; text-align: start; margin-block-end: 8px; }
.ms-footer ul { list-style: none; display: grid; gap: 5px; }
.ms-footer a { color: var(--muted); text-decoration: none; }
.ms-footer a:hover { color: var(--teal); }
.ms-brand { display: inline-flex; align-items: center; gap: 10px; color: var(--fg) !important; }
.ms-brand img { block-size: 34px; inline-size: auto; }
.ms-brand-name { display: flex; flex-direction: column; line-height: 1.15; }
.ms-brand-name b { font-weight: 700; }
.ms-brand-name i { font: normal 500 0.62rem/1.2 var(--mono); color: var(--faint); letter-spacing: 0.1em; }
.ms-footer-tag { margin-block-start: 8px; color: var(--muted); }
.ms-mono { font-family: var(--mono); }
.ms-footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; margin-block-start: 26px; padding-block-start: 16px; border-block-start: 1px solid var(--line); color: var(--faint); font-size: 0.8rem; }
.ms-footer-bottom { align-items: center; }
@media (max-width: 900px) {
  .ms-footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-areas: "about about" "product features" "help features" "legal features";
    gap: 20px 18px;
  }
  .ms-footer-about { grid-area: about; }
  .ms-footer nav[aria-labelledby="f-product"] { grid-area: product; }
  .ms-footer nav[aria-labelledby="f-features"] { grid-area: features; }
  .ms-footer nav[aria-labelledby="f-help"] { grid-area: help; }
  .ms-footer nav[aria-labelledby="f-legal"] { grid-area: legal; }
  .ms-footer { padding-block: 28px 20px; font-size: 0.82rem; }
  .ms-footer ul { gap: 4px; }
  .ms-footer a { overflow-wrap: anywhere; }
  .ms-footer-bottom { justify-content: center; gap: 12px; margin-block-start: 20px; padding-block-start: 14px; font-size: 0.78rem; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
