/* OREYNE Product Page v1.7.40 — Low Stock Mode */

/* Product detail: 1–5 real stock = restrained urgency. */
body.oreyne-pdp-active .oreyne-pdp-key-info__row.availability.low-stock .oreyne-pdp-key-info__label,
body.oreyne-pdp-active .oreyne-pdp-key-info__row.availability.low-stock .oreyne-pdp-key-info__value {
    color: #9b3b35 !important;
}

body.oreyne-pdp-active .oreyne-pdp-key-info__row.availability.low-stock .oreyne-pdp-key-info__value {
    font-weight: 500;
}

body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock {
    justify-content: flex-start;
    flex-wrap: wrap;
}

body.oreyne-pdp-active .oreyne-pdp-low-stock-note {
    display: inline-flex;
    flex: 1 1 180px;
    min-width: 0;
    max-width: 260px;
    margin: 0 auto 0 0;
    padding: 0;
    flex-direction: column;
    justify-content: center;
    gap: 2px;
    color: #9b3b35;
    font-size: 12px;
    line-height: 1.35;
}

body.oreyne-pdp-active .oreyne-pdp-low-stock-note[hidden] {
    display: none !important;
}

body.oreyne-pdp-active .oreyne-pdp-low-stock-note__title {
    font-weight: 600;
}

body.oreyne-pdp-active .oreyne-pdp-low-stock-note__text {
    font-weight: 400;
}

body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity input.qty {
    cursor: default;
}

body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity .plus,
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity .minus,
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity [data-qty-plus],
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity [data-qty-minus],
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity [data-quantity-plus],
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity [data-quantity-minus] {
    opacity: .32 !important;
    pointer-events: none !important;
    cursor: default !important;
}

@media (max-width: 767px) {
    body.oreyne-pdp-active .oreyne-pdp-low-stock-note {
        flex-basis: 135px;
        max-width: 185px;
        font-size: 11.5px;
    }
}

/* Mini Cart / Cart / Checkout. */
.oreyne-low-stock-cart-note {
    display: block;
    margin-top: 4px;
    color: #9b3b35;
    font-size: 11px;
    line-height: 1.35;
    font-weight: 500;
}

.oreyne-low-stock-cart-qty {
    display: inline-block;
    min-width: 18px;
    color: inherit;
}

.oreyne-low-stock-item .quantity .plus,
.oreyne-low-stock-item .quantity .minus,
.oreyne-low-stock-item .quantity [data-qty-plus],
.oreyne-low-stock-item .quantity [data-qty-minus],
.oreyne-low-stock-item .quantity [data-quantity-plus],
.oreyne-low-stock-item .quantity [data-quantity-minus] {
    opacity: .32 !important;
    pointer-events: none !important;
    cursor: default !important;
}

/* v1.7.39: product detail Low Stock quantity is a fixed display value, not an editable control. */
body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity input.qty {
    pointer-events: none !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    cursor: default !important;
}


/* v1.7.40: keep a clear, non-editable Quantity = 1 visual box even when WooCommerce
   converts min=max=1 into a hidden quantity input. The hidden native field remains in
   the form so checkout submission still carries quantity=1. */
body.oreyne-pdp-active .oreyne-pdp-low-stock-static-qty {
    flex: 0 0 142px;
    width: 142px;
    max-width: 142px;
    min-height: 48px;
    margin: 0;
    border: 1px solid #dedbd6;
    background: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    color: #222;
    font-size: 15px;
    font-weight: 400;
    line-height: 1;
    cursor: default;
    user-select: none;
    -webkit-user-select: none;
}

body.oreyne-pdp-active .oreyne-pdp-low-stock-static-qty[hidden] {
    display: none !important;
}

body.oreyne-pdp-active .oreyne-pdp-purchase-row.is-low-stock .quantity.oreyne-pdp-low-stock-native-qty {
    /* Keep WooCommerce's hidden quantity=1 field in the form, but remove its empty visual slot. */
    position: absolute !important;
    width: 1px !important;
    max-width: 1px !important;
    min-width: 1px !important;
    min-height: 1px !important;
    height: 1px !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    clip: rect(0 0 0 0) !important;
    clip-path: inset(50%) !important;
    white-space: nowrap !important;
}

@media (max-width: 767px) {
    body.oreyne-pdp-active .oreyne-pdp-low-stock-static-qty {
        flex-basis: 118px;
        width: 118px;
        max-width: 118px;
        min-height: 46px;
        font-size: 14px;
    }
}
