/* Base typography for the English (dir="ltr") pages.
   The site sets `body { font-family: IranYekanFaNum-Regular !important }`, whose Latin
   glyphs and digits (rendered Persian) don't fit English text, so LTR pages use Montserrat
   as one family with real weights instead of synthesized bold. */

@font-face { font-family: MontserratLtr; font-weight: 400; src: url('../fonts/Montserrat-Regular.ttf') format("truetype"); }
@font-face { font-family: MontserratLtr; font-weight: 500; src: url('../fonts/Montserrat-Medium.ttf') format("truetype"); }
@font-face { font-family: MontserratLtr; font-weight: 600; src: url('../fonts/Montserrat-SemiBold.ttf') format("truetype"); }
@font-face { font-family: MontserratLtr; font-weight: 700; src: url('../fonts/Montserrat-Bold.ttf') format("truetype"); }
@font-face { font-family: MontserratLtr; font-weight: 800; src: url('../fonts/Montserrat-ExtraBold.ttf') format("truetype"); }
@font-face { font-family: MontserratLtr; font-weight: 900; src: url('../fonts/Montserrat-Black.ttf') format("truetype"); }

html[dir="ltr"] body {
    font-family: MontserratLtr, sans-serif !important;
}

/* Persian text that stays on an English page (e.g. the "فارسی" option, untranslated DB content) */
html[dir="ltr"] [lang="fa"],
html[dir="ltr"] [lang="ckb"] {
    font-family: IranYekanFaNum-Regular, sans-serif;
}

/* Rich-text content (CKEditor descriptions): the site forces Persian fonts here with !important */
html[dir="ltr"] .editor-section,
html[dir="ltr"] .editor-section p,
html[dir="ltr"] .editor-section span,
html[dir="ltr"] .editor-section strong,
html[dir="ltr"] .editor-section li {
    font-family: MontserratLtr, sans-serif !important;
}
html[dir="ltr"] .editor-section h1,
html[dir="ltr"] .editor-section h2,
html[dir="ltr"] .editor-section h3 {
    font-family: MontserratLtr, sans-serif !important;
    font-weight: 800;
}
html[dir="ltr"] .editor-section strong {
    font-weight: 700;
}

/* ...except untranslated Persian content shown as a fallback */
html[dir="ltr"] [lang="fa"],
html[dir="ltr"] [lang="fa"] p,
html[dir="ltr"] [lang="fa"] span,
html[dir="ltr"] [lang="fa"] strong,
html[dir="ltr"] [lang="fa"] li {
    font-family: IranSansFaNum-Regular, sans-serif !important;
}
html[dir="ltr"] [lang="fa"] h1,
html[dir="ltr"] [lang="fa"] h2,
html[dir="ltr"] [lang="fa"] h3 {
    font-family: IranSansFaNum-Black, sans-serif !important;
}

/* Justified English text without hyphenation leaves big gaps between words;
   the Persian pages keep text-justify. */
html[dir="ltr"] .text-justify,
html[dir="ltr"] .sm\:text-justify {
    text-align: left;
}

/* Projects page > latest project roadmaps: every slide has a fixed height, so an
   English title must stay on one line instead of wrapping into the next slide. */
html[dir="ltr"] .roadmap .swiper-slide > div > div {
    min-width: 0;
}
html[dir="ltr"] .roadmap .swiper-slide > div > div > p:first-child {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 16px;
}

/* Home hero: the service image overlaps the text card by 80px (rtl:-ml-20); the LTR
   class in the view was -mr-6, so in English the image and card sat side by side. */
@media (min-width: 910px) {
    html[dir="ltr"] .tab-content > div > div:first-child {
        margin-right: -5rem;
    }
}

/* LXP page: the view had a typo (ltr:lg:lef-[101px]) and the class isn't in the Tailwind build */
@media (min-width: 1024px) {
    html[dir="ltr"] .ltr-lg-left-101 {
        left: 101px;
    }
}
