/* Tone — homepage. Brand only: navy #01147A, teal #01FFD5, violet #5D12D2, indigo #6874E8, mist #DADCE2. Font: Cairo Play. */
:root {
	--navy: #01147a;
	--navy-ink: #050b3d;
	--teal: #01ffd5;
	--violet: #5d12d2;
	--indigo: #6874e8;
	--mist: #dadce2;
	--mist-2: #f3f4f8;
	--lav: #eeeffb;
	--ink: #0d1440;
	--muted: #4c5279;
	--line: rgba(1, 20, 122, .1);
	--radius: 20px;
	--wrap: 1240px;
	--ease: cubic-bezier(.22, 1, .36, 1);
	--font: "Cairo Play", "Cairo", system-ui, -apple-system, "Segoe UI", Tahoma, sans-serif;

	/* One type scale for every section */
	--fs-title: clamp(2rem, 3.4vw, 2.9rem);
	--fs-lead: clamp(1.02rem, 1.2vw, 1.14rem);
	--fs-body: 1.06rem;
	--fs-small: .92rem;
	--lh: 1.85;
	--sec-y: clamp(64px, 7.5vw, 104px);
	--head-gap: clamp(28px, 3.4vw, 44px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
	margin: 0; background: #fff; color: var(--ink);
	font-family: var(--font); font-size: 17px; line-height: var(--lh);
	-webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden;
}
img, video, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; border-radius: 6px; }

.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.center { text-align: center; }
.sr-only, .hp { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: fixed; top: -60px; right: 16px; z-index: 100; background: var(--teal); color: var(--navy); padding: 8px 16px; border-radius: 10px; font-weight: 700; }
.skip:focus { top: 12px; }

/* ── Shared section scaffolding ── */
.sec { padding: var(--sec-y) 0; }
.sec-title { margin: 0 0 .45em; color: var(--navy); font-size: var(--fs-title); font-weight: 800; line-height: 1.25; }
.sec-title--light { color: #fff; }
.sec-head { margin-bottom: var(--head-gap); max-width: 720px; }
.sec-head .sec-title { margin-bottom: .3em; }
.sec-head--split { max-width: none; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px 48px; flex-wrap: wrap; }
.sec-head--split > div { max-width: 760px; }
.lead { margin: 0; color: var(--muted); font-size: var(--fs-lead); line-height: 1.8; }

/* ── Buttons ── */
.btn {
	--bg: var(--navy); --fg: #fff;
	display: inline-flex; align-items: center; justify-content: center; gap: 10px;
	min-height: 48px; padding: 10px 26px; border: 0; border-radius: 999px; cursor: pointer;
	background: var(--bg); color: var(--fg); font-weight: 700; font-size: 1rem; line-height: 1; white-space: nowrap;
	transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.btn svg { width: 1.2em; height: 1.2em; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .35s var(--ease); }
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px -12px rgba(1, 20, 122, .45); }
.btn:hover svg { transform: translateX(-4px); }
.btn--teal { --bg: var(--teal); --fg: var(--navy); }
.btn--teal:hover { box-shadow: 0 14px 30px -12px rgba(1, 200, 170, .6); }
.btn--navy { --bg: var(--navy); --fg: #fff; }

/* ── Nav ── */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; padding: 14px 0; transition: background .4s, padding .4s, box-shadow .4s; }
.nav__in { display: flex; align-items: center; gap: 28px; }
.nav__logo img { width: 52px; height: 52px; border-radius: 6px; transition: width .4s, height .4s; }
.nav__links { display: flex; gap: 6px; margin-inline-start: auto; }
.nav__links a { padding: 8px 14px; color: #fff; font-weight: 600; font-size: .98rem; border-radius: 999px; transition: color .25s, background .25s; }
.nav__links a:hover { background: rgba(255, 255, 255, .12); }
.nav__cta { min-height: 42px; padding-inline: 20px; }
.nav__menu-cta { display: none; }
.nav__lang { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .4); color: #fff; font-weight: 700; font-size: .92rem; line-height: 1; transition: background .25s, color .25s, border-color .25s; }
.nav__lang:hover { background: rgba(255, 255, 255, .14); }
.nav__lang svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.nav__lang span { font-family: var(--font); }
.nav__burger { display: none; width: 46px; height: 46px; border: 0; border-radius: 12px; background: rgba(255, 255, 255, .14); cursor: pointer; position: relative; }
.nav__burger span { position: absolute; right: 12px; left: 12px; height: 2px; background: #fff; border-radius: 2px; transition: transform .35s var(--ease), top .35s var(--ease); }
.nav__burger span:first-child { top: 18px; }
.nav__burger span:last-child { top: 26px; }
.nav.is-solid { background: rgba(255, 255, 255, .94); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); box-shadow: 0 1px 0 var(--line); padding: 8px 0; }
.nav.is-solid .nav__logo img { width: 44px; height: 44px; }
.nav.is-solid .nav__links a { color: var(--navy); }
.nav.is-solid .nav__links a:hover { background: var(--lav); }
.nav.is-solid .nav__burger { background: var(--lav); }
.nav.is-solid .nav__lang { color: var(--navy); border-color: rgba(1, 20, 122, .2); }
.nav.is-solid .nav__lang:hover { background: var(--lav); }
.nav.is-solid .nav__burger span { background: var(--navy); }

/* ── Hero: always the video's own ratio, so the button sits exactly under the baked-in headline ── */
.hero { position: relative; aspect-ratio: 1684 / 946; background: var(--navy-ink); overflow: hidden; }
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero__cta {
	position: absolute; top: var(--cta-top, 64%); right: var(--cta-right, 2.6%);
	min-height: 0; padding: .8em 1.7em; font-size: clamp(.78rem, 1.15vw, 1.1rem); gap: .6em;
}

/* ── About ── */
.about__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.about__media { margin: 0; }
.about__media img { width: 100%; max-width: 420px; height: auto; margin-inline: auto; }
.about__copy p { color: var(--muted); font-size: var(--fs-lead); max-width: 56ch; margin-bottom: .8em; }
.about__copy .btn { margin-top: 12px; }

/* ── Stats: light, no boxes ── */
.stats { background: var(--mist-2); }
.stats .sec-title { margin-bottom: var(--head-gap); }
.stats__row { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(var(--n, 5), minmax(0, 1fr)); }
.stat { text-align: center; padding: 6px 12px; }
.stat + .stat { border-inline-start: 1px solid rgba(1, 20, 122, .12); }
.stat__icon { width: 56px; height: 56px; object-fit: contain; margin: 0 auto 12px; }
.stat__num { margin: 0; color: var(--navy); font-size: clamp(2rem, 3.2vw, 2.8rem); font-weight: 800; line-height: 1.15; font-variant-numeric: tabular-nums; }
.stat__pre { color: var(--violet); }
.stat__label { margin: 6px 0 0; color: var(--muted); font-weight: 600; font-size: var(--fs-small); }

/* ── Services ── */
.services__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.svc {
	position: relative; display: block; aspect-ratio: 1.6; overflow: hidden; isolation: isolate; container-type: inline-size;
	border-radius: var(--radius); background: #f2f1fb; box-shadow: 0 1px 0 rgba(1, 20, 122, .06), 0 20px 40px -30px rgba(1, 20, 122, .35);
	transition: transform .5s var(--ease), box-shadow .5s var(--ease);
}
.svc__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: right center; z-index: -1; transition: transform .8s var(--ease); }
.svc__body { position: absolute; inset: 0 51% 0 6%; display: flex; flex-direction: column; justify-content: center; text-align: start; }
.svc__title { color: var(--navy); font-weight: 800; font-size: 6cqi; line-height: 1.25; margin-bottom: 2.2cqi; }
.svc__desc { color: var(--muted); font-size: 3.4cqi; line-height: 1.65; }
.svc:hover { transform: translateY(-6px); box-shadow: 0 30px 50px -28px rgba(93, 18, 210, .4); }
.svc:hover .svc__img { transform: scale(1.04); }
.svc--dark { background: var(--navy); }
.svc--dark .svc__title { color: #fff; }
.svc--dark .svc__desc { color: rgba(255, 255, 255, .8); }
.services__foot { display: flex; align-items: center; gap: 28px; margin-top: var(--head-gap); }
.services__rule { flex: 1; height: 1px; background: rgba(104, 116, 232, .45); }
.services__sig { color: var(--indigo); letter-spacing: .38em; font-size: .78rem; font-weight: 600; white-space: nowrap; }

/* ── Works ── */
.works { background: var(--mist-2); }
.works .sec-head .lead { max-width: 68ch; }
.works__grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-flow: dense; gap: 14px; }
.work {
	position: relative; display: block; width: 100%; padding: 0; border: 0; cursor: pointer; overflow: hidden;
	aspect-ratio: 16 / 9; border-radius: 16px; background: linear-gradient(135deg, var(--navy), var(--violet));
	box-shadow: 0 20px 40px -28px rgba(1, 20, 122, .55); transition: transform .5s var(--ease);
}
.work--v { grid-row: span 2; aspect-ratio: auto; }
.work img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.work::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(5, 11, 61, .82)); }
.work__title { position: absolute; z-index: 1; right: 14px; left: 14px; bottom: 10px; color: #fff; font-weight: 700; font-size: var(--fs-small); line-height: 1.4; text-align: start; }
.work__play { position: absolute; z-index: 1; left: 50%; top: 46%; translate: -50% -50%; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: var(--teal); transition: transform .4s var(--ease); box-shadow: 0 0 0 8px rgba(1, 255, 213, .2); }
.work__play svg { width: 20px; fill: var(--navy); margin-left: 3px; }
.work--v .work__play { width: 64px; height: 64px; }
.work__soon { position: absolute; z-index: 1; top: 12px; right: 12px; padding: 0 10px; border-radius: 999px; background: rgba(255, 255, 255, .18); color: #fff; font-size: .78rem; font-weight: 700; }
.work--soon { cursor: default; }
.work--soon .work__play { opacity: .5; }
.work:not(.work--soon):hover { transform: translateY(-4px); }
.work:not(.work--soon):hover img { transform: scale(1.05); }
.work:not(.work--soon):hover .work__play { transform: scale(1.1); }

/* ── Clients: 3 auto-scrolling rows, identical tiles ── */
.clients .sec-title { margin-bottom: var(--head-gap); }
.marquee { --gap: 14px; --dur: calc(var(--count) * 3.4s); position: relative; overflow: hidden; padding: 6px 0; mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); }
.marquee + .marquee { margin-top: 8px; }
.marquee__track { list-style: none; margin: 0; padding: 0; display: flex; gap: var(--gap); width: max-content; animation: marq var(--dur) linear infinite; }
.marquee[data-dir="b"] .marquee__track { animation-direction: reverse; }
.marquee:hover .marquee__track { animation-play-state: paused; }
/* RTL: the track grows leftwards, so sliding right by half (one copy) loops seamlessly */
@keyframes marq { from { transform: translateX(0); } to { transform: translateX(calc(50% + var(--gap) / 2)); } }
.logo { flex: none; width: 180px; height: 104px; display: grid; place-items: center; padding: 16px 22px; border-radius: 16px; background: #fff; border: 1px solid var(--line); }
.logo img { max-width: 100%; max-height: 64px; width: auto; height: auto; object-fit: contain; user-select: none; }
/* White logos are painted in brand navy so every tile keeps the same white background */
.logo__mask { display: block; width: 100%; height: 64px; background: var(--navy); -webkit-mask-position: center; mask-position: center; -webkit-mask-size: contain; mask-size: contain; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat; }

/* ── Contact (reference layout: centred title, mic behind, form + contact pills) ── */
.contact { position: relative; overflow: hidden; background: var(--navy); color: #fff; isolation: isolate; }
.contact__mic { position: absolute; z-index: -1; left: 50%; top: clamp(40px, 6vw, 80px); translate: -50% 0; height: min(86%, 760px); width: auto; opacity: .55; pointer-events: none; }
.contact .sec-title { margin-bottom: var(--head-gap); }
.contact__grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .8fr); gap: clamp(24px, 4vw, 56px); max-width: 1100px; margin-inline: auto; align-items: start; }
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field[hidden] { display: none; }
.field > span { font-size: var(--fs-small); font-weight: 600; color: #fff; }
.field b { color: var(--teal); font-weight: 700; }
.field input, .field select, .field textarea {
	width: 100%; min-height: 48px; padding: 10px 16px; border-radius: 12px;
	border: 1px solid rgba(255, 255, 255, .55); background: rgba(218, 220, 226, .5); color: var(--navy-ink);
	backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: border-color .2s, box-shadow .2s, background .2s;
}
.field select { appearance: none; -webkit-appearance: none; padding-left: 44px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23050b3d' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-position: left 16px center; background-size: 18px; background-repeat: no-repeat; }
.field textarea { resize: vertical; min-height: 130px; }
.field input::placeholder, .field textarea::placeholder { color: rgba(5, 11, 61, .55); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--teal); background-color: rgba(218, 220, 226, .7); box-shadow: 0 0 0 4px rgba(1, 255, 213, .25); }
.field.is-bad input { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(1, 255, 213, .35); }
.form__foot { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.form__foot .btn { min-width: 140px; border-radius: 12px; }
.form__note { margin: 0; font-weight: 700; font-size: var(--fs-small); }
.form__note.ok { color: var(--teal); }
.form__note.err { color: #fff; }
.form button[disabled] { opacity: .7; cursor: progress; }
.contact__list { list-style: none; margin: 30px 0 0; padding: 0; display: grid; gap: 14px; }
.contact__list a { display: flex; align-items: center; gap: 12px; padding: 18px 22px; border-radius: 14px; background: rgba(218, 220, 226, .28); border: 1px solid rgba(255, 255, 255, .35); font-weight: 600; font-size: 1.05rem; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); transition: background .3s, border-color .3s; }
.contact__list a:hover { background: rgba(218, 220, 226, .38); border-color: var(--teal); }
.contact__list svg { width: 22px; height: 22px; fill: var(--teal); flex: none; }

/* ── Footer ── */
.foot { background: var(--navy-ink); color: rgba(255, 255, 255, .7); padding: 40px 0 28px; }
.foot__in { display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; }
.foot__in img { width: 60px; height: 60px; border-radius: 6px; }
.foot__social { list-style: none; margin: 0; padding: 0; display: flex; gap: 10px; }
.foot__social a { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; background: rgba(255, 255, 255, .08); transition: background .3s, transform .3s var(--ease); }
.foot__social a:hover { background: var(--teal); transform: translateY(-3px); }
.foot__social svg { width: 18px; fill: #fff; }
.foot__social a:hover svg { fill: var(--navy); }
.foot__copy { margin: 0; font-size: .88rem; }
.foot__copy a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }

/* ── WhatsApp float ── */
.wa-float { position: fixed; inset-inline-end: 20px; bottom: 20px; z-index: 40; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #25d366; box-shadow: 0 12px 30px -10px rgba(37, 211, 102, .7); transition: transform .3s var(--ease); }
.wa-float:hover { transform: scale(1.08); }
.wa-float svg { width: 30px; fill: #fff; }

/* ── Lightbox ── */
.lightbox { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 20px; background: rgba(5, 11, 61, .9); backdrop-filter: blur(6px); }
.lightbox[hidden] { display: none; }
.lightbox__frame { width: min(1100px, 100%); aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; background: #000; }
.lightbox__frame.is-v { width: auto; height: min(86vh, 900px); aspect-ratio: 9 / 16; max-width: 100%; }
.lightbox__frame iframe { width: 100%; height: 100%; border: 0; }
.lightbox__close { position: absolute; top: 16px; left: 16px; width: 48px; height: 48px; border: 0; border-radius: 50%; background: #fff; color: var(--navy); font-size: 30px; line-height: 1; cursor: pointer; }

/* ── Reveal ── */
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: var(--d, 0s); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* ── Responsive ── */
@media (max-width: 1100px) {
	.works__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
	.stats__row { grid-template-columns: repeat(3, minmax(0, 1fr)); row-gap: 28px; }
	.stat:nth-child(3n + 1) { border-inline-start: 0; }
}
@media (max-width: 900px) {
	:root { --sec-y: 60px; --head-gap: 26px; }
	.nav { background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.6) blur(14px); -webkit-backdrop-filter: saturate(1.6) blur(14px); box-shadow: 0 1px 0 var(--line); padding: 8px 0; }
	.nav .nav__logo img { width: 44px; height: 44px; }
	.nav__links { position: fixed; inset: 0 0 auto; padding: 84px 20px 24px; flex-direction: column; gap: 2px; background: #fff; box-shadow: 0 30px 60px -30px rgba(1, 20, 122, .4); transform: translateY(-105%); transition: transform .5s var(--ease); z-index: -1; }
	.nav__links a { color: var(--navy); font-size: 1.1rem; padding: 12px 16px; }
	.nav__links .nav__menu-cta { display: flex; margin-top: 10px; color: var(--navy); }
	.nav.is-open .nav__links { transform: none; }
	.nav__burger { display: block; background: var(--lav); }
	.nav__burger span { background: var(--navy); }
	.nav.is-open .nav__burger span:first-child { top: 22px; transform: rotate(45deg); }
	.nav.is-open .nav__burger span:last-child { top: 22px; transform: rotate(-45deg); }
	.nav__lang { margin-inline-start: auto; color: var(--navy); border-color: rgba(1, 20, 122, .2); min-height: 40px; padding: 6px 12px; }
	.nav__cta { min-height: 40px; padding-inline: 16px; font-size: .92rem; }
	.hero { margin-top: 60px; }
	.about__grid { grid-template-columns: 1fr; text-align: center; }
	.about__grid { gap: 20px; }
	.about__media img { max-width: 230px; }
	.about__copy p { margin-inline: auto; }
	.services__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.works__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
	.contact__grid { grid-template-columns: 1fr; }
	.contact__list { margin-top: 4px; }
	.contact__mic { opacity: .35; height: 70%; }
}
@media (max-width: 640px) {
	body { font-size: 16px; }
	:root { --sec-y: 52px; --fs-title: 1.9rem; }
	.nav__cta { display: none; }
	/* Mobile hero: button stays under the headline, scaled for touch */
	.hero__cta { font-size: .74rem; padding: .7em 1.2em; min-height: 32px; gap: .4em; }
	.services__grid { grid-template-columns: 1fr; gap: 12px; }
	.stats__row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.stat { border-inline-start: 0 !important; }
	.stat:last-child:nth-child(odd) { grid-column: span 2; }
	.stat__icon { width: 46px; height: 46px; }
	.sec-head--split { align-items: flex-start; }
	.work__play { width: 40px; height: 40px; box-shadow: 0 0 0 5px rgba(1, 255, 213, .2); }
	.work__play svg { width: 16px; }
	.work__title { font-size: .8rem; right: 10px; left: 10px; bottom: 8px; }
	.logo { width: 140px; height: 84px; padding: 12px 16px; border-radius: 14px; }
	.logo img { max-height: 52px; }
	.logo__mask { height: 52px; }
	.services__foot { flex-direction: column; align-items: stretch; gap: 16px; }
	.services__rule { display: none; }
	.services__sig { text-align: center; }
	.contact__list a { padding: 14px 18px; font-size: 1rem; }
	.form__foot .btn { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
	[data-reveal] { opacity: 1; transform: none; }
	.marquee__track { animation: none; flex-wrap: wrap; width: auto; justify-content: center; }
	.marquee__track [aria-hidden="true"] { display: none; }
}

/* ── English (LTR) ── */
[dir="ltr"] .btn svg { transform: scaleX(-1); }
[dir="ltr"] .btn:hover svg { transform: scaleX(-1) translateX(-4px); }
[dir="ltr"] .field select { padding-left: 16px; padding-right: 44px; background-position: right 16px center; }
/* LTR track grows rightwards: slide left by one copy */
@keyframes marq-ltr { from { transform: translateX(0); } to { transform: translateX(calc(-50% - var(--gap) / 2)); } }
[dir="ltr"] .marquee__track { animation-name: marq-ltr; }
[dir="ltr"] .sec-title, [dir="ltr"] .stat__num { letter-spacing: -.01em; }
[dir="ltr"] .lead, [dir="ltr"] .about__copy p { line-height: 1.7; }
