/* ============================================================
   PRODUCT PAGE
   ============================================================ */

.mi-single-product-page .site-main {
  padding-top: 0;
}

.custom-single-product {
  width: min(1400px, calc(100% - 48px));
  margin: 0 auto;
}

/* ============================================================
   PRODUCT MAIN
   ============================================================ */

.product-main {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(400px, 0.9fr);
  gap: clamp(40px, 5vw, 90px);
  align-items: start;
}

/* ============================================================
   GALLERY
   ============================================================ */

.product-gallery {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 20px;
  min-width: 0;
}

.product-thumbnails {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.product-thumbnail {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1.15;
  padding: 0;
  margin: 0;
  overflow: hidden;
  border: 1px solid transparent;
  border-radius: 14px;
  background: #f4f4f4;
  cursor: pointer;
  transition:
    border-color 0.25s ease,
    opacity 0.25s ease,
    transform 0.25s ease;
}

.product-thumbnail:hover {
  transform: translateY(-2px);
}

.product-thumbnail.is-active {
  border-color: #111;
}

.product-thumbnail img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.product-gallery-more {
  width: 54px;
  height: 54px;
  margin: 6px auto 0;
  border: 1px solid #d7d7d7;
  border-radius: 50%;
  background: #fff;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.product-gallery-more svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

/* ============================================================
   MAIN IMAGE
   ============================================================ */

.product-main-image {
  position: relative;
  overflow: hidden;
  border-radius: 18px;
  background: #f4f4f5;
  aspect-ratio: 0.82;
}

.product-main-image-element {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition:
    opacity 0.25s ease,
    transform 0.5s ease;
}

.product-main-image:hover .product-main-image-element {
  transform: scale(1.015);
}

/* ============================================================
   ZOOM
   ============================================================ */

.product-image-zoom {
  position: absolute;
  right: 20px;
  bottom: 20px;

  width: 52px;
  height: 52px;

  display: grid;
  place-items: center;

  border: 0;
  border-radius: 50%;

  background: rgba(255, 255, 255, 0.94);

  cursor: pointer;

  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  justify-content: center;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease;
  border: 1px solid #000;
}

.product-image-zoom:hover {
  transform: scale(1.06);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.product-image-zoom svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: #111;
  stroke-width: 1.8;
}

/* ============================================================
   PRODUCT SUMMARY
   ============================================================ */

.product-summary {
  min-width: 0;
  padding-top: 18px;
}

.product-badge {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 12px;

  border-radius: 8px;

  background: #f1f1f1;

  font-size: 13px;
  font-weight: 600;
  line-height: 1;
}

.product-title {
  margin: 18px 0 14px;

  color: #0d0d0d;

  font-size: clamp(36px, 4vw, 58px);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 700;
}

/* ============================================================
   RATING
   ============================================================ */

.product-rating {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
}

.product-stars {
  display: flex;
  gap: 2px;
  color: #111;
  font-size: 18px;
  line-height: 1;
}

.product-stars span {
  opacity: 0.25;
}

.product-stars span.is-full {
  opacity: 1;
}

.product-review-link {
  color: #222;
  text-decoration: none;
  font-size: 15px;
}

.product-review-link:hover {
  text-decoration: underline;
}

.product-review-link span {
  color: #555;
}

/* ============================================================
   PRICE
   ============================================================ */

.product-price-wrapper {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;

  margin-bottom: 22px;
}

.product-price-sale {
  color: #111;
  font-size: 36px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.product-price-sale .woocommerce-Price-currencySymbol {
  margin-right: 2px;
}

.product-price-regular {
  color: #777;
  font-size: 18px;
  text-decoration: line-through;
}

.product-discount {
  display: inline-flex;
  align-items: center;

  padding: 7px 11px;

  border-radius: 7px;

  background: #111;
  color: #fff;

  font-size: 12px;
  font-weight: 700;
}

/* ============================================================
   PRECIO VARIABLE (rango de precios)
   ============================================================ */

/*
 * WooCommerce genera: "Desde: $X.000 - $Y.000"
 * o bien con ins/del para precios en oferta.
 */

.single_variation_wrap {
  width: 100%;
}

.product-price-sale .woocommerce-Price-amount {
  font-size: inherit;
  font-weight: inherit;
}

/* El separador "–" entre precio min y max */
.product-price-sale .woocommerce-price-separator {
  margin: 0 6px;
  font-weight: 400;
  color: #666;
}

/* Precio en oferta variable: sin tachado en el precio activo */
.product-price-sale ins {
  text-decoration: none;
}

/* Precio original tachado en variable con descuento */
.product-price-sale del {
  font-size: 20px;
  font-weight: 400;
  color: #999;
  text-decoration: line-through;
  margin-left: 8px;
}

/* ============================================================
   DESCRIPTION
   ============================================================ */

.product-short-description {
  max-width: 600px;

  color: #3c3c3c;

  font-size: 16px;
  line-height: 1.65;
}

.product-short-description p {
  margin: 0;
}

.product-divider {
  width: 100%;
  height: 1px;
  margin: 28px 0;

  background: #e4e4e4;
}

/* ============================================================
   PURCHASE
   ============================================================ */

.product-purchase {
  width: 100%;
}

/* ============================================================
   WOOCOMMERCE VARIABLE PRODUCT
   ============================================================ */

.product-purchase form.cart {
  margin: 0;
}

.product-purchase form.variations_form {
  margin: 0;
}

.product-purchase table.variations {
  width: 100%;
  margin: 0 0 20px;
  border: 0;
  border-collapse: collapse;
}

.product-purchase table.variations tr,
.product-purchase table.variations td,
.product-purchase table.variations th {
  border: 0;
  background: none;
}

.product-purchase table.variations tr {
  display: block;
  margin-bottom: 24px;
}

.product-purchase table.variations .label {
  display: block;
  padding: 0 0 11px;

  text-align: left;
}

.product-purchase table.variations .label label {
  color: #222;
  font-size: 15px;
  font-weight: 600;
}

.product-purchase table.variations .value {
  display: block;
  padding: 0;
  background: none;
}

/*
 * Select nativo:
 * Lo mantenemos funcional para WooCommerce pero lo
 * ocultamos visualmente.
 */

.product-purchase table.variations select {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

/* ============================================================
   CUSTOM VARIATION BUTTONS
   ============================================================ */

.custom-variation-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.custom-variation-option {
  /* min-width: 58px;
  min-height: 58px; */

  padding: 0 18px;

  border: 1px solid #d8d8d8;
  border-radius: 10px;

  background: #fff;
  color: #111;

  font-size: 14px;
  font-weight: 500;

  cursor: pointer;

  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    transform 0.2s ease;
}

.custom-variation-option:hover {
  border-color: #111;
  transform: translateY(-1px);
}

.custom-variation-option.is-selected {
  border-color: #111;
  background: #111;
  color: #fff;
}

.custom-variation-option.is-disabled {
  opacity: 0.35;
  cursor: not-allowed;
  text-decoration: line-through;
}

.custom-variation-options button[data-value="S"],
button[data-value="M"],
button[data-value="L"],
button[data-value="XL"],
button[data-value="XXL"] {
  width: 58px;
  height: 58px;
}

/* ============================================================
   COLOR SWATCH
   ============================================================ */

.custom-variation-options.is-color {
  gap: 12px;
}

.custom-color-option {
  position: relative;

  width: 26px;
  height: 26px;

  padding: 0;

  border: 2px solid transparent;
  border-radius: 50%;

  cursor: pointer;

  background: #ddd;

  transition:
    transform 0.2s ease,
    border-color 0.2s ease;
}

.custom-color-option::after {
  content: "";

  position: absolute;
  inset: 3px;

  border-radius: 50%;

  background: var(--swatch-color, #ddd);
}

.custom-color-option.is-selected {
  border-color: #111;
  transform: scale(1.08);
}

.custom-color-option.is-selected::before {
  content: "";

  position: absolute;
  inset: -5px;

  border: 1px solid #aaa;
  border-radius: 50%;
}

/* ============================================================
   SIZE GUIDE
   ============================================================ */

.product-option-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.product-size-guide {
  color: #222;
  font-size: 14px;
  text-decoration: underline;
  cursor: pointer;
}

/* ============================================================
   RESET
   ============================================================ */

.product-purchase .reset_variations {
  display: none !important;
}

/* ============================================================
   SINGLE PRODUCT BUTTON
   ============================================================ */

.product-purchase .single_add_to_cart_button,
.product-purchase button.single_add_to_cart_button {
  /* min-height: 64px; */

  width: 100%;

  border: 0;
  border-radius: 12px;

  background: #050505;
  color: #fff;

  font-size: 17px;
  font-weight: 600;

  cursor: pointer;

  transition:
    transform 0.2s ease,
    background 0.2s ease,
    opacity 0.2s ease;
}

.product-purchase .single_add_to_cart_button:hover {
  background: #222;
  transform: translateY(-1px);
}

.product-purchase .single_add_to_cart_button.disabled,
.product-purchase .single_add_to_cart_button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

/* ============================================================
   CANTIDAD
   ============================================================ */

/* ============================================================
   SELECTOR DE CANTIDAD
   ============================================================ */

.product-purchase .quantity {
  display: flex !important;
  align-items: center;
  width: 150px;
  height: 64px;
  margin: 0 !important;
  padding: 0;

  border: 1px solid #d8d8d8;
  border-radius: 12px;
  background: #fff;

  overflow: hidden;
}

/* BOTONES + Y - */

.product-purchase .quantity .quantity-minus,
.product-purchase .quantity .quantity-plus {
  width: 48px;
  height: 100%;

  flex: 0 0 48px;

  display: grid;
  place-items: center;

  padding: 0;
  margin: 0;

  border: 0;

  background: transparent;
  color: #111;

  font-size: 22px;
  font-weight: 400;

  line-height: 1;

  cursor: pointer;

  transition:
    background 0.2s ease,
    opacity 0.2s ease;
}

.product-purchase .quantity .quantity-minus:hover,
.product-purchase .quantity .quantity-plus:hover {
  background: #f3f3f3;
}

/* INPUT */

.product-purchase .quantity .qty {
  width: 54px;
  height: 100%;

  flex: 1;

  padding: 0;
  margin: 0;

  border: 0 !important;

  background: transparent;

  color: #111;

  font-size: 16px;
  font-weight: 600;

  text-align: center;

  box-shadow: none !important;

  -moz-appearance: textfield;
}

/* Quitar flechas nativas */

.product-purchase .quantity .qty::-webkit-outer-spin-button,
.product-purchase .quantity .qty::-webkit-inner-spin-button {
  margin: 0;
  -webkit-appearance: none;
}

/* ============================================================
   BOTÓN + CANTIDAD
   ============================================================ */

.product-purchase .woocommerce-variation-add-to-cart,
.product-purchase form.cart:not(.variations_form) {
  display: flex;

  align-items: stretch;

  gap: 12px;
}

/* Botón */

.product-purchase .woocommerce-variation-add-to-cart .single_add_to_cart_button,
.product-purchase form.cart:not(.variations_form) .single_add_to_cart_button {
  flex: 1;
  min-width: 0;
  font-family: "Roboto Mono", monospace;
}

/* Wishlist */

.product-purchase .woocommerce-variation-add-to-cart .product-wishlist {
  flex: 0 0 64px;
}

/* ============================================================
   MOBILE
   ============================================================ */

@media (max-width: 600px) {
  .product-purchase .quantity {
    width: 130px;
    height: 58px;
  }

  .product-purchase .quantity .quantity-minus,
  .product-purchase .quantity .quantity-plus {
    width: 40px;
    flex-basis: 40px;
  }

  .product-purchase .woocommerce-variation-add-to-cart,
  .product-purchase form.cart:not(.variations_form) {
    gap: 8px;
  }
}

/* ============================================================
   WISHLIST
   ============================================================ */

.product-wishlist {
  width: 64px;
  height: 64px;

  flex: 0 0 64px;

  border: 1px solid #d9d9d9;
  border-radius: 12px;

  background: #fff;

  display: grid;
  place-items: center;

  cursor: pointer;
}

.product-wishlist svg {
  width: 25px;
  height: 25px;

  fill: none;
  stroke: #111;
  stroke-width: 1.7;
}

/* ============================================================
   BENEFITS
   ============================================================ */

.product-benefits {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;

  margin-top: 28px;
}

.product-benefit {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.product-benefit-icon {
  flex: 0 0 25px;

  width: 25px;
  height: 25px;
}

.product-benefit-icon svg {
  width: 100%;
  height: 100%;

  fill: none;
  stroke: #111;
  stroke-width: 1.5;
}

.product-benefit strong,
.product-benefit span {
  display: block;
}

.product-benefit strong {
  margin-bottom: 3px;

  color: #222;
  font-size: 12px;
  font-weight: 600;
}

.product-benefit div span {
  color: #666;
  font-size: 11px;
  line-height: 1.3;
}

/* ============================================================
   BOTTOM
   ============================================================ */

.product-bottom {
  display: grid;
  /* grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr); */

  gap: clamp(40px, 6vw, 90px);

  margin-top: 70px;
  padding-bottom: 80px;
}

/* ============================================================
   TABS
   ============================================================ */

.product-tabs-nav {
  display: flex;
  align-items: center;
  gap: 40px;

  border-bottom: 1px solid #ddd;
}

.product-tab-button {
  position: relative;

  padding: 0 0 16px;

  border: 0;

  background: none;

  color: #666;

  font-size: 15px;
  font-weight: 500;

  cursor: pointer;
}

.product-tab-button:hover {
  background: transparent;
  font-weight: 600;
}

.product-tab-button::after {
  content: "";

  position: absolute;

  left: 0;
  bottom: -1px;

  width: 0;
  height: 2px;

  background: #111;

  transition: width 0.25s ease;
}

.product-tab-button.is-active {
  color: #111;
  font-weight: 600;
}

.product-tab-button.is-active::after {
  width: 100%;
}

/* ============================================================
   TAB CONTENT
   ============================================================ */

.product-tab-content {
  display: none;

  padding-top: 28px;

  color: #444;

  font-size: 15px;
  line-height: 1.7;
}

.product-tab-content.is-active {
  display: block;
}

.product-tab-content h3 {
  margin: 0 0 12px;

  color: #111;

  font-size: 22px;
}

.product-tab-content p {
  margin-top: 0;
}

/* ============================================================
   PRODUCT FEATURES
   ============================================================ */

.product-features {
  list-style: none;

  margin: 24px 0 0;
  padding: 0;
}

.product-features li {
  display: flex;
  align-items: center;
  gap: 12px;

  margin-bottom: 13px;

  color: #222;
}

.feature-icon {
  width: 22px;
  height: 22px;

  display: grid;
  place-items: center;

  border-radius: 50%;

  background: #f2f2f2;

  font-size: 12px;
}

/* ============================================================
   EXTRA IMAGE
   ============================================================ */

.product-extra-image {
  overflow: hidden;

  min-height: 400px;

  border-radius: 18px;

  background: #f2f2f2;
}

.product-detail-image {
  width: 100%;
  height: 100%;

  min-height: 400px;

  display: block;

  object-fit: cover;
}

/* ============================================================
   LIGHTBOX
   ============================================================ */

.product-lightbox {
  position: fixed;

  inset: 0;

  z-index: 999999;

  display: flex;
  align-items: center;
  justify-content: center;

  padding: 40px;

  background: rgba(0, 0, 0, 0.88);

  opacity: 0;
  visibility: hidden;

  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.product-lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.product-lightbox img {
  max-width: 90vw;
  max-height: 90vh;

  object-fit: contain;
}

.product-lightbox-close {
  position: absolute;

  top: 25px;
  right: 25px;

  display: flex;
  justify-content: center;
  align-items: center;
  width: 30px;
  height: 30px;
  padding: 0;
  border-radius: 100px;

  background: #fff;

  font-size: 25px;

  cursor: pointer;
}

/* ============================================================
   WOOCOMMERCE NOTICES
   ============================================================ */

.product-summary .woocommerce-message,
.product-summary .woocommerce-error,
.product-summary .woocommerce-info {
  margin: 0 0 20px;
}

/* ============================================================
   MOBILE
   ============================================================ */

@media (max-width: 1100px) {
  .product-main {
    grid-template-columns: minmax(0, 1fr) minmax(340px, 0.85fr);
    gap: 35px;
  }

  .product-gallery {
    grid-template-columns: 80px minmax(0, 1fr);
  }

  .product-title {
    font-size: clamp(32px, 4vw, 45px);
  }

  .product-benefits {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 800px) {
  .custom-single-product {
    width: min(100% - 32px, 680px);
  }

  .product-main {
    display: block;
  }

  .product-gallery {
    grid-template-columns: 1fr;
  }

  .product-thumbnails {
    order: 2;

    display: grid;
    grid-template-columns: repeat(4, 1fr);

    gap: 10px;

    margin-top: 12px;
  }

  .product-thumbnail {
    aspect-ratio: 1;
  }

  .product-gallery-more {
    display: none;
  }

  .product-main-image {
    order: 1;

    aspect-ratio: 0.85;
  }

  .product-summary {
    padding-top: 35px;
  }

  .product-bottom {
    display: block;
    margin-top: 50px;
  }

  .product-extra-image {
    margin-top: 40px;
  }
}

@media (max-width: 600px) {
  .custom-single-product {
    width: calc(100% - 24px);
  }

  .product-title {
    font-size: 34px;
  }

  .product-price-sale {
    font-size: 30px;
  }

  .product-rating {
    margin-bottom: 18px;
  }

  .product-short-description {
    font-size: 15px;
  }

  .product-tabs-nav {
    gap: 22px;

    overflow-x: auto;

    scrollbar-width: none;
  }

  .product-tabs-nav::-webkit-scrollbar {
    display: none;
  }

  .product-tab-button {
    flex: 0 0 auto;

    white-space: nowrap;
  }

  .product-benefits {
    grid-template-columns: 1fr;
  }

  .product-extra-image,
  .product-detail-image {
    min-height: 280px;
  }
}

/* ============================================================
   OVERRIDES STOREFRONT / WOOCOMMERCE
   ============================================================ */

.mi-single-product-page .site-content {
  margin: 0;
}

.mi-single-product-page .woocommerce-breadcrumb {
  display: block;
}

.mi-single-product-page .single-product div.product {
  margin: 0;
}

.mi-single-product-page .single-product div.product::before,
.mi-single-product-page .single-product div.product::after {
  display: none;
}

.mi-single-product-page .single-product div.product .summary {
  width: auto;
  float: none;
  margin: 0;
}

.mi-single-product-page .single-product div.product .images {
  width: auto;
  float: none;
  margin: 0;
}

.mi-single-product-page
  .single-product
  div.product
  .woocommerce-product-gallery {
  width: auto;
  float: none;
}

.mi-single-product-page
  .single-product
  div.product
  .woocommerce-product-gallery__wrapper {
  margin: 0;
}

.mi-single-product-page .single-product div.product .product_meta {
  display: none;
}

.mi-single-product-page .single-product div.product .woocommerce-tabs {
  display: none;
}

.mi-single-product-page .single-product div.product .related {
  display: none;
}

.mi-single-product-page .single-product div.product .up-sells {
  display: none;
}

/* =========================================================
   PRODUCTOS - CANTIDAD + AGREGAR AL CARRITO
   ========================================================= */

.woocommerce .quantity {
  display: flex !important;
  align-items: center;
  justify-content: center;
  /* width: 300px !important;
  min-width: 300px !important; */
  height: 128px;
  margin: 0 !important;
}

/* Botones - y + */
.woocommerce .quantity .minus,
.woocommerce .quantity .plus {
  display: flex !important;
  align-items: center;
  justify-content: center;

  width: 48px !important;
  min-width: 48px !important;
  height: 48px !important;

  padding: 0 !important;
  margin: 0 !important;

  border: 1px solid #d5d5d5 !important;
  background: #fff !important;
  color: #111 !important;

  font-size: 24px !important;
  line-height: 1 !important;

  cursor: pointer;
}

/* Input de cantidad */
.woocommerce .quantity .qty {
  width: 100px !important;
  min-width: 100px !important;
  height: 48px !important;

  padding: 0 !important;
  margin: 0 !important;

  border-top: 1px solid #d5d5d5 !important;
  border-bottom: 1px solid #d5d5d5 !important;
  border-left: 0 !important;
  border-right: 0 !important;

  background: #fff !important;
  color: #111 !important;

  text-align: center !important;
  font-size: 18px !important;
  font-weight: 500 !important;
}

/* Quitar flechas nativas del input */
.woocommerce .quantity .qty::-webkit-inner-spin-button,
.woocommerce .quantity .qty::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.woocommerce .quantity .qty {
  -moz-appearance: textfield;
}

/* =========================================================
   BOTÓN AGREGAR AL CARRITO
   ========================================================= */

.woocommerce .add_to_cart_button,
.woocommerce a.add_to_cart_button,
.woocommerce button.single_add_to_cart_button {
  display: flex !important;
  align-items: center;
  justify-content: center;

  /* width: 180px !important;
  min-width: 180px !important;
  max-width: 180px !important; */

  /* height: 56px !important; */

  padding: 0 24px !important;
  margin: 0 !important;

  white-space: nowrap !important;
  overflow: hidden !important;

  writing-mode: horizontal-tb !important;
  text-orientation: mixed !important;

  background: #000 !important;
  color: #fff !important;

  border: 0 !important;
  border-radius: 8px !important;

  font-size: 16px !important;
  line-height: 1 !important;

  flex-shrink: 0 !important;
}

/* =========================================================
   CONTENEDOR DE CADA PRODUCTO
   ========================================================= */

.woocommerce .product,
.woocommerce li.product {
  min-width: 0;
}

/* Evitar que los elementos se aplasten */
.woocommerce .product .cart,
.woocommerce li.product .cart,
.woocommerce .product form.cart {
  display: flex !important;
  align-items: center;
  gap: 24px;

  min-width: 0;
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 768px) {
  .woocommerce .quantity {
    /* width: 180px !important;
    min-width: 180px !important; */
  }

  .woocommerce .quantity .qty {
    width: 60px !important;
    min-width: 60px !important;
  }

  .woocommerce .quantity .minus,
  .woocommerce .quantity .plus {
    width: 40px !important;
    min-width: 40px !important;
  }

  .woocommerce .add_to_cart_button,
  .woocommerce a.add_to_cart_button,
  .woocommerce button.single_add_to_cart_button {
    /* width: 140px !important;
    min-width: 140px !important;
    max-width: 140px !important; */
    padding: 0 12px !important;
  }

  .woocommerce .product .cart,
  .woocommerce li.product .cart,
  .woocommerce .product form.cart {
    gap: 12px;
  }
}

/* =========================================================
   CANTIDAD WOOCOMMERCE
   ========================================================= */

.product-purchase .quantity {
  display: flex;
  align-items: center;
  width: max-content;
  height: 48px;
  margin: 0;
  border: 1px solid #d9d9d9;
  border-radius: 6px;
  overflow: hidden;
  background: #fff;
}

/* Input */

.product-purchase .quantity .qty {
  width: 50px;
  height: 46px;
  margin: 0;
  padding: 0;
  border: 0;
  outline: none;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
  background: transparent;
  box-shadow: none;
}

/* Ocultar flechas nativas */

.product-purchase .quantity .qty::-webkit-outer-spin-button,
.product-purchase .quantity .qty::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.product-purchase .quantity .qty {
  -moz-appearance: textfield;
}

/* Botones + y - */

.product-purchase .quantity-button {
  width: 42px;
  height: 46px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #111;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;

  display: flex;
  align-items: center;
  justify-content: center;

  transition:
    background-color 0.2s ease,
    color 0.2s ease;
}

.product-purchase .quantity-button:hover {
  background: #f5f5f5;
}

.product-purchase .quantity-button:active {
  background: #ebebeb;
}

/* Separadores */

.product-purchase .quantity-button-minus {
  border-right: 1px solid #e5e5e5;
}

.product-purchase .quantity-button-plus {
  border-left: 1px solid #e5e5e5;
}

/* =========================================================
   ADD TO CART
   ========================================================= */

.product-purchase .single_add_to_cart_button {
  min-height: 48px;
  padding: 0 30px;
  border: 0;
  border-radius: 6px;
  cursor: pointer;
}

/* Producto simple */

.product-purchase form.cart {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* Producto variable */

.product-purchase .variations_button {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 767px) {
  .product-purchase form.cart {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .product-purchase .quantity {
    width: 100%;
    justify-content: space-between;
  }

  .product-purchase .quantity .qty {
    flex: 1;
  }

  .product-purchase .single_add_to_cart_button {
    width: 100%;
  }
}

.product-purchase .variations {
  display: table !important;
  visibility: visible !important;
  opacity: 1 !important;
}

.product-purchase .variations_form {
  display: block !important;
}

.product-purchase .variations select {
  display: block !important;
  visibility: visible !important;
  opacity: 1 !important;
}

/**/
.custom-color-option {
  --swatch-color: #d2d2d2;

  background: var(--swatch-color) !important;
}

.custom-color-option::before {
  background: var(--swatch-color) !important;
}

/* ============================================================
   BOTÓN AGREGAR AL CARRITO — LOADING
   ============================================================ */

.single_add_to_cart_button {
  position: relative;
  transition: opacity 0.2s ease;
}

.single_add_to_cart_button.is-loading {
  pointer-events: none;
  opacity: 0.75;
}

/* Círculo de carga */
.single_add_to_cart_button.is-loading::before {
  content: "";

  display: inline-block;

  width: 14px;
  height: 14px;

  margin-right: 9px;

  border: 2px solid currentColor;
  border-right-color: transparent;

  border-radius: 50%;

  vertical-align: -2px;

  animation: miniCartButtonSpin 0.7s linear infinite;
}

@keyframes miniCartButtonSpin {
  to {
    transform: rotate(360deg);
  }
}

/*/*DRAWER*/

/* ==========================================================
   MINI CART DRAWER
========================================================== */

.mini-cart-overlay {
  position: fixed;
  inset: 0;

  z-index: 999998;

  background: rgba(0, 0, 0, 0.45);

  opacity: 0;
  visibility: hidden;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.mini-cart-overlay.is-open {
  opacity: 1;
  visibility: visible;
}

/* ==========================================================
   DRAWER
========================================================== */

.mini-cart {
  position: fixed;

  top: 0;
  left: 0;

  z-index: 999999;

  width: min(430px, 92vw);
  height: 100vh;

  background: #fff;

  display: flex;
  flex-direction: column;

  right: 0;
  left: auto;
  transform: translateX(100%);

  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);

  box-shadow: 12px 0 40px rgba(0, 0, 0, 0.12);
}

.mini-cart.is-open {
  transform: translateX(0);
}

/* ==========================================================
   HEADER
========================================================== */

.mini-cart__header {
  flex: 0 0 auto;

  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 24px;

  border-bottom: 1px solid #eee;
}

.mini-cart__item-name {
  font-size: 1.3rem;
  line-height: 1;
}

.mini-cart__title {
  margin: 0;

  font-size: 22px;
  line-height: 1.2;
}

.mini-cart__close {
  width: 40px;
  height: 40px;

  padding: 0;

  border: 0;
  background: transparent;

  display: flex;
  align-items: center;
  justify-content: center;

  cursor: pointer;
}

.mini-cart__close svg {
  width: 20px;
  height: 20px;

  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

/* ==========================================================
   BODY
========================================================== */

.mini-cart__body {
  position: relative;

  flex: 1 1 auto;

  overflow-y: auto;

  padding: 20px 24px;
}

.mini-cart__products {
  display: flex;
  flex-direction: column;

  gap: 20px;
}

.mini-cart__item {
  display: grid;

  grid-template-columns: 90px minmax(0, 1fr);

  gap: 15px;

  padding-bottom: 20px;

  border-bottom: 1px solid #eee;
}

.mini-cart__item-image {
  width: 90px;
}

.mini-cart__item-image img {
  display: block;

  width: 100%;
  height: auto;

  aspect-ratio: 1 / 1;

  object-fit: cover;
}

.mini-cart__item-content {
  min-width: 0;

  display: flex;
  flex-direction: column;

  justify-content: space-between;
}

.mini-cart__item-top {
  display: flex;

  justify-content: space-between;

  gap: 10px;
}

.mini-cart__item-title {
  margin: 0 0 6px;

  font-size: 15px;
  line-height: 1.3;
}

.mini-cart__item-variation {
  font-size: 12px;

  color: #777;
}

.mini-cart__item-variation dl {
  margin: 0;
}

.mini-cart__item-variation dt,
.mini-cart__item-variation dd {
  display: inline;
}

.mini-cart__item-variation dt {
  font-weight: 600;
}

.mini-cart__item-variation dd {
  margin: 0 8px 0 3px;
}

.mini-cart__item-variation p {
  display: inline;
  margin: 0;
}

.mini-cart__remove {
  flex: 0 0 auto;

  width: 30px;
  height: 30px;

  padding: 0;

  border: 0;

  background: transparent;

  cursor: pointer;

  opacity: 0.65;
}

.mini-cart__remove:hover {
  opacity: 1;
}

.mini-cart__remove svg {
  width: 18px;
  height: 18px;

  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
}

/* ==========================================================
   BOTTOM ITEM
========================================================== */

.mini-cart__item-bottom {
  display: flex;

  align-items: center;
  justify-content: space-between;

  gap: 10px;

  margin-top: 15px;
}

.mini-cart__quantity {
  display: inline-flex !important;

  align-items: center;

  border: 1px solid #ddd;
}

.mini-cart__qty-button {
  width: 30px;
  height: 30px;

  padding: 0;

  border: 0;

  background: transparent;

  font-size: 18px;

  cursor: pointer;
}

.mini-cart__qty-value {
  min-width: 30px;

  text-align: center;

  font-size: 13px;
}

.mini-cart__item-price {
  font-size: 14px;
  font-weight: 600;
}

/* ==========================================================
   EMPTY
========================================================== */

.mini-cart__empty {
  display: none;

  padding: 50px 20px;

  text-align: center;
}

.mini-cart.is-empty .mini-cart__empty {
  display: block;
}

/* ==========================================================
   FOOTER
========================================================== */

.mini-cart__footer {
  flex: 0 0 auto;

  padding: 20px 24px 24px;

  border-top: 1px solid #eee;

  background: #fff;
}

.mini-cart__subtotal {
  display: flex;

  align-items: center;
  justify-content: space-between;

  margin-bottom: 18px;

  font-size: 16px;
}

.mini-cart__subtotal-value {
  font-size: 18px;
}

/* ==========================================================
   BUTTONS
========================================================== */

.mini-cart__button {
  display: flex;

  align-items: center;
  justify-content: center;

  width: 100%;

  min-height: 50px;

  margin-top: 10px;

  text-decoration: none;

  font-size: 14px;
  font-weight: 600;

  transition:
    opacity 0.2s ease,
    transform 0.2s ease;
}

.mini-cart__button:hover {
  opacity: 0.85;
  transform: translateY(-1px);
}

.mini-cart__button--cart {
  border: 1px solid #111;

  color: #111;

  background: #fff;
}

.mini-cart__button--checkout {
  border: 1px solid #111;

  color: #fff;

  background: #111;
}

/* ==========================================================
   LOADING
========================================================== */

.mini-cart__loading {
  position: absolute;

  inset: 0;

  z-index: 10;

  display: none;

  align-items: center;
  justify-content: center;

  background: rgba(255, 255, 255, 0.65);
}

.mini-cart.is-loading .mini-cart__loading {
  display: flex;
}

.mini-cart__loading span {
  width: 25px;
  height: 25px;

  border: 2px solid #ddd;
  border-top-color: #111;

  border-radius: 50%;

  animation: miniCartSpin 0.7s linear infinite;
}

@keyframes miniCartSpin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================
   BODY LOCK
========================================================== */

body.mini-cart-open {
  overflow: hidden;
}

/* ==========================================================
   MOBILE
========================================================== */

@media (max-width: 600px) {
  .mini-cart {
    width: 92vw;
  }

  .mini-cart__header {
    padding: 20px;
  }

  .mini-cart__body {
    padding: 18px 20px;
  }

  .mini-cart__footer {
    padding: 18px 20px 20px;
  }
}

/* ============================================================
   MINI CART
   ============================================================ */

/* OVERLAY */
#mini-cart-overlay {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;

  background: rgba(0, 0, 0, 0.45);

  z-index: 9998;

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

/* OVERLAY VISIBLE */
#mini-cart-overlay.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

/* MINI CART */
#mini-cart {
  position: fixed;
  top: 0;
  right: 0;

  width: min(420px, 90vw);
  height: 100vh;

  background: #fff;

  z-index: 9999;

  transform: translateX(100%);
  transition: transform 0.3s ease;

  overflow-y: auto;
}

/* MINI CART ABIERTO */
#mini-cart.is-open {
  transform: translateX(0);
}

/* ============================================================
   EVITAR SCROLL DEL BODY CUANDO EL MINI CART ESTÁ ABIERTO
   ============================================================ */

body.mini-cart-open {
  overflow: hidden;
}

/* Imagen de guía de tallas */
.product-tab-content[data-content="size"] .product-description img {
  width: 750px;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  display: block;
}

.product-purchase .added_to_cart.wc-forward {
  display: none !important;
}
