"use strict";$(document).ready((function(){var e=document.querySelectorAll(".door"),o=document.querySelectorAll(".door__sales"),t=(document.querySelector(".door__wrapper"),document.querySelector(".spin-result-wrapper")),n=(document.querySelector(".pop-up-button"),document.querySelector(".order_block"),document.getElementById("door__1")),r=document.getElementById("door__2"),i=document.getElementById("door__3"),c=document.getElementById("door__sales1"),l=document.getElementById("door__sales2"),s=document.getElementById("door__sales3"),u=$("#discount").text();function d(a){a.currentTarget.classList.add("open"),setTimeout((function(){t.style.display="block"}),2500),o.forEach((function(e){n.classList.contains("open")?(c.innerHTML=u+"%",l.innerHTML="35%",s.innerHTML="50%"):r.classList.contains("open")?(l.innerHTML=u+"%",c.innerHTML="50%",s.innerHTML="35%"):i.classList.contains("open")&&(c.innerHTML="35%",s.innerHTML=u+"%",l.innerHTML="50%")}));for(var p=0;p<e.length;p++)!function(o){e[o].classList.contains("open")||setTimeout((function(){e[o].classList.add("open")}),1500)}(p);for(var m=0;m<e.length;m++)e[m].removeEventListener("click",d);for(m=0;m<e.length;m++)e[m].removeEventListener("touchend",d)}e.forEach((function(e){e.addEventListener("click",d)}));let a=1;$(".box").click((function(){setTimeout((function(){$(".hide-block").hide(),$(".door__wrapper").hide(),$(".order_block").show(),setTimeout((function(){$(window).width()<767&&$("#scroll-point").hide()}),5e3)}),3e3),a&&(setTimeout((function(){p=setInterval(f,1e3)}),5e3),a=0)})),$(".close-popup, .pop-up-button").click((function(e){e.preventDefault(),$(".spin-result-wrapper").fadeOut()}));var p,m=600;function f(){if(0<m){m-=1;var e=Math.floor(m/60),o=10<=(o=m-60*e)?o:"0"+o;if(e<0&&(e=0),$("#min").html("0"+e),$("#sec").html(o),0==e&&0==o)return clearInterval(p),!1}}$(" a, .pop-up-button, .close-popup, .vtgoodlink").click((function(e){return $(".door__wrapper").is(":visible")?$("html, body").animate({scrollTop:$(".door__wrapper").offset().top},800):$("html, body").animate({scrollTop:$("#order_form").offset().top-($(window).height()-$("#order_form").outerHeight(!0))},800),e.preventDefault(),$(".spin-result-wrapper").fadeOut(),!1}))}));