/*!
 * 首页独立样式 - home.css
 * Dedicated homepage styles for DELOS Lighting
 */

/* ===== 新闻 5列上图下标题 ===== */
#news-preview .home-news-list {
  display: grid !important;
  grid-template-columns: repeat(5, 1fr) !important;
  gap: 16px !important;
}

#news-preview .home-news-item {
  display: flex !important;
  flex-direction: column !important;
  background: #FFFFFF !important;
  border: 1px solid #F0F2F5 !important;
  border-radius: 6px !important;
  overflow: hidden !important;
  text-decoration: none !important;
  color: inherit !important;
  transition: border-color 0.3s ease, box-shadow 0.3s ease !important;
}

#news-preview .home-news-item:hover {
  border-color: #D5DAE3 !important;
  box-shadow: 0 6px 20px rgba(15, 27, 45, 0.06) !important;
}

/* 图片 */
#news-preview .home-news-item-img {
  width: 100% !important;
  aspect-ratio: 16/10 !important;
  overflow: hidden !important;
  background: #F5F6F8 !important;
  flex-shrink: 0 !important;
}

#news-preview .home-news-item-img img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.4s ease !important;
}

#news-preview .home-news-item:hover .home-news-item-img img {
  transform: scale(1.06) !important;
}

#news-preview .home-news-item-ph {
  width: 100% !important;
  height: 100% !important;
  min-height: 120px !important;
  background: linear-gradient(135deg, #E8EDF4, #D5DEE8) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  position: relative !important;
}

#news-preview .home-news-item-ph::before {
  content: 'NEWS' !important;
  font-family: 'Oswald', 'Arial', sans-serif !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  letter-spacing: 4px !important;
  color: rgba(15, 27, 45, 0.15) !important;
  text-transform: uppercase !important;
}

/* 标题 */
#news-preview .home-news-item-body {
  padding: 14px 16px 16px !important;
}

#news-preview .home-news-item-title {
  font-size: 13.5px !important;
  font-weight: 600 !important;
  color: #0F1B2D !important;
  margin: 0 !important;
  line-height: 1.45 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  transition: color 0.3s ease !important;
}

#news-preview .home-news-item:hover .home-news-item-title {
  color: #47809A !important;
}

/* 隐藏不需要的元素 */
#news-preview .home-news-item-meta,
#news-preview .home-news-item-summary,
#news-preview .home-news-item-more {
  display: none !important;
}

/* 清除旧干扰 */
#news-preview .home-news-item:nth-child(4),
#news-preview .home-news-item:nth-child(5) {
  grid-column: auto !important;
}

@media (max-width: 1200px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(5, 1fr) !important;
  }
}
@media (max-width: 992px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(5, 1fr) !important;
  }
}
@media (max-width: 768px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 12px !important;
  }
  #news-preview .home-news-item-title {
    font-size: 12px !important;
  }
  #news-preview .home-news-item-body {
    padding: 10px 12px 12px !important;
  }
}
@media (max-width: 480px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 10px !important;
  }
}
/* ===== 产品卡片 - 统一极简风 ===== */
#products-preview .home-cat-card {
  min-height: 0 !important;
}

#products-preview .home-cat-card-title {
  padding-bottom: 0 !important;
  margin-bottom: 0 !important;
}

#products-preview .home-cat-card-title::after {
  display: none !important;
}

#products-preview .home-cat-card:hover .home-cat-card-title::after {
  display: none !important;
}

#products-preview .home-cat-card-desc {
  min-height: 0 !important;
}

#products-preview .home-cat-card-subs {
  min-height: 0 !important;
}

#products-preview .home-cat-card-link {
  margin-top: 12px !important;
  padding-top: 0 !important;
}

/* ===== 分类引导卡片（shadcn/ui 风格） ===== */
.home-cat-grid-cards {
  display: grid !important;
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 20px !important;
}

.home-cat-card {
  display: flex !important;
  flex-direction: column !important;
  background: #FFFFFF !important;
  border: 1px solid var(--border, #E2EAF2) !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  text-decoration: none !important;
  transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.home-cat-card:hover {
  border-color: var(--accent, #47809A) !important;
  box-shadow: 0 4px 20px rgba(30,91,184,0.06) !important;
}

.home-cat-card-img {
  width: 100% !important;
  aspect-ratio: 4/3 !important;
  overflow: hidden !important;
  background: var(--bg-soft, #F5F6F8) !important;
  flex-shrink: 0 !important;
}

.home-cat-card-img img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  transition: transform 0.4s ease !important;
}

.home-cat-card:hover .home-cat-card-img img {
  transform: scale(1.05) !important;
}

.home-cat-card-body {
  padding: 20px !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 10px !important;
  flex: 1 !important;
}

.home-cat-card-title {
  font-size: 18px !important;
  font-weight: 700 !important;
  color: #0F1B2D !important;
  margin: 0 !important;
  line-height: 1.4 !important;
  text-align: center !important;
}

.home-cat-card-desc {
  font-size: 13px !important;
  color: #5A6B7E !important;
  line-height: 1.6 !important;
  margin: 0 !important;
  text-align: center !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

.home-cat-card-subs {
  display: flex !important;
  flex-wrap: wrap !important;
  justify-content: center !important;
  gap: 6px !important;
}

.home-cat-card-sub {
  display: inline-block !important;
  font-size: 11px !important;
  color: var(--accent, #47809A) !important;
  background: rgba(71, 128, 154, 0.08) !important;
  padding: 2px 10px !important;
  border-radius: 999px !important;
  line-height: 1.6 !important;
  white-space: nowrap !important;
}

.home-cat-card-link {
  font-size: 13px !important;
  font-weight: 600 !important;
  color: var(--accent, #47809A) !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 4px !important;
  margin-top: auto !important;
  transition: gap 0.2s ease !important;
}

.home-cat-card:hover .home-cat-card-link {
  gap: 8px !important;
}

@media (max-width: 1024px) {
  .home-cat-grid-cards {
    grid-template-columns: repeat(2, 1fr) !important;
  }
}

@media (max-width: 640px) {
  .home-cat-grid-cards {
    grid-template-columns: 1fr !important;
  }
}

/* ===== ABOUT 区 ===== */
#about-preview .about-preview-text h3 {
  font-size: 24px !important;
  margin-bottom: 6px !important;
}

#about-preview .about-preview-text h3::after {
  width: 36px !important;
  height: 2px !important;
  margin-top: 16px;
}

#about-preview .about-preview-text p {
  font-size: 14px !important;
  line-height: 1.85 !important;
  margin-bottom: 14px !important;
}

#about-preview .about-stats-row {
  padding: 36px 24px !important;
}

/* ===== 响应式 ===== */
@media (max-width: 1200px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(4, 1fr) !important;
  }
}
@media (max-width: 992px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(3, 1fr) !important;
  }
  #news-preview .home-news-item-title {
    font-size: 12.5px !important;
  }
}
@media (max-width: 768px) {
  #news-preview .home-news-list {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 16px !important;
  }
}
@media (max-width: 480px) {
  #news-preview .home-news-list {
    grid-template-columns: 1fr !important;
  }
  #news-preview .home-news-item-title {
    font-size: 14px !important;
    min-height: auto !important;
  }
}


/* ===== 中英双语标题 ===== */
.home-section-title {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  gap: 2px !important;
}
.home-section-title-cn {
  font-size: 32px !important;
  font-weight: 600 !important;
  color: #1C2C40 !important;
  letter-spacing: 2px !important;
}
/* 让英文变小，放下面 */
#products-preview .home-section-title,
#about-preview .home-section-title,
#news-preview .home-section-title,
.home-section-title {
  font-size: 14px !important;
  font-weight: 500 !important;
  color: #8E9DB3 !important;
  letter-spacing: 4px !important;
  line-height: 1.2 !important;
}