window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
window.REBELMOUSE_STDLIB.loadExternalScript("https://securepubads.g.doubleclick.net/tag/js/gpt.js", function() {
});
});
window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
(function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start': new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0], j=d.createElement(s),dl=l!='dataLayer'?'&l="+l:"';j.async=true;j.src="https://www.googletagmanager.com/gtm.js?id="+i+dl;f.parentNode.insertBefore(j,f); })(window,document,'script','dataLayer','GTM-TBZ76RQ');
var gotag = document.createElement('iframe'); gotag.src = "https://www.googletagmanager.com/ns.html?id=GTM-TBZ76RQ"; gotag.style.height = 0; gotag.style.width = 0; gotag.style.display = 'none';
document.body.appendChild(gotag); console.log('gtag appended')
});
window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
console.log("script runs"); const subscribeForm = document.getElementById("mc-embedded-subscribe-form");
subscribeForm && subscribeForm.addEventListener("submit", (event) => { const errorTarget = document.getElementsByClassName('mce_inline_error'); const responseTarget = document.getElementsByClassName('response');
if (errorTarget.length > 0) {
console.log("errors test");
for (let i = 0; i < errorTarget.length; i++) {
if(!errorTarget[i].classList.contains('newsletter-element__input')) {
setTimeout(() => {
errorTarget[i].style.display = 'none';
}, 4000);
}
}
}
if (responseTarget) {
setTimeout(() => {
for (let i = 0; i < responseTarget.length; i++) {
responseTarget[i].style.display = 'none';
}
}, 4000);
}
}, false);
});
window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
function mc_resp_0(a){a.style.display='none';a.removeAttribute("class");a.innerHTML='';}
document.querySelectorAll("form#MC").forEach(function(form){form.addEventListener("submit",function(e){e.preventDefault();if(document.querySelector('#MC_robot').value !==''){return false}var script = document.createElement('script');let email=form.querySelector('input#MC_email');script.src=this.action.replace('/post?','/post-json?')+'&EMAIL='+email.value;document.body.appendChild(script);var callback = 'callback';window[callback] = function(data) {delete window[callback];document.body.removeChild(script);
var parts = data.msg.split(' - ', 2);if (parts[1] === undefined) {msg = data.msg;} else {var i = parseInt(parts[0], 10);if (i.toString() === parts[0]) {index = parts[0];msg = parts[1];} else {index = -1;msg = data.msg;}}let resp=form.querySelector('#MC_resp');mc_resp_0(resp);resp.innerHTML=msg;if(data.result=='error'){resp.classList.add('bad');}else{resp.classList.add('good');email.value="";}
resp.style.display='inline-block';setTimeout(function(){mc_resp_0(resp)},3000);
console.log(data);}
})});
});
window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
(function(d,s){var DID="b0bf7582-16c5-4fc1-a03f-8f705ea43617";var js,fjs=d.getElementsByTagName(s)[0];js=d.createElement(s);js.async=1;js.src="https://track.cbdatatracker.com/Home?v=3&id='"+DID+"'";fjs.parentNode.insertBefore(js,fjs);}(document,'script'))
});
window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){
!function(e,t,r,n){if(!e[n]){for(var a=e[n]=[],i=["survey","reset","config","init","set","get","event","identify","track","page","screen","group","alias"],s=0;s
var lastScrollTop = 0;
document.querySelector('.email-wrapper').parentNode.classList.add('sidebar-sticky');
window.addEventListener('scroll',function(){ var st = window.pageYOffset || document.documentElement.scrollTop; if(isInViewport(latestStories, false) && st > lastScrollTop){ console.log('I see it!'); document.querySelector('.email-wrapper').parentNode.classList.add('sidebar-unfixed');
} else if(isInViewport(latestStories, false) && st < lastScrollTop){ document.querySelector('.email-wrapper').parentNode.classList.remove('sidebar-unfixed'); } lastScrollTop = st <= 0 ? 0 : st; }); }); window.REBELMOUSE_ACTIVE_TASKS_QUEUE.push(function(){ window.REBELMOUSE_STDLIB.loadExternalScript("https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js", function() { }); });