(function($){
function killWhiteBackground(){
// Force body background
document.documentElement.style.background = "linear-gradient(135deg, #f6f1ea, #eaf2f8, #eef3ec)";
document.body.style.background = "linear-gradient(135deg, #f6f1ea, #eaf2f8, #eef3ec)";
// Kill inline backgrounds everywhere Semplice re-applies them
const kill = document.querySelectorAll(
'#content, #content-holder, .semplice-content, .row, .column, .content-block, .project-background'
);
kill.forEach(el => {
el.style.background = "transparent";
});
// Remove injected background layers (this is usually the culprit)
document.querySelectorAll('[class*="background"], [id*="background"]').forEach(el => {
if (el !== document.body && el !== document.documentElement) {
el.style.background = "transparent";
}
});
}
// Run immediately
document.addEventListener("DOMContentLoaded", killWhiteBackground);
// Re-run after Semplice AJAX navigation
$(window).on('sempliceTransitionInDone', killWhiteBackground);
// Hard safety loop (because Semplice re-injects styles late)
setInterval(killWhiteBackground, 500);
})(jQuery);