/* ==========================================================================
   优奥工品 · 首页「产品中心」板块专属样式（index.html #products）
   复用 main.d104da6e.css 的变量与基础组件，不修改公共文件；
   页面级组件统一使用 home-shop-* / home-prod-* 语义前缀，
   避免与产品中心页（products.css）的 shop-* / product-* 样式冲突。
   ========================================================================== */

/* ---------- 板块底色：与相邻 section 形成交替 ---------- */
.section--products {
  background: var(--bg-alt);
}

/* ---------- 店铺卡片（home-shop） ---------- */
.home-shop__grid {
  display: grid;
  gap: 24px;
  grid-template-columns: repeat(3, 1fr);
}
.home-shop__card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.home-shop__card:hover {
  border-color: var(--primary-200);
  box-shadow: var(--shadow-lg);
  transform: translateY(-6px);
}
.home-shop__head {
  background: linear-gradient(150deg, #15181b, #0d0f11);
  padding: 24px 24px 20px;
  position: relative;
}
.home-shop__head:after {
  background: radial-gradient(300px 150px at 90% 0, rgba(180, 20, 20, .32), rgba(180, 20, 20, 0));
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}
.home-shop__badge {
  background: rgba(180, 20, 20, .28);
  border: 1px solid rgba(217, 67, 67, .42);
  border-radius: 100px;
  color: #f0a8a8;
  display: inline-block;
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: .02em;
  padding: 5px 13px;
  position: relative;
  z-index: 1;
}
.home-shop__name {
  color: #fff;
  font-size: 18px;
  font-weight: 600;
  margin: 12px 0 0;
  position: relative;
  z-index: 1;
}
.home-shop__head p {
  color: hsla(0, 0%, 100%, .66);
  font-size: 13px;
  line-height: 1.75;
  margin-top: 6px;
  position: relative;
  z-index: 1;
}
/* 京东自营店：浅色头部，形成视觉区分 */
.home-shop__card--light .home-shop__head {
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.home-shop__card--light .home-shop__head:after {
  display: none;
}
.home-shop__card--light .home-shop__name {
  color: var(--ink);
}
.home-shop__card--light .home-shop__head p {
  color: var(--ink-3);
}
.home-shop__card--light .home-shop__badge {
  background: var(--bg-alt);
  border-color: var(--line);
  color: var(--ink-2);
}
.home-shop__body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 22px 24px 24px;
}
.home-shop__meta {
  display: grid;
  gap: 8px;
}
.home-shop__meta li {
  color: var(--ink-3);
  font-size: 13px;
  line-height: 1.75;
  padding-left: 16px;
  position: relative;
}
.home-shop__meta li:before {
  background: var(--primary);
  border-radius: 50%;
  content: "";
  height: 5px;
  left: 0;
  position: absolute;
  top: 10px;
  width: 5px;
}
.home-shop__meta li b {
  color: var(--ink-2);
  font-weight: 600;
}

/* ---------- 主推产品速览（home-prod） ---------- */
.home-prod__box {
  background: var(--primary-50);
  border: 1px solid var(--primary-100);
  border-radius: var(--radius);
  margin-top: 18px;
  padding: 12px 14px;
}
.home-prod__tag {
  color: var(--primary);
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .04em;
}
.home-prod__name {
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 600;
  line-height: 1.6;
  margin-top: 4px;
}
.home-prod__price {
  color: var(--primary);
  font-size: 14px;
  font-weight: 700;
  margin-top: 6px;
}
.home-prod__price span {
  color: var(--ink-4);
  font-size: 12px;
  font-weight: 400;
  margin-left: 8px;
}

/* ---------- 类目快捷入口（chip） ---------- */
.home-shop__cats {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 26px;
}
.home-shop__cat {
  align-items: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  display: inline-flex;
  gap: 10px;
  padding: 10px 18px;
  transition: background-color .22s ease, border-color .22s ease;
}
.home-shop__cat:hover {
  background: var(--primary-50);
  border-color: var(--primary-200);
}
.home-shop__cat-name {
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
}
.home-shop__cat-desc {
  color: var(--ink-3);
  font-size: 13px;
}
@media (max-width: 480px) {
  .home-shop__cats {
    flex-direction: column;
  }
  .home-shop__cat {
    justify-content: center;
  }
}

/* ---------- 卡片按钮组 ---------- */
.home-shop__actions {
  border-top: 1px solid var(--line);
  display: flex;
  gap: 10px;
  /* 卡片为 flex column 且 grid 等高：auto 将按钮组推至卡片底部，跨卡片对齐 */
  margin-top: auto;
  padding-top: 18px;
}
.home-shop__actions .btn {
  flex: 1;
}
/* 次级按钮：outline 风格（主 CSS 未提供，仅在首页板块内生效） */
.home-shop__actions .btn--outline {
  background: #fff;
  border-color: var(--line);
  color: var(--ink-2);
}
.home-shop__actions .btn--outline:hover {
  background: var(--primary-50);
  border-color: var(--primary-200);
  color: var(--primary);
}

/* ---------- 板块底部 CTA ---------- */
.home-products__cta {
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 34px;
  text-align: center;
}
.home-products__cta-note {
  color: var(--ink-3);
  font-size: 13px;
}

/* ---------- 响应式（与主站断点对齐：1024 / 768） ---------- */
@media (max-width: 1024px) {
  .home-shop__grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 768px) {
  .home-shop__head {
    padding: 20px 20px 16px;
  }
  .home-shop__body {
    padding: 18px 20px 20px;
  }
}
/* 窄屏（≤480px）：板块底部 CTA 文案较长，允许换行并自适应高度，避免横向溢出 */
@media (max-width: 480px) {
  .home-products__cta .btn {
    height: auto;
    line-height: 1.4;
    min-height: 48px;
    padding: 8px 18px;
    white-space: normal;
  }
}
