/* Circular flag with the same inherited border and dimensions as the header icons. */
.nav .language-switch {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  min-width: 40px;
  min-height: 40px;
  padding: 2px;
  border: 1px solid #fbf3ea47;
  border-radius: 50%;
  box-sizing: border-box;
  overflow: hidden;
  flex: 0 0 40px;
  direction: ltr;
  line-height: 1;
}
.nav.is-solid .language-switch {
  border-color: var(--c-line);
}
.language-switch__flag {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
  pointer-events: none;
}
.nav .language-switch:focus-visible {
  outline: 2px solid var(--c-apricot);
  outline-offset: 3px;
}
.nav__tools { min-width: 0; }
.nav__tools .icon-btn { flex-shrink: 0; }
.nav__tools .search { min-width: 0; }
@media (821px <= width <= 1100px) {
  .nav { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 10px; }
  .nav__links { gap: 2px; }
  .nav__links a { padding-inline: 8px; white-space: nowrap; }
  .nav__tools { gap: 5px; }
  .nav__tools .search { width: auto; flex: 0 1 170px; min-width: 78px; padding-inline: 8px; }
}
@media (width <= 480px) {
  .nav { gap: 8px; }
  .nav__tools { gap: 5px; }
}
@media (width <= 360px) {
  .nav { padding-inline: 10px; }
}
/* Arabic locale only. Preserve LTR coordinates of existing animation tracks. */
html[lang="ar"] { --font-body: Tahoma, Arial, sans-serif; --font-serif: Tahoma, Arial, sans-serif; }
html[lang="ar"] body { font-family: var(--font-body); }
html[lang="ar"] em { font-style: normal; }
html[lang="ar"] h2, html[lang="ar"] .hero__title, html[lang="ar"] .craft__text, html[lang="ar"] .promise__text { letter-spacing: normal; line-height: 1.32; }
html[lang="ar"] .logo, html[lang="ar"] .logo em, html[lang="ar"] .loader__word, html[lang="ar"] .footer__word { direction: ltr; font-family: "Instrument Serif", Georgia, serif; font-style: italic; }
html[lang="ar"] .hero__copy { right: var(--edge); left: auto; text-align: right; }
html[lang="ar"] .stat { left: var(--edge); right: auto; }
html[lang="ar"] .carousel, html[lang="ar"] .carousel__viewport, html[lang="ar"] .carousel__track,
html[lang="ar"] .gallery__viewport, html[lang="ar"] .gallery__track, html[lang="ar"] .marquee, html[lang="ar"] .marquee__row, html[lang="ar"] .head__arrows { direction: ltr; }
html[lang="ar"] .pcard, html[lang="ar"] .gtile, html[lang="ar"] .review { direction: rtl; }
html[lang="ar"] .pcard__variant { margin-left: 0; margin-right: 6px; }
html[lang="ar"] .news__msg { right: 20px; left: auto; }
html[lang="ar"] .reviews__num { direction: ltr; text-align: right; }
html[lang="ar"] .hero__title { font-size: clamp(2.3rem, 1.2rem + 4.4vw, 5.4rem); }
html[lang="ar"] .btn svg, html[lang="ar"] .pill svg, html[lang="ar"] .link svg { scale: -1 1; }
@media (width <= 820px) {
  html[lang="ar"] .stat { right: var(--gutter); left: auto; }
  html[lang="ar"] .stat__label { max-width: 22ch; }
  html[lang="ar"] .menu { font-style: normal; }
}


/* Arabic homepage hero only. The mirror is applied to an independent plane:
   GSAP still owns the image's zoom/pointer motion and its parent's scroll parallax.
   English keeps the original composition and the original image DOM. */
html[lang="ar"] body[data-page="home"] .hero__image-plane {
  position: absolute;
  inset: 0;
  transform: scaleX(-1);
  transform-origin: 50% 50%;
}
html[lang="ar"] body[data-page="home"] .hero__shade {
  background:
    linear-gradient(270deg, #2a1520e0 0%, #2a1520cb 28%, #2a1520b8 50%, #2a152040 73%, transparent 96%),
    linear-gradient(180deg, #2a152073 0%, transparent 23%, transparent 67%, #2a152099 100%);
}
html[lang="ar"] body[data-page="home"] .hero__copy {
  right: var(--edge);
  left: auto;
  width: min(620px, calc(100% - 2 * var(--edge) - 218px));
  color: var(--c-cream);
  text-align: right;
}
html[lang="ar"] body[data-page="home"] .hero__title {
  font-size: clamp(2.35rem, 3.9vw, 4.5rem);
  font-weight: 600;
  line-height: 1.22;
  letter-spacing: normal;
  text-shadow: 0 2px 18px #2a15204d;
}
html[lang="ar"] body[data-page="home"] .hero__title em {
  font-family: var(--font-body);
  font-style: normal;
  font-weight: inherit;
  letter-spacing: normal;
  color: var(--c-apricot);
}
html[lang="ar"] body[data-page="home"] .hero__title .line {
  padding-block: .04em .14em;
  margin-bottom: -.10em;
}
html[lang="ar"] body[data-page="home"] .hero__sub {
  color: var(--c-cream);
  max-width: 44ch;
  margin: 18px 0 25px;
  font-size: clamp(.95rem, 1.2vw, 1.08rem);
  line-height: 1.8;
  text-shadow: 0 1px 10px #2a152070;
}
html[lang="ar"] body[data-page="home"] .hero .stat__num {
  direction: ltr;
  text-align: right;
}
@media (min-width: 821px) and (max-width: 1100px) {
  html[lang="ar"] body[data-page="home"] .hero__shade {
    background:
      linear-gradient(270deg, #2a1520e0 0%, #2a1520cd 38%, #2a1520bf 57%, #2a152044 79%, transparent 100%),
      linear-gradient(180deg, #2a152073 0%, transparent 23%, transparent 67%, #2a152099 100%);
  }
}
@media (min-width: 821px) and (max-height: 660px) {
  html[lang="ar"] body[data-page="home"] .hero__copy { bottom: 36px; }
  html[lang="ar"] body[data-page="home"] .hero__title {
    font-size: clamp(2.3rem, 3.3vw, 3.8rem);
  }
  html[lang="ar"] body[data-page="home"] .hero__sub { margin-block: 12px 18px; }
}
@media (max-width: 820px) {
  html[lang="ar"] body[data-page="home"] .hero__shade {
    background:
      linear-gradient(180deg, #2a15207a 0%, #2a152026 24%, #2a1520ad 49%, #2a1520ed 100%),
      linear-gradient(270deg, #2a152077 0%, #2a15203d 56%, transparent 100%);
  }
  html[lang="ar"] body[data-page="home"] .hero__copy {
    width: calc(100% - 2 * var(--gutter));
    right: var(--gutter);
    bottom: 146px;
  }
  html[lang="ar"] body[data-page="home"] .hero__title {
    font-size: clamp(1.8rem, 7.7vw, 3.4rem);
    line-height: 1.25;
  }
  html[lang="ar"] body[data-page="home"] .hero__sub {
    font-size: .95rem;
    line-height: 1.7;
    margin-block: 14px 20px;
  }
  html[lang="ar"] body[data-page="home"] .hero .stat {
    max-width: calc(100% - 2 * var(--gutter));
    gap: 10px;
  }
  html[lang="ar"] body[data-page="home"] .hero .stat__label { max-width: 16ch; }
}
@media (max-width: 380px) {
  html[lang="ar"] body[data-page="home"] .hero__copy { bottom: 132px; }
  html[lang="ar"] body[data-page="home"] .hero__title { font-size: clamp(1.65rem, 7.7vw, 1.95rem); }
  html[lang="ar"] body[data-page="home"] .hero__sub { font-size: .9rem; margin-block: 12px 16px; }
  html[lang="ar"] body[data-page="home"] .hero .stat { padding: 10px 12px; }
  html[lang="ar"] body[data-page="home"] .hero .stat__num { font-size: 1.8rem; }
}
