/* MMX — Hide Titles & White Bars (Everywhere) — v1.0.2 */

/* 1) BLOCKSY + generic page headers */
body:not(.single-product) .ct-page-title,
body:not(.single-product) .ct-page-title .entry-title,
body:not(.single-product) .page-header,
body:not(.single-product) header.page-header,
body:not(.single-product) .entry-header,
body:not(.single-product) .entry-header-wrap,
body:not(.single-product) .hero,
body:not(.single-product) .hero-section,
body:not(.single-product) .ct-hero,
body:not(.single-product) .ct-title,
body:not(.single-product) .ct-header-title,
body:not(.single-product) .wp-block-template-part[aria-label="Page Title"],
body:not(.single-product) .wp-block-cover.is-style-blocksy-hero,
body:not(.single-product) .wp-block-cover.has-global-padding,
/* Woo archives header */
body.archive .woocommerce-products-header,
body.tax-product_cat .woocommerce-products-header,
body.post-type-archive .woocommerce-products-header,
/* Gutenberg "Cover" randomly used as page hero */
body:not(.single-product) .wp-block-cover__inner-container > h1,
body:not(.single-product) .wp-block-cover__background,
/* Possible duplicate "site title" blocks */
body:not(.single-product) .site-title-bar,
body:not(.single-product) .page-title,
body:not(.single-product) .archive-title,
body:not(.single-product) .entry-title.page-title {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
}

/* 2) Remove left-over spacing from themes (Blocksy, Twenty*, etc.) */
.ct-header-sticky-placeholder,
.ct-header-divider,
.has-page-header,
.site-main > .page-header,
.site-main .blocksy-page-title,
.site-content .page-header,
.site-content .page-title-wrap {
    display: none !important; height: 0 !important; margin: 0 !important; padding: 0 !important;
}

/* 3) Normalize top spacing so no white bar remains */
.site-content, .ct-container, .ct-main, .ct-content, .content-area, .site-main {
    padding-top: 0 !important;
    margin-top: 0 !important;
}

/* 4) Keep product titles intact on single product pages */
.single-product .entry-summary .product_title,
.single-product .entry-title,
.single-product .product .summary .product_title {
    display: block !important;
    visibility: visible !important;
    height: auto !important;
}

/* 5) Prevent double spacing under admin bar on mobile */
html[lang] body {
    --mmx-zero: 0 !important;
}
