/* Store-owned PDP container corrections. Keeps the Builder module flow intact.

   ORDEN ÚNICO DE LA FICHA (desktop: fila de la grilla · celular/tablet: order del flex).
   Este archivo es el único lugar que ordena los bloques de la columna de compra; los demás
   módulos (lp-store-single-title, pestañas, confianza, reseñas) no asignan filas ni orders.

     1  migas de pan            .loq-pdp-breadcrumbs
     2  marca                   .lp-fragrance-identity
     3  título + presentación   .lqsp-titleflow
     4  calificación            .lp-pdp-reviews (siempre presente: con reseñas o "Sé el primero")
     5  descripción breve       .lp-pdp-short-description (+ notas)
     6  precio                  .lqsp-priceflow
     7  método de pago          .lp-store-pdp-payment-method
     8  formato                 .lp-fragrance-formats
     9  añadir al carrito       .lqsp-buyflow
    10  confianza               .lp-pdp-confianza (WhatsApp, entrega, compra protegida, envío, original)
    11  bloques del Core que la confianza reemplaza (ocultos): envío, compra protegida, cuotas
    12  pestañas                .lq-tabs            (ancho completo)
    13  reseñas                 .lp-resenas         (ancho completo)
    14  así preparamos          .lp-store-pdp-preparation-shorts
    15  relacionados            .lqsp-related-products-section
*/
body.single-product .lq-sp {
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
}

body.single-product .lq-sp > .site-container.gds-container {
  box-sizing: border-box;
  width: 100%;
  max-width: 1440px !important;
  margin-inline: auto !important;
  padding-inline: clamp(18px, 3vw, 48px) !important;
}

body.single-product .lq-sp .lqsp-desktop {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
}

body.single-product .lq-sp .lqsp-desktop > * {
  box-sizing: border-box;
  min-width: 0;
}

/* Keep the purchase decision compact and give the real add-to-cart action one
   clear, consistent treatment without changing Builder module behavior. */
body.single-product .lq-sp .lqsp-priceflow {
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-main {
  color: var(--gds-color-text, #111316) !important;
  font-size: clamp(1.75rem, 3vw, 2.25rem) !important;
  font-weight: 750 !important;
  line-height: 1.05 !important;
}

/* Core already emits the sale percentage from WooCommerce's active sale data.
   Arrange its existing badge beside the current price without duplicating it. */
body.single-product .lq-sp .lqsp-priceflow .lq-price-anchor:has(.lq-badge-sale--inline[data-price-role="sale-pct"]) {
  display: grid !important;
  grid-template-columns: max-content max-content;
  grid-template-areas:
    "regular regular"
    "current badge"
    "transfer transfer";
  align-items: baseline;
  justify-content: start;
  column-gap: 10px;
  row-gap: 4px;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-anchor:has(.lq-badge-sale--inline[data-price-role="sale-pct"]) .lq-price-main {
  grid-area: current;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-row--regular {
  display: contents !important;
}

/* Precio por transferencia (tiendas con descuento): siempre debajo del precio, que es lo primero que se lee. */
body.single-product .lq-sp .lqsp-priceflow .lq-price-anchor:not(:has(.lq-badge-sale--inline[data-price-role="sale-pct"])) {
  display: grid !important;
  grid-template-columns: minmax(0, max-content);
  grid-template-areas:
    "current"
    "transfer";
  justify-content: start;
  row-gap: 4px;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-anchor .lq-price-main {
  grid-area: current;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-anchor .lq-transfer-price {
  grid-area: transfer;
  justify-self: start;
}

/* Sin precio de oferta la fila viene con hidden: no se dibuja ni la pastilla "0% OFF". */
body.single-product .lq-sp .lqsp-priceflow .lq-price-row--regular[hidden] {
  display: none !important;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-regular-label {
  display: none !important;
}

body.single-product .lq-sp .lqsp-priceflow .lq-price-row--regular del {
  grid-area: regular;
  align-self: start;
}

body.single-product .lq-sp .lqsp-priceflow .lq-badge-sale--inline[data-price-role="sale-pct"] {
  position: static !important;
  inset: auto !important;
  grid-area: badge;
  display: inline-flex !important;
  align-items: center;
  align-self: center;
  justify-self: start;
  width: max-content !important;
  min-height: 24px !important;
  height: auto !important;
  justify-content: center;
  padding: 0 9px !important;
  border: 0;
  border-radius: 4px !important;
  background: var(--gds-color-success, #00a650) !important;
  color: #fff !important;
  font-size: 0.75rem !important;
  font-weight: 700 !important;
  line-height: 1;
  white-space: nowrap;
}

body.single-product .lq-sp .lqsp-buyflow .lq-custom-btns {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  gap: 0 !important;
  margin: 0 !important;
}

body.single-product .lq-sp .lqsp-buyflow .lq-custom-btns .lq-btn-buy-now {
  display: none !important;
}

body.single-product .lq-sp .lqsp-buyflow .lq-custom-btns .lq-btn-add-cart {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  margin: 0 !important;
  padding: 12px 20px;
  border: 1px solid var(--gds-color-text, #111316) !important;
  border-radius: var(--gds-radius-control, 8px) !important;
  background: var(--gds-color-text, #111316) !important;
  color: var(--gds-color-surface, #fff) !important;
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.2;
  text-align: center;
  box-shadow: none !important;
}

body.single-product .lq-sp .lqsp-buyflow .lq-custom-btns .lq-btn-add-cart:hover,
body.single-product .lq-sp .lqsp-buyflow .lq-custom-btns .lq-btn-add-cart:focus-visible {
  background: #303236 !important;
  border-color: #303236 !important;
}

/* ---------------------------------------------------------------------------
   Ritmo vertical de la columna de compra (el Core pone row-gap 16px y margen 0
   en cada bloque; acá se pide el aire extra donde cambia de zona).
   --------------------------------------------------------------------------- */
body.single-product .lq-sp .lqsp-desktop > .lp-fragrance-formats {
  margin-top: 8px !important;
}

body.single-product .lq-sp .lqsp-desktop > .lqsp-buyflow {
  margin-top: 8px !important;
}

body.single-product .lq-sp .lqsp-desktop > .lp-pdp-confianza {
  margin-top: 4px !important;
}

/* Envío y Compra Protegida del Core: la misma información vive en el módulo de confianza debajo del botón. Sólo se
   ocultan como bloques sueltos de la columna; dentro de la pestaña "Garantía y devoluciones" siguen visibles.
   Las cuotas sí quedan, pegadas al precio (tiendas con cuotas sin interés; sin cuotas el bloque no se dibuja). */
body.single-product .lq-sp .lqsp-desktop > .lq-shipping-minimal,
body.single-product .lq-sp .lqsp-desktop > .lq-trust-info-section {
  display: none !important;
}

/* La columna de compra va en filas numeradas: las cuotas ocupan la primera libre entre el precio y el botón
   (escritorio: fila 7, en el mapa de filas de más abajo; tablet de 768 a 1023: fila 7, columna 2; celular: fila 8, debajo del precio). */
body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments {
  margin-top: -6px !important;
  padding-inline: 16px !important; /* el mismo margen interno que el precio y el botón */
}

body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments .lq-pdp-installments__text {
  font-size: 14px;
  font-weight: 500;
}

body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments .lq-pdp-installments__text .amount {
  color: var(--gds-color-text, #111316);
  font-weight: 700;
}

/* Tablet (dos columnas desde 768 px): en la columna de compra, como en escritorio. Celular: una columna. */
@media (min-width: 768px) and (max-width: 1023px) {
  body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments {
    grid-row: 7 !important;
    grid-column: 2 !important;
  }
}

@media (max-width: 767px) {
  body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments {
    grid-row: 8 !important;
    grid-column: 1 !important;
  }
}

/* ---------------------------------------------------------------------------
   Celular y tablet: una sola columna en el mismo orden.
   --------------------------------------------------------------------------- */
@media (max-width: 1023px) {
  body.single-product .lq-sp > .site-container.gds-container {
    padding-inline: 18px !important;
  }

  body.single-product .lq-sp .lqsp-desktop {
    align-items: stretch;
  }

  body.single-product .lq-sp .lqsp-desktop > * {
    width: 100%;
    max-width: 100%;
    order: 20;
  }

  body.single-product .lq-sp .lqsp-titleflow,
  body.single-product .lq-sp .lqsp-buyflow,
  body.single-product .lq-sp .lp-fragrance-notes,
  body.single-product .lq-sp .lq-tabs,
  body.single-product .lq-sp .lp-resenas,
  body.single-product .lq-sp .lqsp-related-products-section {
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    min-width: 0;
  }

  body.single-product .lq-sp .lqsp-desktop > .loq-pdp-breadcrumbs { order: 0 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-gallery { order: 1 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-fragrance-identity { order: 2 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-titleflow { order: 3 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-reviews { order: 4 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-short-description { order: 5 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-priceflow { order: 6 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-store-pdp-payment-method,
  body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments { order: 7 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-fragrance-formats { order: 8 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-buyflow {
    order: 9 !important;
    grid-column: 1 !important;
    grid-row: auto !important;
  }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-confianza { order: 10 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lq-shipping-minimal,
  body.single-product .lq-sp .lqsp-desktop > .lq-trust-info-section { order: 11 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lq-tabs { order: 12 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-resenas { order: 13 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-store-pdp-preparation-shorts { order: 14 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-related-products-section { order: 15 !important; }

  body.single-product .lq-sp .lqsp-titleflow .product_title {
    max-width: 100%;
    white-space: normal;
    overflow-wrap: anywhere;
    font-size: clamp(1.75rem, 8vw, 2.25rem);
  }

  body.single-product .lq-sp .lp-fragrance-notes__grid {
    box-sizing: border-box;
    width: 100%;
    min-width: 0;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.single-product .lq-sp .lp-fragrance-notes__card {
    min-width: 0;
  }
}

/* ---------------------------------------------------------------------------
   Escritorio: galería a la izquierda (filas 1-11), compra a la derecha, y los
   bloques de ancho completo debajo del más alto de los dos.
   --------------------------------------------------------------------------- */
@media (min-width: 1024px) {
  body.single-product .lq-sp .lqsp-desktop {
    column-gap: clamp(32px, 3.5vw, 56px);
  }

  /* Builder marks editorial blocks as full-width. Core's PDP grid keeps them
     in the purchase column unless the store enforces the full row here. */
  body.single-product .lq-sp .lqsp-desktop > .lqsp-block--full {
    grid-column: 1 / -1 !important;
    width: 100% !important;
    max-width: 100%;
  }

  body.single-product .lq-sp .lqsp-desktop > .lqsp-gallery { grid-row: 1 / span 11 !important; }

  body.single-product .lq-sp .lqsp-desktop > .loq-pdp-breadcrumbs { grid-column: 2 !important; grid-row: 1 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-fragrance-identity { grid-column: 2 !important; grid-row: 2 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-titleflow { grid-column: 2 !important; grid-row: 3 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-reviews { grid-column: 2 !important; grid-row: 4 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-short-description { grid-column: 2 !important; grid-row: 5 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-priceflow { grid-column: 2 !important; grid-row: 6 !important; margin: 0 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-store-pdp-payment-method,
  body.single-product .lq-sp .lqsp-desktop > .lq-pdp-installments { grid-column: 2 !important; grid-row: 7 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-fragrance-formats { grid-column: 2 !important; grid-row: 8 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lqsp-buyflow { grid-column: 2 !important; grid-row: 9 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-pdp-confianza { grid-column: 2 !important; grid-row: 10 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lq-shipping-minimal,
  body.single-product .lq-sp .lqsp-desktop > .lq-trust-info-section { grid-column: 2 !important; grid-row: 11 !important; }

  body.single-product .lq-sp .lqsp-desktop > .lq-tabs.lqsp-block--full { grid-row: 12 !important; margin-top: 0 !important; }
  body.single-product .lq-sp .lqsp-desktop > .lp-resenas { grid-row: 13 !important; }
  /* "Así preparamos tu pedido" y relacionados se ubican solos en las filas siguientes. */
}

/* Unboxed delivery copy uses the published global benefit/success token. */
body.single-product .lq-sp .lq-shipping-minimal {
  align-items: center !important;
  gap: 8px !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--gds-color-success, #00a650) !important;
  font-size: 12px !important;
  line-height: 1.35;
}

body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-icon,
body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-main,
body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-sub,
body.single-product .lq-sp .lq-shipping-minimal strong {
  color: var(--gds-color-success, #00a650) !important;
}

body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  flex: 0 0 18px;
  margin: 0 !important;
}

body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin: 0 !important;
  font-size: 12px !important;
  line-height: 1.35 !important;
}

body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-text *,
body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-main,
body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-sub {
  font-size: 12px !important;
  line-height: 1.35 !important;
}

body.single-product .lq-sp .lq-shipping-minimal .lq-shipping-sub {
  opacity: 0.82;
}

/* Compra protegida (dentro de la pestaña Garantía y devoluciones): líneas de beneficio, sin tarjeta. */
body.single-product .lq-sp .lq-trust-info-section {
  display: flex !important;
  flex-direction: column;
  gap: 10px !important;
  width: 100%;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--gds-color-text, #111316) !important;
  font-size: 14px !important;
  line-height: 1.45;
}

body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-row {
  align-items: center;
  gap: 10px;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
  margin: 0 !important;
  color: var(--gds-color-text, #111316) !important;
}

body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-content,
body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-link,
body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-text {
  font-size: 14px !important;
  line-height: 1.45 !important;
}

body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-content * {
  font-size: 14px !important;
  line-height: 1.45 !important;
}

body.single-product .lq-sp .lq-trust-info-section .lq-trust-info-link {
  font-weight: 650;
  text-decoration: none;
}

/* Keep the product identity stack compact on every PDP. */
body.single-product .lq-sp .lp-fragrance-identity {
  margin-block-end: -6px !important;
}

body.single-product .lq-sp .lqsp-titleflow {
  margin-block: -2px 0 !important;
}

body.single-product .lq-sp .lqsp-titleflow .product_title {
  margin-block: 0 !important;
}

body.single-product .lq-sp .lp-pdp-reviews {
  margin-block-start: -6px !important;
}

/* The Core header prints its own rating row; the store's rating block (fila 4) replaces it. */
body.single-product .lq-sp .lqsp-titleflow .lq-header-rating {
  display: none !important;
}
