/* ==========================================================================
   NAWA — brand tokens (from NAWA Brand Guidelines, Working Identity 01)
   Balance: ivory 55% · forest 30% · terracotta 10% · sage 5%
   Small text only forest-on-ivory or ivory-on-forest.
   ========================================================================== */
:root {
  --forest: #182824;
  --forest-2: #1f332e;
  --forest-3: #2a423b;
  --ivory: #F5F1E8;
  --ivory-2: #ECE6D9;
  --ivory-3: #E2DACA;
  --terra: #C66C4F;
  --terra-deep: #A8553B;
  --sage: #AAB7A2;

  --ink: var(--forest);
  --ink-soft: rgba(24, 40, 36, .74);
  --line: rgba(24, 40, 36, .14);
  --line-light: rgba(245, 241, 232, .16);
  --ivory-soft: rgba(245, 241, 232, .74);

  --font-en: "Manrope", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-ar: "Tajawal", "Manrope", Arial, sans-serif;

  --wrap: 1280px;
  --gutter: clamp(16px, 4vw, 56px);
  --section: clamp(88px, 12vw, 168px);
  --radius: 22px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; }
@supports (overflow: clip) { html, body { overflow-x: clip; } }
body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--font-en);
  font-size: 17px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
html[dir="rtl"] body { font-family: var(--font-ar); font-size: 18px; line-height: 1.6; }
[lang="ar"] { font-family: var(--font-ar); }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
::selection { background: var(--terra); color: var(--ivory); }
:focus-visible { outline: 2px solid var(--terra); outline-offset: 3px; border-radius: 6px; }

/* Subtle paper grain for a printed, premium feel */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 100; opacity: .05;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }
.skip { position: absolute; inset-inline-start: 16px; top: -60px; z-index: 200; background: var(--forest); color: var(--ivory); padding: 10px 16px; border-radius: 10px; }
.skip:focus { top: 12px; }

/* Mark colours */
.m-dot { fill: var(--c-dot, #C66C4F); }
.m-sage { fill: var(--c-sage, #AAB7A2); }
.m-main { fill: var(--c-main, #182824); }
.f-terra { fill: var(--terra); }
.f-sage { fill: var(--sage); }
.section--forest, .logo--light, .case--next, .footer, body.menu-open .nav { --c-main: #F5F1E8; }

/* ---------- Type ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px; margin: 0 0 28px;
  font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
}
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--terra); flex: none; }
.eyebrow--light { color: var(--ivory); }
html[dir="rtl"] .eyebrow { letter-spacing: 0; font-size: 15px; }

.display {
  margin: 0; font-weight: 800; letter-spacing: -.035em; line-height: 1.02;
  font-size: clamp(40px, 6.4vw, 92px);
  text-wrap: balance;
}
html[dir="rtl"] .display { letter-spacing: 0; line-height: 1.2; }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--forest); --fg: var(--ivory);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 56px; padding: 0 28px; border-radius: 999px; border: 1px solid transparent;
  background: var(--bg); color: var(--fg); font-weight: 700; font-size: 16px; cursor: pointer;
  overflow: hidden; isolation: isolate; transition: transform .4s var(--ease), color .4s var(--ease), border-color .4s;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--fill, var(--forest-3)); transform: scaleX(0); transform-origin: right;
  transition: transform .55s var(--ease-out);
}
html[dir="rtl"] .btn::before { transform-origin: left; }
.btn:hover::before { transform: scaleX(1); transform-origin: left; }
html[dir="rtl"] .btn:hover::before { transform-origin: right; }
.btn:active { transform: scale(.98); }
.btn--sm { min-height: 44px; padding: 0 20px; font-size: 15px; }
.btn--full { width: 100%; }
.btn--terra { --bg: var(--terra-deep); --fg: var(--ivory); --fill: var(--forest); }
.section--forest .btn--terra { --fill: var(--ivory); }
.section--forest .btn--terra:hover { color: var(--forest); }
.btn--forest { --bg: var(--forest); --fg: var(--ivory); --fill: var(--terra); }
.btn--forest:hover { color: var(--forest); }
.btn--ivory { --bg: var(--ivory); --fg: var(--forest); --fill: var(--terra); }
.btn--ghost { --bg: transparent; --fg: var(--forest); --fill: var(--forest); border-color: var(--line); }
.btn--ghost:hover { color: var(--ivory); border-color: var(--forest); }
.arrow { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .4s var(--ease); }
.btn:hover .arrow { transform: translateX(4px); }
html[dir="rtl"] .arrow { transform: scaleX(-1); }
html[dir="rtl"] .btn:hover .arrow { transform: scaleX(-1) translateX(4px); }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; gap: 12px; color: var(--forest); direction: ltr; }
.logo__mark { width: 40px; height: 30px; }
.logo__en { font-family: var(--font-en); font-weight: 800; font-size: 22px; letter-spacing: .02em; }
.logo__bar { width: 1px; height: 22px; background: currentColor; opacity: .5; }
.logo__ar { font-family: var(--font-ar); font-weight: 800; font-size: 24px; line-height: 1; transform: translateY(-2px); }
.logo--light { color: var(--ivory); }
.logo--lg .logo__mark { width: 72px; height: 54px; }
.logo--lg .logo__en { font-size: clamp(36px, 5vw, 56px); }
.logo--lg .logo__ar { font-size: clamp(38px, 5.2vw, 60px); }
.logo--lg .logo__bar { height: clamp(30px, 4vw, 48px); }

/* ---------- Nav ---------- */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; transition: background .4s, box-shadow .4s, transform .5s var(--ease); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 84px; }
.nav.is-scrolled { background: rgba(245, 241, 232, .82); backdrop-filter: blur(16px) saturate(1.2); -webkit-backdrop-filter: blur(16px) saturate(1.2); box-shadow: 0 1px 0 var(--line); }
.nav.is-scrolled .nav__inner { height: 72px; }
.nav.is-hidden { transform: translateY(-100%); }
.nav__links { display: flex; gap: 6px; }
.nav__links a { position: relative; padding: 10px 14px; font-weight: 600; font-size: 15px; border-radius: 999px; transition: background .3s; }
.nav__links a:hover { background: rgba(24, 40, 36, .06); }
.nav__links a.is-active::after { content: ""; position: absolute; left: 50%; bottom: 2px; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--terra); }
.nav__actions { display: flex; align-items: center; gap: 10px; }
.lang { min-width: 44px; min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: transparent; cursor: pointer; font-weight: 700; font-size: 15px; transition: background .3s, border-color .3s; }
.lang:hover { background: var(--forest); color: var(--ivory); border-color: var(--forest); }
html:not([dir="rtl"]) .lang { font-family: var(--font-ar); font-size: 16px; }
html[dir="rtl"] .lang { font-family: var(--font-en); }
.burger { display: none; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); background: transparent; cursor: pointer; position: relative; }
.burger span { position: absolute; left: 14px; right: 14px; height: 1.6px; background: currentColor; transition: transform .4s var(--ease), top .4s var(--ease); }
.burger span:nth-child(1) { top: 19px; }
.burger span:nth-child(2) { top: 27px; }
.burger[aria-expanded="true"] span:nth-child(1) { top: 23px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { top: 23px; transform: rotate(-45deg); }

.menu { position: fixed; inset: 0; z-index: 45; background: var(--forest); color: var(--ivory); padding-top: 110px; }
.menu[hidden] { display: none; }
.menu__inner { display: flex; flex-direction: column; gap: 4px; }
.menu__inner a { font-size: clamp(34px, 9vw, 52px); font-weight: 800; letter-spacing: -.02em; padding: 8px 0; border-bottom: 1px solid var(--line-light); }
.menu__inner .menu__cta { color: var(--terra); border: 0; margin-top: 16px; }
body.menu-open { overflow: hidden; }
body.menu-open .nav { background: var(--forest); color: var(--ivory); box-shadow: none; }

body.menu-open .nav .logo { color: var(--ivory); }
body.menu-open .nav .lang, body.menu-open .burger { border-color: var(--line-light); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100svh; display: flex; flex-direction: column; justify-content: center; padding: 130px 0 40px; overflow: hidden; }
.hero::before { /* sage wash, very restrained */
  content: ""; position: absolute; width: 70vw; height: 70vw; max-width: 980px; max-height: 980px; border-radius: 50%;
  inset-inline-end: -18vw; top: 50%; transform: translateY(-50%);
  background: radial-gradient(closest-side, rgba(170, 183, 162, .28), rgba(170, 183, 162, 0));
  pointer-events: none;
}
.hero__grid { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; align-items: center; gap: clamp(24px, 4vw, 64px); }
.hero__title { margin: 0 0 32px; font-weight: 800; font-size: clamp(48px, 8.4vw, 128px); line-height: .98; letter-spacing: -.045em; }
html[dir="rtl"] .hero__title { letter-spacing: 0; line-height: 1.18; font-size: clamp(48px, 8vw, 118px); }
.hero__title .line { display: block; overflow: hidden; padding-bottom: .06em; }
.hero__title .line > span { display: inline-block; transform: translateY(105%); transition: transform 1.2s var(--ease-out); }
.hero__title .line:nth-child(2) > span { transition-delay: .12s; }
.is-loaded .hero__title .line > span { transform: none; }
.hero__title em { font-style: normal; color: var(--terra); }
.hero__lead { max-width: 560px; margin: 0 0 40px; font-size: clamp(17px, 1.4vw, 20px); color: var(--ink-soft); }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 12px; }

.hero__art { position: relative; aspect-ratio: 1; display: grid; place-items: center; }
.orbit { position: absolute; inset: 6%; border: 1px solid var(--line); border-radius: 50%; }
.orbit::before, .orbit::after { content: ""; position: absolute; border-radius: 50%; border: 1px dashed rgba(24, 40, 36, .1); }
.orbit::before { inset: 14%; }
.orbit::after { inset: -9%; border-style: solid; border-color: rgba(24, 40, 36, .06); }
.hero__mark { width: 74%; height: auto; overflow: visible; direction: ltr; transform: translate3d(var(--px, 0), var(--py, 0), 0); transition: transform .9s var(--ease-out); }
/* Motion concept: focus → expand → move forward */
.hero__mark .m-dot, .hero__mark .m-sage, .hero__mark .m-main { transform-box: fill-box; }
.hero__mark .m-dot { transform-origin: center; transform: scale(0); }
.hero__mark .m-sage, .hero__mark .m-main { transform-origin: left center; transform: scaleX(0); }
.is-loaded .hero__mark .m-dot { animation: pop 1s var(--ease-out) .3s forwards; }
.is-loaded .hero__mark .m-sage { animation: grow 1.1s var(--ease-out) .85s forwards; }
.is-loaded .hero__mark .m-main { animation: grow 1.2s var(--ease-out) 1.25s forwards; }
@keyframes pop { 0% { transform: scale(0); } 60% { transform: scale(1.15); } 100% { transform: scale(1); } }
@keyframes grow { to { transform: scaleX(1); } }

.hero__tag {
  position: absolute; display: inline-flex; align-items: center; gap: 8px; padding: 10px 16px; border-radius: 999px;
  background: rgba(245, 241, 232, .9); border: 1px solid var(--line); font-size: 13px; font-weight: 700; letter-spacing: .04em;
  box-shadow: 0 20px 40px -24px rgba(24, 40, 36, .4); opacity: 0; transform: translateY(12px);
  transition: opacity .8s var(--ease-out), transform .8s var(--ease-out);
}
.is-loaded .hero__tag { opacity: 1; transform: none; }
.hero__tag--1 { top: 12%; inset-inline-start: 0; transition-delay: 1.6s; }
.hero__tag--2 { bottom: 16%; inset-inline-start: 8%; transition-delay: 1.8s; }
.hero__tag--3 { top: 24%; inset-inline-end: -2%; transition-delay: 2s; }
.dot { width: 9px; height: 9px; border-radius: 50%; flex: none; }
.dot--terra { background: var(--terra); } .dot--sage { background: var(--sage); } .dot--forest { background: var(--forest); }

.hero__foot { position: relative; display: flex; align-items: center; justify-content: space-between; margin-top: clamp(40px, 6vw, 72px); }
.pager { display: flex; gap: 8px; }
.pager i { width: 28px; height: 2px; background: var(--line); }
.pager i.on { background: var(--terra); }
.scroll { display: inline-flex; align-items: center; gap: 14px; font-size: 13px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; min-height: 44px; }
html[dir="rtl"] .scroll { letter-spacing: 0; }
.scroll__line { width: 56px; height: 1px; background: var(--forest); position: relative; overflow: hidden; }
.scroll__line::after { content: ""; position: absolute; inset: 0; background: var(--terra); animation: slide 2.2s var(--ease) infinite; }
@keyframes slide { 0% { transform: translateX(-100%); } 60%, 100% { transform: translateX(100%); } }

/* ---------- Marquee ---------- */
.marquee { background: var(--forest); color: var(--ivory); overflow: hidden; padding: 26px 0; direction: ltr; }
.marquee__track { display: flex; align-items: center; gap: 36px; width: max-content; animation: marquee 48s linear infinite; }
.marquee__track span { font-size: clamp(22px, 2.6vw, 34px); font-weight: 700; letter-spacing: -.01em; white-space: nowrap; }
.marquee__track i { width: 12px; height: 12px; border-radius: 50%; background: var(--terra); flex: none; }
.marquee__track i:nth-of-type(3n+2) { background: var(--sage); }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { position: relative; padding: var(--section) 0; }
.section--forest { background: var(--forest); color: var(--ivory); }
.section--ivory2 { background: var(--ivory-2); }
.head { display: grid; gap: 0; margin-bottom: clamp(48px, 7vw, 96px); max-width: 980px; }
.head__lead { max-width: 520px; margin: 28px 0 0; font-size: 18px; color: var(--ink-soft); }
.section--forest .head__lead, .section--forest p { color: var(--ivory-soft); }
.head--row { max-width: none; grid-template-columns: 1fr auto; align-items: end; gap: 40px; }
.head--row .head__lead { margin: 0; }

/* Manifesto */
.manifesto__grid { display: grid; grid-template-columns: 220px 1fr; gap: 40px; }
.manifesto__text { max-width: 760px; margin: 40px 0 0; font-size: clamp(19px, 1.8vw, 24px); line-height: 1.5; color: var(--ink-soft); }
.manifesto__text strong { color: var(--terra-deep); font-weight: 800; }
.pillars { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: clamp(64px, 9vw, 120px); border-top: 1px solid var(--line); }
.pillar { padding: 32px 28px 8px 0; border-inline-end: 1px solid var(--line); }
.pillar:last-child { border-inline-end: 0; }
.pillar + .pillar { padding-inline-start: 28px; }
.pillar__k { display: block; margin-bottom: 14px; font-size: 13px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--terra-deep); }
html[dir="rtl"] .pillar__k { letter-spacing: 0; font-size: 15px; }
.pillar p { margin: 0; font-size: 18px; line-height: 1.45; }

/* Solutions */
.solutions::before { content: ""; position: absolute; inset-inline-end: 0; top: 0; width: 40vw; height: 40vw; max-width: 560px; max-height: 560px; border-radius: 0 0 0 100%; background: var(--forest-2); pointer-events: none; }
html[dir="rtl"] .solutions::before { border-radius: 0 0 100% 0; }
.solutions .wrap { position: relative; }
.svc { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-light); }
.svc__item { border-bottom: 1px solid var(--line-light); }
.svc__row {
  width: 100%; display: grid; grid-template-columns: 72px 1fr auto 48px; align-items: center; gap: 16px;
  padding: clamp(22px, 3vw, 36px) 0; background: none; border: 0; cursor: pointer; text-align: start; color: var(--ivory);
}
.svc__n { font-size: 14px; font-weight: 700; color: var(--sage); font-variant-numeric: tabular-nums; }
.svc__t { font-size: clamp(26px, 3.6vw, 52px); font-weight: 700; letter-spacing: -.03em; line-height: 1.1; transition: transform .5s var(--ease-out), color .3s; }
html[dir="rtl"] .svc__t { letter-spacing: 0; }
.svc__row:hover .svc__t { transform: translateX(12px); }
html[dir="rtl"] .svc__row:hover .svc__t { transform: translateX(-12px); }
.svc__tag { padding: 6px 14px; border-radius: 999px; background: var(--sage); color: var(--forest); font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.svc__plus { position: relative; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line-light); transition: background .4s, border-color .4s, transform .5s var(--ease-out); }
.svc__plus::before, .svc__plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 16px; height: 1.6px; margin: -.8px 0 0 -8px; background: var(--ivory); transition: transform .5s var(--ease-out); }
.svc__plus::after { transform: rotate(90deg); }
.svc__row[aria-expanded="true"] .svc__plus { background: var(--terra); border-color: var(--terra); transform: rotate(180deg); }
.svc__row[aria-expanded="true"] .svc__plus::before, .svc__row[aria-expanded="true"] .svc__plus::after { background: var(--forest); }
.svc__row[aria-expanded="true"] .svc__plus::after { transform: rotate(0); }
.svc__body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .6s var(--ease-out); }
.svc__body > * { min-height: 0; overflow: hidden; }
.svc__row[aria-expanded="true"] + .svc__body { grid-template-rows: 1fr; }
.svc__body p { max-width: 640px; margin: 0 0 0 88px; font-size: 18px; }
html[dir="rtl"] .svc__body p { margin: 0 88px 0 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 22px 0 36px; margin: 0 0 0 88px; }
html[dir="rtl"] .chips { margin: 0 88px 0 0; }
.chips li { padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line-light); font-size: 14px; font-weight: 600; color: var(--ivory); }

/* AI */
.ai__grid { display: grid; grid-template-columns: 1fr 420px; gap: clamp(48px, 8vw, 120px); align-items: center; }
.ai__copy > p { max-width: 540px; margin: 32px 0 0; font-size: 18px; color: var(--ink-soft); }
.ticks { list-style: none; padding: 0; margin: 48px 0 0; display: grid; gap: 28px; }
.ticks li { display: grid; grid-template-columns: 40px 1fr; gap: 16px; }
.ticks strong { display: block; font-size: 19px; margin-bottom: 4px; }
.ticks span:not(.tick) { color: var(--ink-soft); }
.tick { width: 40px; height: 40px; border-radius: 50%; background: var(--forest); position: relative; }
.tick::after { content: ""; position: absolute; left: 14px; top: 12px; width: 12px; height: 7px; border-left: 2px solid var(--ivory); border-bottom: 2px solid var(--ivory); transform: rotate(-45deg); }

.phone {
  position: relative; width: 100%; max-width: 380px; margin-inline: auto; aspect-ratio: 9 / 18.5; padding: 14px; border-radius: 52px;
  background: var(--forest); box-shadow: 0 60px 100px -40px rgba(24, 40, 36, .55), inset 0 0 0 2px var(--forest-3);
}
.phone::before { content: ""; position: absolute; width: 240px; height: 240px; border-radius: 50%; background: var(--terra); inset-inline-start: -110px; bottom: 60px; z-index: -1; }
.phone::after { content: ""; position: absolute; width: 160px; height: 320px; border-radius: 0 320px 320px 0; background: var(--sage); inset-inline-end: -70px; top: 40px; z-index: -1; }
.phone__notch { position: absolute; left: 50%; top: 24px; width: 96px; height: 26px; margin-left: -48px; border-radius: 20px; background: #0d1714; z-index: 2; }
.phone__bar { display: flex; align-items: center; gap: 12px; height: 104px; padding: 46px 20px 12px; border-radius: 40px 40px 0 0; background: var(--forest-2); color: var(--ivory); }
.phone__avatar { width: 40px; height: 40px; padding: 8px; border-radius: 50%; background: var(--ivory); }
.phone__avatar { --c-main: #182824; }
.phone__bar strong { display: block; font-size: 15px; }
.phone__bar small { font-size: 12px; color: var(--sage); }
.chat { height: calc(100% - 104px); padding: 18px 14px; border-radius: 0 0 40px 40px; background: var(--ivory); display: flex; flex-direction: column; gap: 10px; overflow: hidden; }
.msg { max-width: 82%; padding: 10px 14px; border-radius: 18px; font-size: 14px; line-height: 1.4; opacity: 0; transform: translateY(10px) scale(.98); transition: opacity .5s var(--ease-out), transform .5s var(--ease-out); }
.msg.show { opacity: 1; transform: none; }
.msg--in { align-self: flex-start; background: #fff; border-end-start-radius: 6px; box-shadow: 0 1px 0 var(--line); }
.msg--out { align-self: flex-end; background: var(--forest); color: var(--ivory); border-end-end-radius: 6px; }
.msg--card { display: flex; gap: 10px; align-items: center; padding: 8px; }
.msg__img { width: 52px; height: 52px; flex: none; border-radius: 12px; background: linear-gradient(135deg, var(--ivory-3), var(--ivory) 60%, var(--sage)); }
.msg--card strong { display: block; font-size: 13px; }
.msg--card small { font-size: 12px; color: var(--sage); }
.typing { align-self: flex-end; display: flex; gap: 4px; padding: 12px 14px; border-radius: 18px; background: var(--forest); opacity: 0; transition: opacity .3s; }
.typing.show { opacity: 1; }
.typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--sage); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 60%, 100% { opacity: .3; } 30% { opacity: 1; } }

/* Approach */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step { position: relative; padding: 36px 32px 40px; border-radius: var(--radius); background: var(--ivory); border: 1px solid var(--line); transition: transform .6s var(--ease-out), box-shadow .6s var(--ease-out); }
.step:hover { transform: translateY(-6px); box-shadow: 0 40px 60px -40px rgba(24, 40, 36, .35); }
.step__ico { height: 92px; margin-bottom: 40px; }
.step__ico svg { height: 100%; width: auto; direction: ltr; }
.step__n { position: absolute; top: 36px; inset-inline-end: 32px; font-size: 14px; font-weight: 700; color: var(--ink-soft); }
.step h3 { margin: 0 0 12px; font-size: 30px; font-weight: 800; letter-spacing: -.02em; }
.step p { margin: 0; color: var(--ink-soft); }

/* Work */
.work__grid { display: grid; grid-template-columns: 1.55fr 1fr; gap: 20px; }
.case { border-radius: var(--radius); overflow: hidden; background: var(--ivory-2); border: 1px solid var(--line); display: flex; flex-direction: column; }
.case__visual { position: relative; padding: clamp(28px, 5vw, 56px) clamp(28px, 5vw, 56px) 0; background: var(--sage); height: clamp(300px, 34vw, 440px); overflow: hidden; }
.case__visual::before { content: ""; position: absolute; width: 320px; height: 320px; border-radius: 50%; background: var(--terra); inset-inline-end: -80px; top: -120px; opacity: .9; }
.browser { position: relative; border-radius: 14px 14px 0 0; background: var(--ivory); box-shadow: 0 40px 80px -30px rgba(24, 40, 36, .5); transform: translateY(12px); transition: transform .8s var(--ease-out); }
.case:hover .browser { transform: translateY(0); }
.browser__bar { display: flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-bottom: 1px solid var(--line); direction: ltr; }
.browser__bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--ivory-3); }
.browser__bar span { margin-left: 12px; font-size: 12px; color: var(--ink-soft); }
.browser__body { padding: 22px; }
.b-hero { display: grid; gap: 10px; padding: 26px; border-radius: 10px; background: var(--forest); margin-bottom: 14px; }
.b-hero span { height: 12px; width: 60%; border-radius: 4px; background: rgba(245, 241, 232, .85); }
.b-hero span:nth-child(2) { width: 40%; opacity: .5; }
.b-hero .b-btn { width: 90px; height: 24px; border-radius: 99px; background: var(--terra); margin-top: 6px; }
.b-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.b-grid i { aspect-ratio: 1; border-radius: 8px; background: var(--ivory-2); }
.case__wa { position: absolute; bottom: 28px; inset-inline-end: 28px; display: inline-flex; gap: 8px; align-items: center; padding: 10px 16px; border-radius: 999px; background: var(--forest); color: var(--ivory); font-size: 13px; font-weight: 700; box-shadow: 0 20px 40px -20px rgba(0,0,0,.5); }
.case__meta { padding: 32px clamp(28px, 4vw, 44px) 40px; }
.case__cat { font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-soft); }
html[dir="rtl"] .case__cat { letter-spacing: 0; }
.case h3 { margin: 10px 0 12px; font-size: clamp(28px, 3vw, 40px); font-weight: 800; letter-spacing: -.02em; }
.case__meta p { margin: 0; max-width: 620px; color: var(--ink-soft); }
.case--next { background: var(--forest); color: var(--ivory); border: 0; }
.case__next { display: flex; flex-direction: column; align-items: flex-start; height: 100%; padding: clamp(32px, 4vw, 48px); }
.case__next > svg { width: 96px; height: 72px; margin-bottom: auto; direction: ltr; }
.case__next h3 { margin: 64px 0 16px; font-size: clamp(32px, 3.6vw, 48px); line-height: 1.05; }
.case__next p { margin: 0 0 32px; color: var(--ivory-soft); }

/* Why */
.why__grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line-light); }
.why__item { padding: 40px 28px 0 0; }
.why__item + .why__item { padding-inline-start: 28px; border-inline-start: 1px solid var(--line-light); }
.why__big { display: block; font-size: clamp(54px, 6.4vw, 96px); font-weight: 800; letter-spacing: -.05em; line-height: 1; margin-bottom: 20px; color: var(--ivory); direction: ltr; }
html[dir="rtl"] .why__big { text-align: right; }
.why__item:nth-child(2) .why__big { color: var(--sage); }
.why__item:nth-child(3) .why__big { color: var(--terra); }
.why__item p { margin: 0; font-size: 17px; }

/* FAQ */
.faq__grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: clamp(40px, 6vw, 96px); }
.faq__list { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { position: relative; list-style: none; cursor: pointer; padding: 28px 56px 28px 0; font-size: clamp(19px, 1.8vw, 23px); font-weight: 700; letter-spacing: -.01em; min-height: 44px; }
html[dir="rtl"] .faq summary { padding: 28px 0 28px 56px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; inset-inline-end: 8px; top: 50%; width: 12px; height: 12px; margin-top: -9px; border-right: 2px solid var(--forest); border-bottom: 2px solid var(--forest); transform: rotate(45deg); transition: transform .4s var(--ease-out); }
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; border-color: var(--terra); }
.faq details p { margin: 0 0 28px; max-width: 640px; color: var(--ink-soft); }

/* Contact */
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(48px, 7vw, 112px); align-items: start; }
.contact__copy > p { max-width: 460px; margin: 28px 0 0; font-size: 18px; }
.contact__direct { display: grid; gap: 12px; margin-top: 48px; max-width: 420px; }
.direct { display: flex; align-items: center; gap: 16px; padding: 18px 22px; border-radius: 18px; border: 1px solid var(--line-light); transition: background .3s, border-color .3s; }
.direct:hover { background: var(--forest-2); border-color: var(--sage); }
.direct svg { width: 26px; height: 26px; fill: var(--terra); color: var(--terra); flex: none; }
.direct small { display: block; font-size: 13px; color: var(--sage); }
.direct strong { font-size: 18px; direction: ltr; unicode-bidi: isolate; }

.form { padding: clamp(28px, 4vw, 48px); border-radius: 28px; background: var(--ivory); color: var(--forest); }
.field { display: grid; gap: 8px; margin: 0 0 22px; padding: 0; border: 0; min-width: 0; }
.field__row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label, .field legend { font-size: 15px; font-weight: 700; padding: 0; }
.opt { font-weight: 500; color: var(--ink-soft); }
.field input, .field textarea {
  width: 100%; min-height: 52px; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--ivory-3);
  background: #fff; color: var(--forest); font: inherit; font-size: 16px; transition: border-color .25s, box-shadow .25s;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--forest); box-shadow: 0 0 0 4px rgba(170, 183, 162, .45); }
.field__err { display: none; margin: 0; font-size: 14px; font-weight: 600; color: #9B3A22; }
.field.invalid input, .field.invalid textarea { border-color: #9B3A22; }
.field.invalid .field__err { display: block; }
.pick { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.pick label { position: relative; cursor: pointer; }
.pick input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.pick span { display: inline-flex; align-items: center; min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--ivory-3); background: #fff; font-size: 15px; font-weight: 600; transition: background .25s, color .25s, border-color .25s; }
.pick input:checked + span { background: var(--forest); color: var(--ivory); border-color: var(--forest); }
.pick input:focus-visible + span { outline: 2px solid var(--terra); outline-offset: 2px; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.form__status { margin: 16px 0 0; font-weight: 600; min-height: 1.5em; }
.form__status.ok { color: var(--forest); }
.form__status.err { color: #9B3A22; }
.form.is-sending button[type="submit"] { opacity: .7; pointer-events: none; }

/* Footer */
.footer { background: var(--forest); color: var(--ivory); padding: clamp(64px, 8vw, 112px) 0 32px; border-top: 1px solid var(--line-light); }
.footer__top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 32px; padding-bottom: 56px; border-bottom: 1px solid var(--line-light); }
.footer__tag { margin: 0; font-size: 18px; color: var(--ivory-soft); text-align: end; }
.footer__tag [lang="ar"] { font-size: 22px; font-weight: 700; color: var(--ivory); }
.footer__cols { display: grid; grid-template-columns: repeat(3, minmax(0, 220px)); gap: 32px; padding: 48px 0; }
.footer h4 { margin: 0 0 16px; font-size: 13px; letter-spacing: .16em; text-transform: uppercase; color: var(--sage); }
html[dir="rtl"] .footer h4 { letter-spacing: 0; font-size: 15px; }
.footer__cols a { display: block; padding: 8px 0; color: var(--ivory-soft); transition: color .3s; }
.footer__cols a:hover { color: var(--ivory); }
.footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding-top: 28px; border-top: 1px solid var(--line-light); font-size: 14px; color: var(--ivory-soft); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease-out), transform 1s var(--ease-out); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }
.no-js .reveal { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav__links { display: none; }
  .burger { display: inline-block; }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__art { max-width: 520px; width: 100%; margin-inline: auto; order: -1; }
  .hero { padding-top: 104px; }
  .ai__grid { grid-template-columns: 1fr; }
  .pillars, .why__grid { grid-template-columns: 1fr 1fr; }
  .pillar:nth-child(2) { border-inline-end: 0; }
  .pillar:nth-child(3) { padding-inline-start: 0; }
  .pillar:nth-child(n+3), .why__item:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: 24px; }
  .why__item:nth-child(n+3) { border-color: var(--line-light); padding-bottom: 0; }
  .why__item:nth-child(3) { padding-inline-start: 0; border-inline-start: 0; }
  .why__item { padding-bottom: 24px; }
  .contact__grid, .faq__grid, .work__grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .manifesto__grid { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 680px) {
  body { font-size: 16px; }
  .nav__cta { display: none; }
  .nav__inner { height: 72px; }
  .logo__mark { width: 34px; height: 26px; }
  .logo__en { font-size: 19px; }
  .logo__ar { font-size: 21px; }
  .hero__art { max-width: 360px; }
  .hero__tag { font-size: 12px; padding: 8px 12px; }
  .hero__tag--3 { inset-inline-end: 0; }
  .hero__ctas .btn { flex: 1 1 100%; }
  .head--row { grid-template-columns: 1fr; gap: 24px; }
  .pillars, .why__grid { grid-template-columns: 1fr; }
  .pillar, .pillar + .pillar { padding: 24px 0; border-inline-end: 0; border-bottom: 1px solid var(--line); margin: 0; border-top: 0; }
  .why__item, .why__item + .why__item { padding: 32px 0; border-inline-start: 0; border-top: 0; border-bottom: 1px solid var(--line-light); margin: 0; }
  .svc__row { grid-template-columns: 40px 1fr 44px; }
  .svc__tag { display: none; }
  .svc__plus { width: 44px; height: 44px; }
  .svc__body p, .chips { margin-inline: 0 !important; }
  .field__row { grid-template-columns: 1fr; gap: 0; }
  .phone { max-width: 330px; }
  .phone::before { width: 180px; height: 180px; inset-inline-start: -60px; }
  .phone::after { inset-inline-end: -40px; }
  .footer__tag { text-align: start; }
  .footer__cols { grid-template-columns: 1fr 1fr; }
  .case__wa { inset-inline-end: 16px; bottom: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0s !important; }
  .marquee__track { animation: none; }
  .hero__mark .m-dot, .hero__mark .m-sage, .hero__mark .m-main, .hero__title .line > span { transform: none !important; animation: none !important; }
  .reveal, .hero__tag, .msg, .typing { opacity: 1; transform: none; }
}
