/* 瀑布流 */
eval(function(p,a,c,k,e,r){e=function(c){return(c<a?'':e(parseInt(c/a)))+((c=c%a)>35?String.fromCharCode(c+29):c.toString(36))};if(!''.replace(/^/,String)){while(c--)r[e(c)]=k[c]||e(c);k=[function(e){return r[e]}];e=function(){return'\\w+'};c=1};while(c--)if(k[c])p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c]);return p}('(3(f,e,l){4 h=e.1H,k;h.18.n={2n:3(){e(2).O("M",h.18.n.13)},2k:3(){e(2).K("M",h.18.n.13)},13:3(a,c){4 b=2,d=1C;a.2e="n";k&&27(k);k=A(3(){1k.1H.26.t(b,d)},"1u"===c?0:24)}};e.Y.n=3(a){u a?2.O("n",a):2.22("n",["1u"])};e.z=3(a,c){2.7=e(c);2.1p(a);2.C()};e.z.1x={1y:!0,1z:!1,1G:{20:!1,1Z:1W},w:0,1e:!1,R:!1,1j:{Q:"1V"}};e.z.1m={14:3(a){4 c=2.5.1P;u c?a.1t(c).Z(a.1w(c)):a},12:3(a){u 2.14(a).p({Q:"1O"}).1A("6-1D")},1p:3(a){2.5=e.1F(!0,{},e.z.1x,a);2.r=[];a=2.7[0].o;2.F={G:a.G||""};4 c=2.5.1j,b;9(b 1d c)2.F[b]=a[b]||"";2.7.p(c);2.17=2.5.1e?"1N":"1g";2.P={x:1i(2.7.p("1h-"+2.17),10),y:1i(2.7.p("1h-B"),10)};2.S=2.5.j&&"3"==1n 2.5.j;4 d=2;A(3(){d.7.1A("6")},0);2.5.1y&&e(f).O("n.6",3(){d.M()});2.U()},C:3(a){2.V();2.W(a)},1r:3(a,c){e.1K(a)&&(2.5=e.1F(!0,2.5,a))},X:3(a,c){9(4 b=0,d=a.J;b<d;b++)2.1v(a[b]);d={};d.G=i.11.t(i,2.q);v(2.5.R){9(4 e=0,b=2.8;--b&&0===2.q[b];)e++;d.1B=(2.8-e)*2.j-2.5.w}2.r.N({$16:2.7,o:d});9(4 e=2.1E?2.5.1z?"28":"p":"p",g=2.5.1G,f,b=0,d=2.r.J;b<d;b++)f=2.r[b],f.$16[e](f.o,g);2.r=[];c&&c.s(a);2.1E=!0},V:3(){4 a=(2.5.R?2.7.1J():2.7).1B();2.j=2.S?2.5.j(a):2.5.j||2.$m.1s(!0)||a;2.j+=2.5.w;2.8=i.1L((a+2.5.w)/2.j);2.8=i.11(2.8,1)},1v:3(a){a=e(a);4 c,b,d,f,g;c=i.1M(a.1s(!0)/(2.j+2.5.w));c=i.1f(c,2.8);v(1===c)d=2.q;15 9(b=2.8+1-c,d=[],g=0;g<b;g++)f=2.q.1q(g,g+c),d[g]=i.11.t(i,f);g=i.1f.t(i,d);b=c=0;9(f=d.J;b<f;b++)v(d[b]===g){c=b;1Q}d={B:g+2.P.y};d[2.17]=2.j*c+2.P.x;2.r.N({$16:a,o:d});a=g+a.1R(!0);d=2.8+1-f;9(b=0;b<d;b++)2.q[c+b]=a},M:3(){4 a=2.8;2.V();(2.S||2.8!==a)&&2.W()},W:3(a){4 c=2.8;9(2.q=[];c--;)2.q.N(0);2.X(2.$m,a)},U:3(){2.$m=2.12(2.7.1S())},1T:3(a){2.U();2.C(a)},1U:3(a,c,b){v(c){2.14(a).p({B:2.7.G()});4 d=2;A(3(){d.19(a,b)},1)}15 2.19(a,b)},19:3(a,c){4 b=2.12(a);2.$m=2.$m.Z(b);2.X(b,c)},1b:3(a){2.$m=2.$m.1X(a);a.1b()},1Y:3(){2.$m.1a("6-1D").H(3(){2.o.Q="";2.o.B="";2.o.1g=""});4 a=2.7[0].o,c;9(c 1d 2.F)a[c]=2.F[c];2.7.K(".6").1a("6").21("6");e(f).K(".6")}};e.Y.D=3(a){3 c(a){a=a.23;a.E!==h&&-1===e.25(a,k)&&(k.N(a),0>=--g&&(A(b),f.K(".D",c)))}3 b(){a.s(d,f)}4 d=2,f=d.1w("1l").Z(d.1t("1l")),g=f.J,h="I:1I/29;2a,2b///2c==",k=[];g||b();f.O("2d.D T.D",c).H(3(){4 a=2.E;2.E=h;2.E=a});u d};e.Y.6=3(a){v("2f"==1n a){4 c=2g.1m.1q.s(1C,1);2.H(3(){4 b=e.I(2,"6");b?e.2h(b[a])&&"2i"!==a.2j(0)?b[a].t(b,c):f.L&&f.L.T("2l 2m 1c \'"+a+"\' 9 6 2o"):f.L&&f.L.T("2p s 2q 2r 6 2s 1o 2t; 2u 1o s 1c \'"+a+"\'")})}15 2.H(3(){4 b=e.I(2,"6");b?(b.1r(a||{}),b.C()):e.I(2,"6",2v e.z(a,2))});u 2}})(2w,1k);',62,157,'||this|function|var|options|masonry|element|cols|for|||||||||Math|columnWidth|||bricks|smartresize|style|css|colYs|styleQueue|call|apply|return|if|gutterWidth|||Mason|setTimeout|top|_init|imagesLoaded|src|originalStyle|height|each|data|length|unbind|console|resize|push|bind|offset|position|isFitWidth|isFluid|error|reloadItems|_getColumns|_reLayout|layout|fn|add||max|_getBricks|handler|_filterFindBricks|else|el|horizontalDirection|special|_appended|removeClass|remove|method|in|isRTL|min|left|padding|parseInt|containerStyle|jQuery|img|prototype|typeof|to|_create|slice|option|outerWidth|filter|execAsap|_placeBrick|find|settings|isResizable|isAnimated|addClass|width|arguments|brick|isLaidOut|extend|animationOptions|event|image|parent|isPlainObject|floor|ceil|right|absolute|itemSelector|break|outerHeight|children|reload|appended|relative|500|not|destroy|duration|queue|removeData|trigger|target|100|inArray|handle|clearTimeout|animate|gif|base64|R0lGODlhAQABAIAAAAAAAP|ywAAAAAAQABAAACAUwAOw|load|type|string|Array|isFunction|_|charAt|teardown|no|such|setup|instance|cannot|methods|on|prior|initialization|attempted|new|window'.split('|'),0,{}))
function item_masonry() {
	$('.item-list img').load(function() {
		$('.item-loop').masonry({
			itemSelector: '.loop',
			isAnimated: true
		})
	});
	$('.item-loop').masonry({
		itemSelector: '.loop',
		isAnimated: true
	})
}
var startHref;
$(function() {
	var p = false;
	if ($(".item-list").length > 0) {
		p = true;
		item_masonry()
	}
	$(".page-more a").click(function() {
		var href = $(this).attr("href");
		startHref = href;
		if (href != undefined) {
			$.ajax({
				type: "get",
				cache: false,
				url: startHref,
				success: function(data) {
					var $result = $(data).find(".loop");
					if (p) {
						$(".item-loop").append($result).masonry('appended', $result);
						item_masonry()
					} else {
						$(".item-loop").append($result)
					}
					var newHref = $(data).find(".page-more a").attr("href");
					if (newHref != "") {
						$(".page-more a").attr("href", newHref)
					} else {
						$(".page-more").html("")
					}
				}
			})
		}
		return false
	});
	$(window).bind("scroll", function() {
		if ($(document).scrollTop() + $(window).height() > $(document).height() - 258) {
			if ($(".page-more a").attr('href') != startHref) {
				$(".page-more a").trigger("click")
			}
		}
	})
});

/* 更多加载 */
$(function() {
	$(".cpage-more a").click(function() {
		var href = $(this).attr("href");
		startHref = href;
		if (href != undefined) {
			$.ajax({
				type: "get",
				cache: false,
				url: startHref,
				success: function(data) {
					var $result = $(data).find(".cloop");
					$(".citem-loop").append($result);
					var newHref = $(data).find(".cpage-more a").attr("href");
					if (newHref != "") {
						$(".cpage-more a").attr("href", newHref)
					} else {
						$(".cpage-more").hide()
					}
				}
			})
		}
		return false
	})
});

/* 返回顶部 */
$(function() {
	$(window).scroll(function() {
		if ($(window).scrollTop() > 50) {
			$(".topIco").show()
		} else {
			$(".topIco").hide()
		}
	});
	$(".topIco").click(function() {
		$("body").animate({
			scrollTop: 0
		},
		300)
	})
});

/* 滚动导航 */
$(function() {
	$(window).scroll(function() {
		if ($(window).scrollTop() > 149) {
			$(".all-bgc").addClass("fixed-nav fixed-navShow")
		} else {
			$(".all-bgc").removeClass("fixed-nav fixed-navShow")
		}
	})
});

/* 固定层
$(function() {
	function scrollLis() {
		var toTop = offs.top - $(window).scrollTop();
		if (toTop == 0 || toTop < 0) {
			if (!$(".fixed-div").hasClass("fixed")) $(".fixed-div").addClass("fixed")
		} else {
			$(".fixed-div").removeClass("fixed")
		}
	}
	var offs = $('.fixed-div').offset();
	$(window).scroll(function() {
		scrollLis()
	})
});
*/

/*!
 * SuperSlide v2.1.1 
 * 轻松解决网站大部分特效展示问题
 * 详尽信息请看官网：http://www.SuperSlide2.com/
 *
 * Copyright 2011-2013, 大话主席
 *
 * 请尊重原创，保留头部版权
 * 在保留版权的前提下可应用于个人或商业用途

 * v2.1.1：修复当调用多个SuperSlide，并设置returnDefault:true 时返回defaultIndex索引错误

 */
!function(a){a.fn.slide=function(b){return a.fn.slide.defaults={type:"slide",effect:"fade",autoPlay:!1,delayTime:500,interTime:2500,triggerTime:150,defaultIndex:0,titCell:".hd li",mainCell:".bd",targetCell:null,trigger:"mouseover",scroll:1,vis:1,titOnClassName:"on",autoPage:!1,prevCell:".prev",nextCell:".next",pageStateCell:".pageState",opp:!1,pnLoop:!0,easing:"swing",startFun:null,endFun:null,switchLoad:null,playStateCell:".playState",mouseOverStop:!0,defaultPlay:!0,returnDefault:!1},this.each(function(){var c=a.extend({},a.fn.slide.defaults,b),d=a(this),e=c.effect,f=a(c.prevCell,d),g=a(c.nextCell,d),h=a(c.pageStateCell,d),i=a(c.playStateCell,d),j=a(c.titCell,d),k=j.size(),l=a(c.mainCell,d),m=l.children().size(),n=c.switchLoad,o=a(c.targetCell,d),p=parseInt(c.defaultIndex),q=parseInt(c.delayTime),r=parseInt(c.interTime);parseInt(c.triggerTime);var Q,t=parseInt(c.scroll),u=parseInt(c.vis),v="false"==c.autoPlay||0==c.autoPlay?!1:!0,w="false"==c.opp||0==c.opp?!1:!0,x="false"==c.autoPage||0==c.autoPage?!1:!0,y="false"==c.pnLoop||0==c.pnLoop?!1:!0,z="false"==c.mouseOverStop||0==c.mouseOverStop?!1:!0,A="false"==c.defaultPlay||0==c.defaultPlay?!1:!0,B="false"==c.returnDefault||0==c.returnDefault?!1:!0,C=0,D=0,E=0,F=0,G=c.easing,H=null,I=null,J=null,K=c.titOnClassName,L=j.index(d.find("."+K)),M=p=-1==L?p:L,N=p,O=p,P=m>=u?0!=m%t?m%t:t:0,R="leftMarquee"==e||"topMarquee"==e?!0:!1,S=function(){a.isFunction(c.startFun)&&c.startFun(p,k,d,a(c.titCell,d),l,o,f,g)},T=function(){a.isFunction(c.endFun)&&c.endFun(p,k,d,a(c.titCell,d),l,o,f,g)},U=function(){j.removeClass(K),A&&j.eq(N).addClass(K)};if("menu"==c.type)return A&&j.removeClass(K).eq(p).addClass(K),j.hover(function(){Q=a(this).find(c.targetCell);var b=j.index(a(this));I=setTimeout(function(){switch(p=b,j.removeClass(K).eq(p).addClass(K),S(),e){case"fade":Q.stop(!0,!0).animate({opacity:"show"},q,G,T);break;case"slideDown":Q.stop(!0,!0).animate({height:"show"},q,G,T)}},c.triggerTime)},function(){switch(clearTimeout(I),e){case"fade":Q.animate({opacity:"hide"},q,G);break;case"slideDown":Q.animate({height:"hide"},q,G)}}),B&&d.hover(function(){clearTimeout(J)},function(){J=setTimeout(U,q)}),void 0;if(0==k&&(k=m),R&&(k=2),x){if(m>=u)if("leftLoop"==e||"topLoop"==e)k=0!=m%t?(0^m/t)+1:m/t;else{var V=m-u;k=1+parseInt(0!=V%t?V/t+1:V/t),0>=k&&(k=1)}else k=1;j.html("");var W="";if(1==c.autoPage||"true"==c.autoPage)for(var X=0;k>X;X++)W+="<li>"+(X+1)+"</li>";else for(var X=0;k>X;X++)W+=c.autoPage.replace("$",X+1);j.html(W);var j=j.children()}if(m>=u){l.children().each(function(){a(this).width()>E&&(E=a(this).width(),D=a(this).outerWidth(!0)),a(this).height()>F&&(F=a(this).height(),C=a(this).outerHeight(!0))});var Y=l.children(),Z=function(){for(var a=0;u>a;a++)Y.eq(a).clone().addClass("clone").appendTo(l);for(var a=0;P>a;a++)Y.eq(m-a-1).clone().addClass("clone").prependTo(l)};switch(e){case"fold":l.css({position:"relative",width:D,height:C}).children().css({position:"absolute",width:E,left:0,top:0,display:"none"});break;case"top":l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+u*C+'px"></div>').css({top:-(p*t)*C,position:"relative",padding:"0",margin:"0"}).children().css({height:F});break;case"left":l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+u*D+'px"></div>').css({width:m*D,left:-(p*t)*D,position:"relative",overflow:"hidden",padding:"0",margin:"0"}).children().css({"float":"left",width:E});break;case"leftLoop":case"leftMarquee":Z(),l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; width:'+u*D+'px"></div>').css({width:(m+u+P)*D,position:"relative",overflow:"hidden",padding:"0",margin:"0",left:-(P+p*t)*D}).children().css({"float":"left",width:E});break;case"topLoop":case"topMarquee":Z(),l.wrap('<div class="tempWrap" style="overflow:hidden; position:relative; height:'+u*C+'px"></div>').css({height:(m+u+P)*C,position:"relative",padding:"0",margin:"0",top:-(P+p*t)*C}).children().css({height:F})}}var $=function(a){var b=a*t;return a==k?b=m:-1==a&&0!=m%t&&(b=-m%t),b},_=function(b){var c=function(c){for(var d=c;u+c>d;d++)b.eq(d).find("img["+n+"]").each(function(){var b=a(this);if(b.attr("src",b.attr(n)).removeAttr(n),l.find(".clone")[0])for(var c=l.children(),d=0;d<c.size();d++)c.eq(d).find("img["+n+"]").each(function(){a(this).attr(n)==b.attr("src")&&a(this).attr("src",a(this).attr(n)).removeAttr(n)})})};switch(e){case"fade":case"fold":case"top":case"left":case"slideDown":c(p*t);break;case"leftLoop":case"topLoop":c(P+$(O));break;case"leftMarquee":case"topMarquee":var d="leftMarquee"==e?l.css("left").replace("px",""):l.css("top").replace("px",""),f="leftMarquee"==e?D:C,g=P;if(0!=d%f){var h=Math.abs(0^d/f);g=1==p?P+h:P+h-1}c(g)}},ab=function(a){if(!A||M!=p||a||R){if(R?p>=1?p=1:0>=p&&(p=0):(O=p,p>=k?p=0:0>p&&(p=k-1)),S(),null!=n&&_(l.children()),o[0]&&(Q=o.eq(p),null!=n&&_(o),"slideDown"==e?(o.not(Q).stop(!0,!0).slideUp(q),Q.slideDown(q,G,function(){l[0]||T()})):(o.not(Q).stop(!0,!0).hide(),Q.animate({opacity:"show"},q,function(){l[0]||T()}))),m>=u)switch(e){case"fade":l.children().stop(!0,!0).eq(p).animate({opacity:"show"},q,G,function(){T()}).siblings().hide();break;case"fold":l.children().stop(!0,!0).eq(p).animate({opacity:"show"},q,G,function(){T()}).siblings().animate({opacity:"hide"},q,G);break;case"top":l.stop(!0,!1).animate({top:-p*t*C},q,G,function(){T()});break;case"left":l.stop(!0,!1).animate({left:-p*t*D},q,G,function(){T()});break;case"leftLoop":var b=O;l.stop(!0,!0).animate({left:-($(O)+P)*D},q,G,function(){-1>=b?l.css("left",-(P+(k-1)*t)*D):b>=k&&l.css("left",-P*D),T()});break;case"topLoop":var b=O;l.stop(!0,!0).animate({top:-($(O)+P)*C},q,G,function(){-1>=b?l.css("top",-(P+(k-1)*t)*C):b>=k&&l.css("top",-P*C),T()});break;case"leftMarquee":var c=l.css("left").replace("px","");0==p?l.animate({left:++c},0,function(){l.css("left").replace("px","")>=0&&l.css("left",-m*D)}):l.animate({left:--c},0,function(){l.css("left").replace("px","")<=-(m+P)*D&&l.css("left",-P*D)});break;case"topMarquee":var d=l.css("top").replace("px","");0==p?l.animate({top:++d},0,function(){l.css("top").replace("px","")>=0&&l.css("top",-m*C)}):l.animate({top:--d},0,function(){l.css("top").replace("px","")<=-(m+P)*C&&l.css("top",-P*C)})}j.removeClass(K).eq(p).addClass(K),M=p,y||(g.removeClass("nextStop"),f.removeClass("prevStop"),0==p&&f.addClass("prevStop"),p==k-1&&g.addClass("nextStop")),h.html("<span>"+(p+1)+"</span>/"+k)}};A&&ab(!0),B&&d.hover(function(){clearTimeout(J)},function(){J=setTimeout(function(){p=N,A?ab():"slideDown"==e?Q.slideUp(q,U):Q.animate({opacity:"hide"},q,U),M=p},300)});var bb=function(a){H=setInterval(function(){w?p--:p++,ab()},a?a:r)},cb=function(a){H=setInterval(ab,a?a:r)},db=function(){z||(clearInterval(H),bb())},eb=function(){(y||p!=k-1)&&(p++,ab(),R||db())},fb=function(){(y||0!=p)&&(p--,ab(),R||db())},gb=function(){clearInterval(H),R?cb():bb(),i.removeClass("pauseState")},hb=function(){clearInterval(H),i.addClass("pauseState")};if(v?R?(w?p--:p++,cb(),z&&l.hover(hb,gb)):(bb(),z&&d.hover(hb,gb)):(R&&(w?p--:p++),i.addClass("pauseState")),i.click(function(){i.hasClass("pauseState")?gb():hb()}),"mouseover"==c.trigger?j.hover(function(){var a=j.index(this);I=setTimeout(function(){p=a,ab(),db()},c.triggerTime)},function(){clearTimeout(I)}):j.click(function(){p=j.index(this),ab(),db()}),R){if(g.mousedown(eb),f.mousedown(fb),y){var ib,jb=function(){ib=setTimeout(function(){clearInterval(H),cb(0^r/10)},150)},kb=function(){clearTimeout(ib),clearInterval(H),cb()};g.mousedown(jb),g.mouseup(kb),f.mousedown(jb),f.mouseup(kb)}"mouseover"==c.trigger&&(g.hover(eb,function(){}),f.hover(fb,function(){}))}else g.click(eb),f.click(fb)})}}(jQuery),jQuery.easing.jswing=jQuery.easing.swing,jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(a,b,c,d,e){return jQuery.easing[jQuery.easing.def](a,b,c,d,e)},easeInQuad:function(a,b,c,d,e){return d*(b/=e)*b+c},easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c},easeInOutQuad:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b+c:-d/2*(--b*(b-2)-1)+c},easeInCubic:function(a,b,c,d,e){return d*(b/=e)*b*b+c},easeOutCubic:function(a,b,c,d,e){return d*((b=b/e-1)*b*b+1)+c},easeInOutCubic:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b+c:d/2*((b-=2)*b*b+2)+c},easeInQuart:function(a,b,c,d,e){return d*(b/=e)*b*b*b+c},easeOutQuart:function(a,b,c,d,e){return-d*((b=b/e-1)*b*b*b-1)+c},easeInOutQuart:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b+c:-d/2*((b-=2)*b*b*b-2)+c},easeInQuint:function(a,b,c,d,e){return d*(b/=e)*b*b*b*b+c},easeOutQuint:function(a,b,c,d,e){return d*((b=b/e-1)*b*b*b*b+1)+c},easeInOutQuint:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b*b+c:d/2*((b-=2)*b*b*b*b+2)+c},easeInSine:function(a,b,c,d,e){return-d*Math.cos(b/e*(Math.PI/2))+d+c},easeOutSine:function(a,b,c,d,e){return d*Math.sin(b/e*(Math.PI/2))+c},easeInOutSine:function(a,b,c,d,e){return-d/2*(Math.cos(Math.PI*b/e)-1)+c},easeInExpo:function(a,b,c,d,e){return 0==b?c:d*Math.pow(2,10*(b/e-1))+c},easeOutExpo:function(a,b,c,d,e){return b==e?c+d:d*(-Math.pow(2,-10*b/e)+1)+c},easeInOutExpo:function(a,b,c,d,e){return 0==b?c:b==e?c+d:(b/=e/2)<1?d/2*Math.pow(2,10*(b-1))+c:d/2*(-Math.pow(2,-10*--b)+2)+c},easeInCirc:function(a,b,c,d,e){return-d*(Math.sqrt(1-(b/=e)*b)-1)+c},easeOutCirc:function(a,b,c,d,e){return d*Math.sqrt(1-(b=b/e-1)*b)+c},easeInOutCirc:function(a,b,c,d,e){return(b/=e/2)<1?-d/2*(Math.sqrt(1-b*b)-1)+c:d/2*(Math.sqrt(1-(b-=2)*b)+1)+c},easeInElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(0==b)return c;if(1==(b/=e))return c+d;if(g||(g=.3*e),h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return-(h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g))+c},easeOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(0==b)return c;if(1==(b/=e))return c+d;if(g||(g=.3*e),h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return h*Math.pow(2,-10*b)*Math.sin((b*e-f)*2*Math.PI/g)+d+c},easeInOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(0==b)return c;if(2==(b/=e/2))return c+d;if(g||(g=e*.3*1.5),h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return 1>b?-.5*h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+c:.5*h*Math.pow(2,-10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+d+c},easeInBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),d*(b/=e)*b*((f+1)*b-f)+c},easeOutBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),d*((b=b/e-1)*b*((f+1)*b+f)+1)+c},easeInOutBack:function(a,b,c,d,e,f){return void 0==f&&(f=1.70158),(b/=e/2)<1?d/2*b*b*(((f*=1.525)+1)*b-f)+c:d/2*((b-=2)*b*(((f*=1.525)+1)*b+f)+2)+c},easeInBounce:function(a,b,c,d,e){return d-jQuery.easing.easeOutBounce(a,e-b,0,d,e)+c},easeOutBounce:function(a,b,c,d,e){return(b/=e)<1/2.75?d*7.5625*b*b+c:2/2.75>b?d*(7.5625*(b-=1.5/2.75)*b+.75)+c:2.5/2.75>b?d*(7.5625*(b-=2.25/2.75)*b+.9375)+c:d*(7.5625*(b-=2.625/2.75)*b+.984375)+c},easeInOutBounce:function(a,b,c,d,e){return e/2>b?.5*jQuery.easing.easeInBounce(a,2*b,0,d,e)+c:.5*jQuery.easing.easeOutBounce(a,2*b-e,0,d,e)+.5*d+c}});

/* 幻灯 */
jQuery(".slideBox").slide({
	mainCell: ".bd ul",
	interTime: 5000,
	autoPlay: true
});
jQuery(".slideBox").hover(function() {
	jQuery(this).find(".prev").stop(true, true).fadeIn(300);
	jQuery(this).find(".next").stop(true, true).fadeIn(300)
},
function() {
	jQuery(this).find(".prev").fadeOut(300);
	jQuery(this).find(".next").fadeOut(300)
});

/* 内页幻灯 */
jQuery("#slideBox1").slide({
	mainCell: ".bd dl",
	autoPlay: true,
	effect: "left",
	interTime: 5000,
	endFun: function(i, c) {
		jQuery("#slideBox1 .tit").css({
			"bottom": -32
		}).eq(i).animate({
			"bottom": 0
		});
		jQuery("#slideBox1 .bg").css({
			"bottom": -32
		}).eq(i).animate({
			"bottom": 0
		})
	}
});

/* 切换 放大 */
(function(){function r(){this.init.apply(this,arguments)}var d,k,h;d={addHandler:function(a,b,c){a.addEventListener?a.addEventListener(b,c,!1):a.attachEvent?a.attachEvent("on"+b,c):a["on"+b]=c},removeHandler:function(a,b,c){a.removeEventListener?a.removeEventListener(b,c,!1):a.detachEvent?a.detachEvent("on"+b,c):a["on"+b]=null},getEvent:function(a){return a?a:window.event},getTarget:function(a){return a.target||a.srcElement},preventDefault:function(a){a.preventDefault?a.preventDefault():a.returnValue=!1},stopPropagation:function(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0}};k={byId:function(a){return"string"===typeof a?document.getElementById(a):a},byClass:function(a,b){for(var c=[],d=new RegExp("(^| )"+a+"( |$)"),f=this.byTagName("*",b),e=0;e<f.length;e++)d.test(f[e].className)&&c.push(f[e]);return c},byTagName:function(a,b){return(b||document).getElementsByTagName(a)}};h={hasClass:function(a,b){return-1<(" "+a.className+" ").indexOf(" "+b+" ")?!0:!1},addClass:function(a,b){this.hasClass(a,b)||(a.className+=" "+b)},removeClass:function(a,b){a.className=a.className.replace(new RegExp("(^|\\s)"+b+"(?:\\s|$)"),"$1").replace(/\s{1,}/g," ")}};r.prototype={init:function(a){this.magWrap=k.byId(a);this.magMain=this.magWrap.children[0];this.mW=this.magMain.offsetWidth;this.mH=this.magMain.offsetHeight;this.magImg=this.magMain.getElementsByTagName("img")[0];this.mImgSrc=this.magImg.getAttribute("src").slice(0,-4);this.specBox=k.byClass("spec-items",this.magWrap)[0];this.specUl=this.specBox.getElementsByTagName("ul")[0];this.specItem=this.specBox.getElementsByTagName("li");this.specFn();this.setEventFn().dragEvent()},setEleFn:function(){var a="",b=document.createDocumentFragment(),c=document.createDocumentFragment();this.oMD=document.createElement("div");this.oMD.className="MagnifierDrag";this.oMD.style.cssText="width:"+this.mW/3+"px;height:"+this.mH/3+"px;";this.oMD.innerHTML="&nbsp;";this.oMP=document.createElement("div");this.oMP.className="MagnifierPop";this.oMP.style.cssText="width:"+this.mW+"px;height:"+this.mH+"px;right:"+(-this.mW-10)+"px;";this.oMI=document.createElement("div");this.oMI.className="MagnifierImg";this.oMI.style.cssText="width:"+3*this.mW+"px;height:"+3*this.mH+"px;";a='<img style="width:100%;height:100%;" src="'+this.mImgSrc+'.jpg">';this.oMI.innerHTML=a;this.oMP.appendChild(this.oMI);b.appendChild(this.oMD);c.appendChild(this.oMP);this.magMain.appendChild(b);this.magWrap.appendChild(c)},removeFn:function(){this.magMain.removeChild(this.oMD);this.magWrap.removeChild(this.oMP)},setMousemoveFn:function(a){var b=document.documentElement.scrollLeft||document.body.scrollLeft,c=document.documentElement.scrollTop||document.body.scrollTop;_x=a.clientX+b-(this.magWrap.getBoundingClientRect().left+b)-this.oMD.offsetWidth/2;_y=a.clientY+c-(this.magMain.getBoundingClientRect().top+c)-this.oMD.offsetHeight/2;_l=this.magMain.offsetWidth-this.oMD.offsetWidth;_t=this.magMain.offsetHeight-this.oMD.offsetHeight;_l2=-(this.oMI.offsetWidth-this.magMain.offsetWidth);_t2=-(this.oMI.offsetHeight-this.magMain.offsetHeight);0>_x?_x=0:_x>_l&&(_x=_l);0>_y?_y=0:_y>_t&&(_y=_t);this.oMD.style.left=_x+"px";this.oMD.style.top=_y+"px";_bigx=_x/_l;_bigy=_y/_t;this.oMI.style.left=_bigx*_l2+"px";this.oMI.style.top=_bigy*_t2+"px"},setEventFn:function(){function a(a){a=d.getEvent(a);switch(a.type){case"mouseenter":b.setEleFn();break;case"mousemove":b.oMD&&b.setMousemoveFn(a);break;case"mouseleave":b.removeFn()}}var b=this;return{dragEvent:function(){d.addHandler(b.magMain,"mouseenter",a);d.addHandler(b.magMain,"mousemove",a);d.addHandler(b.magMain,"mouseleave",a)}}},specFn:function(){function a(a){a=d.getTarget(a);if(-1<a.className.indexOf("spe_rightBtn")){m=++n;m>l-5&&h.removeClass(a,"on");if(m>l-4)return n=l-4,!1;b.buttur(b.specUl,{left:-(m*g)});h.addClass(f,"on")}if(-1<a.className.indexOf("spe_leftBtn")){p=--n;1>p&&h.removeClass(a,"on");if(0>p)return n=0,!1;b.buttur(b.specUl,{left:-(p*g)});h.addClass(e,"on")}}var b=this,c,q,f=k.byClass("spe_leftBtn",b.magWrap)[0],e=k.byClass("spe_rightBtn",b.magWrap)[0],g=this.specUl.getElementsByTagName("li")[0].offsetWidth+5,l=b.specItem.length,n=0,p=null,m=null;d.addHandler(b.specUl,"mouseover",function(a){a=d.getTarget(a);var e=0;if("UL"!=a.nodeName){"IMG"==a.nodeName&&(a=a.parentNode);for(;e<l;e++)b.specItem[e].className="";a.className="on";c=a.getElementsByTagName("img")[0];q=c.getAttribute("src");b.magImg.setAttribute("src",q);b.mImgSrc=q.slice(0,-4)}});4<l&&(h.addClass(e,"on"),d.addHandler(b.magWrap,"click",a))},buttur:function(a,b){window.clearTimeout(a.timer);var c=this,d=null;for(direc in b){var f=direc.toLowerCase(),e="offset"+f.substr(0,1).toUpperCase()+f.substring(1).toLowerCase(),g=(b[direc]-a[e])/8,g=0<=g?Math.ceil(g):Math.floor(g);a.style[f]=a[e]+g+"px";d+=g}d&&("function"==typeof fnCallback?fnCallback.call(a):a.timer=window.setTimeout(function(){c.buttur(a,b)},20))}};window.MagnifierF=function(a){return new r(a)}})();window.onload=function(){MagnifierF("MagnifierWrap2")};
jQuery(".slideBox2").slide({
	mainCell: ".bd ul",
	easing: "easeInBack"
});

/* 分类下拉 */
$(function() {
	$(".navBox h3").click(function() {
		$(this).toggleClass("noActive").siblings("h3").removeClass("noActive");
		$(this).toggleClass("active").siblings("h3").removeClass("active");
		$(this).next("ul").slideToggle(300).siblings("ul").slideUp(500)
	})
});

/* 加载 */
$(window).load(function() {
	$(".loading").css("visibility", "hidden")
});

/* 搜索提示 */
function checksearch(the) {
	if ($.trim(the.key.value) == '') {
		alert('请输入关键字');
		the.key.focus();
		the.key.value = '';
		return false
	}
	if ($.trim(the.key.value) == '请输入关键字') {
		alert('请输入关键字');
		the.key.focus();
		the.key.value = '';
		return false
	}
}

/* 修复 */
window.onerror=function(){return!0};