var popupStatus=0;function loadPopup(){if(popupStatus==0){$j("#backgroundPopup").css({opacity:"0.0"});$j("#backgroundPopup").fadeIn("slow");$j("#popupContact").fadeIn("slow");popupStatus=1;}}function disablePopup(){if(popupStatus==1){$j("#backgroundPopup").fadeOut("slow");$j("#popupContact").fadeOut("slow");popupStatus=0;}}function centerPopup(){var windowWidth=document.documentElement.clientWidth;var windowHeight=document.documentElement.clientHeight;var popupHeight=$j("#popupContact").height();var popupWidth=$j("#popupContact").width();$j("#popupContact").css({position:"absolute",top:"110.5px;",left:"320px;"});$j("#backgroundPopup").css({height:windowHeight});}$j(document).ready(function(){$j("#buttonSlides").click(function(){centerPopup();loadPopup();});$j("#popupContactClose").click(function(){disablePopup();});$j("#backgroundPopup").click(function(){disablePopup();});$j(document).keypress(function(e){if(e.keyCode==27&&popupStatus==1){disablePopup();}});});
