/* 热门精选区域 - 蓝白大厂工业直角风 */
.hot-selection-section {
  padding: 80px 0;
  background-color: #f8faff; /* 极浅的蓝白底色 */
  color: #1e293b;
  font-family: "Inter", "Microsoft YaHei", sans-serif;
  position: relative;
}

/* 装饰背景：增加一点大厂常用的光晕感 */
.hot-selection-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 400px;
  background: radial-gradient(circle at 50% -20%, rgba(22, 119, 255, 0.05) 0%, transparent 70%);
  pointer-events: none;
}

.hot-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
  z-index: 2;
}

/* 标题区优化 */
.hot-header {
  text-align: center;
  margin-bottom: 60px;
}

.hot-header h2 {
  font-size: 36px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 15px;
  letter-spacing: -0.5px;
}

.hot-header h2 span {
  color: #1677FF; /* 大厂标准蓝 */
  margin-left: 10px;
}

.hot-header p {
  color: #64748b;
  font-size: 16px;
}

/* 网格布局 */
.hot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

/* 卡片重塑：纯白直角 */
.hot-card {
  background: #ffffff;
  border: 1px solid #e2e8f0; /* 浅灰色精细边框 */
  padding: 32px 24px;
  position: relative;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: 0 !important; /* 强制直角 */
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

/* 悬停效果：品牌蓝激活 */
.hot-card:hover {
  transform: translateY(-8px);
  border-color: #1677FF;
  box-shadow: 0 20px 25px -5px rgba(22, 119, 255, 0.1), 0 10px 10px -5px rgba(22, 119, 255, 0.04);
}

/* Featured 状态：移除侧边高亮条，保持纯白直角一致性 */
.hot-card.featured {
  border-left: 1px solid #e2e8f0;
}

/* 标签重塑 */
.hot-card-tag {
  position: absolute;
  top: 0;
  right: 0;
  padding: 4px 12px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  border-radius: 0 !important; /* 直角 */
}

.tag-hot { background: #ff4d4f; color: #fff; }
.tag-new { background: #52c41a; color: #fff; }

/* 内容排版 */
.hot-card h3 {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 12px;
  color: #1e293b;
}

.hot-card .desc {
  font-size: 14px;
  color: #64748b;
  line-height: 1.6;
  margin-bottom: 24px;
  height: 45px;
  overflow: hidden;
}

/* 配置列表：精细化对齐 */
.hot-specs {
  border-top: 1px solid #f1f5f9;
  padding-top: 20px;
  margin-bottom: 30px;
}

.spec-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.spec-item .label {
  color: #94a3b8;
  font-size: 13px;
}

.spec-item .val {
  color: #334155;
  font-weight: 600;
  font-size: 14px;
}

/* 价格区域 */
.hot-price-wrap {
  margin-top: auto;
  margin-bottom: 24px;
  padding: 15px;
  background-color: #f8fafc;
}

.price-row {
  display: flex;
  align-items: baseline;
  gap: 4px;
}

.price-row .currency {
  font-size: 16px;
  color: #ff4d4f; /* 价格通常用醒目的红色或蓝色，大厂常用深红/橘红 */
  font-weight: 600;
}

.price-row .amount {
  font-size: 36px;
  font-weight: 700;
  color: #ff4d4f;
  letter-spacing: -1px;
}

.price-row .cycle {
  font-size: 14px;
  color: #94a3b8;
}

.old-price {
  font-size: 13px;
  color: #94a3b8;
  text-decoration: line-through;
  margin-top: 4px;
}

/* 按钮重塑：大厂蓝 */
.hot-buy-btn {
  display: block;
  width: 100%;
  padding: 14px;
  text-align: center;
  background: #1677FF;
  color: #fff !important;
  text-decoration: none !important;
  font-weight: 600;
  font-size: 15px;
  border-radius: 0 !important; /* 直角 */
  transition: all 0.2s;
  border: none;
}

.hot-buy-btn:hover {
  background: #0050b3;
  box-shadow: 0 4px 12px rgba(22, 119, 255, 0.3);
}

/* 多 Tab 导航样式 */
.hot-selection-tabs {
  display: flex;
  justify-content: center;
  gap: 0; /* 移除间距，改用边框连接 */
  margin-top: 35px;
  border-bottom: 2px solid #f1f5f9;
  padding-bottom: 0;
}

.hot-tab-item {
  padding: 12px 30px;
  font-size: 16px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  position: relative;
  transition: all 0.3s;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px; /* 压在底边线上 */
}

.hot-tab-item:hover {
  color: #1677FF;
}

.hot-tab-item.active {
  color: #1677FF;
  border-bottom-color: #1677FF;
}

.hot-tab-item.active::after {
  display: none; /* 移除旧样式 */
}

/* Tab 面板容器 */
.hot-tabs-panels {
  margin-top: 40px;
}

.hot-tab-panel {
  display: none;
  animation: hotFadeIn 0.5s ease-out;
}

.hot-tab-panel.active {
  display: block;
}

@keyframes hotFadeIn {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 响应式适配 (大厂级移动端优化) */
@media (max-width: 768px) {
  .hot-selection-section {
    padding: 30px 15px;
  }

  /* 1. Tab 导航条：横向滑动模式 */
  .hot-selection-tabs {
    display: flex;
    justify-content: flex-start;
    overflow-x: auto;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 2px;
    margin-top: 20px;
    border-bottom: 1px solid #f1f5f9;
    scrollbar-width: none;
  }
  .hot-selection-tabs::-webkit-scrollbar {
    display: none;
  }
  .hot-tab-item {
    padding: 10px 15px;
    font-size: 14px;
    flex-shrink: 0;
    margin-bottom: -1px;
  }

  /* 2. 商品列表：横向滑动模式 */
  .hot-grid {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    gap: 16px;
    margin-top: 20px;
    padding: 10px 15px 30px !important; /* 底部增加间距给阴影留位 */
    -webkit-overflow-scrolling: touch;
    scroll-snap-type: x mandatory;
    scrollbar-width: none; /* Firefox */
  }

  .hot-grid::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
  }

  .hot-card {
    flex: 0 0 85% !important; /* 每个卡片占屏幕 85%，露出下一个卡片的头 */
    scroll-snap-align: center;
    padding: 24px 20px;
    text-align: left;
    position: relative;
    border-radius: 0 !important;
    height: auto;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05) !important;
  }

  /* 标题与标签处理 */
  .hot-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
    padding-right: 60px; /* 为标签留位 */
  }

  .hot-card .hot-card-tag {
    position: absolute;
    top: 15px;
    right: 15px;
    font-size: 11px;
    padding: 2px 6px;
  }

  .hot-card .desc {
    font-size: 12px;
    margin-bottom: 12px;
    -webkit-line-clamp: 1; /* 手机端只显一行描述 */
  }

  /* 规格胶囊化 */
  .hot-specs {
    border: none;
    padding: 0;
    margin-bottom: 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    height: auto;
  }

  .hot-specs .spec-item {
    background: #f8fafc;
    padding: 4px 8px;
    font-size: 11px;
    border: none;
    display: flex;
    width: auto;
    flex: none;
  }

  .hot-specs .spec-item .label {
    color: #94a3b8;
    margin-right: 4px;
  }

  /* 价格与按钮并排 */
  .hot-price-wrap {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px dashed #e2e8f0;
    padding-top: 12px;
    margin-top: 0;
  }

  .hot-price-wrap .price-row {
    margin: 0;
  }

  .hot-price-wrap .amount {
    font-size: 20px;
  }

  .hot-card .hot-buy-btn {
    width: auto;
    margin-top: 0;
    padding: 8px 15px;
    font-size: 13px;
  }

  /* 滑动提示样式 */
  .hot-scroll-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 5px;
    padding-bottom: 10px;
  }

  .hint-text {
    font-size: 12px;
    color: #94a3b8;
    font-weight: 500;
  }

  .hint-line {
    width: 60px;
    height: 3px;
    background: #f1f5f9;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
  }

  .hint-dot {
    width: 25px;
    height: 100%;
    background: #1677FF;
    border-radius: 4px;
    position: absolute;
    top: 0;
    left: 0;
    animation: hotHintSlide 2s infinite ease-in-out;
  }

  @keyframes hotHintSlide {
    0%, 100% { transform: translateX(0); }
    50% { transform: translateX(35px); }
  }
}

/* 桌面端隐藏滑动提示 */
@media (min-width: 769px) {
  .hot-scroll-hint {
    display: none !important;
  }
}
