/* =========================
   Font Face Definitions
   ========================= */
@font-face {
  font-family: 'YekanBakh-Regular';
  src: url('../fonts/YekanBakh-Regular.eot');
  src: url('../fonts/YekanBakh-Regular.eot?#iefix') format('embedded-opentype'),
       url('../fonts/YekanBakh-Regular.woff2') format('woff2'),
       url('../fonts/YekanBakh-Regular.woff') format('woff'),
       url('../fonts/YekanBakh-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'YekanBakh-Thin';
  src: url('../fonts/YekanBakh-Thin.woff') format('woff');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* Widget Icon Styles - Pharmacy Pro Theme */

/* Ensure Font Awesome icons load properly in widgets */
.widget {
    position: relative;
    font-family: 'YekanBakh-Regular', Arial, sans-serif !important;
}

/* Prevent font inheritance for icons (including fa-thin) */
.widget i[class*="fa-"],
.widget i[class*="fas"],
.widget i[class*="far"],
.widget i[class*="fab"],
.widget i[class*="fal"],
.widget i[class*="fad"],
.widget i[class*="fa-thin"],
.widget i[class*="thin"][class*="fa-"] {
    font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
    font-weight: 900 !important;
    font-style: normal !important;
    font-variant: normal !important;
    text-rendering: auto !important;
    line-height: 1 !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
    display: inline-block !important;
}

/* Widget title icons */
.widget-title i {
    margin-left: 8px;
    font-size: 16px;
    color: #2c5aa0;
    vertical-align: middle;
}

/* General widget icon styles - already defined above */

/* Specific widget icon positioning */
.widget ul li i {
    margin-left: 8px;
    color: #666;
    font-size: 14px;
}

.widget ul li:hover i {
    color: #2c5aa0;
    transition: color 0.3s ease;
}

/* Footer widget icons */
.footer-widget i {
    color: #fff;
    opacity: 0.8;
}

.footer-widget i:hover {
    opacity: 1;
    transition: opacity 0.3s ease;
}

/* Sidebar widget icons */
.sidebar .widget i {
    color: #2c5aa0;
}

/* Shop sidebar widget icons */
.shop-sidebar .widget i {
    color: #28a745;
}

/* Text widget icon support */
.widget_text i {
    margin: 0 5px;
    color: #2c5aa0;
}

/* Custom HTML widget icon support */
.widget_custom_html i {
    margin: 0 5px;
    color: #2c5aa0;
}

/* Recent posts widget icons */
.widget_recent_entries ul li:before {
    content: "\f1ea";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Categories widget icons */
.widget_categories ul li:before {
    content: "\f07b";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Archives widget icons */
.widget_archive ul li:before {
    content: "\f187";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Search widget icon */
.widget_search .search-form:before {
    content: "\f002";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    pointer-events: none;
}

/* Tag cloud widget icons */
.widget_tag_cloud a:before {
    content: "\f02b";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 5px;
    color: #2c5aa0;
}

/* Calendar widget icon */
.widget_calendar caption:before {
    content: "\f073";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* RSS widget icon */
.widget_rss .rsswidget:before {
    content: "\f09e";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #ff6600;
}

/* Meta widget icons */
.widget_meta ul li:before {
    content: "\f0c0";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Pages widget icons */
.widget_pages ul li:before {
    content: "\f15c";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Comments widget icons */
.widget_recent_comments ul li:before {
    content: "\f075";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Navigation menu widget icons */
.widget_nav_menu ul li:before {
    content: "\f0c9";
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    margin-left: 8px;
    color: #2c5aa0;
}

/* Ensure icons are visible and properly styled */
.widget i[class*="fa-"]:not([class*="fa-spin"]):not([class*="fa-pulse"]) {
    animation: none;
}

/* Loading state for async Font Awesome */
.widget i[class*="fa-"]:not(.loaded) {
    opacity: 0;
    transition: opacity 0.3s ease;
}

.widget i[class*="fa-"].loaded {
    opacity: 1;
}

/* Fallback for when Font Awesome fails to load */
@font-face {
    font-family: 'FontAwesome-Fallback';
    src: url('data:font/woff2;base64,') format('woff2');
    font-display: swap;
}

.widget i[class*="fa-"]:not([style*="font-family"]) {
    font-family: 'FontAwesome-Fallback', sans-serif;
}

/* Responsive widget icons */
@media (max-width: 768px) {
    .widget i {
        font-size: 14px;
    }
    
    .widget-title i {
        font-size: 14px;
    }
}

/* Dark mode support for widget icons */
@media (prefers-color-scheme: dark) {
    .widget i {
        color: #60a5fa;
    }
    
    .widget ul li:hover i {
        color: #93c5fd;
    }
}
