/* Products page specific styles */

/* Category header with title and More link */
.category-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0;
  margin-top: 0;
}

.category-header h3 {
  margin: 0;
  font-size: 1.5rem;
}

/* Ensure h4 titles in category headers match More size */
.category-header h4 {
  margin: 0;
  font-size: 1.5rem;
}

/* Breadcrumb navigation */
.breadcrumb {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.breadcrumb a {
  color: var(--primary-color);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

.breadcrumb span {
  color: var(--text-muted);
}

/* Pagination section */
.pagination-section {
  margin-top: 3rem;
  padding: 2rem 0;
  border-top: 1px solid var(--border-color);
}

.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
}

.pagination-btn {
  padding: 0.75rem 1.5rem;
  background: white;
  color: var(--primary-color);
  text-decoration: none;
  border-radius: 6px;
  font-weight: 600;
  transition: all 0.3s ease;
  border: 2px solid var(--primary-color);
  cursor: pointer;
  display: inline-block;
  min-width: 100px;
  text-align: center;
  line-height: 1.5;
  white-space: nowrap;
}

.pagination-btn:hover {
  background: var(--primary-color);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.pagination-btn.disabled {
  background: #f5f5f5;
  color: #999;
  border-color: #ddd;
  cursor: not-allowed;
  pointer-events: none;
  opacity: 0.6;
}

.pagination-info {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1rem;
  color: var(--text-color);
}

.pagination-info .current-page {
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--primary-color);
}

.pagination-info .total-pages {
  font-weight: 600;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .category-header {
    gap: 0.75rem;
    align-items: baseline;
    justify-content: space-between;
  }
  
  .category-header h3 {
    font-size: 1.25rem;
  }
  
  .more-link {
    font-size: 1.25rem;
  }
  
  .pagination {
    flex-direction: column;
    gap: 1rem;
  }
  
  .pagination-btn {
    width: 100%;
    text-align: center;
  }
}

/* Gallery grid for photo pages (pic_full.php) */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

/* Workshop lists on production page: use flex with 4 per row */
.workshop-list {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 40px;
}

.workshop-list .case-item {
  flex: 0 0 calc((100% - 18px * 3) / 4);
}

/* Increase vertical spacing between workshop blocks */
.workshop-card .workshop-list {
  margin-top: 24px;   /* space below the title */
  margin-bottom: 32px;/* space before next title */
}

.workshop-card .category-header.mt-12 {
  margin-top: 40px;   /* larger gap between blocks */
}

@media (max-width: 992px) {
  .workshop-list .case-item {
    flex-basis: calc((100% - 18px * 2) / 3);
  }
  .workshop-card .category-header.mt-12 { margin-top: 32px; }
  .workshop-card .workshop-list { margin-bottom: 28px; }
}

@media (max-width: 576px) {
  .workshop-list .case-item {
    flex-basis: calc((100% - 18px) / 2);
  }
  .workshop-card .category-header.mt-12 { margin-top: 28px; }
  .workshop-card .workshop-list { margin-bottom: 24px; }
}

.gallery-card {
  display: block;
  background: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  text-decoration: none;
  color: inherit;
}

.gallery-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.gallery-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
}

.gallery-info {
  padding: 1rem;
}

.gallery-info h4 {
  margin: 0 0 0.5rem 0;
  font-size: 1rem;
  color: var(--text-color);
}

.gallery-info p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* Responsive gallery grid */
@media (max-width: 992px) {
  .gallery-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
  }
}

@media (max-width: 576px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .gallery-card img {
    height: 160px;
  }
}

/* Customers photo wall specific styles */
.customers-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 28px; /* increase spacing between items */
  margin-top: 2rem;
}

.customers-grid .product-card {
  text-decoration: none; /* remove underline if any */
  display: block;
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid #eef2f7;
  padding-bottom: 8px;
}

.customers-grid .product-card img {
  width: 100%;
  height: 160px; /* slightly smaller than default product images */
  object-fit: contain; /* preserve logo aspect */
  display: block;
  padding: 18px; /* add inner whitespace around image */
}

.customers-grid .product-card .info { text-align: center; padding-top: 6px; }
.customers-grid .product-card .info h4 { margin: 0; color: #000; font-weight: 700; font-size: 0.95rem; text-decoration: none; }

@media (max-width: 900px) {
  .customers-grid { gap: 20px; }
}

@media (max-width: 640px) {
  .customers-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .customers-grid .product-card img { height: 120px; padding: 12px; }
}

/* Product listing: ensure product names under images are centered, black, no underline */
.products-grid .product-card { text-decoration: none; display: block; color: inherit; }
.products-grid .product-card .info { text-align: center; padding-top: 6px; }
.products-grid .product-card .info h4 { margin: 0; color: #000; font-weight: 800; font-size: 1.05rem; text-decoration: none; }

/* General product-card title rules to cover popular, marquee, and other lists */
.product-card { text-decoration: none; color: inherit; }
.product-card .info { text-align: center; }
.product-card .info h4 { margin: 0; color: #000; font-weight: 700; font-size: 0.95rem; text-decoration: none; }

/* Marquee-style product cards (used on product_detail related products) */
.marquee-product-card { text-decoration: none; color: inherit; display: inline-block; }
.marquee-product-card h4 { margin: 6px 0 0 0; color: #000; font-weight: 700; text-align: center; text-decoration: none; font-size: 0.95rem; }

/* Example: category heading spacing override */
#category-signage h3,
#category-indoor h3,
#category-festival h3,
#category-custom h3,
#category-commercial h3,
#category-hospitality h3,
#category-art h3,
#category-outdoor h3 { margin-top: 12px; }

