'),window.customElements.define("img-comparison-slider",d))})()})();(()=>{const duplicateMarqueeContent=(marqueeRoot)=>{const marqueeContainer=marqueeRoot.firstElementChild;const visibleWidth=marqueeRoot.offsetWidth;const contentWidth=marqueeContainer.offsetWidth;let multiplier=1;marqueeContainer.innerHTML+=marqueeContainer.innerHTML;while(contentWidth*multiplier=32)break}};const marqueeElements=document.querySelectorAll('.marquee-img-root');marqueeElements.forEach(duplicateMarqueeContent)})();class ScrollToTop{constructor(selector='.dugme-yukari'){this.elements=document.querySelectorAll(selector);this.bindEvents()} bindEvents(){this.elements.forEach(element=>{element.addEventListener('click',this.scrollToTop)})} scrollToTop(){window.scrollTo({top:0,behavior:'smooth'})}} document.addEventListener('DOMContentLoaded',()=>{new ScrollToTop()});(function(){const counters=document.querySelectorAll('.counter-item');const speed=500;const isMobile=window.matchMedia("(max-width: 767px)").matches;const animateCounters=(entries)=>{entries.forEach(entry=>{if(entry.isIntersecting){const counter=entry.target;const targetValue=parseInt(counter.dataset.target);const increment=targetValue/speed;const digitSpan=counter.querySelector('.counter-value');const bgColor=counter.dataset.bgColor;const bgPath=counter.dataset.bgPath;const bgImgLg=counter.dataset.bgImgLg;if(bgImgLg&&isMobile===!1){counter.style.backgroundImage='url('+bgPath+bgImgLg+')'} const bgImgSm=counter.dataset.bgImgSm;if(bgImgSm&&isMobile===!0){counter.style.backgroundImage='url('+bgPath+bgImgSm+')'} if(bgColor){counter.style.backgroundColor=bgColor} let currentValue=0;const updateCounter=()=>{currentValue+=increment;digitSpan.textContent=Math.ceil(currentValue);if(currentValue{observer.observe(counter)})})();const DEFAULT_OPTIONS={rootMargin:'0px',threshold:0.1};class ImageLazyLoader{constructor(options={}){this.options={...DEFAULT_OPTIONS,...options};this.images=[];this.observer=null;this.loadedImages=new WeakSet();this.init()} static isIntersectionObserverSupported(){return'IntersectionObserver' in window&&'IntersectionObserverEntry' in window&&'intersectionRatio' in window.IntersectionObserverEntry.prototype} init(){if(ImageLazyLoader.isIntersectionObserverSupported()){this.observer=new IntersectionObserver(this.onIntersection.bind(this),{rootMargin:this.options.rootMargin,threshold:this.options.threshold})} this.loadImages()} loadImages(){this.images=Array.from(document.querySelectorAll('img[data-src]'));if(this.observer){this.images.forEach(img=>{if(!this.loadedImages.has(img)){this.observer.observe(img)}})}else{this.loadAllImages()}} onIntersection(entries){entries.forEach(entry=>{if(entry.isIntersecting){this.loadImage(entry.target);this.observer.unobserve(entry.target)}})} loadImage(img){if(!this.loadedImages.has(img)){const src=img.getAttribute('data-src');if(src){img.src=src;img.removeAttribute('data-src');this.loadedImages.add(img)}}} loadAllImages(){this.images.forEach(img=>this.loadImage(img))}} document.addEventListener('DOMContentLoaded',()=>{new ImageLazyLoader()});(()=>{'use strict';const tooltip=document.createElement('div');tooltip.classList.add('statusbar-tooltip');document.body.appendChild(tooltip);const getFullUrl=(path)=>{try{return new URL(path,window.location.href).href}catch{return window.location.origin+path}};const handleClick=(event,url)=>{if(event.ctrlKey||event.metaKey){window.open(url,'_blank')}else{window.location.href=url} event.preventDefault()};const handleMouseUp=(event,url)=>{if(event.button===1){window.open(url,'_blank');event.preventDefault()}};const showTooltip=(event,url)=>{const fullUrl=getFullUrl(url);tooltip.style.display='block';tooltip.textContent=fullUrl};const hideTooltip=()=>{tooltip.style.display='none'};const addListeners=(element)=>{const url=element.dataset.clicktogo;if(!url)return;const fullUrl=getFullUrl(url);element.addEventListener('click',(e)=>handleClick(e,fullUrl));element.addEventListener('mouseup',(e)=>handleMouseUp(e,fullUrl));element.addEventListener('mouseover',(e)=>showTooltip(e,url));element.addEventListener('mouseout',hideTooltip);element.addEventListener('focus',(e)=>showTooltip(e,url));element.addEventListener('blur',hideTooltip)};document.querySelectorAll('.clicktogo').forEach(addListeners)})()