/* Font Awesome Icon Fixes Only */
/* IRANSans fonts are loaded via vazir-fonts.css */

/* Font Awesome Icon Base */
.fa, .fas, .far, .fal, .fab {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Pro", "Font Awesome 6 Brands" !important;
    font-weight: 900;
    font-style: normal;
    font-variant: normal;
    text-rendering: auto;
    line-height: 1;
    display: inline-block;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Solid icons */
.fas, .fa-solid {
    font-weight: 900;
}

/* Regular icons */
.far, .fa-regular {
    font-weight: 400;
}

/* Light icons */
.fal, .fa-light {
    font-weight: 300;
}

/* Brands icons */
.fab, .fa-brands {
    font-family: "Font Awesome 6 Brands" !important;
    font-weight: 400;
}

/* Ensure icons don't inherit text font */
i[class*="fa-"],
i[class*="fas"],
i[class*="far"],
i[class*="fal"],
i[class*="fab"] {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
}

/* Fallback for icon loading issues */
.fa:before,
.fas:before,
.far:before,
.fal:before,
.fab:before {
    display: inline-block;
}

/* Better font rendering - Exclude icons */
*:not(.fa):not(.fas):not(.far):not(.fal):not(.fab):not(i):not(svg):not([class*="fa-"]) {
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Ensure icons have proper sizing */
.fa, .fas, .far, .fal, .fab, i[class*="fa-"] {
    font-size: inherit !important;
    line-height: inherit !important;
}

/* Fix icon spacing */
i.fa, i.fas, i.far, i.fal, i.fab {
    margin: 0 0.25em;
}
