/* ==========================================================================
   Mina Group - Catalog & Product Grid Styles
   ========================================================================== */

.catalog-section {
  padding: 2.5rem 0 5rem;
}

/* Controls Bar (Tabs & Search) */
.catalog-controls-bar {
  background-color: #ffffff;
  padding: 1.5rem;
  border-radius: var(--radius-xl);
  box-shadow: 0 4px 20px -2px rgba(0, 0, 0, 0.06);
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  border: 1px solid var(--color-border);
  margin-bottom: 2rem;
}

.catalog-search-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.search-input-wrapper {
  position: relative;
  flex: 1;
  min-width: 280px;
}

.search-input-wrapper i {
  position: absolute;
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--color-accent-500);
  font-size: 1.1rem;
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 0.85rem 3rem 0.85rem 1.25rem;
  border: 1.5px solid var(--color-border);
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  outline: none;
  background-color: #f8fafc;
  transition: all var(--transition-fast);
}

.search-input:focus {
  border-color: var(--color-accent-500);
  background-color: #ffffff;
  box-shadow: 0 0 0 4px rgba(245, 158, 11, 0.15);
}

.results-count-badge {
  font-size: 0.88rem;
  color: var(--color-primary-950);
  font-weight: 700;
  background-color: var(--color-bg-subtle);
  padding: 0.55rem 1.25rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--color-border);
}

/* Category Tabs - Modern Refined Pill Style */
.category-tabs-wrapper {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding: 0.4rem 0.2rem 0.6rem;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.category-tabs-wrapper::-webkit-scrollbar {
  height: 5px;
}
.category-tabs-wrapper::-webkit-scrollbar-track {
  background: #f1f5f9;
  border-radius: 4px;
}
.category-tabs-wrapper::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.category-tab {
  background-color: #f8fafc;
  border: 1.5px solid #e2e8f0;
  color: #475569;
  padding: 0.7rem 1.35rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  transition: all var(--transition-normal);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.category-tab i {
  font-size: 1rem;
  color: #64748b;
  transition: transform var(--transition-fast), color var(--transition-fast);
}

.category-tab:hover {
  background-color: #ffffff;
  border-color: var(--color-accent-400);
  color: var(--color-primary-950);
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.06);
}

.category-tab:hover i {
  color: var(--color-accent-500);
  transform: scale(1.1);
}

.category-tab.active {
  background: linear-gradient(135deg, #0b1528 0%, #172554 100%);
  border-color: #0b1528;
  color: #ffffff;
  box-shadow: 0 6px 16px rgba(11, 21, 40, 0.28);
  transform: translateY(-1px);
}

.category-tab.active i {
  color: var(--color-accent-400);
  transform: scale(1.1);
}

/* Products Grid */
.products-grid-wrapper {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.75rem;
  margin-top: 1rem;
}

/* Product Card */
.product-card {
  background-color: #ffffff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: all var(--transition-normal);
  position: relative;
}

.product-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: var(--color-accent-400);
}

.product-card-top {
  position: absolute;
  top: 12px;
  right: 12px;
  left: 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 5;
}

.product-thumb-wrapper {
  background: radial-gradient(circle, #f8fafc 0%, #e2e8f0 100%);
  height: 230px;
  padding: 1.75rem 1rem 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  cursor: pointer;
  overflow: hidden;
}

.product-card-img {
  max-height: 190px;
  max-width: 90%;
  object-fit: contain;
  transition: transform var(--transition-smooth);
}

.product-card:hover .product-card-img {
  transform: scale(1.08);
}

.overlay-quickview {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(to top, rgba(6, 12, 24, 0.8), transparent);
  color: #ffffff;
  padding: 0.75rem;
  text-align: center;
  font-size: 0.82rem;
  font-weight: 700;
  opacity: 0;
  transform: translateY(10px);
  transition: all var(--transition-normal);
}

.product-card:hover .overlay-quickview {
  opacity: 1;
  transform: translateY(0);
}

.product-card-body {
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-cat-name {
  font-size: 0.75rem;
  color: var(--color-accent-600);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 0.25rem;
}

.product-card-title {
  font-size: 1.08rem;
  font-weight: 800;
  color: var(--color-primary-950);
  cursor: pointer;
  margin-bottom: 0.35rem;
  line-height: 1.35;
  transition: color var(--transition-fast);
}

.product-card-title:hover {
  color: var(--color-accent-600);
}

.product-card-spec {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  margin-bottom: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.product-card-spec i {
  color: var(--color-accent-500);
}

/* Packaging Selection Chips */
.product-packages-selection {
  margin-bottom: 1rem;
}

.pkg-select-label {
  font-size: 0.78rem;
  color: var(--color-text-light);
  display: block;
  margin-bottom: 0.35rem;
}

.pkg-chips {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
}

.pkg-chip {
  background-color: var(--color-bg-subtle);
  border: 1px solid var(--color-border);
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.pkg-chip:hover {
  border-color: var(--color-accent-500);
}

.pkg-chip.active {
  background-color: var(--color-primary-900);
  color: #ffffff;
  border-color: var(--color-primary-950);
}

/* Pricing */
.product-card-pricing {
  margin-top: auto;
  padding: 0.85rem 0 1rem;
  border-top: 1px dashed var(--color-border);
}

.price-display {
  display: flex;
  align-items: baseline;
  gap: 0.35rem;
}

.price-display .currency {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-text-muted);
}

.price-display .amount {
  font-size: 1.4rem;
  font-weight: 900;
  color: var(--color-primary-950);
  font-family: var(--font-heading);
}

.vat-tag {
  font-size: 0.72rem;
  color: var(--color-success);
  font-weight: 700;
  margin-right: auto;
}

.wholesale-hint {
  font-size: 0.75rem;
  color: var(--color-accent-600);
  margin-top: 0.25rem;
  background-color: var(--color-accent-50);
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-sm);
  display: inline-block;
}

/* Card Footer */
.product-card-footer {
  display: flex;
  gap: 0.5rem;
}

.product-card-footer .btn {
  flex: 1;
}

.no-results-box {
  grid-column: 1 / -1;
  text-align: center;
  padding: 4rem 1rem;
  background-color: #ffffff;
  border-radius: var(--radius-lg);
  border: 1px dashed var(--color-border);
}

.no-results-box i {
  font-size: 3rem;
  color: var(--color-text-light);
  margin-bottom: 1rem;
}

/* ==========================================================================
   CATALOG RESPONSIVE MEDIA QUERIES
   ========================================================================== */

@media (max-width: 1024px) {
  .catalog-section {
    padding: 2rem 0 4rem;
  }

  .products-grid-wrapper {
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.25rem;
  }

  .product-thumb-wrapper {
    height: 210px;
  }
}

@media (max-width: 768px) {
  .catalog-section {
    padding: 1.5rem 0 3.5rem;
  }

  .catalog-controls-bar {
    padding: 1rem;
    border-radius: var(--radius-lg);
    gap: 1rem;
    margin-bottom: 1.5rem;
  }

  .category-tab {
    padding: 0.55rem 1rem;
    font-size: 0.85rem;
  }

  .search-input {
    padding: 0.75rem 2.75rem 0.75rem 1rem;
    font-size: 0.9rem;
  }

  .results-count-badge {
    font-size: 0.82rem;
    padding: 0.45rem 1rem;
  }

  .product-card-title {
    font-size: 1rem;
  }
}

@media (max-width: 600px) {
  .products-grid-wrapper {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .catalog-search-row {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }

  .search-input-wrapper {
    min-width: 100%;
  }

  .results-count-badge {
    text-align: center;
    width: 100%;
  }

  .product-thumb-wrapper {
    height: 200px;
    padding: 1.25rem 1rem 0.75rem;
  }

  .product-card-img {
    max-height: 170px;
  }

  .product-card-body {
    padding: 1rem;
  }

  .price-display .amount {
    font-size: 1.25rem;
  }
}

@media (max-width: 360px) {
  .product-card-footer {
    flex-direction: column;
    gap: 0.5rem;
  }

  .product-card-footer .btn {
    width: 100%;
  }
}
