/* Make sure the gallery slide can be used as positioning parent */
.image_slider__image,
.product_image_slider__thumbs__image,
.woocommerce-product-gallery__wrapper,
.woocommerce-product-gallery__image {
	position: relative;
}

/* Elementor Loop Item image containers */
.e-loop-item .elementor-widget-theme-post-featured-image,
.e-loop-item .elementor-widget-image,
.e-loop-item .elementor-widget-container,
.e-loop-item .elementor-widget-container img,
[data-elementor-type="loop-item"] .elementor-widget-theme-post-featured-image,
[data-elementor-type="loop-item"] .elementor-widget-image,
[data-elementor-type="loop-item"] .elementor-widget-container {
	position: relative !important;
}

/* wrapper positioned inside slides */
.wcib-badges-wrapper {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
	z-index: 9999;
}

/* basic badge style */
.wcib-badge {
	position: absolute;
	max-width: 25%;
	height: auto;
	pointer-events: none;
	display: block;
	margin: 0;
	padding: 0;
}

/* positions - ensure badges stay in corners */
.wcib-pos-top-left { 
	top: 8px !important; 
	left: 8px !important; 
	right: auto !important;
	bottom: auto !important;
	margin: 0 !important;
	padding: 0 !important;
	transform: none !important;
	text-align: left !important;
	float: none !important;
	display: block !important;
}
.wcib-pos-top-right { 
	top: 8px !important; 
	right: 8px !important; 
	left: auto !important;
	bottom: auto !important;
	transform: none !important;
}
.wcib-pos-bottom-left { 
	bottom: 8px !important; 
	left: 8px !important; 
	top: auto !important;
	right: auto !important;
	transform: none !important;
}
.wcib-pos-bottom-right { 
	bottom: 8px !important; 
	right: 8px !important; 
	top: auto !important;
	left: auto !important;
	transform: none !important;
}

/* Fallback wrapper is hidden; JS will show/move it */
.wcib-fallback { display: none !important; }

/* Prevent duplicate badges - hide additional badges if multiple exist */
.wcib-badges-wrapper .wcib-badge ~ .wcib-badge {
	display: none !important;
}

/* Ensure only one badge wrapper per container */
.elementor-widget-container .wcib-badges-wrapper ~ .wcib-badges-wrapper,
.elementor-widget-theme-post-featured-image .wcib-badges-wrapper ~ .wcib-badges-wrapper {
	display: none !important;
}
