@font-face {
  font-family: VazirmatnVF;
  src: url("font/VazirMatn/VazirmatnVF.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/*
 * Universal Persian font for RTL admin.
 * Uses a broad selector with icon exclusions to ensure
 * consistent Persian typography across all admin plugins
 * without needing to enumerate every element type.
 */
html[dir="rtl"] *:not(pre):not(code):not(kbd):not(svg):not(#newcontent):not([class*="fa-"]):not([class*="bi-"]):not([class*="ion-"]):not([class*="material"]):not([class*="icon"]):not([class*="glyphicon"]):not([class*="CodeMirror"]):not([class*="cm-"]):not([class*="monaco-"]) {
    font-family: 'VazirmatnVF', sans-serif !important;
}

/* Preserve Dashicons font */
.dashicons,
.dashicons-before:before,
span.dashicons,
#wpadminbar .ab-icon:before,
#wpadminbar .dashicons {
    font-family: "dashicons" !important;
}

/* Preserve monospace for code elements */
html[dir="rtl"] pre,
html[dir="rtl"] pre *,
html[dir="rtl"] kbd,
html[dir="rtl"] code,
html[dir="rtl"] code *,
html[dir="rtl"] #newcontent,
html[dir="rtl"] .CodeMirror-lines,
html[dir="rtl"] .CodeMirror-lines *,
html[dir="rtl"] .monaco-editor,
html[dir="rtl"] .monaco-editor * {
    font-family: monospace !important;
}

/* Prevent SVG content from inheriting custom fonts */
svg, svg * {
    font-family: inherit !important;
}

/* Font weight adjustments for variable font */
.plugins .inactive .plugin-title strong {
    font-weight: 400 !important;
    font-variation-settings: "wght" 400 !important;
}
#adminmenu .wp-submenu li.current,
#adminmenu .wp-submenu li.current a,
#adminmenu .wp-submenu li.current a:hover,
#comment-status-display,
#dashboard_right_now .versions .b,
#ed_reply_toolbar #ed_reply_strong,
#pass-strength-result.short,
#pass-strength-result.strong,
#post-status-display,
#post-visibility-display,
.feature-filter .feature-name,
.item-controls .item-order a,
.media-item .percent,
.plugins .name,
.row-title,
.plugin-title strong,
#editable-post-name,
.post-state,
h1.wp-heading-inline {
    font-variation-settings: "wght" 650 !important;
    font-weight: 400 !important;
}