/* Avenir Arabic — Arabic script via Noto (iOS-safe), Latin via Avenir files */
@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/NotoSansArabic-Regular.ttf") format("truetype");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+0660-0669, U+06F0-06F9;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/NotoSansArabic-Medium.ttf") format("truetype");
    font-weight: 500;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+0660-0669, U+06F0-06F9;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/NotoSansArabic-SemiBold.ttf") format("truetype");
    font-weight: 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+0660-0669, U+06F0-06F9;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/NotoSansArabic-Bold.ttf") format("truetype");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+0660-0669, U+06F0-06F9;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/NotoSansArabic-ExtraBold.ttf") format("truetype");
    font-weight: 800 900;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF, U+0660-0669, U+06F0-06F9;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/AvenirArabic-Medium.otf") format("opentype"),
         url("/build/assets/alfont-D6AyeCaS.otf") format("opentype");
    font-weight: 400 600;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0100-024F, U+1E00-1EFF;
}

@font-face {
    font-family: "Avenir Arabic";
    src: url("/assets/fonts/avenir-arabic/avenir-arabic-heavy.otf") format("opentype"),
         url("/build/assets/alfont-D6AyeCaS.otf") format("opentype");
    font-weight: 700 900;
    font-style: normal;
    font-display: swap;
    unicode-range: U+0000-00FF, U+0100-024F, U+1E00-1EFF;
}

@font-face {
    font-family: "Avenir";
    src: url("/build/assets/alfont-D6AyeCaS.otf") format("opentype");
    font-weight: 100 900;
    font-style: normal;
    font-display: swap;
}

:root {
    --font-avenir-arabic: "Avenir Arabic", "Avenir", -apple-system, BlinkMacSystemFont, "Geeza Pro", "Noto Sans Arabic", sans-serif;
    --font-plusjakarta: "Avenir Arabic", "Avenir", sans-serif;
    --font-sans: "Avenir Arabic", "Avenir", sans-serif;
}

html,
body {
    font-family: var(--font-avenir-arabic) !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-synthesis: none;
}

[dir="rtl"],
[dir="rtl"] body {
    letter-spacing: normal !important;
    font-feature-settings: "liga" 1, "calt" 1, "rlig" 1;
    -webkit-font-feature-settings: "liga" 1, "calt" 1, "rlig" 1;
    font-synthesis: none;
}

[dir="rtl"] :where(.tracking-tighter, .tracking-tight, .tracking-wide, .tracking-wider, .tracking-widest),
[dir="rtl"] :where([class*="tracking-["]) {
    letter-spacing: normal !important;
}
