/* =====================================================
   Omar WooCommerce Only CSS
   هذا الملف يتحمل فقط في صفحات WooCommerce
   ولا يتحمل في صفحات المقالات
===================================================== */

/* =====================================================
   381003 - margin-bottom Rating Stars Next The Title (CSS)
===================================================== */
div.product .woocommerce-product-rating {
    margin-bottom: 1em;
    clear: both;
}
/* =====================================================
   381253 - تقليل المسافات البينية بين المنتجات في كل الموقع
===================================================== */
@media screen and (max-width: 768px) {
  /* ✅ تقليل المسافات بين كل المنتجات في جميع تصنيفات الأرشيف */
  body.archive.tax-product_cat ul.products {
      gap: 5px;
      padding: 0px;
  }

  /* ✅ ضبط هوامش كل منتج */
  body.archive.tax-product_cat ul.products li.product {
      margin: 0px;
      padding: 0px;
      text-align: center;
  }
}
/* =====================================================
   381260 - Hide the pagination For Infinty Scrolling (Css)
===================================================== */
/* Hide pagination visually only on WooCommerce archive/category pages */
body.archive.woocommerce .woocommerce-pagination {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
/* =====================================================
   381264 - ازالة Title من ال Categories
===================================================== */
/* 🔒 إخفاء جميع H1 من رأس صفحات المتجر بدون التأثير على SEO */
.woocommerce-products-header__title.page-title {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  padding: 0;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
  border: 0;
}
/* =====================================================
   381284 - تقصير طول العنوان ... (CSS)
===================================================== */
.woocommerce-loop-product__title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
  line-height: 1.4;
  max-height: calc(1.4em * 2); /* 👈 سطرين فقط بدقة */
}
/* =====================================================
   381288 - عكس ليبول الخصم الاوريجينال فوق و ال New تحت (css)
===================================================== */
.ckit-badge_wrapper {
  flex-direction: column-reverse !important;
}


/* ✅ اللافتات */
.ckit-badge_wrapper {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  display: flex !important;
  /* flex-direction: column-reverse !important;  شيلت السطر ده */
  gap: 0px !important;
  z-index: 2 !important;
  align-items: flex-start !important;
}

/* 🔽 حجم الليبولات على الموبايل فقط */
@media screen and (max-width: 768px) {
  .ckit-badge {
    font-size: 10px !important;
    padding: 2px 6px !important;
    border-radius: 4px !important;
  }
}
/* =====================================================
   382158 - Flying Add to card Car to the cart (Css)
===================================================== */
.fly-cart {
  position: absolute;
  z-index: 999999;
  pointer-events: none;
}

.cart-bounce {
  animation: cartBounceAnim 0.4s ease;
}

@keyframes cartBounceAnim {
  0%,100% { transform: scale(1); }
  50% { transform: scale(1.5); }
}

.added_to_cart.wc-forward {
  display: none !important;
}
/* =====================================================
   382272 - Title - Price - Fonts-size(single product - archive page) On Mobile (CSS)
===================================================== */
@media (max-width: 767px) {
    /* السعر للمنتجات باللغة العربية */
    .archive.woocommerce ul.products li.product .price:lang(ar) {
        font-family: 'Cairo', sans-serif;
        font-size: 14px !important;
        font-weight: 650 !important; /* وسط بين العادي والـ Bold */
    }

    /* السعر للمنتجات باللغة الإنجليزية */
    .archive.woocommerce ul.products li.product .price:lang(en) {
        font-family: 'Arial', sans-serif; /* أو أي خط تاني تحبه */
        font-size: 14px !important;
        font-weight: 500 !important;
    }

    /* عنوان المنتج - نفس الخط في جميع اللغات */
    .archive.woocommerce ul.products li.product .woocommerce-loop-product__title {
        font-family: 'Cairo', sans-serif;
        font-size: 12.5px !important;
        font-weight: 500 !important;
    }
}



/* السعر بعد الخصم في صفحات الأرشيف */
.archive.woocommerce ul.products li.product .price ins {
    color: red !important;
}

/* السعر قبل الخصم */
.archive.woocommerce ul.products li.product .price del {
    color: #999 !important; /* رمادي */
}








/* added by Omar (single product title font and size) */
@media screen and (max-width: 768px) {
  /* للغات RTL (العربية) */
  [dir="rtl"] .single-product .product_title {
    font-size: 18px !important;
    font-weight: 500 !important;
    font-family: 'Cairo', sans-serif !important;
    padding-left: 4px !important;
    padding-right: 0 !important;
  }

  /* للغات LTR (الإنجليزية) */
  [dir="ltr"] .single-product .product_title {
    font-size: 18px !important;
    font-weight: 500 !important;
    font-family: 'Cairo', sans-serif !important;
    padding-right: 4px !important;
    padding-left: 0 !important;
  }
}
/* =====================================================
   382275 - تنسيق add to card و Buy Now داخل Container (Css) (تعديل رقم 2)
===================================================== */
.woocommerce-card__header .button-group {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: -10px;
  margin-bottom: 30px;
}

.woocommerce-card__header .button-group .add_to_cart_button {
  flex: 0 0 50%;
  text-align: center;
}

.woocommerce-card__header .button-group .wc-buy-now-btn {
  flex: 0 0 44%;
  text-align: center;
}

.woocommerce-card__header .button-group .add_to_cart_button,
.woocommerce-card__header .button-group .wc-buy-now-btn {
  padding: 12px 2px;
  box-sizing: border-box;
  border-radius: 10px !important; /* الحواف لكل الأزرار */
}

@media screen and (max-width: 768px) {
  .woocommerce-card__header .add_to_cart_button,
  .woocommerce-card__header .wc-buy-now-btn {
    font-size: 12.5px !important; 
    font-weight: 600 !important;
    padding: 10px 2px !important;
    height: auto !important;
    min-height: unset !important;
  }
}

/* نسخة اللغة العربية فقط */
@media screen and (max-width: 768px) {
  html[lang="ar"] .woocommerce-card__header .button-group .add_to_cart_button,
  html[lang="ar"] .woocommerce-card__header .button-group .wc-buy-now-btn {
    font-family: 'Cairo', sans-serif;
    font-size: 10px !important;
    font-weight: 800 !important;
  }
}

.added_to_cart.wc-forward {
  display: none !important;
}

/* توحيد علامة الصح في كل الأزرار */
.ajax_add_to_cart.add_to_cart_button.loading:after,
.single-product .product form.cart .single_add_to_cart_button.loading:after {
    content: "✔";
    font-size: 22px;
    color: #fff;
    border: none;
    width: auto;
    height: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    margin: 0; /* إلغاء أي إزاحة قديمة */
    transform: translate(-50%, -50%);
    opacity: 1;
    animation: none !important;
    transition: none;
}
/* =====================================================
   382342 - SKU Color single product page at the top (CSS)
===================================================== */
/* النسخة العربية (RTL) → على الشمال */
html[dir="rtl"] .sku_wrapper {
    text-align: left !important;
    font-size: 12px !important;
    padding-left: 2px !important;
    color: black !important; /* لون النص الأساسي (SKU:) */
}

html[dir="rtl"] .sku_wrapper .sku {
    color: #006566 !important; /* لون الكود */
}

/* النسخة الإنجليزية (LTR) → على اليمين */
html[dir="ltr"] .sku_wrapper {
    text-align: right !important;
    font-size: 12px !important;
    padding-right: 2px !important;
    color: black !important; /* لون النص الأساسي (SKU:) */
}

html[dir="ltr"] .sku_wrapper .sku {
    color: #006566 !important; /* لون الكود */
}
