/* 9yed · site styles. Brand book 2026: Sky ground, Navy ink, Royal sections, Lime highlight. */

:root {
  --sky: #83B3FF;
  --lime: #97CB07;
  --navy: #021D3C;
  --royal: #184C99;
  --royal-2: #1C53A3;
  --paper: #F2F2F2;
  --white: #FFFFFF;

  --ink: var(--navy);
  --ink-2: #133461;          /* navy tinted toward sky, for secondary text on sky */
  --ground: var(--sky);
  --surface: var(--paper);
  --line: rgba(2, 29, 60, .14);
  --focus: var(--navy);

  --f-title: "League Spartan", "Baloo Bhaijaan 2", system-ui, sans-serif;
  --f-body: "Poppins", "Tajawal", system-ui, sans-serif;
  --f-label: "DM Sans", "Tajawal", system-ui, sans-serif;
  --f-hand: "Caveat", cursive;

  --ease-out: cubic-bezier(.23, 1, .32, 1);
  --ease-io: cubic-bezier(.77, 0, .175, 1);
  --ease-drawer: cubic-bezier(.32, .72, 0, 1);

  --wrap: 1312px;
  --gutter: clamp(16px, 4.4vw, 64px);
  --gap: clamp(16px, 1.7vw, 24px);
  --hdr: 104px;
  --r-sm: 10px;
  --r: 16px;
  --r-lg: 24px;

  --s: .96;                   /* phone scale, set by JS from the viewport height */
  --pw: calc(300px * var(--s));
  --ph: calc(630px * var(--s));
  --stick-top: calc(50svh - var(--ph) / 2 + 40px);

  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 1.0625rem/1.65 var(--f-body);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img, svg, canvas { display: block; max-width: 100%; }
img { height: auto; }
svg { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4, p, figure, ol, ul, dl, dd { margin: 0; }
ol, ul { padding: 0; list-style: none; }
::selection { background: var(--lime); color: var(--navy); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
html { scrollbar-color: var(--royal) var(--sky); scrollbar-width: thin; }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--sky); }
::-webkit-scrollbar-thumb { background: var(--royal); border-radius: 10px; border: 2px solid var(--sky); }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip {
  position: fixed; inset-inline-start: 16px; top: 12px; z-index: 100;
  background: var(--navy); color: var(--white); padding: 12px 18px; border-radius: var(--r-sm);
  font: 600 .95rem var(--f-body); text-decoration: none;
  transform: translateY(-160%); transition: transform 200ms var(--ease-out);
}
.skip:focus-visible { transform: none; outline-color: var(--lime); }

.wrap { width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto; }

/* ---------- Type ---------- */
.h-display, .h-section, .h-sub {
  font-family: var(--f-title);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: -.01em;
  text-wrap: balance;
  color: var(--royal);
}
.h-display { font-size: clamp(2.45rem, 1.1rem + 4.3vw, 5.1rem); line-height: .94; color: var(--navy); }
.h-section { font-size: clamp(1.9rem, 1.05rem + 2.5vw, 3.35rem); line-height: .98; }
.h-sub { font-size: clamp(1.45rem, 1rem + 1.2vw, 2.1rem); line-height: 1.02; }
.lead { font-size: clamp(1.05rem, .98rem + .3vw, 1.2rem); line-height: 1.6; max-width: 33em; color: var(--ink-2); }
p { max-width: 36em; text-wrap: pretty; }
.label { font: 700 .78rem/1.2 var(--f-label); letter-spacing: .12em; text-transform: uppercase; }

/* ---------- Buttons ---------- */
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  --bg: var(--navy); --fg: var(--white); --bd: var(--navy);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 24px;
  border: 2px solid var(--bd); border-radius: 14px;
  background: var(--bg); color: var(--fg);
  font: 600 1rem/1 var(--f-body); text-decoration: none; white-space: nowrap;
  cursor: pointer;
  transition: transform 160ms var(--ease-out), background-color 200ms ease, color 200ms ease, border-color 200ms ease;
}
.btn svg { width: 18px; height: 18px; transition: transform 200ms var(--ease-out); }
.btn:active { transform: scale(.97); }
.btn--line { --bg: transparent; --fg: var(--navy); --bd: var(--navy); }
@media (hover: hover) and (pointer: fine) {
  .btn--solid:hover { --bg: var(--royal); --bd: var(--royal); }
  .btn--line:hover { --bg: var(--navy); --fg: var(--white); }
  .btn:hover svg { transform: translateX(3px); }
  [dir="rtl"] .btn:hover svg { transform: scaleX(-1) translateX(3px); }
}
[dir="rtl"] .btn svg { transform: scaleX(-1); }
.link { display: inline-flex; align-items: center; gap: 8px; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; text-decoration-color: rgba(2,29,60,.35); transition: text-decoration-color 200ms ease; }
.link:hover { text-decoration-color: var(--navy); }
.link svg { width: 18px; height: 18px; }

/* ---------- Header ---------- */
.hdr {
  position: fixed; inset: 0 0 auto; z-index: 50;
  background: var(--sky);
  transition: box-shadow 240ms ease;
}
.hdr[data-compact="true"] { box-shadow: 0 1px 0 var(--line); }
.hdr__in {
  width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto;
  height: var(--hdr); display: flex; align-items: center; gap: 28px;
  transition: height 320ms var(--ease-out);
}
.hdr[data-compact="true"] .hdr__in { height: 72px; }
.hdr__logo { display: flex; align-items: center; flex: none; height: 100%; }
.hdr__lockup { height: 84px; width: auto; transition: height 320ms var(--ease-out); }
.hdr[data-compact="true"] .hdr__lockup { height: 58px; }
.hdr__nav { display: flex; gap: 6px; margin-inline-start: auto; }
.hdr__nav a {
  padding: 10px 12px; border-radius: 10px; text-decoration: none;
  font: 600 .95rem/1 var(--f-body); color: var(--navy);
  transition: background-color 200ms ease;
}
.hdr__nav a:hover { background: rgba(2,29,60,.08); }
.hdr__nav a[aria-current="true"] { background: rgba(2,29,60,.1); }
.hdr__tools { display: flex; align-items: center; gap: 12px; }
.hdr__cta { min-height: 46px; padding: 0 18px; font-size: .95rem; }
.lang { display: inline-flex; padding: 4px; border-radius: 12px; background: rgba(2,29,60,.08); }
.lang button {
  min-height: 38px; min-width: 44px; padding: 0 10px; border: 0; border-radius: 9px; background: transparent;
  font: 700 .8rem/1 var(--f-label); letter-spacing: .04em; color: var(--navy); cursor: pointer;
  transition: background-color 200ms ease, color 200ms ease, transform 160ms var(--ease-out);
}
.lang button[lang="ar"] { font: 700 .95rem/1 "Tajawal", sans-serif; letter-spacing: 0; }
.lang button:active { transform: scale(.96); }
.lang button[aria-pressed="true"] { background: var(--navy); color: var(--white); }
.hdr__menu { display: none; width: 48px; height: 48px; border: 0; border-radius: 12px; background: var(--navy); color: var(--white); cursor: pointer; align-items: center; justify-content: center; }
.hdr__menu svg { width: 22px; height: 22px; }
.menu {
  position: fixed; inset: 72px 0 0; background: var(--sky); padding: 24px var(--gutter) 40px;
  display: flex; flex-direction: column; gap: 28px;
}
.menu[hidden] { display: none; }
.menu nav { display: grid; }
.menu nav a { padding: 16px 0; border-bottom: 1px solid var(--line); text-decoration: none; font: 700 1.9rem/1 var(--f-title); text-transform: uppercase; color: var(--royal); }
.menu .btn { width: 100%; }

/* ---------- Story (hero + chapters with one sticky phone) ---------- */
.story {
  width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: var(--gap);
  position: relative;
}
.story__hero {
  grid-column: 1 / 8; grid-row: 1; position: relative; z-index: 3;
  min-height: 100svh; padding: calc(var(--hdr) + 32px) 0 72px;
  display: flex; flex-direction: column; justify-content: center; gap: 26px;
  pointer-events: none;
}
.story__hero > * { pointer-events: auto; }
.story__hero .h-display { max-width: 15ch; }
.story__hero .lead { max-width: 25em; }
.story__hero .fact { max-width: 27em; }
.fact { display: flex; align-items: center; gap: 12px; font: 600 .98rem/1.45 var(--f-body); color: var(--navy); }
.dots { flex: none; width: 22px; height: 10px; background: radial-gradient(circle 4px at 4px 5px, var(--lime) 98%, transparent), radial-gradient(circle 4px at 17px 5px, var(--lime) 98%, transparent); }

.story__carnet {
  grid-column: 5 / 12; grid-row: 1; align-self: end; position: relative; z-index: 1;
  height: min(62svh, 600px); margin-bottom: 3svh;
}
.carnet-canvas { width: 100%; height: 100%; opacity: 0; transition: opacity 600ms ease; }
.carnet-canvas.is-ready { opacity: 1; }
.carnet-fallback { display: none; position: absolute; inset: auto 6% 10% auto; width: 78%; border-radius: var(--r-lg); box-shadow: 0 30px 60px -30px rgba(2,29,60,.6); }
.no-webgl .carnet-canvas { display: none; }
.no-webgl .carnet-fallback { display: block; }

.story__device { grid-column: 9 / 13; grid-row: 1 / span 7; position: relative; z-index: 4; padding-top: var(--stick-top); }
.device-sticky { position: sticky; top: var(--stick-top); display: flex; justify-content: flex-end; }

.step {
  grid-column: 1 / 9; position: relative; z-index: 2;
  min-height: 100svh; padding-block: 14svh;
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: clamp(20px, 3vw, 48px); align-items: center;
}
.step__text { display: grid; gap: 22px; }
.step__text p { color: var(--ink-2); font-size: 1.08rem; }
.step__photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 40%; border-radius: var(--r-lg); box-shadow: 0 28px 50px -28px rgba(2,29,60,.55); }
.step__phone { display: none; }
.step__board img { width: 100%; max-width: 380px; margin-inline: auto; border-radius: var(--r-lg); box-shadow: 0 28px 50px -28px rgba(2,29,60,.5); }

/* Characters */
.cast { position: relative; display: flex; justify-content: center; align-items: flex-end; min-height: 440px; }
.step--money .cast { overflow-x: clip; }
.char { position: relative; width: max-content; }
.char img { height: clamp(300px, 46svh, 430px); width: auto; filter: drop-shadow(0 18px 14px rgba(2,29,60,.18)); }
.char--hanout img, .char--client-basket img { transform: scaleX(-1); }
[dir="rtl"] .char--hanout img, [dir="rtl"] .char--client-basket img { transform: none; }
.char[data-react="hop"] img { animation: hop 520ms var(--ease-out); }
@keyframes hop { 0%,100% { translate: 0 0; } 40% { translate: 0 -10px; } }
.char--hanout[data-react="hop"] img { animation-name: hop; }

.bubble {
  position: absolute; top: -8px; inset-inline-end: -36px; z-index: 2;
  padding: 10px 16px; border-radius: 18px 18px 18px 4px;
  background: var(--white); color: var(--navy);
  font: 600 1.05rem/1.2 var(--f-body); white-space: nowrap;
  box-shadow: 0 12px 24px -12px rgba(2,29,60,.45);
  transform-origin: 10% 100%;
  opacity: 0; transform: scale(.9) translateY(6px);
  transition: opacity 220ms var(--ease-out), transform 320ms var(--ease-out);
}
html:not(.js) .bubble, .bubble.is-on { opacity: 1; transform: none; }
.bubble--lime { background: var(--lime); }
[lang="ar"] .bubble { font-family: "Baloo Bhaijaan 2", sans-serif; font-size: 1.2rem; }
[dir="rtl"] .bubble { border-radius: 18px 18px 4px 18px; transform-origin: 90% 100%; }
.char--hanout .bubble { inset-inline-end: auto; inset-inline-start: -10px; top: -18px; }

.palm { position: absolute; z-index: 3; top: 35%; inset-inline-end: 6%; width: 0; height: 0; }
.bill {
  display: inline-flex; align-items: baseline; gap: 4px;
  padding: 10px 16px; border-radius: 10px;
  background:
    radial-gradient(circle 3px at 10px 10px, var(--sky) 98%, transparent),
    radial-gradient(circle 3px at 20px 10px, var(--sky) 98%, transparent),
    var(--lime);
  color: var(--navy); box-shadow: 0 14px 24px -12px rgba(2,29,60,.55), inset 0 0 0 2px rgba(2,29,60,.85);
  font: 700 1rem/1 var(--f-body); white-space: nowrap;
}
.bill b { font: 800 1.5rem/1 var(--f-body); letter-spacing: -.02em; }
.bill--held { position: absolute; left: 0; top: 0; transform: translate(-50%, -50%) rotate(-8deg); opacity: 0; transition: opacity 160ms ease; }
.bill--held.is-on { opacity: 1; }
.bill--fly { position: fixed; left: 0; top: 0; z-index: 60; pointer-events: none; opacity: 0; will-change: transform; }

.step--client .cast { justify-content: flex-end; padding-top: 104px; }
.notif {
  position: absolute; top: 0; inset-inline-start: 0; z-index: 3;
  display: flex; align-items: center; gap: 10px; padding: 12px 16px 12px 12px; max-width: 280px;
  background: var(--white); border-radius: 18px; box-shadow: 0 18px 30px -18px rgba(2,29,60,.55);
  opacity: 0; transform: translateY(8px) scale(.96);
  transition: opacity 240ms var(--ease-out), transform 420ms var(--ease-out);
}
html:not(.js) .notif, .notif.is-on { opacity: 1; transform: none; }
.notif img { width: 40px; height: 40px; border-radius: 12px; background: var(--sky); object-fit: cover; object-position: 50% 15%; }
.notif span { display: grid; line-height: 1.25; }
.notif b { font-size: .95rem; }
.notif small { font-size: .9rem; color: var(--ink-2); }

/* Transfer chips (carnet line to phone row) */
.chips-layer { position: fixed; inset: 0; pointer-events: none; z-index: 45; }
.chip-fly {
  position: absolute; left: 0; top: 0; display: inline-flex; gap: 14px; align-items: baseline;
  padding: 6px 14px; border-radius: 8px; background: #FBFAF6; color: #1F3270;
  box-shadow: 0 10px 22px -10px rgba(2,29,60,.5), inset 0 0 0 1px rgba(31,50,112,.12);
  font: 600 1.35rem/1.1 var(--f-hand); white-space: nowrap; will-change: transform, opacity, filter;
}
.chip-fly .ar { font: 700 1.25rem/1.1 "Aref Ruqaa", serif; }

/* ---------- Phone ---------- */
.phone { position: relative; width: var(--pw); height: var(--ph); flex: none; }
.phone__inner { position: absolute; left: 0; top: 0; width: 300px; height: 630px; transform: scale(var(--s)); transform-origin: 0 0; direction: ltr; }
.phone__frame {
  position: relative; width: 300px; height: 630px; padding: 10px; border-radius: 48px;
  background: linear-gradient(145deg, #1B2742, #050B18 60%);
  box-shadow:
    0 50px 80px -40px rgba(2,29,60,.7),
    0 18px 30px -18px rgba(2,29,60,.5),
    inset 0 0 0 2px #2E3B5E, inset 0 0 0 4px #0A1222;
}
.phone__frame::before, .phone__frame::after { content: ""; position: absolute; width: 3px; border-radius: 2px; background: #1B2742; }
.phone__frame::before { left: -3px; top: 120px; height: 56px; }
.phone__frame::after { right: -3px; top: 150px; height: 84px; }
.phone__island { position: absolute; z-index: 6; top: 20px; left: 50%; width: 84px; height: 24px; margin-left: -42px; border-radius: 20px; background: #000; }

.app {
  position: relative; height: 100%; border-radius: 38px; overflow: hidden;
  background: linear-gradient(180deg, #CFE0FF 0, #EEF3FC 150px, #F4F7FC 100%);
  font-family: "Poppins", "Tajawal", sans-serif; color: var(--navy);
  display: flex; flex-direction: column;
}
.app[dir="rtl"] { font-family: "Tajawal", sans-serif; }
.app svg { width: 18px; height: 18px; }
.app__status { display: flex; justify-content: space-between; align-items: center; height: 44px; padding: 14px 26px 0; font: 600 12px/1 "Poppins", sans-serif; direction: ltr; }
.app__status-icons { display: flex; gap: 4px; align-items: center; }
.app__status-icons i { width: 14px; height: 9px; border-radius: 2px; background: var(--navy); opacity: .8; }
.app__status-icons b { font-size: 11px; padding: 1px 4px; border: 1.5px solid var(--navy); border-radius: 4px; }
.app__top { display: flex; align-items: center; gap: 10px; padding: 8px 18px 10px; }
.app__avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; object-position: 50% 12%; background: var(--sky); box-shadow: 0 0 0 2px var(--white); }
.app__hello { display: grid; line-height: 1.15; }
.app__hello small { font-size: 11px; color: #4A5D7E; }
.app__hello strong { font-size: 15px; }
.app__bell { margin-inline-start: auto; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--white); }
.app__bell svg { width: 16px; height: 16px; }

.app__screens { position: relative; flex: 1; }
.scr {
  position: absolute; inset: 0; padding: 4px 16px 12px;
  display: flex; flex-direction: column; gap: 10px;
  opacity: 0; visibility: hidden; filter: blur(4px); transform: translateY(6px);
  transition: opacity 260ms ease, filter 300ms ease, transform 360ms var(--ease-out), visibility 0s linear 300ms;
}
.phone[data-screen="karni"] [data-scr="karni"],
.phone[data-screen="tap"] [data-scr="tap"],
.phone[data-screen="client"] [data-scr="client"],
.phone[data-screen="try"] [data-scr="try"],
.phone[data-screen="voice"] [data-scr="voice"],
.phone[data-screen="gains"] [data-scr="gains"] {
  opacity: 1; visibility: visible; filter: none; transform: none;
  transition: opacity 260ms ease 60ms, filter 300ms ease 60ms, transform 420ms var(--ease-out) 60ms, visibility 0s;
}
.app__h { display: flex; align-items: center; gap: 6px; font: 700 18px/1.2 "Poppins", "Tajawal", sans-serif; }
.app[dir="rtl"] .app__h { font-family: "Tajawal", sans-serif; font-weight: 700; }
.app__tabs {
  display: grid; grid-template-columns: repeat(4, 1fr); height: 66px; padding: 8px 8px 14px;
  background: var(--white); box-shadow: 0 -1px 0 rgba(2,29,60,.08);
}
.app__tabs span { display: grid; justify-items: center; align-content: center; gap: 3px; border-radius: 14px; color: #5B6B86; }
.app__tabs small { font-size: 10px; font-weight: 500; }
.app__tabs svg { width: 18px; height: 18px; }
.phone[data-screen="karni"] [data-tab="karni"],
.phone[data-screen="tap"] [data-tab="karni"],
.phone[data-screen="voice"] [data-tab="karni"],
.phone[data-screen="client"] [data-tab="karni"],
.phone[data-screen="try"] [data-tab="promo"],
.phone[data-screen="gains"] [data-tab="profile"] { color: var(--royal); background: #E3EDFF; }

/* Karni screen */
.karni__head { display: flex; justify-content: space-between; align-items: baseline; }
.karni__count { font: 600 12px/1 "Poppins", sans-serif; color: var(--royal-2); }
.app[dir="rtl"] .karni__count { font-family: "Tajawal", sans-serif; }
.karni__total { display: flex; justify-content: space-between; align-items: center; padding: 12px 14px; border-radius: 16px; background: var(--royal); color: var(--white); }
.karni__total small { font-size: 12px; opacity: .85; }
.karni__total strong { font-size: 18px; font-variant-numeric: tabular-nums; }
.karni__list { display: grid; gap: 6px; }
.row {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 14px; background: var(--white);
  box-shadow: 0 1px 0 rgba(2,29,60,.05);
}
.js .row { opacity: 0; transform: translateY(6px); filter: blur(4px); }
.row.is-in { opacity: 1; transform: none; filter: none; transition: opacity 300ms ease, transform 420ms var(--ease-out), filter 300ms ease; }
.row__av { flex: none; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: #E3EDFF; color: var(--royal-2); font: 700 13px/1 "Poppins", sans-serif; }
.row__txt { display: grid; line-height: 1.2; min-width: 0; }
.row__txt b { font-size: 13px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row__txt small { font-size: 10px; color: #56667F; }
.row__amt { margin-inline-start: auto; font: 700 13px/1 "Poppins", sans-serif; color: var(--royal-2); font-variant-numeric: tabular-nums; white-space: nowrap; }
.karni__toast {
  position: absolute; left: 16px; right: 16px; bottom: 64px; display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; border-radius: 14px; background: var(--navy); color: var(--white); font-size: 12px; font-weight: 500;
  opacity: 0; transform: translateY(8px); transition: opacity 240ms ease, transform 360ms var(--ease-out);
}
.karni__toast svg { width: 16px; height: 16px; color: var(--lime); }
.karni__toast.is-on { opacity: 1; transform: none; }
.app__fab {
  position: absolute; bottom: 12px; left: 50%; translate: -50% 0; display: inline-flex; align-items: center; gap: 6px;
  padding: 11px 18px; border-radius: 16px; background: var(--lime); color: var(--navy); font: 700 13px/1 "Poppins", "Tajawal", sans-serif;
  box-shadow: 0 10px 18px -10px rgba(2,29,60,.6); white-space: nowrap;
}

/* Tap screen */
.tap__head { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 6px 10px; border-radius: 999px; background: var(--white); font-size: 11px; font-weight: 600; box-shadow: inset 0 0 0 1px rgba(2,29,60,.1); transition: background-color 200ms ease, color 200ms ease; }
.chip svg { width: 13px; height: 13px; }
.chip--navy { background: var(--navy); color: var(--white); box-shadow: none; }
.chip--lime { background: var(--lime); color: var(--navy); box-shadow: none; }
.chip.is-on { background: var(--royal); color: var(--white); box-shadow: none; }
.tap__client { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 14px; background: var(--white); }
.tap__client small { display: block; font-size: 10px; color: #56667F; }
.tap__client b { font-size: 13px; }
.tap__amount { text-align: center; font: 700 34px/1.1 "Poppins", sans-serif; color: var(--navy); font-variant-numeric: tabular-nums; direction: ltr; }
.tap__amount small { font-size: 16px; color: var(--royal-2); }
.tap__chips { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.tap__pad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; direction: ltr; }
.tap__pad span { display: grid; place-items: center; height: 34px; border-radius: 10px; background: var(--white); font: 600 15px/1 "Poppins", sans-serif; transition: background-color 120ms ease, transform 120ms var(--ease-out); }
.tap__pad span.is-hit { background: #D7E6FF; transform: scale(.94); }
.tap__btn { display: grid; place-items: center; height: 42px; border-radius: 14px; background: var(--lime); font: 700 14px/1 "Poppins", "Tajawal", sans-serif; transition: transform 140ms var(--ease-out); }
.tap__btn.is-hit { transform: scale(.96); }
.tap__ok, .try__ok {
  position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: 8px; text-align: center; padding: 20px;
  background: rgba(244,247,252,.94); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; visibility: hidden; transition: opacity 260ms ease, visibility 0s linear 260ms;
}
.tap__ok.is-on, .try__ok.is-on { opacity: 1; visibility: visible; transition: opacity 260ms ease, visibility 0s; }
.tap__ok b, .try__ok b { font-size: 19px; }
.tap__ok small, .try__ok small { font-size: 12px; color: #4A5D7E; }
.ok-ring { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--lime); transform: scale(.9); transition: transform 420ms var(--ease-out); }
.is-on > .ok-ring { transform: none; }
.ok-ring svg { width: 30px; height: 30px; stroke-width: 3; color: var(--navy); }

/* Client screen */
.cl__head { display: flex; align-items: center; gap: 6px; font-size: 15px; }
.app[dir="rtl"] .cl__head svg { transform: scaleX(-1); }
.cl__card { display: grid; gap: 2px; padding: 18px; border-radius: 20px; background: var(--royal); color: var(--white); }
.cl__card small { font-size: 12px; opacity: .85; }
.cl__card strong { font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.cl__ops { display: grid; gap: 6px; }
.cl__ops li { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 14px; background: var(--white); font-size: 12px; }
.cl__ops b { margin-inline-start: auto; color: var(--royal-2); font-variant-numeric: tabular-nums; direction: ltr; }
.op-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--lime); flex: none; }
.cl__reminder {
  display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 14px; background: #E3EDFF; color: var(--royal); font-size: 12px; font-weight: 600;
  opacity: 0; transform: translateY(6px); transition: opacity 240ms ease, transform 360ms var(--ease-out);
}
.cl__reminder.is-on { opacity: 1; transform: none; }

/* Try screen */
.try__cam { position: relative; height: 270px; border-radius: 22px; background: #0B1730; display: grid; place-items: center; overflow: hidden; }
.try__qr { width: 132px; height: 132px; fill: var(--white); stroke: none; padding: 8px; background: var(--white); border-radius: 6px; }
.try__qr path { fill: var(--navy); }
.try__corners { position: absolute; inset: 50px 58px 64px; border-radius: 12px;
  background:
    linear-gradient(var(--lime), var(--lime)) top left / 26px 4px no-repeat,
    linear-gradient(var(--lime), var(--lime)) top left / 4px 26px no-repeat,
    linear-gradient(var(--lime), var(--lime)) top right / 26px 4px no-repeat,
    linear-gradient(var(--lime), var(--lime)) top right / 4px 26px no-repeat,
    linear-gradient(var(--lime), var(--lime)) bottom left / 26px 4px no-repeat,
    linear-gradient(var(--lime), var(--lime)) bottom left / 4px 26px no-repeat,
    linear-gradient(var(--lime), var(--lime)) bottom right / 26px 4px no-repeat,
    linear-gradient(var(--lime), var(--lime)) bottom right / 4px 26px no-repeat; }
.try__line { position: absolute; left: 62px; right: 62px; top: 56px; height: 2px; background: var(--lime); box-shadow: 0 0 12px 2px rgba(151,203,7,.7); opacity: 0; }
.try__cam small { position: absolute; bottom: 16px; color: #C9D6EE; font-size: 11px; }
.try__prod { display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 12px; background: var(--white); font-size: 13px; font-weight: 600; }

/* Gains screen */
.g__level { padding: 14px; border-radius: 18px; background: var(--white); display: grid; gap: 10px; }
.g__level-top { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }
.g__stars { display: flex; gap: 2px; color: var(--lime); }
.g__stars svg { width: 15px; height: 15px; fill: var(--lime); stroke: var(--lime); }
.g__bar { height: 10px; border-radius: 10px; background: #E3EDFF; overflow: hidden; }
.g__bar i { display: block; height: 100%; width: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--royal-2), var(--lime)); transform-origin: left; transform: scaleX(var(--g, 1)); transition: transform 900ms var(--ease-out); }
.app[dir="rtl"] .g__bar i { transform-origin: right; background: linear-gradient(-90deg, var(--royal-2), var(--lime)); }
.g__money { display: grid; justify-items: center; padding: 14px; border-radius: 20px; background: var(--royal); color: var(--white); transition: background-color 300ms ease; }
.g__money strong { font-size: 38px; line-height: 1.05; font-variant-numeric: tabular-nums; }
.g__money small { font-size: 12px; opacity: .85; }
.g__money.is-out { background: var(--navy); }
.g__btn { display: flex; justify-content: center; align-items: center; gap: 8px; height: 44px; padding: 0 14px; border-radius: 14px; background: var(--lime); font: 700 13px/1 "Poppins", "Tajawal", sans-serif; }
.g__acts { display: grid; gap: 4px; }
.g__acts li { display: flex; align-items: center; gap: 8px; font-size: 12px; padding: 6px 4px; }
.g__acts svg { width: 16px; height: 16px; color: var(--royal-2); stroke-width: 2.6; }

/* Voice entry screen (coming soon) */
.v__mic { position: relative; display: grid; place-items: center; height: 92px; }
.v__btn { position: relative; z-index: 1; display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--lime); color: var(--navy); box-shadow: 0 10px 18px -10px rgba(2,29,60,.6); }
.v__btn svg { width: 28px; height: 28px; }
.v__ring { position: absolute; width: 64px; height: 64px; border-radius: 50%; background: rgba(151,203,7,.35); opacity: 0; }
.scr--voice.is-live .v__ring { animation: ring 1.2s var(--ease-out) 3; }
@keyframes ring { from { transform: scale(1); opacity: .9; } to { transform: scale(1.9); opacity: 0; } }
.v__wave { display: flex; justify-content: center; align-items: center; gap: 4px; height: 26px; }
.v__wave i { width: 4px; height: 8px; border-radius: 4px; background: var(--royal-2); }
.scr--voice.is-live .v__wave i { animation: wave 520ms ease-in-out infinite alternate; }
.v__wave i:nth-child(2n) { animation-delay: 120ms; }
.v__wave i:nth-child(3n) { animation-delay: 240ms; }
@keyframes wave { to { height: 24px; } }
.v__heard { justify-self: center; align-self: center; padding: 8px 12px; border-radius: 14px 14px 14px 4px; background: var(--navy); color: var(--white); font-size: 12px; font-weight: 600; text-align: center; }
.v__ask { display: grid; gap: 8px; padding: 10px 12px; border-radius: 14px; background: var(--white); }
.v__ask small { font-size: 12px; font-weight: 600; }
.v__tastes { display: flex; flex-wrap: wrap; gap: 6px; }
.v__done { display: flex; align-items: center; gap: 6px; padding: 10px 12px; border-radius: 14px; background: #E3EDFF; color: var(--royal); font-size: 11px; font-weight: 600; }
.v__done svg { width: 15px; height: 15px; flex: none; stroke-width: 2.6; }
.v__heard, .v__ask, .v__done { opacity: 0; transform: translateY(6px); transition: opacity 240ms ease, transform 360ms var(--ease-out); }
.v__heard.is-on, .v__ask.is-on, .v__done.is-on { opacity: 1; transform: none; }

/* "Coming soon" sticker on the voice chapter's picture */
.soon {
  position: absolute; z-index: 2; top: 18%; inset-inline-start: -78px;
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 12px; border-radius: 999px;
  background: var(--navy); color: var(--lime); font: 700 .78rem/1 var(--f-label); letter-spacing: .1em; text-transform: uppercase;
}
.soon svg { width: 15px; height: 15px; }
[lang="ar"] .soon { letter-spacing: 0; font-size: .9rem; }
.char--voice .bubble { top: -12px; }

/* Who-are-you rows: picture slot (shown once join-*.png exists) */
.path.has-art { grid-template-columns: 168px minmax(0, 1fr) auto; }
.path__art { width: 168px; height: 126px; border-radius: 16px; object-fit: cover; background: #E3EDFF; }

/* ---------- Royal theme ---------- */
.theme-royal { --ground: var(--royal); --ink: var(--white); --ink-2: #DCE7FF; --line: rgba(255,255,255,.18); --focus: var(--lime); background: var(--royal); color: var(--white); }
.theme-royal .h-section, .theme-royal .h-sub { color: var(--white); }
.theme-royal .btn--solid { --bg: var(--lime); --fg: var(--navy); --bd: var(--lime); }
.theme-royal .btn--line { --fg: var(--white); --bd: var(--white); }

/* ---------- Client ---------- */
.client { padding-block: clamp(80px, 12svh, 140px); min-height: 100svh; display: grid; align-content: center; }
.client__head { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: var(--gap); align-items: end; margin-bottom: clamp(32px, 5svh, 56px); }
.client__head p { color: var(--ink-2); }
.board { display: grid; grid-template-columns: 1.25fr 1fr 1fr; gap: var(--gap); }
.panel {
  position: relative; display: grid; grid-template-rows: auto 1fr; gap: 18px; overflow: hidden;
  padding: 22px; border-radius: var(--r-lg); background: var(--lime); color: var(--navy);
  transition: transform 240ms var(--ease-out);
}
.panel h3 { font: 700 1.35rem/1.05 var(--f-title); text-transform: uppercase; color: var(--navy); }
.panel p { margin-top: 8px; font-size: .98rem; color: #1B3A13; color: var(--navy); }
.panel__art { display: grid; place-items: end center; min-height: 250px; }
.panel--wide .panel__art img { border-radius: var(--r); width: 100%; }
.panel__art--duo { grid-template-columns: auto auto; justify-content: center; align-items: end; gap: 10px; }
.panel__char { height: 230px; width: auto; }
.panel__gift { width: 120px; border-radius: var(--r); align-self: end; }
.mini-phone { width: 128px; padding: 5px; border-radius: 22px; background: #0B1222; box-shadow: 0 20px 30px -18px rgba(2,29,60,.7); }
.mini-phone img { border-radius: 17px; aspect-ratio: 720 / 1500; object-fit: cover; object-position: top; }
@media (hover: hover) and (pointer: fine) {
  .panel:hover { transform: translateY(-2px); }
  .panel img { transition: transform 400ms var(--ease-out); }
  .panel:hover .panel__art img { transform: scale(1.025); }
}

/* ---------- Brands ---------- */
.brands { padding-block: clamp(88px, 13svh, 150px); }
.brands__head { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: var(--gap) clamp(24px, 4vw, 64px); align-items: end; }
.brands__intro { display: grid; gap: 22px; justify-items: start; }
.brands__intro p { color: var(--ink-2); }

.chain { margin-top: clamp(48px, 7svh, 72px); position: relative; }
.chain__nodes { display: grid; grid-template-columns: repeat(4, 1fr); }
.chain__nodes li { display: grid; justify-items: start; gap: 12px; }
.chain__nodes b { font: 700 clamp(1.1rem, .9rem + .8vw, 1.6rem)/1 var(--f-title); text-transform: uppercase; color: var(--navy); }
.chain__dot { width: 18px; height: 18px; border-radius: 50%; background: var(--navy); box-shadow: 0 0 0 5px var(--sky); position: relative; z-index: 2; }
.chain__track { position: absolute; left: 9px; right: 0; top: 8px; height: 3px; display: flex; }
.chain__nodes li:last-child { justify-items: start; }
.chain__seen { flex: 1; background: var(--navy); }
.chain__blind { flex: 2; background: repeating-linear-gradient(90deg, var(--navy) 0 8px, transparent 8px 16px); opacity: .45; transition: opacity 400ms ease, background 400ms ease; }
.chain.is-lit .chain__blind { opacity: 1; background: var(--lime); }
.chain__pulse { position: absolute; top: -5px; left: 0; width: 13px; height: 13px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 0 4px rgba(151,203,7,.35); opacity: 0; }
.chain__labels { display: grid; grid-template-columns: 1fr 2fr; margin-top: 18px; gap: var(--gap); }
.chain__lbl { font: 700 .8rem/1.3 var(--f-label); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-2); }
.chain__lbl--blind { display: grid; gap: 6px; }
.chain__lbl--blind s { text-decoration-thickness: 2px; text-decoration-color: transparent; transition: text-decoration-color 400ms ease; }
.chain.is-lit .chain__lbl--blind s { text-decoration-color: var(--navy); }
.chain__lbl--blind b { justify-self: start; padding: 6px 10px; border-radius: 8px; background: var(--navy); color: var(--lime); opacity: 0; transform: translateY(4px); transition: opacity 300ms ease 200ms, transform 400ms var(--ease-out) 200ms; }
.chain.is-lit .chain__lbl--blind b { opacity: 1; transform: none; }
html:not(.js) .chain .chain__lbl--blind b { opacity: 1; transform: none; }
[dir="rtl"] .chain__track { left: 0; right: 9px; flex-direction: row-reverse; }
[dir="rtl"] .chain__pulse { left: auto; right: 0; }
[dir="rtl"] .palm { inset-inline-end: 12%; }
[dir="rtl"] .chain__lbl, [dir="rtl"] .chain__nodes b { letter-spacing: 0; }

/* Dashboard (live HTML, demo data) */
.dash {
  margin-top: clamp(48px, 7svh, 80px);
  display: grid; grid-template-columns: 220px minmax(0, 1fr); overflow: hidden;
  border-radius: 26px; background: #F3F6FB; color: var(--navy);
  box-shadow: 0 50px 90px -50px rgba(2,29,60,.75), 0 0 0 1px rgba(2,29,60,.06);
  font-family: "Poppins", sans-serif; direction: ltr; text-align: left;
}
.dash svg { width: 18px; height: 18px; }
.dash__side { background: var(--navy); color: #C9D6EE; padding: 22px 16px; display: grid; align-content: start; gap: 22px; }
.dash__brand { display: flex; align-items: center; gap: 10px; color: var(--white); }
.dash__brand img { width: 42px; height: 42px; border-radius: 50%; background: var(--sky); object-fit: cover; object-position: 50% 12%; }
.dash__brand span { display: grid; line-height: 1.15; }
.dash__brand b { font: 700 20px/1 var(--f-title); }
.dash__brand small { font-size: 11px; opacity: .8; }
.dash__side ul { display: grid; gap: 4px; }
.dash__side li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 12px; font-size: 13px; }
.dash__side li.is-on { background: var(--lime); color: var(--navy); font-weight: 600; }
.dash__main { padding: 22px; display: grid; gap: 16px; min-width: 0; }
.dash__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.dash__top h3 { font: 700 clamp(1.05rem, .9rem + .5vw, 1.4rem)/1.15 "Poppins", sans-serif; }
.dash__top small { font-size: 12px; color: #4A5D7E; }
.dash__demo { flex: none; padding: 6px 12px; border-radius: 999px; background: #FFF1E0; color: #8A4B00; font-size: 12px; font-weight: 600; box-shadow: inset 0 0 0 1px #F5C68E; }
.dash__kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.kpi { display: grid; gap: 8px; align-content: start; padding: 14px; border-radius: 18px; background: var(--white); box-shadow: 0 1px 0 rgba(2,29,60,.05); font-size: 12px; color: #4A5D7E; }
.kpi small { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 500; color: var(--navy); }
.kpi small svg { width: 16px; height: 16px; color: var(--royal-2); }
.kpi b { font: 700 clamp(1.6rem, 1.1rem + 1.2vw, 2.3rem)/1 "Poppins", sans-serif; color: var(--navy); font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.kpi b em { font-style: normal; font-size: max(.5em, 14px); color: #4A5D7E; }
.kpi__bar { display: block; height: 6px; border-radius: 6px; background: #E3EDFF; overflow: hidden; }
.kpi__bar i { display: block; height: 100%; width: 100%; background: #83B3FF; transform-origin: left; transform: scaleX(var(--v)); border-radius: inherit; }
.kpi__bar--lime i { background: var(--lime); }
.kpi__stars { display: flex; gap: 2px; color: var(--lime); }
.kpi__stars svg { width: 15px; height: 15px; fill: var(--lime); stroke: var(--lime); }
.kpi__stars .half { fill: none; }
.kpi--royal { background: var(--royal); color: #DCE7FF; }
.kpi--royal small { color: var(--white); }
.kpi--royal small svg { color: var(--lime); }
.kpi--royal b { color: var(--lime); }
.dash__row { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 12px; }
.dash__chart, .dash__zones { padding: 16px; border-radius: 18px; background: var(--white); }
.dash h4 { font-size: 14px; font-weight: 600; margin-bottom: 12px; display: flex; justify-content: space-between; gap: 8px; }
.dash h4 small { font-weight: 400; color: #4A5D7E; font-size: 12px; }
.bars { height: 200px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; align-items: end; padding-top: 22px; border-bottom: 1px solid #E3EDFF; }
.bar { position: relative; height: 100%; }
.bar i { position: absolute; bottom: 0; left: 14%; width: 72%; height: calc(var(--h) * 100%); border-radius: 10px 10px 4px 4px; background: #83B3FF; transform-origin: bottom; }
.bar--lime i { background: var(--lime); }
.bar b { position: absolute; left: 0; right: 0; text-align: center; bottom: calc(var(--h) * 100% + 6px); font-size: 14px; font-weight: 700; }
.bar small { position: absolute; left: 0; right: 0; text-align: center; bottom: -24px; font-size: 11px; color: #4A5D7E; white-space: nowrap; }
.dash__chart { padding-bottom: 36px; }
.js .dash:not(.is-in) .bar i { transform: scaleY(.04); }
.dash.is-in .bar i { transition: transform 900ms var(--ease-out); }
.dash.is-in .bar:nth-child(2) i { transition-delay: 70ms; }
.dash.is-in .bar:nth-child(3) i { transition-delay: 140ms; }
.dash.is-in .bar:nth-child(4) i { transition-delay: 210ms; }
.dash__zones ul { display: grid; gap: 8px; }
.dash__zones li { display: flex; align-items: center; gap: 10px; font-size: 13px; font-weight: 600; }
.dash__zones li span:nth-child(2) { display: grid; line-height: 1.2; }
.dash__zones li small { font-weight: 400; color: #4A5D7E; font-size: 11px; }
.dash__zones li b { margin-left: auto; font-size: 16px; color: var(--royal-2); }
.zone { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; font-weight: 700; font-size: 13px; }
.zone--a { background: var(--lime); color: var(--navy); }
.zone--b { background: var(--royal); color: var(--white); }
.zone--c { background: var(--sky); color: var(--navy); }
.dash__h-un { margin-top: 16px; }
.dash__un li { padding: 8px 10px; border-radius: 12px; background: #F4F9E6; }
.dash__un li b { margin: 0; min-width: 34px; font-size: 18px; color: var(--navy); }
.dash__un li span { font-weight: 500; }
.dash__un li svg { margin-left: auto; color: #5F8A06; }

.offres { padding-block: clamp(88px, 13svh, 150px); }
.theme-royal .offer, .theme-royal .offer:last-child { border-color: rgba(255,255,255,.4); }
.theme-royal .offer dt, .theme-royal .flow__list h4 { color: var(--white); }
.theme-royal .flow__list p { color: var(--ink-2); }
.theme-royal .trust-notes p { background: var(--lime); color: var(--navy); }
.theme-royal .trust-notes svg { color: var(--navy); }
.offers { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: var(--gap) clamp(24px, 4vw, 64px); }
.offers__list { display: grid; }
.offer { display: grid; grid-template-columns: 11rem minmax(0, 1fr) auto; gap: 8px 24px; align-items: baseline; padding: 20px 0; border-top: 2px solid var(--navy); }
.offer:last-child { border-bottom: 2px solid var(--navy); }
.offer dt { font: 700 1.3rem/1.1 var(--f-title); text-transform: uppercase; color: var(--navy); }
.offer dd { color: var(--ink-2); font-size: 1rem; }
.offer .offer__pay { font: 700 .76rem/1.2 var(--f-label); letter-spacing: .1em; text-transform: uppercase; color: var(--navy); padding: 6px 10px; border-radius: 8px; background: var(--paper); white-space: nowrap; }
[dir="rtl"] .offer .offer__pay { letter-spacing: 0; }

.flow { margin-top: clamp(64px, 9svh, 110px); }
.flow__list { margin-top: 28px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gap); counter-reset: f; }
.flow__list li { display: grid; gap: 10px; align-content: start; }
.flow__list figure { aspect-ratio: 1; overflow: hidden; border-radius: var(--r-lg); background: var(--royal); }
.flow__list img { width: 100%; height: 100%; object-fit: cover; transition: transform 400ms var(--ease-out); }
.flow__list li:first-child img { object-position: 52% 30%; }
.flow__list li:last-child img { object-position: 50% 50%; }
.flow__list h4 { margin-top: 8px; font: 700 1.2rem/1.05 var(--f-title); text-transform: uppercase; color: var(--navy); }
.flow__list p { font-size: .98rem; color: var(--ink-2); }
@media (hover: hover) and (pointer: fine) { .flow__list li:hover img { transform: scale(1.03); } }

.trust-notes { margin-top: clamp(48px, 7svh, 80px); display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); }
.trust-notes p { display: flex; gap: 14px; align-items: flex-start; padding: 20px 22px; border-radius: var(--r-lg); background: var(--paper); color: var(--navy); font-size: 1rem; max-width: none; }
.trust-notes svg { flex: none; width: 24px; height: 24px; color: var(--royal); }

/* ---------- FAQ ---------- */
.faq { padding-block: clamp(88px, 13svh, 150px); min-height: 100svh; display: grid; align-content: center; }
.faq__grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.faq__side { display: grid; gap: 40px; justify-items: start; position: sticky; top: 120px; }
.faq__char { height: 300px; width: auto; filter: drop-shadow(0 16px 14px rgba(0,0,0,.18)); }
.faq__list { display: grid; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; gap: 20px;
  padding: 24px 0; min-height: 44px; font: 600 clamp(1.08rem, 1rem + .4vw, 1.3rem)/1.3 var(--f-body);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 34px; height: 34px; border-radius: 50%;
  background:
    linear-gradient(var(--navy), var(--navy)) center / 14px 2px no-repeat,
    linear-gradient(var(--navy), var(--navy)) center / 2px 14px no-repeat,
    var(--lime);
  transition: transform 260ms var(--ease-out);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { padding: 0 0 26px; color: var(--ink-2); max-width: 40em; }
@media (hover: hover) and (pointer: fine) { .faq summary:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 6px; } }

/* ---------- Who are you: one path per audience ---------- */
.join { padding-block: clamp(88px, 13svh, 150px); }
.join__grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: var(--gap) clamp(24px, 4vw, 64px); align-items: start; }
.join__list { display: grid; }
.path { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 10px 20px; align-items: center; padding: 22px 0; border-top: 1px solid rgba(255,255,255,.32); }
.path:last-child { border-bottom: 1px solid rgba(255,255,255,.32); }
.path__icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px; background: var(--lime); color: var(--navy); }
.path__icon svg { width: 24px; height: 24px; }
.path h3 { font: 700 1.3rem/1.1 var(--f-title); text-transform: uppercase; color: var(--white); text-wrap: balance; }
.path p { margin-top: 6px; color: var(--ink-2); font-size: .98rem; }
.path .btn { white-space: nowrap; }

/* ---------- End (lime moment) ---------- */
.theme-lime { --ground: var(--lime); --ink: var(--navy); --ink-2: var(--navy); --line: rgba(2,29,60,.2); --focus: var(--navy); background: var(--lime); color: var(--navy); }
.end { padding-block: clamp(88px, 13svh, 150px); min-height: 90svh; display: grid; align-content: center; }
.end__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, .6fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.end__text { display: grid; gap: 28px; }
.end .h-display { color: var(--navy); max-width: 15ch; }
.end__h2 { display: block; color: var(--royal); }
.end .lead { color: var(--navy); }
.end__logo { width: min(100%, 340px); justify-self: end; border-radius: var(--r-lg); }
.theme-lime .btn--solid:hover { --bg: var(--royal); --bd: var(--royal); }

/* ---------- Footer ---------- */
.ftr { padding-block: 64px 40px; }
.ftr__grid { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 40px var(--gap); }
.ftr__brand { display: grid; gap: 18px; justify-items: start; }
.ftr__brand img { width: 200px; }
.ftr__brand p { color: var(--ink-2); font-size: .98rem; max-width: 30em; }
.ftr__contact { display: grid; gap: 8px; align-content: start; font-weight: 600; }
.ftr__contact p { font-weight: 400; color: var(--ink-2); }
.ftr__trust { grid-column: 1 / -1; display: grid; gap: 16px; }
.ftr__trust .label { color: var(--navy); }
[dir="rtl"] .label { letter-spacing: 0; }
.logos { display: flex; flex-wrap: wrap; gap: 12px; }
.logos li { display: grid; place-items: center; height: 72px; padding: 10px 18px; border-radius: 14px; background: var(--white); }
.logos img { max-height: 48px; width: auto; }
.ftr__legal { grid-column: 1 / -1; font-size: .9rem; color: var(--ink-2); border-top: 1px solid var(--line); padding-top: 20px; max-width: none; }

/* ---------- Hero entrance (once, on load) ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(18px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
/* Hold the hero and header text until the chosen language is applied (no flash of French). */
.js:not(.i18n-ready) .story__hero > *, .js:not(.i18n-ready) .hdr__nav, .js:not(.i18n-ready) .hdr__tools { opacity: 0; }
@media (prefers-reduced-motion: no-preference) {
  .js.i18n-ready [data-enter] .story__hero > * { animation: rise 760ms var(--ease-out) both; }
  .js.i18n-ready [data-enter] .story__hero > :nth-child(2) { animation-delay: 90ms; }
  .js.i18n-ready [data-enter] .story__hero > :nth-child(3) { animation-delay: 170ms; }
  .js.i18n-ready [data-enter] .story__hero > :nth-child(4) { animation-delay: 240ms; }
  .js [data-enter] .device-sticky .phone { animation: rise 900ms var(--ease-out) 200ms both; }
  .js.i18n-ready .hero-title mark { animation: marker 1000ms var(--ease-io) 700ms both; }
}

/* Hero title: navy, then royal with a lime highlighter stroke (the carnet's highlighter) */
.hero-title__b { color: var(--royal); }
.hero-title mark {
  color: inherit; padding: 0 .04em;
  background: linear-gradient(to top, transparent .05em, var(--lime) .05em, var(--lime) .36em, transparent .36em) no-repeat left bottom / 100% 100%;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
[dir="rtl"] .hero-title mark { background-position: right bottom; }
@keyframes marker { from { background-size: 0% 100%; } to { background-size: 100% 100%; } }

/* Early-bird offer */
.step__text .offer-note {
  display: inline-flex; align-items: center; gap: 10px; justify-self: start;
  padding: 12px 16px; border-radius: 14px; background: var(--navy); color: var(--white);
  font: 600 1rem/1.4 var(--f-body); max-width: 32em;
}
.offer-note svg { flex: none; width: 22px; height: 22px; color: var(--lime); }

/* Email fallback panel (shown only when no mail app opened) */
.mailhelp {
  position: fixed; inset: auto auto 24px 50%; translate: -50% 12px; margin: 0;
  width: min(460px, calc(100vw - 32px)); padding: 24px; border: 0; border-radius: 22px;
  background: var(--white); color: var(--navy);
  box-shadow: 0 40px 80px -30px rgba(2,29,60,.55), 0 0 0 1px rgba(2,29,60,.08);
  display: none; opacity: 0;
  transition: opacity 220ms var(--ease-out), translate 320ms var(--ease-out), display 320ms allow-discrete, overlay 320ms allow-discrete;
}
.mailhelp:popover-open, .mailhelp.is-open { display: grid; gap: 12px; opacity: 1; translate: -50% 0; }
@starting-style { .mailhelp:popover-open { opacity: 0; translate: -50% 12px; } }
.mailhelp__x { position: absolute; top: 12px; inset-inline-end: 12px; display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 12px; background: var(--paper); color: var(--navy); cursor: pointer; }
.mailhelp__x svg { width: 20px; height: 20px; }
.mailhelp__t { font: 700 1.45rem/1.1 var(--f-title); text-transform: uppercase; color: var(--royal); padding-inline-end: 52px; }
.mailhelp__p { color: var(--ink-2); font-size: .98rem; }
.mailhelp__addr { display: flex; align-items: center; gap: 8px; font-weight: 600; direction: ltr; justify-content: flex-start; }
[dir="rtl"] .mailhelp__addr { justify-content: flex-end; }
.mailhelp__addr svg { width: 18px; height: 18px; color: var(--royal); }
.mailhelp__acts { display: flex; flex-wrap: wrap; gap: 8px; }
.mailhelp__acts .btn { flex: 1 1 auto; min-height: 48px; padding: 0 18px; }

/* ---------- Arabic ---------- */
[lang="ar"] { --f-title: "Baloo Bhaijaan 2", system-ui, sans-serif; --f-body: "Tajawal", system-ui, sans-serif; --f-label: "Tajawal", system-ui, sans-serif; }
[lang="ar"] .h-display, [lang="ar"] .h-section, [lang="ar"] .h-sub { font-weight: 800; letter-spacing: 0; line-height: 1.2; }
[lang="ar"] .h-display { font-size: clamp(2.2rem, 1.1rem + 3.6vw, 4.4rem); }
[lang="ar"] .h-section { font-size: clamp(1.8rem, 1rem + 2.2vw, 3rem); }
[lang="ar"] .story__hero .h-display { max-width: 14ch; }
[lang="ar"] body, [lang="ar"] .lead, [lang="ar"] p { line-height: 1.8; }
[lang="ar"] .path h3, [lang="ar"] .panel h3, [lang="ar"] .offer dt, [lang="ar"] .flow__list h4, [lang="ar"] .chain__nodes b, [lang="ar"] .menu nav a { font-weight: 800; letter-spacing: 0; line-height: 1.25; }
[lang="ar"] .btn { font-weight: 700; font-size: 1.05rem; }
[dir="rtl"] .hdr__nav, [dir="rtl"] .hdr__tools { direction: rtl; }

/* ---------- Responsive ---------- */
@media (max-width: 1180px) and (min-width: 821px) {
  .story__hero { padding-top: calc(var(--hdr) + 8px); gap: 20px; }
  .story__hero .h-display { font-size: clamp(2.4rem, 1rem + 3.4vw, 3.5rem); max-width: 15ch; }
  .story__hero .lead { max-width: 22em; font-size: 1rem; }
}

@media (max-width: 1180px) {
  .hdr__nav { display: none; }
  .hdr__menu { display: inline-flex; }
  .hdr__tools { margin-inline-start: auto; }
  .story__hero { grid-column: 1 / 9; }
  .story__carnet { grid-column: 4 / 10; }
  .story__device { grid-column: 9 / 13; }
  .step { grid-column: 1 / 9; grid-template-columns: 1fr; align-content: center; gap: 28px; }
  .cast { min-height: 360px; justify-content: flex-start; }
  .board { grid-template-columns: 1fr 1fr; }
  .panel--wide { grid-column: 1 / -1; }
  .panel--wide .panel__art img { max-height: 280px; width: auto; }
  .dash { grid-template-columns: 1fr; }
  .dash__side { display: none; }
  .offers { grid-template-columns: 1fr; }
}

@media (max-width: 820px) {
  :root { --hdr: 72px; }
  .hdr__lockup, .hdr[data-compact="true"] .hdr__lockup { height: 54px; }
  .hdr__cta { display: none; }
  .hdr__menu { display: inline-flex; }
  .lang button { min-width: 44px; padding: 0 8px; }

  .story { grid-template-columns: minmax(0, 1fr); }
  .story__hero { grid-column: 1; grid-row: 1; min-height: auto; padding: calc(var(--hdr) + 28px) 0 24px; gap: 20px; }
  .story__hero .h-display { max-width: 15ch; }
  .story__carnet { grid-column: 1; grid-row: 2; align-self: start; justify-self: start; width: 64%; height: calc(var(--ph) + 10px); margin: 0; }
  .story__device { grid-column: 1; grid-row: 2; padding-top: 0; }
  .step--paper { grid-row: 3; }
  .step--tap { grid-row: 4; }
  .step--voice { grid-row: 5; }
  .step--client { grid-row: 6; }
  .step--try { grid-row: 7; }
  .step--money { grid-row: 8; }
  .soon { inset-inline-start: -64px; }
  .device-sticky { position: static; justify-content: flex-end; }
  .step { grid-column: 1; min-height: 0; padding: 72px 0 32px; align-content: start; gap: 24px; }
  .step__phone { display: flex; justify-content: center; --s: .58; --pw: calc(300px * var(--s)); --ph: calc(630px * var(--s)); }
  .cast { min-height: 0; justify-content: center; }
  .char img { height: 220px; }
  .bubble { inset-inline-end: -24px; font-size: .95rem; }
  .notif { position: relative; top: auto; margin-bottom: 12px; }
  .step--client .cast { flex-direction: column; align-items: center; padding-top: 0; }
  .step--money .cast { padding-top: 8px; }
  .step--voice .cast, .step--tap .cast { padding-top: 48px; }
  .char--hanout .bubble { top: 16%; inset-inline-start: auto; inset-inline-end: calc(100% + 6px); }
  .step__photo img { aspect-ratio: 16 / 10; }
  .step__board img { max-width: 260px; }

  .client__head, .brands__head, .faq__grid, .end__grid, .trust-notes, .join__grid { grid-template-columns: 1fr; }
  .path { grid-template-columns: 44px minmax(0, 1fr); }
  .path__icon { width: 44px; height: 44px; border-radius: 14px; }
  .path .btn { grid-column: 1 / -1; width: 100%; white-space: normal; }
  .path.has-art { grid-template-columns: 116px minmax(0, 1fr); align-items: start; }
  .path__art { width: 116px; height: 87px; border-radius: 12px; }
  .board { grid-template-columns: 1fr; }
  .panel__art { min-height: 0; }
  .faq__side { position: static; }
  .faq__char { display: none; }
  .chain__nodes b { font-size: 1rem; }
  .chain__labels { grid-template-columns: 1fr; }
  .dash__kpis { grid-template-columns: 1fr 1fr; }
  .dash__row { grid-template-columns: 1fr; }
  .dash__top { flex-direction: column; }
  .offer { grid-template-columns: 1fr; }
  .offer .offer__pay { justify-self: start; }
  .flow__list { grid-template-columns: 1fr 1fr; }
  .end__logo { justify-self: start; width: 180px; }
  .ftr__grid { grid-template-columns: 1fr; }
  .actions .btn { flex: 1 1 auto; }
}

@media (max-width: 420px) {
  .lang button { min-width: 40px; font-size: .74rem; }
  .flow__list { grid-template-columns: 1fr; }
  .dash__main { padding: 14px; }
  .kpi { padding: 12px; }
  .chain__nodes { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; scroll-behavior: auto !important; }
  .js .row { opacity: 1; transform: none; filter: none; }
  .scr { transform: none !important; filter: none !important; }
}
