(function(a){a.fn.compactize=function(b){var c={labelOpacity:true};b=a.extend(c,b);return this.each(function(){var e=a(this),d=a("#"+e.attr("for"));d.focus(function(){if(b.labelOpacity){if(d.val()===""){e.css("opacity","0.5")}}else{e.hide()}});if(b.labelOpacity){d.keydown(function(){e.hide();e.css("opacity",1)})}d.blur(function(){if(d.val()===""){e.show()}if(b.labelOpacity){e.css("opacity",1)}});window.setTimeout(function(){if(d.val()!==""){e.hide()}},50)})}})(jQuery);(function(a){a.fn.extend({hrefId:function(){return a(this).attr("href").substr(a(this).attr("href").indexOf("#"))}})})(jQuery);jQuery(function(b){var a={utils:{links:function(){b("a[rel*=external]").click(function(c){c.preventDefault();window.open(b(this).attr("href"))})},mails:function(){b("a[href^=mailto:]").each(function(){var c=b(this).attr("href").replace("mailto:","");var d=c.replace("/at/","@");b(this).attr("href","mailto:"+d);if(b(this).text()==c){b(this).text(d)}})}},ui:{tabs:function(){b(".product-tabs li a").click(function(){if(b(this).is(".active")){return false}b(".product-tabs li a").removeClass("active");b(this).addClass("active");b(".tabs-area-b .product-list").removeClass("active");b(b(this).hrefId()).addClass("active");return false})},showcase:function(){$showcase=b("div.showcase-a");var d=750;var c=5000;$showcase.find("div.item").mouseenter(function(){$showcase.data("activity",1);if(!b(this).is(".active")){b(this).addClass("active").siblings().removeClass("active").find("p.photo").hide();b(this).find("p.photo").show()}}).mouseleave(function(){$showcase.removeData("activity")});$showcase.find("div.item").each(function(){var e=b(this).find("p.photo a");if(e.size()>0){b(this).addClass("linked");b(this).find("div.side").click(function(){window.location=e.attr("href")})}});showcaseChange=function(e){if($showcase.find("div.item p.photo:animated").size()>0){return false}var f=$showcase.find("div.item.active");if(typeof arguments[0]=="undefined"){if($showcase.data("activity")==1){return false}var e=(f.next("div.item").size()<1)?$showcase.find("div.item:first"):f.next("div.item")}f.find("p.photo").fadeOut(d,function(){f.removeClass("active");e.addClass("active");e.find("p.photo").fadeIn(d)})};var c=setInterval("showcaseChange()",(c+2*d))}}};a.utils.links();a.utils.mails();a.ui.tabs();a.ui.showcase();b("#root #nav li:not(.nav-4) a.level-top").click(function(){b("#nav li").removeClass("active");b("#top .hidden-layer").hide();var c=b(this).parent().attr("class");colorArr=c.split(" ");for(var d=0;d<colorArr.length;++d){if(colorArr[d].substring(0,4)=="nav-"){c=colorArr[d]}}b("#top ."+c+" .hidden-layer").show();b(this).parent().addClass("active");return false});b("#top .hidden-layer p.close-layer").click(function(){b(this).parent().hide();b("#nav li").removeClass("active")});b("#recentproducts p.more a").click(function(){b("#recentproducts .product-f").show("normal");return false});b("#sidebarcart p.more a").click(function(){b("#sidebarcart .product-f").show("normal");return false})});
