:root{
  --brand:#7b2ff7; --brand-hover:#6417d8;
  --bn-h:300px; --bn-h-m:200px;
  --cat-gap:14px; --cat-pad:14px; --cat-br:12px; --cat-ic:42px;
  --cat-bg:#fff; --cat-sep:#eee;
}

/* أساسيات آمنة */
*{box-sizing:border-box} html{-webkit-text-size-adjust:100%;scroll-behavior:smooth}
img,video{max-width:100%;height:auto;display:block;object-fit:cover}
@media(prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important;scroll-behavior:auto!important}}

/* البنرات/الهيرو: لا content-visibility عليها لتفادي اختفاء مفاجئ */
.fixed-banner,.hero,.hero-section,.s-block--fixed-banner,.wide-placeholder,.banner,.banner-slider{
  content-visibility:visible!important; contain:auto!important; min-height:var(--bn-h); overflow:hidden;
}
@media(max-width:768px){
  .fixed-banner,.hero,.hero-section,.s-block--fixed-banner,.wide-placeholder,.banner,.banner-slider{min-height:var(--bn-h-m)}
}
.fixed-banner img,.hero img,.hero-section img,.s-block--fixed-banner img,.wide-placeholder img,.banner img,.banner-slider img,.swiper-slide img{
  aspect-ratio:auto!important; width:100%!important; height:auto!important; visibility:visible!important; opacity:1!important;
}

/* منتجات: مربّع 1:1 مع حجز مساحة مسبقاً (يقتل الـCLS) */
.product-card img,.product-item img,.s-product-item img,.products-list img,.s-products .product img{
  width:100%!important; aspect-ratio:1/1!important; object-fit:cover!important; border-radius:10px; transition:transform .25s;
}
.product-card:hover img,.product-item:hover img{transform:scale(1.03)}

/* قائمة التصنيفات على طريقة سلة (مع SVG لاحقاً من JS) */
.cat-list a{display:flex;align-items:center;gap:var(--cat-gap);padding:var(--cat-pad);border-radius:var(--cat-br);background:var(--cat-bg)}
.cat-list li+li{border-top:1px solid var(--cat-sep)}
.cat-list a .cat-ic{flex:0 0 var(--cat-ic);height:var(--cat-ic);display:grid;place-items:center;border-radius:10px;background:#f5f5f7}
.cat-list a .cat-name{flex:1;font-weight:700;color:#111;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cat-list a img{display:none!important} /* نخفي صور التصنيف لتظهر أيقونات الـSVG */

/* أزرار وهوية سريعة */
.btn,button,.salla-button,.add-to-cart-button,.cart-btn{
  background:var(--brand)!important; border-color:var(--brand)!important; color:#fff!important; border:0; border-radius:10px; padding:.6rem 1rem;
}
.btn:hover,.salla-button:hover,.add-to-cart-button:hover,.cart-btn:hover{background:var(--brand-hover)!important;opacity:.9} /* === Perf V2 — CSS (safe) === */
:root{
  --brand:#7b2ff7;--brand-hover:#6417d8;
  --bn-h:300px;--bn-h-m:200px;
}
/* أساسي */
*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%;scroll-behavior:smooth}
body{font-family:system-ui,-apple-system,Segoe UI,Roboto,"Tajawal",Arial,sans-serif;line-height:1.6;color:#111;background:#fff;overflow-x:hidden}
a{text-decoration:none;color:var(--brand)}
h1,h2,h3{word-wrap:break-word}

/* صور وفيديو مع حجز مساحة افتراضي */
img,video{max-width:100%;height:auto;display:block;object-fit:cover}
img:not([width]):not([height]){aspect-ratio:16/9}

/* احجز للبنرات لكن لا تفرض ratio عليها */
.fixed-banner,.hero,.hero-section,.s-block--fixed-banner,.wide-placeholder{
  min-height:var(--bn-h);overflow:hidden;contain:layout paint;
  content-visibility:visible; /* لا تُخفى */
}
@media(max-width:768px){
  .fixed-banner,.hero,.hero-section,.s-block--fixed-banner,.wide-placeholder{min-height:var(--bn-h-m)}
}
/* البنرات: لا تطبق ratio العام */
.fixed-banner img:not([width]):not([height]),
.hero img:not([width]):not([height]),
.hero-section img:not([width]):not([height]),
.s-block--fixed-banner img:not([width]):not([height]),
.wide-placeholder img:not([width]):not([height]){aspect-ratio:auto}

/* شكل صور المنتجات (مربعة متناسقة) */
.product-card img,.products-list img,.s-products .product img,.product-item img,.s-product-item img{
  width:100%;aspect-ratio:1/1;object-fit:cover;border-radius:10px;transition:transform .25s ease;
}
.product-card:hover img,.product-item:hover img{transform:scale(1.03)}

/* أزرار وهوية لونية بسيطة */
.btn,button,.salla-button,.add-to-cart-button,.cart-btn{
  background:var(--brand)!important;border-color:var(--brand)!important;color:#fff!important;
  border:0;border-radius:10px;padding:.6rem 1rem;cursor:pointer;transition:opacity .15s
}
.btn:hover,button:hover,.salla-button:hover,.add-to-cart-button:hover,.cart-btn:hover{
  background:var(--brand-hover)!important;border-color:var(--brand-hover)!important;color:#fff!important;opacity:.9
}

/* Lazy blur لطيف */
.lazyload{filter:blur(10px);transition:filter .4s ease}
.lazyloaded{filter:blur(0)}

/* تقليل الحركة */
@media(prefers-reduced-motion:reduce){
  *{animation:none!important;transition:none!important;scroll-behavior:auto!important}
}

/* تصحيح شائع للسلايدر */
.swiper,.swiper-container{overflow:visible}
.swiper-wrapper{align-items:stretch}
.swiper-slide{height:auto;min-height:200px} /* === Safe CSS (لا تغيّر روابط/سلوك – فقط تنعيم عرض الصور) === */
:root{--brand:#7b2ff7;--brand-hover:#6417d8}

/* أساسيات خفيفة */
*{box-sizing:border-box;margin:0;padding:0}
html{-webkit-text-size-adjust:100%;scroll-behavior:smooth}
body{font-family:system-ui,-apple-system,Segoe UI,Roboto,"Tajawal",Arial,sans-serif;line-height:1.6;color:#111;background:#fff}

/* الصور: بدون فرض ratio على البنرات */
img{max-width:100%;height:auto;display:block;object-fit:cover}
.fixed-banner img,
.hero img,
.hero-section img,
.s-block--fixed-banner img,
.wide-placeholder img,
.banner img,
.banner-slider img,
.swiper-slide img{aspect-ratio:auto !important}

/* منتجات مربعة متناسقة فقط (لا تمس البنرات) */
.product-card img,.products-list img,.product-item img,.s-product-item img{
  width:100%; aspect-ratio:1/1; object-fit:cover; border-radius:10px;
  transition:transform .25s ease;
}
.product-card:hover img,.product-item:hover img{transform:scale(1.02)}

/* تقليل الحركة */
@media (prefers-reduced-motion:reduce){
  *{animation:none!important;transition:none!important;scroll-behavior:auto!important}
} /* === Lahzabs CSS Fix for CLS & Layout Stability === */
img {
  display:block;
  max-width:100%;
  height:auto;
  aspect-ratio:auto;
}
.product-card img,.products-list img,.s-products .product img,.s-product-item img {
  aspect-ratio:1/1;
  border-radius:10px;
  object-fit:cover;
} /* === Lahzabs CLS & Layout Stability Fix === */
img{display:block;max-width:100%;height:auto;aspect-ratio:auto;}
.product-card img,.products-list img,.product-item img,.s-product-item img{
  aspect-ratio:1/1;object-fit:cover;border-radius:10px;transition:transform .25s ease;
}
.product-card:hover img,.product-item:hover img{transform:scale(1.02)}