/*! © 2026 Yahoo, Inc. UDS Tailwind and Purger v0.0.0-development */
import { BACKGROUND_BLUR_COLOR_PREFIX, BACKGROUND_BLUR_FALLBACK_COLOR_PREFIX } from "../../css-tokens/dist/index.js";
import plugin from "tailwindcss/plugin.js";

//#region src/tailwind/plugins/blurBgFallback.ts
const blurBgFallbackPlugin = plugin.withOptions(() => ({ addUtilities }) => {
	addUtilities({
		".uds-bgBlurFillFallback": { fill: `var(--${BACKGROUND_BLUR_FALLBACK_COLOR_PREFIX})` },
		"@supports (backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))": {
			".uds-bgBlurFillFallback": { fill: `var(--${BACKGROUND_BLUR_COLOR_PREFIX})` },
			".uds-bgBlurFallback": {
				WebkitBackdropFilter: "var(--uds-backdrop-blur)",
				backdropFilter: "var(--uds-backdrop-blur)"
			}
		},
		"@media (prefers-reduced-transparency)": {
			".uds-bgBlurFillFallback": { fill: `var(--${BACKGROUND_BLUR_FALLBACK_COLOR_PREFIX})` },
			".uds-bgBlurFallback": {
				WebkitBackdropFilter: "none",
				backdropFilter: "none"
			}
		}
	});
}, () => ({ safelist: ["uds-bgBlurFillFallback", "uds-bgBlurFallback"] }));

//#endregion
export { blurBgFallbackPlugin };
//# sourceMappingURL=blurBgFallback.js.map