/* Font Awesome محلي - إصدار 6.4.0 */

/* تعريف الخطوط المحلية */
@font-face {
  font-family: "Font Awesome 6 Free";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("../fonts/fa-regular-400.woff2") format("woff2"), 
       url("../fonts/fa-regular-400.ttf") format("truetype");
}

@font-face {
  font-family: "Font Awesome 6 Free";
  font-style: normal;
  font-weight: 900;
  font-display: block;
  src: url("../fonts/fa-solid-900.woff2") format("woff2"), 
       url("../fonts/fa-solid-900.ttf") format("truetype");
}

@font-face {
  font-family: "Font Awesome 6 Brands";
  font-style: normal;
  font-weight: 400;
  font-display: block;
  src: url("../fonts/fa-brands-400.woff2") format("woff2"), 
       url("../fonts/fa-brands-400.ttf") format("truetype");
}

/* الأساسيات */
.fa,
.fas,
.far,
.fal,
.fad,
.fab,
.fak,
.fa-solid,
.fa-regular,
.fa-light,
.fa-thin,
.fa-duotone,
.fa-brands,
.fa-kit {
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  display: var(--fa-display, inline-block);
  font-style: normal;
  font-variant: normal;
  line-height: 1;
  text-rendering: auto;
}

.fas,
.fa-solid {
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
}

.far,
.fa-regular {
  font-family: "Font Awesome 6 Free";
  font-weight: 400;
}

.fab,
.fa-brands {
  font-family: "Font Awesome 6 Brands";
  font-weight: 400;
}

/* الأحجام */
.fa-xs {
  font-size: 0.75em;
  line-height: 0.08333em;
  vertical-align: 0.125em;
}

.fa-sm {
  font-size: 0.875em;
  line-height: 0.07143em;
  vertical-align: 0.05357em;
}

.fa-lg {
  font-size: 1.25em;
  line-height: 0.05em;
  vertical-align: -0.075em;
}

.fa-xl {
  font-size: 1.5em;
  line-height: 0.04167em;
  vertical-align: -0.125em;
}

.fa-2x {
  font-size: 2em;
}

.fa-3x {
  font-size: 3em;
}

.fa-4x {
  font-size: 4em;
}

.fa-5x {
  font-size: 5em;
}

.fa-6x {
  font-size: 6em;
}

.fa-7x {
  font-size: 7em;
}

.fa-8x {
  font-size: 8em;
}

.fa-9x {
  font-size: 9em;
}

.fa-10x {
  font-size: 10em;
}

/* العرض الثابت */
.fa-fw {
  text-align: center;
  width: 1.25em;
}

/* الأيقونات الأساسية */
.fa-home:before { content: "\f015"; }
.fa-tachometer-alt:before { content: "\f3f4"; }
.fa-file-invoice:before { content: "\f570"; }
.fa-money-bill-wave:before { content: "\f53a"; }
.fa-handshake:before { content: "\f2b5"; }
.fa-chart-bar:before { content: "\f080"; }
.fa-building:before { content: "\f1ad"; }
.fa-users:before { content: "\f0c0"; }
.fa-percentage:before { content: "\f295"; }
.fa-cogs:before { content: "\f085"; }
.fa-cog:before { content: "\f013"; }
.fa-database:before { content: "\f1c0"; }
.fa-shield-alt:before { content: "\f3ed"; }
.fa-check-circle:before { content: "\f058"; }
.fa-user:before { content: "\f007"; }
.fa-bell:before { content: "\f0f3"; }
.fa-sign-out-alt:before { content: "\f2f5"; }
.fa-university:before { content: "\f19c"; }
.fa-tools:before { content: "\f7d9"; }
.fa-user-check:before { content: "\f4fc"; }
.fa-hdd:before { content: "\f0a0"; }
.fa-info-circle:before { content: "\f05a"; }
.fa-bolt:before { content: "\f0e7"; }
.fa-history:before { content: "\f1da"; }
.fa-ban:before { content: "\f05e"; }
.fa-file-archive:before { content: "\f1c6"; }
.fa-heart:before { content: "\f004"; }

/* إصلاحات إضافية */
.fa-solid,
.fas {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
}

.fa-regular,
.far {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 400 !important;
}

.fa-brands,
.fab {
  font-family: "Font Awesome 6 Brands" !important;
  font-weight: 400 !important;
}

/* تحسينات للعرض */
i[class^="fa-"],
i[class*=" fa-"] {
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
  font-style: normal !important;
  display: inline-block !important;
  text-rendering: auto !important;
  line-height: 1 !important;
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
}

/* إصلاح خاص للنسبة المئوية */
.fa-percent:before,
.fa-percentage:before {
  content: "\f295";
  font-family: "Font Awesome 6 Free" !important;
  font-weight: 900 !important;
}

/* تحسين الألوان */
.text-primary { color: #0d6efd !important; }
.text-success { color: #198754 !important; }
.text-info { color: #0dcaf0 !important; }
.text-warning { color: #ffc107 !important; }
.text-danger { color: #dc3545 !important; }
.text-secondary { color: #6c757d !important; }

/* تحسين الخلفيات */
.bg-primary { background-color: #0d6efd !important; }
.bg-success { background-color: #198754 !important; }
.bg-info { background-color: #0dcaf0 !important; }
.bg-warning { background-color: #ffc107 !important; }
.bg-danger { background-color: #dc3545 !important; }
.bg-secondary { background-color: #6c757d !important; }

/* تحسين الشفافية */
.bg-opacity-10 { --bs-bg-opacity: 0.1; }
.bg-opacity-15 { --bs-bg-opacity: 0.15; }
.bg-opacity-25 { --bs-bg-opacity: 0.25; }

/* إصلاح مشاكل العرض */
.fa, .fas, .far, .fab {
  visibility: visible !important;
  opacity: 1 !important;
  display: inline-block !important;
}

/* تحسين للأيقونات في الأزرار */
.btn i {
  margin-left: 0.5rem;
}

/* تحسين للأيقونات في القوائم */
.nav-link i {
  margin-left: 0.75rem;
  width: 1.25rem;
  text-align: center;
}

/* تحسين للأيقونات في البطاقات */
.card i {
  font-size: 1.25rem;
}

/* تحسين للأيقونات في الهيدر */
.page-header i {
  font-size: 1.5rem;
  margin-left: 0.75rem;
}

/* تحسين الأفاتار */
.avatar {
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

.avatar i {
  font-size: 1rem;
}

.avatar.avatar-xs {
  width: 1.75rem;
  height: 1.75rem;
}

.avatar.avatar-sm {
  width: 2.25rem;
  height: 2.25rem;
}

.avatar.avatar-md {
  width: 3.5rem;
  height: 3.5rem;
}

.avatar.avatar-lg {
  width: 4.5rem;
  height: 4.5rem;
}

.avatar:hover {
  transform: scale(1.1);
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.2);
}