/* MGL Shuddha — Shop Page CSS (assets/css/shop.css) */

.shop-layout { display: grid; grid-template-columns: 260px 1fr; gap: 28px; align-items: start; padding: 32px 0; }

/* --- Sidebar Filters --- */
.filter-sidebar {
  position: sticky;
  top: calc(var(--header-h) + 16px);
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
}
.filter-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  background: var(--maroon);
  color: var(--white);
}
.filter-header h3 { font-family: var(--font-body); font-size: 0.9rem; font-weight: 700; color: var(--white); }
.filter-clear-btn { font-size: 0.75rem; color: var(--gold-light); font-weight: 500; cursor: pointer; }
.filter-section { padding: 16px 20px; border-bottom: 1px solid var(--border); }
.filter-section:last-child { border-bottom: none; }
.filter-section-title {
  display: flex; align-items: center; justify-content: space-between;
  font-size: 0.82rem; font-weight: 700; color: var(--text-dark);
  margin-bottom: 12px; cursor: pointer;
}
.filter-section-title i { font-size: 0.7rem; color: var(--text-muted); transition: transform var(--transition); }
.filter-section-title.collapsed i { transform: rotate(-90deg); }
.filter-body {}
.filter-check {
  display: flex; align-items: center; gap: 10px;
  padding: 5px 0;
  cursor: pointer;
  font-size: 0.82rem;
  color: var(--text-mid);
  transition: color var(--transition);
}
.filter-check:hover { color: var(--maroon); }
.filter-check input[type="checkbox"] { accent-color: var(--maroon); width: 15px; height: 15px; flex-shrink: 0; }
.filter-check .count { margin-left: auto; font-size: 0.72rem; color: var(--text-light); }

/* Price Range */
.price-inputs { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.price-input {
  flex: 1; padding: 7px 10px; border: 1.5px solid var(--border);
  border-radius: var(--radius-sm); font-size: 0.8rem;
  text-align: center; outline: none;
}
.price-input:focus { border-color: var(--maroon); }
.price-sep { color: var(--text-muted); font-size: 0.75rem; }
input[type="range"] { width: 100%; accent-color: var(--maroon); }

/* Weight / Box tags */
.filter-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.filter-tag {
  padding: 5px 12px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-full);
  font-size: 0.75rem; font-weight: 600;
  color: var(--text-mid);
  cursor: pointer;
  transition: all var(--transition);
}
.filter-tag:hover, .filter-tag.active { background: var(--maroon); color: var(--white); border-color: var(--maroon); }

/* --- Shop Main --- */
.shop-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--white); border-radius: var(--radius-md);
  padding: 12px 18px; border: 1px solid var(--border);
  margin-bottom: 20px; gap: 12px; flex-wrap: wrap;
}
.shop-result-count { font-size: 0.85rem; color: var(--text-muted); }
.shop-result-count strong { color: var(--text-dark); }
.shop-toolbar-right { display: flex; align-items: center; gap: 12px; }
.sort-select {
  padding: 7px 32px 7px 12px; border: 1.5px solid var(--border);
  border-radius: var(--radius-md); font-size: 0.82rem;
  color: var(--text-dark); background: var(--white);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%234A4A4A' fill='none' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 10px center;
  outline: none; cursor: pointer;
}
.sort-select:focus { border-color: var(--maroon); }
.view-toggle { display: flex; border: 1.5px solid var(--border); border-radius: var(--radius-md); overflow: hidden; }
.view-btn {
  width: 34px; height: 34px; display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; color: var(--text-muted); cursor: pointer; transition: all var(--transition);
}
.view-btn.active, .view-btn:hover { background: var(--maroon); color: var(--white); }

/* List view */
.products-list .product-card {
  display: flex; flex-direction: row;
}
.products-list .product-card-img { width: 160px; flex-shrink: 0; aspect-ratio: auto; height: 160px; }
.products-list .product-card-body { flex: 1; }

/* Mobile filter button */
.mobile-filter-btn {
  display: none;
  position: fixed; bottom: 74px; left: 16px;
  z-index: 600;
  background: var(--maroon); color: var(--white);
  border-radius: var(--radius-full); padding: 10px 20px;
  font-size: 0.85rem; font-weight: 600;
  box-shadow: var(--shadow-lg);
  gap: 8px;
}

@media (max-width: 991px) {
  .shop-layout { grid-template-columns: 1fr; }
  .filter-sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 280px; z-index: 1000; transform: translateX(-100%); transition: transform 0.3s ease; border-radius: 0; overflow-y: auto; }
  .filter-sidebar.open { transform: translateX(0); }
  .mobile-filter-btn { display: flex; }
}
@media (max-width: 767px) {
  .shop-toolbar { flex-direction: column; align-items: flex-start; }
  .products-list .product-card { flex-direction: column; }
  .products-list .product-card-img { width: 100%; height: auto; }
}
