/* Waajeh — الموقع التعريفي. نفس هوية التطبيق: أسود، أبيض، برتقالي الشعار، أزرق وأحمر للطرفين. */
:root {
  --bg: #000;
  --s1: #0f0f0f;
  --s2: #171717;
  --s3: #222;
  --line: #1f1f1f;
  --line2: #2c2c2c;
  --t1: #fff;
  --t2: #a1a1a1;
  --t3: #808080; /* تباين 4.5:1 على الأقل فوق --bg و--s1 و--s2 */
  --brand: #E5484D;
  --a: #4C8DFF;
  --b: #F97314;
  --win: #34C759;
  --r: 20px;
  --font: 'IBM Plex Sans Arabic', -apple-system, 'SF Arabic', 'Segoe UI', Tahoma, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--t1); font: 400 16px/1.7 var(--font); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; }
h1, h2, h3 { margin: 0; line-height: 1.3; }
p { margin: 0; }
.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 20px; }
.muted { color: var(--t2); }
.small { font-size: 14px; }
.link { color: var(--t1); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--t3); }
.skip { position: absolute; inset-inline-start: -999px; top: 8px; background: #fff; color: #000; padding: 8px 14px; border-radius: 10px; z-index: 50; }
.skip:focus { inset-inline-start: 8px; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; border-radius: 8px; }

/* أزرار */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 22px; border: 0; border-radius: 999px; background: #fff; color: #000; font: 600 15px var(--font); cursor: pointer; transition: transform .15s, opacity .15s; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: scale(.98); }
.btn[disabled] { opacity: .5; cursor: default; transform: none; }
.btn.sm { height: 38px; padding: 0 16px; font-size: 14px; }

/* الشريط العلوي */
.nav { position: sticky; top: 0; z-index: 20; background: rgba(0,0,0,.72); backdrop-filter: saturate(160%) blur(16px); -webkit-backdrop-filter: saturate(160%) blur(16px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.nav.scrolled { border-bottom-color: var(--line); }
.nav-in { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; letter-spacing: .3px; }
.logo { width: 28px; height: 28px; }
.links { display: flex; gap: 22px; margin-inline-start: auto; font-size: 15px; color: var(--t2); }
.links a:hover { color: var(--t1); }

/* الواجهة الأولى */
.hero { position: relative; padding: 56px 0 72px; overflow: hidden; }
.hero::before { content: ''; position: absolute; inset: -20% -10% auto; height: 620px; background: radial-gradient(40% 50% at 30% 40%, rgba(76,141,255,.16), transparent 70%), radial-gradient(40% 50% at 70% 40%, rgba(249,115,20,.14), transparent 70%); pointer-events: none; }
.hero-in { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; align-items: center; gap: 48px; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 14px; border: 1px solid var(--line2); border-radius: 999px; color: var(--t2); font-size: 14px; margin-bottom: 22px; }
.eyebrow .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px rgba(229,72,77,.18); }
h1 { font-size: clamp(44px, 7.4vw, 84px); font-weight: 700; line-height: 1.12; letter-spacing: -.5px; }
h1 .muted { color: var(--t3); }
.lead { margin-top: 20px; max-width: 520px; color: var(--t2); font-size: 18px; line-height: 1.8; }
.fine { margin-top: 14px; color: var(--t3); font-size: 13px; }

/* أزرار المتاجر */
.stores { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 30px; }
.stores.center { justify-content: center; }
.store { display: inline-flex; align-items: center; gap: 12px; height: 58px; padding: 0 20px 0 22px; border-radius: 16px; background: #fff; color: #000; transition: transform .15s; }
.store:hover { transform: translateY(-2px); }
.store svg { width: 26px; height: 26px; flex: none; }
.store span { display: flex; flex-direction: column; line-height: 1.2; text-align: start; }
.store small { font-size: 11px; opacity: .65; }
.store b { font-size: 17px; font-weight: 600; white-space: nowrap; }
.store.soon { background: var(--s2); color: var(--t1); border: 1px solid var(--line2); font: inherit; cursor: pointer; }

/* الجوال التفاعلي */
/* إطار iPhone 18 Pro Max: حواف رفيعة، إطار معدني، وDynamic Island أصغر */
.device { justify-self: center; position: relative; width: min(330px, 84vw); }
.phone { position: relative; padding: 3px; border-radius: 17.5% / 8.2%; background: linear-gradient(145deg, #5a5a5e 0%, #2b2b2e 18%, #1a1a1c 50%, #2e2e31 82%, #57575b 100%); box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 40px 120px -24px rgba(0,0,0,.95), 0 0 90px -30px rgba(229,72,77,.35); }
.phone::before, .phone::after, .device .btn-l, .device .btn-r { content: ''; position: absolute; width: 3px; border-radius: 2px; background: linear-gradient(90deg, #2a2a2d, #626266); }
.phone::before { left: -2px; top: 17%; height: 4.6%; }            /* زر الإجراء */
.phone::after { left: -2px; top: 24.5%; height: 8.6%; } /* رفع الصوت */
.device .btn-l { left: 1px; top: 35.5%; height: 8.6%; }            /* خفض الصوت */
.device .btn-r { right: 1px; top: 27%; height: 12.5%; background: linear-gradient(270deg, #2a2a2d, #626266); } /* الزر الجانبي */
.device .btn-c { position: absolute; right: 1px; top: 62%; width: 3px; height: 6.5%; border-radius: 2px; background: linear-gradient(270deg, #1d1d1f, #48484c); } /* التحكم بالكاميرا */
.bezel { padding: 2.3%; border-radius: 16.5% / 7.7%; background: #000; }
.screen { position: relative; aspect-ratio: 1320 / 2868; border-radius: 14% / 6.45%; background: #000; overflow: hidden; display: flex; flex-direction: column; padding: 52px 12px 18px; }
.screen::before { content: ''; position: absolute; top: 1.25%; left: 50%; width: 20%; height: 3.6%; transform: translateX(-50%); border-radius: 99px; background: #000; box-shadow: inset 0 0 0 1px #0d0d0d; z-index: 2; }
.ph-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 13px; }
.tag { font-weight: 600; }
.chip-lock { display: inline-flex; align-items: center; gap: 5px; height: 26px; padding: 0 10px; border-radius: 999px; background: var(--s2); color: var(--t2); font-size: 12px; }
.chip-lock svg { width: 13px; height: 13px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.vs { position: relative; flex: 1; direction: ltr; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; min-height: 0; }
.side { position: relative; display: flex; flex-direction: column; padding: 0; border: 0; border-radius: 18px; overflow: hidden; background: var(--s1); color: #fff; font: inherit; cursor: default; transition: transform .2s, box-shadow .2s, opacity .3s; }
.side:not([disabled]) { cursor: pointer; }
.side:not([disabled]):hover { transform: translateY(-2px); }
.side.a { --c: var(--a); }
.side.b { --c: var(--b); }
.clip { position: relative; flex: 1; overflow: hidden; background: radial-gradient(120% 80% at 50% 10%, color-mix(in srgb, var(--c) 45%, #000), #050505 75%); }
.blob { position: absolute; width: 140%; aspect-ratio: 1; left: -20%; top: 10%; border-radius: 50%; background: radial-gradient(circle, color-mix(in srgb, var(--c) 55%, transparent), transparent 60%); filter: blur(10px); animation: drift 7s ease-in-out infinite alternate; }
.side.b .blob { animation-delay: -3.5s; }
@keyframes drift { from { transform: translate(-12%, 6%) scale(.9); } to { transform: translate(12%, -6%) scale(1.1); } }
/* شخص مموّه: الهوية مخفية */
.who { position: absolute; left: 50%; bottom: -6%; width: 78%; aspect-ratio: 1 / 1.3; transform: translateX(-50%); filter: blur(7px); opacity: .85; background: radial-gradient(circle at 50% 22%, rgba(255,255,255,.55) 0 17%, transparent 18%), radial-gradient(ellipse 50% 42% at 50% 92%, rgba(255,255,255,.4) 0 98%, transparent 100%); }
.prog { position: absolute; top: 8px; left: 8px; right: 8px; height: 3px; border-radius: 3px; overflow: hidden; background: rgba(255,255,255,.18); z-index: 1; }
.prog i { display: block; height: 100%; width: 0; background: var(--c); }
.pct { position: absolute; inset: auto 0 18px; text-align: center; font-size: 30px; font-weight: 700; opacity: 0; transform: translateY(8px); transition: opacity .35s, transform .35s; text-shadow: 0 2px 16px rgba(0,0,0,.6); }
.vs-badge { position: absolute; top: 42%; left: 50%; transform: translate(-50%, -50%); width: 42px; height: 42px; border-radius: 50%; background: #000; border: 2px solid #fff; display: grid; place-items: center; font: 800 13px var(--font); letter-spacing: .5px; z-index: 2; direction: ltr; }
.bar { display: flex; height: 8px; margin-top: 12px; border-radius: 99px; overflow: hidden; background: var(--s2); direction: ltr; }
.bar i { width: 50%; transition: width .9s cubic-bezier(.2,.8,.2,1); }
.bar .ba { background: var(--a); }
.bar .bb { background: var(--b); }
.ph-hint { margin-top: 12px; min-height: 22px; text-align: center; font-size: 13px; color: var(--t2); }
.screen.can .side:not([disabled]) { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--c) 70%, transparent); }
.screen.done .pct { opacity: 1; transform: none; }
.screen.done .side.picked { box-shadow: inset 0 0 0 3px var(--c); }
.screen.done .side:not(.picked) { opacity: .55; }
.screen.done .who { filter: blur(2px); }

/* أقسام */
.sec { padding: 88px 0; border-top: 1px solid var(--line); }
.h2 { font-size: clamp(28px, 4vw, 42px); font-weight: 700; margin-bottom: 36px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.steps li { position: relative; padding: 28px; border-radius: var(--r); background: var(--s1); border: 1px solid var(--line); }
.num { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: #fff; color: #000; font-weight: 700; font-size: 18px; margin-bottom: 18px; }
.steps li:nth-child(3) .num { background: var(--brand); color: #fff; }
.steps h3, .card h3 { font-size: 20px; margin-bottom: 8px; }
.steps p, .card p { color: var(--t2); font-size: 15px; }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.card { padding: 26px; border-radius: var(--r); background: var(--s1); border: 1px solid var(--line); }
.ic { width: 28px; height: 28px; margin-bottom: 18px; fill: none; stroke: var(--t1); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* الرتب */
.tiers { display: grid; grid-template-columns: repeat(5, 1fr); gap: 12px; margin-top: 16px; padding: 26px; border-radius: var(--r); background: var(--s1); border: 1px solid var(--line); }
.tier { display: flex; flex-direction: column; align-items: center; gap: 10px; font-size: 15px; }
.tier b { font-weight: 600; }
.sq { position: relative; width: 56px; height: 56px; border-radius: 18px; background: var(--c); display: grid; place-items: center; overflow: hidden; }
.sq svg { width: 62%; height: 62%; fill: #000; }
.sq.shine::after { content: ''; position: absolute; inset: -40%; background: linear-gradient(115deg, transparent 40%, rgba(255,255,255,.25) 47%, transparent 52%, rgba(255,255,255,.15) 58%, transparent 63%); transform: translateX(-70%); animation: shine 3.2s ease-in-out infinite; }
@keyframes shine { 0% { transform: translateX(-70%); } 40%, 100% { transform: translateX(70%); } }

.sq.t1 { --c: #9AA3AE; } .sq.t2 { --c: #2EC4B6; } .sq.t3 { --c: #9B7BFF; } .sq.t4 { --c: #F2C14E; } .sq.t5 { --c: #E5484D; }
.nav .push { margin-inline-start: auto; }
.nf { min-height: 100vh; justify-content: center; gap: 14px; }
.nf h1 { font-size: 40px; }
.nf .lead { margin-top: 0; }

/* مواجهة حية من التطبيق */
.ph-tags { display: inline-flex; align-items: center; gap: 8px; min-width: 0; }
.ph-tags .tag { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 130px; }
.live { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: 6px; background: var(--b); color: #fff; font-size: 11px; font-weight: 700; }
.live i { width: 6px; height: 6px; border-radius: 50%; background: #fff; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.clip video, .clip img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.screen.real .blob, .screen.real .who { display: none; }
.screen.real .clip::after { content: ''; position: absolute; inset: auto 0 0; height: 45%; background: linear-gradient(transparent, rgba(0,0,0,.65)); }
.screen.real .pct { z-index: 1; }
.ph-sub { margin-top: 2px; text-align: center; font-size: 12px; color: var(--t3); }

/* مقطع التطبيق */
.screen.vid { padding: 0; background: #000; }
.screen.vid::before { z-index: 2; }
.app-vid { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top center; pointer-events: none; background: #000; }
.snd { position: relative; flex: none; width: 38px; height: 38px; margin-inline-end: -12px; border: 1px solid var(--line2); border-radius: 50%; background: var(--s2); color: #fff; display: grid; place-items: center; cursor: pointer; transition: background .15s, transform .15s, border-color .15s; }
.snd:hover { background: var(--s3); transform: scale(1.05); }
.snd svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.snd[aria-pressed="false"]::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 1.5px solid var(--brand); opacity: 0; animation: ping 2.4s ease-out 1s 3; }
@keyframes ping { 0% { opacity: .9; transform: scale(.85); } 100% { opacity: 0; transform: scale(1.35); } }
.snd .on, .snd[aria-pressed="true"] .off { display: none; }
.snd[aria-pressed="true"] .on { display: block; }

/* التحميل */
.cta-in { text-align: center; display: flex; flex-direction: column; align-items: center; }
.cta .h2 { margin-bottom: 0; }
.cta .lead { margin-inline: auto; margin-top: 12px; }
.logo.big { width: 72px; height: 72px; margin-bottom: 22px; }
.form.beta { position: static; width: 100%; max-width: 440px; margin-top: 28px; text-align: start; }
.form.beta .btn { width: 100%; }
.form.beta .form-msg:empty { display: none; }
.form.beta [data-beta-hint] { margin-top: -4px; text-align: center; }

/* الدعم */
.support { display: grid; grid-template-columns: 1.1fr .9fr; gap: 32px; align-items: start; }
.faq { display: flex; flex-direction: column; gap: 10px; }
.faq details { border-radius: 16px; background: var(--s1); border: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 18px 20px; font-weight: 600; display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 22px; font-weight: 400; color: var(--t2); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 20px 18px; color: var(--t2); font-size: 15px; }

.form { display: flex; flex-direction: column; gap: 14px; position: sticky; top: 84px; }
.form h3 { font-size: 22px; margin: 0; }
.form label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--t2); }
.form input, .form select, .form textarea { width: 100%; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--line2); background: #000; color: var(--t1); font: 400 15px var(--font); transition: border-color .15s; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--brand); outline-offset: 2px; border-color: var(--t3); border-radius: 12px; }
.form textarea { resize: none; min-height: 130px; }
.form select { -webkit-appearance: none; appearance: none; cursor: pointer; padding-inline-end: 42px; background: #000 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23a1a1a1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat left 14px center / 18px; }
.form .invalid { border-color: var(--brand); }
.form .hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.form-msg { min-height: 22px; font-size: 14px; }
.form-msg.ok { color: var(--win); }
.form-msg.err { color: var(--brand); }

/* التذييل */
.foot { border-top: 1px solid var(--line); padding: 40px 0 calc(40px + env(safe-area-inset-bottom)); }
.foot-in { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 28px; }
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; color: var(--t2); font-size: 14px; }
.foot nav a:hover { color: var(--t1); }
.foot .small { margin-inline-start: auto; color: var(--t3); }

/* صفحة الشروط */
.doc { max-width: 760px; padding-top: 48px; padding-bottom: 88px; }
.doc h1 { font-size: clamp(30px, 5vw, 44px); margin-bottom: 8px; }
.doc .updated { color: var(--t3); font-size: 14px; margin-bottom: 36px; }
.doc h2 { font-size: 24px; margin: 44px 0 14px; }
.doc h3 { font-size: 18px; margin: 28px 0 8px; }
.doc h4 { font-size: 16px; font-weight: 600; margin: 22px 0 6px; color: var(--t1); }
.doc p { color: #cfcfcf; margin: 0 0 12px; }
.doc ul { margin: 0 0 14px; padding-inline-start: 22px; color: #cfcfcf; }
.doc li { margin-bottom: 4px; }
.doc .toc { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.doc .toc a { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--line2); font-size: 14px; color: var(--t2); }
.doc .toc a:hover { color: var(--t1); }

/* الجوال */
@media (max-width: 900px) {
  .hero { padding-top: 32px; }
  .hero-in, .support { grid-template-columns: 1fr; }
  .hero-copy { text-align: center; }
  .hero-copy .lead { margin-inline: auto; }
  .stores { justify-content: center; }
  .grid { grid-template-columns: 1fr 1fr; }
  .form { position: static; }
}
@media (max-width: 640px) {
  .links { display: none; }
  .nav .btn { margin-inline-start: auto; }
  .steps, .grid { grid-template-columns: 1fr; }
  .tiers { grid-template-columns: repeat(5, 1fr); gap: 6px; padding: 20px 10px; }
  .sq { width: 46px; height: 46px; border-radius: 15px; }
  .tier { font-size: 13px; }
  .sec { padding: 64px 0; }
  .lead { font-size: 16px; }
  .store { flex: 1 1 150px; justify-content: center; gap: 10px; padding: 0 14px; }
  .store b { font-size: 16px; }
  .foot .small { margin-inline-start: 0; width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* رسالة صغيرة */
.toast { position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); padding: 12px 20px; border-radius: 999px; background: #fff; color: #000; font-weight: 600; font-size: 15px; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 60; white-space: nowrap; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* الموقع مغلق مؤقتًا */
.is-closed body > :not(.closed-page):not(.toast) { display: none !important; }
.closed-page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; padding: 40px 24px; text-align: center; background: radial-gradient(50% 40% at 50% 35%, rgba(229,72,77,.12), transparent 70%), #000; }
.closed-page .logo.big { margin-bottom: 0; }
.closed-name { font-size: 22px; font-weight: 700; letter-spacing: .3px; margin-bottom: 18px; }
.closed-page h1 { font-size: clamp(30px, 6vw, 46px); }
.closed-page .lead { margin: 0 auto; max-width: 460px; }
.closed-page .link { margin-top: 10px; color: var(--t2); }

/* ===== شاشة المواجهة داخل الجوال (نسخة من واجهة التطبيق، بوحدات iPhone: 440 نقطة عرض) ===== */
.screen.app { padding: 0; background: #000; container-type: inline-size; contain: layout paint style; }
/* نسبة القسمة بين المقطعين: قيمة وحدة تتحرك في الأب، وكل شيء يُحسب منها في كل إطار
   (المقطعان والفاصل والصور وشريط التصويت والدائرة)، فيتحركون مع بعض بالضبط بلا أي فرق. */
@property --d { syntax: '<number>'; inherits: true; initial-value: .382; }
.ap { --d: .382; transition: --d .55s cubic-bezier(.65,0,.35,1); }
.show-b .ap { --d: .618; }
.ap { --p: calc(100cqw / 440); position: absolute; inset: 0; color: #fff; font-family: -apple-system, 'SF Arabic', 'IBM Plex Sans Arabic', sans-serif; font-size: calc(var(--p) * 14); line-height: 1.2; direction: rtl; user-select: none; }
.ap svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ap > *, .ap-card > * { position: absolute; }
/* الشريط العلوي */
.ap-logo { right: calc(var(--p) * 21); top: calc(var(--p) * 79); width: auto !important; height: calc(var(--p) * 22) !important; aspect-ratio: 406 / 422; overflow: visible; }
/* نفس شعار التطبيق: الأحمر يسار والأبيض يمين، ولكل واحد حافة خفيفة */
.ap svg.ap-logo path { stroke-width: 9.5; }
.ap svg.ap-logo .l { fill: #E5484D; stroke: #EC7074; }
.ap svg.ap-logo .r { fill: #fff; stroke: #DDDDDD; }
.ap-seg { right: calc(var(--p) * 117); top: calc(var(--p) * 69); width: calc(var(--p) * 207); height: calc(var(--p) * 42); border-radius: calc(var(--p) * 14); background: #1c1c1e; display: flex; align-items: center; padding: calc(var(--p) * 4); gap: calc(var(--p) * 4); }
.ap-seg b, .ap-seg span { flex: 1; height: 100%; display: grid; place-items: center; border-radius: calc(var(--p) * 11); font-size: calc(var(--p) * 13); }
.ap-seg b { background: #2e2e30; font-weight: 700; }
.ap-seg span { color: #8a8a8a; font-weight: 600; }
.ap-ic { top: calc(var(--p) * 79); width: calc(var(--p) * 22); height: calc(var(--p) * 22); }
.ap-search { left: calc(var(--p) * 67); } .ap-info { left: calc(var(--p) * 22); }
.ap-prog { top: calc(var(--p) * 133); left: calc(var(--p) * 30); right: calc(var(--p) * 30); height: calc(var(--p) * 3); display: flex; gap: calc(var(--p) * 4); direction: ltr; z-index: 2; }
.ap-prog span { flex: 1; border-radius: 3px; background: rgba(255,255,255,.28); overflow: hidden; }
.ap-prog span i { display: block; height: 100%; width: 100%; background: #fff; transform: scaleX(0); transform-origin: right center; will-change: transform; }
.ap-prog span { direction: rtl; } /* الخطين يتعبّون من اليمين لليسار، مثل التطبيق */
/* بطاقة المواجهة */
.ap-card { contain: layout paint; left: calc(var(--p) * 16); right: calc(var(--p) * 16); top: calc(var(--p) * 122); height: calc(var(--p) * 630); border-radius: calc(var(--p) * 22); overflow: hidden; background: #0a0a0a; }
.clip { top: 0; bottom: 0; overflow: hidden; isolation: isolate; }
/* كل مقطع يوصل لنص الفاصل بالضبط (ب ينتهي عند طرفه الأيمن، وأ يبدأ من طرفه الأيسر)، والفاصل يغطي الحد بينهما. */
.clip.b { left: 0; width: calc(var(--d) * 100% + .5px); }
.clip.a { right: 0; width: calc((1 - var(--d)) * 100% + .5px); }
/* الفاصل رفيع 1px: طبقة مستقلة تتحرك بـ transform، فعرضه ثابت تمامًا في كل إطار (ما يتغير بسبب كسور البكسل). */
.ap-card::before { content: ''; position: absolute; top: 0; bottom: 0; left: -.5px; width: 1px; background: #000; z-index: 1; pointer-events: none; transform: translateX(calc((100cqw - var(--p) * 32) * var(--d))); will-change: transform; }
/* الصورة بمقاس ثابت (عرض المقطع المفتوح) ومتوسّطة في مكانها: أثناء الانتقال يتغير القص فقط، ولا تكبر ولا تتزحلق. */
.ap-card .clip img { position: absolute; inset: 0 auto 0 calc(50% - ((100cqw - var(--p) * 32) * .618 + 2px) / 2); width: calc((100cqw - var(--p) * 32) * .618 + 2px); height: 100%; max-width: none; object-fit: cover; z-index: 0; }
/* التظليل على الصورة نفسها (filter) بدل طبقة سوداء فوقها: الطبقة كان يطلع على حافتها خط فاتح في سفاري
   (حافة الصورة تبين تحتها)، والحين ما فيه طبقتين أصلًا فما يطلع أي خط. */
.clip .shade { display: none; }
.ap-card .clip img { filter: brightness(1); transition: filter .55s cubic-bezier(.65,0,.35,1); }
.ap-card .clip.b img { filter: brightness(.45); }
/* الصورة اليسار (الجدار الملوّن) أفتح، فإضاءتها وهي مفتوحة 65٪. */
.show-b .ap-card .clip.b img { filter: brightness(.65); }
.show-b .ap-card .clip.a img { filter: brightness(.17); }
/* الصورة اليمين أفتح من اليسار، فتظليلها وهي مصغّرة أقوى (83٪ بدل 55٪). */
.clip .play { position: absolute; z-index: 2; top: 50%; left: 50%; width: calc(var(--p) * 44); height: calc(var(--p) * 44); margin: calc(var(--p) * -22) 0 0 calc(var(--p) * -22); border-radius: 50%; background: rgba(0,0,0,.45); border: 1.5px solid rgba(255,255,255,.35); padding: calc(var(--p) * 12); color: #fff; transition: opacity .55s cubic-bezier(.65,0,.35,1); }
.clip.a .play, .show-b .clip.b .play { opacity: 0; }
.show-b .clip.a .play { opacity: 1; }
.ap-card::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(rgba(0,0,0,.45), transparent 18%, transparent 80%, rgba(0,0,0,.55)); }
.ap-chips { right: calc(var(--p) * 12); top: calc(var(--p) * 27); display: flex; gap: calc(var(--p) * 6); z-index: 2; }
.ap-chips .chip { height: calc(var(--p) * 27); padding: 0 calc(var(--p) * 10); border-radius: calc(var(--p) * 14); background: rgba(0,0,0,.42); display: inline-flex; align-items: center; gap: calc(var(--p) * 4); font-size: calc(var(--p) * 12); font-weight: 600; background: rgba(0,0,0,.55); }
.ap-chips .hard { background: rgba(255,122,69,.25); color: #FFB3B5; }
.ap-chips .hard svg { width: calc(var(--p) * 13); height: calc(var(--p) * 13); color: #FF7A45; stroke-width: 2.2; }
.ap-time { left: calc(var(--p) * 14); top: calc(var(--p) * 32); display: flex; align-items: center; gap: calc(var(--p) * 4); font-size: calc(var(--p) * 12); z-index: 2; }
.ap-time svg { width: calc(var(--p) * 13); height: calc(var(--p) * 13); }
.ap-time b { font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: .3px; }
.ap-acts { left: calc(var(--p) * 10); bottom: calc(var(--p) * 8); display: flex; gap: calc(var(--p) * 8); direction: ltr; z-index: 2; }
.ap-acts .ci { width: calc(var(--p) * 36); height: calc(var(--p) * 36); border-radius: 50%; background: rgba(0,0,0,.45); border: 1px solid rgba(255,255,255,.12); padding: calc(var(--p) * 9); display: block; }
.ap-acts .mic { color: #34C759; }
.ap-sup { right: calc(var(--p) * 12); bottom: calc(var(--p) * 8); height: calc(var(--p) * 36); padding: 0 calc(var(--p) * 12); border-radius: calc(var(--p) * 18); background: rgba(0,0,0,.5); border: 1px solid rgba(242,193,78,.4); display: flex; align-items: center; gap: calc(var(--p) * 6); font-size: calc(var(--p) * 13); z-index: 2; }
.ap-sup b { color: #E9D29A; font-weight: 600; }
.ap-sup span { font-weight: 700; }
/* نفس عملة التطبيق (CoinIcon): دائرة ذهبية مسطحة وفيها حلقة داخلية أغمق. */
.coin { width: calc(var(--p) * 16); height: calc(var(--p) * 16); flex: none; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Ccircle cx='12' cy='12' r='10' fill='%23F2C14E'/%3E%3Ccircle cx='12' cy='12' r='6.5' fill='none' stroke='%239A7417' stroke-width='1.6'/%3E%3C/svg%3E") center / contain no-repeat; }
/* شريط التصويت */
.ap-vote { left: calc(var(--p) * 16); right: calc(var(--p) * 16); top: calc(var(--p) * 772); height: calc(var(--p) * 44); border-radius: calc(var(--p) * 22); overflow: visible; direction: ltr; }
/* الإطار فوق النصفين (مو حولهما)، فعرض الشريط نفس عرض المواجهة بالضبط والدائرة تحت الفاصل تمامًا. */
.ap-vote::after { content: ''; position: absolute; inset: 0; border: 1px solid #2F3336; border-radius: inherit; pointer-events: none; z-index: 1; }
.ap-vote .half { position: absolute; top: 0; bottom: 0; display: flex; align-items: center; gap: calc(var(--p) * 8); padding: 0 calc(var(--p) * 18); font-size: calc(var(--p) * 14.5); transition: background-color .55s cubic-bezier(.65,0,.35,1); direction: rtl; white-space: nowrap; overflow: hidden; }
.ap-vote .half.b { left: 0; width: calc(var(--d) * 100%); border-radius: calc(var(--p) * 22) 0 0 calc(var(--p) * 22); justify-content: flex-end; }
.ap-vote .half.a { right: 0; width: calc((1 - var(--d)) * 100%); border-radius: 0 calc(var(--p) * 22) calc(var(--p) * 22) 0; justify-content: flex-start; background: #16181C; }
.show-b .ap-vote .half.a { background: transparent; }
.show-b .ap-vote .half.b { background: #1C1816; }
.ap-vote .dot { width: calc(var(--p) * 8); height: calc(var(--p) * 8); border-radius: 50%; flex: none; }
.ap-vote .half.a .dot { background: #4C8DFF; } .ap-vote .half.b .dot { background: #F97314; order: 2; }
.ap-vote .half.b .lb-open, .ap-vote .half.b .lb-closed { order: 1; }
/* قبل التصويت: الجهة المصغّرة نقطة لونها فقط على طرفها، بلا «المنافس» (مثل التطبيق).
   الكلمة القديمة تختفي أول الحركة، والجديدة تظهر بعد نصها (ما يظهرون مع بعض)، والنقطة ثابتة مكانها على الطرف. */
.lb-closed { display: none; }
.lb-open { font-weight: 700; transition: opacity .22s ease-out .3s; }
.half.b .lb-open, .show-b .half.a .lb-open { opacity: 0; transition: opacity .15s ease-in; }
.show-b .half.b .lb-open { opacity: 1; transition: opacity .22s ease-out .3s; }
.ap-vote .ring { position: absolute; top: 50%; left: calc(var(--d) * 100%); width: calc(var(--p) * 52); height: calc(var(--p) * 52); margin: calc(var(--p) * -26) 0 0 calc(var(--p) * -26); border-radius: 50%; background: #000; box-shadow: inset 0 0 0 calc(var(--p) * 3) #2F3336; display: grid; place-items: center; font-weight: 900; font-size: calc(var(--p) * 14); z-index: 2; }
/* التبويبات */
.ap-nav { left: 0; right: 0; top: calc(var(--p) * 862); height: calc(var(--p) * 70); border-top: 1px solid #1f1f1f; display: flex; align-items: center; justify-content: space-around; padding: 0 calc(var(--p) * 18); }
.ap-nav > span { position: relative; width: calc(var(--p) * 26); height: calc(var(--p) * 26); color: #9a9a9a; }
.ap-nav .on { color: #fff; }
.ap-nav .mid { width: calc(var(--p) * 50); height: calc(var(--p) * 40); border-radius: calc(var(--p) * 12); background: #1c1c1e; border: 1px solid #333; display: flex; align-items: center; justify-content: center; gap: calc(var(--p) * 2); direction: ltr; }
.ap-nav .mid i { display: block; width: calc(var(--p) * 8); height: calc(var(--p) * 16); background: #f2f2f2; border-radius: calc(var(--p) * 3) 0 0 calc(var(--p) * 3); }
.ap-nav .mid i + i { width: calc(var(--p) * 6); height: calc(var(--p) * 12); background: rgba(242,242,242,.4); border-radius: 0 calc(var(--p) * 3) calc(var(--p) * 3) 0; }
.ap-nav .badge::after { content: ''; position: absolute; top: calc(var(--p) * -2); right: calc(var(--p) * -2); width: calc(var(--p) * 7); height: calc(var(--p) * 7); border-radius: 50%; background: #E5484D; }
@media (prefers-reduced-motion: reduce) { .ap, .ap-card .clip img, .clip .play, .ap-vote .half, .lb-open { transition: none !important; } }

/* خطوات تحميل النسخة التجريبية */
.tf-back { position: fixed; inset: 0; z-index: 100; background: rgba(0,0,0,.6); display: flex; align-items: flex-end; justify-content: center; opacity: 0; pointer-events: none; transition: opacity .25s; }
.tf-back.on { opacity: 1; pointer-events: auto; }
.tf-sheet { position: relative; width: 100%; max-width: 440px; background: var(--s1); border: 1px solid var(--line2); border-radius: 24px 24px 0 0; padding: 26px 22px calc(26px + env(safe-area-inset-bottom)); transform: translateY(24px); transition: transform .3s cubic-bezier(.2,.8,.2,1); }
.tf-back.on .tf-sheet { transform: none; }
@media (min-width: 600px) { .tf-back { align-items: center; } .tf-sheet { border-radius: 24px; } }
.tf-x { position: absolute; top: 14px; left: 14px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--s3); color: var(--t2); font-size: 22px; line-height: 1; cursor: pointer; }
.tf-sheet h3 { font-size: 20px; font-weight: 600; }
.tf-sub { font-size: 14px; margin-top: 6px; }
.tf-pc { margin-top: 14px; padding: 10px 14px; border-radius: 12px; background: var(--s2); color: var(--t2); font-size: 13px; }
.tf-pc[hidden] { display: none; }
.tf-steps { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 18px; }
.tf-steps li { display: flex; gap: 12px; }
.tf-n { flex: 0 0 28px; height: 28px; border-radius: 50%; background: var(--s3); color: var(--t1); font-size: 14px; font-weight: 600; display: flex; align-items: center; justify-content: center; }
.tf-steps li > div { flex: 1; min-width: 0; }
.tf-steps b { display: block; font-size: 15px; font-weight: 600; }
.tf-steps small { display: block; color: var(--t2); font-size: 13px; margin: 2px 0 10px; }
.tf-btn { display: flex; align-items: center; justify-content: center; gap: 8px; height: 46px; border-radius: 23px; background: var(--brand); color: #fff; font-size: 15px; font-weight: 600; }
.tf-btn.ghost { background: var(--s3); color: var(--t1); }
.tf-btn svg { width: 18px; height: 18px; }

