/* Merjema Shop 1.2 — isolated WooCommerce product and related-product layout. */
body.single-product .woocommerce div.product.ms-single-product,
body.single-product .ms-single-product {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  float: none !important;
  clear: both !important;
  margin: 0 !important;
}
body.single-product .ms-single-product .ms-product-row {
  display: grid !important;
  grid-template-columns: minmax(0, 46fr) minmax(0, 54fr) !important;
  width: 100% !important;
  gap: clamp(20px, 4vw, 54px) !important;
  align-items: start !important;
  margin: 18px 0 24px !important;
}
body.single-product .ms-product-row > .ms-product-picture,
body.single-product .ms-product-row > .ms-product-details {
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  margin: 0 !important;
  float: none !important;
  position: relative;
}
body.single-product .woocommerce div.product .ms-product-picture div.images,
body.single-product .woocommerce div.product .ms-product-picture .woocommerce-product-gallery,
body.single-product .woocommerce-page div.product .ms-product-picture div.images {
  float: none !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  position: relative !important;
}
body.single-product .ms-product-picture .woocommerce-product-gallery__wrapper,
body.single-product .ms-product-picture .woocommerce-product-gallery__image {
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
}
body.single-product .ms-product-picture img.wp-post-image,
body.single-product .ms-product-picture .woocommerce-product-gallery__image img,
body.single-product .ms-product-picture img.attachment-woocommerce_single {
  box-sizing: border-box !important;
  display: block !important;
  width: 100% !important;
  max-height: 420px !important;
  height: auto !important;
  aspect-ratio: 1 / 1;
  object-fit: contain !important;
  border: 1px solid #e6eaf0;
  background: #f6f8fb;
  border-radius: 15px;
  padding: 18px;
}
body.single-product .ms-product-picture .woocommerce-product-gallery__trigger {
  display: none !important;
}
body.single-product .ms-product-picture ol.flex-control-thumbs {
  display: flex !important;
  flex-wrap: wrap;
  gap: 10px;
  margin: 12px 0 0 !important;
  padding: 0 !important;
}
body.single-product .ms-product-picture ol.flex-control-thumbs li {
  width: 68px !important;
  flex: 0 0 68px;
  float: none !important;
  list-style: none !important;
}
body.single-product .ms-product-picture ol.flex-control-thumbs li img {
  width: 100% !important;
  height: 68px !important;
  object-fit: contain !important;
}
body.single-product .woocommerce div.product .ms-product-details.summary,
body.single-product .woocommerce-page div.product .ms-product-details.summary {
  float: none !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding: 4px 0 0 !important;
}
body.single-product .ms-product-details h1.product_title {
  font-size: clamp(24px, 2.7vw, 35px) !important;
  line-height: 1.2 !important;
  margin: 0 0 15px !important;
  letter-spacing: -.5px;
}
body.single-product .ms-product-details p.price,
body.single-product .ms-product-details .price {
  color: #d64e28 !important;
  font-size: 28px !important;
  font-weight: 800 !important;
  margin: 0 0 16px !important;
}
body.single-product .ms-product-details .woocommerce-product-details__short-description {
  color: #566579;
  margin: 12px 0 22px;
  font-size: 15px;
}
body.single-product .ms-product-details form.cart {
  display: flex !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin: 16px 0 23px !important;
}
body.single-product .ms-product-details form.cart .quantity,
body.single-product .ms-product-details form.cart .single_add_to_cart_button {
  margin: 0 !important;
  float: none !important;
}
body.single-product .ms-product-details form.cart input.qty {
  width: 78px !important;
  min-height: 45px;
}
body.single-product .ms-product-details form.cart button.single_add_to_cart_button {
  padding: 14px 24px !important;
  min-height: 45px;
  border-radius: 10px !important;
  white-space: nowrap !important;
}
body.single-product .ms-product-details .product_meta {
  border-top: 1px solid #e6eaf0;
  padding-top: 17px;
  font-size: 13px;
  color: #5f6d7d;
}
body.single-product .ms-single-product .ms-product-bottom {
  display: block !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  margin: 25px 0 0 !important;
  clear: both !important;
}
body.single-product .ms-product-bottom > .woocommerce-tabs,
body.single-product .ms-product-bottom > .related,
body.single-product .ms-product-bottom > .up-sells,
body.single-product .ms-product-bottom > .upsells {
  display: block !important;
  clear: both !important;
  float: none !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 25px 0 32px !important;
}
body.single-product .ms-product-bottom .woocommerce-tabs ul.tabs {
  display: flex !important;
  gap: 20px;
  width: 100%;
  padding: 0 0 8px !important;
  margin: 0 0 18px !important;
  border-bottom: 1px solid #e6eaf0;
  list-style: none !important;
}
body.single-product .ms-product-bottom .woocommerce-tabs ul.tabs li {
  display: inline-flex;
  list-style: none !important;
  float: none !important;
  margin: 0 !important;
  padding: 7px 8px !important;
}
body.single-product .ms-product-bottom .related > h2 {
  margin: 15px 0 20px !important;
  font-size: clamp(21px, 2.2vw, 27px);
}
body.single-product .ms-product-bottom ul.products {
  display: grid !important;
  width: 100% !important;
  max-width: 100% !important;
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 18px !important;
  padding: 0 !important;
  margin: 0 !important;
  list-style: none !important;
  float: none !important;
  clear: both !important;
}
body.single-product .ms-product-bottom ul.products::before,
body.single-product .ms-product-bottom ul.products::after {display: none !important;content:none !important}
body.single-product .ms-product-bottom ul.products li.product {
  box-sizing: border-box !important;
  display: flex !important;
  flex-direction: column !important;
  float: none !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 12px !important;
  border: 1px solid #e6eaf0;
  border-radius: 14px;
  overflow: hidden;
}
body.single-product .ms-product-bottom ul.products li.product a {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}
body.single-product .ms-product-bottom ul.products li.product img {
  display: block !important;
  width: 100% !important;
  height: 170px !important;
  max-width: 100% !important;
  object-fit: contain !important;
}
body.single-product .ms-product-bottom ul.products li.product .woocommerce-loop-product__title {
  min-height: 54px !important;
  font-size: 14px !important;
  line-height: 1.4 !important;
}
body.single-product .ms-product-bottom ul.products li.product .button {
  align-self: stretch;
  white-space: normal !important;
  margin-top: auto !important;
  width: calc(100% - 10px);
}
@media (max-width: 980px) {
  body.single-product .ms-single-product .ms-product-row {grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;gap: 22px!important}
  body.single-product .ms-product-bottom ul.products {grid-template-columns: repeat(2, minmax(0, 1fr)) !important}
}
@media (max-width: 720px) {
  body.single-product .ms-single-product .ms-product-row {grid-template-columns: minmax(0, 1fr) !important;gap: 20px!important}
  body.single-product .ms-product-picture img.wp-post-image,
  body.single-product .ms-product-picture .woocommerce-product-gallery__image img {max-height: 320px!important}
  body.single-product .ms-product-bottom ul.products {grid-template-columns: repeat(2, minmax(0, 1fr)) !important;gap: 10px!important}
  body.single-product .ms-product-bottom ul.products li.product img {height: 125px!important}
  body.single-product .ms-product-bottom ul.products li.product .button {font-size: 12px!important;padding: 10px 6px!important}
}
