/* =========================================================
   search.css (loaded AFTER stylesan.css)
   Scope: search results page only
   Goals:
   - Cart icon renders correctly (icon + badge aligned)
   - H1 sits 20px below header (reliable even with <br>)
   ========================================================= */

/* ---------- 1) Header: remove stray top whitespace ---------- */
html, body{
  margin: 0 !important;
  padding: 0 !important;
}

#mu-header,
#mu-header .navbar{
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  box-shadow: none !important;
  background: #fff !important;
}

#mu-header{
  border-bottom: 1px solid #e5e5e5 !important;
}

/* Bootstrap default adds bottom margin to navbar */
#mu-header .navbar{
  margin-bottom: 0 !important;
}

/* ---------- 2) H1: force 20px below nav/header ---------- */
/* Your page has: <section id="mu-chef"><br> ... so margin alone won't behave.
   We remove the <br> effect by zeroing the first element spacing and adding padding. */
#mu-chef{
  padding-top: 80px !important;   /* the actual 20px requirement */
}

/* If the theme has extra top padding/margin inside, normalise it */
#mu-chef .mu-chef-area,
#mu-chef .mu-rec-sold-title,
#mu-chef .mu-chef-area-squeeze{
  margin-top: 0 !important;
  padding-top: 0 !important;
}

/* Keep the H1 itself tidy */
#mu-chef .mu-chef-area-squeeze h1.newArrivals{
  margin-top: 0 !important;       /* spacing is controlled by #mu-chef padding */
}

/* ---------- 3) Cart icon: render via ::before (bulletproof) ---------- */
/* Ensure the link is a positioning context for the badge */
a.cartIconStyle{
  position: relative !important;
  display: inline-block !important;
  visibility: visible !important;
  opacity: 1 !important;
  line-height: 1 !important;
  text-decoration: none !important;
}

/* Hide any original <i> icon so we fully control output */
a.cartIconStyle i.fa{
  display: none !important;
}

/* Draw the cart color: lime !important; */
a.cartIconStyle::before{
  content: "\f07a" !important;              /* FontAwesome shopping-cart */
  font-family: "FontAwesome" !important;    /* FA4 */
  font-size: 25px !important;
  line-height: 25px !important;
  color: #008080 !important;
  display: inline-block !important;
}

/* Badge sits top-right of icon */
a.cartIconStyle #cartCount{
  position: absolute !important;
  top: 3px !important;
  right: -24px !important;
  z-index: 2 !important;
  margin: 0 !important;
  line-height: 1 !important;
  background: #777 !important;
  color: #fff !important;
}

/* ---------- 4) RESPONSIVE PLACEMENT ---------- */
/* Desktop: cart should sit in the normal nav flow (NOT fixed). */
@media (min-width: 1200px){
  a.cartIconStyle{
    position: absolute !important;
    top: 50% !important;
    right: 15px !important;
    transform: translateY(-50%) !important;
    z-index: 1001 !important;
  }
}

/* Mobile/tablet: cart pinned left of burger */
@media (max-width: 1199px){
  #mu-header{
    position: relative !important;
  }

  /* Burger top-right */
  #mu-header .navbar-toggle{
    position: absolute !important;
    top: 14px !important;
    right: 12px !important;
    margin: 0 !important;
    z-index: 1002 !important;
  }

  /* Cart left of burger */
  a.cartIconStyle{
    position: absolute !important;
    top: 14px !important;
    right: 78px !important; /* space for burger */
    transform: none !important;
    z-index: 1001 !important;
  }
}
@media (max-width: 767px){
  #mu-chef{
    padding-top: -195px !important;  /* more space on mobile */
  }
}
/* ===== Match nGroupFiltering product grid look & feel ===== */

.product-grid-wrapper { margin-top: 8px; }

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.product-card {
  background: #ffffff;
  border: 1px solid #ddd;
  border-radius: 6px;
  padding: 10px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(34,25,25,0.15);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.product-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(34,25,25,0.25);
}

.product-card a { color: inherit; text-decoration: none; }

.product-card img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 4px;
}

.product-title {
  font-family: 'Poppins', serif;
  font-size: 13px;
  font-weight: 500;
  color: #363636;
  margin-top: 8px;
  min-height: 36px;
  transition: all 0.25s ease;
}

.product-price {
  margin-top: 6px;
  font-family: 'Poppins', serif;
  font-size: 13px;
  color: #008080;
  font-weight: 600;
}

.product-price-sold { color: #cc0000; }

/* ===== Chic centred sort bar with background (same as nGroup) ===== */

.sort-wrapper {
  display: flex;
  justify-content: center;
  margin: 10px 0 15px;
}

.sort-bar-bg {
  background: #f6f8f8;
  padding: 6px 20px;
  border-radius: 12px;
  border: 1px solid #e0e5e5;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
  color:#008080;
}

.sort-tabs {
  display: flex;
  gap: 22px;
  align-items: center;
}

.sort-tab {
  font-family: 'Poppins', serif;
  font-size: 12px;
  color: #555;
  text-decoration: none;
  padding-bottom: 4px;
  position: relative;
  transition: all .25s ease;
}

.sort-tab:hover { color: #008080; }

.sort-tab.active {
  color: #008080;
  font-weight: 600;
}

.sort-tab.active::after {
  content: "";
  position: absolute;
  bottom: -2px;
  left: 0;
  height: 2px;
  width: 100%;
  background: #008080;
  border-radius: 1px;
}

.chev {
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-left: 3px;
  border-right: 1.3px solid currentColor;
  border-bottom: 1.3px solid currentColor;
  opacity: 0.7;
  transform: rotate(-45deg);
}
.chev.up { transform: rotate(-135deg); }
.chev.down { transform: rotate(45deg); }

.total-count {
  margin-top: 10px;
  font-size: 12px;
  color: #666;
  font-family: 'Poppins', serif;
}
#mu-chef h1.newArrivals{
  margin-top: 0 !important;
  padding-top: 0 !important;
}

@media (max-width: 767px){
  #mu-chef{
    margin-top: 20px !important;  /* adjust carefully */
    padding-top: 0 !important;
  }
}

