.product-inner-container {
  display: flex;
  flex-direction: column;
}

.stock.in-stock {
  display: none;
}
.stock.out-of-stock {
  display: none;
}

.main-product-inner {
  display: grid;
  grid-template-columns: 0.9fr 1.04fr;
  gap: 50px;
  padding-top: 32px;
  transition:
    padding-top 0.4s ease,
    gap 0.4s ease;
}
.product-inner-left {
  overflow: hidden;
}
.main-product-image {
  width: 100%;
  height: auto;
  border-radius: 4px;
  border: 1px solid var(--neutral200);
  overflow: hidden;
  position: relative;
  aspect-ratio: 1 / 1;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  cursor: pointer;
}
.main-product-image img,
.main-product-image picture {
  height: 100%;
  width: 100%;
  -o-object-fit: contain;
  object-fit: contain;
}
.action-badge {
  position: absolute;
  top: 20px;
  left: 0;
  padding: 10px;
  color: var(--primary500);
  background: var(--black_white100);
  border-radius: 0px 6px 6px 0px;
}
.zoom-img {
  position: absolute;
  height: 39px;
  width: 39px;
  background: var(--black_white50);
  border: 1px solid var(--neutral200);
  border-radius: 6px;
  right: 10px;
  top: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: border-color 0.4s ease;
}
.zoom-img img {
  height: 17px;
  width: 17px;
}
.zoom-img:hover {
  border-color: var(--primary500);
}
.gallery-wrapper {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.all-product-thumbnails {
  display: flex;
  gap: 12px;
  width: 100%;
  overflow-x: auto;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}
.all-product-thumbnails img {
  border: 1px solid var(--neutral200);
  border-radius: 4px;
  cursor: pointer;
  min-width: 100px;
  min-height: 100px;
  height: 100px;
  width: 100px;
  transition:
    border-color 0.4s ease,
    height 0.4s ease,
    width 0.4s ease;
}
.all-product-thumbnails img.active {
  border-color: var(--black_white950);
}

table.variations {
  display: none;
}

/* Product lower menu */
.lower-product-inner {
  padding: 50px 0 100px;
  transition: padding 0.4s ease;
}
.menu-product {
  display: flex;
  border-bottom: 1px solid var(--neutral200);
}

.tab-item {
  padding: 16px 24px;
  color: var(--neutral600);
  cursor: pointer;
  border-bottom: 1px solid transparent;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition:
    color 0.4s ease,
    border-color 0.4s ease,
    padding 0.4s ease;
}

.tab-item.active {
  color: var(--primary500);
  border-color: var(--primary500);
}

.tab-item > span {
  display: none;
}

.tab-content {
  display: none;
  padding-top: 32px;
  color: var(--black_white950);
  transition: padding-top 0.4s ease;
}

.tab-content.active {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
#tab-nutrition.tab-content.active {
  gap: 4px;
}

/* Reviews */
#tab-reviews-product {
  padding-top: 50px;
  transition: padding-top 0.4s ease;
}
#tab-reviews-product .primary-btn-large {
  max-width: 378px;
  width: 100%;
}
.reviews-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 32px;
  color: var(--black_white950);
  transition: gap 0.4s ease;
}

.reviews-wrapper .h1 {
  color: var(--primary500);
}

/* Stock */
.woocommerce-variation-availability {
  display: none;
}

/* Comments modal */
#review_modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  display: none; /* hidden by default */
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

#review_modal .modal-content {
  position: relative;
  background: var(--black_white50);
  color: var(--black_white950);
  padding: 24px;
  border-radius: 8px;
  max-width: 450px;
  width: 90%;
  box-sizing: border-box;
  transition: padding 0.4s ease;
}

#review_modal .comment-respond {
  display: flex;
  flex-direction: column;
}

#review_modal .h5 {
  margin-bottom: 24px;
  transition: margin-bottom 0.4s ease;
}
#review_modal .upper-review-form-rating {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
  transition: margin-bottom 0.4s ease;
}
#review_modal .upper-review-form-rating label,
#review_modal .bottom-review-form-rating {
  color: var(--neutral600);
}

#review_modal .bottom-review-form-rating {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 24px;
  transition: margin-bottom 0.4s ease;
}
#review_modal .bottom-review-form-rating textarea {
  border: 1px solid var(--neutral200);
  border-radius: 8px;
  padding: 13px 16px;
  resize: none;
  color: var(--neutral600);
  height: 120px;
  width: 100%;
  transition:
    border-color 0.4s ease,
    color 0.4s ease;
}
#review_modal .bottom-review-form-rating textarea:hover {
  border-color: var(--primary500);
}
#review_modal .bottom-review-form-rating textarea:focus {
  border-color: var(--primary500);
  color: var(--black_white950);
  outline: none;
}
#review_modal .bottom-review-form-rating textarea:not(:placeholder-shown) {
  color: var(--black_white950);
}

#review_modal .primary-btn-large {
  width: 100%;
  cursor: pointer;
}

#review_modal .comment-notes {
  color: var(--neutral600);
  margin-bottom: 24px;
  transition: margin-bottom 0.4s ease;
}

#review_modal .close {
  position: absolute;
  top: 24px;
  right: 24px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 26px;
  width: 26px;
  font-size: 38px;
  color: var(--black_white950);
  transition: color 0.4s ease;
}
#review_modal .close:hover {
  color: var(--primary500);
}
/*  review not logged in */
/* Hide the default checkbox */
#review_modal .comment-form-cookies-consent input[type="checkbox"] {
  display: none;
}

/* Custom box */
#review_modal .comment-form-cookies-consent .custom-box {
  display: inline-block;
  width: 18px;
  height: 18px;
  border: 2px solid var(--neutral200);
  background: var(--black_white50);
  border-radius: 2px;
  margin-right: 10px;
  vertical-align: middle;
  position: relative;
  cursor: pointer;
  transition:
    background0color 0.4s ease,
    border-color 0.4s ease;
}

/* Checked state: green background with white checkmark */
#review_modal
  .comment-form-cookies-consent
  input[type="checkbox"]:checked
  + label
  .custom-box {
  background: var(--primary500);
  border-color: var(--primary500);
}
/* Checkmark */
#review_modal
  .comment-form-cookies-consent
  input[type="checkbox"]:checked
  + label
  .custom-box::after {
  content: "";
  position: absolute;
  left: 4px;
  top: 0px;
  width: 6px;
  height: 12px;
  border: solid var(--black_white50);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
/* Label text styling */
#review_modal .comment-form-cookies-consent label {
  cursor: pointer;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
}
.comment-form-author label,
.comment-form-email label {
  display: none;
}
.comment-form-author,
.comment-form-email,
.comment-form-cookies-consent {
  margin-bottom: 12px;
  color: var(--neutral600);
}
.comment-form-author input,
.comment-form-email input {
  padding: 11px 16px;
  border: 1px solid var(--neutral200);
  border-radius: 8px;
  color: var(--neutral600);
  width: 100%;
  transition:
    border-color 0.4s ease,
    color 0.4s ease;
}

.comment-form-author input:hover,
.comment-form-email input:hover {
  border-color: var(--primary500);
}
.comment-form-author input:focus,
.comment-form-email input:focus {
  border-color: var(--primary500);
  color: var(--black_white950);
  outline: none;
}
.comment-form-author input:not(:placeholder-shown),
.comment-form-email input:not(:placeholder-shown) {
  color: var(--black_white950);
}

/* review revieer */
.reviews-wrapper ol {
  display: flex;
  flex-direction: column;
  gap: 40px;
  max-width: 800px;
  width: 100%;
  transition: gap 0.4s ease;
}
.custom-review {
  border-bottom: 1px solid var(--neutral200);
  color: var(--neutral950);
  padding-bottom: 40px;
  transition: padding-bottom 0.4s ease;
}
.custom-review .review-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.custom-review .review-date {
  color: var(--neutral500);
}
.custom-review .review-box {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Right side */
.product-rating {
  display: flex;
  gap: 4px;
  margin-bottom: 16px;
  transition: margin-bottom 0.4s ease;
}
.product-rating .star {
  height: 16px;
  width: 16px;
}
.product-rating .review-count {
  color: var(--neutral500);
}
.single-product-title {
  color: var(--black_white950);
  margin-bottom: 24px;
}
.single-product-description {
  color: var(--neutral600);
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 24px;
}
.variation-short-description {
  color: var(--neutral600);
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 24px;
}
.product-price-wrapper {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 32px;
}
.product-price-wrapper .price-old {
  color: var(--neutral600);
  text-decoration: line-through;
}
.product-price-wrapper .price-new,
.product-price-wrapper .price-normal {
  color: var(--primary500);
}
.product-price-wrapper .price-new {
  display: flex;
  align-items: center;
  gap: 4px;
}
.product-price-wrapper .price-new .discount-badge {
  margin-left: 12px;
  color: var(--primary500);
  background: var(--black_white100);
  padding: 8px;
  border-radius: 8px;
}
.product-price-wrapper .price-unit {
  color: var(--neutral400);
}
/* variable select */
.all-attributes-wrapper {
  margin-bottom: 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.attribute-category {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.attribute-label {
  color: var(--black_white950);
}
.all-attributes-wrapper .swatches {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.all-attributes-wrapper .swatch {
  background: var(--black_white50);
  border: 1px solid var(--neutral200);
  border-radius: 8px;
  color: var(--neutral600);
  padding: 7px 16px;
  transition:
    background-color 0.4s ease,
    color 0.4s ease,
    border-color 0.4s ease;
}
.all-attributes-wrapper .swatch.active {
  border-color: var(--primary500);
  background: var(--black_white100);
  color: var(--primary500);
}
.all-attributes-wrapper .swatch:hover {
  cursor: pointer;
  border-color: var(--primary500);
  color: var(--primary500);
}

.custom-stock .stock-label {
  color: var(--neutral600);
}
.custom-stock .stock-value {
  color: var(--primary500);
}

/* Base STARS: full */
.stars span a {
  text-indent: -9999px;
  display: inline-block;
  width: 20px;
  height: 20px;
  line-height: 0;
  overflow: hidden;
  background: url("../../../assets/icons/star-full.png") no-repeat center center !important;
  background-size: contain;
  margin-right: 4px;
  cursor: pointer;
}

/* Selected stars: make stars to left empty */
.stars span a[aria-checked="true"],
.stars span a[aria-checked="true"] ~ a {
  background: url("../../../assets/icons/star-empty.png") no-repeat center
    center !important;
  background-size: contain;
}

.stars span a.active {
  background: url("../../../assets/icons/star-full.png") no-repeat center center !important;
  background-size: contain;
}
/* Related products */
.product-inner-similar {
  position: relative;
  padding: 50px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 40px;
  transition:
    padding 0.4s ease,
    gap 0.4s ease;
}
.product-inner-similar::before {
  content: "";
  position: absolute;
  background: var(--neutral100);
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  height: 100%;
  width: 100vw;
  z-index: -1;
}
.product-inner-similar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}
.product-inner-similar ul {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
}
.related-products-right a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--black_white950);
  border-bottom: 1px solid transparent;
  transition:
    color 0.4s ease,
    border-color 0.4s ease;
}
.related-products-right a:hover {
  color: var(--primary500);
  border-color: var(--primary500);
}
.related-products-mobile {
  display: none;
}

.product-inner-similar ul {
  flex-wrap: nowrap !important;
}

/* Responsive */
@media (max-width: 768px) {
  /* Product upper part */
  .main-product-inner {
    padding-top: 24px;
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .all-product-thumbnails {
    scrollbar-width: none;
  }
  .all-product-thumbnails img {
    height: 60px;
    width: 60px;
    min-width: 60px;
    min-height: 60px;
  }
  .zoom-img {
    top: unset;
    bottom: 10px;
  }
  /* left sinde */
  .product-rating {
    margin-bottom: 12px;
  }
  /* Product lower menu */
  .lower-product-inner {
    padding: 40px 0;
    margin-left: -16px;
    margin-right: -16px;
  }
  .menu-product {
    flex-direction: column;
    gap: 16px;
  }
  .tab-item {
    border-color: var(--neutral200);
    padding: 16px 16px;
  }
  .tab-item > span {
    display: block;
    transform: rotate(0deg);
    transition: transform 0.4s ease;
  }
  .tab-item > span svg {
    height: 24px;
    width: 24px;
  }
  .tab-item.active > span {
    transform: rotate(180deg);
  }

  .tab-content {
    padding: 0 16px 16px;
  }
  /* Related products */
  .product-inner-similar {
    padding: 32px 0;
    gap: 24px;
  }
  .related-products-right {
    display: none;
  }
  .related-products-mobile {
    display: block;
  }
  .related-products-mobile a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--black_white950);
    border-bottom: 1px solid transparent;
    width: -webkit-max-content;
    width: -moz-max-content;
    width: max-content;
    transition:
      color 0.4s ease,
      border-color 0.4s ease;
  }
  .related-products-mobile a:hover {
    color: var(--primary500);
    border-color: var(--primary500);
  }
  /* reviews */
  #tab-reviews-product {
    padding-top: 24px;
  }
  #review_modal .modal-content {
    padding: 16px;
  }
  .reviews-wrapper {
    gap: 24px;
  }
  #review_modal .h5,
  #review_modal .upper-review-form-rating,
  #review_modal .bottom-review-form-rating,
  #review_modal .comment-notes {
    margin-bottom: 16px;
  }
  /* review revieer */
  .reviews-wrapper ol {
    gap: 24px;
  }
  .custom-review {
    padding-bottom: 24px;
  }

  .product-inner-similar ul {
    flex-wrap: wrap !important;
  }
}
