/*
 * Baypo Dynamic Add-ons
 * Clean professional configurator CSS
 */

/* -----------------------------
   Main container
----------------------------- */

.baypo-da-live {
    direction: rtl !important;
    display: flex !important;
    flex-direction: column !important;
    background: #ffffff !important;
    border: 1px solid #e6e8ef !important;
    padding: 14px 16px !important;
    margin: 16px 0 !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.03) !important;
    color: #000b3f !important;
}

.baypo-da-live .baypo-da-addon-input {
    display: none !important;
}

/* -----------------------------
   Section order
----------------------------- */

.baypo-da-live .baypo-da-price-wrap {
    order: 1 !important;
}

.baypo-da-live .baypo-da-summary-wrap {
    order: 2 !important;
}

.baypo-da-live .baypo-da-qty-wrap {
    order: 3 !important;
}

.baypo-da-live .baypo-da-actions {
    order: 4 !important;
}

.baypo-da-live .baypo-da-add-to-cart-result {
    order: 5 !important;
}

.baypo-da-live .baypo-da-group {
    order: 10 !important;
}

/* -----------------------------
   Price
----------------------------- */

.baypo-da-live .baypo-da-price-wrap {
    display: flex !important;
    justify-content: center !important;
    align-items: baseline !important;
    gap: 8px !important;
    flex-wrap: wrap !important;
    min-height: 32px !important;
    border-top: 0 !important;
    border-bottom: 1px solid #eef0f4 !important;
    padding-top: 0 !important;
    padding-bottom: 10px !important;
    margin-top: 0 !important;
    margin-bottom: 8px !important;
    text-align: center !important;
}

.baypo-da-live .baypo-da-price-label {
    visibility: hidden !important;
    min-width: 135px !important;
    text-align: right !important;
    white-space: nowrap !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #000b3f !important;
}

.baypo-da-live .baypo-da-price-label.is-visible {
    visibility: visible !important;
}

.baypo-da-live #baypo-da-live-price {
    font-size: 22px !important;
    font-weight: 700 !important;
    color: #d00000 !important;
    line-height: 1.2 !important;
}

.baypo-da-live #baypo-da-live-regular-price {
    font-size: 14px !important;
    color: #888888 !important;
    text-decoration: line-through !important;
}

/* -----------------------------
   Selected summary
----------------------------- */

.baypo-da-live .baypo-da-summary-wrap {
    text-align: center !important;
    font-size: 12px !important;
    color: #777777 !important;
    line-height: 1.35 !important;
    margin: 0 0 8px 0 !important;
}

/* -----------------------------
   Quantity
----------------------------- */

.baypo-da-live .baypo-da-qty-wrap {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 12px !important;
    margin: 0 0 12px 0 !important;
    direction: rtl !important;
}

.baypo-da-live .baypo-qty-label {
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #000b3f !important;
    line-height: 1 !important;
    white-space: nowrap !important;
}

.baypo-da-live .baypo-qty-control {
    display: inline-grid !important;
    grid-template-columns: 40px 56px 40px !important;
    align-items: center !important;
    height: 40px !important;
    gap: 0 !important;
    border: 1px solid #cfd3dc !important;
    border-radius: 4px !important;
    overflow: hidden !important;
    background: #ffffff !important;
    direction: ltr !important;
}

.baypo-da-live .baypo-da-qty-btn {
    width: 40px !important;
    height: 40px !important;
    min-width: 40px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #f7f8fb !important;
    color: #000b3f !important;
    font-size: 17px !important;
    font-weight: 600 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: pointer !important;
    box-shadow: none !important;
    transition: background-color 0.16s ease, color 0.16s ease !important;
}

.baypo-da-live .baypo-da-qty-btn:hover,
.baypo-da-live .baypo-da-qty-btn:focus {
    background: #000b3f !important;
    color: #ffffff !important;
}

.baypo-da-live .baypo-da-qty-input {
    width: 56px !important;
    height: 40px !important;
    min-width: 56px !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 0 !important;
    border-left: 1px solid #cfd3dc !important;
    border-right: 1px solid #cfd3dc !important;
    border-radius: 0 !important;
    background: #ffffff !important;
    color: #000b3f !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    text-align: center !important;
    line-height: 40px !important;
    box-shadow: none !important;
    outline: none !important;
    appearance: textfield !important;
    -moz-appearance: textfield !important;
}

.baypo-da-live .baypo-da-qty-input::-webkit-outer-spin-button,
.baypo-da-live .baypo-da-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none !important;
    margin: 0 !important;
}

/* -----------------------------
   Main action buttons
----------------------------- */

.baypo-da-live .baypo-da-actions {
    display: flex !important;
    justify-content: center !important;
    align-items: stretch !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    margin: 0 0 16px 0 !important;
    padding: 0 0 14px 0 !important;
    border-bottom: 1px solid #eef0f4 !important;
}

.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now,
.baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
.baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
    width: 220px !important;
    min-width: 220px !important;
    max-width: 220px !important;
    height: 46px !important;
    min-height: 46px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 8px 12px !important;
    margin: 0 !important;
    border: 1px solid #ffc400 !important;
    border-radius: 4px !important;
    background: #ffc400 !important;
    color: #000b3f !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    text-align: center !important;
    transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease !important;
}

.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart:hover,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now:hover,
.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart:focus,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now:focus,
.baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn:hover,
.baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn:hover,
.baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn:focus,
.baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn:focus {
    background: #000b3f !important;
    border-color: #000b3f !important;
    color: #ffffff !important;
    transform: translateY(-1px) !important;
}

.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart:disabled,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now:disabled {
    opacity: 0.65 !important;
    cursor: not-allowed !important;
    transform: none !important;
}

/* -----------------------------
   Groups
----------------------------- */

.baypo-da-live .baypo-da-group {
    margin: 0 0 14px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
}

.baypo-da-live .product-custom-options .option-label {
    display: block !important;
    margin: 0 0 7px 0 !important;
    padding: 0 !important;
    border: 0 !important;
    text-align: right !important;
    direction: rtl !important;
    color: #000b3f !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.35 !important;
}

.baypo-da-live .product-custom-options .option-label strong {
    display: block !important;
    text-align: right !important;
    color: inherit !important;
    font-size: inherit !important;
    font-weight: inherit !important;
    line-height: inherit !important;
}

/* -----------------------------
   Add-on buttons desktop
----------------------------- */

@media (min-width: 769px) {
    .baypo-da-live .baypo-da-options {
        display: grid !important;
        grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
        gap: 7px !important;
        width: 100% !important;
        align-items: stretch !important;
    }

    .baypo-da-live .baypo-da-selection-button {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        min-height: 36px !important;
        height: auto !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 5px 8px !important;
        margin: 0 !important;
        background: #fbfafc !important;
        border: 1px solid #d8dbe2 !important;
        border-radius: 4px !important;
        color: #111827 !important;
        text-align: center !important;
        cursor: pointer !important;
        box-shadow: none !important;
        transition: border-color 0.15s ease, background-color 0.15s ease, box-shadow 0.15s ease, transform 0.15s ease !important;
    }

    .baypo-da-live .baypo-da-selection-button:hover {
        background: #ffffff !important;
        border-color: #9fb7d3 !important;
        box-shadow: 0 2px 6px rgba(0,0,0,0.045) !important;
        transform: translateY(-1px) !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-label {
        display: block !important;
        width: 100% !important;
        font-size: 11.5px !important;
        font-weight: 500 !important;
        line-height: 1.15 !important;
        text-align: center !important;
        white-space: normal !important;
        overflow-wrap: normal !important;
        word-break: normal !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-price {
        display: block !important;
        margin-top: 1px !important;
        color: #666666 !important;
        font-size: 9.5px !important;
        font-weight: 500 !important;
        line-height: 1.1 !important;
        text-align: center !important;
        white-space: nowrap !important;
        direction: ltr !important;
    }

    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        min-height: 36px !important;
        background: #ffffff !important;
        border: 2px solid #0073aa !important;
        box-shadow: 0 0 0 1px rgba(0,115,170,0.08) !important;
        color: #000b3f !important;
        transform: none !important;
    }

    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-label {
        color: #000b3f !important;
        font-weight: 700 !important;
    }

    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-price {
        color: #0073aa !important;
        font-weight: 600 !important;
    }
}

/* -----------------------------
   Add-on buttons mobile
----------------------------- */

@media (max-width: 768px) {
    .baypo-da-live {
        padding: 12px !important;
    }

    .baypo-da-live .baypo-da-options {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 7px !important;
        width: 100% !important;
    }

    .baypo-da-live .baypo-da-selection-button {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        min-height: 40px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;
        padding: 7px 10px !important;
        margin: 0 !important;
        border-radius: 4px !important;
        text-align: right !important;
        line-height: 1.2 !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-label {
        flex: 1 1 auto !important;
        font-size: 12.5px !important;
        font-weight: 600 !important;
        line-height: 1.2 !important;
        text-align: right !important;
        white-space: normal !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-price {
        flex: 0 0 auto !important;
        margin-top: 0 !important;
        font-size: 10.5px !important;
        font-weight: 500 !important;
        white-space: nowrap !important;
        direction: ltr !important;
        text-align: left !important;
    }

    .baypo-da-live .baypo-da-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 8px !important;
    }

    .baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
    .baypo-da-live .baypo-da-actions #baypo-da-buy-now,
    .baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
    .baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: 44px !important;
        min-height: 44px !important;
    }

    .baypo-da-live .baypo-da-qty-wrap {
        justify-content: space-between !important;
    }
}

/* -----------------------------
   Images
----------------------------- */

@media (min-width: 1025px) {
    .baypo-da-live #baypo-da-live-image-preview {
        position: fixed !important;
        top: 0;
        left: 0;

        width: 240px !important;
        max-width: 240px !important;

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

        background: #ffffff !important;
        border: 0 !important;
        border-radius: 14px !important;
        box-shadow: 0 10px 30px rgba(0,0,0,0.16) !important;
        z-index: 99999 !important;

        text-align: center !important;
        pointer-events: none !important;

        opacity: 0;
        visibility: hidden;
        transform: translateY(6px);
        transition:
            opacity 0.14s ease,
            transform 0.14s ease,
            visibility 0.14s ease;
    }

    .baypo-da-live #baypo-da-live-image-preview.is-visible {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .baypo-da-live #baypo-da-live-image-preview img {
        display: block !important;
        width: 100% !important;
        max-width: 100% !important;
        max-height: 220px !important;
        height: auto !important;
        object-fit: contain !important;

        border: 0 !important;
        padding: 0 !important;
        background: transparent !important;
        border-radius: 10px !important;
    }

    .baypo-da-live #baypo-da-live-image-preview .baypo-da-live-image-caption {
        margin-top: 7px !important;
        font-size: 12px !important;
        line-height: 1.35 !important;
        text-align: center !important;
        color: #000b3f !important;
    }

    .baypo-da-live .baypo-da-group-image-preview {
        display: none !important;
    }
}


@media (max-width: 1024px) {
    .baypo-da-live #baypo-da-live-image-preview {
        display: none !important;
    }

    .baypo-da-live .baypo-da-group-image-preview {
        margin-top: 8px !important;
        margin-bottom: 8px !important;
        text-align: center !important;
    }

    .baypo-da-live .baypo-da-group-image-preview img {
        max-width: 240px !important;
        width: auto !important;
        height: auto !important;
        border: 0 !important;
        padding: 0 !important;
        background: transparent !important;
        border-radius: 10px !important;
        box-shadow: 0 6px 18px rgba(0,0,0,0.10) !important;
    }
}

/*
 * =========================================================
 * Final UX correction:
 * Desktop group rows instead of table-like stacked rows.
 * Group title on the right, options on the left.
 * =========================================================
 */

@media (min-width: 769px) {

    .baypo-da-live {
        padding: 12px 14px !important;
    }

    /*
     * Each group becomes one horizontal row:
     * [ title ] [ options ]
     */
    .baypo-da-live .baypo-da-group {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 12px !important;

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

        border-top: 1px solid #f1f2f5 !important;
    }

    .baypo-da-live .baypo-da-group:first-of-type {
        border-top: 0 !important;
    }

    /*
     * Group title: right side, compact, no table-header feeling.
     */
    .baypo-da-live .product-custom-options .option-label {
        flex: 0 0 170px !important;
        width: 170px !important;
        max-width: 170px !important;

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

        display: block !important;

        text-align: right !important;
        direction: rtl !important;

        border: 0 !important;

        font-size: 13px !important;
        font-weight: 700 !important;
        line-height: 1.35 !important;
        color: #000b3f !important;
    }

    .baypo-da-live .product-custom-options .option-label strong {
        display: block !important;
        text-align: right !important;
        font-size: inherit !important;
        font-weight: inherit !important;
        line-height: inherit !important;
        color: inherit !important;
    }

    /*
     * Options use all remaining width.
     */
    .baypo-da-live .baypo-da-options {
        flex: 1 1 auto !important;
        min-width: 0 !important;

        display: grid !important;
        grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)) !important;
        gap: 7px !important;

        width: auto !important;
        align-items: stretch !important;
    }

    /*
     * Option buttons: lower, smoother, less table-like.
     */
    .baypo-da-live .baypo-da-selection-button {
        min-height: 34px !important;
        padding: 5px 8px !important;

        background: #fbfbfd !important;
        border: 1px solid #d9dde6 !important;
        border-radius: 5px !important;

        box-shadow: none !important;
    }

    .baypo-da-live .baypo-da-selection-button:hover {
        background: #ffffff !important;
        border-color: #8fb3cc !important;
        box-shadow: 0 2px 5px rgba(0,0,0,0.045) !important;
        transform: translateY(-1px) !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-label {
        font-size: 11.5px !important;
        font-weight: 500 !important;
        line-height: 1.15 !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-price {
        margin-top: 1px !important;
        font-size: 9.5px !important;
        line-height: 1.1 !important;
        color: #666 !important;
    }

    /*
     * Selected option: clear but not too heavy.
     */
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        min-height: 34px !important;
        border: 2px solid #0073aa !important;
        background: #ffffff !important;
        box-shadow: 0 0 0 1px rgba(0,115,170,0.08) !important;
        transform: none !important;
    }

    /*
     * Group image preview is mobile only, keep it out of desktop row layout.
     */
    .baypo-da-live .baypo-da-group-image-preview {
        display: none !important;
    }
}

/*
 * Wider desktop: allow more compact columns.
 */
@media (min-width: 1300px) {
    .baypo-da-live .product-custom-options .option-label {
        flex-basis: 180px !important;
        width: 180px !important;
        max-width: 180px !important;
    }

    .baypo-da-live .baypo-da-options {
        grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)) !important;
    }
}

/*
 * Mobile: keep stacked full-width behavior.
 */
@media (max-width: 768px) {
    .baypo-da-live .baypo-da-group {
        display: block !important;
        padding: 0 !important;
        margin-bottom: 12px !important;
        border-top: 0 !important;
    }

    .baypo-da-live .product-custom-options .option-label {
        width: auto !important;
        max-width: none !important;
        margin-bottom: 7px !important;
        text-align: right !important;
    }
}


/*
 * =========================================================
 * Final pro action block alignment
 * RTL product page: price / qty / action buttons aligned to the right.
 * Keeps add-on group-title-on-same-line layout unchanged.
 * =========================================================
 */

@media (min-width: 769px) {

    /*
     * Price should feel anchored to the product form, not floating center.
     */
    .baypo-da-live .baypo-da-price-wrap {
        justify-content: flex-end !important;
        text-align: right !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        margin-bottom: 8px !important;
    }

    .baypo-da-live .baypo-da-price-label {
        min-width: auto !important;
        margin-left: 6px !important;
        font-size: 13px !important;
        font-weight: 600 !important;
    }

    .baypo-da-live #baypo-da-live-price {
        font-size: 26px !important;
        font-weight: 800 !important;
        line-height: 1.15 !important;
        letter-spacing: -0.2px !important;
    }

    .baypo-da-live #baypo-da-live-regular-price {
        font-size: 15px !important;
        margin-right: 8px !important;
    }

    /*
     * Selected summary should also align right.
     */
    .baypo-da-live .baypo-da-summary-wrap {
        text-align: right !important;
        font-size: 12px !important;
        margin-bottom: 10px !important;
    }

    /*
     * Qty row: align to right and keep compact.
     */
    .baypo-da-live .baypo-da-qty-wrap {
        justify-content: flex-end !important;
        width: 100% !important;
        margin-bottom: 12px !important;
    }

    /*
     * Buttons: align right, same row, clean spacing.
     */
    .baypo-da-live .baypo-da-actions {
        justify-content: flex-end !important;
        align-items: stretch !important;
        gap: 10px !important;
        width: 100% !important;
        margin-bottom: 14px !important;
        padding-bottom: 14px !important;
    }

    .baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
    .baypo-da-live .baypo-da-actions #baypo-da-buy-now,
    .baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
    .baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
        width: 220px !important;
        min-width: 220px !important;
        max-width: 220px !important;
        height: 46px !important;
        min-height: 46px !important;
    }

    /*
     * Give the upper action block a calmer separation from add-ons.
     */
    .baypo-da-live .baypo-da-actions + .baypo-da-add-to-cart-result,
    .baypo-da-live .baypo-da-add-to-cart-result {
        text-align: right !important;
    }
}

/*
 * Mobile: keep centered/comfortable enough, but price can still be stronger.
 */
@media (max-width: 768px) {
    .baypo-da-live #baypo-da-live-price {
        font-size: 24px !important;
        font-weight: 800 !important;
    }

    .baypo-da-live .baypo-da-price-wrap {
        justify-content: center !important;
    }

    .baypo-da-live .baypo-da-actions {
        justify-content: center !important;
    }
}


/*
 * Final fix: force price / qty / action buttons to the RIGHT side
 * inside the RTL product configurator box.
 */
@media (min-width: 769px) {

    .baypo-da-live .baypo-da-price-wrap,
    .baypo-da-live .baypo-da-summary-wrap,
    .baypo-da-live .baypo-da-qty-wrap,
    .baypo-da-live .baypo-da-actions {
        width: 100% !important;
        max-width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        direction: rtl !important;
    }

    .baypo-da-live .baypo-da-price-wrap {
        display: flex !important;
        justify-content: flex-start !important;
        text-align: right !important;
    }

    .baypo-da-live .baypo-da-summary-wrap {
        text-align: right !important;
    }

    .baypo-da-live .baypo-da-qty-wrap {
        display: flex !important;
        justify-content: flex-start !important;
        text-align: right !important;
    }

    .baypo-da-live .baypo-da-actions {
        display: flex !important;
        justify-content: flex-start !important;
        align-items: stretch !important;
        text-align: right !important;
    }

    /*
     * Keep button order visually natural in RTL:
     * right button first, then second button to its left.
     */
    .baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart {
        order: 1 !important;
    }

    .baypo-da-live .baypo-da-actions #baypo-da-buy-now {
        order: 2 !important;
    }
}


/*
 * Reliable selected visual state.
 * JS adds .is-selected to the label, so mobile gets clear feedback.
 */
.baypo-da-live .baypo-da-selection-button.is-selected {
    background: #ffffff !important;
    border: 2px solid #0073aa !important;
    color: #000b3f !important;
    box-shadow: 0 0 0 1px rgba(0,115,170,0.12) !important;
}

.baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-label {
    font-weight: 700 !important;
    color: #000b3f !important;
}

.baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-price {
    font-weight: 600 !important;
    color: #0073aa !important;
}

/*
 * Mobile selected state should be obvious but not too heavy.
 */
@media (max-width: 768px) {
    .baypo-da-live .baypo-da-selection-button.is-selected {
        border: 2px solid #0073aa !important;
        background: #ffffff !important;
        box-shadow: inset 4px 0 0 #0073aa !important;
    }
}


/*
 * =========================================================
 * Strong selected indication for add-on cards
 * Especially important on mobile where hover does not exist.
 * JS adds .is-selected to the selected label.
 * =========================================================
 */

/* Desktop + general selected state */
.baypo-da-live .baypo-da-selection-button.is-selected,
.baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
    background: #ffffff !important;
    border: 2px solid #0073aa !important;
    color: #000b3f !important;
    box-shadow: 0 0 0 1px rgba(0,115,170,0.14) !important;
}

.baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-label,
.baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-label {
    font-weight: 800 !important;
    color: #000b3f !important;
}

.baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-price,
.baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-price {
    font-weight: 700 !important;
    color: #0073aa !important;
}

/* Mobile: make selected card very obvious */
@media (max-width: 768px) {
    .baypo-da-live .baypo-da-selection-button {
        position: relative !important;
        transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease !important;
        -webkit-tap-highlight-color: rgba(0,115,170,0.12) !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        background: #f3fbff !important;
        border: 2px solid #0073aa !important;
        box-shadow: inset -5px 0 0 #0073aa, 0 1px 4px rgba(0,0,0,0.06) !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected::after,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button::after {
        content: "✓" !important;
        position: absolute !important;
        top: 50% !important;
        left: 10px !important;
        transform: translateY(-50%) !important;

        width: 22px !important;
        height: 22px !important;

        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;

        border-radius: 50% !important;
        background: #0073aa !important;
        color: #ffffff !important;

        font-size: 13px !important;
        font-weight: 800 !important;
        line-height: 1 !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-label,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-label {
        color: #000b3f !important;
        font-weight: 800 !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-price,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-price {
        color: #0073aa !important;
        font-weight: 800 !important;
    }
}


/*
 * Final mobile selected-state cleanup:
 * Professional selected card without V/check mark and without heavy blue strip.
 * Selection is shown by border, soft background and stronger text.
 */

/* Remove the mobile checkmark completely */
@media (max-width: 768px) {
    .baypo-da-live .baypo-da-selection-button.is-selected::after,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button::after {
        content: none !important;
        display: none !important;
    }

    /*
     * Remove heavy blue side strip.
     * Keep selected state clear but clean.
     */
    .baypo-da-live .baypo-da-selection-button.is-selected,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        background: #f4fbff !important;
        border: 2px solid #0073aa !important;
        box-shadow: 0 1px 5px rgba(0, 115, 170, 0.16) !important;
        color: #000b3f !important;
    }

    /*
     * Selected text emphasis.
     */
    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-label,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-label {
        color: #000b3f !important;
        font-weight: 800 !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-price,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-price {
        color: #0073aa !important;
        font-weight: 800 !important;
    }

    /*
     * Make touch press feel responsive without changing layout.
     */
    .baypo-da-live .baypo-da-selection-button:active {
        background: #eef8ff !important;
        border-color: #0073aa !important;
        transform: scale(0.995) !important;
    }
}

@media (min-width: 1025px) {
  .baypo-da-live #baypo-da-live-image-preview {
    position: fixed !important;
    top: 0;
    left: 0;

    width: 300px;
    max-width: 300px;
    margin-top: 0 !important;
    text-align: center;

    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 14px;
    padding: 8px;

    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.22);
    z-index: 99999;

    pointer-events: none;

    opacity: 0;
    visibility: hidden;
    transform: translateY(6px);
    transition:
      opacity 0.14s ease,
      transform 0.14s ease,
      visibility 0.14s ease;
  }

  .baypo-da-live #baypo-da-live-image-preview.is-visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .baypo-da-live #baypo-da-live-image-preview img {
    display: block;
    width: 100%;
    height: auto;
    max-height: 260px;
    object-fit: contain;
    border: 0 !important;
    background: transparent !important;
    padding: 0 !important;
    border-radius: 10px;
  }

  .baypo-da-live #baypo-da-live-image-preview .baypo-da-live-image-caption {
    margin-top: 7px;
    font-size: 13px;
    line-height: 1.35;
    text-align: center;
    color: #222;
  }
}

@media (max-width: 1024px) {
  .baypo-da-live #baypo-da-live-image-preview {
    position: static;
  }
}

/*
 * =========================================================
 * BAYPO FINAL PURCHASE BOX CLEANUP
 * Source of truth for add-on / purchase layout.
 * Trust strip itself is injected/styled from WPCodeBox.
 * =========================================================
 */

.baypo-da-live {
    direction: rtl !important;
    display: flex !important;
    flex-direction: column !important;

    background: #ffffff !important;
    border: 1px solid #dbe3ef !important;
    border-radius: 14px !important;

    padding: 12px 16px 14px !important;
    margin: 16px 0 !important;

    box-shadow: 0 8px 24px rgba(5, 10, 48, 0.07) !important;
    color: #000b3f !important;
    gap: 0 !important;
}

/* Correct order inside the configurator */
.baypo-da-live .baypo-da-price-wrap {
    order: 1 !important;
}

.baypo-da-live .baypo-da-summary-wrap {
    order: 2 !important;
}

.baypo-da-live .baypo-da-qty-wrap {
    order: 3 !important;
}

.baypo-da-live .baypo-da-actions {
    order: 4 !important;
}

.baypo-da-live .baypo-product-trust-box {
    order: 5 !important;
}

.baypo-da-live .baypo-da-add-to-cart-result {
    order: 6 !important;
}

.baypo-da-live .baypo-da-group {
    order: 10 !important;
}

/* Price area */
.baypo-da-live .baypo-da-price-wrap {
    width: 100% !important;

    display: flex !important;
    justify-content: flex-start !important;
    align-items: baseline !important;
    flex-wrap: wrap !important;
    gap: 8px !important;

    text-align: right !important;
    direction: rtl !important;

    min-height: 0 !important;
    padding: 6px 0 8px !important;
    margin: 0 0 8px 0 !important;

    border-top: 0 !important;
    border-bottom: 1px solid #eef2f7 !important;
}

.baypo-da-live .baypo-da-price-label {
    font-size: 12px !important;
    font-weight: 500 !important;
    color: #9aa3b2 !important;
    min-width: auto !important;
    visibility: visible !important;
}

.baypo-da-live #baypo-da-live-price {
    font-size: 28px !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    color: #d00000 !important;
    letter-spacing: -0.2px !important;
}

.baypo-da-live #baypo-da-live-regular-price {
    font-size: 14px !important;
    color: #8a8f98 !important;
    text-decoration: line-through !important;
}

/* Selected summary: keep small, no empty space */
.baypo-da-live .baypo-da-summary-wrap {
    width: 100% !important;
    min-height: 0 !important;

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

    text-align: right !important;
    font-size: 11px !important;
    line-height: 1.25 !important;
    color: #9aa3b2 !important;
}

/* Quantity */
.baypo-da-live .baypo-da-qty-wrap {
    width: 100% !important;

    display: flex !important;
    justify-content: flex-start !important;
    align-items: center !important;
    gap: 10px !important;

    margin: 4px 0 10px 0 !important;
    padding: 0 !important;

    direction: rtl !important;
    text-align: right !important;
}

.baypo-da-live .baypo-qty-label {
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #000b3f !important;
    white-space: nowrap !important;
}

.baypo-da-live .baypo-qty-control {
    display: inline-grid !important;
    grid-template-columns: 36px 48px 36px !important;
    height: 36px !important;

    border: 1px solid #dbe3ef !important;
    border-radius: 9px !important;
    overflow: hidden !important;

    background: #ffffff !important;
    direction: ltr !important;
}

.baypo-da-live .baypo-da-qty-btn {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;

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

    background: #f6f8fb !important;
    color: #000b3f !important;

    font-size: 16px !important;
    font-weight: 700 !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    cursor: pointer !important;
    box-shadow: none !important;
}

.baypo-da-live .baypo-da-qty-btn:hover,
.baypo-da-live .baypo-da-qty-btn:focus {
    background: #eef2f7 !important;
    color: #000b3f !important;
}

.baypo-da-live .baypo-da-qty-input {
    width: 48px !important;
    height: 36px !important;
    min-width: 48px !important;

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

    border: 0 !important;
    border-left: 1px solid #dbe3ef !important;
    border-right: 1px solid #dbe3ef !important;
    border-radius: 0 !important;

    background: #ffffff !important;
    color: #000b3f !important;

    font-size: 14px !important;
    font-weight: 700 !important;
    line-height: 36px !important;
    text-align: center !important;

    box-shadow: none !important;
    outline: none !important;
}

/* Buttons */
.baypo-da-live .baypo-da-actions {
    width: 100% !important;

    display: flex !important;
    justify-content: flex-start !important;
    align-items: stretch !important;
    flex-wrap: wrap !important;
    gap: 10px !important;

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

    border-bottom: 0 !important;
    text-align: right !important;
}

.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now,
.baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
.baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
    width: 220px !important;
    min-width: 220px !important;
    max-width: 220px !important;

    height: 46px !important;
    min-height: 46px !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    padding: 8px 12px !important;
    margin: 0 !important;

    border: 1px solid #ffc400 !important;
    border-radius: 8px !important;

    background: #ffc400 !important;
    color: #000b3f !important;

    font-size: 14px !important;
    font-weight: 800 !important;
    line-height: 1.2 !important;
    text-align: center !important;

    cursor: pointer !important;
    box-shadow: none !important;

    transition: filter 0.15s ease, transform 0.15s ease !important;
}

.baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart:hover,
.baypo-da-live .baypo-da-actions #baypo-da-buy-now:hover,
.baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn:hover,
.baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn:hover {
    background: #ffc400 !important;
    border-color: #ffc400 !important;
    color: #000b3f !important;
    filter: brightness(0.96) !important;
    transform: translateY(-1px) !important;
}

/* Add-on rows */
@media (min-width: 769px) {
    .baypo-da-live .baypo-da-group {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-start !important;
        gap: 12px !important;

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

        border-top: 1px solid #f1f2f5 !important;
        background: transparent !important;
    }

    .baypo-da-live .baypo-da-group:first-of-type {
        border-top: 0 !important;
        padding-top: 6px !important;
    }

    .baypo-da-live .product-custom-options .option-label {
        flex: 0 0 170px !important;
        width: 170px !important;
        max-width: 170px !important;

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

        text-align: right !important;
        direction: rtl !important;

        font-size: 13px !important;
        font-weight: 700 !important;
        line-height: 1.35 !important;
        color: #000b3f !important;
    }

    .baypo-da-live .baypo-da-options {
        flex: 1 1 auto !important;
        min-width: 0 !important;

        display: grid !important;
        grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)) !important;
        gap: 7px !important;

        width: auto !important;
        align-items: stretch !important;
    }

    .baypo-da-live .baypo-da-selection-button {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;

        min-height: 34px !important;
        height: auto !important;

        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;

        padding: 5px 8px !important;
        margin: 0 !important;

        background: #fbfbfd !important;
        border: 1px solid #d9dde6 !important;
        border-radius: 5px !important;

        color: #111827 !important;
        text-align: center !important;
        cursor: pointer !important;

        box-shadow: none !important;
    }

    .baypo-da-live .baypo-da-selection-button:hover {
        background: #ffffff !important;
        border-color: #8fb3cc !important;
        box-shadow: 0 2px 5px rgba(0,0,0,0.045) !important;
        transform: translateY(-1px) !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-label {
        display: block !important;
        width: 100% !important;

        font-size: 11.5px !important;
        font-weight: 500 !important;
        line-height: 1.15 !important;

        text-align: center !important;
        white-space: normal !important;
    }

    .baypo-da-live .baypo-da-selection-button .baypo-da-button-price {
        display: block !important;
        margin-top: 1px !important;

        color: #666666 !important;
        font-size: 9.5px !important;
        font-weight: 500 !important;
        line-height: 1.1 !important;

        text-align: center !important;
        white-space: nowrap !important;
        direction: ltr !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        background: #ffffff !important;
        border: 2px solid #0073aa !important;
        color: #000b3f !important;
        box-shadow: 0 0 0 1px rgba(0,115,170,0.12) !important;
        transform: none !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-label,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-label {
        font-weight: 800 !important;
        color: #000b3f !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected .baypo-da-button-price,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button .baypo-da-button-price {
        font-weight: 700 !important;
        color: #0073aa !important;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .baypo-da-live {
        padding: 12px !important;
    }

    .baypo-da-live .baypo-da-price-wrap {
        justify-content: center !important;
        text-align: center !important;
    }

    .baypo-da-live #baypo-da-live-price {
        font-size: 24px !important;
    }

    .baypo-da-live .baypo-da-qty-wrap {
        justify-content: center !important;
    }

    .baypo-da-live .baypo-da-actions {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 8px !important;
    }

    .baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
    .baypo-da-live .baypo-da-actions #baypo-da-buy-now,
    .baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
    .baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;
        height: 44px !important;
        min-height: 44px !important;
        border-radius: 8px !important;
    }

    .baypo-da-live .baypo-da-group {
        display: block !important;
        padding: 0 !important;
        margin-bottom: 12px !important;
        border-top: 0 !important;
    }

    .baypo-da-live .product-custom-options .option-label {
        width: auto !important;
        max-width: none !important;
        margin-bottom: 7px !important;
        text-align: right !important;
    }

    .baypo-da-live .baypo-da-options {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 7px !important;
        width: 100% !important;
    }

    .baypo-da-live .baypo-da-selection-button {
        width: 100% !important;
        min-width: 0 !important;
        max-width: none !important;

        min-height: 40px !important;

        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        gap: 10px !important;

        padding: 7px 10px !important;
        margin: 0 !important;

        border-radius: 6px !important;
        text-align: right !important;
        line-height: 1.2 !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button {
        background: #f4fbff !important;
        border: 2px solid #0073aa !important;
        box-shadow: 0 1px 5px rgba(0, 115, 170, 0.16) !important;
        color: #000b3f !important;
    }

    .baypo-da-live .baypo-da-selection-button.is-selected::after,
    .baypo-da-live .baypo-da-addon-input:checked + .baypo-da-selection-button::after {
        content: none !important;
        display: none !important;
    }
}




/*
 * =========================================================
 * BAYPO FINAL CENTER PURCHASE ACTION AREA
 * Keep configurator rows as-is, but center price / qty / buttons.
 * =========================================================
 */

@media (min-width: 769px) {

    .baypo-da-live .baypo-da-price-wrap {
        justify-content: center !important;
        text-align: center !important;
    }

    .baypo-da-live .baypo-da-summary-wrap {
        text-align: center !important;
    }

    .baypo-da-live .baypo-da-qty-wrap {
        justify-content: center !important;
        text-align: center !important;
    }

    .baypo-da-live .baypo-da-actions {
        justify-content: center !important;
        text-align: center !important;
    }

    .baypo-da-live .baypo-da-actions #baypo-da-test-add-to-cart,
    .baypo-da-live .baypo-da-actions #baypo-da-buy-now,
    .baypo-da-live .baypo-da-actions .baypo-da-add-to-cart-btn,
    .baypo-da-live .baypo-da-actions .baypo-da-buy-now-btn {
        width: 220px !important;
        min-width: 220px !important;
        max-width: 220px !important;
    }
}

