/* Product quick view modal */

body.kwz-qv-lock {
  overflow: hidden;
}

.kwz-qv[hidden] {
  display: none !important;
}

.kwz-qv.is-open {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.kwz-qv__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(14, 8, 30, 0.45);
}

.kwz-qv__dialog {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  width: min(1040px, 100%);
  max-height: 90vh;
  overflow: hidden;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 18px 48px rgba(14, 8, 30, 0.18);
}

.kwz-qv__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: #f7f5fb;
  cursor: pointer;
  z-index: 3;
}

.kwz-qv__close:before,
.kwz-qv__close:after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 2px;
  background: #0e081e;
}

.kwz-qv__close:before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.kwz-qv__close:after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.kwz-qv__body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  padding: 24px;
  -webkit-overflow-scrolling: touch;
}

.kwz-qv__bar {
  flex: 0 0 auto;
  padding: 16px 24px calc(16px + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid #ece8f4;
  background: #fff;
}

.kwz-qv__bar[hidden] {
  display: none !important;
}

.kwz-qv__loading,
.kwz-qv__error {
  margin: 0;
  min-height: 280px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  text-align: center;
  color: #6b6280;
}

@media (min-width: 768px) {
  .kwz-qv.is-loading .kwz-qv__dialog {
    width: min(420px, 100%);
    min-height: 280px;
  }
}

.kwz-qv__spinner {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 3px solid rgba(124, 88, 211, 0.18);
  border-top-color: var(--primary-color, #7c58d3);
  animation: kwz-qv-spin 0.7s linear infinite;
}

@keyframes kwz-qv-spin {
  to {
    transform: rotate(360deg);
  }
}

.kwz-qv__layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 28px;
  align-items: start;
}

.kwz-qv__media {
  position: sticky;
  top: 0;
}

.kwz-qv__media img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  object-fit: contain;
  object-position: top;
  background: #f7f5fb;
  border-radius: 12px;
}

.kwz-qv__title {
  margin: 0 0 8px;
  padding-right: 44px;
  font-size: 20px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--heading-color, #0e081e);
}

.kwz-qv__excerpt {
  margin: 0 0 8px;
  font-size: 14px;
  line-height: 1.5;
  color: #6b6280;
}

.kwz-qv__excerpt p {
  margin: 0 0 0.6em;
}

.kwz-qv__excerpt p:last-child {
  margin-bottom: 0;
}

.kwz-qv .quantity label,
.kwz-qv .woocommerce-quantity label {
  display: none !important;
}

.kwz-qv .variations_form .variations,
.kwz-qv .variations_form .reset_variations,
.kwz-qv .variations_form .woocommerce-variation,
.kwz-qv .variations_form .woocommerce-variation-price,
.kwz-qv .variations_form .woocommerce-variation-availability {
  display: none !important;
}

.kwz-qv .zr-ph__pickTitle {
  display: none;
}

.kwz-qv .zr-varcards {
  gap: 8px;
}

.kwz-qv .zr-varcard {
  padding: 10px;
  border-radius: 12px;
  gap: 10px;
  grid-template-columns: 48px 1fr auto;
  transform: none;
}

.kwz-qv .zr-varcard:hover {
  transform: none;
  box-shadow: none;
}

.kwz-qv .zr-varcard.is-active {
  box-shadow: none;
}

.kwz-qv .zr-varcard__img img,
.kwz-qv .zr-varcard__imgPh {
  width: 48px;
  height: 48px;
  border-radius: 10px;
}

.kwz-qv .zr-note {
  margin: 12px 0 0;
  padding: 8px 12px;
  font-size: 13px;
  align-items: center;
}

.kwz-qv .zr-note__icon {
  margin-top: 0;
}

.kwz-qv .kwz-product-go {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 16px;
  font-size: 14px;
  font-weight: 700;
  color: var(--primary-color, #7c58d3);
  text-decoration: none;
}

.kwz-qv .kwz-product-go:hover {
  color: var(--additional01-color, #ff47a2);
}

.kwz-qv-tabs {
  margin-top: 16px;
}

.kwz-qv-tabs__nav {
  display: flex;
  gap: 0;
  border-bottom: 1px solid #ece8f4;
}

.kwz-qv-tabs__btn {
  appearance: none;
  border: none;
  background: transparent !important;
  border-radius: 0 !important;
  overflow: visible !important;
  box-shadow: none !important;
  padding: 8px 16px !important;
  margin: 0 0 -1px;
  font-size: 14px;
  font-weight: 700;
  color: #6b6280 !important;
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.kwz-qv-tabs__btn:first-child {
  padding-left: 0 !important;
}

.kwz-qv-tabs__btn.is-active,
.kwz-qv-tabs__btn:hover,
.kwz-qv-tabs__btn:focus,
.kwz-qv-tabs__btn:active {
  background: transparent !important;
  color: var(--heading-color, #0e081e) !important;
}

.kwz-qv-tabs__btn.is-active {
  border-bottom-color: var(--primary-color, #7c58d3);
}

.kwz-qv-tabs__panel {
  display: none;
  padding: 12px 0 0;
  font-size: 14px;
  line-height: 1.55;
  text-align: left;
  color: #3d3550;
}

.kwz-qv-tabs__panel.is-active {
  display: block;
}

.kwz-qv-tabs__panel > h2,
.kwz-qv-tabs__panel .woocommerce-Tabs-panel h2 {
  display: none;
}

.kwz-qv-tabs__panel p:first-child {
  margin-top: 0;
}

.kwz-qv-tabs__panel p.wp-block-paragraph:empty {
  display: none;
}

.kwz-qv table.shop_attributes {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.kwz-qv table.shop_attributes th,
.kwz-qv table.shop_attributes td {
  padding: 8px 0;
  border-bottom: 1px solid #ece8f4;
  text-align: left;
  vertical-align: top;
}

.kwz-qv table.shop_attributes th {
  width: 42%;
  padding-right: 16px;
  font-weight: 700;
  color: #6b6280;
}

.kwz-qv table.shop_attributes a.kwz-attr-link {
  color: var(--primary-color, #6b3fa0);
  text-decoration: none;
}

.kwz-qv table.shop_attributes a.kwz-attr-link:hover,
.kwz-qv table.shop_attributes a.kwz-attr-link:focus {
  text-decoration: underline;
}

.kwz-qv__bar .zr-atcRow {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: 0;
  gap: 16px;
}

.kwz-qv__bar .zr-atcForm {
  flex: 0 1 auto;
  min-width: 0;
  margin-left: auto;
}

.kwz-qv__bar .zr-atcForm form.cart,
.kwz-qv__bar .single_variation_wrap,
.kwz-qv__bar .woocommerce-variation-add-to-cart {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  width: auto;
  min-height: 0;
}

.kwz-qv__bar .zr-atcPriceBox,
.kwz-qv__bar .zr-atcRow.is-price .zr-atcPriceBox {
  display: none !important;
}

.kwz-qv__bar .single_variation,
.kwz-qv__bar .woocommerce-variation,
.kwz-qv__bar .woocommerce-variation-description,
.kwz-qv__bar .woocommerce-variation-price,
.kwz-qv__bar .woocommerce-variation-availability {
  display: none !important;
  height: 0 !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

.kwz-qv__bar .quantity,
.kwz-qv__bar .woocommerce-quantity {
  display: flex;
  align-items: center;
  margin: 0 12px 0 0 !important;
  height: 48px;
}

.kwz-qv__bar .pxl-quantity {
  position: relative;
  display: block;
  height: 48px;
}

.kwz-qv__bar .quantity-button,
.kwz-qv__bar .quantity-up,
.kwz-qv__bar .quantity-down {
  display: block !important;
  position: absolute;
  right: 8px;
  width: 18px;
  height: 16px;
  line-height: 16px;
  z-index: 2;
}

.kwz-qv__bar .quantity-up {
  top: 6px;
  bottom: auto;
}

.kwz-qv__bar .quantity-down {
  top: auto;
  bottom: 6px;
}

.kwz-qv__bar .quantity-up:before,
.kwz-qv__bar .quantity-down:before {
  font-size: 14px;
  line-height: 16px;
}

.kwz-qv__bar input.qty[type="number"] {
  width: 76px !important;
  height: 48px !important;
  min-height: 48px !important;
  max-height: 48px !important;
  line-height: 48px !important;
  padding: 0 22px 0 8px !important;
  text-align: center !important;
  font-size: 16px !important;
  font-weight: 700;
  border-radius: 12px !important;
  box-sizing: border-box !important;
}

.kwz-qv__bar .zr-atcForm .single_add_to_cart_button,
.kwz-qv__bar .zr-atcForm button.single_add_to_cart_button,
.kwz-qv__bar button.single_add_to_cart_button {
  flex: 0 0 auto !important;
  width: auto !important;
  max-width: none !important;
  min-width: 148px !important;
  min-height: 48px !important;
  height: 48px !important;
  margin: 0 !important;
  padding-left: 20px !important;
  padding-right: 20px !important;
  border-radius: 12px !important;
}

@media (max-width: 767.98px) {
  .kwz-qv.is-open {
    padding: 0;
    align-items: stretch;
    justify-content: stretch;
  }

  .kwz-qv__dialog {
    width: 100%;
    max-width: none;
    height: 100%;
    max-height: none;
    border-radius: 0;
    box-shadow: none;
  }

  .kwz-qv__close {
    top: 12px;
    right: 12px;
  }

  .kwz-qv__body {
    padding: 20px 16px 12px;
  }

  .kwz-qv__bar {
    padding: 14px 16px calc(14px + env(safe-area-inset-bottom, 0px));
  }

  .kwz-qv__layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .kwz-qv__media {
    position: static;
    max-width: 180px;
    margin: 0 auto;
  }

  .kwz-qv__title {
    font-size: 18px;
    padding-right: 40px;
  }

  .kwz-qv .zr-varcards {
    grid-template-columns: 1fr;
  }

  .kwz-qv__bar .zr-atcRow,
  .kwz-qv__bar .zr-atcForm form.cart {
    flex-wrap: nowrap;
  }

  .kwz-qv__bar input.qty[type="number"] {
    width: 68px !important;
  }
}
