:root {
--red: #D81316;
--red-deep: #A11F1D;
--yellow: #FDBC07;
--asphalt: #0A0F15;
--track: #625D5E;
--paper: #F1EEEB;
}

* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 5rem; }
body {
font-family: "Cairo", Tahoma, Arial, sans-serif;
background: var(--paper);
color: var(--asphalt);
line-height: 1.8;
}
.wrap { max-width: 960px; margin: 0 auto; padding: 0 1.25rem; }

a:focus-visible, button:focus-visible { outline: 3px solid var(--red-deep); outline-offset: 3px; }
::selection { background: var(--yellow); color: var(--asphalt); }

/* header — Rhythm polish (live v1, snug baked) */
.site-header {
position: sticky; top: 0; z-index: 10;
background: var(--asphalt); color: var(--paper);
}
.site-header .wrap {
display: flex; flex-wrap: wrap; align-items: center;
gap: .5rem 2rem; padding: 1.1rem 1.25rem;
}
.brand { display: inline-flex; flex: none; }
.brand img { display: block; height: 28px; width: auto; }
.site-nav { display: flex; flex-wrap: wrap; gap: 0 1.5rem; }
.site-nav a, .social a, .lang-switch { color: var(--paper); text-decoration: none; }
.site-nav a, .lang-switch { font-weight: 600; }
.site-nav a { font-size: .98rem; }
.lang-switch:hover, .site-nav a:hover, .social a:hover { color: var(--yellow); }
.header-end { display: flex; align-items: center; margin-inline-start: auto; }
.site-header .btn { flex: none; }
.site-header a:focus-visible, .menu-toggle:focus-visible { outline-color: var(--yellow); }
.menu-toggle { display: none; }
.menu-toggle .ri-close-line { display: none; }
@media (max-width: 47.99rem) {
.header-end { order: 3; gap: .75rem; }
.menu-toggle { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; background: transparent; color: var(--paper); border: 0; font: inherit; font-size: 1.5rem; line-height: 1; cursor: pointer; }
.site-header .lang-switch { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; }
.site-header .site-nav, .site-header .btn { display: none; }
.site-header.menu-open .site-nav { display: flex; flex-direction: column; gap: .25rem; flex: 1 1 100%; order: 4; padding-top: .75rem; }
.site-header.menu-open .site-nav a { display: flex; align-items: center; min-height: 44px; padding: .5rem 0; }
.site-header.menu-open .btn { display: inline-flex; justify-content: center; flex: 1 1 100%; order: 5; min-height: 44px; padding: .75rem 1.4rem; }
.site-header.menu-open .menu-toggle .ri-menu-line { display: none; }
.site-header.menu-open .menu-toggle .ri-close-line { display: inline; }
}

/* buttons */
.btn {
display: inline-flex; align-items: center; gap: .6rem; padding: .5rem 1.4rem;
background: var(--red); color: #fff; text-decoration: none;
font: inherit; font-weight: 700; border: 0; border-radius: 4px; cursor: pointer;
}
.btn:hover { background: var(--red-deep); }
.btn i { font-size: 1.15em; line-height: 1; font-style: normal; transition: transform .35s cubic-bezier(.16,1,.3,1); }
.btn:hover i { transform: translateX(4px); }
html[dir="rtl"] .btn i { transform: scaleX(-1); }
html[dir="rtl"] .btn:hover i { transform: scaleX(-1) translateX(4px); }

/* hero: the racing-red/asphalt treatment starts here — Pulse (live overdrive v3, speed 0.4 baked) */
.hero { background: var(--asphalt); color: var(--paper); padding: 6rem 0 7rem; position: relative; }
.hero .wrap { padding-block: 0; }
.hero h1 {
font-size: clamp(2.4rem, 6vw, 4rem); line-height: 1.1; font-weight: 800; letter-spacing: -.02em;
max-width: 18ch; overflow-wrap: anywhere;
animation: hero-in .9s cubic-bezier(.16,1,.3,1) both;
}
/* 18ch of Cairo Arabic is much narrower than 18ch of the Latin face. */
html[lang="en"] .hero h1 { max-width: 24ch; }
.tagline {
display: flex; align-items: center; gap: .6rem;
margin-top: 1.6rem; font-size: .85rem; letter-spacing: .16em;
font-variant-caps: small-caps; font-weight: 700;
animation: hero-in .9s .12s cubic-bezier(.16,1,.3,1) both;
}
.checker {
display: inline-block; vertical-align: middle; flex: none;
width: 1.4rem; height: 1.4rem; margin-inline-end: .6rem;
background:
    conic-gradient(var(--red) 25%, transparent 0 50%, var(--red) 0 75%, transparent 0)
    0 0 / .7rem .7rem;
animation: hero-checker-spin 1.8s linear infinite;
}
.hero .lede {
margin-top: 1.2rem; font-size: 1.05rem; line-height: 1.8;
color: var(--paper); opacity: .8; max-width: 52ch;
animation: hero-in .9s .24s cubic-bezier(.16,1,.3,1) both;
}
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.5rem; margin-top: 2rem;
animation: hero-in .9s .36s cubic-bezier(.16,1,.3,1) both; }
.hero .btn { display: inline-flex; gap: .6rem; align-items: center; padding: .75rem 1.9rem; font-weight: 800;
transition: transform .35s cubic-bezier(.16,1,.3,1), background .25s; }
.hero .btn:hover { transform: translateY(-2px); }
.hero .quiet { color: var(--paper); font-size: .95rem; text-underline-offset: .2em; }
.hero .quiet:hover { color: var(--yellow); }
.hero a:focus-visible { outline-color: var(--yellow); }
/* checkered finish line; paper squares because the backdrop is asphalt — animated */
.flag {
position: absolute; left: 0; right: 0; bottom: 0; height: 32px;
background:
    conic-gradient(var(--paper) 25%, transparent 0 50%, var(--paper) 0 75%, transparent 0)
    0 0 / 32px 32px;
animation: hero-flag 3.6s linear infinite;
}
@keyframes hero-in { from { opacity: 0; transform: translateY(14px); filter: blur(6px); } to { opacity: 1; transform: none; filter: none; } }
@keyframes hero-flag { to { background-position: 32px 0; } }
@keyframes hero-checker-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
.hero h1, .tagline, .hero .lede, .hero-actions, .checker, .flag { animation: none; }
.hero .btn, .btn i { transition: none; }
}

section { padding: 3.5rem 0; }
/* one family, three roles: section head at 2.6rem, subhead at 1.2rem, body
   at 1rem. Supporting copy is set by tone, not by shrinking below 1rem. */
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }
h2 { font-size: clamp(2rem, 4vw, 2.6rem); line-height: 1.25; margin-bottom: 2.25rem; }
h3 { font-size: 1.2rem; line-height: 1.3; }

/* pit stop: the one section that plays the metaphor literally, so it takes the
   asphalt surface. Four numbered stations read as a sequence; the number is the
   loudest element and the rules stop the columns from becoming cards again. */
.pit-stop { background: var(--asphalt); color: var(--paper); padding: 4.5rem 0; }
.pit-lede { color: var(--paper); opacity: .8; max-width: 60ch; margin-bottom: 2.5rem; }
.pit-stages {
display: grid; gap: 2.25rem 2.5rem; list-style: none; padding: 0;
counter-reset: stage;
grid-template-columns: 1fr;
}
@media (min-width: 48rem) { .pit-stages { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 64rem) { .pit-stages { grid-template-columns: repeat(4, 1fr); } }
.pit-stages li {
border-top: 1px solid rgba(241, 238, 235, .3);
padding-top: 1.25rem; overflow-wrap: anywhere;
counter-increment: stage;
}
.pit-stages li::before {
content: counter(stage, decimal-leading-zero);
display: block; font-weight: 700; font-size: 2.1rem; line-height: 1;
letter-spacing: .02em; color: var(--red); margin-bottom: .6rem;
}
.pit-stages h3 { margin: 0 0 .5rem; }
.pit-stages p { color: var(--paper); opacity: .75; }

/* contact: the finish line (Flight overdrive v3, speed 0.4 baked). Centered display,
   underline fields with yellow focus, full-width morphing submit, moving flag. */
.contact {
background: var(--asphalt); color: var(--paper);
text-align: center; padding: 6rem 0 5rem; position: relative; overflow: hidden;
color-scheme: dark; caret-color: var(--yellow);
}
.contact h2 { font-size: clamp(2.4rem, 5vw, 3.6rem); line-height: 1.05; letter-spacing: -.02em; font-weight: 800; }
.contact .wrap > p { opacity: .8; margin-bottom: .5rem; max-width: 52ch; margin-inline: auto; line-height: 1.8; }
.contact .mail {
font-size: clamp(1rem, 4.5vw, 1.3rem); font-weight: 700;
color: var(--yellow); direction: ltr; unicode-bidi: embed; overflow-wrap: anywhere;
text-decoration: none;
}
.contact .mail:hover { text-decoration: underline; }
.contact a:focus-visible, .contact button:focus-visible { outline-color: var(--yellow); }
.contact .flag {
position: absolute; left: 0; right: 0; bottom: 0; height: 28px;
background:
    conic-gradient(var(--paper) 25%, transparent 0 50%, var(--paper) 0 75%, transparent 0)
    0 0 / 28px 28px;
animation: contact-flag 3.6s linear infinite;
}
@keyframes contact-flag { to { background-position: 28px 0; } }
@media (prefers-reduced-motion: reduce) {
.contact .flag, .brief-form .btn, .field input, .field textarea { animation: none; transition: none; }
}

/* the brief form is the primary action; the email below it is the secondary route */
.brief-form {
display: grid; gap: 1.25rem; text-align: start;
max-width: 860px; margin: 3rem auto 0;
}
@media (min-width: 48rem) { .brief-form { grid-template-columns: 1fr 1fr; } }
@media (max-width: 47.99rem) { .brief-form .btn { width: 100%; } }
.field { display: grid; gap: .5rem; position: relative; }
.field--wide { grid-column: 1 / -1; }
.field label { font-size: .92rem; font-weight: 700; letter-spacing: .02em; }
.field input, .field textarea {
font: inherit; width: 100%; padding: .85rem .9rem;
color: var(--paper); background: rgba(241, 238, 235, .05);
border: 0; border-bottom: 2px solid rgba(241, 238, 235, .3); border-radius: 0;
transition: border-color .46s, background .3s;
}
.field input::placeholder, .field textarea::placeholder { color: var(--paper); opacity: .55; }
/* keep Chrome's autofill from repainting the dark field light blue */
.field input:-webkit-autofill {
-webkit-text-fill-color: var(--paper);
-webkit-box-shadow: 0 0 0 100px var(--asphalt) inset;
}
.lane { border: 0; padding: 0; margin: 0; min-width: 0; display: grid; gap: .75rem; }
.lane legend { font-size: .92rem; font-weight: 700; letter-spacing: .02em; margin: 0 0 .9rem; }
/* service options as square selectable chips; checked = the signal-yellow fill on asphalt */
.lane-group { display: flex; flex-wrap: wrap; align-items: stretch; gap: .75rem; }
.lane-group label { display: inline-flex; align-items: center; padding: .5rem 1.1rem; border: 0; border-radius: 0; background: rgba(241, 238, 235, .07); font-weight: 600; font-size: 1rem; letter-spacing: .01em; cursor: pointer; user-select: none; transition: background .2s, color .2s; }
.lane-group label:hover { background: rgba(241, 238, 235, .12); color: var(--yellow); }
.lane-group label:has(input:checked) { background: var(--yellow); color: var(--asphalt); }
.lane-group label:has(input:focus-visible) { outline: 3px solid var(--yellow); outline-offset: 2px; }
/* checkboxes are visually hidden but stay keyboard-focusable; the label carries the state */
.lane-group input[type="checkbox"] {
position: absolute; opacity: 0; pointer-events: none;
}
@media (min-width: 48rem) {
.lane-group label { flex: 0 1 auto; white-space: nowrap; }
}
@media (max-width: 47.99rem) {
.lane-group label { flex: 0 0 auto; white-space: nowrap; justify-content: center; padding: .6rem 1.1rem; }
}
.field textarea { resize: vertical; min-height: 120px; }
.field :is(input, textarea):focus { border-bottom-color: var(--yellow); background: rgba(241, 238, 235, .09); }
.field :is(input, textarea):focus-visible { outline: none; border-bottom-color: var(--yellow); }
.field input[type="email"] { direction: ltr; }
.brief-form .btn { width: 100%; padding: 1rem; font-size: 1.1rem; font-weight: 800; display: inline-flex; justify-content: center; gap: .6rem;
transition: transform .42s cubic-bezier(.16,1,.3,1), background .25s; }
.brief-form .btn:hover { transform: translateY(-2px); }
.req { color: var(--red); }
.opt { font-weight: 400; color: var(--paper); opacity: .5; }
/* honeypot: in the DOM for bots, out of sight and out of the tab order for people */
.honeypot { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.form-status { margin-top: .25rem; font-weight: 600; }
.form-status[data-state="success"] { color: var(--paper); }
.form-status[data-state="error"] { color: var(--yellow); }
/* the email is the fallback route, so it only appears when sending failed */
.form-status[data-state="success"] .form-status-mail { display: none; }
.form-status-mail { color: inherit; margin-inline-start: .3em; direction: ltr; unicode-bidi: embed; overflow-wrap: anywhere; }

/* footer */
.site-footer { background: var(--asphalt); color: var(--paper); padding: 0 0 2rem; }
.site-footer .wrap { display: grid; justify-items: center; gap: 1rem; text-align: center; padding-top: 2.5rem; }
.site-footer .brand img { height: 30px; }
.social { display: flex; flex-wrap: wrap; justify-content: center; gap: 0 1.25rem; }
.social a { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; font-size: 1.75rem; line-height: 1; }
.site-footer a:focus-visible { outline-color: var(--yellow); }
.copyright { font-size: .85rem; opacity: .8; }

/* Services accordion (Arabic and English services sections). */
.services .acc { interpolate-size: allow-keywords; }
.services .acc details { border-bottom: 1px solid rgba(10, 15, 21, .18); }
.services .acc summary {
  position: relative;
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  padding: 1.4rem .25rem;
  cursor: pointer;
  list-style: none;
}
.services .acc summary::-webkit-details-marker { display: none; }
.services .acc summary::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: -1px;
  width: 100%;
  height: 3px;
  background: var(--red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s cubic-bezier(.2, .7, .2, 1);
}
.services .acc summary:dir(rtl)::before,
html[dir="rtl"] .services .acc summary::before { transform-origin: 100% 50%; }
.services .acc details[open] summary::before { transform: scaleX(1); }
.services .acc summary:focus-visible {
  outline: 3px solid var(--red-deep);
  outline-offset: -3px;
}
.services .acc .num {
  color: var(--red);
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: .12em;
  min-width: 2.6rem;
  flex: none;
}
.services .acc h3 {
  margin: 0;
  font-size: clamp(1.3rem, 2.4vw, 1.7rem);
  font-weight: 700;
  letter-spacing: -.015em;
}
.services .acc details:not([open]) h3 { opacity: .5; }
.services .acc details:not([open]):hover h3 { opacity: .85; }
.services .acc .chev {
  margin-inline-start: auto;
  color: var(--red);
  font-weight: 700;
  font-size: 1.5rem;
  line-height: 1;
  transition: transform .35s cubic-bezier(.2, .7, .2, 1);
}
.services .acc details[open] .chev { transform: rotate(45deg); }
.services .acc details::details-content {
  height: 0;
  overflow: clip;
  transition: height .35s ease, content-visibility .35s allow-discrete;
}
.services .acc details[open]::details-content { height: auto; }
.services .acc .panel {
  display: grid;
  gap: 1.1rem;
  padding: .25rem .25rem 1.7rem;
  padding-inline-start: 3.85rem;
}
.services .acc .panel p {
  margin: 0;
  color: var(--track);
  line-height: 1.8;
  max-width: 52ch;
}
.services .acc .panel ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: .6rem 2.2rem;
}
.services .acc .panel li {
  font-weight: 600;
  font-size: 1rem;
  color: var(--asphalt);
  display: flex;
  align-items: center;
  gap: .55rem;
}
.services .acc .panel li::before {
  content: "";
  width: .58rem;
  height: .58rem;
  flex: none;
  background: conic-gradient(var(--red) 0 25%, transparent 0 50%, var(--red) 0 75%, transparent 0);
}

/* Team cards: photo-first, grayscale→color reveal. */
.team .crew { display: grid; gap: 1.5rem; }
.team .member {
  background: rgba(216, 19, 16, .06);
  transition: background-color .3s ease;
}
.team .member:hover,
.team .member:focus-within { background: rgba(216, 19, 16, .12); }
.team .photo {
  margin: 0;
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
}
.team .photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: grayscale(.85);
  transition: filter .45s ease, transform .45s cubic-bezier(.2, .7, .2, 1);
}
.team .member:hover .photo img,
.team .member:focus-within .photo img { filter: grayscale(0); transform: scale(1.04); }
.team .crew h3 {
  margin: 1.1rem 1.25rem 0;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -.015em;
}
.team .role {
  margin: .2rem 1.25rem 1.2rem;
  color: var(--track);
  line-height: 1.8;
}
.team .links {
  margin: 0 1.25rem 1.4rem;
  display: flex;
  flex-wrap: wrap;
  gap: .4rem 1.4rem;
}
.team .links a { font-weight: 600; color: var(--asphalt); text-decoration: none; transition: color .2s ease; }
.team .links a:hover { color: var(--red-deep); }
.team .links a:focus-visible { outline: 3px solid var(--red-deep); outline-offset: 2px; }
@media (min-width: 48rem) {
  .team .crew { grid-template-columns: repeat(3, 1fr); }
}

/* 404: the one page where the visitor is off the track, so the pit-lane sign
   carries the number and the copy sends them back to the start. */
.error {
background: var(--asphalt); color: var(--paper);
position: relative; display: grid; align-content: center;
min-height: calc(100svh - 4rem); padding: 5rem 0 8rem;
}
.error .wrap { width: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 2.5rem 3.5rem; }
.error-sign {
flex: none; display: grid; place-items: center;
width: clamp(8.5rem, 24vw, 11rem); aspect-ratio: 1;
border: .55rem solid var(--red); border-radius: 50%;
background: var(--paper); color: var(--asphalt);
font-size: clamp(2.4rem, 7vw, 3.6rem); font-weight: 700; line-height: 1;
letter-spacing: -.02em; transform: rotate(-6deg);
animation: error-sign-in .8s cubic-bezier(.16,1,.3,1) both;
}
.error-body { flex: 1 1 20rem; min-width: 0; }
.error h1 {
font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.2; letter-spacing: -.02em;
max-width: 18ch; overflow-wrap: anywhere;
animation: hero-in .9s .12s cubic-bezier(.16,1,.3,1) both;
}
html[lang="en"] .error h1 { max-width: 24ch; }
.error .lede {
margin-top: 1.1rem; max-width: 46ch; opacity: .8; overflow-wrap: anywhere;
animation: hero-in .9s .24s cubic-bezier(.16,1,.3,1) both;
}
.error-actions {
display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.5rem;
margin-top: 2rem; animation: hero-in .9s .36s cubic-bezier(.16,1,.3,1) both;
}
.error .btn { padding: .75rem 1.9rem; font-weight: 800; }
.error .quiet { color: var(--paper); text-underline-offset: .2em; }
.error .quiet:hover { color: var(--yellow); }
.error a:focus-visible { outline-color: var(--yellow); }
.error .flag {
position: absolute; inset-inline: 0; bottom: 0; height: 28px;
background:
    conic-gradient(var(--paper) 25%, transparent 0 50%, var(--paper) 0 75%, transparent 0)
    0 0 / 28px 28px;
animation: contact-flag 3.6s linear infinite;
}
@keyframes error-sign-in {
from { opacity: 0; transform: rotate(-14deg) translateY(-1.25rem) scale(.9); }
to { opacity: 1; transform: rotate(-6deg); }
}
@media (prefers-reduced-motion: reduce) {
.error-sign, .error h1, .error .lede, .error-actions, .error .flag { animation: none; }
}
