/*
--------------------------------------------
📦 Baziti Category Page Styles (RTL) v6.3
--------------------------------------------
*/

/* 🖼 بنر دسته با گاتر ثابت */
.bz-cat-hero {
  margin: 0 auto 28px;
  width: 100%;
}
.bz-cat-hero .bz-content-wrap {
  max-width: 1320px;
  margin-inline: auto;
  padding-inline: 24px;
  box-sizing: border-box;
}
@media (max-width: 768px) {
  .bz-cat-hero .bz-content-wrap {
    padding-inline: 16px;
  }
}
.bz-cat-hero img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 16px;
  object-fit: cover;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}
body.dark-mode .bz-cat-hero img {
  box-shadow: 0 4px 10px rgba(255,255,255,0.06);
}

/* 🏷️ هدر دسته */
.bz-cat-header {
  text-align: center;
  margin: 20px auto 30px;
}
.bz-cat-title {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--baziti-text);
  margin-bottom: 10px;
}
.bz-cat-desc {
  color: var(--baziti-muted);
  font-size: 0.95rem;
  line-height: 1.8;
  max-width: 800px;
  margin: 0 auto;
}

/* 🛍️ گرید محصولات */
.bz-products-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  margin-top: 10px;
}

/* کارت محصول */
.bz-product-card {
  background: var(--baziti-card);
  border-radius: 14px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.05);
  padding: 12px;
  transition: all 0.25s ease;
  position: relative;
  overflow: hidden;
}
.bz-product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.08);
}

/* تصویر محصول */
.bz-product-thumb {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 10px;
}
.bz-product-thumb img {
  width: 100%;
  height: auto;
  border-radius: 10px;
  object-fit: cover;
  transition: transform 0.3s ease;
}
.bz-product-thumb:hover img {
  transform: scale(1.05);
}

/* عنوان و قیمت */
.bz-product-body {
  text-align: center;
}
.bz-product-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--baziti-text);
  text-decoration: none;
  display: block;
  margin-bottom: 6px;
  transition: color 0.3s;
}
.bz-product-title:hover {
  color: var(--baziti-primary);
}
.price {
  color: var(--baziti-primary);
  font-weight: 700;
  margin-bottom: 8px;
  display: inline-block;
}

/* 🛒 دکمه افزودن به سبد */
.bz-add-to-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--baziti-primary);
  color: #fff;
  border-radius: 10px;
  padding: 8px 12px;
  transition: all 0.25s ease;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}
.bz-add-to-cart:hover {
  background: var(--baziti-secondary);
  transform: translateY(-2px);
}
.bz-cart-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

/* ❌ بدون محصول */
.bz-no-products {
  text-align: center;
  padding: 40px 0;
  color: var(--baziti-muted);
  font-size: 1rem;
}

/* 📱 واکنش‌گرایی */
@media (max-width: 1200px) {
  .bz-products-grid { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 992px) {
  .bz-products-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .bz-products-grid { grid-template-columns: repeat(2, 1fr); }
  .bz-cat-title { font-size: 1.4rem; }
}

/* 🌙 دارک‌مود */
body.dark-mode .bz-product-card {
  background: #111827;
  box-shadow: 0 3px 6px rgba(0,0,0,0.5);
}
body.dark-mode .bz-cat-title {
  color: #f3f4f6;
}
body.dark-mode .bz-cat-desc {
  color: #9ca3af;
}
body.dark-mode .bz-add-to-cart {
  background: var(--baziti-accent);
  color: #fff;
}
body.dark-mode .bz-add-to-cart:hover {
  background: var(--baziti-primary);
}
body.dark-mode .bz-product-title:hover {
  color: var(--baziti-accent);
}
/* 🛒 دکمه افزودن به سبد - نسخه مینیمال نهایی */
.bz-product-body {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

/* فقط آیکون زنبیل */
.bz-add-to-cart {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: var(--baziti-primary);
  border: none;
  outline: none;
  padding: 8px;
  border-radius: 50%;
  transition: transform 0.25s ease, color 0.25s ease;
  cursor: pointer;
}

/* فقط آیکون در حالت هاور رنگ بگیرد */
.bz-add-to-cart:hover {
  color: var(--baziti-secondary);
  transform: scale(1.12);
}

/* آیکون بزرگ‌تر و واضح‌تر */
.bz-cart-icon {
  width: 26px;
  height: 26px;
  fill: currentColor;
}

/* 🌙 دارک‌مود */
body.dark-mode .bz-add-to-cart {
  color: var(--baziti-accent);
}
body.dark-mode .bz-add-to-cart:hover {
  color: var(--baziti-primary);
}
/* چیدمان قطعی: عنوان، قیمت، دکمه — ستونی و وسط */
.bz-products-grid .bz-product-card .bz-product-body{
  display:flex !important;
  flex-direction:column !important;
  align-items:center !important;
  justify-content:flex-start;
  gap:8px;
  text-align:center;
}

.bz-products-grid .bz-product-card .price{
  order:1;
  margin:0 0 4px 0;
}
.bz-products-grid .bz-product-card .bz-add-to-cart{
  order:2;
}

/* دکمه مینیمال فقط آیکون */
.bz-products-grid .bz-product-card .bz-add-to-cart{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  background:transparent !important;
  border:none !important;
  box-shadow:none !important;
  padding:8px;
  border-radius:50%;
  color:var(--baziti-primary);
  cursor:pointer;
  transition:transform .2s ease, color .2s ease;
  z-index:2;
}

/* فقط خود آیکون در هاور تغییر رنگ/اندازه بده */
.bz-products-grid .bz-product-card .bz-add-to-cart:hover{
  color:var(--baziti-secondary);
  transform:scale(1.12);
}

/* آیکون بزرگ‌تر و خوانا */
.bz-products-grid .bz-product-card .bz-cart-icon{
  width:26px;
  height:26px;
  fill:currentColor;
  display:block;
  line-height:1;
}

/* اطمینان از اینکه تصویر رو دکمه را نمی‌پوشاند */
.bz-products-grid .bz-product-card .bz-product-thumb{ position:relative; z-index:0; }
.bz-products-grid .bz-product-card .bz-product-body{ position:relative; z-index:1; }

/* دارک‌مود */
body.dark-mode .bz-products-grid .bz-product-card .bz-add-to-cart{ color:var(--baziti-accent); }
body.dark-mode .bz-products-grid .bz-product-card .bz-add-to-cart:hover{ color:var(--baziti-primary); }
