/**
 * Hide AdSense Error Messages
 * Completely hides any ad errors or blocked content messages
 * so users never see distracting error banners
 */

/* Hide AdSense error overlays and blocked content messages */
.adsbygoogle[data-ad-status="unfilled"],
.adsbygoogle[data-adsbygoogle-status="error"],
.adsbygoogle[data-ad-status="error"],
ins.adsbygoogle[data-ad-status] {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    min-height: 0 !important;
    overflow: hidden !important;
}

/* Hide the "Content blocked" message overlay */
.adsbygoogle > div[style*="background"] {
    display: none !important;
}

/* Hide AdSense error iframes */
iframe[id^="aswift"][style*="visibility: hidden"],
iframe[id^="google_ads_iframe"][style*="display: none"] {
    display: none !important;
    height: 0 !important;
    min-height: 0 !important;
}

/* Collapse ad containers that failed to load */
.ad-container:has(.adsbygoogle[data-ad-status="unfilled"]),
.ad-container:has(.adsbygoogle:empty) {
    display: none !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Hide any overlay error messages from Google */
div[style*="background-color"][style*="rgba"] {
    opacity: 0 !important;
    pointer-events: none !important;
}

/* Ensure ad containers collapse gracefully when empty */
.adsbygoogle:empty,
.adsbygoogle:not([data-ad-status="filled"]):empty {
    display: none !important;
    visibility: hidden !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}
