/* ============================================================
   VI Feerie — Section "Thương hiệu đối tác Hàn Quốc" (Brands Marquee)
   ============================================================ */

.brands-section {
  padding: 64px 0;
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  overflow: hidden;
  position: relative;
}

/* Khung bọc marquee với hiệu ứng mờ dần 2 mép */
.brands-marquee {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 10px 0;
  mask-image: linear-gradient(
    to right,
    transparent 0%,
    rgba(0, 0, 0, 1) 10%,
    rgba(0, 0, 0, 1) 90%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(
    to right,
    transparent 0%,
    rgba(0, 0, 0, 1) 10%,
    rgba(0, 0, 0, 1) 90%,
    transparent 100%
  );
}

.brands-marquee__track {
  display: flex;
  gap: 24px;
  width: max-content;
  will-change: transform;
  animation: brandsScroll 36s linear infinite;
}

.brands-marquee--reverse .brands-marquee__track {
  animation: brandsScrollReverse 40s linear infinite;
  margin-top: 18px;
}

.brands-marquee:hover .brands-marquee__track {
  animation-play-state: paused;
}

/* Logo thương hiệu — không khung, chỉ ảnh */
.brand-card {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 220px;
  height: max-content;
  padding: 0 24px;
  background: transparent;
  border: none;
  box-shadow: none;
  border-radius: 0;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.25s var(--ease);
}

.brand-card img {
  max-width: 100%;
  max-height: 80px;
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform 0.25s var(--ease);
}

.brand-card:hover {
  transform: translateY(-2px);
}

.brand-card:hover img {
  transform: scale(1.06);
}

/* Keyframes cuộn liên tục */
@keyframes brandsScroll {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

@keyframes brandsScrollReverse {
  0% {
    transform: translateX(-50%);
  }
  100% {
    transform: translateX(0);
  }
}

/* Điểm nhấn chứng nhận chất lượng bên dưới */
.brands-badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px dashed var(--line);
}

.brands-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
}

.brands-badge svg {
  width: 20px;
  height: 20px;
  color: var(--brand-deep);
  flex-shrink: 0;
}

.brands-badge strong {
  color: var(--ink);
  font-weight: 600;
}

/* ============================================================
   Responsive
   ============================================================ */

@media screen and (max-width: 820px) {
  .brands-section {
    padding: 48px 0;
  }

  .brand-card {
    width: 180px;

    padding: 0 18px;
  }

  .brand-card img {
    max-height: 68px;
  }

  .brands-marquee__track {
    gap: 16px;
    animation-duration: 26s;
  }

  .brands-marquee--reverse .brands-marquee__track {
    margin-top: 12px;
    animation-duration: 30s;
  }

  .brands-badges {
    flex-wrap: wrap;
    gap: 18px 24px;
    margin-top: 28px;
    padding-top: 20px;
  }
}

@media screen and (max-width: 520px) {
  .brands-section {
    padding: 38px 0;
  }

  .brand-card {
    width: 160px;

    padding: 0 16px;
  }

  .brand-card img {
    max-height: 60px;
  }

  .brands-badge {
    font-size: 12px;
  }

  .brands-badge svg {
    width: 17px;
    height: 17px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .brands-marquee__track {
    animation: none !important;
  }

  .brands-marquee {
    overflow-x: auto;
    mask-image: none;
    -webkit-mask-image: none;
  }
}
