.es-bis[hidden] {
    display: none !important;
}


/*
 * Keep the BIS UI minimal and aligned with the Add to Cart area.
 * The wrapper can be a <form> (simple OOS) or a <div> (variable OOS).
 */
.es-bis {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 10px;
    margin: 0;
    padding: 0;
}

.es-bis__title {
    flex: 0 0 100%;
    width: 100%;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    direction: rtl;
    text-align: right;
    transform: translateY(-2px);
}

.es-bis__field-row {
    flex: 0 0 100%;
    width: 100%;
    margin: 0;
}

.es-bis-cart {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 40px;
    column-gap: 10px;
    row-gap: 10px;
    align-items: start;
}

.es-bis-cart > .es-bis__title,
.es-bis-cart > .es-bis__variation-field,
.es-bis-cart > .es-bis__consent,
.es-bis-cart > .es-bis__message,
.es-bis-cart > .es-bis__ts,
.es-bis-cart > .es-bis__hp,
.es-bis-cart > .es-bis__product-id,
.es-bis-cart > .es-bis__variation-id {
    grid-column: 1 / -1;
}

.es-bis__variation-field {
    display: grid;
    gap: 6px;
    width: 100%;
    direction: rtl;
    text-align: right;
}

.es-bis__variation-label {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
}

.es-bis__exact-variation {
    width: 100%;
    min-height: 40px;
}

.es-bis-cart > .es-bis__field-row {
    grid-column: 1;
    width: auto;
}

.es-bis-cart > .tinv-wraper.woocommerce.tinv-wishlist {
    grid-column: 2;
    align-self: stretch;
    margin: 0;
    position: relative;
}

.es-bis-cart > .tinv-wraper.woocommerce.tinv-wishlist .tinvwl_add_to_wishlist_button,
.es-bis-cart > .tinv-wraper.woocommerce.tinv-wishlist a[class*="add_to_wishlist"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    min-width: 40px;
    min-height: 40px;
    height: 40px;
    margin: 0;
}

.es-bis__submit[disabled],
.es-bis__submit[aria-disabled="true"] {
    opacity: 0.65;
    cursor: not-allowed;
}

.es-bis__consent {
    flex: 0 0 100%;
    display: inline-flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.4;
    margin-top: 2px;
}

.es-bis__consent-checkbox {
    margin-top: 2px;
}

.es-bis__consent-text {
    font-size: 14px;
}

.es-bis__message {
    flex: 0 0 100%;
    margin-top: 4px;
    font-size: 14px;
}

.es-bis__message.is-success {
    color: #14532d;
}

.es-bis__message.is-error {
    color: #7f1d1d;
}

/* Honeypot field (bot friction). */
.es-bis__hp {
    position: absolute !important;
    left: -10000px !important;
    top: auto !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    opacity: 0 !important;
}

@media (max-width: 600px) {
    .es-bis-cart {
        grid-template-columns: minmax(0, 1fr);
    }

    .es-bis-cart > .es-bis__title {
        order: 1;
    }

    .es-bis-cart > .es-bis__variation-field {
        order: 2;
    }

    .es-bis-cart > .es-bis__field-row {
        order: 2;
        grid-column: 1;
        width: 100%;
    }

    .es-bis-cart > .es-bis__consent {
        order: 3;
    }

    .es-bis-cart > .es-bis__message {
        order: 4;
    }

    .es-bis-cart > .tinv-wraper.woocommerce.tinv-wishlist {
        order: 5;
        grid-column: 1;
        justify-self: start;
        align-self: start;
    }
}
