const optionButtons = document.querySelectorAll('.choice-btn');
const continueBtn = document.getElementById('continueBtn');
let selected = false;
/* SELECT OPTIONS */ optionButtons.forEach(button => {
button.addEventListener('click', () => {
optionButtons.forEach(btn => { btn.classList.remove('active'); });
button.classList.add('active');
continueBtn.classList.add('active');
selected = true;
});
});
/* WEBSITE SUBSCRIBE EVENT */ continueBtn.addEventListener('click', function(e){
if(!selected){ e.preventDefault(); return; }
e.preventDefault();
continueBtn.innerHTML = "ANA HAÆŠAWA..."; continueBtn.style.opacity = ".9"; continueBtn.style.pointerEvents = "none";
/* META SUBSCRIBE EVENT */ if(typeof fbq === 'function'){ fbq('track', 'Subscribe'); }
/* REDIRECT DELAY */ setTimeout(() => {
window.location.href = "https://career.ninetechy.com/insurance-jobs-with-visa-sponsorship/";
}, 600);
});