/**
 * Designer Pro Compatibility Styles
 */

/* Fix for Designer Pro personalize button */
.wcpu-wcdp-tab-pane .wcdp-designer-button,
.wcpu-wcdp-tab-pane .wcdp-customize-button {
    display: inline-block !important;
    visibility: visible !important;
    opacity: 1 !important;
    position: static !important;
    margin: 10px 0 !important;
    float: none !important;
}

/* Hide the Designer Pro button outside of our tabs */
body.single-product .wcdp-designer-button:not(.wcpu-wcdp-tab-pane .wcdp-designer-button),
body.single-product .wcdp-customize-button:not(.wcpu-wcdp-tab-pane .wcdp-customize-button) {
    display: none !important;
}

/* Position fix for form elements */
form.cart .quantity {
    display: block;
    float: none;
    margin-bottom: 15px;
}

/* Hidden button class */
.wcpu-hidden-button {
    display: none !important;
}

/* Custom class for our form with tabs */
form.wcpu-tabbed-form {
    display: flex;
    flex-direction: column;
}

/* Position tabs properly in the form flow */
form.wcpu-tabbed-form .wcpu-wcdp-tabs-container {
    order: 20;
}

/* Position the add to cart button after tabs */
form.wcpu-tabbed-form .single_add_to_cart_button {
    order: 30;
}

/* Handle empty tab states */
.wcpu-wcdp-tab-pane:empty {
    display: none !important;
}

/* Fix for tab content bottom margin */
.wcpu-wcdp-tab-content {
    margin-bottom: 15px !important;
}

/* Force tab display to correct type */
.wcpu-wcdp-tabs-nav {
    display: flex !important;
}

/* Fix for tabs with float issues */
.wcpu-wcdp-tabs-container:after {
    content: "";
    display: table;
    clear: both;
}
