/*
 * Our Theme Pro 5.9.352 — PRODUCT MOBILE FINAL LOCK
 * Reference: approved mobile composition supplied by the merchant.
 * Scope: product page, <= 767.98px only.
 *
 * This file intentionally fixes only the conversion-card geometry that was
 * being overridden by older rules inside the theme bundle. No checkout,
 * category, desktop or tablet selectors are touched.
 */
@media (max-width: 767.98px) {
  /* Keep the normal gallery -> info rhythm, but reserve enough room between
     the availability/info card and the floating conversion ribbon. */
  html body#product .ots-pdp-final__buy,
  html body.page-product .ots-pdp-final__buy {
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    width: 100% !important;
    margin-top: 18px !important;
    padding: 42px 12px 14px !important;
    overflow: visible !important;
    border: 1px solid #efdee4 !important;
    border-radius: 20px !important;
    background: #fff !important;
    box-shadow: 0 7px 24px rgba(92,8,37,.06) !important;
    box-sizing: border-box !important;
  }

  /* Critical regression fix: an older theme rule forced this ribbon to
     position:static + width:100%. The approved layout is a compact floating
     tab attached to the upper-right corner of the purchase card. */
  html body#product .ots-pdp-final__buy > .ots-pdp-final__ribbon,
  html body.page-product .ots-pdp-final__buy > .ots-pdp-final__ribbon {
    position: absolute !important;
    inset: -16px 8px auto auto !important;
    top: -16px !important;
    right: 8px !important;
    bottom: auto !important;
    left: auto !important;
    order: 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 7px !important;
    width: 181px !important;
    min-width: 181px !important;
    max-width: calc(100% - 24px) !important;
    min-height: 34px !important;
    height: 34px !important;
    margin: 0 !important;
    padding: 7px 12px !important;
    border: 0 !important;
    border-radius: 0 0 8px 8px !important;
    background: linear-gradient(135deg,#a90034,#c30945) !important;
    color: #fff !important;
    font-family: Poppins,Arial,sans-serif !important;
    font-size: 10.5px !important;
    font-weight: 700 !important;
    line-height: 1 !important;
    text-align: center !important;
    white-space: nowrap !important;
    box-shadow: 0 8px 18px rgba(125,0,31,.14) !important;
    z-index: 12 !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__buy > .ots-pdp-final__ribbon > span,
  html body.page-product .ots-pdp-final__buy > .ots-pdp-final__ribbon > span {
    flex: 0 0 auto !important;
    margin: 0 !important;
    font-size: 13px !important;
    line-height: 1 !important;
  }

  /* PRICE — exact approved inset card. */
  html body#product .ots-pdp-final__buy .product__prices,
  html body.page-product .ots-pdp-final__buy .product__prices {
    display: block !important;
    width: 100% !important;
    margin: 0 0 18px !important;
    padding: 18px 15px 17px !important;
    border: 1px solid #f1dfe5 !important;
    border-radius: 18px !important;
    background: linear-gradient(180deg,#fff9fb 0%,#fff5f8 100%) !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__buy .product__prices-block,
  html body.page-product .ots-pdp-final__buy .product__prices-block {
    display: block !important;
    width: 100% !important;
    text-align: center !important;
  }
  html body#product .ots-pdp-price-main-row,
  html body.page-product .ots-pdp-price-main-row {
    display: flex !important;
    align-items: baseline !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
    gap: 7px 14px !important;
    width: 100% !important;
  }
  html body#product .ots-pdp-final__buy .product__price,
  html body.page-product .ots-pdp-final__buy .product__price {
    flex: 0 0 auto !important;
    margin: 0 !important;
    color: #b80036 !important;
    font-family: Poppins,Arial,sans-serif !important;
    font-size: 43px !important;
    font-weight: 700 !important;
    line-height: .95 !important;
    letter-spacing: -.055em !important;
    white-space: nowrap !important;
  }
  html body#product .ots-pdp-final__buy .product__tax-infos,
  html body.page-product .ots-pdp-final__buy .product__tax-infos {
    margin: 16px 0 0 !important;
    color: #756a6f !important;
    font-size: 13px !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
    white-space: nowrap !important;
  }
  html body#product .ots-pdp-discount-row,
  html body.page-product .ots-pdp-discount-row {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
    gap: 9px !important;
    margin: 13px 0 0 !important;
  }
  html body#product .ots-pdp-final__buy .product__regular-price,
  html body.page-product .ots-pdp-final__buy .product__regular-price {
    margin: 0 !important;
    color: #81787d !important;
    font-size: 16px !important;
    font-weight: 500 !important;
    line-height: 1 !important;
    text-decoration: line-through !important;
  }
  html body#product .ots-pdp-final__buy .product__discount-percentage,
  html body#product .ots-pdp-final__buy .product__discount-amount,
  html body.page-product .ots-pdp-final__buy .product__discount-percentage,
  html body.page-product .ots-pdp-final__buy .product__discount-amount {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    min-height: 32px !important;
    padding: 6px 12px !important;
    border: 1px solid #f3c5d1 !important;
    border-radius: 999px !important;
    background: #ffe8ef !important;
    color: #b80036 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    line-height: 1.1 !important;
    white-space: nowrap !important;
  }

  /* The desktop quantity label is hidden; the compact label belongs to the
     quantity control, exactly as in the approved mobile reference. */
  html body#product .ots-pdp-final__buy > .ots-pdp-final__quantity-label,
  html body#product .ots-pdp-final__buy .ots-pdp-final__actions > form > .ots-pdp-final__quantity-label,
  html body.page-product .ots-pdp-final__buy > .ots-pdp-final__quantity-label,
  html body.page-product .ots-pdp-final__buy .ots-pdp-final__actions > form > .ots-pdp-final__quantity-label {
    display: none !important;
  }

  /* QUANTITY + CTA — one compact decision row. */
  html body#product .ots-pdp-final__buy .product__actions-qty-add,
  html body#product .ots-pdp-final__buy .ots-pdp-qty-row,
  html body.page-product .ots-pdp-final__buy .product__actions-qty-add,
  html body.page-product .ots-pdp-final__buy .ots-pdp-qty-row {
    display: grid !important;
    grid-template-columns: 104px minmax(0,1fr) !important;
    column-gap: 10px !important;
    row-gap: 0 !important;
    align-items: stretch !important;
    width: 100% !important;
    max-width: none !important;
    height: 49px !important;
    min-height: 49px !important;
    max-height: 49px !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__buy .product__actions-qty-add > :not(.product-actions__quantity):not(.product__add-to-cart),
  html body.page-product .ots-pdp-final__buy .product__actions-qty-add > :not(.product-actions__quantity):not(.product__add-to-cart) {
    display: none !important;
  }
  html body#product .ots-pdp-final__buy .product-actions__quantity,
  html body.page-product .ots-pdp-final__buy .product-actions__quantity {
    position: relative !important;
    display: block !important;
    width: 104px !important;
    min-width: 104px !important;
    max-width: 104px !important;
    height: 49px !important;
    min-height: 49px !important;
    max-height: 49px !important;
    margin: 0 !important;
    padding: 14px 0 0 !important;
    overflow: visible !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-mobile-qty-label,
  html body.page-product .ots-pdp-mobile-qty-label {
    position: absolute !important;
    top: 0 !important;
    left: 2px !important;
    display: block !important;
    margin: 0 !important;
    color: #40383c !important;
    font-size: 10px !important;
    font-weight: 500 !important;
    line-height: 12px !important;
    white-space: nowrap !important;
  }
  html body#product .ots-pdp-final__buy .product__quantity,
  html body#product .ots-pdp-final__buy .quantity-button,
  html body#product .ots-pdp-final__buy .input-group,
  html body#product .ots-pdp-final__buy .quantity-button__group,
  html body.page-product .ots-pdp-final__buy .product__quantity,
  html body.page-product .ots-pdp-final__buy .quantity-button,
  html body.page-product .ots-pdp-final__buy .input-group,
  html body.page-product .ots-pdp-final__buy .quantity-button__group {
    width: 104px !important;
    min-width: 104px !important;
    max-width: 104px !important;
    margin: 0 !important;
  }
  html body#product .ots-pdp-final__buy .quantity-button__group,
  html body.page-product .ots-pdp-final__buy .quantity-button__group {
    display: grid !important;
    grid-template-columns: 34px 36px 34px !important;
    height: 35px !important;
    min-height: 35px !important;
    max-height: 35px !important;
    border: 1px solid #ead8de !important;
    border-radius: 11px !important;
    background: #fff !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__buy .quantity-button__group > button,
  html body#product .ots-pdp-final__buy .quantity-button__group > input,
  html body.page-product .ots-pdp-final__buy .quantity-button__group > button,
  html body.page-product .ots-pdp-final__buy .quantity-button__group > input {
    height: 35px !important;
    min-height: 35px !important;
    max-height: 35px !important;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
  }
  html body#product .ots-pdp-final__buy .product__add-to-cart,
  html body.page-product .ots-pdp-final__buy .product__add-to-cart {
    display: flex !important;
    align-items: center !important;
    justify-self: stretch !important;
    align-self: stretch !important;
    flex: 1 1 auto !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 49px !important;
    min-height: 49px !important;
    max-height: 49px !important;
    margin: 0 !important;
    padding: 0 !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__buy .product__add-to-cart-button,
  html body.page-product .ots-pdp-final__buy .product__add-to-cart-button {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    width: 100% !important;
    min-width: 0 !important;
    max-width: none !important;
    height: 49px !important;
    min-height: 49px !important;
    max-height: 49px !important;
    margin: 0 !important;
    padding: 0 14px !important;
    border: 0 !important;
    border-radius: 26px !important;
    background: linear-gradient(135deg,#b60038,#cb0044) !important;
    color: #fff !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    box-shadow: 0 10px 22px rgba(183,0,54,.18) !important;
    box-sizing: border-box !important;
  }

  /* Approved three-column reassurance row. */
  html body#product .ots-pdp-final__trust,
  html body.page-product .ots-pdp-final__trust {
    display: grid !important;
    grid-template-columns: repeat(3,minmax(0,1fr)) !important;
    gap: 0 !important;
    width: 100% !important;
    margin: 18px 0 0 !important;
    padding: 14px 2px 13px !important;
    border: 0 !important;
    border-top: 1px solid #efdee4 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__trust-item,
  html body#product .ots-pdp-final__trust-item.has-no-icon,
  html body.page-product .ots-pdp-final__trust-item,
  html body.page-product .ots-pdp-final__trust-item.has-no-icon {
    position: relative !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-start !important;
    gap: 7px !important;
    min-width: 0 !important;
    padding: 0 6px !important;
    text-align: center !important;
  }
  html body#product .ots-pdp-final__trust-icon,
  html body.page-product .ots-pdp-final__trust-icon {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
    margin: 0 !important;
    border-radius: 50% !important;
    background: #ffedf2 !important;
    color: #bd0037 !important;
  }
  html body#product .ots-pdp-final__trust-text,
  html body.page-product .ots-pdp-final__trust-text {
    display: block !important;
    max-width: none !important;
    margin: 0 auto !important;
    color: #4d4549 !important;
    font-size: 9.2px !important;
    font-weight: 500 !important;
    line-height: 1.25 !important;
    text-align: center !important;
    white-space: normal !important;
  }

  /* Approved confidence / payment card. */
  html body#product .ots-pdp-final__security,
  html body.page-product .ots-pdp-final__security {
    width: 100% !important;
    margin: 14px 0 0 !important;
    padding: 12px !important;
    border: 1px solid #efd7df !important;
    border-radius: 15px !important;
    background: #fff1f5 !important;
    box-shadow: none !important;
    overflow: visible !important;
    box-sizing: border-box !important;
  }
  html body#product .ots-pdp-final__security-title,
  html body.page-product .ots-pdp-final__security-title {
    display: grid !important;
    grid-template-columns: 31px minmax(0,1fr) !important;
    gap: 9px !important;
    align-items: center !important;
    padding: 0 !important;
  }
  html body#product .ots-pdp-final__payments,
  html body.page-product .ots-pdp-final__payments {
    display: flex !important;
    align-items: center !important;
    justify-content: space-around !important;
    flex-wrap: nowrap !important;
    gap: 8px !important;
    margin: 9px 0 0 !important;
    padding: 9px 10px !important;
    border: 1px solid #f1dfe4 !important;
    border-radius: 10px !important;
    background: #fff !important;
    box-sizing: border-box !important;
  }
}

@media (max-width: 374px) {
  html body#product .ots-pdp-final__buy > .ots-pdp-final__ribbon,
  html body.page-product .ots-pdp-final__buy > .ots-pdp-final__ribbon {
    width: 181px !important;
    min-width: 181px !important;
    max-width: calc(100% - 20px) !important;
    right: 6px !important;
  }
  html body#product .ots-pdp-final__buy .product__actions-qty-add,
  html body#product .ots-pdp-final__buy .ots-pdp-qty-row,
  html body.page-product .ots-pdp-final__buy .product__actions-qty-add,
  html body.page-product .ots-pdp-final__buy .ots-pdp-qty-row {
    grid-template-columns: 96px minmax(0,1fr) !important;
    column-gap: 8px !important;
  }
  html body#product .ots-pdp-final__buy .product-actions__quantity,
  html body#product .ots-pdp-final__buy .product__quantity,
  html body#product .ots-pdp-final__buy .quantity-button,
  html body#product .ots-pdp-final__buy .input-group,
  html body#product .ots-pdp-final__buy .quantity-button__group,
  html body.page-product .ots-pdp-final__buy .product-actions__quantity,
  html body.page-product .ots-pdp-final__buy .product__quantity,
  html body.page-product .ots-pdp-final__buy .quantity-button,
  html body.page-product .ots-pdp-final__buy .input-group,
  html body.page-product .ots-pdp-final__buy .quantity-button__group {
    width: 96px !important;
    min-width: 96px !important;
    max-width: 96px !important;
  }
  html body#product .ots-pdp-final__buy .quantity-button__group,
  html body.page-product .ots-pdp-final__buy .quantity-button__group {
    grid-template-columns: 31px 34px 31px !important;
  }
  html body#product .ots-pdp-final__buy .product__add-to-cart-button,
  html body.page-product .ots-pdp-final__buy .product__add-to-cart-button {
    font-size: 12.5px !important;
    padding-inline: 10px !important;
  }
}


/* 5.9.352 — remove the outer white info box on mobile, keep only the availability card boxed; the price/buy card remains boxed exactly as before. */
@media (max-width: 767.98px) {
  html body#product .ots-pdp-final__info,
  html body.page-product .ots-pdp-final__info {
    margin: 0 0 14px !important;
    padding: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  html body#product .ots-pdp-final__info-card,
  html body.page-product .ots-pdp-final__info-card {
    padding: 18px 16px 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }
}
