.hero-gradient {
  background: linear-gradient(135deg, rgba(139, 69, 19, 0.85) 0%, rgba(0, 100, 0, 0.75) 100%);
}

/* Hero Banner Swiper */
.hero-swiper {
  width: 100%;
  height: 80vh;
  min-height: 500px;
}
.hero-swiper .swiper-wrapper,
.hero-swiper .swiper-slide {
  height: 100%;
}
.hero-slide {
  position: relative;
  overflow: hidden;
  width: 100%;
  height: 100%;
  min-height: inherit;
}
.hero-slide-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  pointer-events: none;
}
/* Swiper 初始化前：首张 Banner 立即可见 */
.hero-swiper:not(.swiper-initialized) .swiper-slide:not(:first-child) {
  display: none;
}
.hero-swiper:not(.swiper-initialized) .swiper-slide:first-child {
  opacity: 1 !important;
}
.hero-slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  z-index: 0;
}
.hero-slide-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.35) 50%, rgba(0,0,0,0.25) 100%);
}
.hero-slide-content {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem 1.5rem;
  pointer-events: none;
}
.hero-slide-content a {
  pointer-events: auto;
}
.hero-pagination {
  bottom: 24px !important;
  z-index: 20;
}
.hero-pagination .swiper-pagination-bullet {
  width: 10px;
  height: 10px;
  background: rgba(255,255,255,0.5);
  opacity: 1;
}
.hero-pagination .swiper-pagination-bullet-active {
  background: #FFD700 !important;
  width: 28px;
  border-radius: 5px;
}
.hero-nav-prev,
.hero-nav-next {
  z-index: 20;
  color: #fff !important;
  width: 44px !important;
  height: 44px !important;
  background: rgba(0,0,0,0.3);
  border-radius: 50%;
  backdrop-filter: blur(4px);
}
.hero-nav-prev::after,
.hero-nav-next::after {
  font-size: 18px !important;
  font-weight: bold;
}
.hero-nav-prev:hover,
.hero-nav-next:hover {
  background: rgba(0,0,0,0.5);
}

/* 产品/分类图片 - 固定比例容器，防止图片高度为0 */
.product-img-outer { position: relative; }
.product-badge-oem {
  position: absolute;
  top: 12px; left: 12px;
  z-index: 5;
  background: #FFD700;
  color: #8B4513;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
}
.product-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #f3f4f6;
}
.product-img-wrap .product-card-img,
.product-img-wrap img {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-detail-img {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  max-height: 560px;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #f3f4f6;
}
.product-detail-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.product-card-img:hover,
.product-img-wrap:hover img {
  transform: scale(1.05);
}
.product-img-wrap img,
.product-card-img {
  transition: transform 0.3s ease;
}

/* 兼容旧类名 */
.img-cover {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.aspect-square { aspect-ratio: 1 / 1; position: relative; overflow: hidden; }
.aspect-square > img.img-cover {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.drop-shadow-lg { filter: drop-shadow(0 4px 6px rgba(0,0,0,0.4)); }
.drop-shadow-md { filter: drop-shadow(0 2px 4px rgba(0,0,0,0.35)); }

.swiper-pagination-bullet-active { background: #FFD700 !important; }
[x-cloak] { display: none !important; }

/* Site header navigation — spacing not in Tailwind build */
.site-nav-row {
  gap: 0.5rem;
}
.site-nav-logo {
  flex-shrink: 0;
  min-width: 0;
}
.site-nav-logo-text {
  display: none;
  max-width: 12rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.site-nav-links {
  display: none;
  align-items: center;
  justify-content: center;
  flex: 1 1 auto;
  gap: 0.875rem;
  min-width: 0;
  padding: 0 0.5rem;
}
.site-nav-links a {
  color: #374151;
  font-size: 0.875rem;
  font-weight: 500;
  white-space: nowrap;
  flex-shrink: 0;
  text-decoration: none;
  transition: color 0.15s ease;
  padding: 0.25rem 0.5rem;
}
.site-nav-links a:hover {
  color: #8B4513;
}
.site-nav-actions {
  display: none;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}
.site-nav-hamburger {
  display: block;
  flex-shrink: 0;
}
@media (min-width: 640px) {
  .site-nav-logo-text {
    display: inline;
  }
}
@media (min-width: 1280px) {
  .site-nav-links,
  .site-nav-actions {
    display: flex;
  }
  .site-nav-hamburger {
    display: none;
  }
  .site-nav-mobile-menu {
    display: none !important;
  }
  .site-nav-links {
    gap: 1rem;
  }
}

/* Article content */
.article-content h2 { font-size: 1.5rem; font-weight: 700; color: #111827; margin: 2rem 0 1rem; }
.article-content h3 { font-size: 1.25rem; font-weight: 600; color: #374151; margin: 1.5rem 0 0.75rem; }
.article-content p { margin-bottom: 1rem; line-height: 1.75; }
.article-content ul, .article-content ol { margin: 1rem 0 1rem 1.5rem; }
.article-content li { margin-bottom: 0.5rem; }
.article-content img { border-radius: 0.75rem; margin: 1.5rem 0; max-width: 100%; height: auto; box-shadow: 0 4px 6px rgba(0,0,0,0.1); }
.article-content table { width: 100%; border-collapse: collapse; margin: 1.5rem 0; font-size: 0.9rem; }
.article-content th { background: #8B4513; color: #fff; padding: 0.75rem 1rem; text-align: left; }
.article-content td { border: 1px solid #e5e7eb; padding: 0.75rem 1rem; }
.article-content tr:nth-child(even) td { background: #f9fafb; }
.aspect-video { aspect-ratio: 16/9; }
.line-clamp-2 { overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.line-clamp-3 { overflow: hidden; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; }
