/* ==========================================================================
   BASHANTOUD ENGINEERING — Design system
   Primary (trust / base): green #009999
   Accent (CTA / highlights): orange #FFA500
   Background: light sand beige — warm, Sudan-inspired, harmonizes with both brand hues
   Compatibility baseline: see .cursor/rules/qa-responsive-compatibility.mdc
   ========================================================================== */

:root {
  /* --- Core brand (exact logo values) --- */
  --primary: #009999;
  --primary-hover: #007d7d;
  --primary-muted: #006b6b;
  --primary-soft: #e6f7f7;
  --on-primary: #ffffff;

  --accent: #ffa500;
  --accent-hover: #e69500;
  --accent-soft: #fff4e0;
  --on-accent: #1c1917;

  /* --- Surfaces & text --- */
  --background: #faf8f5;
  --surface: #ffffff;
  --text-dark: #1f1d1b;
  --text-body: #3f3a36;
  --text-muted: #5c5650;
  --text-light: #ffffff;
  --border-color: #e8e2d9;

  /* --- Extended sand (sections, borders) — optional depth --- */
  --sand-100: #f3efe8;
  --sand-200: #e5ddd5;

  /* --- Focus & rings (green = brand) --- */
  --focus-ring: rgba(0, 153, 153, 0.35);

  /* --- Footer: deep green (trust) + warm undertone --- */
  --footer-bg: #0c2221;
  --footer-surface: #132e2c;
  --footer-text: #d8ebe9;
  --footer-muted: #9eb8b6;
  --footer-border: #1f403d;

  /* --- Legacy aliases (older class names in markup) --- */
  --color-text: var(--text-body);
  --color-text-heading: var(--text-dark);
  --color-text-muted: var(--text-muted);
  --color-bg-page: var(--background);
  --color-bg-elevated: var(--surface);
  --color-bg-muted: var(--sand-100);
  --color-border: var(--border-color);
  --color-white: #ffffff;
  --color-sand-100: var(--sand-100);
  --color-accent-ring: var(--focus-ring);

  /* Typography */
  --font-en: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-ar: "Tajawal", "Noto Sans Arabic", "Tahoma", "Arial", sans-serif;
  --font-body: var(--font-en);
  --fw-normal: 400;
  --fw-medium: 500;
  --fw-semibold: 600;
  --fw-bold: 700;

  /* Elevation */
  --shadow-color: 28 24 20;
  --shadow-sm: 0 1px 2px rgb(var(--shadow-color) / 0.06);
  --shadow-md: 0 8px 24px rgb(var(--shadow-color) / 0.09);
  --shadow-lg: 0 16px 48px rgb(var(--shadow-color) / 0.12);
  --shadow-accent: 0 10px 32px rgb(255 165 0 / 0.28);

  --radius: 14px;
  --radius-sm: 10px;
  --radius-pill: 999px;
  --transition: 0.22s ease;
  --transition-long: 0.35s ease;

  --header-h: 78px;
  /* Hero: keep top tight to navbar (avoid huge gap above headline) */
  --hero-padding-top: 1.5rem;
  --hero-padding-bottom: 3rem;
  --hero-padding-top-mobile: 1.25rem;
  --hero-padding-bottom-mobile: 2rem;
  --section-space-y: clamp(4rem, 9vw, 6rem);
  --container-max: 1200px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: var(--fw-normal);
  line-height: 1.65;
  color: var(--text-body);
  background: var(--background);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  font-size: clamp(0.9375rem, 0.9rem + 0.2vw, 1rem);
}

html[lang="ar"] body {
  font-family: var(--font-ar);
  word-break: break-word;
  overflow-wrap: break-word;
}

h1,
h2,
h3,
.section__title,
.hero__title,
.card__title,
.site-footer__brand {
  font-family: inherit;
  color: var(--text-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--primary-hover);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--accent-hover);
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: var(--on-accent);
  padding: 0.8rem 1.35rem;
  z-index: 10000;
  border-radius: var(--radius-sm);
  font-weight: var(--fw-semibold);
  box-shadow: var(--shadow-md);
}

.skip-link:focus {
  top: max(1rem, env(safe-area-inset-top, 0px));
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: clamp(1rem, 4.5vw, 1.75rem);
}

.section {
  padding-block: var(--section-space-y);
}

.section--alt {
  background: var(--surface);
  border-block: 1px solid var(--border-color);
}

.section__title {
  font-size: clamp(1.9rem, 4.2vw, 2.45rem);
  font-weight: var(--fw-bold);
  margin: 0 0 0.75rem;
  letter-spacing: -0.028em;
  line-height: 1.18;
}

.section__subtitle {
  color: var(--text-muted);
  max-width: 38rem;
  margin: 0 0 2.85rem;
  font-size: 1.0625rem;
  line-height: 1.68;
}

/* FIX-2: Allow Services and Projects subtitles to expand to full width on desktop */
@media (min-width: 1024px) {
  #services .section__subtitle--wide,
  #projects .section__subtitle--wide {
    max-width: none;
  }
}

.text-center {
  text-align: center;
}

.text-center .section__subtitle {
  margin-inline: auto;
}

#main {
  margin: 0;
  padding: 0;
}

/* --------------------------------------------------------------------------
   Header (sticky + scroll state)
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgb(255 255 255 / 0.94);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: background var(--transition-long), box-shadow var(--transition-long),
    border-color var(--transition);
  padding-inline: max(0px, env(safe-area-inset-left, 0px)) max(0px, env(safe-area-inset-right, 0px));
}

.site-header.is-scrolled {
  background: rgb(255 255 255 / 0.99);
  box-shadow: var(--shadow-md);
  border-bottom-color: rgb(0 153 153 / 0.12);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: var(--header-h);
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--text-dark);
  font-weight: var(--fw-bold);
  font-size: 1rem;
  letter-spacing: 0.02em;
}

.logo__img {
  display: block;
  width: auto;
  height: 48px;
  max-width: min(300px, 82vw);
  object-fit: contain;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 0.5rem;
  cursor: pointer;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  -webkit-tap-highlight-color: rgb(0 153 153 / 0.12);
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-dark);
  border-radius: 1px;
  transition: var(--transition);
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav__list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0.15rem;
}

.nav__link {
  display: block;
  padding: 0.55rem 0.95rem;
  color: var(--text-muted);
  font-weight: var(--fw-medium);
  font-size: 0.9375rem;
  border-radius: var(--radius-sm);
  transition: background var(--transition), color var(--transition);
}

.nav__link:hover {
  color: var(--primary-hover);
  background: var(--accent-soft);
}

.nav__link--active {
  color: var(--primary-muted);
  background: var(--primary-soft);
  font-weight: var(--fw-semibold);
}

.lang-switch {
  display: flex;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  overflow: hidden;
  margin-inline-start: 0.85rem;
  box-shadow: var(--shadow-sm);
}

.lang-switch button {
  padding: 0.5rem 0.85rem;
  border: none;
  background: var(--surface);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.06em;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}

.lang-switch button:hover {
  background: var(--sand-100);
  color: var(--text-dark);
}

.lang-switch button.is-active {
  background: var(--accent);
  color: var(--on-accent);
}

/* --------------------------------------------------------------------------
   Shop Now — nav pill button
   -------------------------------------------------------------------------- */
.btn-shop-nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 1.05rem;
  font-size: 0.78rem;
  font-weight: var(--fw-bold);
  font-family: inherit;
  letter-spacing: 0.03em;
  white-space: nowrap;
  border-radius: var(--radius-pill);
  background: var(--accent);
  color: var(--on-accent);
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background var(--transition), transform var(--transition), box-shadow var(--transition);
  box-shadow: 0 2px 10px rgb(255 165 0 / 0.32);
  margin-inline-start: 0.5rem;
  min-height: 36px;
  flex-shrink: 0;
}

.btn-shop-nav:hover {
  background: var(--accent-hover);
  color: var(--on-accent);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgb(255 165 0 / 0.42);
}

.btn-shop-nav:active {
  transform: scale(0.97);
}

@media (max-width: 900px) {
  .btn-shop-nav {
    margin-inline-start: 0;
    align-self: flex-start;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    padding: 0.65rem 1.25rem;
    min-height: 44px;
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 900px) {
  .nav-toggle {
    display: flex;
  }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border-color);
    padding: 1.1rem;
    flex-direction: column;
    align-items: stretch;
    transform: translateY(-120%);
    opacity: 0;
    visibility: hidden;
    transition: transform var(--transition-long), opacity var(--transition), visibility var(--transition);
    box-shadow: var(--shadow-md);
  }

  .nav.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav__list {
    flex-direction: column;
    gap: 0;
  }

  .nav__link {
    padding: 0.85rem 1rem;
    min-height: 44px;
    display: flex;
    align-items: center;
  }

  .lang-switch {
    margin-inline-start: 0;
    align-self: flex-start;
  }

  .lang-switch button {
    min-height: 44px;
    min-width: 44px;
  }
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  display: block;
  padding: var(--hero-padding-top) 0 var(--hero-padding-bottom);
  margin: 0;
  background: linear-gradient(145deg, #006d6d 0%, #008787 40%, #15a3a3 85%);
  color: var(--text-light);
  overflow: hidden;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 120% 80% at 0% 0%, rgb(0 153 153 / 0.22) 0%, transparent 55%),
    radial-gradient(ellipse 100% 70% at 95% 10%, rgb(255 165 0 / 0.18) 0%, transparent 58%),
    radial-gradient(ellipse 90% 60% at 15% 100%, rgb(0 0 0 / 0.25) 0%, transparent 60%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: url("images/hero-pattern.svg");
  background-size: cover;
  opacity: 0.1;
  pointer-events: none;
}

.hero__grid {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 900px) {
  .hero__grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    align-items: start;
  }
}

@media (max-width: 767.98px) {
  .hero {
    padding: var(--hero-padding-top-mobile) 0 var(--hero-padding-bottom-mobile);
  }

  .hero__grid {
    gap: 1.5rem;
  }

  .hero__grid .hero__visual {
    order: -1;
  }
}

.hero__badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 1.2rem;
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  background: rgb(255 165 0 / 0.2);
  border: 1px solid rgb(255 165 0 / 0.38);
  color: #fff8ed;
}

.hero__title {
  font-size: clamp(2.25rem, 5.5vw, 3.35rem);
  font-weight: var(--fw-bold);
  line-height: 1.1;
  margin: 0 0 1.25rem;
  letter-spacing: -0.038em;
  color: var(--text-light);
  max-width: 20ch;
}

@media (min-width: 900px) {
  .hero__title {
    max-width: none;
  }
}

.hero__lead {
  font-size: 1.125rem;
  opacity: 0.94;
  max-width: 36rem;
  margin: 0 0 2rem;
  line-height: 1.72;
  color: rgb(255 255 255 / 0.94);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  align-items: center;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.95rem 1.75rem;
  font-size: 0.97rem;
  font-weight: var(--fw-semibold);
  font-family: inherit;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: transform var(--transition), box-shadow var(--transition), background var(--transition),
    color var(--transition), border-color var(--transition);
  touch-action: manipulation;
  min-height: 44px;
}

.btn:active {
  transform: scale(0.98);
}

.btn--block {
  width: 100%;
}

.btn--primary {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: var(--shadow-accent);
}

.btn--primary:hover {
  background: var(--accent-hover);
  box-shadow: var(--shadow-lg);
}

.btn--outline {
  background: transparent;
  color: var(--text-light);
  border: 2px solid rgb(255 255 255 / 0.45);
}

.btn--outline:hover {
  background: rgb(0 153 153 / 0.28);
  border-color: rgb(255 255 255 / 0.9);
}

.btn--dark {
  background: var(--primary);
  color: var(--on-primary);
  box-shadow: var(--shadow-md);
}

.btn--dark:hover {
  background: var(--primary-hover);
  box-shadow: var(--shadow-lg);
}

.hero__visual {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  aspect-ratio: 4 / 3;
  border: 1px solid rgb(255 255 255 / 0.14);
}

.hero__visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.15rem;
  margin-top: 2.85rem;
  padding-top: 2.1rem;
  border-top: 1px solid rgb(255 255 255 / 0.18);
}

.hero__stat {
  text-align: center;
}

.hero__stat-value {
  font-size: 1.6rem;
  font-weight: var(--fw-bold);
  color: var(--accent);
  letter-spacing: -0.02em;
}

.hero__stat-label {
  font-size: 0.8rem;
  opacity: 0.9;
  color: rgb(255 255 255 / 0.88);
}

@media (max-width: 599px) {
  .hero__stats {
    grid-template-columns: 1fr;
  }
}

/* --------------------------------------------------------------------------
   Cards & grids
   -------------------------------------------------------------------------- */
.grid-2 {
  display: grid;
  gap: 2.35rem;
}

@media (min-width: 768px) {
  .grid-2 {
    grid-template-columns: 1fr 1fr;
  }
}

.grid-3 {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.grid-4 {
  display: grid;
  gap: 1.35rem;
}

@media (min-width: 600px) {
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.9rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-long), box-shadow var(--transition), border-color var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgb(0 153 153 / 0.25);
}

.card__icon {
  width: 54px;
  height: 54px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--primary-soft), var(--surface));
  border-radius: var(--radius-sm);
  color: var(--primary-hover);
  margin-bottom: 1.15rem;
  border: 1px solid rgb(0 153 153 / 0.14);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.8);
}

.card__icon svg {
  width: 26px;
  height: 26px;
}

.card__title {
  font-size: 1.125rem;
  font-weight: var(--fw-bold);
  margin: 0 0 0.55rem;
  color: var(--text-dark);
}

.card__text {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.96rem;
  line-height: 1.65;
}

.mvv {
  display: grid;
  gap: 1.5rem;
}

@media (min-width: 768px) {
  .mvv {
    grid-template-columns: 1fr 1fr;
  }
}

.mvv__box {
  background: var(--sand-100);
  padding: 2.15rem;
  border-radius: var(--radius);
  border-inline-start: 4px solid var(--primary);
  box-shadow: var(--shadow-sm);
}

.mvv__label {
  font-size: 0.72rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary-hover);
  margin-bottom: 0.55rem;
}

.mvv__text {
  margin: 0;
  color: var(--text-body);
  line-height: 1.65;
}

.why-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.why-list li {
  display: flex;
  gap: 1.1rem;
  align-items: flex-start;
  padding: 1.05rem 0;
  border-bottom: 1px solid var(--border-color);
}

.why-list li:last-child {
  border-bottom: none;
}

.why-list__check {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--primary);
  color: var(--on-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: var(--fw-bold);
  box-shadow: 0 2px 10px rgb(0 153 153 / 0.35);
}

.project-card {
  background: var(--sand-100);
  border-radius: var(--radius);
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-weight: var(--fw-semibold);
  border: 2px dashed rgb(0 153 153 / 0.28);
  transition: border-color var(--transition), background var(--transition);
}

.project-card:hover {
  border-color: rgb(255 165 0 / 0.45);
  background: var(--accent-soft);
}

.contact-grid {
  display: grid;
  gap: 2.85rem;
}

@media (min-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr 1.1fr;
  }
}

.contact-info__item {
  display: flex;
  gap: 1.1rem;
  margin-bottom: 1.6rem;
}

.contact-info__icon {
  width: 46px;
  height: 46px;
  border-radius: var(--radius-sm);
  background: var(--primary-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-hover);
  border: 1px solid rgb(0 153 153 / 0.16);
  flex-shrink: 0;
}

.contact-info__icon svg {
  width: 22px;
  height: 22px;
}

/* FIX-4: WhatsApp icon variant — official green */
.contact-info__icon--whatsapp {
  background: #e8fdf1;
  color: #25d366;
  border-color: rgb(37 211 102 / 0.22);
}

.contact-info__label {
  font-size: 0.78rem;
  font-weight: var(--fw-semibold);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 0 0 0.2rem;
}

.contact-info__value {
  margin: 0;
  font-weight: var(--fw-semibold);
  color: var(--text-dark);
}

/* FIX-3: Phone numbers always display LTR regardless of page direction */
.phone-ltr {
  direction: ltr;
  unicode-bidi: embed;
  display: inline-block;
}

.form-group {
  margin-bottom: 1.3rem;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: var(--fw-semibold);
  margin-bottom: 0.45rem;
  color: var(--text-dark);
}

.form-group input,
.form-group textarea,
.form-group select {
  width: 100%;
  padding: 0.85rem 1.08rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: max(1rem, 16px);
  background: var(--surface);
  color: var(--text-body);
  transition: border-color var(--transition), box-shadow var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--focus-ring);
}

.form-group textarea {
  min-height: 150px;
  resize: vertical;
}

.form-note {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-top: 0.85rem;
  line-height: 1.55;
}

.form-success {
  display: none;
  padding: 1rem 1.15rem;
  background: var(--primary-soft);
  color: var(--primary-hover);
  border-radius: var(--radius-sm);
  margin-top: 1rem;
  font-weight: var(--fw-semibold);
  border: 1px solid rgb(0 153 153 / 0.22);
}

.form-success.is-visible {
  display: block;
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding-block: 0 2.5rem;
}

.site-footer__cta {
  padding-block: 2.5rem 2.25rem;
  border-bottom: 1px solid var(--footer-border);
  margin-bottom: 2.5rem;
}

.site-footer__cta-inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  align-items: flex-start;
  justify-content: space-between;
}

@media (min-width: 768px) {
  .site-footer__cta-inner {
    flex-direction: row;
    align-items: center;
    gap: 2rem;
  }
}

.site-footer__cta-text {
  margin: 0;
  font-size: 1.125rem;
  font-weight: var(--fw-medium);
  line-height: 1.5;
  color: var(--footer-text);
  max-width: 36rem;
}

.site-footer__cta-btn {
  flex-shrink: 0;
}

.site-footer__grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 768px) {
  .site-footer__grid {
    grid-template-columns: 1.25fr 1fr 1fr;
  }
}

.site-footer__desc {
  margin: 0;
  color: var(--footer-muted);
  line-height: 1.65;
  max-width: 26rem;
}

.site-footer__links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer__links li {
  margin-bottom: 0.55rem;
}

.site-footer__links a {
  color: var(--footer-muted);
  transition: color var(--transition);
}

.site-footer__links a:hover {
  color: var(--accent);
}

.site-footer a {
  color: var(--footer-muted);
  transition: color var(--transition);
}

.site-footer__col p {
  margin: 0 0 0.5rem;
  color: var(--footer-muted);
  line-height: 1.55;
}

.site-footer a:hover {
  color: var(--accent);
}

.site-footer .btn--primary {
  color: var(--on-accent);
}

.site-footer .btn--primary:hover {
  color: var(--on-accent);
}

.site-footer__brand {
  font-weight: var(--fw-bold);
  color: var(--text-light);
  margin-bottom: 0.9rem;
  letter-spacing: 0.03em;
}

.site-footer__copy {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--footer-border);
  font-size: 0.9rem;
  color: var(--footer-muted);
  text-align: center;
}

/* --------------------------------------------------------------------------
   WhatsApp floating button
   FIX: WhatsApp Button RTL iOS — explicit right/left instead of inset-inline-end
   to avoid WebKit fixed+RTL+transform bug on iOS 15.3 and earlier
   -------------------------------------------------------------------------- */
.whatsapp-float {
  position: fixed;
  z-index: 9998;
  width: 58px;
  height: 58px;
  min-width: 44px;
  min-height: 44px;
  border-radius: 999px;
  border-radius: var(--radius-pill);
  background: #25d366;
  color: #fff;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-align: center;
      -ms-flex-align: center;
          align-items: center;
  -webkit-box-pack: center;
      -ms-flex-pack: center;
          justify-content: center;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.45);
  /* FIX: WhatsApp Button RTL iOS — NO transform on base state; hover handled separately */
  -webkit-transition: box-shadow 0.22s ease;
          transition: box-shadow 0.22s ease;
  -webkit-transition: box-shadow var(--transition);
          transition: box-shadow var(--transition);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  /* FIX: WhatsApp Button RTL iOS — explicit bottom + right for LTR (safe on all iOS) */
  bottom: 1rem;
  bottom: max(1rem, env(safe-area-inset-bottom, 0px));
  right: 1rem;
  right: max(1rem, env(safe-area-inset-right, 0px));
  left: auto;
  will-change: transform;
}

/* FIX: WhatsApp Button RTL iOS — explicit left/right swap for RTL; no inset-inline-end */
[dir="rtl"] .whatsapp-float {
  right: auto;
  left: 1rem;
  left: max(1rem, env(safe-area-inset-left, 0px));
}

/* FIX: WhatsApp Button RTL iOS — transform only on :hover, not base, to avoid iOS bug */
.whatsapp-float:hover {
  -webkit-transform: scale(1.06);
          transform: scale(1.06);
  box-shadow: 0 10px 32px rgba(37, 211, 102, 0.55);
}

.whatsapp-float:active {
  -webkit-transform: scale(0.98);
          transform: scale(0.98);
}

.whatsapp-float__icon {
  width: 30px;
  height: 30px;
}

/* --------------------------------------------------------------------------
   Scroll-to-top button
   FIX-1: Vertically centered on the right side (LTR) or left side (RTL)
          Shown only when user scrolls past the #home section (via JS)
   -------------------------------------------------------------------------- */
.scroll-top {
  position: fixed;
  z-index: 9997;
  /* FIX-1: center vertically on the side, not at the bottom corner */
  top: 50%;
  right: 1.5rem;
  transform: translateY(-50%);
  /* End of FIX-1 positioning */
  width: 46px;
  height: 46px;
  border-radius: var(--radius-pill);
  background: var(--primary);
  color: var(--on-primary);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  /* FIX-1: smooth fade transition (opacity + visibility) */
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity var(--transition-long), visibility var(--transition-long), background var(--transition), transform var(--transition-long);
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
}

/* FIX-1: RTL — mirror to left side */
[dir="rtl"] .scroll-top {
  right: auto;
  left: 1.5rem;
}

.scroll-top svg {
  width: 20px;
  height: 20px;
}

/* FIX-1: visible state — JS adds .is-visible when past #home */
.scroll-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.scroll-top:hover {
  background: var(--primary-hover);
}

.scroll-top:active {
  transform: translateY(-50%) scale(0.95);
}

/* Scroll animations — light fade-up */
[data-animate] {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.65s ease, transform 0.65s ease;
}

[data-animate].is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Accessibility: respect OS "reduce motion" */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  [data-animate] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }

  .btn,
  .whatsapp-float,
  .card,
  .site-header,
  .scroll-top {
    transition: none !important;
  }

  .whatsapp-float:hover,
  .whatsapp-float:active {
    transform: none;
  }

  .scroll-top:active {
    transform: translateY(-50%);
  }
}

/* ==========================================================================
   ABOUT — Story section additions
   ========================================================================== */

.section__tag {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.about-story {
  max-width: 780px;
  margin: 0 auto 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.about-story p {
  color: var(--text-body);
  line-height: 1.85;
  font-size: 1rem;
}

.about-closing {
  font-size: 1.05rem !important;
  font-weight: 600;
  color: var(--primary) !important;
  border-left: 3px solid var(--primary);
  padding-left: 1rem;
  margin-top: 0.5rem;
}

[dir="rtl"] .about-closing {
  border-left: none;
  border-right: 3px solid var(--primary);
  padding-left: 0;
  padding-right: 1rem;
}

.about-links {
  margin-bottom: 2.5rem;
  text-align: center;
}

.about-links__label {
  font-size: 0.72rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.about-links__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.about-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.4rem 1rem;
  border-radius: 100px;
  border: 1px solid var(--border-color);
  background: var(--surface);
  color: var(--primary);
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s;
}

.about-link::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  flex-shrink: 0;
}

.about-link:hover {
  border-color: var(--primary);
  background: var(--primary-soft);
}

.about-timeline {
  max-width: 680px;
  margin: 0 auto 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
  padding-left: 2rem;
}

.about-timeline::before {
  content: '';
  position: absolute;
  left: 0.6rem;
  top: 0.5rem;
  bottom: 0.5rem;
  width: 1.5px;
  background: var(--border-color);
}

[dir="rtl"] .about-timeline {
  padding-left: 0;
  padding-right: 2rem;
}

[dir="rtl"] .about-timeline::before {
  left: auto;
  right: 0.6rem;
}

.timeline-item {
  display: grid;
  grid-template-columns: 68px 1fr;
  gap: 0.75rem;
  padding-bottom: 1.25rem;
  position: relative;
}

.timeline-item::after {
  content: '';
  position: absolute;
  left: -1.4rem;
  top: 0.3rem;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  background: var(--surface);
}

[dir="rtl"] .timeline-item::after {
  left: auto;
  right: -1.4rem;
}

.timeline-item--key::after  { background: var(--primary); border-color: var(--primary); }
.timeline-item--global::after { background: #185FA5; border-color: #185FA5; }
.timeline-item--hard::after { background: var(--accent); border-color: var(--accent); }

.timeline-year {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-muted);
  padding-top: 0.15rem;
  line-height: 1.4;
}

.timeline-event {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-dark);
  line-height: 1.5;
}

.timeline-detail {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  line-height: 1.5;
}

.about-quote {
  font-size: 1.05rem;
  font-style: italic;
  color: var(--primary);
  border-left: 3px solid var(--primary);
  padding-left: 1rem;
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

[dir="rtl"] .about-quote {
  border-left: none;
  border-right: 3px solid var(--primary);
  padding-left: 0;
  padding-right: 1rem;
}

.about-chapter {
  margin-bottom: 1.5rem;
}

.about-chapter__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ==========================================================================
   PROJECTS SECTION
   ========================================================================== */

.projects-grid {
  display: grid;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

@media (min-width: 640px) {
  .projects-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .projects-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.project-card-new {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 1.6rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  transition: transform var(--transition-long), box-shadow var(--transition), border-color var(--transition);
}

.project-card-new:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: rgb(0 153 153 / 0.28);
}

.project-card-new__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.project-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: var(--fw-bold);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-pill);
}

.project-badge--supply {
  background: var(--primary-soft);
  color: var(--primary-muted);
  border: 1px solid rgb(0 153 153 / 0.18);
}

.project-badge--install {
  background: var(--accent-soft);
  color: #b36b00;
  border: 1px solid rgb(255 165 0 / 0.22);
}

.project-badge--sanitary {
  background: #eef4ff;
  color: #185FA5;
  border: 1px solid rgb(24 95 165 / 0.18);
}

.project-badge--bulk {
  background: var(--sand-100);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.project-badge--mep {
  background: #f3f0ff;
  color: #5a35b0;
  border: 1px solid rgb(90 53 176 / 0.18);
}

.project-status {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: var(--fw-semibold);
  padding: 0.28rem 0.65rem;
  border-radius: var(--radius-pill);
  letter-spacing: 0.04em;
}

.project-status--done {
  background: rgb(0 153 153 / 0.1);
  color: var(--primary-muted);
}

.project-status--ongoing {
  background: rgb(255 165 0 / 0.13);
  color: #b36b00;
}

.project-card-new__icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, var(--primary-soft), var(--surface));
  border-radius: var(--radius-sm);
  color: var(--primary-hover);
  border: 1px solid rgb(0 153 153 / 0.12);
  flex-shrink: 0;
}

.project-card-new__icon svg {
  width: 22px;
  height: 22px;
}

.project-card-new__title {
  font-size: 1rem;
  font-weight: var(--fw-bold);
  color: var(--text-dark);
  margin: 0;
  line-height: 1.35;
}

.project-card-new__desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
  margin: 0;
  flex: 1;
}

.project-card-new__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  margin-top: auto;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border-color);
}

.project-meta-item {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-weight: var(--fw-medium);
}

.project-meta-icon {
  font-size: 0.72rem;
  line-height: 1;
}

.projects-cta {
  text-align: center;
  margin-top: 0.5rem;
}

[dir="rtl"] .project-card-new__header {
  flex-direction: row-reverse;
}

[dir="rtl"] .project-card-new__meta {
  flex-direction: row-reverse;
}

/* ==========================================================================
   FIX: Google Fonts Dependency — Bulletproof fallback font stacks
   Ensures readable text on Huawei HMS / no-GMS devices
   ========================================================================== */

/* When Google Fonts fail (detected by JS adding .fonts-failed to <html>),
   override with system fonts that render correctly on all platforms */
html.fonts-failed body,
html.fonts-failed h1,
html.fonts-failed h2,
html.fonts-failed h3,
html.fonts-failed p,
html.fonts-failed a,
html.fonts-failed button,
html.fonts-failed input,
html.fonts-failed select,
html.fonts-failed textarea {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", Arial, sans-serif;
}

html.fonts-failed[lang="ar"] body,
html.fonts-failed[lang="ar"] h1,
html.fonts-failed[lang="ar"] h2,
html.fonts-failed[lang="ar"] h3,
html.fonts-failed[lang="ar"] p,
html.fonts-failed[lang="ar"] a,
html.fonts-failed[lang="ar"] button,
html.fonts-failed[lang="ar"] input,
html.fonts-failed[lang="ar"] select,
html.fonts-failed[lang="ar"] textarea {
  font-family: "Noto Sans Arabic", "Arabic UI", "Geeza Pro", "Traditional Arabic", "Arial Unicode MS", Tahoma, Arial, sans-serif;
}

/* ==========================================================================
   FIX: Opera Mini Compatibility — CSS custom property hardcoded fallbacks
   Every var() must have a hardcoded value on the line before it
   ========================================================================== */

/* Body base */
body {
  color: #3f3a36;
  color: var(--text-body);
  background: #faf8f5;
  background: var(--background);
}

/* Section titles */
.section__title {
  color: #1f1d1b;
  color: var(--text-dark);
}

.section__subtitle {
  color: #5c5650;
  color: var(--text-muted);
}

/* Primary button */
.btn--primary {
  background: #ffa500;
  background: var(--accent);
  color: #1c1917;
  color: var(--on-accent);
}

.btn--primary:hover {
  background: #e69500;
  background: var(--accent-hover);
}

/* Dark button */
.btn--dark {
  background: #009999;
  background: var(--primary);
  color: #ffffff;
  color: var(--on-primary);
}

.btn--dark:hover {
  background: #007d7d;
  background: var(--primary-hover);
}

/* Cards */
.card {
  background: #ffffff;
  background: var(--surface);
  border: 1px solid #e8e2d9;
  border: 1px solid var(--border-color);
}

.card__icon {
  background: #e6f7f7;
  background: linear-gradient(145deg, var(--primary-soft), var(--surface));
  color: #007d7d;
  color: var(--primary-hover);
}

/* Nav links */
.nav__link {
  color: #5c5650;
  color: var(--text-muted);
}

.nav__link--active {
  color: #006b6b;
  color: var(--primary-muted);
  background: #e6f7f7;
  background: var(--primary-soft);
}

/* Lang switch */
.lang-switch button.is-active {
  background: #ffa500;
  background: var(--accent);
  color: #1c1917;
  color: var(--on-accent);
}

/* Header */
.site-header {
  background: rgba(255,255,255,0.94);
  border-bottom: 1px solid #e8e2d9;
  border-bottom: 1px solid var(--border-color);
}

/* Footer */
.site-footer {
  background: #0c2221;
  background: var(--footer-bg);
  color: #d8ebe9;
  color: var(--footer-text);
}

.site-footer__copy {
  color: #9eb8b6;
  color: var(--footer-muted);
  border-top: 1px solid #1f403d;
  border-top: 1px solid var(--footer-border);
}

/* Contact info */
.contact-info__icon {
  background: #e6f7f7;
  background: var(--primary-soft);
  color: #007d7d;
  color: var(--primary-hover);
}

/* Why-list check */
.why-list__check {
  background: #009999;
  background: var(--primary);
  color: #ffffff;
  color: var(--on-primary);
}

/* Scroll-top button */
.scroll-top {
  background: #009999;
  background: var(--primary);
  color: #ffffff;
  color: var(--on-primary);
}

.scroll-top:hover {
  background: #007d7d;
  background: var(--primary-hover);
}

/* ==========================================================================
   FIX: Opera Mini Compatibility — CSS Grid fallbacks using Flexbox
   For browsers without Grid support
   ========================================================================== */

/* hero__grid: flex fallback */
.hero__grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.hero__grid > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 280px;
          flex: 1 1 280px;
}

/* grid-4: flex fallback */
.grid-4 {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.grid-4 > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 220px;
          flex: 1 1 220px;
}

/* grid-2: flex fallback */
.grid-2 {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.grid-2 > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 280px;
          flex: 1 1 280px;
}

/* projects-grid: flex fallback */
.projects-grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.projects-grid > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 280px;
          flex: 1 1 280px;
}

/* contact-grid: flex fallback */
.contact-grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.contact-grid > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 280px;
          flex: 1 1 280px;
}

/* ==========================================================================
   FIX: Touch Target Sizes — minimum 44×44px on all interactive elements
   Applied globally via padding augmentation, not visual resize
   ========================================================================== */

/* Nav links — already have padding, ensure min-height */
.nav__link {
  min-height: 44px;
  min-width: 44px;
  display: -webkit-inline-box;
  display: -ms-inline-flexbox;
  display: inline-flex;
  -webkit-box-align: center;
      -ms-flex-align: center;
          align-items: center;
}

/* Footer links — add padding for touch target */
.site-footer__links a {
  display: inline-block;
  padding-block: 0.4rem;
  min-height: 44px;
  display: -webkit-inline-box;
  display: -ms-inline-flexbox;
  display: inline-flex;
  -webkit-box-align: center;
      -ms-flex-align: center;
          align-items: center;
}

/* Lang switch buttons — already 44px min via earlier rules, reinforce */
.lang-switch button {
  min-height: 44px;
  min-width: 44px;
}

/* Shop nav button */
.btn-shop-nav {
  min-height: 44px;
}

/* Form inputs and selects */
.form-group input,
.form-group select,
.form-group textarea {
  min-height: 44px;
}

/* About links */
.about-link {
  min-height: 44px;
  display: -webkit-inline-box;
  display: -ms-inline-flexbox;
  display: inline-flex;
  -webkit-box-align: center;
      -ms-flex-align: center;
          align-items: center;
}

/* ==========================================================================
   FIX: WhatsApp Button RTL iOS — reduced-motion override (clean state)
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  .whatsapp-float {
    -webkit-transition: none !important;
            transition: none !important;
  }
  .whatsapp-float:hover,
  .whatsapp-float:active {
    -webkit-transform: none !important;
            transform: none !important;
  }
}

/* ==========================================================================
   FIX: Opera Mini Compatibility — additional Grid flex fallbacks
   (hero__stats, mvv, site-footer__grid, grid-3, timeline-item)
   ========================================================================== */

/* hero__stats: 3-column stats row */
.hero__stats {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
  -webkit-box-pack: center;
      -ms-flex-pack: center;
          justify-content: center;
}

.hero__stat {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 120px;
          flex: 1 1 120px;
}

/* mvv grid: Mission / Vision cards */
.mvv {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.mvv > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 260px;
          flex: 1 1 260px;
}

/* mvv-grid (about section uses this class) */
.mvv-grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
  gap: 1.5rem;
}

.mvv-grid > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 260px;
          flex: 1 1 260px;
}

/* grid-3 */
.grid-3 {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.grid-3 > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 240px;
          flex: 1 1 240px;
}

/* site-footer__grid */
.site-footer__grid {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
}

.site-footer__grid > * {
  -webkit-box-flex: 1;
      -ms-flex: 1 1 200px;
          flex: 1 1 200px;
}

/* timeline-item: year + event columns */
.timeline-item {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: horizontal;
  -webkit-box-direction: normal;
      -ms-flex-direction: row;
          flex-direction: row;
  gap: 0.75rem;
}

.timeline-year {
  -ms-flex-negative: 0;
      flex-shrink: 0;
  width: 68px;
}

/* ==========================================================================
   v2 COMPATIBILITY FIXES — 2026-04-05
   ========================================================================== */

/* --------------------------------------------------------------------------
   FIX-1: Bulletproof font fallback stacks
   -------------------------------------------------------------------------- */
:root {
  --font-en: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-ar: "Tajawal", "Noto Sans Arabic", "Arabic UI", "Geeza Pro", "Traditional Arabic", Tahoma, Arial, sans-serif;
}
html.fonts-failed body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif; }
html.fonts-failed[lang="ar"] body { font-family: "Noto Sans Arabic", "Arabic UI", "Geeza Pro", Tahoma, Arial, sans-serif; }

/* --------------------------------------------------------------------------
   FIX-4: Scroll-to-top :active — preserve translateY(-50%) on tap
   -------------------------------------------------------------------------- */
.scroll-top:active {
  transform: translateY(-50%) scale(0.95);
}

/* --------------------------------------------------------------------------
   FIX-7: Select font-size — prevent iOS auto-zoom (enforced)
   -------------------------------------------------------------------------- */
.form-group input,
.form-group textarea,
.form-group select {
  font-size: max(1rem, 16px);
}

/* --------------------------------------------------------------------------
   FIX-9: WhatsApp float — RTL hover jump fix (translateZ for GPU compositing)
   -------------------------------------------------------------------------- */
.whatsapp-float {
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}
.whatsapp-float:hover {
  -webkit-transform: translateZ(0) scale(1.06);
  transform: translateZ(0) scale(1.06);
}

/* --------------------------------------------------------------------------
   FIX-10/20: Backdrop-filter — Mediatek + Huawei HarmonyOS 2 fallback
   -------------------------------------------------------------------------- */
@supports not (backdrop-filter: blur(1px)) {
  .site-header {
    background: rgba(250, 248, 245, 0.98);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}
@media (prefers-reduced-data: reduce) {
  .site-header {
    background: rgba(255, 255, 255, 0.99);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

/* --------------------------------------------------------------------------
   FIX-11: Samsung Internet — physical fallbacks before logical properties
   -------------------------------------------------------------------------- */
.lang-switch {
  margin-left: 0.85rem;
  margin-inline-start: 0.85rem;
}
.btn-shop-nav {
  margin-left: 0.5rem;
  margin-inline-start: 0.5rem;
}
@media (max-width: 900px) {
  .lang-switch { margin-left: 0; margin-inline-start: 0; }
  .btn-shop-nav { margin-left: 0; margin-inline-start: 0; }
}

/* --------------------------------------------------------------------------
   FIX-14: Hero iPhone SE (375–390px) — prevent 4-line title wrap
   -------------------------------------------------------------------------- */
@media (max-width: 390px) {
  .hero__title {
    font-size: 1.75rem;
    font-size: clamp(1.75rem, 5vw, 2.25rem);
    max-width: none;
    letter-spacing: -0.025em;
  }
  .hero__lead {
    font-size: 0.9rem;
    line-height: 1.6;
  }
}

/* --------------------------------------------------------------------------
   FIX-15: clamp() Android 8 fallback — px before every clamp()
   -------------------------------------------------------------------------- */
body {
  font-size: 0.9375rem;
  font-size: clamp(0.9375rem, 0.9rem + 0.2vw, 1rem);
}
.section__title {
  font-size: 1.9rem;
  font-size: clamp(1.9rem, 4.2vw, 2.45rem);
}
.hero__title {
  font-size: 2.25rem;
  font-size: clamp(2.25rem, 5.5vw, 3.35rem);
}

/* --------------------------------------------------------------------------
   FIX-16: iPad landscape — cap wide subtitle at 75ch (1024–1180px)
   -------------------------------------------------------------------------- */
@media (min-width: 1024px) and (max-width: 1180px) {
  .section__subtitle--wide { max-width: 75ch; }
}

/* --------------------------------------------------------------------------
   FIX-19: Tablet nav 768–900px — prevent link wrap overflow
   -------------------------------------------------------------------------- */
@media (min-width: 768px) and (max-width: 900px) {
  .nav__list {
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .nav__list::-webkit-scrollbar { display: none; }
  .nav__link {
    white-space: nowrap;
    padding-left: 0.6rem;
    padding-right: 0.6rem;
  }
}

/* --------------------------------------------------------------------------
   FIX-3: noscript contact fallback styling
   -------------------------------------------------------------------------- */
.noscript-contact-fallback {
  background: #e6f7f7;
  border: 1px solid #009999;
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 2rem;
  text-align: center;
  font-family: Arial, sans-serif;
  line-height: 1.7;
}
.noscript-contact-fallback a { color: #006b6b; font-weight: 600; }

/* --------------------------------------------------------------------------
   FIX: prefers-reduced-motion — ensure scroll-top active stays correct
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .scroll-top:active { transform: translateY(-50%); }
}
