/* ========================================================
   Root Variables (Theme Colors)
   ======================================================== */
:root {
  --darkBg-color: #0f0f11;
  --blue: #3E2476;
  --orange: #F38429;
  --lightBlue: #4691CC;
  --green: #D2AC66;
  --red: #D9251B;
  --lightGrey: #EAF2F1;
}

body {
  background-color: #f7f9fa;
  color: var(--darkBg-color);
  font-family: 'Outfit', sans-serif;
}

/* ========================================================
   Mobile Filter Sticky Bar
   ======================================================== */
.mobile-filter-bar {
  border-color: var(--lightGrey) !important;
  z-index: 1020;
}

.btn-filter-mobile {
  background-color: var(--orange);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 6px;
  border: none;
}

.btn-filter-mobile:hover,
.btn-filter-mobile:focus {
  background-color: var(--blue);
  color: #ffffff;
}

.text-brand-orange {
  color: var(--orange);
}

/* ========================================================
   Sidebar & Filters
   ======================================================== */
.filter-sidebar-wrapper {
  border: 1px solid var(--lightGrey);
  box-shadow: 0 4px 12px rgba(15, 15, 17, 0.03);
}

.filter-main-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--darkBg-color);
}

.reset-filter-btn {
  font-size: 0.8rem;
  text-decoration: underline;
  transition: color 0.2s;
}

.reset-filter-btn:hover {
  color: var(--orange) !important;
}

.filter-group {
  border-bottom: 1px solid var(--lightGrey);
  padding: 10px 0;
}

.filter-group:last-child {
  border-bottom: none;
}

.filter-group-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  padding: 4px 0;
  user-select: none;
}

.filter-group-header h6 {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--darkBg-color);
}

.filter-group-header i {
  font-size: 0.7rem;
  color: #888;
  transition: transform 0.2s ease;
}

.filter-group-header.collapsed i {
  transform: rotate(-90deg);
}

.filter-group-body {
  padding-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  font-size: 0.82rem;
  cursor: pointer;
  color: #333;
}

.custom-checkbox input[type="checkbox"] {
  margin-right: 8px;
  accent-color: var(--blue);
  cursor: pointer;
}

.custom-checkbox .count {
  margin-left: auto;
  color: #888;
  font-size: 0.78rem;
}

.custom-range {
  accent-color: var(--orange);
}

/* ========================================================
   Catalog Header
   ======================================================== */
.catalog-header {
  border: 1px solid var(--lightGrey);
}

.catalog-main-heading {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--blue);
}

.catalog-desc {
  font-size: 0.84rem;
  line-height: 1.5;
}

.sort-select {
  border-color: var(--lightGrey);
  color: var(--darkBg-color);
  font-size: 0.82rem;
  cursor: pointer;
  width: auto;
}

.sort-select:focus {
  border-color: var(--lightBlue);
  box-shadow: 0 0 0 0.2rem rgba(70, 145, 204, 0.15);
}

/* ========================================================
   Product Cards
   ======================================================== */
.product-card {
  background: #ffffff;
  border: 1px solid var(--lightGrey);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 18px rgba(15, 15, 17, 0.08);
}

.discount-tag {
  position: absolute;
  top: 8px;
  left: 8px;
  background-color: var(--darkBg-color);
  color: #ffffff;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 3px;
  z-index: 2;
}

/* Responsive Image Container */
.product-thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 10px;
  background-color: #fafafa;
  border-radius: 4px;
}

.product-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}

.product-card:hover .product-thumb img {
  transform: scale(1.04);
}

.product-content {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

/* Small paragraph name truncated at 3 lines */
p.product-name {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--darkBg-color);
  line-height: 1.4;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 3.45em;
}

.price-box {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 4px;
}

.current-price {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--red);
}

.original-price {
  font-size: 0.78rem;
  color: #888;
  text-decoration: line-through;
}

.stock-status {
  font-size: 0.75rem;
  font-weight: 600;
}

.stock-status.in-stock {
  color: var(--green);
}

/* Action Buttons */
.btn-whatsapp {
  background-color: #25D366;
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
  padding: 8px 10px;
  border-radius: 5px;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: opacity 0.2s ease, filter 0.2s ease;
}

.btn-whatsapp:hover {
  filter: brightness(0.92);
  color: #ffffff;
}

.btn-know-more {
  background-color: var(--blue);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
  padding: 8px 10px;
  border-radius: 5px;
  text-decoration: none;
  transition: background-color 0.2s ease;
  border: none;
  display: block;
}

.btn-know-more:hover {
  background-color: var(--orange);
  color: #ffffff;
}

/* ========================================================
   Pagination
   ======================================================== */
.custom-pagination .page-link {
  color: var(--blue);
  border: 1px solid var(--lightGrey);
  font-size: 0.82rem;
  border-radius: 4px;
  padding: 5px 10px;
}

.custom-pagination .page-item.active .page-link {
  background-color: var(--blue);
  border-color: var(--blue);
  color: #ffffff;
}

.custom-pagination .page-link:hover {
  background-color: var(--lightGrey);
  color: var(--orange);
}

/* ========================================================
   Responsive Synchronization (Breakpoint: 991.98px / 992px)
   ======================================================== */
@media (max-width: 991.98px) {
  #desktopFilterSlot,
  aside.col-12.col-lg-3 {
    display: none !important;
  }
  
  .mobile-filter-bar {
    display: block !important;
  }

  .mobile-offcanvas-drawer {
    max-width: 320px;
    background-color: #ffffff;
  }

  .mobile-offcanvas-drawer .offcanvas-body {
    padding: 1rem;
    overflow-y: auto;
    max-height: calc(100vh - 65px);
  }

  .mobile-offcanvas-drawer #filterContainer {
    display: block !important;
    border: none;
    box-shadow: none;
    padding: 0 !important;
  }
}

@media (min-width: 992px) {
  .mobile-filter-bar {
    display: none !important;
  }
  
  #desktopFilterSlot,
  aside.col-12.col-lg-3 {
    display: block !important;
  }
}