/* =========================================================
   DHgate-style homepage styles (front page only)
   Prefix: dg-
   ========================================================= */

/* ---- 大搜索栏 ---- */
.dg-searchbar { background: var(--ink, #0B2545); padding: 18px 0; }
.dg-searchbar-inner { max-width: 1200px; margin: 0 auto; padding: 0 16px; }
.dg-search-form { display: flex; gap: 10px; }
.dg-search-input {
  flex: 1; height: 46px; border: none; border-radius: 8px 0 0 8px;
  padding: 0 18px; font-size: 15px; outline: none; color: var(--ink, #0B2545);
}
.dg-search-btn {
  height: 46px; padding: 0 28px; border: none; border-radius: 0 8px 8px 0;
  background: var(--accent, #1B6FD8); color: #fff; font-size: 15px; font-weight: 600;
  cursor: pointer; transition: background .2s;
}
.dg-search-btn:hover { background: #155cb5; }

/* ---- Hero 三栏 ---- */
.dg-hero { padding: 24px 0 8px; }
.dg-hero-grid {
  max-width: 1200px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: 230px 1fr 250px; gap: 16px;
}
.dg-cats {
  background: #fff; border: 1px solid var(--line, #E5EAF1); border-radius: 10px;
  overflow: hidden; height: fit-content;
}
.dg-cats-head {
  background: var(--ink, #0B2545); color: #fff; font-weight: 700; font-size: 15px;
  padding: 12px 16px;
}
.dg-cats-list { list-style: none; margin: 0; padding: 6px 0; }
.dg-cats-list li { border-bottom: 1px solid var(--line, #E5EAF1); }
.dg-cats-list li:last-child { border-bottom: none; }
.dg-cats-list a {
  display: block; padding: 10px 16px; color: var(--ink, #0B2545); font-size: 14px;
  text-decoration: none; transition: background .15s, color .15s;
}
.dg-cats-list a:hover { background: var(--accent-soft, #E8F1FD); color: var(--accent, #1B6FD8); }

.dg-banner { display: flex; flex-direction: column; gap: 12px; }
.dg-banner-main {
  flex: 1; border-radius: 12px; padding: 34px 36px; color: #fff;
  background: linear-gradient(120deg, #0B2545 0%, #124A8F 60%, #1B6FD8 100%);
  display: flex; flex-direction: column; justify-content: center; min-height: 240px;
}
.dg-banner-tag {
  display: inline-block; width: fit-content; background: rgba(255,255,255,.18);
  border: 1px solid rgba(255,255,255,.35); border-radius: 20px; padding: 4px 14px;
  font-size: 12px; letter-spacing: 2px; text-transform: uppercase; margin-bottom: 14px;
}
.dg-banner-title { font-size: 32px; font-weight: 800; margin: 0 0 10px; line-height: 1.15; }
.dg-banner-text { font-size: 15px; opacity: .9; margin: 0 0 20px; max-width: 480px; }
.dg-btn {
  display: inline-block; width: fit-content; background: #fff; color: var(--ink, #0B2545);
  font-weight: 700; padding: 11px 30px; border-radius: 8px; text-decoration: none;
  transition: transform .15s, box-shadow .15s;
}
.dg-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(0,0,0,.18); }

.dg-banner-thumbs { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.dg-banner-card {
  background: #fff; border: 1px solid var(--line, #E5EAF1); border-radius: 10px;
  padding: 14px 16px; text-align: center;
}
.dg-banner-card strong { display: block; font-size: 14px; color: var(--ink, #0B2545); }
.dg-banner-card span { font-size: 12px; color: var(--ink-2, #4A5568); }
.dg-banner-card b { color: var(--accent, #1B6FD8); }

.dg-promo { display: flex; flex-direction: column; gap: 12px; }
.dg-promo-card {
  border-radius: 10px; padding: 20px 18px; flex: 1;
  display: flex; flex-direction: column; justify-content: center;
}
.dg-promo-deals { background: #FFF4E5; border: 1px solid #FFD9A8; }
.dg-promo-deals h3 { margin: 0 0 6px; font-size: 18px; color: #D97706; }
.dg-promo-deals p { margin: 0 0 10px; font-size: 12px; color: #B45309; }
.dg-promo-deals a { font-size: 13px; font-weight: 700; color: #D97706; text-decoration: none; }
.dg-promo-ship { background: var(--accent-soft, #E8F1FD); border: 1px solid #C9E0FB; }
.dg-promo-ship h3 { margin: 0 0 6px; font-size: 16px; color: var(--ink, #0B2545); }
.dg-promo-ship p { margin: 0; font-size: 12px; color: var(--ink-2, #4A5568); }

/* ---- 商品区块 ---- */
.dg-section { padding: 34px 0 10px; }
.dg-section-alt { background: var(--bg-soft, #F5F8FC); }
.dg-section-head {
  max-width: 1200px; margin: 0 auto 20px; padding: 0 16px;
  display: flex; align-items: baseline; justify-content: space-between;
}
.dg-section-title { margin: 0; font-size: 22px; font-weight: 800; color: var(--ink, #0B2545); }
.dg-section-head a { color: var(--accent, #1B6FD8); font-size: 14px; font-weight: 600; text-decoration: none; }
.dg-section-head a:hover { text-decoration: underline; }

.dg-grid {
  max-width: 1200px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px;
}
.dg-card {
  background: #fff; border: 1px solid var(--line, #E5EAF1); border-radius: 10px;
  overflow: hidden; transition: box-shadow .2s, transform .2s;
}
.dg-card:hover { box-shadow: 0 10px 26px rgba(11,37,69,.10); transform: translateY(-2px); }
.dg-card-img {
  position: relative; display: block;
  aspect-ratio: 1 / 1; background: #F4F6F9; overflow: hidden;
}
.dg-card-img img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  transition: transform .3s;
}
.dg-card:hover .dg-card-img img { transform: scale(1.05); }
.dg-discount {
  position: absolute; top: 10px; left: 10px; background: #E23744; color: #fff;
  font-size: 12px; font-weight: 700; padding: 3px 8px; border-radius: 4px;
}
.dg-card-title {
  display: block; padding: 10px 12px 2px; font-size: 13px; line-height: 1.45;
  color: var(--ink, #0B2545); text-decoration: none; min-height: 40px;
}
.dg-card-title:hover { color: var(--accent, #1B6FD8); }
.dg-card-price { padding: 4px 12px 14px; }
.dg-price-now { font-size: 17px; font-weight: 800; color: var(--accent, #1B6FD8); }
.dg-price-old { font-size: 13px; color: var(--ink-3, #7A8699); text-decoration: line-through; margin-left: 8px; }

/* ---- 分类横幅 ---- */
.dg-cat-row {
  max-width: 1200px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px;
}
.dg-cat-card {
  position: relative; display: block; border-radius: 12px; overflow: hidden;
  aspect-ratio: 3 / 2; text-decoration: none;
}
.dg-cat-card img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.dg-cat-card:hover img { transform: scale(1.06); }
.dg-cat-card::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,37,69,0) 30%, rgba(11,37,69,.78) 100%);
}
.dg-cat-name {
  position: absolute; left: 14px; right: 14px; bottom: 34px; z-index: 2;
  color: #fff; font-size: 16px; font-weight: 800; text-shadow: 0 1px 6px rgba(0,0,0,.4);
}
.dg-cat-go {
  position: absolute; left: 14px; bottom: 12px; z-index: 2;
  color: #FFD166; font-size: 12px; font-weight: 700;
}
.dg-cat-card:hover .dg-cat-go { text-decoration: underline; }

/* ---- 服务承诺 ---- */
.dg-services { padding: 40px 0 44px; background: var(--ink, #0B2545); margin-top: 30px; }
.dg-services-row {
  max-width: 1200px; margin: 0 auto; padding: 0 16px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center;
}
.dg-service { color: #fff; }
.dg-service strong { display: block; font-size: 15px; margin-bottom: 4px; }
.dg-service span { font-size: 12px; opacity: .75; }

/* ---- 响应式 ---- */
@media (max-width: 1100px) {
  .dg-grid { grid-template-columns: repeat(4, 1fr); }
  .dg-cat-row { grid-template-columns: repeat(3, 1fr); }
  .dg-hero-grid { grid-template-columns: 200px 1fr; }
  .dg-promo { grid-column: 1 / -1; flex-direction: row; }
  .dg-promo-card { flex: 1; }
}
@media (max-width: 820px) {
  .dg-hero-grid { grid-template-columns: 1fr; }
  .dg-cats { order: 3; }
  .dg-banner { order: 1; }
  .dg-promo { order: 2; grid-column: auto; flex-direction: column; }
  .dg-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .dg-cat-row { grid-template-columns: repeat(2, 1fr); }
  .dg-services-row { grid-template-columns: repeat(2, 1fr); }
  .dg-search-form { flex-direction: column; }
  .dg-search-input { border-radius: 8px; }
  .dg-search-btn { border-radius: 8px; width: 100%; }
}
/* NOVATECH wide promo banner 2.35:1 */
.dg-promo-home .dg-promo-track{height:auto;}
.dg-promo-home .dg-promo-slide{display:block;min-width:100%;padding:0;background:transparent;height:auto;}
.dg-promo-home .dg-promo-slide img{width:100%;height:auto;aspect-ratio:2.35/1;object-fit:cover;border-radius:0;background:transparent;}
.dg-promo-home .dg-promo-body{display:none;}
.dg-promo-home .dg-promo-track{height:auto !important;}
.dg-promo-home .dg-promo-slide{display:block !important;min-width:100% !important;padding:0 !important;background:transparent !important;height:auto !important;}
.dg-promo-home .dg-promo-slide img{width:100% !important;height:auto !important;aspect-ratio:2.35/1 !important;object-fit:cover !important;border-radius:0 !important;background:transparent !important;max-width:none !important;max-height:none !important;flex:none !important;}
.dg-promo-home .dg-promo-body{display:none !important;}
