/* Home – 热门产品（首卡铺满，其余固定图框 contain） */
#product_center_content {
  width: 100%;
  display: flex;
  justify-content: center;
  background: #fff;
}

#product_center_content .all_product_cont {
  width: 1200px;
  max-width: calc(100% - 40px);
  margin-top: 49px;
  margin-bottom: 70px;
  box-sizing: border-box;
}

.hot-products .index-title {
  color: #000;
  font-size: 30px;
  text-align: center;
  margin: 0;
  font-weight: 400;
}

.hot-products .products-header {
  margin-top: 37px;
}

.hot-products .products-header ul {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.hot-products .products-header ul li {
  font-size: 14px;
  cursor: pointer;
  margin: 0;
  display: flex;
  border-radius: 25px;
  align-items: center;
  color: #767676;
  border: none;
  background: transparent;
  padding: 10px 29px;
  transition: color 0.2s, background 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}

.hot-products .products-header ul li.active {
  color: #fff;
  background: #f60;
}

.hot-products .products-content {
  margin-top: 30px;
}

.hot-products .products-content > div.hidden {
  display: none;
}

.hot-products .products-content .flex {
  display: flex;
  justify-content: center;
  flex-wrap: nowrap;
  gap: 0;
  max-width: 1200px;
  margin: 0 auto;
}

.hot-products .fs14 {
  font-size: 14px;
}

.hot-products .products-itme,
.hot-products .products-itme-prices,
.hot-products .products-itme-more {
  width: 228px;
  height: 294px;
  border-radius: 5px;
  overflow: hidden;
  position: relative;
  box-sizing: border-box;
  transition: transform 0.3s, box-shadow 0.3s;
  flex-shrink: 0;
  color: inherit;
  text-decoration: none;
}

.hot-products .products-itme:hover,
.hot-products .products-itme-prices:hover,
.hot-products .products-itme-more:hover {
  transform: translateY(-3px);
  box-shadow: 0 0 10px #d8d8d8;
}

/* 首卡：整卡铺满 */
.hot-products .products-itme-one {
  display: block;
  margin-left: 0;
  border: none;
  background: #f5f5f5;
  padding: 0;
}

.hot-products .products-itme-one .products-itme-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
}

.hot-products .products-itme-one .products-itme-media img {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center;
}

.hot-products .products-itme-one .products-itme-name {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 55px;
  z-index: 1;
  width: 100%;
  margin: 0;
  padding: 0 8px;
  text-align: center;
  color: #333;
  line-height: 1.4;
}

/* 其余产品卡：固定图框 + contain */
.hot-products .products-itme-prices {
  display: flex;
  flex-direction: column;
  align-items: center;
  border: 1px solid #eae7e7;
  background: #fff;
  margin-left: 16px;
  padding: 20px 16px 24px;
}

.hot-products .products-itme-prices .products-itme-media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 180px;
  flex: 0 0 180px;
  background: #fff;
}

.hot-products .products-itme-prices .products-itme-media img {
  display: block;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  object-position: center;
}

.hot-products .products-itme-prices .products-itme-name {
  position: static;
  width: 100%;
  margin-top: auto;
  padding-top: 16px;
  text-align: center;
  color: #333;
  line-height: 1.4;
  word-break: break-word;
}

.hot-products .products-itme-more {
  margin-left: 16px;
  border: 1px solid #eae7e7;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  background: #fff;
}

.hot-products .products-itme-more img {
  width: 47px;
  height: 47px;
  display: block;
  object-fit: contain;
}

.hot-products .products-itme-more .fs14 {
  margin-top: 14px;
  color: #333;
}

/* Tablet：卡片换行网格 */
@media (max-width: 1240px) {
  #product_center_content .all_product_cont {
    max-width: calc(100% - 32px);
    margin-top: 40px;
    margin-bottom: 56px;
  }

  .hot-products .products-content .flex {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    justify-content: stretch;
  }

  .hot-products .products-itme,
  .hot-products .products-itme-prices,
  .hot-products .products-itme-more {
    width: 100%;
    height: auto;
    min-height: 260px;
    margin-left: 0;
  }

  .hot-products .products-itme-prices {
    padding: 16px 12px 20px;
  }

  .hot-products .products-itme-prices .products-itme-media {
    height: 150px;
    flex-basis: 150px;
  }

  .hot-products .products-itme-one {
    min-height: 260px;
  }

  .hot-products .products-itme-one .products-itme-name {
    bottom: 28px;
  }
}

/* Mobile：Tab 横滑 + 两列卡片 */
@media (max-width: 767px) {
  #product_center_content .all_product_cont {
    max-width: 100%;
    padding: 0 12px;
    margin-top: 32px;
    margin-bottom: 48px;
  }

  .hot-products .index-title {
    font-size: 24px;
  }

  .hot-products .products-header {
    margin-top: 24px;
    margin-left: -12px;
    margin-right: -12px;
  }

  .hot-products .products-header ul {
    flex-wrap: nowrap;
    justify-content: flex-start;
    gap: 4px;
    padding: 0 12px 4px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .hot-products .products-header ul::-webkit-scrollbar {
    display: none;
  }

  .hot-products .products-header ul li {
    padding: 8px 18px;
    font-size: 13px;
  }

  .hot-products .products-content {
    margin-top: 20px;
  }

  .hot-products .products-content .flex {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
  }

  .hot-products .products-itme,
  .hot-products .products-itme-prices,
  .hot-products .products-itme-more {
    min-height: 220px;
  }

  .hot-products .products-itme-one {
    /* 首卡跨两列，接近官方大图印象 */
    grid-column: 1 / -1;
    min-height: 200px;
    aspect-ratio: 16 / 9;
  }

  .hot-products .products-itme-one .products-itme-name {
    bottom: 20px;
  }

  .hot-products .products-itme-prices {
    padding: 12px 10px 16px;
  }

  .hot-products .products-itme-prices .products-itme-media {
    height: 120px;
    flex-basis: 120px;
  }

  .hot-products .products-itme-prices .products-itme-name {
    padding-top: 10px;
    font-size: 13px;
  }

  .hot-products .products-itme-more {
    min-height: 220px;
  }

  .hot-products .products-itme-more img {
    width: 40px;
    height: 40px;
  }
}

@media (max-width: 480px) {
  .hot-products .products-itme,
  .hot-products .products-itme-prices,
  .hot-products .products-itme-more {
    min-height: 200px;
  }

  .hot-products .products-itme-one {
    min-height: 180px;
  }

  .hot-products .products-itme-prices .products-itme-media {
    height: 100px;
    flex-basis: 100px;
  }
}
