/* ==============================================
   Hdev Blog Slider CSS
   ============================================== */

.hdev-blog-slider-wrap {
  position: relative;
  width: 100%;
}

.hdev-blog-slider-wrap.has-dots {
  padding-bottom: 50px; /* Space for pagination */
}

/* Card Style */
.hdev-bs-card {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  border-radius: 10px;
  box-shadow:
    0 3px 6px -4px rgba(0, 0, 0, 0.16),
    0 3px 6px rgba(0, 0, 0, 0.23);
  overflow: hidden;
  height: auto; /* Bỏ height 100% vì đã dùng flex trên slide */
  width: 100%;
  flex-grow: 1; /* Cho phép card chiếm toàn bộ chiều cao của slide */
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

/* Fix Swiper flex layout if needed */
.hdev-blog-slider-wrap .swiper-wrapper {
  align-items: stretch;
  padding-top: 15px;
  padding-bottom: 20px; /* Khoảng trống để shadow và viền dưới không bị cắt */
}
.hdev-blog-slider-wrap .swiper-slide {
  height: auto;
  display: flex; /* Bắt buộc để thẻ hdev-bs-card bên trong tự động stretch */
}

/* Image */
.hdev-bs-image-wrap {
  width: 100%;
  height: 200px; /* Cố định chiều cao ảnh */
  overflow: hidden;
}
.hdev-bs-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}
.hdev-bs-card:hover .hdev-bs-image {
  transform: scale(1.05);
}

/* Content */
.hdev-bs-content {
  padding: 20px;
  flex-grow: 1; /* Đẩy footer xuống đáy */
}

.hdev-bs-title {
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 10px;
  color: #333;
}

.hdev-bs-excerpt {
  font-size: 14px;
  color: #666;
  line-height: 1.5;
  margin-bottom: 0;
}

/* Footer */
.hdev-bs-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  border-top: 1px solid #f0f0f0;
}

.hdev-bs-date {
  display: flex;
  align-items: center;
  font-size: 13px;
  color: #888;
}

.hdev-bs-date svg {
  margin-right: 5px;
}

.hdev-bs-readmore {
  font-size: 14px;
  font-weight: 600;
  color: #f38221; /* Cam DrThin */
}

/* Navigation & Pagination styling */
.hdev-blog-slider-wrap .swiper-pagination-bullet {
  width: 30px;
  height: 8px;
  border-radius: 10px;
  background: #ccc;
  opacity: 1;
  transition: all 0.3s ease;
}

.hdev-blog-slider-wrap .swiper-pagination-bullet-active {
  background: #f38221;
  width: 40px;
}

.hdev-blog-slider-wrap .swiper-button-next,
.hdev-blog-slider-wrap .swiper-button-prev {
  color: #f38221;
  background: #ffffff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
}

.hdev-blog-slider-wrap .swiper-button-next:after,
.hdev-blog-slider-wrap .swiper-button-prev:after {
  font-size: 18px;
}

/* Mobile autoHeight fix */
@media (max-width: 767px) {
  .hdev-blog-slider-wrap .swiper-wrapper {
    align-items: flex-start !important; /* Allow autoHeight to work properly */
  }
}
