:root {
  --navy: #102c4c;
  --ink: #152c42;
  --blue: #194d7d;
  --gold: #d7ae60;
  --muted: #516476;
  --line: #dbe3e9;
  --paper: #f3f5f6;
  --white: #fff;
  --radius: 14px;
  --header-height: 76px;
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font: 1rem/1.7 "IBM Plex Sans Arabic", "DM Sans", sans-serif;
}
html[lang="en"] body { font-family: "DM Sans", "IBM Plex Sans Arabic", sans-serif; }
a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid #a76a12; outline-offset: 4px; }
button { font: inherit; }
img { display: block; max-width: 100%; }
figure, h1, h2, h3, h4, p, dd { margin: 0; }
.en, html[lang="en"] .ar { display: none; }
html[lang="en"] .en { display: inline; }

.wrap { width: min(1200px, calc(100% - 64px)); margin-inline: auto; }
.section { padding-block: clamp(52px, 7vw, 96px); }
.section-head { display: flex; gap: 24px; align-items: end; justify-content: space-between; margin-bottom: 32px; }
.section-head > * { min-width: 0; }
h2 { color: var(--navy); font-size: clamp(1.75rem, 4vw, 2.7rem); line-height: 1.22; letter-spacing: -.025em; }
.section-intro { max-width: 52ch; color: var(--muted); }
.kicker { display: block; margin-bottom: 8px; font-size: .875rem; font-weight: 700; color: #795619; }
.kicker::before { content: ""; display: inline-block; background: var(--gold); width: 24px; height: 2px; vertical-align: middle; margin-inline-end: 9px; }

.topbar { position: sticky; top: 0; z-index: 30; background: #fff; border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: var(--header-height); }
.brand { flex-shrink: 0; }
.brand img { width: 165px; height: auto; }
.navlinks { display: flex; align-items: center; gap: clamp(13px, 2vw, 27px); }
.navlinks a { font-weight: 600; font-size: .9375rem; }
.navlinks a:hover, .text-link:hover { color: var(--blue); text-decoration: underline; }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.lang-btn, .menu-btn { cursor: pointer; min-height: 44px; min-width: 44px; padding-inline: 9px; border: 1px solid var(--line); border-radius: 7px; background: white; color: var(--navy); font-size: .875rem; font-weight: 700; }
.menu-btn { display: none; font-size: 1.15rem; }

.actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.btn { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; padding: 9px 16px; border: 1px solid transparent; border-radius: 7px; font-size: .9375rem; font-weight: 700; text-align: center; line-height: 1.35; }
.btn-gold { background: var(--gold); color: #172638; }
.btn-gold:hover { background: #edc67c; }
.btn-dark { background: var(--navy); color: white; }
.btn-dark:hover { background: var(--blue); }
.btn-outline { border-color: #b8c6d2; color: var(--navy); }
.btn-outline:hover { background: var(--paper); }
.btn-glass { border-color: #94a7ba; color: #fff; }
.btn-glass:hover { background: #ffffff1c; }
.text-link { color: var(--navy); font-size: .9375rem; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

.hero { background: #0d283f; color: var(--white); padding-block: clamp(36px, 5.5vw, 76px); }
.hero-grid { display: grid; grid-template-columns: .92fr 1.08fr; gap: clamp(29px, 5vw, 64px); align-items: center; }
.hero .kicker, .contact .kicker { color: #f0c980; }
.hero h1 { max-width: 14ch; font-size: clamp(2.45rem, 5.25vw, 4.55rem); line-height: 1.13; letter-spacing: -.038em; margin-bottom: 20px; text-wrap: balance; }
.hero h1 em { font-style: normal; color: #f0c980; }
.hero p:not(.kicker) { max-width: 52ch; color: #d9e4ed; font-size: clamp(1rem, 1.55vw, 1.16rem); margin-bottom: 27px; }
.hero-image { position: relative; border-radius: var(--radius); overflow: hidden; background: #233a4a; border: 1px solid #ffffff32; }
.hero-image img { width: 100%; height: clamp(350px, 38vw, 550px); object-fit: cover; object-position: 52% center; }
.hero-image figcaption { position: absolute; inset: auto 15px 15px; width: fit-content; border-inline-start: 3px solid var(--gold); border-radius: 4px; background: #081b2edf; padding: 8px 13px; font-size: .875rem; }

.metrics { border-bottom: 1px solid var(--line); }
.metrics-grid { display: grid; grid-template-columns: repeat(3, 1fr); padding-block: 22px; }
.metric { padding-inline: 20px; border-inline-start: 1px solid var(--line); }
.metric:first-child { border: 0; padding-inline-start: 0; }
.metric strong { display: block; color: var(--navy); font-size: clamp(1.35rem, 3vw, 2rem); line-height: 1.2; }
.metric > span { display: block; color: var(--muted); margin-top: 4px; font-size: .875rem; }

.portfolio { background: var(--paper); }
.portfolio-group + .portfolio-group { margin-top: 40px; padding-top: 30px; border-top: 1px solid var(--line); }
.group-title { font-size: clamp(1.25rem, 2.5vw, 1.65rem); color: var(--navy); margin-bottom: 16px; }
.portfolio-grid, .res-grid { display: grid; gap: 20px; }
.portfolio-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.res-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.property { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.property-image { aspect-ratio: 16 / 9; overflow: hidden; background: #d5dfe6; }
.property-image img { width: 100%; height: 100%; object-fit: cover; object-position: center 45%; }
.property-content { flex: 1; padding: clamp(16px, 2.1vw, 24px); display: flex; flex-direction: column; gap: 14px; }
.property h4 { font-size: clamp(1.1rem, 2vw, 1.4rem); line-height: 1.3; color: var(--navy); }
.property-district { color: var(--muted); font-size: .925rem; margin-top: 3px; }
.property-specs { margin: 0; padding-top: 14px; border-top: 1px solid var(--line); display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.property-specs dt { font-size: .875rem; color: var(--muted); }
.property-specs dd { font-size: .975rem; font-weight: 700; }
.property-footer { margin-top: auto; padding-top: 4px; gap: 10px 15px; }

.case-study { border-bottom: 1px solid var(--line); }
.case-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.case-image { overflow: hidden; border-radius: var(--radius); background: var(--paper); }
.case-image img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; }
.case-image figcaption { padding: 8px 14px; color: var(--muted); font-size: .875rem; }
.case-copy p { color: var(--muted); margin-block: 14px 20px; }

.services { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.service { padding: 18px 19px; border: 1px solid var(--line); border-block-start: 3px solid var(--gold); border-radius: 7px; }
.service h3 { color: var(--navy); font-size: 1.2rem; line-height: 1.4; margin-bottom: 7px; }
.service p { color: var(--muted); }

.fal-licenses {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px 30px;
  margin-top: 24px;
  padding: clamp(16px, 2.1vw, 24px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.fal-licenses h3 { color: var(--navy); font-size: 1.2rem; }
.fal-licenses dl { display: flex; flex-wrap: wrap; gap: 12px 28px; margin: 0; }
.fal-licenses dt { color: var(--muted); font-size: .925rem; }
.fal-licenses dd { color: var(--navy); font-size: 1.125rem; font-weight: 700; }
.fal-licenses dd a { text-decoration: underline; text-underline-offset: 3px; }
.fal-licenses dd a:hover { color: var(--blue); }


.contact { background: var(--navy); color: #fff; }
.contact-panel { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.contact h2 { color: white; }
.contact p { max-width: 54ch; margin-top: 12px; color: #dce7ee; }
.contact-actions { flex-shrink: 0; }

.footer { padding-block: 28px; background: #0d283f; color: #e1e9f0; }
.footer-row, .footer-links { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 14px 18px; }
.footer-brand { display: flex; align-items: center; gap: 12px; }
.footer-brand img { width: 115px; height: auto; filter: brightness(0) invert(1); }
.footer-links, .copyright, .footer-brand p { font-size: .875rem; }
.footer-links a:hover { text-decoration: underline; }
.copyright { margin-top: 22px; border-top: 1px solid #ffffff35; padding-top: 13px; color: #b8c8d6; }

@media (max-width: 860px) {
  .wrap { width: min(1200px, calc(100% - 42px)); }
  .menu-btn { display: inline-block; }
  .navlinks { display: none; position: absolute; inset: 100% 0 auto; background: white; padding: 10px 21px; border-bottom: 1px solid var(--line); }
  .navlinks.open { display: grid; gap: 0; }
  .navlinks a { padding-block: 10px; }
  .res-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-panel { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 640px) {
  :root { --header-height: 64px; }
  .wrap { width: calc(100% - 32px); }
  .brand img { width: 128px; }
  .nav-actions > .btn { display: none; }
  .section-head, .hero-grid, .portfolio-grid, .res-grid, .case-grid, .services { display: grid; grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .hero-grid, .case-grid { gap: 24px; }
  .hero-image img { height: clamp(220px, 62vw, 380px); }
  .metric { padding-inline: 9px; }
  .metric > span { font-size: .8125rem; }
  .property-content { gap: 11px; }
  .portfolio-group + .portfolio-group { margin-top: 26px; padding-top: 23px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

.hero-carousel { --slide-entry: 25px; min-width: 0; }
html[dir="rtl"] .hero-carousel { --slide-entry: -25px; }
.hero-slide:not([hidden]) { animation: slide-enter .45s ease-out; }
.hero-slide img { object-position: center 44%; }
.hero-slide figcaption { inset-block-end: 17px; padding: 10px 15px; }
.hero-slide figcaption strong { display: block; font-size: clamp(1rem, 2.5vw, 1.15rem); line-height: 1.35; }
.hero-city { color: #f0c980; }
.hero-carousel-controls { display: flex; align-items: center; justify-content: center; gap: clamp(5px, 2vw, 14px); margin-top: 7px; }
.hero-carousel-controls[hidden] { display: none; }
.hero-carousel-controls button { background: transparent; color: #e1e9f0; padding-inline: clamp(6px, 1.5vw, 12px); border: 1px solid transparent; border-radius: 6px; min-height: 44px; font-size: .875rem; cursor: pointer; line-height: 1.3; }
.hero-carousel-controls button:hover { background: #ffffff1c; color: #fff; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
@keyframes slide-enter {
  from { transform: translateX(var(--slide-entry)); opacity: .65; }
  to { transform: translateX(0); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-slide:not([hidden]) { animation: none; }
}
