:root {
  --sf-primary: #c62828;
  --sf-font: Tahoma, "Segoe UI", "Iranian Sans", system-ui, sans-serif;
  --sf-bar-h: 56px;
}
body.sahifa-pro, body.rtl-ready, body {
  font-family: var(--sf-font) !important;
  direction: rtl;
  text-align: right;
  color: #1a1a1a !important;
  line-height: 1.8;
}
h1,h2,h3,h4,h5,h6,.post-title,.post-title a,.widget-title {
  font-family: var(--sf-font) !important;
  color: #111 !important;
  opacity: 1 !important;
}
a[href], .post-title a, article a {
  pointer-events: auto !important;
  cursor: pointer !important;
  position: relative;
  z-index: 3 !important;
}
.theme-notice, a[href*="hamyarwp"], a[href*="tielabs.com/buy"] {
  display: none !important;
}

.sf-mobile-bar {
  display: none; position: sticky; top: 0; z-index: 100000;
  height: var(--sf-bar-h); background: #1a1a1a; color: #fff;
  align-items: center; justify-content: space-between; padding: 0 12px;
  box-shadow: 0 2px 12px rgba(0,0,0,.3);
}
.sf-mobile-bar .sf-brand {
  flex: 1; text-align: center; font-weight: 700; font-size: 16px;
  color: #fff !important; text-decoration: none !important;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-family: var(--sf-font) !important;
}
.sf-menu-toggle, .sf-search-toggle {
  width: 44px; height: 44px; border: 0; background: transparent; color: #fff;
  font-size: 20px; cursor: pointer; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
}
.sf-drawer-overlay {
  display: none !important; position: fixed; inset: 0;
  background: rgba(0,0,0,.55); z-index: 100010; pointer-events: none;
}
.sf-drawer-overlay.is-open { display: block !important; pointer-events: auto; }
.sf-drawer {
  display: none !important; position: fixed; top: 0; right: 0;
  width: min(320px, 86vw); height: 100%; background: #111; color: #fff;
  z-index: 100011; overflow-y: auto; -webkit-overflow-scrolling: touch;
  box-shadow: -4px 0 24px rgba(0,0,0,.3); pointer-events: none;
}
.sf-drawer.is-open { display: block !important; pointer-events: auto; }
.sf-drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px; background: var(--sf-primary); position: sticky; top: 0; z-index: 2;
}
.sf-drawer-title {
  font-weight: 700; font-size: 15px; margin: 0; color: #fff;
  font-family: var(--sf-font) !important;
  max-width: 75%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.sf-drawer-close {
  width: 40px; height: 40px; border: 0; background: rgba(255,255,255,.15);
  color: #fff; font-size: 22px; border-radius: 8px; cursor: pointer;
}
.sf-drawer-nav, ul.sf-drawer-nav {
  list-style: none !important; margin: 0 !important; padding: 8px 0 40px !important;
}
.sf-drawer-nav li { border-bottom: 1px solid rgba(255,255,255,.08); list-style: none !important; }
.sf-drawer-nav a {
  display: block; padding: 14px 18px; color: #f0f0f0 !important;
  text-decoration: none !important; font-size: 15px; font-family: var(--sf-font) !important;
}
.sf-drawer-nav a:hover, .sf-drawer-nav .current-menu-item > a {
  background: rgba(198,40,40,.35); color: #fff !important;
}
.sf-drawer-nav .sub-menu {
  list-style: none !important; margin: 0 !important; padding: 0 !important; background: #0a0a0a;
}
.sf-drawer-nav .sub-menu a { padding-right: 32px; font-size: 14px; color: #ccc !important; }
.sf-mobile-search {
  display: none !important; position: fixed; top: var(--sf-bar-h); left: 0; right: 0;
  z-index: 100005; background: #fff; padding: 12px; box-shadow: 0 4px 16px rgba(0,0,0,.12);
  pointer-events: none;
}
.sf-mobile-search.is-open { display: block !important; pointer-events: auto; }
.sf-mobile-search form { display: flex; gap: 8px; }
.sf-mobile-search input[type="search"] {
  flex: 1; border: 1px solid #e4e6eb; border-radius: 8px; padding: 10px 14px;
  font-family: var(--sf-font); font-size: 15px;
}
.sf-mobile-search button {
  background: var(--sf-primary); color: #fff; border: 0; border-radius: 8px;
  padding: 0 16px; font-weight: 700; cursor: pointer;
}
body.sf-drawer-open { overflow: hidden; }

@media (max-width: 991px) {
  .sf-mobile-bar { display: flex !important; visibility: visible !important; }
  #slide-out-open, #slide-out { display: none !important; pointer-events: none !important; }
}
@media (min-width: 992px) {
  .sf-mobile-bar, .sf-drawer, .sf-drawer-overlay, .sf-mobile-search {
    display: none !important; pointer-events: none !important;
  }
}

.entry-content table, .post-inner table, article table, .wp-block-table table {
  width: 100% !important; border-collapse: collapse !important;
  margin: 1.2em 0 !important; background: #fff; color: #1a1a1a !important;
}
.entry-content table th, .entry-content table td,
article table th, article table td {
  padding: 10px 12px !important; border: 1px solid #dde1e6 !important;
  text-align: right !important; color: #1a1a1a !important;
}
.entry-content table th, article table th {
  background: #f0f2f5 !important; font-weight: 700 !important;
}
.entry-content, .post-inner {
  overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%;
}
@media (max-width: 767px) {
  .entry-content table, article table {
    display: block !important; min-width: 480px; font-size: 13px !important;
  }
  body { font-size: 15px !important; }
  .post-title, .post-title a { font-size: 1.12rem !important; }
  .container { max-width: 100% !important; padding-left: 12px !important; padding-right: 12px !important; }
  #sidebar, .sidebar { width: 100% !important; float: none !important; margin-top: 24px; }
}
