/* Seller Store Page Styles */

.seller-store-container {
  background: #f5f5f5;
  padding: 24px 0;
  min-height: calc(100vh - 200px);
}

/* 店招改为深色主题风格，背景深灰色，白色文字 */
/* Update store header max-width from 1200px to 1160px to match .wrap container */
.store-header-full {
  background: #2d2d2d;
  border: 1px solid #1a1a1a;
  border-radius: 12px;
  margin-bottom: 24px;
  max-width: 1160px;
  margin-left: auto;
  margin-right: auto;
  /* Match wrap padding */
  padding: 40px 24px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.store-header-full .store-title {
  font-size: 36px;
  font-weight: bold;
  margin: 0 0 12px;
  color: #ffffff;
  letter-spacing: -0.5px;
}

.store-header-full .store-description {
  font-size: 16px;
  color: #b0b0b0;
  margin: 0 0 20px;
  line-height: 1.6;
}

.store-header-full .store-tags {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.store-tag {
  padding: 8px 18px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 20px;
  font-size: 13px;
  color: #e0e0e0;
  transition: all 0.2s;
}

.store-tag:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: rgba(255, 255, 255, 0.3);
}

/* 左右布局：左侧导航栏 + 右侧内容区 */
.store-layout {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

/* Left Sidebar */
.store-sidebar {
  width: 260px;
  flex-shrink: 0;
  background: white;
  border-radius: 8px;
  border: 1px solid #e5e5e5;
  overflow: hidden;
}

/* 隐藏不需要的元素 */
.sidebar-logo {
  display: none;
}

.breadcrumb {
  display: none;
}

.store-header {
  display: none;
}

.sidebar-nav {
  padding: 8px 0;
  border-bottom: 1px solid #e5e5e5;
}

.sidebar-nav a.sidebar-nav-item {
  display: block;
  width: 100%;
  padding: 12px 24px;
  background: none;
  border: none;
  text-decoration: none;
  text-align: left;
  font-size: 15px;
  color: #333;
  cursor: pointer;
  transition: all 0.2s;
}

.sidebar-nav a.sidebar-nav-item:hover {
  background: #f5f5f5;
}

.sidebar-nav a.sidebar-nav-item.active {
  background: #f0f0f0;
  font-weight: 500;
  position: relative;
}

.sidebar-nav a.sidebar-nav-item.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: #333;
}

.sidebar-info {
  padding: 24px;
}

.sidebar-info-title {
  font-size: 16px;
  font-weight: bold;
  margin: 0 0 16px;
  color: #333;
}

.sidebar-info-item {
  display: flex;
  font-size: 13px;
  margin-bottom: 8px;
  color: #666;
}

.info-label {
  flex-shrink: 0;
  color: #888;
}

.info-value {
  color: #333;
}

/* Right Main Content */
.store-main {
  flex: 1;
  min-width: 0;
}

.action-buttons {
  display: flex;
  gap: 12px;
  margin-bottom: 24px;
}

.action-btn {
  flex: 1;
  padding: 12px 20px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 14px;
  color: #333;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
}

.action-btn:hover {
  background: #f9f9f9;
  border-color: #999;
}

.action-btn svg {
  flex-shrink: 0;
}

/* Add styles for category filters without gray background */
.category-filters {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px; /* Reduced from 24px to 20px */
  margin-top: 0; /* Ensure no top margin */
}

.category-btn {
  padding: 8px 16px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 14px;
  color: #333;
  cursor: pointer;
  transition: all 0.2s;
}

.category-btn:hover {
  border-color: #999;
  background: #f9f9f9;
}

/* Change active category button from blue to black */
.category-btn.active {
  background: #2d2d2d;
  color: white;
  border-color: #2d2d2d;
}

/* Content Wrapper */
.content-wrapper {
  background: white;
  border-radius: 8px;
  border: 1px solid #e5e5e5;
  /* Reduce top padding by 20px (from 24px to 4px) */
  padding: 4px 32px 24px 32px;
}

/* Add specific styling for booking services title */
.content-wrapper h2 {
  font-size: 20px;
  font-weight: bold;
  margin: 20px 0 24px; /* Added 20px top margin */
  color: #333;
}

.content-section {
  display: none;
}

.content-section.active {
  display: block;
}

.content-section h2 {
  font-size: 20px;
  font-weight: bold;
  margin: 0 0 16px;
  color: #333;
}

.content-section h3 {
  font-size: 18px;
  font-weight: bold;
  margin: 32px 0 16px;
  color: #333;
}

.content-section h3:first-child {
  margin-top: 0;
}

/* 添加商品分类卡片样式 */
.category-card {
  background: white;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  padding: 24px;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.category-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  border-color: #ccc;
}

.category-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  margin-bottom: 8px;
}

.category-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

.category-info {
  flex: 1;
}

.category-name {
  font-size: 16px;
  font-weight: bold;
  margin: 0 0 8px;
  color: #333;
}

.category-desc {
  font-size: 13px;
  color: #666;
  margin: 0 0 8px;
  line-height: 1.5;
}

.category-count {
  font-size: 12px;
  color: #888;
  margin: 0 0 12px;
}

.category-link {
  display: inline-block;
  font-size: 13px;
  color: #0066cc;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s;
}

.category-link:hover {
  color: #0052a3;
  text-decoration: underline;
}

.loading-message,
.error-message,
.empty-message {
  padding: 40px 20px;
  text-align: center;
  font-size: 14px;
  color: #888;
}

.error-message {
  color: #d32f2f;
}

/* Info Cards */
.info-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 32px;
  /* Add 20px spacing above info cards section */
  margin-top: 20px;
}

.info-card {
  padding: 20px;
  background: #f9f9f9;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
}

.info-card h3 {
  font-size: 16px;
  font-weight: bold;
  margin: 0 0 12px;
  color: #333;
}

.info-card p {
  font-size: 14px;
  color: #666;
  margin: 4px 0;
  line-height: 1.6;
}

/* Announcements */
.announcements-section {
  margin-bottom: 32px;
}

.announcements-list {
  list-style: disc;
  padding-left: 24px;
  margin: 0;
}

.announcements-list li {
  font-size: 14px;
  color: #666;
  margin-bottom: 8px;
  line-height: 1.6;
}

/* Map Placeholder */
.map-placeholder {
  height: 240px;
  background: #f5f5f5;
  border: 1px solid #e0e0e0;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 32px;
}

.map-placeholder p {
  font-size: 14px;
  color: #999;
  margin: 0;
}

/* Services Grid */
.services-section {
  margin-bottom: 32px;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.service-card {
  padding: 20px;
  background: #f9f9f9;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  text-align: center;
}

.service-card h4 {
  font-size: 15px;
  font-weight: bold;
  margin: 0 0 8px;
  color: #333;
}

.service-card p {
  font-size: 13px;
  color: #888;
  margin: 0;
  line-height: 1.5;
}

/* Products Grid */
.section-hint {
  font-size: 13px;
  color: #888;
  margin: 0 0 8px;
}

/* Ensure products grid is properly displayed with fixed 3-column layout */
.products-grid {
  display: grid !important;
  grid-template-columns: repeat(3, 1fr) !important;
  gap: 24px !important;
  margin-top: 16px; /* Reduced from 24px to 16px to move products closer to filters */
  width: 100%;
}

.product-card {
  background: white;
  border: 1px solid #e5e5e5;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
  transform: translateY(-4px);
}

/* Product image wrapper with badges */
/* Add better image loading states */
.product-image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  background: #f8f8f8;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.product-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  background: #f0f0f0;
}

.product-card:hover .product-image {
  transform: scale(1.05);
}

/* Product badges (NEW, SALE) */
.product-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: bold;
  color: white;
  z-index: 1;
}

.badge-new {
  background: #2d2d2d;
}

.badge-sale {
  background: #e53935;
}

/* Product info section */
.product-info {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.product-category-badge {
  display: inline-block;
  padding: 4px 12px;
  background: #f5f5f5;
  color: #666;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-radius: 4px;
  width: fit-content;
}

.product-name {
  font-size: 16px;
  font-weight: 600;
  color: #2d2d2d;
  margin: 0;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  min-height: 44px;
}

/* Price section with old price strikethrough */
.product-price-section {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 4px 0;
}

.product-price {
  font-size: 24px;
  font-weight: 700;
  color: #2d2d2d;
}

.product-price-old {
  font-size: 14px;
  color: #999;
  text-decoration: line-through;
}

/* Star rating section */
.product-rating {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 4px 0;
}

.stars {
  color: #ffc107;
  font-size: 14px;
  letter-spacing: 1px;
}

.rating-count {
  font-size: 13px;
  color: #666;
}

/* Add to cart button */
.product-btn-add-cart {
  width: 100%;
  padding: 14px 20px;
  background: #2d2d2d;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: auto;
}

.product-btn-add-cart:hover {
  background: #1a1a1a;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .store-layout {
    flex-direction: column;
  }

  .store-sidebar {
    width: 100%;
  }

  .info-cards {
    grid-template-columns: 1fr;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .products-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

@media (max-width: 640px) {
  .action-buttons {
    flex-direction: column;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .products-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}
