/* ============================================================
   MUSCLE BOOSTER NUTRITION
   Layout / styling modelled on musclemarvelnutrition.in
   ============================================================ */

:root {
  --red: #DD2121;
  --black: #000000;
  --grey-card: #F3F3F3;
  --grey-text: #5E5E5E;
  --white: #ffffff;
  --slider-ease: cubic-bezier(0.25, 0.46, 0.45, 0.94); /* easeOutQuad */
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Poppins", Arial, Helvetica, sans-serif;
  background: var(--white);
  color: #000;
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

.btn-black {
  display: inline-block;
  background: var(--black);
  color: #fff;
  border: 0;
  border-radius: 5px;
  padding: 10px 22px;
  font-family: "Poppins", sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity .2s;
}
.btn-black:hover { opacity: .85; }
.btn-black.block { display: block; width: 100%; text-align: center; }

/* ===================== HEADER ===================== */
.site-header {
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 1px 6px rgba(0, 0, 0, .08);
}
.header-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 12px 30px;
  display: flex;
  align-items: center;
  gap: 20px;
}

.logo { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.logo-mark {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  background: var(--red);
  color: #fff;
  font-weight: 700;
  font-size: 17px;
  letter-spacing: .5px;
  border-radius: 6px;
  transform: skewX(-8deg);
}
.logo-text { display: flex; flex-direction: column; line-height: 1.05; }
.logo-line { font-size: 15px; font-weight: 700; letter-spacing: 1px; }
.logo-sub { font-size: 10px; font-weight: 500; letter-spacing: 4.5px; color: var(--grey-text); }

.main-nav { flex: 1; display: flex; justify-content: center; }
.main-nav ul { display: flex; gap: 30px; }
.main-nav a {
  font-family: Arial, Helvetica, sans-serif;
  font-size: 15px;
  color: var(--grey-text);
  padding: 8px 0;
  display: block;
  position: relative;
}
.main-nav a:hover, .main-nav a.active { color: #000; }
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 2px;
  width: 0; height: 2px;
  background: var(--red);
  transition: width .25s;
}
.main-nav a:hover::after { width: 100%; }

.header-tools { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.icon-btn {
  background: none; border: 0; cursor: pointer;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: #000;
  transition: background .2s, color .2s;
}
.icon-btn svg { fill: currentColor; }
.icon-btn:hover { background: #000; color: #fff; }

.cart-wrap { position: relative; }
.cart-icon { position: relative; }
.cart-count {
  position: absolute;
  top: 0; right: 0;
  background: #000;
  color: #fff;
  font-size: 10px;
  font-weight: 600;
  min-width: 17px; height: 17px;
  border-radius: 50%;
  display: grid; place-items: center;
  border: 2px solid #fff;
}
.cart-popup {
  position: absolute;
  top: 54px; right: 0;
  width: 300px;
  background: #fff;
  border: 1px solid #e6e6e6;
  border-radius: 6px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, .15);
  padding: 18px;
  display: none;
}
.cart-popup.show { display: block; }
.cart-popup h4 { font-size: 14px; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 12px; }
.cart-empty { font-size: 14px; color: var(--grey-text); }
.cart-line { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid #f0f0f0; }
.cart-line img { width: 44px; height: 44px; object-fit: cover; border-radius: 4px; }
.cart-line .cl-name { font-size: 12px; font-weight: 600; line-height: 1.3; }
.cart-line .cl-price { font-size: 12px; color: var(--grey-text); }
.cart-line button { margin-left: auto; border: 0; background: none; cursor: pointer; color: #999; font-size: 18px; }
.cart-foot { margin-top: 14px; }
.cart-total { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 10px; }

.menu-toggle { display: none; background: none; border: 0; cursor: pointer; flex-direction: column; gap: 5px; padding: 6px; }
.menu-toggle span { width: 24px; height: 2px; background: #000; display: block; }

/* search drawer */
.search-bar { display: none; border-top: 1px solid #eee; background: #fafafa; }
.search-bar.show { display: block; }
.search-inner { max-width: 1400px; margin: 0 auto; padding: 14px 30px; display: flex; gap: 10px; }
.search-inner select, .search-inner input {
  border: 1px solid #ddd;
  border-radius: 5px;
  padding: 10px 12px;
  font-family: "Poppins", sans-serif;
  font-size: 14px;
  background: #fff;
}
.search-inner input { flex: 1; }

/* ===================== HERO SLIDER ===================== */
.slider {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #0b0b12;
}
.slider-viewport { width: 100%; overflow: hidden; }
.slider-track {
  display: flex;
  width: 100%;
  will-change: transform;
}
.slide {
  flex: 0 0 100%;
  width: 100%;
  display: block;
}
.slide img {
  width: 100%;
  aspect-ratio: 16 / 5;   /* 1920x600 like the source slider */
  object-fit: cover;
  object-position: center;
}

.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px; height: 32px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  opacity: 0;
  transition: opacity .4s;
  z-index: 5;
}
.slider-arrow.prev { left: 15px; }
.slider-arrow.next { right: 15px; }
.slider:hover .slider-arrow { opacity: 1; }
.slider-arrow:focus-visible { opacity: 1; outline: 2px solid #fff; }

@media (max-width: 700px) {
  .slider-arrow { display: none; }   /* hidden on mobile portrait, as on the source site */
}

/* ===================== SECTIONS ===================== */
.section-title {
  font-family: "Poppins", sans-serif;
  font-size: 25px;
  font-weight: 600;
  color: #000;
  text-align: left;
  margin: 0 0 22px;
}

.products { padding: 46px 0 20px; }

.filter-row { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 28px; }
.filter {
  border: 1px solid #ddd;
  background: #fff;
  border-radius: 5px;
  padding: 8px 18px;
  font-family: "Poppins", sans-serif;
  font-size: 13px;
  font-weight: 500;
  color: var(--grey-text);
  cursor: pointer;
  transition: all .2s;
}
.filter:hover { border-color: #000; color: #000; }
.filter.active { background: var(--red); border-color: var(--red); color: #fff; }

/* product grid — 3 across, 35px gap */
.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 35px;
}

/* red plate behind a light card, exactly like the source cards */
.product-card {
  background: var(--red);
  box-shadow: 2px 2px 20px 0 rgba(0, 0, 0, .5);
  margin-bottom: 7px;
  display: flex;
  flex-direction: column;
}
.product-inner {
  background: var(--grey-card);
  border-radius: 20px;
  padding-bottom: 2em;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.product-thumb { overflow: hidden; border-radius: 20px 20px 0 0; }
.product-thumb img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 20px 20px 0 0;
  transition: transform 2.6s ease;
}
.product-card:hover .product-thumb img { transform: scale(1.08); }

.product-name {
  font-family: "Roboto Slab", serif;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.4;
  padding: 14px 1em 0;
}
.product-size {
  font-size: 12px;
  color: var(--grey-text);
  padding: 4px 1em 0;
  letter-spacing: .3px;
}
.product-price {
  font-family: "Poppins", sans-serif;
  color: #000;
  font-size: 15px;
  padding: 6px 1em 12px;
  display: flex;
  gap: 8px;
  align-items: baseline;
}
.product-price del { color: #8a8a8a; font-size: 13px; }
.product-price ins { text-decoration: none; font-weight: 500; }
.product-actions { padding: 0 1em; margin-top: auto; }

/* ===================== ABOUT ===================== */
.about { padding: 50px 0 10px; }
.about-inner { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: start; }
.about-inner p { font-size: 15px; color: #3a3a3a; margin-bottom: 12px; max-width: 640px; }
.about-points { display: grid; gap: 12px; }
.about-points li {
  background: var(--grey-card);
  border-left: 4px solid var(--red);
  border-radius: 6px;
  padding: 12px 16px;
  display: flex;
  flex-direction: column;
}
.about-points strong { font-size: 14px; }
.about-points span { font-size: 13px; color: var(--grey-text); }

/* ===================== INSTAGRAM ===================== */
.instagram { padding: 50px 0 60px; }
.insta-slider { position: relative; }

/* sliding strip — 3 tiles per view, same tile size as the product grid */
.insta-track {
  display: flex;
  gap: 35px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
}
.insta-track::-webkit-scrollbar { display: none; }
.insta-track a {
  flex: 0 0 calc((100% - 70px) / 3);   /* 3 across minus 2 gaps */
  scroll-snap-align: start;
  display: block;
  overflow: hidden;
  border-radius: 20px;
  position: relative;
}
.insta-track img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; transition: transform .6s; }
.insta-track a:hover img { transform: scale(1.1); }

.insta-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px; height: 38px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, .55);
  display: grid; place-items: center;
  cursor: pointer;
  opacity: 0;
  transition: opacity .3s, background .2s;
  z-index: 5;
}
.insta-arrow.prev { left: -10px; }
.insta-arrow.next { right: -10px; }
.insta-arrow:hover { background: var(--red); }
.insta-slider:hover .insta-arrow { opacity: 1; }
.insta-arrow:focus-visible { opacity: 1; outline: 2px solid #000; }

/* ===================== FOOTER ===================== */
.site-footer {
  background: #000 url("assets/footer-bg.png") bottom right / cover no-repeat;
  color: #fff;
  padding: 56px 0 0;
  margin-top: 20px;
}
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; padding-bottom: 40px; }
.footer-col h4 {
  font-family: "Poppins", sans-serif;
  font-size: 17px;
  font-weight: 400;
  color: #fff;
  margin-bottom: 14px;
}
.footer-col li { font-size: 14px; font-weight: 300; color: rgba(255, 255, 255, .75); margin-bottom: 7px; }
.footer-col a { color: rgba(255, 255, 255, .75); transition: color .3s; }
.footer-col a:hover { color: #fff; }
.copyright {
  border-top: 1px solid rgba(255, 255, 255, .15);
  text-align: center;
  padding: 18px 20px;
  font-size: 13px;
  font-weight: 300;
  color: rgba(255, 255, 255, .8);
}

/* ===================== MODAL / TOAST ===================== */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .6);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 500;
  padding: 20px;
}
.modal.show { display: flex; }
.modal-box {
  background: #fff;
  border-radius: 8px;
  padding: 30px;
  width: 100%;
  max-width: 400px;
  position: relative;
}
.modal-box h3 { font-size: 20px; font-weight: 600; margin-bottom: 18px; }
.modal-box label { display: block; font-size: 13px; margin-bottom: 5px; }
.modal-box label span { color: var(--red); }
.modal-box input[type="text"], .modal-box input[type="password"] {
  width: 100%;
  border: 1px solid #ddd;
  border-radius: 5px;
  padding: 10px 12px;
  margin-bottom: 14px;
  font-family: "Poppins", sans-serif;
  font-size: 14px;
}
.form-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; font-size: 13px; }
.check { display: flex; align-items: center; gap: 6px; margin: 0; }
.modal-close { position: absolute; top: 10px; right: 14px; background: none; border: 0; font-size: 26px; line-height: 1; cursor: pointer; color: #888; }
.modal-foot { margin-top: 14px; font-size: 13px; }
.modal-foot a { color: var(--red); }

.toast {
  position: fixed;
  bottom: 26px; left: 50%;
  transform: translate(-50%, 24px);
  background: #000;
  color: #fff;
  padding: 12px 22px;
  border-radius: 6px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: all .3s;
  z-index: 600;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ===================== RESPONSIVE ===================== */
@media (max-width: 1024px) {
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 25px; }
  .insta-track { gap: 25px; }
  .insta-track a { flex-basis: calc((100% - 25px) / 2); }   /* 2 per view */
  .about-inner { grid-template-columns: 1fr; }
  .main-nav ul { gap: 18px; }
  .main-nav a { font-size: 14px; }
}

@media (max-width: 860px) {
  /* compact bar: hamburger left · logo centred · cart right */
  .header-inner { padding: 10px 14px; flex-wrap: wrap; gap: 0; }
  .menu-toggle { display: flex; order: 1; min-width: 44px; align-items: flex-start; }
  .logo { order: 2; margin: 0 auto; gap: 8px; }
  .header-tools { order: 3; min-width: 44px; justify-content: flex-end; gap: 4px; }
  #searchToggle { display: none; }        /* search bar is always visible on mobile */

  .main-nav {
    order: 4;
    flex: 0 0 100%;
    display: none;
    border-top: 1px solid #eee;
    margin-top: 10px;
    padding-top: 8px;
  }
  .main-nav.open { display: block; }
  .main-nav ul { flex-direction: column; gap: 0; }
  .main-nav a { padding: 11px 0; border-bottom: 1px solid #f2f2f2; }

  /* single rounded search control: icon + input + category, no visible split */
  .search-bar { display: block; border-top: 0; background: #fff; }
  .search-inner {
    margin: 0 14px 10px;
    padding: 0 12px;
    gap: 0;
    flex-wrap: nowrap;
    align-items: center;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
  }
  .search-inner input {
    order: 1;                 /* icon + input first, category last */
    flex: 1;
    min-width: 0;
    border: 0;
    border-radius: 0;
    outline: none;
    padding: 11px 8px 11px 26px;
    background: transparent url("data:image/svg+xml;charset=UTF-8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23888'%3E%3Cpath d='M15.5 14h-.79l-.28-.27A6.47 6.47 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5Zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14Z'/%3E%3C/svg%3E") no-repeat left center / 16px 16px;
  }
  .search-inner input::placeholder { color: #8a8a8a; }
  .search-inner select {
    order: 2;                 /* sits at the right edge of the same box */
    flex: 0 0 auto;
    width: auto;
    max-width: 34%;
    margin-left: auto;
    border: 0;
    border-radius: 0;
    outline: none;
    padding: 11px 0;
    background: transparent;
    color: var(--grey-text);
    font-size: 14px;
    text-align: right;
    text-align-last: right;
    text-overflow: ellipsis;
    -webkit-appearance: none;
    appearance: none;
  }
  #searchGo { display: none; }            /* Enter key / category change runs the search */
}

@media (max-width: 600px) {
  .product-grid { grid-template-columns: 1fr; }
  .insta-track a { flex-basis: 100%; }                      /* 1 per view, swipe to scroll */
  .insta-arrow { display: none; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .section-title { font-size: 21px; }
  .cart-popup { width: 260px; }
  .logo-mark { width: 34px; height: 34px; font-size: 14px; border-radius: 5px; }
  .logo-line { font-size: 13px; }
  .logo-sub { font-size: 8px; letter-spacing: 3px; }

  /* filters stay on one swipeable line instead of stacking */
  .filter-row {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin: 0 -20px 20px;
    padding: 0 20px 4px;
    scrollbar-width: none;
  }
  .filter-row::-webkit-scrollbar { display: none; }
  .filter { flex: 0 0 auto; white-space: nowrap; }
}
