/* blog-scroll.css — کارت‌های مقاله (صفحه اصلی + صفحه محصول)
   اسکرول افقی از کلاس‌های .featured-scroll در styles.css استفاده می‌کند. */

.blog-section { margin-top: 1.5rem; }

.blog-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 1rem;
}
.blog-head .section-title { margin: 0; }
.blog-more, .blog-more:hover {
  background: #e0568f; color: #fff; text-decoration: none;
  border-radius: 12px; padding: 7px 18px; font-size: 14px; white-space: nowrap;
  transition: background .2s;
}
.blog-more:hover { background: #c23e78; }

/* عرض هر کارت: موبایل ~۷۸٪ ، دسکتاپ سه‌تایی */
.featured-scroll .blog-item { width: min(300px, 78%); }
@media (min-width: 768px) {
  .featured-scroll .blog-item { width: calc((100% - 2rem) / 3); }
}

.blog-card {
  --bl-ac: #e0568f;
  position: relative; isolation: isolate;
  display: flex; flex-direction: column; justify-content: flex-end;
  aspect-ratio: 4 / 5; min-height: 360px;
  padding: 20px; border-radius: 26px; overflow: hidden;
  background: linear-gradient(160deg, #f8c4da, #e0568f 70%, #7a3a55);
  color: #2b2b33; text-decoration: none;
  transition: transform .25s ease, box-shadow .25s ease;
}
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 10px 28px rgba(224, 86, 143, .25); color: #2b2b33; text-decoration: none; }

.blog-card__img {
  position: absolute; inset: 0; z-index: -2;
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .4s ease;
}
.blog-card:hover .blog-card__img { transform: scale(1.05); }

/* محو سفید پایین کارت برای خوانایی متن */
.blog-card::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(to top, #fff 0%, rgba(255,255,255,.94) 34%, rgba(255,255,255,.55) 52%, rgba(255,255,255,0) 72%);
}

.blog-card__cat {
  position: absolute; top: 16px; inset-inline-end: 16px;
  background: rgba(255,255,255,.9); color: #2b2b33;
  font-size: 12px; padding: 3px 14px; border-radius: 10px;
}
.blog-card__title { margin: 0 0 8px; font-size: 16px; font-weight: 800; line-height: 1.8; color: #2b2b33;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.blog-card__text { margin: 0 0 12px; font-size: 13px; line-height: 1.9; color: #5c5c66;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.blog-card__meta { display: flex; justify-content: space-between; font-size: 12px; color: #6b6b76; margin-bottom: 12px; }

.blog-card__go { display: flex; align-items: center; gap: 12px; }
.blog-card__btn {
  width: 56px; height: 34px; border-radius: 12px; display: grid; place-items: center;
  background: var(--bl-ac); color: #fff; font-size: 16px;
}
.blog-card__line { flex: 1; height: 1px; background: #d9d9df; }

@media (max-width: 575.98px) {
  .blog-card { padding: 16px; }
  .blog-card__text { -webkit-line-clamp: 2; }
}

/* ردیف‌های انتهای صفحه محصول */
.related-rows { margin-top: clamp(2rem, 5vw, 3.5rem); }
.related-row + .related-row { margin-top: 1rem; }

@media (prefers-reduced-motion: reduce) {
  .blog-card, .blog-card__img { transition: none !important; }
}