/* 
 * Icon Fallback CSS
 * حل احتياطي لمشكلة عدم ظهور الأيقونات
 */

/* التأكد من تحميل Font Awesome بشكل صحيح */
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css');

/* إصلاح عرض الأيقونات */
.fas, .far, .fab, .fa {
  font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
  font-weight: 900;
  font-style: normal;
  font-variant: normal;
  text-rendering: auto;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: inline-block;
}

.far {
  font-weight: 400;
}

.fab {
  font-family: "Font Awesome 6 Brands" !important;
  font-weight: 400;
}

/* التأكد من ظهور الأيقونات في حالة فشل التحميل */
i[class*="fa-"]::before {
  display: inline-block;
  text-rendering: auto;
  -webkit-font-smoothing: antialiased;
}

/* إصلاح مشكلة الأيقونات المخفية */
.fa-moon::before { content: "\f186"; }
.fa-sun::before { content: "\f185"; }
.fa-volume-up::before { content: "\f028"; }
.fa-volume-mute::before { content: "\f6a9"; }
.fa-calendar-check::before { content: "\f274"; }
.fa-tools::before { content: "\f7d9"; }
.fa-images::before { content: "\f302"; }
.fa-file-invoice::before { content: "\f570"; }
.fa-shopping-cart::before { content: "\f07a"; }
.fa-mobile-alt::before { content: "\f3cd"; }
.fa-laptop::before { content: "\f109"; }
.fa-hdd::before { content: "\f0a0"; }
.fa-gamepad::before { content: "\f11b"; }
.fa-tv::before { content: "\f26c"; }
.fa-headphones::before { content: "\f025"; }
.fa-shield-alt::before { content: "\f3ed"; }
.fa-arrow-right::before { content: "\f061"; }
.fa-arrow-left::before { content: "\f060"; }
.fa-check::before { content: "\f00c"; }
.fa-times::before { content: "\f00d"; }
.fa-bars::before { content: "\f0c9"; }
.fa-phone::before { content: "\f095"; }
.fa-envelope::before { content: "\f0e0"; }
.fa-map-marker-alt::before { content: "\f3c5"; }
.fa-star::before { content: "\f005"; }
.fa-quote-left::before { content: "\f10d"; }
.fa-quote-right::before { content: "\f10e"; }
.fa-facebook::before { content: "\f09a"; }
.fa-whatsapp::before { content: "\f232"; }
.fa-instagram::before { content: "\f16d"; }
.fa-twitter::before { content: "\f099"; }
.fa-linkedin::before { content: "\f0e1"; }
.fa-youtube::before { content: "\f167"; }
.fa-arrow-up::before { content: "\f062"; }
.fa-info-circle::before { content: "\f05a"; }
.fa-exclamation-triangle::before { content: "\f071"; }
.fa-spinner::before { content: "\f110"; }
.fa-search::before { content: "\f002"; }
.fa-user::before { content: "\f007"; }
.fa-cog::before { content: "\f013"; }
.fa-home::before { content: "\f015"; }
.fa-download::before { content: "\f019"; }
.fa-upload::before { content: "\f093"; }
.fa-trash::before { content: "\f1f8"; }
.fa-edit::before { content: "\f044"; }
.fa-save::before { content: "\f0c7"; }
.fa-plus::before { content: "\f067"; }
.fa-minus::before { content: "\f068"; }

/* إصلاح مشكلة الأيقونات في الأزرار */
button i[class*="fa-"],
a i[class*="fa-"],
.button i[class*="fa-"] {
  margin-left: 8px;
  margin-right: 8px;
}

/* إصلاح الأيقونات في RTL */
[dir="rtl"] button i[class*="fa-"],
[dir="rtl"] a i[class*="fa-"],
[dir="rtl"] .button i[class*="fa-"] {
  margin-left: 8px;
  margin-right: 8px;
}

/* التأكد من ظهور الأيقونات بشكل صحيح */
.fa-spin {
  animation: fa-spin 2s infinite linear;
}

@keyframes fa-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* إصلاح حجم الأيقونات */
.fa-xs { font-size: 0.75em; }
.fa-sm { font-size: 0.875em; }
.fa-lg { font-size: 1.25em; }
.fa-2x { font-size: 2em; }
.fa-3x { font-size: 3em; }
.fa-4x { font-size: 4em; }
.fa-5x { font-size: 5em; }

/* إصلاح الأيقونات الثابتة */
.fa-fw {
  text-align: center;
  width: 1.25em;
}
