/* تحميل Font Awesome للزوار (القالب أحياناً ما بيحمله إلا للأدمن) */
@import url("https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css");

/* =========================
   توحيد الفونت ببعض الأقسام
   ========================= */
#menu-topbar,
.penci-footer-text-wrap,
.penci-post-subtitle,
.saboxplugin-authorname,
.topbar__trending,
.penci-post-excerpt,
.footer__copyright_menu,
.has-inline-color,
.has-black-color,
.penci-weather-condition,
.penci-weather-week,
.penci-weather-degrees-wrap,
.penci-weather-city,
.wpb_column,
.penci-cat-links,
#recent-posts-1,
#categories-2,
#wp-calendar {
    font-family: "Droid Serif","Cairo",sans-serif;
}

.penci-post-subtitle,
.penci-cat-links,
#recent-posts-1,
#categories-2,
.has-inline-color,
.has-black-color {
    font-size: large;
}

.penci-topbar {
    height: 34px;
    line-height: 38px;
    text-align: center;
}

/* =========================
   Grid نسبة 3:4 بقسم معيّن
   ========================= */
body.category-opinions-tree .penci-post-item .penci-thumb,
body.category-opinions-tree .penci-post-item .penci-image-holder,
body.category-opinions-tree .penci-post-item .penci-post-thumbnail,
body.category-opinions-tree .penci-grid .penci-thumb,
body.category-opinions-tree .penci-grid .penci-image-holder {
    aspect-ratio: 3/4;
    height: auto;
    padding-top: 0 !important;
    overflow: hidden;
    position: relative;
}

body.category-opinions-tree .penci-post-item .penci-thumb > a,
body.category-opinions-tree .penci-post-item .penci-image-holder > a {
    display: block;
    width: 100%;
    height: 100%;
}

body.category-opinions-tree .penci-post-item .penci-thumb img,
body.category-opinions-tree .penci-post-item .penci-image-holder img,
body.category-opinions-tree .penci-grid .penci-thumb img,
body.category-opinions-tree .penci-grid .penci-image-holder img,
body.category-opinions-tree img.wp-post-image {
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    object-position: center;
    display: block;
    max-width: none !important;
    max-height: none !important;
}

/* fallback لو المتصفح ما بيدعم aspect-ratio */
@supports not (aspect-ratio: 1/1) {
    body.category-opinions-tree .penci-post-item .penci-thumb,
    body.category-opinions-tree .penci-post-item .penci-image-holder,
    body.category-opinions-tree .penci-grid .penci-thumb,
    body.category-opinions-tree .penci-grid .penci-image-holder {
        height: 0 !important;
        padding-top: 133.333% !important; /* 4/3 × 100% */
        position: relative;
        overflow: hidden;
    }

    body.category-opinions-tree .penci-post-item .penci-thumb > a,
    body.category-opinions-tree .penci-post-item .penci-image-holder > a {
        position: absolute;
        inset: 0;
    }

    body.category-opinions-tree .penci-post-item .penci-thumb img,
    body.category-opinions-tree .penci-post-item .penci-image-holder img,
    body.category-opinions-tree .penci-grid .penci-thumb img,
    body.category-opinions-tree .penci-grid .penci-image-holder img {
        position: absolute;
        inset: 0;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover;
        object-position: center;
    }
}

/* =========================
   قائمة "المزيد…" بالهيدر
   ========================= */
#main-navigation .menu > li.echo-more > a,
.main-navigation .menu > li.echo-more > a,
.penci-main-menu .menu > li.echo-more > a {
    cursor: pointer;
}

/* إظهار الساب منيو على الهوفر */
#main-navigation .menu > li.echo-more:hover > .sub-menu,
.main-navigation .menu > li.echo-more:hover > .sub-menu,
.penci-main-menu .menu > li.echo-more:hover > .sub-menu {
    display: block;
    opacity: 1;
    visibility: visible;
}

/* ضبط خصائص الساب منيو */
#main-navigation .menu > li.echo-more .sub-menu,
.main-navigation .menu > li.echo-more .sub-menu,
.penci-main-menu .menu > li.echo-more .sub-menu {
    min-width: 200px;
    z-index: 9999;
}

/* =========================
   Topbar (المستطيل الرمادي فوق) موبايل
   حتى ما ينكسر التاريخ + السوشال على سطرين
   ========================= */
@media (max-width: 992px) {
    .penci-topbar {
        height: auto !important;
        line-height: 1.4 !important;
        text-align: initial !important;
    }

    .penci-topbar .topbar__inner,
    .penci-topbar .penci-container,
    .penci-topbar .container {
        display: flex !important;
        flex-wrap: nowrap !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 8px;
    }

    .penci-topbar .topbar__left,
    .penci-topbar .penci-date,
    .penci-topbar .topbar__trending {
        flex: 1 1 auto !important;
        min-width: 0 !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    .penci-topbar .topbar__right,
    .penci-topbar .penci-topbar-right,
    .penci-topbar .penci-socials,
    .penci-topbar .social-icons {
        display: flex !important;
        flex: 0 0 auto !important;
        align-items: center !important;
        gap: 8px;
        white-space: nowrap !important;
    }

    .penci-topbar .penci-socials li,
    .penci-topbar .social-icons li {
        flex: 0 0 auto !important;
    }

    .penci-topbar .topbar__search,
    .penci-topbar .penci-search,
    .penci-topbar .header-search {
        flex: 0 0 auto !important;
    }
}

/* =========================
   القوائم المنسدلة (Submenu / Mega menu)
   حتى ما تختفي ورا حدود الـheader
   ========================= */
.main-navigation,
#site-navigation,
.penci-main-menu,
.main-navigation .menu,
#main-navigation .menu {
    overflow: visible !important; /* لا تقص القوائم المنسدلة */
}

.main-navigation .menu > li,
#main-navigation .menu > li,
.penci-main-menu .menu > li {
    position: relative;
}

.main-navigation .menu > li > ul.sub-menu,
#main-navigation .menu > li > ul.sub-menu,
.penci-main-menu .menu > li > ul.sub-menu,
.main-navigation .menu > li.echo-more > ul.sub-menu {
    z-index: 9999 !important;
    visibility: hidden;
    opacity: 0;
    display: block;
    pointer-events: none;
    transition: opacity .15s ease;
}

/* ديسكتوب: أظهر الساب منيو بالهوفر */
@media (min-width: 1025px) {
    .main-navigation .menu > li:hover > ul.sub-menu,
    #main-navigation .menu > li:hover > ul.sub-menu,
    .penci-main-menu .menu > li:hover > ul.sub-menu,
    .main-navigation .menu > li.echo-more:hover > ul.sub-menu {
        visibility: visible;
        opacity: 1;
        pointer-events: auto;
    }
}

/* RTL: الساب منيو ينفتح يمين */
html[dir="rtl"] .main-navigation .menu > li > ul.sub-menu,
html[dir="rtl"] #main-navigation .menu > li > ul.sub-menu,
html[dir="rtl"] .penci-main-menu .menu > li > ul.sub-menu {
    right: 0;
    left: auto;
}

/* كمان كررنا الكيرسور للـ ...المزيد */
.main-navigation .menu > li.echo-more > a,
#main-navigation .menu > li.echo-more > a {
    cursor: pointer;
}

/* =========================
   حل مشكلة تغيّر الخط على التابلت
   (900px - 1280px) قفل الخط على Cairo
   بدون ما نخرب الأيقونات
   ========================= */
@media (min-width: 900px) and (max-width: 1280px) {

    body,
    body *:not(i):not(svg):not(path):not([class*="fa-"]):not(.fa):not(.fab):not(.fas):not(.far) {
        font-family: "Cairo", "Droid Serif", sans-serif !important;
        font-weight: 400 !important;
        font-style: normal !important;
    }

    /* العناوين الغليظة */
    h1, h2, h3, h4, h5, h6,
    .penci-block__title,
    .penci-entry-title,
    .penci-page-title,
    .penci__post-title,
    .entry-title {
        font-weight: 700 !important;
        font-family: "Cairo", "Droid Serif", sans-serif !important;
    }

    /* عناوين السلايدر وأول بلوك أخبار */
    .penci-slider__text,
    .penci-slider__text *,
    .penci-featured-content *,
    .penci-featured-content .entry-title a,
    .penci-featured-content .entry-title {
        font-family: "Cairo", "Droid Serif", sans-serif !important;
        font-weight: 700 !important;
    }

    /* الميتا (التاريخ - الكاتب - عدد المشاهدات...) */
    .penci_post-meta,
    .penci_post-meta *,
    .penci_post-meta .author,
    .penci_post-meta .entry-meta-item,
    .penci_post-meta .penci-posted-on,
    .penci_post-meta .penci-post-countview-number {
        font-family: "Cairo", "Droid Serif", sans-serif !important;
        font-weight: 400 !important;
    }

    /* التوب بار الرمادي تحت اللوغو */
    .penci-topbar,
    .penci-topbar *,
    .topbar__trending,
    .topbar__trending * {
        font-family: "Cairo", "Droid Serif", sans-serif !important;
        font-weight: 400 !important;
        line-height: 34px !important;
        height: 34px !important;
    }
}

/* =========================
   تكبير خط قائمة الفوتر السفلية
   ========================= */
#menu-footer-menu.menu,
#menu-footer-menu.menu li,
#menu-footer-menu.menu li a {
    font-size: 18px !important;
    line-height: 1.6 !important;
}





/* ====== ECHO SHARE CLEAN FINAL ====== */

/* اخفي أي شير افتراضي من القالب أو من إضافات ثانية */
.penci-social-buttons,
.penci-post-share,
.penci-social-share-footer,
.penci-entry-footer .penci-social-buttons,
.penci-entry-footer .penci-social-share-footer,
.nsv-buttons-wrap,
.ns-buttons,
.ns-facebook,
.ns-twitter,
.ns-whatsapp,
.ns-telegram,
.ns-linkedin {
    display: none !important;
    visibility: hidden !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    line-height: 0 !important;
    font-size: 0 !important;
}

/* صندوق المشاركة الخاص فينا */
.echo-share-bar {
    border: 1px solid #ddd;
    background: #fff;
    padding: 10px;
    margin: 15px 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    direction: ltr; /* ثابت. ما منقلب */
    font-family: "Cairo","Droid Serif",sans-serif;
    font-size: 14px;
    line-height: 1;
}

/* أزرار المنصات */
.echo-share-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    border-radius: 3px;
    text-decoration: none !important;
    font-weight: 700;
    font-size: 14px;
    line-height: 1;
    color: #fff !important;
}

/* الألوان */
.echo-share-email   { background:#777; }
.echo-share-tg      { background:#229ED9; }   /* Telegram */
.echo-share-wa      { background:#25D366; }   /* WhatsApp */
.echo-share-in      { background:#0077B5; }   /* LinkedIn */
.echo-share-x       { background:#000000; }   /* X */
.echo-share-fb      { background:#1877F2; }   /* Facebook */

/* النص جوّا الزر (مو أيقونة فونت، بس نص عادي أو رمز) */
.echo-share-btn span {
    color:#fff !important;
    font-family: "Cairo","Droid Serif",sans-serif;
    font-weight:700;
    font-size:14px;
    line-height:1;
    display:block;
}

/* بلوكات العدّاد (المشاهدة/اللايك) – حالياً ديكور فقط */
.echo-share-meta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border: 1px solid #ddd;
    border-radius: 3px;
    background: #fff;
    padding: 0 8px;
    height: 32px;
    line-height: 32px;
    font-size: 14px;
    color: #000;
    font-weight: 400;
    font-family: "Cairo","Droid Serif",sans-serif;
}

.echo-share-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
    line-height: 1;
    font-size: 14px;
    color: #000;
    font-weight: 400;
}

.echo-share-meta-item i {
    font-style: normal;
    font-weight: 700;
    font-size: 14px;
    line-height: 1;
}

/* كلمة "مشاركة" بالعربي نحطها بأقصى يمين الشريط */
.echo-share-label {
    margin-inline-start: auto; /* يدفشها لنهاية السطر */
    font-size: 14px;
    font-weight: 600;
    color: #000;
    direction: rtl;
    line-height: 1;
    font-family: "Cairo","Droid Serif",sans-serif;
}

/* موبايل: خليه ينزل عمودي بدل ما ينفجر */
@media (max-width: 480px){
    .echo-share-bar {
        flex-direction: column;
        align-items: flex-start;
        gap:10px;
    }
    .echo-share-label {
        margin-inline-start: 0;
        order:3;
        width:100%;
        text-align:right;
        font-size:14px;
    }
    .echo-share-buttons {
        order:1;
        flex-wrap: wrap;
        display:flex;
        gap:6px;
    }
    .echo-share-meta {
        order:2;
    }
}





/* موبايل: خفّ التباعد شوي */
@media (max-width: 480px){
    .penci-social-buttons,
    .penci-social-share-footer,
    .penci-entry-footer .penci-social-buttons {
        gap: 4px !important;
        row-gap: 4px !important;
    }
    .penci-social-buttons .pinci-post-like,
    .penci-social-buttons .penci-post-like-count,
    .penci-social-buttons .penci-post-share-count {
        font-size: 13px !important;
    }
}






/* ====== Echo Share Bar FINAL ====== */

/* الحاوية الأساسية */
.echo-share-bar {
    display: flex;
    flex-wrap: wrap;          /* يسمح ينزل على سطر تاني إذا ضاق العرض */
    flex-direction: row;
    align-items: center;
    column-gap: 6px;
    row-gap: 6px;

    border: 1px solid #dedede;
    border-radius: 3px;
    background: #fff;
    padding: 6px 8px;
    margin: 8px 0;

    line-height: 1;
    font-family: "Cairo","Droid Serif",sans-serif;
    font-size: 14px;
}

/* زر المشاركة الواحد */
.echo-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;

    border-radius: 2px;
    font-weight: 700;
    font-size: 14px;
    line-height: 1;
    text-decoration: none !important;

    color: #fff !important;
    background: #000;
    box-shadow: none;
    border: 0;
    cursor: pointer;
}

/* ألوان المنصات */
.echo-email    { background:#777 !important; }
.echo-telegram { background:#229ED9 !important; }
.echo-whatsapp { background:#25D366 !important; }
.echo-linkedin { background:#0077B5 !important; }
.echo-x        { background:#000000 !important; }
.echo-facebook { background:#1877F2 !important; }

/* نص كلمة مشاركة */
.echo-share-label {
    font-weight: 600;
    font-size: 14px;
    line-height: 1;
    color: #000;

    font-family: "Cairo","Droid Serif",sans-serif;
    margin-inline-start: 6px;
    white-space: nowrap; /* خلّيها كلمة وحدة */
}

/* تصغير لطيف وتحكم بطريقة اللف على الشاشات الضيّقة (موبايل واقف) */
@media (max-width:600px){
    .echo-share-bar {
        padding: 8px;
        column-gap: 8px;
        row-gap: 8px;
        justify-content: flex-start;
    }

    .echo-share-btn {
        width: 36px;
        height: 36px;
        min-width: 36px;
        min-height: 36px;
        font-size: 15px;
        border-radius: 3px;
    }

    .echo-share-label {
        order: 99;              /* حط كلمة "مشاركة" آخر شي بالصف */
        font-size: 15px;
    }
}



/* محاذاة شريط المشاركة بالمنتصف */
.echo-share-bar {
    justify-content: center;  /* وسّط داخلياً */
    direction: ltr;           /* نخلي ترتيب الأزرار ثابت (✉ TG WA in X f) */
    text-align: center;
    width: 100%;
    max-width: 100%;
}

/* خف المسافة بين كلمة "مشاركة" والزر الأخير لأنه بالوسط */
.echo-share-label {
    order: 99;
    margin-inline-start: 8px;
    margin-inline-end: 0;
}








/* >>> Targeted override for https://echo-sy.com/archives/category/opinions <<< */
/* Applies only on the Opinions archive (body.category-opinions) and only on screens <=1280px */
/* Force horizontal "media object" card: image (40%) + text (60%) */

@media (max-width:1280px){
  /* Force each post card to a single row */
  body.archive.category.category-opinions .penci-grid .penci-post-item,
  body.category.category-opinions .penci-grid .penci-post-item,
  body.archive.category.category-opinions .penci-archive__content .penci-post-item,
  body.category.category-opinions .penci-archive__content .penci-post-item{
    width: 100% !important;
    display: flex !important;
    flex-direction: row !important;
    align-items: flex-start !important;
    gap: 12px !important;
  }

  /* IMAGE BLOCK (robust selectors for different PenNews modules) */
  body.category-opinions .penci-post-item .penci-thumb,
  body.category-opinions .penci-post-item .penci-post-thumbnail,
  body.category-opinions .penci-post-item .penci-image-holder,
  body.category-opinions .penci-post-item .penci__thumb,
  body.category-opinions .penci-post-item .penci__image-holder{
    flex: 0 0 40% !important;
    max-width: 40% !important;
    width: 40% !important;
    height: auto !important;
    padding-top: 0 !important;      /* cancel ratio hacks */
    margin: 0 !important;
    position: relative !important;
    overflow: hidden !important;
    aspect-ratio: 3/4 !important;   /* portrait */
  }

  /* Kill pseudo padding hacks that enforce tall boxes */
  body.category-opinions .penci-post-item .penci-thumb:before,
  body.category-opinions .penci-post-item .penci-image-holder:before,
  body.category-opinions .penci-post-item .penci-post-thumbnail:before{
    content: none !important;
    display: none !important;
  }

  /* IMG fill */
  body.category-opinions .penci-post-item .penci-thumb img,
  body.category-opinions .penci-post-item .penci-post-thumbnail img,
  body.category-opinions .penci-post-item .penci-image-holder img{
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center !important;
    display: block !important;
  }

  /* TEXT BLOCK */
  body.category-opinions .penci-post-item .penci__content,
  body.category-opinions .penci-post-item .penci-content{
    flex: 1 1 60% !important;
    max-width: 60% !important;
    width: 60% !important;
  }

  /* Title & excerpt tweaks */
  body.category-opinions .penci-post-item .entry-title{
    margin: 0 0 6px !important;
    line-height: 1.3 !important;
    font-weight: 700 !important;
  }
  body.category-opinions .penci-post-item .penci-post-excerpt{
    margin: 0 !important;
    line-height: 1.5 !important;
  }
}






/* Self-hosted Rubik Arabic (guaranteed Arabic glyphs) */
@font-face{
  font-family: 'RubikArabic'; font-style: normal; font-weight: 400; font-display: swap;
  src: url('/wp-content/uploads/echo-custom/fonts/RubikArabic-Regular.woff2') format('woff2');
}
@font-face{
  font-family: 'RubikArabic'; font-style: normal; font-weight: 500; font-display: swap;
  src: url('/wp-content/uploads/echo-custom/fonts/RubikArabic-Medium.woff2') format('woff2');
}
@font-face{
  font-family: 'RubikArabic'; font-style: normal; font-weight: 700; font-display: swap;
  src: url('/wp-content/uploads/echo-custom/fonts/RubikArabic-Bold.woff2') format('woff2');
}

/* Apply to body text only (keep your headings as Cairo if أردت) */
html[dir="rtl"] body,
body .entry-content { font-family: 'RubikArabic','Cairo',system-ui,-apple-system,"Segoe UI",sans-serif !important; }

/* وزن افتراضي مريح للقراءة */
body .entry-content { font-weight: 400; line-height: 1.9; }
