/*
 * BundlePress Frontend CSS
 * 
 * WooCommerce applies `.woocommerce div.product div.summary p { margin: 1em 0; }`
 * which overrides Chakra UI's inline margin:0 because of selector specificity.
 * The rules below neutralise all WooCommerce / theme margin resets on <p> tags
 * (and other inline elements) inside every BundlePress root element,
 * letting Chakra UI's own styles take full control again.
 */

/* --------------------------------------------------------------------------
   1. Single-product page – bundle display root (bundlepress product type)
   -------------------------------------------------------------------------- */
#bundlepress-bundle-root p,
#bundlepress-bundle-root span,
#bundlepress-bundle-root h1,
#bundlepress-bundle-root h2,
#bundlepress-bundle-root h3,
#bundlepress-bundle-root h4,
#bundlepress-bundle-root h5,
#bundlepress-bundle-root h6,
#bundlepress-bundle-root ul,
#bundlepress-bundle-root ol,
#bundlepress-bundle-root li {
    margin: 0;
    padding: 0;
}

/* --------------------------------------------------------------------------
   2. Upsell widget roots (single-product page & cart page)
   -------------------------------------------------------------------------- */
.bundlepress-upsell-root p,
.bundlepress-upsell-root span,
.bundlepress-upsell-root h1,
.bundlepress-upsell-root h2,
.bundlepress-upsell-root h3,
.bundlepress-upsell-root h4,
.bundlepress-upsell-root h5,
.bundlepress-upsell-root h6,
.bundlepress-upsell-root ul,
.bundlepress-upsell-root ol,
.bundlepress-upsell-root li {
    margin: 0;
    padding: 0;
}

/* --------------------------------------------------------------------------
   3. General bundle display class used by BundleFrontend component
   -------------------------------------------------------------------------- */
.bundlepress-bundle-display p,
.bundlepress-bundle-display span,
.bundlepress-bundle-display h1,
.bundlepress-bundle-display h2,
.bundlepress-bundle-display h3,
.bundlepress-bundle-display h4,
.bundlepress-bundle-display h5,
.bundlepress-bundle-display h6,
.bundlepress-bundle-display ul,
.bundlepress-bundle-display ol,
.bundlepress-bundle-display li {
    margin: 0;
    padding: 0;
}

/* --------------------------------------------------------------------------
   4. Extra specificity override targeting the exact WooCommerce selector
   so that even deeply-nested <p> elements get the reset.
   -------------------------------------------------------------------------- */
.woocommerce div.product div.summary #bundlepress-bundle-root p,
.woocommerce div.product div.summary .bundlepress-upsell-root p,
.woocommerce div.product div.summary .bundlepress-bundle-display p,
.woocommerce #bundlepress-bundle-root p,
.woocommerce .bundlepress-upsell-root p,
.woocommerce .bundlepress-bundle-display p {
    margin: 0 !important;
}

/* --------------------------------------------------------------------------
   5. Cart page – WooCommerce cart rows that may wrap our upsell widget
   -------------------------------------------------------------------------- */
.woocommerce-cart .bundlepress-upsell-root p,
.woocommerce-cart .bundlepress-upsell-root span {
    margin: 0 !important;
}
