function ConversionTracker(){this.init=function(){let n=this;$(document).ready(function(){n.setClickIdAndSource();$(".store-link-button").on("click",function(){let u=$(this).attr("href"),t=$(this).data("vt"),i=$(this).data("ev"),r=$(this).data("lb");n.registerStoreButtonClick($(this).attr("id"),t,i,r)})})};this.registerStoreButtonClick=function(n,t,i,r){let e=Cookies.get("CTG"),o=Cookies.get("CTF"),s=Cookies.get("CTM"),h=Cookies.get("CTDV");try{t&&t!=""&&callHandler(Hit,t)}catch(c){}let f=null,u=null;if(e&&e!="")try{u="gclid="+e}catch(c){}else if(o&&o!="")try{u="fbclid="+o}catch(c){}else if(s&&s!="")try{u="msclkid="+s;window.uetq.push("event",i,{event_category:"StoreClicks",event_label:r,event_value:"1"})}catch(c){}if(u){let n="";h&&h!=""&&(n="&dv="+h);switch(i){case"Go2GooglePlay":let t=encodeURIComponent("https://play.google.com/store/apps/details?id=com.dyve.countthings&"+u+n);f="https://countthings.page.link/?link="+t+"&apn=com.dyve.countthings";break;case"Go2AppleAppStore":let i=encodeURIComponent("https://itunes.apple.com/us/app/countthings-from-photos/id1196810823?"+u+n);f="https://countthings.page.link/?link="+i+"&ibi=com.dyve.CountThings&isi=1196810823&efr=1";break;case"Go2HuaweiAppGallery":let r=encodeURIComponent("https://appgallery.cloud.huawei.com/app/C101856961?"+u+n);f="https://countthings.dre.agconnect.link/?deeplink="+r+"&android_package_name=com.dyve.counting.ag&region_id=1";break;case"Go2SamsungGalaxyStore":let e=encodeURIComponent("https://galaxystore.samsung.com/detail/com.dyve.countthings?"+u+n);f="https://countthings.page.link/?link="+e+"&apn=com.dyve.countthings"}}f&&$("#"+n).attr("href",f)};this.setClickIdAndSource=function(){let n=null;try{n=new URLSearchParams(window.location.search)}catch(u){}var t=new Date;t.setTime(t.getTime()+5184e6);let i=n?n.get("dv"):this.getParam("dv");i&&Cookies.set("CTDV",i,{path:"/",expires:t});let r=n?n.get("gclid"):this.getParam("gclid");if(r)Cookies.set("CTG",r,{path:"/",expires:t});else{let i=n?n.get("wbraid"):this.getParam("wbraid"),r=n?n.get("gbraid"):this.getParam("gbraid");i&&Cookies.set("CTG",i,{path:"/",expires:t});r&&Cookies.set("CTG",r,{path:"/",expires:t});let u=n?n.get("fbclid"):this.getParam("fbclid");if(u)Cookies.set("CTF",u,{path:"/",expires:t});else{let i=n?n.get("msclkid"):this.getParam("msclkid");i&&Cookies.set("CTM",i,{path:"/",expires:t})}}};this.getParam=function(n){var t=new RegExp("[?&]"+n+"=([^&#]*)").exec(window.location.href);return t==null?null:decodeURI(t[1])||0}}(function(n){n.fn.videoPopup=function(t){function u(t){n.each(e,function(n,i){var u=i.test(t,i.regex);if(u)return r.embedLink=i.mount(u),this})}function f(){var n='<iframe src="'+r.embedLink+'" allowfullscreen frameborder="0" autoplay="1"  width="'+i.width+'" ><\/iframe>';return r.embedLink||(n='<div class="videopopupjs__block--notfound">Video not found<\/div>'),'<div class="videopopupjs videopopupjs--animation"><div class="videopopupjs__content"><span class="videopopupjs__close"><\/span>'+n+"<\/div><\/div>"}var r={embedLink:""},i=n.extend({autoplay:!0,showControls:!0,controlsColor:null,loopVideo:!1,showVideoInformations:!0,width:null,customOptions:{}},t),e={youtube:{regex:/^.*((youtu.be\/)|(v\/)|(\/u\/\w\/)|(embed\/)|(watch\?))\??v?=?([^#\&\?]*).*/,test:function(n,t){var i=n.match(t);return i&&i[7].length==11?i[7]:!1},mount:function(t){var r={autoplay:i.autoplay,color:i.controlsColor,loop:i.loopVideo,controls:i.showControls,showinfo:i.showVideoInformations};return Object.assign(r,i.customOptions),"https://www.youtube.com/embed/"+t+"/?"+n.param(r)}}};n(this).css("cursor","pointer");n(this).on("click",function(t){t.preventDefault();var r=n(this).attr("href"),e=u(r);n("body").append(f());n(".videopopupjs__content").css("max-width",700);i.width&&n(".videopopupjs__content").css("max-width",i.width);n(".videopopupjs").hasClass("videopopupjs--animation")&&setTimeout(function(){n(".videopopupjs").removeClass("videopopupjs--animation")},200);n(".videopopupjs, .videopopupjs__close").click(function(){n(".videopopupjs").addClass("videopopupjs--hide").delay(515).queue(function(){n(this).remove()})})});return n(document).keyup(function(t){t.keyCode==27&&n(".videopopupjs__close").click()}),this}})(jQuery);$(function(){$(".videoLink").videoPopup({autoplay:1,controlsColor:"white",showVideoInformations:0,width:1e3,customOptions:{rel:0}})});!function(n){var t,r,i;("function"==typeof define&&define.amd&&(define(n),t=!0),"object"==typeof exports&&(module.exports=n(),t=!0),t)||(r=window.Cookies,i=window.Cookies=n(),i.noConflict=function(){return window.Cookies=r,i})}(function(){function n(){for(var i,r,n=0,t={};n<arguments.length;n++){i=arguments[n];for(r in i)t[r]=i[r]}return t}function t(n){return n.replace(/(%[0-9A-Z]{2})+/g,decodeURIComponent)}function i(r){function u(){}function f(t,i,f){var s,o,e;if("undefined"!=typeof document){f=n({path:"/"},u.defaults,f);"number"==typeof f.expires&&(f.expires=new Date(1*new Date+864e5*f.expires));f.expires=f.expires?f.expires.toUTCString():"";try{s=JSON.stringify(i);/^[\{\[]/.test(s)&&(i=s)}catch(h){}i=r.write?r.write(i,t):encodeURIComponent(i+"").replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent);t=encodeURIComponent(t+"").replace(/%(23|24|26|2B|5E|60|7C)/g,decodeURIComponent).replace(/[\(\)]/g,escape);o="";for(e in f)f[e]&&(o+="; "+e,!0!==f[e]&&(o+="="+f[e].split(";")[0]));return document.cookie=t+"="+i+o}}function e(n,i){var s,u,f;if("undefined"!=typeof document){for(var e={},h=document.cookie?document.cookie.split("; "):[],o=0;o<h.length;o++){s=h[o].split("=");u=s.slice(1).join("=");i||'"'!==u.charAt(0)||(u=u.slice(1,-1));try{if(f=t(s[0]),u=(r.read||r)(u,f)||t(u),i)try{u=JSON.parse(u)}catch(c){}if(e[f]=u,n===f)break}catch(c){}}return n?e[n]:e}}return u.set=f,u.get=function(n){return e(n,!1)},u.getJSON=function(n){return e(n,!0)},u.remove=function(t,i){f(t,"",n(i,{expires:-1}))},u.defaults={},u.withConverter=i,u}return i(function(){})});$(function(){window.URLSearchParams=window.URLSearchParams||function(n){var t=this;t.searchString=n;t.get=function(n){var i=new RegExp("[?&]"+n+"=([^&#]*)").exec(t.searchString);return i==null?null:decodeURI(i[1])||0}};var n=new ConversionTracker;n.init()});$(document).ready(function(){function n(n){var t="#"+n;$(".navmenu__link-top").removeClass("is-current");$(t).addClass("is-current");$(".navmenu__link-arrow-open").toggleClass("navmenu__link-arrow-open")}function t(){$(".menu_user").toggleClass("not-visible");$("#general-menu").hasClass("primary-nav__menu-icon")?($("#general-menu").removeClass("primary-nav__menu-icon"),$("#general-menu").toggleClass("primary-nav__menu-close o-icon o-icon--close")):($("#general-menu").removeClass("primary-nav__menu-close o-icon o-icon--close"),$("#general-menu").toggleClass("primary-nav__menu-icon"))}$(".navmenu__sublist-chk-top").on("change",function(){$(".navmenu__sublist-chk-top").not(this).prop("checked",!1)});$(".navmenu__link-arrow-closed").click(function(){$(this).toggleClass("navmenu__link-arrow-open")});$(".js-nav-menu").click(function(){$(".js-nav-list").toggleClass("is-visible");t()});$(".js-nav-menu-items").click(function(){$(".js-nav-list").removeClass("is-visible")});$(window).resize(function(){$(".js-nav-list").hasClass("is-visible")&&($(".js-nav-list").removeClass("is-visible"),t())});window.location.href.toLowerCase().indexOf("#pricing")>0&&n("navPricing");$("#navPricing").click(function(){n("navPricing")});window.location.href.toLowerCase().indexOf("#download")>0&&n("navDownload");$("#navDownload").click(function(){n("navDownload")});window.location.href.toLowerCase().indexOf("#contact")>0&&n("navSupport");$("#navSupport").click(function(){n("navSupport")});$(document).click(function(){var n=$("#headerElement");n.is(event.target)||n.has(event.target).length||($(".navmenu__sublist-chk-top").prop("checked",!1),$(".navmenu__link-arrow-open").toggleClass("navmenu__link-arrow-open"),$(".js-nav-list").hasClass("is-visible")&&($(".js-nav-list").toggleClass("is-visible"),t()))})})