/* 特卖商品窗口样式 */
.sale-popup {
  position: fixed;
  width: 80%;
  max-width: 300px;
  background: linear-gradient(90deg, #000 0%, rgba(47, 32, 2, 1) 67.79%, rgba(0, 0, 0, 0.8) 90.87%, rgba(0, 0, 0, 0.8) 100%);
  border: 1px solid #250606;
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  z-index: 10000;
  display: none;
}

/* 响应式设计 */
@media (max-width: 768px) {
  .sale-popup {
    width: 90%;
    max-width: 280px;
  }

  .sale-products-container {
    width: 220px;
  }

  .sale-product-item {
    min-width: 220px;
    width: 220px;
  }

  .product-image {
    width: 180px;
    height: 180px;
  }

  .product-name {
    font-size: 11px;
    line-height: 1.3;
  }

  .product-price {
    font-size: 12px;
  }

  .current-price {
    font-size: 13px;
  }

  .original-price {
    font-size: 11px;
  }

  .add-to-cart-btn, .view-detail-btn {
    font-size: 9px;
    padding: 5px 8px;
  }
}

@media (max-width: 480px) {
  .sale-popup {
    width: 95%;
  }

  .sale-products-container {
    width: 200px;
  }

  .sale-product-item {
    min-width: 200px;
    width: 200px;
  }

  .product-image {
    width: 160px;
    height: 160px;
  }

  .product-brand {
    font-size: 9px;
  }

  .product-name {
    font-size: 10px;
  }

  .product-price {
    font-size: 11px;
  }

  .current-price {
    font-size: 12px;
  }

  .original-price {
    font-size: 10px;
  }

  .add-to-cart-btn, .view-detail-btn {
    font-size: 8px;
    padding: 4px 6px;
  }
}

.header-sale-icon {
  cursor: pointer;
  position: relative;
}

.hot-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #ff4757;
  color: white;
  font-size: 8px;
  font-weight: bold;
  padding: 2px 5px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

.sale-popup-header {
  padding: 15px;
  border-bottom: 1px solid #250606;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0,0,0,0.95);
  border-radius: 10px 10px 0 0;
}

.sale-popup-header h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: #F4D17B;
  font-family: "Roboto Mono";
  text-transform: capitalize;
  flex: 0 0 auto;
}

.popup-logo {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
}

.close-btn {
  flex: 0 0 auto;
  background: none;
  border: none;
  font-size: 16px;
  cursor: pointer;
  color: #F4D17B;
  transition: color 0.3s ease;
}

.close-btn:hover {
  color: #ddae41;
}

.countdown {
  font-size: 10px;
  color: #F4D17B;
}

.sale-popup-content {
  padding: 15px;
  background: rgba(0, 0, 0, 0.95);
  border-radius:10px;
}

.sale-products-container {
  position: relative;
  width: 250px;
  overflow: hidden;
  margin: 0 auto;
}

.sale-products-wrapper {
  display: flex;
  transition: transform 0.5s ease;
}

.sale-product-item {
  min-width: 250px;
  text-align: center;
  padding: 0;
  width: 250px;
}

.product-image {
  margin-bottom: 8px;
  width: 200px;
  height: 200px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 8px;
  border: 1px solid #250606;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.3);
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 5px;
  transition: transform 0.3s ease;
}

.product-image:hover img {
  transform: scale(1.05);
}

.product-brand {
  font-size: 10px;
  color: #F4D17B;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Roboto Mono";
}

.brand-logo {
  width: 20px;
  height: 20px;
  margin-right: 5px;
  object-fit: contain;
}

.product-name {
  font-size: 12px;
  font-weight: 700;
  color: #F4D17B;
  margin-bottom: 8px;
  text-align: center;
  font-family: "Roboto Mono";
  text-transform: capitalize;
}

.product-price {
  margin-bottom: 10px;
  text-align: center;
}

.current-price {
  font-size: 14px;
  font-weight: 700;
  color: #ff4757;
  margin-right: 8px;
  font-family: "Roboto Mono";
}

.original-price {
  font-size: 12px;
  color: #F4D17B;
  text-decoration: line-through;
  font-family: "Roboto Mono";
}

.product-actions {
  display: flex;
  gap: 8px;
}

.add-to-cart-btn, .view-detail-btn {
  flex: 1;
  padding: 6px 10px;
  border: none;
  border-radius: 4px;
  font-size: 10px;
  cursor: pointer;
  font-family: "Roboto Mono";
  font-weight: 700;
  transition: all 0.3s ease;
}

.add-to-cart-btn {
  background: linear-gradient(90deg, #ddae41 10.58%, #aa8632 67.79%, #775e23 95.19%);
  color: #fff;
}

.add-to-cart-btn:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(221, 174, 65, 0.4);
}

.add-to-cart-btn:disabled {
  background: #250606;
  cursor: not-allowed;
  color: #F4D17B;
}

.view-detail-btn {
  background: rgba(255, 255, 255, 0.1);
  color: #F4D17B;
  border: 1px solid #F4D17B;
}

.view-detail-btn:hover {
  background: rgba(244, 209, 123, 0.1);
  transform: translateY(-1px);
}

/* 滚动条样式 */
.sale-products-container::-webkit-scrollbar {
  height: 6px;
}

.sale-products-container::-webkit-scrollbar-track {
  background: #250606;
  border-radius: 3px;
}

.sale-products-container::-webkit-scrollbar-thumb {
  background: #F4D17B;
  border-radius: 3px;
}

.sale-products-container::-webkit-scrollbar-thumb:hover {
  background: #ddae41;
}

/* 移动端头部调整 */
header .header-mobile .mobile-icons {
  display: flex;
  align-items: center;
  gap: 15px;
}

header .header-mobile .mobile-icons .header-sale-icon {
  cursor: pointer;
  position: relative;
}

header .header-mobile .mobile-icons .hot-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  background: #ff4757;
  color: white;
  font-size: 8px;
  font-weight: bold;
  padding: 2px 5px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

/* 左右切换按钮样式 */
.slide-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid #F4D17B;
  border-radius: 50%;
  width: 25px;
  height: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10;
  transition: all 0.3s ease;
}

.slide-btn i {
  color: #F4D17B;
  font-size: 12px;
}

.slide-btn:hover {
  background: rgba(244, 209, 123, 0.1);
  border-color: #ddae41;
}

.slide-btn:hover i {
  color: #ddae41;
}

.slide-btn-left {
  left: 10px;
}

.slide-btn-right {
  right: 10px;
}

/* 调整特卖商品容器的相对定位 */
.sale-popup-content {
  position: relative;
}
