var arrowimages={down:['',''],right:['','']} var slidemenu={animateduration:{over:200,out:200},buildmenu:function(menuid,arrowsvar){jQuery(document).ready(function($){$("#navigation a").removeAttr("title");var $mainmenu=$("#"+menuid+">ul") var $headers=$mainmenu.find("ul").parent() $headers.each(function(i){var $curobj=$(this) var $subul=$(this).find('ul:eq(0)') this._dimensions={w:this.offsetWidth,h:this.offsetHeight,subulw:$subul.outerWidth(),subulh:$subul.outerHeight()} this.istopheader=$curobj.parents("ul").length==1?true:false $subul.css({top:this.istopheader?this._dimensions.h+"px":0}) $curobj.hover(function(e){var $targetul=$(this).children("ul:eq(0)") this._offsets={left:$(this).offset().left,top:$(this).offset().top} var menuleft=this.istopheader?0:this._dimensions.w menuleft=(this._offsets.left+menuleft+this._dimensions.subulw>$(window).width())?(this.istopheader?-this._dimensions.subulw+this._dimensions.w:-this._dimensions.w):menuleft if($targetul.queue().length<=1) $targetul.css({left:menuleft+"px",width:this._dimensions.subulw+'px'}).fadeIn(slidemenu.animateduration.out)},function(e){var $targetul=$(this).children("ul:eq(0)") $targetul.fadeOut(slidemenu.animateduration.out)}) $curobj.click(function(){$(this).children("ul:eq(0)").hide()})}) $mainmenu.find("ul").css({display:'none',visibility:'visible'})})}} slidemenu.buildmenu("navigation",arrowimages) ;/* jQuery Tools 1.2.5 Tabs- The basics of UI design. NO COPYRIGHTS OR LICENSES. DO WHAT YOU LIKE. http://flowplayer.org/tools/tabs/ Since: November 2008 Date: Wed Sep 22 06:02:10 2010 +0000 */ (function(c){function p(d,b,a){var e=this,l=d.add(this),h=d.find(a.tabs),i=b.jquery?b:d.children(b),j;h.length||(h=d.children());i.length||(i=d.parent().find(b));i.length||(i=c(b));c.extend(this,{click:function(f,g){var k=h.eq(f);if(typeof f=="string"&&f.replace("#","")){k=h.filter("[href*="+f.replace("#","")+"]");f=Math.max(h.index(k),0)}if(a.rotate){var n=h.length-1;if(f<0)return e.click(n,g);if(f>n)return e.click(0,g)}if(!k.length){if(j>=0)return e;f=a.initialIndex;k=h.eq(f)}if(f===j)return e; g=g||c.Event();g.type="onBeforeClick";l.trigger(g,[f]);if(!g.isDefaultPrevented()){o[a.effect].call(e,f,function(){g.type="onClick";l.trigger(g,[f])});j=f;h.removeClass(a.current);k.addClass(a.current);return e}},getConf:function(){return a},getTabs:function(){return h},getPanes:function(){return i},getCurrentPane:function(){return i.eq(j)},getCurrentTab:function(){return h.eq(j)},getIndex:function(){return j},next:function(){return e.click(j+1)},prev:function(){return e.click(j-1)},destroy:function(){h.unbind(a.event).removeClass(a.current); i.find("a[href^=#]").unbind("click.T");return e}});c.each("onBeforeClick,onClick".split(","),function(f,g){c.isFunction(a[g])&&c(e).bind(g,a[g]);e[g]=function(k){k&&c(e).bind(g,k);return e}});if(a.history&&c.fn.history){c.tools.history.init(h);a.event="history"}h.each(function(f){c(this).bind(a.event,function(g){e.click(f,g);return g.preventDefault()})});i.find("a[href^=#]").bind("click.T",function(f){e.click(c(this).attr("href"),f)});if(location.hash&&a.tabs=="a"&&d.find("[href="+location.hash+"]").length)e.click(location.hash); else if(a.initialIndex===0||a.initialIndex>0)e.click(a.initialIndex)}c.tools=c.tools||{version:"1.2.5"};c.tools.tabs={conf:{tabs:"a",current:"current",onBeforeClick:null,onClick:null,effect:"default",initialIndex:0,event:"click",rotate:false,history:false},addEffect:function(d,b){o[d]=b}};var o={"default":function(d,b){this.getPanes().hide().eq(d).show();b.call()},fade:function(d,b){var a=this.getConf(),e=a.fadeOutSpeed,l=this.getPanes();e?l.fadeOut(e):l.hide();l.eq(d).fadeIn(a.fadeInSpeed,b)},slide:function(d, b){this.getPanes().slideUp(100);this.getPanes().eq(d).slideDown(100,b)},ajax:function(d,b){this.getPanes().eq(0).load(this.getTabs().eq(d).attr("href"),b)}},m;c.tools.tabs.addEffect("horizontal",function(d,b){m||(m=this.getPanes().eq(0).width());this.getCurrentPane().animate({width:0},function(){c(this).hide()});this.getPanes().eq(d).animate({width:m},function(){c(this).show();b.call()})});c.fn.tabs=function(d,b){var a=this.data("tabs");if(a){a.destroy();this.removeData("tabs")}if(c.isFunction(b))b= {onBeforeClick:b};b=c.extend({},c.tools.tabs.conf,b);this.each(function(){a=new p(c(this),d,b);c(this).data("tabs",a)});return b.api?a:this}})(jQuery); ;/* Color animation jQuery-plugin http://www.bitstorm.org/jquery/color-animation/ Copyright 2011 Edwin Martin Released under the MIT and GPL licenses. */ (function(d){function i(){var b=d("script:first"),a=b.css("color"),c=false;if(/^rgba/.test(a))c=true;else try{c=a!=b.css("color","rgba(0, 0, 0, 0.5)").css("color");b.css("color",a)}catch(e){}return c}function g(b,a,c){var e="rgb"+(d.support.rgba?"a":"")+"("+parseInt(b[0]+c*(a[0]-b[0]),10)+","+parseInt(b[1]+c*(a[1]-b[1]),10)+","+parseInt(b[2]+c*(a[2]-b[2]),10);if(d.support.rgba)e+=","+(b&&a?parseFloat(b[3]+c*(a[3]-b[3])):1);e+=")";return e}function f(b){var a,c;if(a=/#([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})/.exec(b))c= [parseInt(a[1],16),parseInt(a[2],16),parseInt(a[3],16),1];else if(a=/#([0-9a-fA-F])([0-9a-fA-F])([0-9a-fA-F])/.exec(b))c=[parseInt(a[1],16)*17,parseInt(a[2],16)*17,parseInt(a[3],16)*17,1];else if(a=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(b))c=[parseInt(a[1]),parseInt(a[2]),parseInt(a[3]),1];else if(a=/rgba\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9\.]*)\s*\)/.exec(b))c=[parseInt(a[1],10),parseInt(a[2],10),parseInt(a[3],10),parseFloat(a[4])];return c} d.extend(true,d,{support:{rgba:i()}});var h=["color","backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","outlineColor"];d.each(h,function(b,a){d.fx.step[a]=function(c){if(!c.init){c.a=f(d(c.elem).css(a));c.end=f(c.end);c.init=true}c.elem.style[a]=g(c.a,c.end,c.pos)}});d.fx.step.borderColor=function(b){if(!b.init)b.end=f(b.end);var a=h.slice(2,6);d.each(a,function(c,e){b.init||(b[e]={a:f(d(b.elem).css(e))});b.elem.style[e]=g(b[e].a,b.end,b.pos)});b.init=true}})(jQuery); ;// ColorBox v1.3.19.3 - jQuery lightbox plugin // (c) 2011 Jack Moore - jacklmoore.com // License: http://www.opensource.org/licenses/mit-license.php (function(a,b,c){function Z(c,d,e){var g=b.createElement(c);return d&&(g.id=f+d),e&&(g.style.cssText=e),a(g)}function $(a){var b=y.length,c=(Q+a)%b;return c<0?b+c:c}function _(a,b){return Math.round((/%/.test(a)?(b==="x"?z.width():z.height())/100:1)*parseInt(a,10))}function ab(a){return K.photo||/\.(gif|png|jpe?g|bmp|ico)((#|\?).*)?$/i.test(a)}function bb(){var b,c=a.data(P,e);c==null?(K=a.extend({},d),console&&console.log&&console.log("Error: cboxElement missing settings object")):K=a.extend({},c);for(b in K)a.isFunction(K[b])&&b.slice(0,2)!=="on"&&(K[b]=K[b].call(P));K.rel=K.rel||P.rel||"nofollow",K.href=K.href||a(P).attr("href"),K.title=K.title||P.title,typeof K.href=="string"&&(K.href=a.trim(K.href))}function cb(b,c){a.event.trigger(b),c&&c.call(P)}function db(){var a,b=f+"Slideshow_",c="click."+f,d,e,g;K.slideshow&&y[1]?(d=function(){F.text(K.slideshowStop).unbind(c).bind(j,function(){if(K.loop||y[Q+1])a=setTimeout(W.next,K.slideshowSpeed)}).bind(i,function(){clearTimeout(a)}).one(c+" "+k,e),r.removeClass(b+"off").addClass(b+"on"),a=setTimeout(W.next,K.slideshowSpeed)},e=function(){clearTimeout(a),F.text(K.slideshowStart).unbind([j,i,k,c].join(" ")).one(c,function(){W.next(),d()}),r.removeClass(b+"on").addClass(b+"off")},K.slideshowAuto?d():e()):r.removeClass(b+"off "+b+"on")}function eb(b){U||(P=b,bb(),y=a(P),Q=0,K.rel!=="nofollow"&&(y=a("."+g).filter(function(){var b=a.data(this,e),c;return b&&(c=b.rel||this.rel),c===K.rel}),Q=y.index(P),Q===-1&&(y=y.add(P),Q=y.length-1)),S||(S=T=!0,r.show(),K.returnFocus&&a(P).blur().one(l,function(){a(this).focus()}),q.css({opacity:+K.opacity,cursor:K.overlayClose?"pointer":"auto"}).show(),K.w=_(K.initialWidth,"x"),K.h=_(K.initialHeight,"y"),W.position(),o&&z.bind("resize."+p+" scroll."+p,function(){q.css({width:z.width(),height:z.height(),top:z.scrollTop(),left:z.scrollLeft()})}).trigger("resize."+p),cb(h,K.onOpen),J.add(D).hide(),I.html(K.close).show()),W.load(!0))}function fb(){!r&&b.body&&(Y=!1,z=a(c),r=Z(X).attr({id:e,"class":n?f+(o?"IE6":"IE"):""}).hide(),q=Z(X,"Overlay",o?"position:absolute":"").hide(),s=Z(X,"Wrapper"),t=Z(X,"Content").append(A=Z(X,"LoadedContent","width:0; height:0; overflow:hidden"),C=Z(X,"LoadingOverlay").add(Z(X,"LoadingGraphic")),D=Z(X,"Title"),E=Z(X,"Current"),G=Z(X,"Next"),H=Z(X,"Previous"),F=Z(X,"Slideshow").bind(h,db),I=Z(X,"Close")),s.append(Z(X).append(Z(X,"TopLeft"),u=Z(X,"TopCenter"),Z(X,"TopRight")),Z(X,!1,"clear:left").append(v=Z(X,"MiddleLeft"),t,w=Z(X,"MiddleRight")),Z(X,!1,"clear:left").append(Z(X,"BottomLeft"),x=Z(X,"BottomCenter"),Z(X,"BottomRight"))).find("div div").css({"float":"left"}),B=Z(X,!1,"position:absolute; width:9999px; visibility:hidden; display:none"),J=G.add(H).add(E).add(F),a(b.body).append(q,r.append(s,B)))}function gb(){return r?(Y||(Y=!0,L=u.height()+x.height()+t.outerHeight(!0)-t.height(),M=v.width()+w.width()+t.outerWidth(!0)-t.width(),N=A.outerHeight(!0),O=A.outerWidth(!0),r.css({"padding-bottom":L,"padding-right":M}),G.click(function(){W.next()}),H.click(function(){W.prev()}),I.click(function(){W.close()}),q.click(function(){K.overlayClose&&W.close()}),a(b).bind("keydown."+f,function(a){var b=a.keyCode;S&&K.escKey&&b===27&&(a.preventDefault(),W.close()),S&&K.arrowKey&&y[1]&&(b===37?(a.preventDefault(),H.click()):b===39&&(a.preventDefault(),G.click()))}),a("."+g,b).live("click",function(a){a.which>1||a.shiftKey||a.altKey||a.metaKey||(a.preventDefault(),eb(this))})),!0):!1}var d={transition:"elastic",speed:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,inline:!1,html:!1,iframe:!1,fastIframe:!0,photo:!1,href:!1,title:!1,rel:!1,opacity:.9,preloading:!0,current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",open:!1,returnFocus:!0,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:undefined},e="colorbox",f="cbox",g=f+"Element",h=f+"_open",i=f+"_load",j=f+"_complete",k=f+"_cleanup",l=f+"_closed",m=f+"_purge",n=!a.support.opacity&&!a.support.style,o=n&&!c.XMLHttpRequest,p=f+"_IE6",q,r,s,t,u,v,w,x,y,z,A,B,C,D,E,F,G,H,I,J,K,L,M,N,O,P,Q,R,S,T,U,V,W,X="div",Y;if(a.colorbox)return;a(fb),W=a.fn[e]=a[e]=function(b,c){var f=this;b=b||{},fb();if(gb()){if(!f[0]){if(f.selector)return f;f=a(""),b.open=!0}c&&(b.onComplete=c),f.each(function(){a.data(this,e,a.extend({},a.data(this,e)||d,b))}).addClass(g),(a.isFunction(b.open)&&b.open.call(f)||b.open)&&eb(f[0])}return f},W.position=function(a,b){function i(a){u[0].style.width=x[0].style.width=t[0].style.width=a.style.width,t[0].style.height=v[0].style.height=w[0].style.height=a.style.height}var c=0,d=0,e=r.offset(),g,h;z.unbind("resize."+f),r.css({top:-9e4,left:-9e4}),g=z.scrollTop(),h=z.scrollLeft(),K.fixed&&!o?(e.top-=g,e.left-=h,r.css({position:"fixed"})):(c=g,d=h,r.css({position:"absolute"})),K.right!==!1?d+=Math.max(z.width()-K.w-O-M-_(K.right,"x"),0):K.left!==!1?d+=_(K.left,"x"):d+=Math.round(Math.max(z.width()-K.w-O-M,0)/2),K.bottom!==!1?c+=Math.max(z.height()-K.h-N-L-_(K.bottom,"y"),0):K.top!==!1?c+=_(K.top,"y"):c+=Math.round(Math.max(z.height()-K.h-N-L,0)/2),r.css({top:e.top,left:e.left}),a=r.width()===K.w+O&&r.height()===K.h+N?0:a||0,s[0].style.width=s[0].style.height="9999px",r.dequeue().animate({width:K.w+O,height:K.h+N,top:c,left:d},{duration:a,complete:function(){i(this),T=!1,s[0].style.width=K.w+O+M+"px",s[0].style.height=K.h+N+L+"px",K.reposition&&setTimeout(function(){z.bind("resize."+f,W.position)},1),b&&b()},step:function(){i(this)}})},W.resize=function(a){S&&(a=a||{},a.width&&(K.w=_(a.width,"x")-O-M),a.innerWidth&&(K.w=_(a.innerWidth,"x")),A.css({width:K.w}),a.height&&(K.h=_(a.height,"y")-N-L),a.innerHeight&&(K.h=_(a.innerHeight,"y")),!a.innerHeight&&!a.height&&(A.css({height:"auto"}),K.h=A.height()),A.css({height:K.h}),W.position(K.transition==="none"?0:K.speed))},W.prep=function(b){function g(){return K.w=K.w||A.width(),K.w=K.mw&&K.mw1){typeof K.current=="string"&&E.html(K.current.replace("{current}",Q+1).replace("{total}",g)).show(),G[K.loop||QK.mw&&(a=(R.width-K.mw)/R.width,d()),K.mh&&R.height>K.mh&&(a=(R.height-K.mh)/R.height,d())),K.h&&(R.style.marginTop=Math.max(K.h-R.height,0)/2+"px"),y[1]&&(K.loop||y[Q+1])&&(R.style.cursor="pointer",R.onclick=function(){W.next()}),n&&(R.style.msInterpolationMode="bicubic"),setTimeout(function(){e(R)},1)}),setTimeout(function(){R.src=c},1)):c&&B.load(c,K.data,function(b,c,d){e(c==="error"?Z(X,"Error").html(K.xhrError):a(this).contents())})},W.next=function(){!T&&y[1]&&(K.loop||y[Q+1])&&(Q=$(1),W.load())},W.prev=function(){!T&&y[1]&&(K.loop||Q)&&(Q=$(-1),W.load())},W.close=function(){S&&!U&&(U=!0,S=!1,cb(k,K.onCleanup),z.unbind("."+f+" ."+p),q.fadeTo(200,0),r.stop().fadeTo(300,0,function(){r.add(q).css({opacity:1,cursor:"auto"}).hide(),cb(m),A.remove(),setTimeout(function(){U=!1,cb(l,K.onClosed)},1)}))},W.remove=function(){a([]).add(r).add(q).remove(),r=null,a("."+g).removeData(e).removeClass(g).die()},W.element=function(){return a(P)},W.settings=d})(jQuery,document,this); ;jQuery.easing['jswing']=jQuery.easing['swing'];jQuery.extend(jQuery.easing,{def:'easeOutQuad',swing:function(x,t,b,c,d){return jQuery.easing[jQuery.easing.def](x,t,b,c,d);},easeInQuad:function(x,t,b,c,d){return c*(t/=d)*t+b;},easeOutQuad:function(x,t,b,c,d){return-c*(t/=d)*(t-2)+b;},easeInOutQuad:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t+b;return-c/2*((--t)*(t-2)-1)+b;},easeInCubic:function(x,t,b,c,d){return c*(t/=d)*t*t+b;},easeOutCubic:function(x,t,b,c,d){return c*((t=t/d-1)*t*t+1)+b;},easeInOutCubic:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t+b;return c/2*((t-=2)*t*t+2)+b;},easeInQuart:function(x,t,b,c,d){return c*(t/=d)*t*t*t+b;},easeOutQuart:function(x,t,b,c,d){return-c*((t=t/d-1)*t*t*t-1)+b;},easeInOutQuart:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t+b;return-c/2*((t-=2)*t*t*t-2)+b;},easeInQuint:function(x,t,b,c,d){return c*(t/=d)*t*t*t*t+b;},easeOutQuint:function(x,t,b,c,d){return c*((t=t/d-1)*t*t*t*t+1)+b;},easeInOutQuint:function(x,t,b,c,d){if((t/=d/2)<1)return c/2*t*t*t*t*t+b;return c/2*((t-=2)*t*t*t*t+2)+b;},easeInSine:function(x,t,b,c,d){return-c*Math.cos(t/d*(Math.PI/2))+c+b;},easeOutSine:function(x,t,b,c,d){return c*Math.sin(t/d*(Math.PI/2))+b;},easeInOutSine:function(x,t,b,c,d){return-c/2*(Math.cos(Math.PI*t/d)-1)+b;},easeInExpo:function(x,t,b,c,d){return(t==0)?b:c*Math.pow(2,10*(t/d-1))+b;},easeOutExpo:function(x,t,b,c,d){return(t==d)?b+c:c*(-Math.pow(2,-10*t/d)+1)+b;},easeInOutExpo:function(x,t,b,c,d){if(t==0)return b;if(t==d)return b+c;if((t/=d/2)<1)return c/2*Math.pow(2,10*(t-1))+b;return c/2*(-Math.pow(2,-10*--t)+2)+b;},easeInCirc:function(x,t,b,c,d){return-c*(Math.sqrt(1-(t/=d)*t)-1)+b;},easeOutCirc:function(x,t,b,c,d){return c*Math.sqrt(1-(t=t/d-1)*t)+b;},easeInOutCirc:function(x,t,b,c,d){if((t/=d/2)<1)return-c/2*(Math.sqrt(1-t*t)-1)+b;return c/2*(Math.sqrt(1-(t-=2)*t)+1)+b;},easeInElastic:function(x,t,b,c,d){var s=1.70158;var p=0;var a=c;if(t==0)return b;if((t/=d)==1)return b+c;if(!p)p=d*.3;if(a=1.3?0:1};k.window=function(a){return d(window)._scrollable()};d.fn._scrollable=function(){return this.map(function(){var a=this,i=!a.nodeName||d.inArray(a.nodeName.toLowerCase(),['iframe','#document','html','body'])!=-1;if(!i)return a;var e=(a.contentWindow||a).document||a.ownerDocument||a;return d.browser.safari||e.compatMode=='BackCompat'?e.body:e.documentElement})};d.fn.scrollTo=function(n,j,b){if(typeof j=='object'){b=j;j=0}if(typeof b=='function')b={onAfter:b};if(n=='max')n=9e9;b=d.extend({},k.defaults,b);j=j||b.speed||b.duration;b.queue=b.queue&&b.axis.length>1;if(b.queue)j/=2;b.offset=p(b.offset);b.over=p(b.over);return this._scrollable().each(function(){var q=this,r=d(q),f=n,s,g={},u=r.is('html,body');switch(typeof f){case'number':case'string':if(/^([+-]=)?\d+(\.\d+)?(px|%)?$/.test(f)){f=p(f);break}f=d(f,this);case'object':if(f.is||f.style)s=(f=d(f)).offset()}d.each(b.axis.split(''),function(a,i){var e=i=='x'?'Left':'Top',h=e.toLowerCase(),c='scroll'+e,l=q[c],m=k.max(q,i);if(s){g[c]=s[h]+(u?0:l-r.offset()[h]);if(b.margin){g[c]-=parseInt(f.css('margin'+e))||0;g[c]-=parseInt(f.css('border'+e+'Width'))||0}g[c]+=b.offset[h]||0;if(b.over[h])g[c]+=f[i=='x'?'width':'height']()*b.over[h]}else{var o=f[h];g[c]=o.slice&&o.slice(-1)=='%'?parseFloat(o)/100*m:o}if(/^\d+$/.test(g[c]))g[c]=g[c]<=0?0:Math.min(g[c],m);if(!a&&b.queue){if(l!=g[c])t(b.onAfterFirst);delete g[c]}});t(b.onAfter);function t(a){r.animate(g,j,b.easing,a&&function(){a.call(this,n,b)})}}).end()};k.max=function(a,i){var e=i=='x'?'Width':'Height',h='scroll'+e;if(!d(a).is('html,body'))return a[h]-d(a)[e.toLowerCase()]();var c='client'+e,l=a.ownerDocument.documentElement,m=a.ownerDocument.body;return Math.max(l[h],m[h])-Math.min(l[c],m[c])};function p(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery); ;(function(p,q){var d,l;d=p.jQuery;l=d.ScrollTo=d.ScrollTo||{config:{duration:400,easing:"swing",callback:q,durationMode:"each",offsetTop:0,offsetLeft:0},configure:function(e){d.extend(l.config,e||{});return this},scroll:function(e,c){var a,b,g,f,i,m,j,k,h,n;a=e.pop();b=a.$container;g=b.get(0);f=a.$target;i=d("").css({position:"absolute",top:"0px",left:"0px"});m=b.css("position");b.css("position","relative");i.appendTo(b);a=i.offset().top;a=f.offset().top-a-parseInt(c.offsetTop,10);j=i.offset().left;k=f.offset().left-j-parseInt(c.offsetLeft,10);f=g.scrollTop;j=g.scrollLeft;i.remove();b.css("position",m);h={};n=function(a){0===e.length?"function"===typeof c.callback&&c.callback.apply(this,[a]):l.scroll(e,c);return!0};c.onlyIfOutside&&(i=f+b.height(),m=j+b.width(),f0){wp_admin_height=jQuery("#wpadminbar").height();} jQuery('#page').css('margin-top',header_fixed_height);jQuery('#header.fixed_header').css({'position':'fixed','top':wp_admin_height});} jQuery(window).load(function(){mk_fixed_header()});jQuery(window).on("debouncedresize",function(event){mk_fixed_header()});var side_social_margin=jQuery('#side_social').outerHeight();jQuery('#side_social').css('margin-top',-(side_social_margin/2));var timer;generalSetSize();jQuery(window).resize(function(){clearTimeout(timer);setTimeout(generalSetSize,100);}) jQuery('#responsive_navigation select').customSelect();jQuery(".tabs_container, .vertical_tabs_container").each(function(){jQuery("ul.tabs, ul.vertical_tabs",this).tabs("div.panes > div, div.vertical_panes > div",{tabs:'li',effect:'fade',fadeOutSpeed:-400});});jQuery.tools.tabs.addEffect("slide",function(i,done){this.getPanes().slideUp();this.getPanes().eq(i).slideDown(function(){done.call();});});jQuery(".accordion").each(function(){var $initialIndex=jQuery(this).attr('data-initialIndex');if($initialIndex==undefined){$initialIndex=0;} jQuery(this).tabs("div.pane",{tabs:'.tab',effect:'slide',initialIndex:$initialIndex});});jQuery(".toggle_title, .bookmark_title").toggle(function(){jQuery(this).addClass('toggle_active');jQuery(this).siblings('.toggle_content, #bookmark ul').slideDown("fast");},function(){jQuery(this).removeClass('toggle_active');jQuery(this).siblings('.toggle_content, #bookmark ul').slideUp("fast");});if($('.newspaper').length>0){var $container=$('.newspaper');$container.isotope({masonryHorizontal:{rowHeight:360}});} if($('#portfolios').length>0){var $container=$('.portfolio_container');$container.isotope({masonryHorizontal:{rowHeight:360}});$('.filter_portfolio a').click(function(){var $this=$(this);if($this.hasClass('.current')){return false;} var $optionSet=$this.parents('.filter_portfolio');$optionSet.find('.current').removeClass('current');$this.addClass('current');var selector=$(this).attr('data-filter');$container.isotope({filter:selector});$container.data('isotope').$filteredAtoms.each(function(){});return false;});} jQuery("#portfolios").preloader({delay:200,imgSelector:'.portfolio_item_wrapper img',beforeShow:function(){jQuery(this).closest('.portfolio_item_wrapper img').css('visibility','hidden');},afterShow:function(){var container=jQuery(this).closest('.portfolio_item_wrapper img').css('visibility','visible');}});jQuery(".image_container").preloader({delay:300,imgSelector:'.image_frame img',beforeShow:function(){jQuery(this).closest('.image_frame img').css('visibility','hidden');},afterShow:function(){jQuery(this).closest('.image_frame').css('background-image','none');var image=jQuery(this).closest('.image_frame img').css('visibility','visible').closest('a');if($('.newspaper').length>0){jQuery('.newspaper.blog_loop').isotope({});}}});jQuery(".contact_info .icon_email").each(function(){jQuery(this).attr('href',jQuery(this).attr('href').replace("*","@"));jQuery(this).html(jQuery(this).html().replace("*","@"));});if(jQuery.tools.validator!=undefined){jQuery.tools.validator.addEffect("contact_form",function(errors,event){jQuery.each(errors,function(index,error){var input=error.input;input.addClass('invalid');});},function(inputs){inputs.removeClass('invalid');});jQuery('.contact_form').validator({effect:'contact_form'}).submit(function(e){var form=jQuery(this);if(!e.isDefaultPrevented()){jQuery('.contact_loading').fadeIn('slow');jQuery.post(this.action,{'to':jQuery('input[name="contact_to"]').val().replace("*","@"),'name':jQuery('input[name="contact_name"]').val(),'email':jQuery('input[name="contact_email"]').val(),'content':jQuery('textarea[name="contact_content"]').val()},function(data){form.fadeIn('fast',function(){jQuery('.contact_loading').fadeOut('slow');jQuery(this).siblings('.success_message').fadeIn('slow').delay(4000).fadeOut();jQuery(this).find('input, textarea').val("");});});e.preventDefault();}});}});(function($){$.fn.preloader=function(options){var settings=$.extend({},$.fn.preloader.defaults,options);return this.each(function(){settings.beforeShowAll.call(this);var imageHolder=$(this);var images=imageHolder.find(settings.imgSelector).css({opacity:0,visibility:'hidden'});var count=images.length;var showImage=function(image,imageHolder){if(image.data.source!=undefined){imageHolder=image.data.holder;image=image.data.source;};count--;if(settings.delay<=0){image.css('visibility','visible').animate({opacity:1},settings.animSpeed,function(){settings.afterShow.call(this)});} if(count==0){imageHolder.removeData('count');if(settings.delay<=0){settings.afterShowAll.call(this);}else{if(settings.gradualDelay){images.each(function(i,e){var image=$(this);setTimeout(function(){image.css('visibility','visible').animate({opacity:1},settings.animSpeed,function(){settings.afterShow.call(this)});},settings.delay*(i+1));});setTimeout(function(){settings.afterShowAll.call(imageHolder[0])},settings.delay*images.length+settings.animSpeed);}else{setTimeout(function(){images.each(function(i,e){$(this).css('visibility','visible').animate({opacity:1},settings.animSpeed,function(){settings.afterShow.call(this)});});setTimeout(function(){settings.afterShowAll.call(imageHolder[0])},settings.animSpeed);},settings.delay);}}}};if(count==0){settings.afterShowAll.call(this);}else{images.each(function(i){settings.beforeShow.call(this);image=$(this);if(this.complete==true){showImage(image,imageHolder);}else{image.bind('error load',{source:image,holder:imageHolder},showImage);if($.browser.opera||($.browser.msie&&parseInt(jQuery.browser.version,10)==9&&document.documentMode==9)){image.trigger("load");}}});}});};jQuery.fn.preloader.defaults={delay:1000,gradualDelay:true,imgSelector:'img',animSpeed:500,beforeShowAll:function(){},beforeShow:function(){},afterShow:function(){},afterShowAll:function(){}};jQuery(document).ready(function(){jQuery('#hc_carousel').find('.thumbnail').each(function(){var desc_height=jQuery(this).find('.carousel-extra-info').outerHeight();jQuery(this).find('.carousel-extra-info').css({'display':'block','bottom':-(desc_height+10)});jQuery(this).hover(function(){jQuery(this).find('.carousel-extra-info').stop().animate({bottom:'3px'},{queue:false,duration:500,easing:'easeInOutExpo'});jQuery(this).find('.carousel-inner-shadow').fadeIn();},function(){jQuery(this).find('.carousel-extra-info').stop().animate({bottom:-(desc_height+10)},{queue:false,duration:500,easing:'easeInOutExpo'});jQuery(this).find('.carousel-inner-shadow').fadeOut();});});jQuery(window).scroll(function(){if(jQuery(this).scrollTop()>300){jQuery('#top-link').fadeIn();}else{jQuery('#top-link').fadeOut();}});jQuery('#top-link').click(function(){jQuery("html, body").animate({scrollTop:0},1000);return false;});});jQuery('#responsive_navigation select').prepend('');jQuery("#responsive_navigation select").change(function(){window.location=jQuery(this).find("option:selected").val();});if(jQuery('.mk-body-parallax').length>0){jQuery('body').parallax("50%",body_parallax_speed);} if(jQuery('.mk-page-parallax').length>0){jQuery('#page').parallax("50%",page_parallax_speed);} if(jQuery('.mk-nicescroll').length>0&&jQuery('.mk-flexsldier-slideshow').length==0){jQuery('html').niceScroll({"cursorwidth":8,"cursorcolor":"#464646","bouncescroll":true});} jQuery('.mk-scroll-top').on('click',function(){jQuery('body').ScrollTo({duration:3000,easing:'easeOutQuart',durationMode:'all'});})})(jQuery);function hover_effect(){jQuery('.image_container a.hover_effect').hover(function(){jQuery(".hover_icon",this).stop().animate({'right':0,'bottom':0},'slow','easeInOutExpo');jQuery(".image_overlay",this).stop().animate({opacity:'1'},"slow");},function(){jQuery(".hover_icon",this).stop().animate({'right':-43,'bottom':-43},'slow','easeInOutExpo');jQuery(".image_overlay",this).stop().animate({opacity:'0'},"slow");})} hover_effect();function portfolio_hover(){jQuery('.portfolio_item').hover(function(){jQuery(".hover_icon",this).stop().animate({'right':0,'bottom':0},'slow','easeInOutExpo');jQuery(".portfolio_item_details",this).stop().animate({opacity:'1'},"slow");jQuery(".portfolio_overlay",this).stop().animate({opacity:'0.8'},"slow");},function(){jQuery(".hover_icon",this).stop().animate({'right':-43,'bottom':-43},'slow','easeInOutExpo');jQuery(".portfolio_item_details",this).stop().animate({opacity:'0'},"slow");jQuery(".portfolio_overlay",this).stop().animate({opacity:'0'},"slow");})} portfolio_hover();var enable_lightbox=function(parent){jQuery(".lightbox").each(function(){jQuery(this).colorbox({opacity:0.7,maxWidth:"95%",maxHeight:"90%",current:"",onComplete:function(){if(typeof Cufon!=="undefined"){Cufon.replace('#cboxTitle');}},onCleanup:function(){jQuery("#cboxLoadedContent").html('');jQuery('.portfolio_arrow_icon_newspaper').css({'right':0});}});});jQuery(".video_lightbox").each(function(){var $height,$width;var $iframe=jQuery(this).attr('data-video');if($iframe==undefined||$iframe=='false'){$iframe=false;}else{$iframe=true;$width=600;$height=480;} jQuery(this).colorbox({opacity:0.7,innerWidth:$width,innerHeight:$height,iframe:$iframe,current:"",onComplete:function(){if(typeof Cufon!=="undefined"){Cufon.replace('#cboxTitle');}},onCleanup:function(){jQuery("#cboxLoadedContent").html('');jQuery('.portfolio_arrow_icon_newspaper').css({'right':0});}});});};enable_lightbox(document);function generalSetSize(){if(jQuery(window).width()<768){jQuery('body').attr('id','iphoneHome');} else if(jQuery(window).width()<1024){jQuery('body').attr('id','iPadHome');} else{jQuery('body').attr('id','home');}} jQuery(window).load(function(){jQuery(".grascale_enabled img").animate({opacity:1},500);jQuery('.grascale_enabled img').each(function(){var el=jQuery(this);el.css({"position":"absolute"}).wrap("
").clone().addClass('img_grayscale').css({"position":"absolute","z-index":"180","opacity":"0"}).insertBefore(el).queue(function(){var el=jQuery(this);el.parent().css({"width":this.width,"height":this.height});el.dequeue();});this.src=grayscale(this.src);});});function grayscale(src){var canvas=document.createElement('canvas');var ctx=canvas.getContext('2d');var imgObj=new Image();imgObj.src=src;canvas.width=imgObj.width;canvas.height=imgObj.height;ctx.drawImage(imgObj,0,0);var imgPixels=ctx.getImageData(0,0,canvas.width,canvas.height);for(var y=0;y6)){return this.each(function(){var currentSelected=$(this).find(':selected');$(this).after(''+currentSelected.text()+'').css({position:'absolute',opacity:0,fontSize:$(this).next().css('font-size')});var selectBoxSpan=$(this).next();var selectBoxWidth=parseInt($(this).width())-parseInt(selectBoxSpan.css('padding-left'))-parseInt(selectBoxSpan.css('padding-right'));var selectBoxSpanInner=selectBoxSpan.find(':first-child');selectBoxSpan.css({display:'inline-block'});selectBoxSpanInner.css({width:selectBoxWidth,display:'inline-block'});var selectBoxHeight=parseInt(selectBoxSpan.height())+parseInt(selectBoxSpan.css('padding-top'))+parseInt(selectBoxSpan.css('padding-bottom'));$(this).height(selectBoxHeight).change(function(){selectBoxSpanInner.text($(this).find(':selected').text()).parent().addClass('changed');});});}}});})(jQuery);(function($){var $event=$.event,$special,resizeTimeout;$special=$event.special.debouncedresize={setup:function(){$(this).on("resize",$special.handler);},teardown:function(){$(this).off("resize",$special.handler);},handler:function(event,execAsap){var context=this,args=arguments,dispatch=function(){event.type="debouncedresize";$event.dispatch.apply(context,args);};if(resizeTimeout){clearTimeout(resizeTimeout);} execAsap?dispatch():resizeTimeout=setTimeout(dispatch,$special.threshold);},threshold:150};})(jQuery); ;!function(d,l){"use strict";var e=!1,n=!1;if(l.querySelector)if(d.addEventListener)e=!0;if(d.wp=d.wp||{},!d.wp.receiveEmbedMessage)if(d.wp.receiveEmbedMessage=function(e){var t=e.data;if(t.secret||t.message||t.value)if(!/[^a-zA-Z0-9]/.test(t.secret)){for(var r,a,i,s=l.querySelectorAll('iframe[data-secret="'+t.secret+'"]'),n=l.querySelectorAll('blockquote[data-secret="'+t.secret+'"]'),o=new RegExp("^https?:$","i"),c=0;c