/* ============================================
   CATALOGUE PAGE - Microlab
   Styles dedies a la page catalogue produits
   ============================================ */

/* ---- LAYOUT GENERAL ---- */

.catalogue-main {
  padding-top: var(--header-height);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ---- BREADCRUMBS ---- */

.breadcrumbs-bar {
  background: var(--bg-light);
  border-bottom: 1px solid var(--border-color);
  padding: 0.85rem 0;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.85rem;
  flex-wrap: wrap;
}

.breadcrumbs a {
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.2s ease;
}
.breadcrumbs a:hover {
  color: var(--secondary-color);
}

.breadcrumb-sep {
  font-size: 1rem;
  color: var(--text-muted);
  opacity: 0.5;
}

.breadcrumb-current {
  color: var(--text-color);
  font-weight: 600;
}

/* ---- CATALOGUE LAYOUT (2 colonnes) ---- */

.catalogue-layout {
  flex: 1;
  background: var(--bg-color);
  padding: 1.5rem 0 3rem;
}

.catalogue-main .container {
  max-width: 1440px;
}

.catalogue-container {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
}

/* ---- SIDEBAR ---- */

.catalogue-sidebar {
  flex: 0 0 300px;
  background: var(--bg-light);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 1.25rem;
  position: sticky;
  top: calc(var(--header-height) + 1.5rem);
  max-height: calc(100vh - var(--header-height) - 3rem);
  overflow-y: auto;
  transition: transform 0.35s ease, visibility 0.35s ease;
}

.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}
.sidebar-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary-color);
  margin: 0;
}
.sidebar-close {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 0.25rem;
  border-radius: 50%;
  transition: var(--transition);
}
.sidebar-close:hover {
  color: var(--text-color);
  background: rgba(0,0,0,0.05);
}

/* Sidebar sections */
.sidebar-section {
  margin-bottom: 1.5rem;
}
.sidebar-section h4 {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 0.75rem;
}

/* Category list */
.category-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.category-item {
  margin-bottom: 0.15rem;
}

.category-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.5rem 0.65rem;
  background: none;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-family: var(--font-family);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-color);
  transition: var(--transition);
  text-align: left;
  gap: 0.5rem;
}
.category-btn:hover {
  background: rgba(99,102,241,0.06);
  color: var(--secondary-color);
}
.category-btn.active {
  background: rgba(99,102,241,0.1);
  color: var(--secondary-color);
  font-weight: 600;
}

.category-btn-left {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex: 1;
  min-width: 0;
}
.category-btn-left .material-icons {
  font-size: 1.1rem;
  flex-shrink: 0;
}
.category-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-count {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-color);
  padding: 0.1rem 0.45rem;
  border-radius: 50px;
  flex-shrink: 0;
  border: 1px solid var(--border-color);
}
.category-btn.active .category-count {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
}

.category-toggle {
  font-size: 1rem;
  transition: transform 0.25s ease;
  color: var(--text-muted);
  flex-shrink: 0;
}
.category-item.open > .category-btn .category-toggle {
  transform: rotate(180deg);
}

/* Subcategory list */
.subcategory-list {
  list-style: none;
  padding: 0 0 0 1.2rem;
  margin: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease;
}
.category-item.open > .subcategory-list {
  max-height: 600px;
}

.subcategory-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0.35rem 0.5rem;
  background: none;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-family: var(--font-family);
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--text-light);
  transition: var(--transition);
  text-align: left;
  gap: 0.35rem;
}
.subcategory-btn:hover {
  background: rgba(99,102,241,0.06);
  color: var(--secondary-color);
}
.subcategory-btn.active {
  background: rgba(99,102,241,0.08);
  color: var(--secondary-color);
  font-weight: 600;
}
.subcategory-btn .category-count {
  font-size: 0.65rem;
}

/* Price filter */
.price-filter {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.price-inputs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.price-input-wrap {
  flex: 1;
  position: relative;
}
.price-currency {
  position: absolute;
  left: 0.5rem;
  top: 50%;
  transform: translateY(-50%);
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  pointer-events: none;
}
.price-input-wrap input {
  width: 100%;
  padding: 0.5rem 0.5rem 0.5rem 2.2rem;
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  font-family: var(--font-family);
  font-size: 0.85rem;
  color: var(--text-color);
  background: var(--bg-color);
  outline: none;
  transition: var(--transition);
}
.price-input-wrap input:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 2px rgba(99,102,241,0.12);
}
.price-dash {
  font-weight: 600;
  color: var(--text-muted);
}
.btn-apply-price {
  padding: 0.5rem 1rem;
  background: var(--secondary-color);
  color: #fff;
  border: none;
  border-radius: 8px;
  font-family: var(--font-family);
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}
.btn-apply-price:hover {
  background: var(--secondary-hover);
}

/* Reset button */
.btn-reset-filters {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  width: 100%;
  padding: 0.6rem 1rem;
  background: transparent;
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  font-family: var(--font-family);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-light);
  cursor: pointer;
  transition: var(--transition);
}
.btn-reset-filters:hover {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}
.btn-reset-filters .material-icons {
  font-size: 1rem;
}

/* ---- SIDEBAR OVERLAY (mobile) ---- */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 998;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.sidebar-overlay.active {
  opacity: 1;
}

/* ---- MAIN CONTENT ---- */

.catalogue-content {
  flex: 1;
  min-width: 0;
}

/* ---- TOOLBAR ---- */

.catalogue-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  background: var(--bg-light);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  padding: 0.75rem 1rem;
}

.toolbar-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.btn-filter-toggle {
  display: none;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.75rem;
  background: var(--bg-color);
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  font-family: var(--font-family);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-color);
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}
.btn-filter-toggle:hover {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}
.btn-filter-toggle .material-icons {
  font-size: 1.1rem;
}

/* Search bar */
.search-bar-catalogue {
  position: relative;
  display: flex;
  align-items: center;
  flex: 1;
  max-width: 400px;
}
.search-bar-catalogue .search-icon {
  position: absolute;
  left: 0.75rem;
  color: var(--text-muted);
  pointer-events: none;
  font-size: 1.2rem;
}
.search-bar-catalogue input {
  width: 100%;
  padding: 0.55rem 2.25rem 0.55rem 2.5rem;
  border: 1.5px solid var(--border-color);
  border-radius: 50px;
  font-family: var(--font-family);
  font-size: 0.875rem;
  color: var(--text-color);
  background: var(--bg-color);
  outline: none;
  transition: var(--transition);
}
.search-bar-catalogue input:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
}
.search-clear-btn {
  position: absolute;
  right: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  padding: 0.15rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.search-clear-btn:hover {
  color: var(--text-color);
  background: rgba(0,0,0,0.05);
}
.search-clear-btn .material-icons {
  font-size: 1rem;
}

/* Counter */
.toolbar-counter {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
  white-space: nowrap;
}
.toolbar-counter #results-count {
  font-weight: 700;
  color: var(--secondary-color);
}

/* Sort */
.toolbar-sort select {
  padding: 0.45rem 2rem 0.45rem 0.75rem;
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  font-family: var(--font-family);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-color);
  background: var(--bg-color);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23555577' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.6rem center;
  outline: none;
  transition: var(--transition);
}
.toolbar-sort select:focus {
  border-color: var(--secondary-color);
}

/* View toggle */
.toolbar-view {
  display: flex;
  border: 1.5px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
}
.view-btn {
  padding: 0.4rem 0.5rem;
  background: var(--bg-color);
  border: none;
  cursor: pointer;
  color: var(--text-muted);
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
.view-btn:first-child {
  border-right: 1px solid var(--border-color);
}
.view-btn.active {
  background: var(--secondary-color);
  color: #fff;
}
.view-btn:hover:not(.active) {
  color: var(--secondary-color);
}
.view-btn .material-icons {
  font-size: 1.2rem;
}

/* ---- ACTIVE FILTERS CHIPS ---- */

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}
.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem 0.65rem;
  background: rgba(99,102,241,0.08);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--secondary-color);
}
.filter-chip-remove {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--secondary-color);
  display: flex;
  align-items: center;
  padding: 0;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}
.filter-chip-remove:hover {
  opacity: 1;
}
.filter-chip-remove .material-icons {
  font-size: 0.9rem;
}

/* ---- PRODUCTS GRID ---- */

.products-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

/* Product card - Grid view */
.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  display: flex;
  flex-direction: column;
  animation: fadeInUp 0.3s ease forwards;
  opacity: 0;
}
.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.product-card-img {
  position: relative;
  aspect-ratio: 1 / 1;
  background: #f1f5f9;
  overflow: hidden;
}
.product-card-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.5rem;
  transition: transform 0.4s ease;
}
.product-card:hover .product-card-img img {
  transform: scale(1.06);
}
.product-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(99,102,241,0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.product-card-overlay .material-icons {
  font-size: 2rem;
  color: #fff;
}
.product-card:hover .product-card-overlay {
  opacity: 1;
}

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

.product-card-cat {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--secondary-color);
  text-transform: uppercase;
  letter-spacing: 0.75px;
}

.product-card-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--primary-color);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.product-card-price {
  margin-top: auto;
  padding-top: 0.5rem;
  display: flex;
  align-items: baseline;
  gap: 0.25rem;
}
.product-card-price .price-amount {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--secondary-color);
}
.product-card-price .price-suffix {
  font-size: 0.65rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* ---- PRODUCTS LIST VIEW ---- */

.products-grid.list-view {
  grid-template-columns: 1fr;
  gap: 0.5rem;
}

.products-grid.list-view .product-card {
  flex-direction: row;
  align-items: center;
}
.products-grid.list-view .product-card-img {
  flex: 0 0 70px;
  width: 70px;
  height: 70px;
  aspect-ratio: auto;
  border-radius: 8px;
  margin: 0.5rem;
}
.products-grid.list-view .product-card-img img {
  padding: 0.25rem;
}
.products-grid.list-view .product-card-overlay {
  display: none;
}
.products-grid.list-view .product-card-body {
  flex-direction: row;
  align-items: center;
  gap: 1rem;
  padding: 0.65rem 1rem;
  flex: 1;
}
.products-grid.list-view .product-card-cat {
  display: none;
}
.products-grid.list-view .product-card-name {
  flex: 1;
  -webkit-line-clamp: 1;
  font-size: 0.875rem;
}
.products-grid.list-view .product-card-list-cat {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
  min-width: 100px;
}
.products-grid.list-view .product-card-price {
  margin-top: 0;
  padding-top: 0;
  flex-shrink: 0;
  min-width: 80px;
  justify-content: flex-end;
}

/* Hide list-cat in grid */
.product-card-list-cat {
  display: none;
}

/* ---- SKELETON LOADING ---- */

.skeleton-card {
  background: var(--bg-light);
  border-radius: var(--border-radius);
  border: 1px solid var(--border-color);
  overflow: hidden;
  animation: skeleton-pulse 1.5s ease-in-out infinite;
}
.skeleton-card::before {
  content: '';
  display: block;
  aspect-ratio: 1 / 1;
  background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
}
.skeleton-card::after {
  content: '';
  display: block;
  height: 80px;
  margin: 0.85rem;
  background: linear-gradient(90deg, #e2e8f0 25%, #f1f5f9 50%, #e2e8f0 75%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.5s ease-in-out infinite;
  border-radius: 6px;
}

@keyframes skeleton-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}
@keyframes skeleton-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---- EMPTY STATE ---- */

.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  color: var(--text-muted);
}
.empty-state .material-icons {
  font-size: 4rem;
  display: block;
  margin-bottom: 1rem;
  opacity: 0.4;
}
.empty-state h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-color);
  margin-bottom: 0.5rem;
}
.empty-state p {
  font-size: 0.95rem;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}
.btn-empty-reset {
  margin: 0 auto;
}

/* ---- PAGINATION ---- */

.catalogue-pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
  flex-wrap: wrap;
}
.pagination-info {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}
.pagination-controls {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.pagination-btn {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-color);
  cursor: pointer;
  transition: var(--transition);
}
.pagination-btn:hover:not(:disabled) {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
}
.pagination-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}
.pagination-numbers {
  display: flex;
  gap: 0.25rem;
}
.page-num-btn {
  min-width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-color);
  cursor: pointer;
  font-family: var(--font-family);
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition);
  padding: 0 0.4rem;
}
.page-num-btn:hover:not(.active) {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}
.page-num-btn.active {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
}
.page-ellipsis {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  color: var(--text-muted);
  font-weight: 600;
}

/* ---- PRODUCT MODAL ---- */

.product-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 1.5rem;
}
.product-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.product-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 22, 40, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
}

.product-modal-content {
  position: relative;
  z-index: 2;
  background: var(--bg-color);
  border-radius: var(--border-radius-xl);
  max-width: 880px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 25px 80px rgba(0,0,0,0.3);
  transform: translateY(25px) scale(0.96);
  transition: transform 0.35s ease;
}
.product-modal.active .product-modal-content {
  transform: translateY(0) scale(1);
}

.product-modal-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 3;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255,255,255,0.9);
  border: 1px solid var(--border-color);
  color: var(--text-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.product-modal-close:hover {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
  transform: rotate(90deg);
}

.product-modal-body {
  display: flex;
}

.product-modal-img {
  flex: 0 0 45%;
  min-height: 380px;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: var(--border-radius-xl) 0 0 var(--border-radius-xl);
}
.product-modal-img img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
}

.product-modal-info {
  flex: 1;
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.product-modal-cat {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--secondary-color);
  color: #fff;
  padding: 0.3rem 0.85rem;
  border-radius: 50px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.75px;
  width: fit-content;
}

.product-modal-info h2 {
  font-size: 1.4rem;
  font-weight: 800;
  color: var(--primary-color);
  line-height: 1.3;
  margin: 0;
}

.product-modal-desc {
  font-size: 0.9rem;
  color: var(--text-light);
  line-height: 1.7;
  margin: 0;
}

.product-modal-subcats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}
.subcat-tag {
  background: var(--bg-light);
  color: var(--text-light);
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.65rem;
  border-radius: 50px;
  border: 1px solid var(--border-color);
}

.product-modal-price-block {
  background: linear-gradient(135deg, rgba(99,102,241,0.06), rgba(16,185,129,0.04));
  border: 1px solid rgba(99,102,241,0.15);
  border-radius: var(--border-radius);
  padding: 1rem 1.25rem;
  margin-top: 0.25rem;
}
.modal-price-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.modal-price-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--secondary-color);
}

.product-modal-actions {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.product-modal-actions .btn {
  width: 100%;
  justify-content: center;
  padding: 0.7rem 1.5rem;
  font-size: 0.9rem;
}
.btn-outline-dark {
  background: transparent;
  border: 1.5px solid var(--border-color);
  color: var(--text-color);
}
.btn-outline-dark:hover {
  border-color: var(--secondary-color);
  color: var(--secondary-color);
}

/* ---- QUOTE REQUEST MODAL ---- */

.quote-modal {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 1.5rem;
}
.quote-modal.active {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.quote-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 22, 40, 0.88);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
}

.quote-modal-content {
  position: relative;
  z-index: 2;
  background: var(--bg-color);
  border-radius: var(--border-radius-xl);
  max-width: 560px;
  width: 100%;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 25px 80px rgba(0,0,0,0.3);
  transform: translateY(25px) scale(0.96);
  transition: transform 0.35s ease;
  padding: 2rem;
}
.quote-modal.active .quote-modal-content {
  transform: translateY(0) scale(1);
}

.quote-modal-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  z-index: 3;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--bg-light);
  border: 1px solid var(--border-color);
  color: var(--text-light);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}
.quote-modal-close:hover {
  background: var(--secondary-color);
  color: #fff;
  border-color: var(--secondary-color);
  transform: rotate(90deg);
}

.quote-modal-header {
  text-align: center;
  margin-bottom: 1.5rem;
}
.quote-modal-icon {
  font-size: 2.5rem;
  color: var(--secondary-color);
  display: block;
  margin-bottom: 0.5rem;
}
.quote-modal-header h2 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--primary-color);
  margin: 0 0 0.5rem;
}
.quote-modal-product-preview {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: linear-gradient(135deg, rgba(99,102,241,0.06), rgba(16,185,129,0.04));
  border: 1px solid rgba(99,102,241,0.15);
  border-radius: 50px;
  padding: 0.4rem 1rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--secondary-color);
  margin: 0;
}

/* Quote form */
.quote-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.quote-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.quote-form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}
.quote-form-group label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-color);
}
.quote-form-group input,
.quote-form-group textarea {
  padding: 0.65rem 0.85rem;
  border: 1.5px solid var(--border-color);
  border-radius: 10px;
  font-family: var(--font-family);
  font-size: 0.875rem;
  color: var(--text-color);
  background: var(--bg-light);
  outline: none;
  transition: var(--transition);
  resize: vertical;
}
.quote-form-group input:focus,
.quote-form-group textarea:focus {
  border-color: var(--secondary-color);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.1);
  background: var(--bg-color);
}
.quote-form-group input.invalid,
.quote-form-group textarea.invalid {
  border-color: #ef4444;
}

.quote-form-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}
.quote-form-actions .btn {
  flex: 1;
  justify-content: center;
  padding: 0.7rem 1rem;
  font-size: 0.875rem;
}

/* Success state */
.quote-success {
  text-align: center;
  padding: 2rem 1rem;
}
.quote-success-icon {
  font-size: 4rem;
  color: #10b981;
  display: block;
  margin-bottom: 1rem;
  animation: successPop 0.4s ease;
}
@keyframes successPop {
  0% { transform: scale(0); }
  50% { transform: scale(1.2); }
  100% { transform: scale(1); }
}
.quote-success h3 {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--primary-color);
  margin: 0 0 0.5rem;
}
.quote-success p {
  font-size: 0.9rem;
  color: var(--text-light);
  margin: 0 0 1.5rem;
}

/* ---- FOOTER ADJUSTMENTS ---- */

.catalogue-footer {
  margin-top: auto;
}
.catalogue-footer .footer-bottom {
  display: flex;
  justify-content: center;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1200px) {
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 1024px) {
  .catalogue-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    z-index: 999;
    width: 300px;
    max-width: 85vw;
    max-height: none;
    border-radius: 0;
    border: none;
    transform: translateX(-100%);
    visibility: hidden;
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
    padding-top: 1rem;
  }
  .catalogue-sidebar.open {
    transform: translateX(0);
    visibility: visible;
  }
  .sidebar-close {
    display: flex;
  }
  .sidebar-overlay.active {
    display: block;
  }
  .btn-filter-toggle {
    display: flex;
  }
  .catalogue-container {
    flex-direction: column;
  }
  .products-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .products-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .catalogue-toolbar {
    flex-direction: column;
    align-items: stretch;
  }
  .toolbar-left {
    flex-wrap: wrap;
  }
  .toolbar-right {
    justify-content: space-between;
    flex-wrap: wrap;
  }
  .search-bar-catalogue {
    max-width: none;
    width: 100%;
    order: 2;
    margin-top: 0.25rem;
  }
  .btn-filter-toggle {
    order: 1;
  }
  .toolbar-counter {
    flex: 1;
  }

  /* Quote modal mobile */
  .quote-modal {
    padding: 0;
  }
  .quote-modal-content {
    max-width: 100%;
    max-height: 100vh;
    border-radius: 0;
    padding: 1.25rem;
    padding-top: 3rem;
  }
  .quote-form-row {
    grid-template-columns: 1fr;
  }
  .quote-form-actions {
    flex-direction: column-reverse;
  }

  .product-modal {
    padding: 0;
  }
  .product-modal-content {
    max-width: 100%;
    max-height: 100vh;
    height: 100%;
    border-radius: 0;
  }
  .product-modal-body {
    flex-direction: column;
    height: 100%;
  }
  .product-modal-img {
    flex: none;
    min-height: 200px;
    max-height: 240px;
    border-radius: 0;
  }
  .product-modal-info {
    padding: 1.25rem;
    overflow-y: auto;
    flex: 1;
  }
  .product-modal-info h2 {
    font-size: 1.2rem;
  }
  .product-modal-close {
    top: 0.5rem;
    right: 0.5rem;
    background: rgba(0,0,0,0.5);
    border: none;
    color: #fff;
  }
  .modal-price-value {
    font-size: 1.5rem;
  }

  .catalogue-pagination {
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
  }

  /* List view adjustments */
  .products-grid.list-view .product-card-body {
    flex-wrap: wrap;
    gap: 0.25rem 0.75rem;
  }
  .products-grid.list-view .product-card-list-cat {
    display: none;
  }
}

@media (max-width: 480px) {
  .products-grid {
    grid-template-columns: 1fr;
  }
  .catalogue-layout {
    padding: 1rem 0 2rem;
  }
  .product-card-body {
    padding: 0.65rem;
  }
  .pagination-numbers {
    gap: 0.15rem;
  }
  .page-num-btn {
    min-width: 32px;
    height: 32px;
    font-size: 0.8rem;
  }
}
