/* ======================================================
   Plugin: Quản Lý Nhà Phân Phối – Webtop
   File:   assets/css/frontend.css
   Mô tả:  Style Swiper slider + Card nhà phân phối
   ====================================================== */

/* ------ Wrapper bao ngoài slider ------ */
.dm-slider-wrapper {
  position: relative;
  width: 100%;
  padding: 4px 0 10px;
}

/* ================================================================
   Swap Indicator (mobile/tablet guide for Distributor Manager)
   ================================================================ */
.tva-swap-indicator-container {
  display: none;
  position: absolute;
  top: 50%;
  z-index: 99;
  pointer-events: none;
  width: 152px;
  height: 52px;
  background: rgba(0, 0, 0, 0.60);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  border-radius: 30px;
  box-sizing: border-box;
}

/* 2 cột (677px - 976px): Giữa màn hình / khung slider */
@media (min-width: 677px) and (max-width: 976px) {
  .tva-swap-indicator-container {
    display: block !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important;
  }
}

/* 1 cột (<= 676px): Giữa card thứ nhất */
@media (max-width: 676px) {
  .tva-swap-indicator-container {
    display: block !important;
    left: 41.67% !important;
    transform: translate(-50%, -50%) !important;
  }
}

.tva-hand-icon {
  animation: tva-hand-swipe 1.6s ease-in-out infinite;
  transform-origin: center;
}

@keyframes tva-hand-swipe {
  0% {
    transform: translateX(0);
  }

  25% {
    transform: translateX(-8px);
  }

  50% {
    transform: translateX(0);
  }

  75% {
    transform: translateX(8px);
  }

  100% {
    transform: translateX(0);
  }
}

/* ------ Swiper override & Equal Height ------ */
.dm-swiper {
  width: 100%;
  overflow: hidden;
  border-radius: 8px !important;
}

@media (max-width: 976px) {
  .dm-swiper {
    border-radius: 0 !important;
  }
}

.dm-swiper .swiper-wrapper {
  display: flex !important;
  align-items: stretch !important;
}

.dm-swiper .swiper-slide {
  height: auto !important;
  display: flex !important;
  flex-direction: column !important;
  user-select: none;
  -webkit-user-select: none;
  background: transparent !important;
  box-shadow: none !important;
  border-radius: 0 !important;
  padding: 0 !important;
  flex-shrink: 0 !important;
  box-sizing: border-box !important;
}

.dm-swiper .swiper-slide.dm-slide-column {
  display: flex !important;
  flex-direction: column !important;
  gap: 16px !important;
  row-gap: 16px !important;
  height: auto !important;
}

@media (min-width: 600px) and (max-width: 991px) {
  .dm-swiper .swiper-slide.dm-slide-column {
    gap: 14px !important;
    row-gap: 14px !important;
  }
}

@media (max-width: 599px) {
  .dm-swiper .swiper-slide.dm-slide-column {
    gap: 12px !important;
    row-gap: 12px !important;
  }
}

.dm-swiper .swiper-slide * {
  -webkit-user-drag: none;
}

.dm-swiper .swiper-button-prev,
.dm-swiper .swiper-button-next,
.dm-swiper .swiper-pagination {
  display: none !important;
}

/* ======================================================
   CARD NHÀ PHÂN PHỐI
   ====================================================== */
.dm-distributor-card {
  background: #dfe8ed;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 20px 0 rgba(0, 0, 0, 0.05);
  transition:
    transform 0.3s cubic-bezier(0.17, 0.84, 0.44, 1),
    box-shadow 0.3s ease;
  display: flex !important;
  flex-direction: column !important;
  height: auto !important;
  flex: 1 1 0% !important;
  width: 100%;
  box-sizing: border-box;
}

/* Nổi card lên khi rê chuột (Hover) */
.dm-distributor-card:hover {
  /*   transform: translateY(-10px); */
  /* box-shadow: 0 12px 30px 0 rgba(0, 0, 0, 0.12); */
}

/* ------ Logo Banner (phần trên card, nền xám nhạt) ------ */
.dm-card-logo-wrap {
  background: #dfe8ed;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  min-height: 140px;
  height: 100%;
  box-sizing: border-box;
}

.dm-card-logo {
  max-width: 160px;
  max-height: 90px;
  object-fit: contain;
  transition: transform 0.2s;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.dm-distributor-card:hover .dm-card-logo {
  transform: scale(1.04);
}

.dm-card-logo-placeholder {
  width: 80px;
  height: 80px;
  background: #fff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  font-weight: 800;
  color: #e63228;
}

/* ------ Body (phần dưới nền trắng) ------ */
.dm-card-body {
  padding: 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  flex: 1;
  height: 100%;
}

/* ------ Meta: "Thành lập năm 1960 · Việt Nam" ------ */
.dm-card-meta {
  font-size: 16px;
  color: #6b7280;
  text-align: center;
  margin: 0;
  font-weight: 400;
  line-height: 1.5;
  margin: 8px 0px 20px !important;
}

/* ------ Danh mục (outlined tags) ------ */
.dm-card-categories {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}

.dm-category-tag {
  background: #ffffff;
  color: #1d1552;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  transition:
    border-color 0.2s,
    color 0.2s;
}

/* ------ Đặc điểm nổi bật ------ */
.dm-card-features {
  list-style: none;
  margin: 0 !important;
  padding: 0 !important;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.dm-card-features li {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 14px;
  color: #4b5563;
  line-height: 1.5;
}

/* Shield icon / SVG in features */
.dm-check-icon,
.dm-card-features svg {
  width: 20px !important;
  height: 20px !important;
  min-width: 20px !important;
  min-height: 20px !important;
  max-width: 20px !important;
  max-height: 20px !important;
  flex-shrink: 0 !important;
  margin-top: 1px;
}

/* ------ Mô tả ------ */
.dm-card-description {
  font-size: 13px;
  color: #6b7280;
  line-height: 1.6;
  border-top: 1px solid #f3f4f6;
  padding-top: 10px;
}

/* ------ Footer + Nút CTA ------ */
.dm-card-footer {
  margin-top: auto !important;
  padding-top: 4px;
}

.dm-card-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 14px 30px;
  margin: 0 auto;
  background: var(--ast-global-color-1);
  color: #fff !important;
  border-radius: 50px;
  font-size: 16px;
  text-decoration: none !important;
  transition:
    background 0.25s ease,
    box-shadow 0.25s ease,
    transform 0.2s ease;
  letter-spacing: 0.01em;
  box-sizing: border-box;
}

.dm-card-btn:hover {
  background-color: rgba(237, 0, 0, 0.88);
  transform: translateY(-1px);
  color: #fff !important;
}

/* ------ Empty state ------ */
.dm-no-distributors {
  color: #6b7280;
  font-style: italic;
  text-align: center;
  padding: 40px;
}