/* Yodac Arabic pages (2026-10-25): Arabic type and right-to-left layout. Loaded only on /ar/ pages. */
html[lang="ar"] {
  --ar-sans: "Noto Sans Arabic", Inter, Arial, sans-serif;
  --ar-serif: "Noto Naskh Arabic", "Noto Serif", Georgia, serif;
}
html[lang="ar"] main.page { --font-primary: var(--ar-serif) !important; --font-secondary: var(--ar-sans) !important; }
html[lang="ar"] body { font-family: var(--ar-sans); }

/* Arabic letters join: never letter-space or case-transform them */
html[lang="ar"] :is(.ybl, .yt, .yodac-footer-v2, header.block-header) *,
html[lang="ar"] :is(.ybl, .yt, .yodac-footer-v2, header.block-header) *::before,
html[lang="ar"] :is(.ybl, .yt, .yodac-footer-v2, header.block-header) *::after { font-family: inherit; letter-spacing: 0 !important; text-transform: none !important; }
html[lang="ar"] :is(.ybl, .yt, .yodac-footer-v2) { font-family: var(--ar-sans); line-height: 1.9; }
html[lang="ar"] header.block-header .item-content { font-family: var(--ar-sans) !important; font-size: 16px; }
html[lang="ar"] :is(.ybl, .yt, .yodac-footer-v2) :is(h1, h2, h3, h4, blockquote, .ybl-intro__lead, .ybl-spec dt, .ybl-approach__item strong, .ybl-channel__value, .yt-fact__value, .yt-lead--xl) { font-family: var(--ar-serif); }
html[lang="ar"] :is(.ybl, .yt) :is(h1, h2, h3, h4) { line-height: 1.45; }
html[lang="ar"] :is(.ybl-hero, .yt-hero) h1 { line-height: 1.35; }
html[lang="ar"] .ybl-intro__lead { line-height: 1.8; }
html[lang="ar"] .ybl a.ybl-pill { font-size: 14px; }
html[lang="ar"] .ybl-approach__item::before { font-family: var(--ar-serif); }

/* Right-to-left layout */
html[dir="rtl"] :is(.ybl-hero, .yt-hero)::before {
  background:
    linear-gradient(180deg, rgba(10, 20, 38, .38) 0%, rgba(10, 20, 38, 0) 22%),
    linear-gradient(270deg, rgba(10, 20, 38, .32) 0%, rgba(10, 20, 38, .12) 40%, rgba(10, 20, 38, 0) 62%);
}
html[dir="rtl"] .ybl-hero__tag span { padding-left: 0; padding-right: 18px; }
html[dir="rtl"] .ybl-hero__tag span::before { left: auto; right: 0; }
html[dir="rtl"] .ybl-intro__body { border-left: 0; padding-left: 0; border-right: 3px solid var(--ybl-blue); padding-right: 36px; }
html[dir="rtl"] .ybl-services__grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
html[dir="rtl"] .ybl-vertical { justify-self: start; writing-mode: horizontal-tb; transform: none; }
html[dir="rtl"].ybl-motion .ybl .ybl-vertical[data-ybl-reveal] { transform: translateY(24px); }
html[dir="rtl"].ybl-motion .ybl .ybl-vertical[data-ybl-reveal].is-visible { transform: none; }
html[dir="rtl"] .ybl-channel__arrow { transform: scaleX(-1); }
html[dir="rtl"] .ybl-channel:hover .ybl-channel__arrow { transform: scaleX(-1) translateX(3px); }
html[dir="rtl"] .ybl-zig__media { border-radius: 20px 140px 20px 20px; }
html[dir="rtl"] .ybl-sheet { border-radius: 16px 72px 16px 16px; }
html[dir="rtl"] .yt { --yt-sig: 16px 72px 16px 16px; --yt-sig-lg: 20px 140px 20px 20px; }
html[dir="rtl"] .yt-gallery figure { border-radius: 12px 48px 12px 12px; }
html[dir="rtl"] .yodac-footer-v2__form .yodac-captcha { text-align: right; }
html[dir="rtl"] :is(.yt-panel, .yt-form-dark, .yodac-footer-v2) input[type="email"] { direction: ltr; text-align: right; }
html[dir="rtl"] [dir="ltr"] { unicode-bidi: isolate; }
html[dir="rtl"] .yt-legal { text-align: left; }
html[dir="rtl"] .yt-legal h2 { text-align: center; }

@media (max-width: 920px) {
  html[dir="rtl"] .ybl-intro__body { border-right: 0; padding-right: 0; }
}
@media (max-width: 680px) {
  html[dir="rtl"] :is(.ybl-hero, .yt-hero)::before {
    background:
      linear-gradient(180deg, rgba(10, 20, 38, .38) 0%, rgba(10, 20, 38, 0) 22%),
      linear-gradient(0deg, rgba(10, 20, 38, .42) 0%, rgba(10, 20, 38, .1) 45%, rgba(10, 20, 38, 0) 70%);
  }
  html[dir="rtl"] .ybl-zig__media { border-radius: 16px 72px 16px 16px; }
  html[dir="rtl"] .ybl-sheet { border-radius: 12px 40px 12px 12px; }
  html[dir="rtl"] .yt { --yt-sig: 12px 48px 12px 12px; --yt-sig-lg: 16px 72px 16px 16px; }
  html[dir="rtl"] .yt-gallery figure { border-radius: 10px 28px 10px 10px; }
}
