document.addEventListener("DOMContentLoaded",function(){function d(){const b=document.querySelector(".countdown-section"),e=document.querySelector(".announcement-bar-section"),f=document.querySelector(".section-header");let h=0,c=35,a=0;b&&b.offsetHeight>0&&(h=b.offsetHeight);e&&e.offsetHeight>0&&(c=e.offsetHeight);f&&f.offsetHeight>0&&(a=f.offsetHeight);document.documentElement.style.setProperty("--countdown-height",h+"px");document.documentElement.style.setProperty("--announcement-bar-height",c+ "px");document.documentElement.style.setProperty("--header-height",a+"px");document.documentElement.style.setProperty("--total-header-height",h+c+a+"px");f&&(f.style.cssText=` position: fixed !important; top: ${h+c}px !important; left: 0 !important; right: 0 !important; width: 100% !important; z-index: 998 !important; margin-bottom: 0 !important; `)}setTimeout(d,100);setTimeout(d,500);setTimeout(d,1E3);const g=document.querySelector(".countdown-section");g&&(new MutationObserver(function(){setTimeout(d,50)})).observe(g,{attributes:!0,attributeFilter:["style"]});window.addEventListener("resize",function(){d()});setInterval(d,2E3);initAnnouncementSlider()}); function initAnnouncementSlider(){function d(n){e.forEach((m,p)=>{p===n?m.classList.add("active"):m.classList.remove("active")})}function g(){c=(c+1)%e.length;d(c)}const b=document.querySelector(".announcement-bar-slider");if(b){var e=b.querySelector(".slider").querySelectorAll(".slideshow__slide"),f=b.querySelector(".slider-button--prev"),h=b.querySelector(".slider-button--next");if(!(e.length<=1)){var c=0,a=null,l=b.dataset.autoplay==="true",k=parseInt(b.dataset.speed)||5;d(0);l&&(a=setInterval(g, k*1E3),b.addEventListener("mouseenter",()=>{a&&clearInterval(a)}),b.addEventListener("mouseleave",()=>{a=setInterval(g,k*1E3)}));f&&h&&(f.addEventListener("click",()=>{c=(c-1+e.length)%e.length;d(c);l&&a&&(clearInterval(a),a=setInterval(g,k*1E3))}),h.addEventListener("click",()=>{g();l&&a&&(clearInterval(a),a=setInterval(g,k*1E3))}))}}};