/* 夏天商城手机端布局修复 - 确保顶部导航显示，移除多余元素 */

/* 确保页面从顶部开始 */
html, body {
  margin: 0 !important;
  padding: 0 !important;
  scroll-padding-top: 0 !important;
}

/* 确保顶部导航栏显示 */
header, .header, .top-bar, .top-nav, .navbar, nav {
  display: flex !important;
  position: sticky !important;
  top: 0 !important;
  z-index: 1000 !important;
  background: #fff !important;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06) !important;
}

/* 搜索栏确保显示 */
.search-bar, .search-box, .search-container {
  display: flex !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/* 隐藏底部多余的翻页箭头（非底部导航的箭头） */
.carousel-arrow, .slider-arrow, .swiper-button-prev, .swiper-button-next,
.prev-btn, .next-btn, [class*="carousel"] [class*="arrow"],
[class*="slider"] [class*="arrow"] {
  display: none !important;
}

/* 确保底部导航固定在底部 */
.bottom-nav, .tabbar, .footer-nav, [class*="bottom-nav"], [class*="tab-bar"] {
  position: fixed !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  z-index: 999 !important;
  background: #fff !important;
  border-top: 1px solid #eee !important;
  display: flex !important;
  justify-content: space-around !important;
  padding: 8px 0 !important;
  padding-bottom: calc(8px + env(safe-area-inset-bottom)) !important;
}

/* 底部导航项 */
.bottom-nav .nav-item, .tabbar .tab-item {
  flex: 1 !important;
  text-align: center !important;
  padding: 4px 0 !important;
}

/* 主内容区确保不被底部导航遮挡 */
.main-content, .content, #root, #app {
  padding-bottom: 60px !important;
  min-height: 100vh !important;
}

/* 商品列表确保从顶部开始 */
.product-list, .goods-list, .product-grid {
  padding-top: 10px !important;
  margin-top: 0 !important;
}

/* 隐藏任何多余的空白区域 */
[class*="empty"], [class*="placeholder"] {
  display: none !important;
}

/* 确保Banner区域正常显示 */
.banner, .carousel, .slider {
  display: block !important;
  visibility: visible !important;
  max-height: 200px !important;
  overflow: hidden !important;
}

/* 分类导航确保显示 */
.category-nav, .category-bar, .nav-icons {
  display: grid !important;
  grid-template-columns: repeat(5, 1fr) !important;
  gap: 8px !important;
  padding: 12px !important;
  background: #fff !important;
}

/* 修复商品卡片 */
.product-card, .goods-card {
  background: #fff !important;
  border-radius: 12px !important;
  overflow: hidden !important;
  margin-bottom: 10px !important;
}

.product-card img, .goods-card img {
  width: 100% !important;
  height: auto !important;
  display: block !important;
}

/* 价格样式 */
.price {
  color: #E02E24 !important;
  font-weight: 700 !important;
  font-size: 18px !important;
}

/* 销量样式 */
.sales {
  color: #999 !important;
  font-size: 12px !important;
}

/* 商品名称 */
.product-name, .goods-name {
  font-size: 14px !important;
  color: #333 !important;
  line-height: 1.4 !important;
  margin: 8px !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

/* 页脚样式 */
footer, .footer {
  background: #1A1A2E !important;
  color: #fff !important;
  padding: 20px !important;
  text-align: center !important;
  font-size: 12px !important;
  margin-bottom: 60px !important;
}

/* 移除任何可能导致内容偏移的样式 */
* {
  box-sizing: border-box !important;
}

/* 确保滚动正常 */
body {
  overflow-x: hidden !important;
  -webkit-overflow-scrolling: touch !important;
}
