/* CMSMasters Cleanple Theme v1.0 */

/*
 * Open source under the BSD License. 
 * 
 * Copyright (c) 2008 George McGinley Smith
*/
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}('h.i[\'E\']=h.i[\'y\'];h.F(h.i,{z:\'A\',y:9(x,t,b,c,d){6 h.i[h.i.z](x,t,b,c,d)},G:9(x,t,b,c,d){6 c*(t/=d)*t+b},A:9(x,t,b,c,d){6-c*(t/=d)*(t-2)+b},H:9(x,t,b,c,d){e((t/=d/2)<1)6 c/2*t*t+b;6-c/2*((--t)*(t-2)-1)+b},I:9(x,t,b,c,d){6 c*(t/=d)*t*t+b},J:9(x,t,b,c,d){6 c*((t=t/d-1)*t*t+1)+b},K:9(x,t,b,c,d){e((t/=d/2)<1)6 c/2*t*t*t+b;6 c/2*((t-=2)*t*t+2)+b},L:9(x,t,b,c,d){6 c*(t/=d)*t*t*t+b},M:9(x,t,b,c,d){6-c*((t=t/d-1)*t*t*t-1)+b},N:9(x,t,b,c,d){e((t/=d/2)<1)6 c/2*t*t*t*t+b;6-c/2*((t-=2)*t*t*t-2)+b},O:9(x,t,b,c,d){6 c*(t/=d)*t*t*t*t+b},P:9(x,t,b,c,d){6 c*((t=t/d-1)*t*t*t*t+1)+b},Q:9(x,t,b,c,d){e((t/=d/2)<1)6 c/2*t*t*t*t*t+b;6 c/2*((t-=2)*t*t*t*t+2)+b},R:9(x,t,b,c,d){6-c*8.B(t/d*(8.g/2))+c+b},S:9(x,t,b,c,d){6 c*8.n(t/d*(8.g/2))+b},T:9(x,t,b,c,d){6-c/2*(8.B(8.g*t/d)-1)+b},U:9(x,t,b,c,d){6(t==0)?b:c*8.j(2,10*(t/d-1))+b},V:9(x,t,b,c,d){6(t==d)?b+c:c*(-8.j(2,-10*t/d)+1)+b},W:9(x,t,b,c,d){e(t==0)6 b;e(t==d)6 b+c;e((t/=d/2)<1)6 c/2*8.j(2,10*(t-1))+b;6 c/2*(-8.j(2,-10*--t)+2)+b},X:9(x,t,b,c,d){6-c*(8.o(1-(t/=d)*t)-1)+b},Y:9(x,t,b,c,d){6 c*8.o(1-(t=t/d-1)*t)+b},Z:9(x,t,b,c,d){e((t/=d/2)<1)6-c/2*(8.o(1-t*t)-1)+b;6 c/2*(8.o(1-(t-=2)*t)+1)+b},11:9(x,t,b,c,d){f s=1.l;f p=0;f a=c;e(t==0)6 b;e((t/=d)==1)6 b+c;e(!p)p=d*.3;e(a<8.r(c)){a=c;f s=p/4}m f s=p/(2*8.g)*8.u(c/a);6-(a*8.j(2,10*(t-=1))*8.n((t*d-s)*(2*8.g)/p))+b},12:9(x,t,b,c,d){f s=1.l;f p=0;f a=c;e(t==0)6 b;e((t/=d)==1)6 b+c;e(!p)p=d*.3;e(a<8.r(c)){a=c;f s=p/4}m f s=p/(2*8.g)*8.u(c/a);6 a*8.j(2,-10*t)*8.n((t*d-s)*(2*8.g)/p)+c+b},13:9(x,t,b,c,d){f s=1.l;f p=0;f a=c;e(t==0)6 b;e((t/=d/2)==2)6 b+c;e(!p)p=d*(.3*1.5);e(a<8.r(c)){a=c;f s=p/4}m f s=p/(2*8.g)*8.u(c/a);e(t<1)6-.5*(a*8.j(2,10*(t-=1))*8.n((t*d-s)*(2*8.g)/p))+b;6 a*8.j(2,-10*(t-=1))*8.n((t*d-s)*(2*8.g)/p)*.5+c+b},14:9(x,t,b,c,d,s){e(s==v)s=1.l;6 c*(t/=d)*t*((s+1)*t-s)+b},15:9(x,t,b,c,d,s){e(s==v)s=1.l;6 c*((t=t/d-1)*t*((s+1)*t+s)+1)+b},16:9(x,t,b,c,d,s){e(s==v)s=1.l;e((t/=d/2)<1)6 c/2*(t*t*(((s*=(1.C))+1)*t-s))+b;6 c/2*((t-=2)*t*(((s*=(1.C))+1)*t+s)+2)+b},D:9(x,t,b,c,d){6 c-h.i.w(x,d-t,0,c,d)+b},w:9(x,t,b,c,d){e((t/=d)<(1/2.k)){6 c*(7.q*t*t)+b}m e(t<(2/2.k)){6 c*(7.q*(t-=(1.5/2.k))*t+.k)+b}m e(t<(2.5/2.k)){6 c*(7.q*(t-=(2.17/2.k))*t+.18)+b}m{6 c*(7.q*(t-=(2.19/2.k))*t+.1a)+b}},1b:9(x,t,b,c,d){e(t<d/2)6 h.i.D(x,t*2,0,c,d)*.5+b;6 h.i.w(x,t*2-d,0,c,d)*.5+c*.5+b}});',62,74,'||||||return||Math|function|||||if|var|PI|jQuery|easing|pow|75|70158|else|sin|sqrt||5625|abs|||asin|undefined|easeOutBounce||swing|def|easeOutQuad|cos|525|easeInBounce|jswing|extend|easeInQuad|easeInOutQuad|easeInCubic|easeOutCubic|easeInOutCubic|easeInQuart|easeOutQuart|easeInOutQuart|easeInQuint|easeOutQuint|easeInOutQuint|easeInSine|easeOutSine|easeInOutSine|easeInExpo|easeOutExpo|easeInOutExpo|easeInCirc|easeOutCirc|easeInOutCirc||easeInElastic|easeOutElastic|easeInOutElastic|easeInBack|easeOutBack|easeInOutBack|25|9375|625|984375|easeInOutBounce'.split('|'),0,{}));

var Froogaloop=function(){function d(a,b,c){c?(e[c]||(e[c]={}),e[c][a]=b):e[a]=b}function c(a){if(a.origin!=playerDomain)return!1;var b=JSON.parse(a.data);a=b.value;var c=b.data,d=d==""?null:b.player_id;b=d?e[d][b.event||b.method]:e[b.event||b.method];var f=[];if(!b)return!1;a!==void 0&&f.push(a);c&&f.push(c);d&&f.push(d);return f.length>0?b.apply(null,f):b.call()}function b(a,b,c){if(!c.contentWindow.postMessage)return!1;var d=c.getAttribute("src").split("?")[0];a=JSON.stringify({method:a,value:b});c.contentWindow.postMessage(a,d)}function a(b){return new a.fn.init(b)}var e={},f=!1;a.fn=a.prototype={playerDomain:"",element:null,init:function(a){typeof a==="string"&&(a=document.getElementById(a));this.element=a;return this},api:function(a,c){if(!this.element||!a)return!1;var e=this.element,f=e.id!=""?e.id:null,g=!c||!c.constructor||!c.call||!c.apply?c:null,i=c&&c.constructor&&c.call&&c.apply?c:null;i&&d(a,i,f);b(a,g,e);return this},addEvent:function(a,e){if(!this.element)return!1;var g=this.element;d(a,e,g.id!=""?g.id:null);a!="ready"&&b("addEventListener",a,g);if(f)return this;g=g.getAttribute("src").split("/");for(var l="",m=0,n=g.length;m<n;m++){if(m<3)l+=g[m];else break;m<2&&(l+="/")}playerDomain=l;window.addEventListener?window.addEventListener("message",c,!1):window.attachEvent("onmessage",c,!1);f=!0;return this},removeEvent:function(a){if(!this.element)return!1;var c=this.element,d;a:{if((d=c.id!=""?c.id:null)&&e[d]){if(!e[d][a]){d=!1;break a}e[d][a]=null}else{if(!e[a]){d=!1;break a}e[a]=null}d=!0}a!="ready"&&d&&b("removeEventListener",a,c)}};a.fn.init.prototype=a.fn;return window.Froogaloop=window.$f=a}();



/*
 * Copyright (c) 2008 Joel Birch
 * 
 * Dual licensed under the MIT and GPL licenses:
 * 	http://www.opensource.org/licenses/mit-license.php
 * 	http://www.gnu.org/licenses/gpl.html
 */
eval(function(a,b,c,d,e,f){e=function(a){return(a<b?"":e(parseInt(a/b)))+((a=a%b)>35?String.fromCharCode(a+29):a.toString(36))};if(!"".replace(/^/,String)){while(c--)f[e(c)]=d[c]||e(c);d=[function(a){return f[a]}];e=function(){return"\\w+"};c=1}while(c--)if(d[c])a=a.replace(new RegExp("\\b"+e(c)+"\\b","g"),d[c]);return a}(";(2($){$.k.z=2(d){4 e=$.k.z,c=e.c,$N=$(['<O 1k=\"',c.P,'\"> &#1l;</O>'].g('')),q=2(){4 a=$(3),l=A(a);Q(l.B);a.R().1m().r()},C=2(){4 a=$(3),l=A(a),o=e.9;Q(l.B);l.B=1n(2(){o.D=($.1o(a[0],o.$m)>-1);a.r();t(o.$m.E&&a.F(['h.',o.j].g('')).E<1){q.8(o.$m)}},o.S)},A=2(a){4 b=a.F(['5.',c.G,':T'].g(''))[0];e.9=e.o[b.U];u b},V=2(a){a.v(c.W).1p($N.1q())};u 3.n(2(){4 s=3.U=e.o.E;4 o=$.X({},e.Y,d);o.$m=$('h.'+o.H,3).1r(0,o.Z).n(2(){$(3).v([o.j,c.I].g(' ')).1s('h:10(5)').11(o.H)});e.o[s]=e.9=o;$('h:10(5)',3)[($.k.12&&!o.13)?'12':'1t'](q,C).n(2(){t(o.14)V($('>a:T-1u',3))}).w('.'+c.I).r();4 b=$('a',3);b.n(2(i){4 a=b.15(i).F('h');b.15(i).1v(2(){q.8(a)}).1w(2(){C.8(a)})});o.16.8(3)}).n(2(){4 a=[c.G];t(e.9.J&&!($.x.17&&$.x.18<7))a.1x(c.y);$(3).v(a.g(' '))})};4 f=$.k.z;f.o=[];f.9={};f.K=2(){4 o=f.9;t($.x.17&&$.x.18>6&&o.J&&o.L.19!=1y)3.1z(f.c.y+'-1a')};f.c={I:'p-1A',G:'p-1B-1C',W:'p-1D-5',P:'p-1E-1F',y:'p-1G'};f.Y={j:'1H',H:'1I',Z:1,S:1J,L:{19:'1K'},1b:'1L',14:M,J:M,13:1c,16:2(){},1d:2(){},1e:2(){},1f:2(){}};$.k.X({r:2(){4 o=f.9,w=(o.D===M)?o.$m:'';o.D=1c;4 a=$(['h.',o.j].g(''),3).1M(3).w(w).11(o.j).1g('>5').1N().1h('1i','1j');o.1f.8(a);u 3},R:2(){4 o=f.9,1O=f.c.y+'-1a',$5=3.v(o.j).1g('>5:1j').1h('1i','1P');f.K.8($5);o.1d.8($5);$5.1Q(o.L,o.1b,2(){f.K.8($5);o.1e.8($5)});u 3}})})(1R);",62,116,"||function|this|var|ul|||call|op|||||||join|li||hoverClass|fn|menu|path|each||sf|over|hideSuperfishUl||if|return|addClass|not|browser|shadowClass|superfish|getMenu|sfTimer|out|retainPath|length|parents|menuClass|pathClass|bcClass|dropShadows|IE7fix|animation|true|arrow|span|arrowClass|clearTimeout|showSuperfishUl|delay|first|serial|addArrow|anchorClass|extend|defaults|pathLevels|has|removeClass|hoverIntent|disableHI|autoArrows|eq|onInit|msie|version|opacity|off|speed|false|onBeforeShow|onShow|onHide|find|css|visibility|hidden|class|187|siblings|setTimeout|inArray|append|clone|slice|filter|hover|child|focus|blur|push|undefined|toggleClass|breadcrumb|js|enabled|with|sub|indicator|shadow|sfHover|overideThisToUse|800|show|normal|add|hide|sh|visible|animate|jQuery".split("|"),0,{}));

eval(function(a,b,c,d,e,f){e=function(a){return(a<b?"":e(parseInt(a/b)))+((a=a%b)>35?String.fromCharCode(a+29):a.toString(36))};if(!"".replace(/^/,String)){while(c--)f[e(c)]=d[c]||e(c);d=[function(a){return f[a]}];e=function(){return"\\w+"};c=1}while(c--)if(d[c])a=a.replace(new RegExp("\\b"+e(c)+"\\b","g"),d[c]);return a}(";(3($){$.5.6=3(k){1 l=$.r({},$.5.6.s,k);G 7.8(3(){1 h=$(7);1 o=$.H?$.r({},l,h.I()):l;1 j=$('<t J=\"u-v\">&#K;</t>').2({'L':0,'M':'N','O':'-P','4':'w'}).Q(h).4();$('#u-v').R();$m=h.S('x');$m.8(3(i){1 c=$m.T(i);1 d=c.y();1 e=d.y('a');1 f=d.2('z-A','U').2('n');1 g=c.B(d).B(e).2({'n':'V','4':'w'}).C().C()[0].W/j;g+=o.D;E(g>o.p){g=o.p}X E(g<o.q){g=o.q}g+='Y';c.2('4',g);d.2({'n':f,'4':'Z%','z-A':'10'}).8(3(){1 a=$('>x',7);1 b=a.2('F')!==11?'F':'12';a.2(b,g)})})})};$.5.6.s={q:9,p:13,D:0}})(14);",62,67,"|var|css|function|width|fn|supersubs|this|each||||||||||||||ULs|float||maxWidth|minWidth|extend|defaults|li|menu|fontsize|auto|ul|children|white|space|add|end|extraWidth|if|left|return|meta|data|id|8212|padding|position|absolute|top|999em|appendTo|remove|find|eq|nowrap|none|clientWidth|else|em|100|normal|undefined|right|25|jQuery".split("|"),0,{}));

eval(function(a,b,c,d,e,f){e=function(a){return(a<b?"":e(parseInt(a/b)))+((a=a%b)>35?String.fromCharCode(a+29):a.toString(36))};if(!"".replace(/^/,String)){while(c--)f[e(c)]=d[c]||e(c);d=[function(a){return f[a]}];e=function(){return"\\w+"};c=1}while(c--)if(d[c])a=a.replace(new RegExp("\\b"+e(c)+"\\b","g"),d[c]);return a}('(3($){$.I.J=3(f,g){4 c={u:7,o:K,v:0};c=$.w(c,g?{x:f,y:g}:f);4 d,8,9,l;4 h=3(a){d=a.z;8=a.A};4 i=3(a,b){b.2=q(b.2);5((B.C(9-d)+B.C(l-8))<c.u){$(b).D("r",h);b.m=1;n c.x.E(b,[a])}F{9=d;l=8;b.2=s(3(){i(a,b)},c.o)}};4 j=3(a,b){b.2=q(b.2);b.m=0;n c.y.E(b,[a])};4 k=3(e){4 p=(e.G=="t"?e.L:e.M)||e.N;O(p&&p!=6){P{p=p.Q}R(e){p=6}}5(p==6){n S}4 a=H.w({},e);4 b=6;5(b.2){b.2=q(b.2)}5(e.G=="t"){9=a.z;l=a.A;$(b).T("r",h);5(b.m!=1){b.2=s(3(){i(a,b)},c.o)}}F{$(b).D("r",h);5(b.m==1){b.2=s(3(){j(a,b)},c.v)}}};n 6.t(k).U(k)}})(H);',57,57,"||hoverIntent_t|function|var|if|this||cY|pX||||||||||||pY|hoverIntent_s|return|interval||clearTimeout|mousemove|setTimeout|mouseover|sensitivity|timeout|extend|over|out|pageX|pageY|Math|abs|unbind|apply|else|type|jQuery|fn|hoverIntent|100|fromElement|toElement|relatedTarget|while|try|parentNode|catch|false|bind|mouseout".split("|"),0,{}));

jQuery(document).ready(function(){
    jQuery('ul#navigation').superfish({ 
        delay:200, 
        animation:{
            opacity:'show', 
            height:'show'
        }, 
        speed:'fast', 
        autoArrows:false, 
        dropShadows:false 
    });
	
    jQuery('#header .navigation ul').superfish({ 
        delay:200, 
        animation:{
            opacity:'show', 
            height:'show'
        }, 
        speed:'fast', 
        autoArrows:false, 
        dropShadows:false 
    });
}); 


/*
 * Slides, A Slideshow Plugin for jQuery
 * By: Nathan Searles, http://nathansearles.com
 * Updated: March 7th, 2011
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 */
(function(a){a.fn.slides=function(b){b=a.extend({},a.fn.slides.option,b);return this.each(function(){function z(){if(b.pause){clearTimeout(c.data("pause"));clearInterval(c.data("interval"));v=setTimeout(function(){clearTimeout(c.data("pause"));w=setInterval(function(){x("next",j)},b.play);c.data("interval",w)},b.pause);c.data("pause",v)}else{y()}}function y(){clearInterval(c.data("interval"))}function x(h,i,j){if(!q&&p){q=true;b.animationStart(o+1);switch(h){case"next":m=o;l=o+1;l=e===l?0:l;s=f*2;h=-f*2;o=l;break;case"prev":m=o;l=o-1;l=l===-1?e-1:l;s=0;h=0;o=l;break;case"pagination":l=parseInt(j,10);m=a("."+b.paginationClass+" li.current a",c).attr("href").match("[^#/]+$");if(l>m){s=f*2;h=-f*2}else{s=0;h=0}o=l;break}if(i==="fade"){if(b.crossfade){d.children(":eq("+l+")",c).css({zIndex:10}).fadeIn(b.fadeSpeed,b.fadeEasing,function(){if(b.autoHeight){d.animate({height:d.children(":eq("+l+")",c).outerHeight()},b.autoHeightSpeed,function(){d.children(":eq("+m+")",c).css({display:"none",zIndex:0});d.children(":eq("+l+")",c).css({zIndex:0});b.animationComplete(l+1);q=false})}else{d.children(":eq("+m+")",c).css({display:"none",zIndex:0});d.children(":eq("+l+")",c).css({zIndex:0});b.animationComplete(l+1);q=false}})}else{d.children(":eq("+m+")",c).fadeOut(b.fadeSpeed,b.fadeEasing,function(){if(b.autoHeight){d.animate({height:d.children(":eq("+l+")",c).outerHeight()},b.autoHeightSpeed,function(){d.children(":eq("+l+")",c).fadeIn(b.fadeSpeed,b.fadeEasing)})}else{d.children(":eq("+l+")",c).fadeIn(b.fadeSpeed,b.fadeEasing,function(){if(a.browser.msie){a(this).get(0).style.removeAttribute("filter")}})}b.animationComplete(l+1);q=false})}}else{d.children(":eq("+l+")").css({left:s,display:"block"});if(b.autoHeight){d.animate({left:h,height:d.children(":eq("+l+")").outerHeight()},b.slideSpeed,b.slideEasing,function(){d.css({left:-f});d.children(":eq("+l+")").css({left:f,zIndex:5});d.children(":eq("+m+")").css({left:f,display:"none",zIndex:0});b.animationComplete(l+1);q=false})}else{d.animate({left:h},b.slideSpeed,b.slideEasing,function(){d.css({left:-f});d.children(":eq("+l+")").css({left:f,zIndex:5});d.children(":eq("+m+")").css({left:f,display:"none",zIndex:0});b.animationComplete(l+1);q=false})}}if(b.pagination){a("."+b.paginationClass+" li.current",c).removeClass("current");a("."+b.paginationClass+" li:eq("+l+")",c).addClass("current")}}}a("."+b.container,a(this)).children().wrapAll('<div class="slides_control"/>');var c=a(this),d=a(".slides_control",c),e=d.children().size(),f=d.children().outerWidth(),h=d.children().outerHeight(),i=b.start-1,j=b.effect.indexOf(",")<0?b.effect:b.effect.replace(" ","").split(",")[0],k=b.effect.indexOf(",")<0?j:b.effect.replace(" ","").split(",")[1],l=0,m=0,n=0,o=0,p,q,r,s,t,u,v,w;if(e<2){return}if(i<0){i=0}if(i>e){i=e-1}if(b.start){o=i}if(b.randomize){d.randomize()}a("."+b.container,c).css({overflow:"hidden",position:"relative"});d.children().css({position:"absolute",top:0,left:d.children().outerWidth(),zIndex:0,display:"none"});d.css({position:"relative",width:f*3,height:h,left:-f});a("."+b.container,c).css({display:"block"});if(b.autoHeight){d.children().css({height:"auto"});d.animate({height:d.children(":eq("+i+")").outerHeight()},b.autoHeightSpeed)}if(b.preload&&d.find("img").length){a("."+b.container,c).css({background:"url("+b.preloadImage+") no-repeat 50% 50%"});var A=d.find("img:eq("+i+")").attr("src")+"?"+(new Date).getTime();if(a("img",c).parent().attr("class")!="slides_control"){u=d.children(":eq(0)")[0].tagName.toLowerCase()}else{u=d.find("img:eq("+i+")")}d.find("img:eq("+i+")").attr("src",A).load(function(){d.find(u+":eq("+i+")").fadeIn(b.fadeSpeed,b.fadeEasing,function(){a(this).css({zIndex:5});a("."+b.container,c).css({background:""});p=true;b.slidesLoaded()})})}else{d.children(":eq("+i+")").fadeIn(b.fadeSpeed,b.fadeEasing,function(){p=true;b.slidesLoaded()})}if(b.bigTarget){d.children().css({cursor:"pointer"});d.children().click(function(){x("next",j);return false})}if(b.hoverPause&&b.play){d.bind("mouseover",function(){y()});d.bind("mouseleave",function(){z()})}if(b.generateNextPrev){a("."+b.container,c).after('<a href="#" class="'+b.prev+'">Prev</a>');a("."+b.prev,c).after('<a href="#" class="'+b.next+'">Next</a>')}a("."+b.next,c).click(function(a){a.preventDefault();if(b.play){z()}x("next",j)});a("."+b.prev,c).click(function(a){a.preventDefault();if(b.play){z()}x("prev",j)});if(b.generatePagination){c.append("<ul class="+b.paginationClass+"></ul>");d.children().each(function(){a("."+b.paginationClass,c).append('<li><a href="#'+n+'">'+(n+1)+"</a></li>");n++})}else{a("."+b.paginationClass+" li a",c).each(function(){a(this).attr("href","#"+n);n++})}a("."+b.paginationClass+" li:eq("+i+")",c).addClass("current");a("."+b.paginationClass+" li a",c).click(function(){if(b.play){z()}r=a(this).attr("href").match("[^#/]+$");if(o!=r){x("pagination",k,r)}return false});a("a.link",c).click(function(){if(b.play){z()}r=a(this).attr("href").match("[^#/]+$")-1;if(o!=r){x("pagination",k,r)}return false});if(b.play){w=setInterval(function(){x("next",j)},b.play);c.data("interval",w)}})};a.fn.slides.option={preload:false,preloadImage:"/img/loading.gif",container:"slides_container",generateNextPrev:false,next:"next",prev:"prev",pagination:true,generatePagination:true,paginationClass:"pagination",fadeSpeed:350,fadeEasing:"",slideSpeed:350,slideEasing:"",start:1,effect:"slide",crossfade:false,randomize:false,play:0,pause:0,hoverPause:false,autoHeight:false,autoHeightSpeed:350,bigTarget:false,animationStart:function(){},animationComplete:function(){},slidesLoaded:function(){}};a.fn.randomize=function(b){function c(){return Math.round(Math.random())-.5}return a(this).each(function(){var d=a(this);var e=d.children();var f=e.length;if(f>1){e.hide();var g=[];for(i=0;i<f;i++){g[g.length]=i}g=g.sort(c);a.each(g,function(a,c){var f=e.eq(c);var g=f.clone(true);g.show().appendTo(d);if(b!==undefined){b(f,g)}f.remove()})}})}})(jQuery);



/*
 * Copyright 2011, Gilbert Pellegrom
 * 
 * Free to use and abuse under the MIT license.
 * http://www.opensource.org/licenses/mit-license.php
 */
(function(a){var b=function(b,c){var d=a.extend({},a.fn.nivoSlider.defaults,c);var e={currentSlide:0,currentImage:"",totalSlides:0,randAnim:"",running:false,paused:false,stop:false};var f=a(b);f.data("nivo:vars",e);f.css("position","relative");f.addClass("nivoSlider");var g=f.children();g.each(function(){var b=a(this);var c="";if(!b.is("img.nivo_slide")){if(b.is("a")){b.addClass("nivo-imageLink");c=b}b=b.find("img.nivo_slide:first")}var d=b.width();if(d==0)d=b.attr("width");var g=b.height();if(g==0)g=b.attr("height");if(d>f.width()){f.width(d)}if(g>f.height()){f.height(g)}if(c!=""){c.css("display","none")}b.css("display","none");e.totalSlides++});if(d.startSlide>0){if(d.startSlide>=e.totalSlides)d.startSlide=e.totalSlides-1;e.currentSlide=d.startSlide}if(a(g[e.currentSlide]).is("img.nivo_slide")){e.currentImage=a(g[e.currentSlide])}else{e.currentImage=a(g[e.currentSlide]).find("img.nivo_slide:first")}if(a(g[e.currentSlide]).is("a")){a(g[e.currentSlide]).css("display","block")}f.css("background",'url("'+e.currentImage.attr("src")+'") no-repeat');f.append(a('<div class="nivo-caption"><p></p></div>').css({display:"none",opacity:d.captionOpacity}));var h=function(b){var c=a(".nivo-caption",f);if(e.currentImage.attr("title")!=""&&e.currentImage.attr("title")!=undefined){var d=e.currentImage.attr("title");if(d.substr(0,1)=="#")d=a(d).html();if(c.css("display")=="block"){c.fadeOut(b.animSpeed,function(){a(this).html(d);a(this).fadeIn(b.animSpeed)})}else{c.html(d)}c.fadeIn(b.animSpeed)}else{c.fadeOut(b.animSpeed)}};h(d);var i=0;if(!d.manualAdvance&&g.length>1){i=setInterval(function(){o(f,g,d,false)},d.pauseTime)}if(d.directionNav){f.append('<div class="nivo-directionNav"><a class="nivo-prevNav">'+d.prevText+'</a><a class="nivo-nextNav">'+d.nextText+"</a></div>");if(d.directionNavHide){a(".nivo-directionNav",f).hide();f.hover(function(){a(".nivo-directionNav",f).show()},function(){a(".nivo-directionNav",f).hide()})}a("a.nivo-prevNav",f).live("click",function(){if(e.running)return false;clearInterval(i);i="";e.currentSlide-=2;o(f,g,d,"prev")});a("a.nivo-nextNav",f).live("click",function(){if(e.running)return false;clearInterval(i);i="";o(f,g,d,"next")})}if(d.controlNav){if(d.controlNavThumbs){var j=a('<div class="nivo-controlNav"></div>')}else{var j=a('<div class="nivo-controlNav"></div>')}f.append(j);for(var k=0;k<g.length;k++){if(d.controlNavThumbs){var l=g.eq(k);if(!l.is("img")){l=l.find("img:first")}if(d.controlNavThumbsFromRel){j.append('<a class="nivo-control" rel="'+k+'"><img src="'+l.attr("rel")+'" alt="" /></a>')}else{j.append('<a class="nivo-control" rel="'+k+'"><img src="'+l.attr("src").replace(d.controlNavThumbsSearch,d.controlNavThumbsReplace)+'" alt="" /></a>')}}else{j.append('<a class="nivo-control" rel="'+k+'">'+(k+1)+"</a>")}}a(".nivo-controlNav a:eq("+e.currentSlide+")",f).addClass("active");a(".nivo-controlNav a",f).live("click",function(){if(e.running)return false;if(a(this).hasClass("active"))return false;clearInterval(i);i="";f.css("background",'url("'+e.currentImage.attr("src")+'") no-repeat');e.currentSlide=a(this).attr("rel")-1;o(f,g,d,"control")})}if(d.keyboardNav){a(window).keypress(function(a){if(a.keyCode=="37"){if(e.running)return false;clearInterval(i);i="";e.currentSlide-=2;o(f,g,d,"prev")}if(a.keyCode=="39"){if(e.running)return false;clearInterval(i);i="";o(f,g,d,"next")}})}if(d.pauseOnHover){f.hover(function(){e.paused=true;clearInterval(i);i=""},function(){e.paused=false;if(i==""&&!d.manualAdvance){i=setInterval(function(){o(f,g,d,false)},d.pauseTime)}})}f.bind("nivo:animFinished",function(){e.running=false;a(g).each(function(){if(a(this).is("a")){a(this).css("display","none")}});if(a(g[e.currentSlide]).is("a")){a(g[e.currentSlide]).css("display","block")}if(i==""&&!e.paused&&!d.manualAdvance){i=setInterval(function(){o(f,g,d,false)},d.pauseTime)}d.afterChange.call(this)});var m=function(b,c,d){for(var e=0;e<c.slices;e++){var f=Math.round(b.width()/c.slices);if(e==c.slices-1){b.append(a('<div class="nivo-slice"></div>').css({left:f*e+"px",width:b.width()-f*e+"px",height:"0px",opacity:"0",background:'url("'+d.currentImage.attr("src")+'") no-repeat -'+(f+e*f-f)+"px 0%"}))}else{b.append(a('<div class="nivo-slice"></div>').css({left:f*e+"px",width:f+"px",height:"0px",opacity:"0",background:'url("'+d.currentImage.attr("src")+'") no-repeat -'+(f+e*f-f)+"px 0%"}))}}};var n=function(b,c,d){var e=Math.round(b.width()/c.boxCols);var f=Math.round(b.height()/c.boxRows);for(var g=0;g<c.boxRows;g++){for(var h=0;h<c.boxCols;h++){if(h==c.boxCols-1){b.append(a('<div class="nivo-box"></div>').css({opacity:0,left:e*h+"px",top:f*g+"px",width:b.width()-e*h+"px",height:f+"px",background:'url("'+d.currentImage.attr("src")+'") no-repeat -'+(e+h*e-e)+"px -"+(f+g*f-f)+"px"}))}else{b.append(a('<div class="nivo-box"></div>').css({opacity:0,left:e*h+"px",top:f*g+"px",width:e+"px",height:f+"px",background:'url("'+d.currentImage.attr("src")+'") no-repeat -'+(e+h*e-e)+"px -"+(f+g*f-f)+"px"}))}}}};var o=function(b,c,d,e){var f=b.data("nivo:vars");if(f&&f.currentSlide==f.totalSlides-1){d.lastSlide.call(this)}if((!f||f.stop)&&!e)return false;d.beforeChange.call(this);if(!e){b.css("background",'url("'+f.currentImage.attr("src")+'") no-repeat')}else{if(e=="prev"){b.css("background",'url("'+f.currentImage.attr("src")+'") no-repeat')}if(e=="next"){b.css("background",'url("'+f.currentImage.attr("src")+'") no-repeat')}}f.currentSlide++;if(f.currentSlide==f.totalSlides){f.currentSlide=0;d.slideshowEnd.call(this)}if(f.currentSlide<0)f.currentSlide=f.totalSlides-1;if(a(c[f.currentSlide]).is("img.nivo_slide")){f.currentImage=a(c[f.currentSlide])}else{f.currentImage=a(c[f.currentSlide]).find("img.nivo_slide:first")}if(d.controlNav){a(".nivo-controlNav a",b).removeClass("active");a(".nivo-controlNav a:eq("+f.currentSlide+")",b).addClass("active")}h(d);a(".nivo-slice",b).remove();a(".nivo-box",b).remove();if(d.effect=="random"){var g=new Array("sliceDownRight","sliceDownLeft","sliceUpRight","sliceUpLeft","sliceUpDown","sliceUpDownLeft","fold","fade","boxRandom","boxRain","boxRainReverse","boxRainGrow","boxRainGrowReverse");f.randAnim=g[Math.floor(Math.random()*(g.length+1))];if(f.randAnim==undefined)f.randAnim="fade"}if(d.effect.indexOf(",")!=-1){var g=d.effect.split(",");f.randAnim=g[Math.floor(Math.random()*g.length)];if(f.randAnim==undefined)f.randAnim="fade"}f.running=true;if(d.effect=="sliceDown"||d.effect=="sliceDownRight"||f.randAnim=="sliceDownRight"||d.effect=="sliceDownLeft"||f.randAnim=="sliceDownLeft"){m(b,d,f);var i=0;var j=0;var k=a(".nivo-slice",b);if(d.effect=="sliceDownLeft"||f.randAnim=="sliceDownLeft")k=a(".nivo-slice",b)._reverse();k.each(function(){var c=a(this);c.css({top:"0px"});if(j==d.slices-1){setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed,"",function(){b.trigger("nivo:animFinished")})},100+i)}else{setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed)},100+i)}i+=50;j++})}else if(d.effect=="sliceUp"||d.effect=="sliceUpRight"||f.randAnim=="sliceUpRight"||d.effect=="sliceUpLeft"||f.randAnim=="sliceUpLeft"){m(b,d,f);var i=0;var j=0;var k=a(".nivo-slice",b);if(d.effect=="sliceUpLeft"||f.randAnim=="sliceUpLeft")k=a(".nivo-slice",b)._reverse();k.each(function(){var c=a(this);c.css({bottom:"0px"});if(j==d.slices-1){setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed,"",function(){b.trigger("nivo:animFinished")})},100+i)}else{setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed)},100+i)}i+=50;j++})}else if(d.effect=="sliceUpDown"||d.effect=="sliceUpDownRight"||f.randAnim=="sliceUpDown"||d.effect=="sliceUpDownLeft"||f.randAnim=="sliceUpDownLeft"){m(b,d,f);var i=0;var j=0;var l=0;var k=a(".nivo-slice",b);if(d.effect=="sliceUpDownLeft"||f.randAnim=="sliceUpDownLeft")k=a(".nivo-slice",b)._reverse();k.each(function(){var c=a(this);if(j==0){c.css("top","0px");j++}else{c.css("bottom","0px");j=0}if(l==d.slices-1){setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed,"",function(){b.trigger("nivo:animFinished")})},100+i)}else{setTimeout(function(){c.animate({height:"100%",opacity:"1.0"},d.animSpeed)},100+i)}i+=50;l++})}else if(d.effect=="fold"||f.randAnim=="fold"){m(b,d,f);var i=0;var j=0;a(".nivo-slice",b).each(function(){var c=a(this);var e=c.width();c.css({top:"0px",height:"100%",width:"0px"});if(j==d.slices-1){setTimeout(function(){c.animate({width:e,opacity:"1.0"},d.animSpeed,"",function(){b.trigger("nivo:animFinished")})},100+i)}else{setTimeout(function(){c.animate({width:e,opacity:"1.0"},d.animSpeed)},100+i)}i+=50;j++})}else if(d.effect=="fade"||f.randAnim=="fade"){m(b,d,f);var o=a(".nivo-slice:first",b);o.css({height:"100%",width:b.width()+"px"});o.animate({opacity:"1.0"},d.animSpeed*2,"",function(){b.trigger("nivo:animFinished")})}else if(d.effect=="slideInRight"||f.randAnim=="slideInRight"){m(b,d,f);var o=a(".nivo-slice:first",b);o.css({height:"100%",width:"0px",opacity:"1"});o.animate({width:b.width()+"px"},d.animSpeed*2,"",function(){b.trigger("nivo:animFinished")})}else if(d.effect=="slideInLeft"||f.randAnim=="slideInLeft"){m(b,d,f);var o=a(".nivo-slice:first",b);o.css({height:"100%",width:"0px",opacity:"1",left:"",right:"0px"});o.animate({width:b.width()+"px"},d.animSpeed*2,"",function(){o.css({left:"0px",right:""});b.trigger("nivo:animFinished")})}else if(d.effect=="boxRandom"||f.randAnim=="boxRandom"){n(b,d,f);var q=d.boxCols*d.boxRows;var j=0;var i=0;var r=p(a(".nivo-box",b));r.each(function(){var c=a(this);if(j==q-1){setTimeout(function(){c.animate({opacity:"1"},d.animSpeed,"",function(){b.trigger("nivo:animFinished")})},100+i)}else{setTimeout(function(){c.animate({opacity:"1"},d.animSpeed)},100+i)}i+=20;j++})}else if(d.effect=="boxRain"||f.randAnim=="boxRain"||d.effect=="boxRainReverse"||f.randAnim=="boxRainReverse"||d.effect=="boxRainGrow"||f.randAnim=="boxRainGrow"||d.effect=="boxRainGrowReverse"||f.randAnim=="boxRainGrowReverse"){n(b,d,f);var q=d.boxCols*d.boxRows;var j=0;var i=0;var s=0;var t=0;var u=new Array;u[s]=new Array;var r=a(".nivo-box",b);if(d.effect=="boxRainReverse"||f.randAnim=="boxRainReverse"||d.effect=="boxRainGrowReverse"||f.randAnim=="boxRainGrowReverse"){r=a(".nivo-box",b)._reverse()}r.each(function(){u[s][t]=a(this);t++;if(t==d.boxCols){s++;t=0;u[s]=new Array}});for(var v=0;v<d.boxCols*2;v++){var w=v;for(var x=0;x<d.boxRows;x++){if(w>=0&&w<d.boxCols){(function(c,e,g,h,i){var j=a(u[c][e]);var k=j.width();var l=j.height();if(d.effect=="boxRainGrow"||f.randAnim=="boxRainGrow"||d.effect=="boxRainGrowReverse"||f.randAnim=="boxRainGrowReverse"){j.width(0).height(0)}if(h==i-1){setTimeout(function(){j.animate({opacity:"1",width:k,height:l},d.animSpeed/1.3,"",function(){b.trigger("nivo:animFinished")})},100+g)}else{setTimeout(function(){j.animate({opacity:"1",width:k,height:l},d.animSpeed/1.3)},100+g)}})(x,w,i,j,q);j++}w--}i+=100}}};var p=function(a){for(var b,c,d=a.length;d;b=parseInt(Math.random()*d),c=a[--d],a[d]=a[b],a[b]=c);return a};var q=function(a){if(this.console&&typeof console.log!="undefined")console.log(a)};this.stop=function(){if(!a(b).data("nivo:vars").stop){a(b).data("nivo:vars").stop=true;q("Stop Slider")}};this.start=function(){if(a(b).data("nivo:vars").stop){a(b).data("nivo:vars").stop=false;q("Start Slider")}};d.afterLoad.call(this);return this};a.fn.nivoSlider=function(c){return this.each(function(d,e){var f=a(this);if(f.data("nivoslider"))return f.data("nivoslider");var g=new b(this,c);f.data("nivoslider",g)})};a.fn.nivoSlider.defaults={effect:"random",slices:15,boxCols:8,boxRows:4,animSpeed:500,pauseTime:3e3,startSlide:0,directionNav:true,directionNavHide:true,controlNav:true,controlNavThumbs:false,controlNavThumbsFromRel:false,controlNavThumbsSearch:".jpg",controlNavThumbsReplace:"_thumb.jpg",keyboardNav:true,pauseOnHover:true,manualAdvance:false,captionOpacity:.8,prevText:"Prev",nextText:"Next",beforeChange:function(){},afterChange:function(){},slideshowEnd:function(){},lastSlide:function(){},afterLoad:function(){}};a.fn._reverse=[].reverse})(jQuery);



/* 
 * jQuery Accordion Slider
 * 
 * Writed by Architector
 * Based on Kwicks Accordion Slider
 * 
 * All Rights Reserved (c) 2011
 */
(function(a){a.fn.kwicks=function(b){var c={isVertical:false,sticky:false,defaultKwick:0,event:"mouseover",spacing:0,duration:1e3,descrAnim:500,descrOpacity:.8};var d=a.extend(c,b);var e=d.isVertical?"height":"width";var f=d.isVertical?"top":"left";return this.each(function(){var b=a(this);var c=b.children("li");var g=b.find("li").find(".slide-description");var h=b.find("li").find(".slide-description-short");var k=c.length;var l=b.css(e).replace(/px/,"")/k;b.addClass("sliderActive");if(d.isVertical){b.addClass("vertical")}else{b.addClass("horizontal")}b.find("li").prepend('<span class="overlay"></span>');var m=c.height();var n=c.width();var p=b.find("li").find(".overlay");if(!d.max){d.max=l*c.size()-d.min*(c.size()-1)}else{d.min=(l*c.size()-d.max)/(c.size()-1)}if(!d.isVertical){h.css({width:l-40,opacity:d.descrOpacity,paddingRight:l*c.size()-d.min});g.css({width:d.max-40,opacity:0,paddingRight:l*c.size()-d.max});p.css({height:m})}else{p.css({width:n});h.css({width:n-20,opacity:d.descrOpacity});g.css({width:n-40,opacity:0})}if(d.sticky){h.css({opacity:0});c.eq(d.defaultKwick).find(".slide-description").css({opacity:d.descrOpacity})}if(d.isVertical){b.css({width:c.eq(0).css("width"),height:l*c.size()+d.spacing*(c.size()-1)+"px"})}else{b.css({width:l*c.size()+d.spacing*(c.size()-1)+"px",height:c.eq(0).css("height")})}var q=[];for(i=0;i<c.size();i++){q[i]=[];for(j=1;j<c.size()-1;j++){if(i==j){q[i][j]=d.isVertical?j*d.min+j*d.spacing:j*d.min+j*d.spacing}else{q[i][j]=(j<=i?j*d.min:(j-1)*d.min+d.max)+j*d.spacing}}}c.each(function(b){var i=a(this);if(b===0){i.css(f,"0px")}else if(b==c.size()-1){i.css(d.isVertical?"bottom":"right","0px")}else{if(d.sticky){i.css(f,q[d.defaultKwick][b])}else{i.css(f,b*l+b*d.spacing)}}if(e=="width"){i.css({margin:0,position:"absolute",width:l})}else{i.css({margin:0,position:"absolute",height:l})}if(d.sticky){if(d.defaultKwick==b){i.css(e,d.max+"px");i.addClass("active")}else{i.css(e,d.min+"px")}}i.bind(d.event,function(){var a=[];var k=[];c.stop().removeClass("active");for(j=0;j<c.size();j++){a[j]=c.eq(j).css(e).replace(/px/,"");k[j]=c.eq(j).css(f).replace(/px/,"")}var l={};l[e]=d.max;var m=d.max-a[b];var n=a[b]/m;i.addClass("active").animate(l,{step:function(g){var h=m!=0?g/m-n:1;c.each(function(g){if(g!=b){c.eq(g).css(e,a[g]-(a[g]-d.min)*h+"px")}if(g>0&&g<c.size()-1){c.eq(g).css(f,k[g]-(k[g]-q[b][g])*h+"px")}})},duration:d.duration,easing:d.easing});h.stop().animate({opacity:0},d.descrAnim/2);g.stop().animate({opacity:d.descrOpacity},d.descrAnim/2);c.not(".active").find(".slide-description").stop().animate({opacity:0},d.descrAnim)})});if(!d.sticky){b.bind("mouseleave",function(){var a=[];var b=[];c.removeClass("active").stop();for(i=0;i<c.size();i++){a[i]=c.eq(i).css(e).replace(/px/,"");b[i]=c.eq(i).css(f).replace(/px/,"")}var j={};j[e]=l;var k=l-a[0];c.eq(0).animate(j,{step:function(g){var h=k!=0?(g-a[0])/k:1;for(i=1;i<c.size();i++){c.eq(i).css(e,a[i]-(a[i]-l)*h+"px");if(i<c.size()-1){c.eq(i).css(f,b[i]-(b[i]-(i*l+i*d.spacing))*h+"px")}}},duration:d.duration,easing:d.easing});g.stop().animate({opacity:0},d.descrAnim/2);h.stop().animate({opacity:d.descrOpacity},d.descrAnim)})}})}})(jQuery);



/*
 * jQuery Tools 1.2.5 Tooltip - UI essentials
 * NO COPYRIGHTS OR LICENSES. DO WHAT YOU LIKE.
 * Since: November 2008
 */
(function(a){function d(d,e){var f=this,h=d.add(f),i,j=0,k=0,l=d.attr("title"),m=d.attr("data-tooltip"),n=b[e.effect],o,p=d.is(":input"),q=p&&d.is(":checkbox, :radio, select, :button, :submit"),r=d.attr("type"),s=e.events[r]||e.events[p?q?"widget":"input":"def"];if(!n){throw'Nonexistent effect "'+e.effect+'"'}s=s.split(/,\s*/);if(s.length!=2){throw"Tooltip: bad events configuration for "+r}d.bind(s[0],function(a){clearTimeout(j);if(e.predelay){k=setTimeout(function(){f.show(a)},e.predelay)}else{f.show(a)}}).bind(s[1],function(a){clearTimeout(k);if(e.delay){j=setTimeout(function(){f.hide(a)},e.delay)}else{f.hide(a)}});if(l&&e.cancelDefault){d.removeAttr("title");d.data("title",l)}a.extend(f,{show:function(b){if(!i){if(m){i=a(m)}else if(e.tip){i=a(e.tip).eq(0)}else if(l){i=a(e.layout).addClass(e.tipClass).appendTo(document.body).hide().append(l)}else{i=d.next();if(!i.length){i=d.parent().next()}}if(!i.length){throw"Cannot find tooltip for "+d}}if(f.isShown()){return f}i.stop(true,true);var g=c(d,i,e);if(e.tip){i.html(d.data("title"))}b=b||a.Event();b.type="onBeforeShow";h.trigger(b,[g]);if(a.browser.mozilla){}else{if(b.isDefaultPrevented()){return f}}g=c(d,i,e);i.css({position:"absolute",top:g.top,left:g.left});o=true;n[0].call(f,function(){b.type="onShow";o="full";h.trigger(b)});var p=e.events.tooltip.split(/,\s*/);if(!i.data("__set")){i.bind(p[0],function(){clearTimeout(j);clearTimeout(k)});if(p[1]&&!d.is("input:not(:checkbox, :radio), textarea")){i.bind(p[1],function(a){if(a.relatedTarget!=d[0]){d.trigger(s[1].split(" ")[0])}})}i.data("__set",true)}return f},hide:function(c){if(!i||!f.isShown()){return f}c=c||a.Event();c.type="onBeforeHide";h.trigger(c);if(a.browser.mozilla){}else{if(c.isDefaultPrevented()){return}}o=false;b[e.effect][1].call(f,function(){c.type="onHide";h.trigger(c)});return f},isShown:function(a){return a?o=="full":o},getConf:function(){return e},getTip:function(){return i},getTrigger:function(){return d}});a.each("onHide,onBeforeShow,onShow,onBeforeHide".split(","),function(b,c){if(a.isFunction(e[c])){a(f).bind(c,e[c])}f[c]=function(b){if(b){a(f).bind(c,b)}return f}})}function c(b,c,d){var e=d.relative?b.position().top:b.offset().top,f=d.relative?b.position().left:b.offset().left,g=d.position[0];e-=c.outerHeight()-d.offset[0];f+=b.outerWidth()+d.offset[1];if(/iPad/i.test(navigator.userAgent)){e-=a(window).scrollTop()}var h=c.outerHeight()+b.outerHeight();if(g=="center"){e+=h/2}if(g=="bottom"){e+=h}g=d.position[1];var i=c.outerWidth()+b.outerWidth();if(g=="center"){f-=i/2}if(g=="left"){f-=i}return{top:e,left:f}}a.tools=a.tools||{version:"1.2.5"};a.tools.tooltip={conf:{effect:"toggle",fadeOutSpeed:"fast",predelay:0,delay:30,opacity:1,tip:0,position:["top","center"],offset:[0,0],relative:false,cancelDefault:true,events:{def:"mouseenter,mouseleave",input:"focus,blur",widget:"focus mouseenter,blur mouseleave",tooltip:"mouseenter,mouseleave"},layout:"<div/>",tipClass:"tooltip"},addEffect:function(a,c,d){b[a]=[c,d]}};var b={toggle:[function(a){var b=this.getConf(),c=this.getTip(),d=b.opacity;if(d<1){c.css({opacity:d})}c.show();a.call()},function(a){this.getTip().hide();a.call()}],fade:[function(a){var b=this.getConf();this.getTip().fadeTo(b.fadeInSpeed,b.opacity,a)},function(a){this.getTip().fadeOut(this.getConf().fadeOutSpeed,a)}]};a.fn.tooltip=function(b){var c=this.data("tooltip");if(c){return c}b=a.extend(true,{},a.tools.tooltip.conf,b);if(typeof b.position=="string"){b.position=b.position.split(/,?\s/)}this.each(function(){c=new d(a(this),b);a(this).data("tooltip",c)});return b.api?c:this}})(jQuery);

(function(a){var b=a.tools.tooltip;a.extend(b.conf,{direction:"up",bounce:false,slideOffset:10,slideInSpeed:200,slideOutSpeed:200,slideFade:!a.browser.msie});var c={up:["-","top"],down:["+","top"],left:["-","left"],right:["+","left"]};b.addEffect("slide",function(a){var b=this.getConf(),d=this.getTip(),f=b.slideFade?{opacity:b.opacity}:{},g=c[b.direction]||c.up;f[g[1]]=g[0]+"="+b.slideOffset;b.slideFade&&d.css({opacity:0});d.show().animate(f,b.slideInSpeed,a)},function(b){var f=this.getConf(),g=f.slideOffset,h=f.slideFade?{opacity:0}:{},i=c[f.direction]||c.up,j=""+i[0];if(f.bounce)j=j=="+"?"-":"+";h[i[1]]=j+"="+g;this.getTip().animate(h,f.slideOutSpeed,function(){a(this).hide();b.call()})})})(jQuery);

(function(a){function c(a){for(var b=a.length;b--;)if(a[b])return false;return true}function b(b){var c=a(window),d=c.width()+c.scrollLeft(),e=c.height()+c.scrollTop();return[b.offset().top<=c.scrollTop(),d<=b.offset().left+b.width(),e<=b.offset().top+b.height(),c.scrollLeft()>=b.offset().left]}var d=a.tools.tooltip;d.dynamic={conf:{classNames:"top right bottom left"}};a.fn.dynamic=function(e){if(typeof e=="number")e={speed:e};e=a.extend({},d.dynamic.conf,e);var f=e.classNames.split(/\s/),h;this.each(function(){var d=a(this).tooltip().onBeforeShow(function(d,i){d=this.getTip();var l=this.getConf();h||(h=[l.position[0],l.position[1],l.offset[0],l.offset[1],a.extend({},l)]);a.extend(l,h[4]);l.position=[h[0],h[1]];l.offset=[h[2],h[3]];d.css({visibility:"hidden",position:"absolute",top:i.top,left:i.left}).show();i=b(d);if(!c(i)){if(i[2]){a.extend(l,e.top);l.position[0]="top";d.addClass(f[0])}if(i[3]){a.extend(l,e.right);l.position[1]="right";d.addClass(f[1])}if(i[0]){a.extend(l,e.bottom);l.position[0]="bottom";d.addClass(f[2])}if(i[1]){a.extend(l,e.left);l.position[1]="left";d.addClass(f[3])}if(i[0]||i[2])l.offset[0]*=-1;if(i[1]||i[3])l.offset[1]*=-1}d.css({visibility:"visible"}).hide()});d.onBeforeShow(function(){var a=this.getConf();this.getTip();setTimeout(function(){a.position=[h[0],h[1]];a.offset=[h[2],h[3]]},0)});d.onHide(function(){var a=this.getTip();a.removeClass(e.classNames)});ret=d});return e.api?ret:this}})(jQuery);

jQuery(document).ready(function(){
    jQuery('.link_tooltip, .newtooltip').tooltip({
        effect:'slide',
        direction:'up',
        slideOffset:15,
        slideInSpeed:300,
        slideOutSpeed:300,
        position:'bottom center'
    });
});




/* Social Icons Scripts */
(function($){$.fn.socicons=function(c){var d={icons:'digg,stumbleupon,delicious,facebook,yahoo',imagesurl:'images/',imageformat:'png',light:true,targetblank:true,shorturl:''};var e=$.extend({},d,c);var f=this;var g=e.targetblank?'target="_blank"':'';var h=e.icons.split(',');for(key in h){var j=h[key];var k=socformat[h[key]];if(k!=undefined){k=k.replace('{TITLE}',urlencode(socicons_title()));k=k.replace('{URL}',urlencode(socicons_url()));k=k.replace('{SHORTURL}',urlencode(socicons_shorturl()));k=k.replace('{KEYWORDS}',urlencode(socicons_metawords()));k=k.replace('{DESCRIPTION}',urlencode(socicons_metadescript()));var l='<a '+g+' href="'+k+'" class="socicons_icon" title="'+j+'"><img src="'+e.imagesurl+j+'.'+e.imageformat+'" alt="'+j+'" /></a>';this.append(l)}}if(e.light){this.find('.socicons_icon').bind('mouseover',function(){$(this).siblings().stop().animate({'opacity':0.3},500)});this.find('.socicons_icon').bind('mouseout',function(){$(this).siblings().stop().animate({'opacity':1},500)})}var m;function socicons_metawords(){if(n==undefined){metaCollection=document.getElementsByTagName('meta');for(i=0;i<metaCollection.length;i++){nameAttribute=metaCollection[i].name.search(/keywords/);if(nameAttribute!=-1){m=metaCollection[i].content;return m}}}else{return m}}var n;function socicons_metadescript(){if(n==undefined){metaCollection=document.getElementsByTagName('meta');for(i=0;i<metaCollection.length;i++){nameAttribute=metaCollection[i].name.search(/description/);if(nameAttribute!=-1){n=metaCollection[i].content;return n}}}else{return n}}function socicons_title(){return document.title}function socicons_url(){var a=document.location.href;return a}function socicons_shorturl(){if(e.shorturl==''){return socicons_url()}else{return e.shorturl}}function urlencode(a){if(a==undefined){return''}return a.replace(/\s/g,'%20').replace('+','%2B').replace('/%20/g','+').replace('*','%2A').replace('/','%2F').replace('@','%40')}function light(a,b){if(b){a.style.opacity=1;a.childNodes[0].style.filter='progid:DXImageTransform.Microsoft.Alpha(opacity=100);'}else{a.style.opacity=light_opacity/100;a.style.filter='alpha(opacity=20)';a.childNodes[0].style.filter='progid:DXImageTransform.Microsoft.Alpha(opacity='+light_opacity+');'}}return this}})(jQuery);

var socformat = Array();
socformat['nujij'] = 'http://nujij.nl/jij.lynkx?t={TITLE}&u={URL}&b={DESCRIPTION}'
socformat['ekudos'] = 'http://www.ekudos.nl/artikel/nieuw?url={URL}&title={TITLE}&desc={DESCRIPTION}';
socformat['digg'] = 'http://digg.com/submit?phase=2&url={URL}&title={TITLE}';
socformat['linkedin'] = 'http://www.linkedin.com/shareArticle?mini=true&url={URL}&title={TITLE}&summary={DESCRIPTION}&source=';
socformat['sphere'] = 'http://www.sphere.com/search?q=sphereit:{URL}';
socformat['technorati'] = 'http://www.technorati.com/faves?add={URL}';
socformat['delicious'] = 'http://del.icio.us/post?url={URL}&title={TITLE}';
socformat['furl'] = 'http://furl.net/storeIt.jsp?u={URL}&t={TITLE}';
socformat['netscape'] = 'http://www.netscape.com/submit/?U={URL}&T={TITLE}';
socformat['yahoo'] = 'http://myweb2.search.yahoo.com/myresults/bookmarklet?u={URL}&t={TITLE}';
socformat['google'] = 'http://www.google.com/bookmarks/mark?op=edit&bkmk={URL}&title={TITLE}';
socformat['newsvine'] = 'http://www.newsvine.com/_wine/save?u={URL}&h={TITLE}';
socformat['reddit'] = 'http://reddit.com/submit?url={URL}&title={TITLE}';
socformat['blogmarks'] = 'http://blogmarks.net/my/new.php?mini=1&url={URL}&title={TITLE}';
socformat['magnolia'] = 'http://ma.gnolia.com/bookmarklet/add?url={URL}&title={TITLE}';
socformat['live'] = 'https://favorites.live.com/quickadd.aspx?marklet=1&mkt=en-us&url={URL}&title={TITLE}&top=1';
socformat['tailrank'] = 'http://tailrank.com/share/?link_href={URL}&title={TITLE}';
socformat['facebook'] = 'http://www.facebook.com/share.php?u={URL}';
socformat['twitter'] = 'http://twitter.com/?status={TITLE}%20-%20{SHORTURL}';
socformat['stumbleupon'] = 'http://www.stumbleupon.com/submit?url={URL}&title={TITLE}';
socformat['bligg'] = 'http://www.bligg.nl/submit.php?url={URL}';
socformat['symbaloo'] = 'http://www.symbaloo.com/en/add/url={URL}&title={TITLE}';
socformat['misterwong'] = 'http://www.mister-wong.com/add_url/?bm_url={URL}&bm_title={TITLE}&bm_comment=&bm_tags={KEYWORDS}';
socformat['buzz']	= 'http://www.google.com/reader/link?url={URL}&title={TITLE}&snippet={DESCRIPTION}&srcURL={URL}&srcTitle={TITLE}';
socformat['myspace'] = 'http://www.myspace.com/Modules/PostTo/Pages/?u={URL}';
socformat['mail']	= 'mailto:to@email.com?SUBJECT={TITLE}&BODY={DESCRIPTION}-{URL}';
socformat['googleplus']	= 'https://m.google.com/app/plus/x/?v=compose&content={TITLE}-{URL}';

jQuery(document).ready(function(){
	jQuery('h6.share').toggle(function(){
		jQuery(this).addClass('open').parent().find('.social').show('slow');
		return false;
	}, function(){
		jQuery(this).removeClass('open').parent().find('.social').hide('slow');
		return false;
	});
}); 



/*
 * Copyright (c) 2009 - 2010 Happyworm Ltd
 * 
 * Dual licensed under the MIT and GPL licenses.
 *  http://www.opensource.org/licenses/mit-license.php
 *  http://www.gnu.org/copyleft/gpl.html
 */
eval(function(a,b,c,d,e,f){e=function(a){return(a<b?"":e(parseInt(a/b)))+((a=a%b)>35?String.fromCharCode(a+29):a.toString(36))};if(!"".replace(/^/,String)){while(c--)f[e(c)]=d[c]||e(c);d=[function(a){return f[a]}];e=function(){return"\\w+"};c=1}while(c--)if(d[c])a=a.replace(new RegExp("\\b"+e(c)+"\\b","g"),d[c]);return a}('(o(c,h){c.5e.7=o(a){G b=1H a==="2m",d=5f.1I.3Y.5g(3h,1),f=6;a=!b&&d.I?c.Y.3Z(5h,[B,a].5i(d)):a;q(b&&a.5j(0)==="5k")M f;b?6.O(o(){G e=c.2n(6,"7"),g=e&&c.5l(e[a])?e[a].3Z(e,d):e;q(g!==e&&g!==h){f=g;M r}}):6.O(o(){G e=c.2n(6,"7");q(e){e.1J(a||{}).3i();e.1J(a||{})}J c.2n(6,"7",3j c.7(a,6))});M f};c.7=o(a,b){q(3h.I){6.T=c(b);6.E=c.Y(B,{},6.E,a);G d=6;6.T.3k("5m.7",o(){d.41()});6.3i()}};c.7.K={1U:"5n",3l:"5o",1j:"5p",1K:"5q",42:"5r",2H:"5s",3m:"5t",43:"5u",44:"5v",45:"5w",13:"5x",V:"5y",46:"5z",47:"5A",3n:"5B",3o:"5C",3p:"5D",48:"5E",1Z:"5F",2I:"5G",2o:"5H",2J:"5I",49:"5J",3q:"5K",2K:"5L"};c.7.4a=["42","43","44","45","46","47","48","49"];c.7.V=o(){c.O(c.7.1I.2p,o(a,b){b.2n("7").p.1k&&b.7("V")})};c.7.1w={4b:r,4c:B,4d:B,4e:r,4f:B,4g:B,4h:":",4i:":",4j:""};c.7.3r=o(a){a=3j 5M(a*5N);G b=a.5O(),d=a.5P();a=a.5Q();b=c.7.1w.4e&&b<10?"0"+b:b;d=c.7.1w.4f&&d<10?"0"+d:d;a=c.7.1w.4g&&a<10?"0"+a:a;M(c.7.1w.4b?b+c.7.1w.4h:"")+(c.7.1w.4c?d+c.7.1w.4i:"")+(c.7.1w.4d?a+c.7.1w.4j:"")};c.7.4k=o(a){a=a.3s();G b=/(5R)(?:.*W)?[ \\/]([\\w.]+)/,d=/(2L) ([\\w.]+)/,f=/(5S)(?:.*? 5T:([\\w.]+))?/;a=/(4l)[ \\/]([\\w.]+)/.2M(a)||b.2M(a)||d.2M(a)||a.4m("5U")<0&&f.2M(a)||[];M{17:a[1]||"",W:a[2]||"0"}};c.7.17={};G m=c.7.4k(2q.5V);q(m.17){c.7.17[m.17]=B;c.7.17.W=m.W}c.7.1I={1L:0,W:{3t:"2.0.0",3u:"2.0.0",v:"5W"},E:{2r:"5X",1V:"y, v",1M:"2N",20:"5Y",14:0.8,18:r,2O:"",2P:"#5Z",1C:{15:".19-A-13",13:".19-13",V:".19-V",2Q:".19-2Q",1r:".19-60-2R",2S:".19-13-2R",21:".19-21",22:".19-22",23:".19-14-2R",2T:".19-14-2R-24",Z:".19-4n-61",X:".19-X"},25:"19",3v:r,62:r},2p:{},p:{1l:"",C:{},4o:B,1a:{},2s:"",1x:B,R:B,1k:r,A:r,2t:0,2u:0,2U:0,Z:0,X:0},4p:{14:h,18:r,Q:0,U:0},z:{1U:r,2V:h,1N:h},1V:{y:B,v:B},1a:{2N:{1D:\'F/63; 1O="2N"\',1E:B,C:"F"},4q:{1D:\'F/4r; 1O="4s.40.2"\',1E:B,C:"F"},64:{1D:\'F/4t; 1O="2W"\',1E:r,C:"F"},4u:{1D:\'F/4u; 1O="1"\',1E:r,C:"F"},65:{1D:\'F/4v; 1O="2W"\',1E:r,C:"F"},4w:{1D:\'A/4r; 1O="66.67, 4s.40.2"\',1E:B,C:"A"},68:{1D:\'A/4t; 1O="69, 2W"\',1E:r,C:"A"},6a:{1D:\'A/4v; 1O="2W, 6b"\',1E:r,C:"A"}},3i:o(){G a=6;6.T.3w();6.p=c.Y({},6.p,6.4p);6.z=c.Y({},6.z);6.1c=[];6.1W=[];6.1F={};6.D={};6.y={};6.y.F={};6.y.A={};6.v={};6.u={};6.u.2X={};6.u.t={};6.p.14=6.2Y(6.E.14,0,1);6.p.18=6.E.18;6.p.Q=6.T.u("Q");6.p.U=6.T.u("U");6.T.u({"6c-6d":6.E.2O});c.O(6.E.1M.3s().3x(","),o(e,g){G i=g.3y(/^\\s+|\\s+$/g,"");q(a.1a[i]){G j=r;c.O(a.1c,o(n,k){q(i===k){j=B;M r}});j||a.1c.4x(i)}});c.O(6.E.1V.3s().3x(","),o(e,g){G i=g.3y(/^\\s+|\\s+$/g,"");q(a.1V[i]){G j=r;c.O(a.1W,o(n,k){q(i===k){j=B;M r}});j||a.1W.4x(i)}});6.z.2V="6e"+6.1L;6.2p[6.z.2V]=6.T;6.T.3z("N")===""&&6.T.3z("N",6.E.25+"6f"+6.1L);6.z.2Z=c.Y({},{N:6.T.3z("N"),t:6.T});6.z.F=c.Y({},{N:6.E.25+"6g"+6.1L,t:h});6.z.A=c.Y({},{N:6.E.25+"6h"+6.1L,t:h});6.z.v=c.Y({},{N:6.E.25+"6i"+6.1L,t:h,1X:6.E.2r+(6.E.2r!==""&&6.E.2r.3Y(-1)!=="/"?"/":"")+"3A.1X"});6.z.S=c.Y({},{N:6.E.25+"6j"+6.1L,t:h});c.O(c.7.K,o(e,g){q(a.E[e]!==h){a.T.3k(g+".7",a.E[e]);a.E[e]=h}});6.D.S=1P.2v("6k");6.D.S.N=6.z.S.N;6.D.S.6l=o(){q(!a.p.A||a.p.1x)a.z.S.t.1s()};6.T.2w(6.D.S);6.z.S.t=c("#"+6.z.S.N);6.z.S.t.u({Q:6.p.Q,U:6.p.U});6.z.S.t.1d();6.1F.F=r;6.1F.A=r;c.O(6.1c,o(e,g){a.1F[a.1a[g].C]=B});6.y.F.1m=r;q(6.1F.F){6.D.F=1P.2v("F");6.D.F.N=6.z.F.N;6.y.F.1m=!!6.D.F.3B}6.y.A.1m=r;q(6.1F.A){6.D.A=1P.2v("A");6.D.A.N=6.z.A.N;6.y.A.1m=!!6.D.A.3B}6.v.1m=6.4y(10);6.y.1Y={};6.v.1Y={};c.O(6.1c,o(e,g){a.y.1Y[g]=a.y[a.1a[g].C].1m&&""!==a.D[a.1a[g].C].3B(a.1a[g].1D);a.v.1Y[g]=a.1a[g].1E&&a.v.1m});6.y.26=r;6.v.26=r;c.O(6.1W,o(e,g){q(e===0)a[g].26=B;J{G i=r,j=r;c.O(a.1c,o(n,k){q(a[a.1W[0]].1Y[k])q(a.1a[k].C==="A")j=B;J i=B});a[g].26=a.1F.F&&!i||a.1F.A&&!j}});6.y.1t={};6.v.1t={};c.O(6.1c,o(e,g){a.y.1t[g]=a.y.1Y[g]&&a.y.26;a.v.1t[g]=a.v.1Y[g]&&a.v.26});6.y.11=r;6.v.11=r;c.O(6.1W,o(e,g){c.O(a.1c,o(i,j){q(a[g].1t[j]){a[g].11=B;M r}})});6.y.11||6.v.11||6.1Q({1n:c.7.1j.27,1o:"{1V:\'"+6.E.1V+"\', 1M:\'"+6.E.1M+"\'}",16:c.7.1R.27,1b:c.7.1S.27});6.y.P=r;6.y.F.H=r;6.y.A.H=r;6.v.P=r;6.v.H=r;q(6.v.11){G b="N="+6m(6.z.2Z.N)+"&6n="+6.p.14+"&18="+6.p.18;q(c.17.2L&&3C(c.17.W)<=8){G d=\'<30 N="\'+6.z.v.N+\'"\';d+=\' 6o="6p:6q-6r-6s-6t-6u"\';d+=\' 6v="\'+1P.1e.6w(0,1P.1e.4m(":"))+\'://6x.4z.4A/6y/3D/6z/v/6A.6B"\';d+=\' 1n="4B/x-3D-v"\';d+=\' Q="0" U="0">\';d+="</30>";G f=[];f[0]=\'<2x 1T="6C" 24="\'+6.z.v.1X+\'" />\';f[1]=\'<2x 1T="4C" 24="4D" />\';f[2]=\'<2x 1T="4E" 24="\'+b+\'" />\';f[3]=\'<2x 1T="4F" 24="4G" />\';f[4]=\'<2x 1T="4H" 24="\'+6.E.2O+\'" />\';b=1P.2v(d);31(d=0;d<f.I;d++)b.6D(1P.2v(f[d]));6.T.2w(b)}J{f=\'<6E 1T="\'+6.z.v.N+\'" N="\'+6.z.v.N+\'" 1l="\'+6.z.v.1X+\'"\';f+=\' Q="0" U="0" 4H="\'+6.E.2O+\'"\';f+=\' 4C="4D" 4E="\'+b+\'"\';f+=\' 4F="4G"\';f+=\' 1n="4B/x-3D-v" 6F="6G://6H.4z.4A/6I/6J" />\';6.T.2w(f)}6.z.v.t=c("#"+6.z.v.N);6.z.v.t.u({Q:"12",U:"12"})}q(6.y.11){q(6.y.F.1m){6.3E(6.D.F,6.y.F);6.T.2w(6.D.F);6.z.F.t=c("#"+6.z.F.N)}q(6.y.A.1m){6.3E(6.D.A,6.y.A);6.T.2w(6.D.A);6.z.A.t=c("#"+6.z.A.N);6.z.A.t.u({Q:"12",U:"12"})}}6.y.11&&!6.v.11&&4I.32(o(){a.z.1U=B;a.W.v="n/a";a.L(c.7.K.1U)},1f);c.O(6.E.1C,o(e,g){a.2y(e,g)});6.1u();6.1p(r);6.2z(6.p.14);6.33(6.p.18);6.u.t.15.I&&6.u.t.15.1d();c.7.1I.1L++},41:o(){6.2A();6.1u();6.1G();6.u.t.Z.I&&6.u.t.Z.34("");6.u.t.X.I&&6.u.t.X.34("");6.p.1k&&6.V();c.O(6.u.t,o(a,b){b.3F(".7")});6.T.6K("7");6.T.3F(".7");6.T.3w();6.2p[6.z.2V]=h},6L:o(){},6M:o(){},3E:o(a,b){G d=6;a.20=6.E.20;a.18=6.E.18;a.1g("2H",o(){q(b.H&&!d.p.R){d.2B(a);d.1u();d.L(c.7.K.2H)}},r);a.1g("2o",o(){q(b.H&&!d.p.R){d.2B(a);d.1u();d.L(c.7.K.2o)}},r);a.1g("3q",o(){q(b.H&&!d.p.R){d.p.X=6.X;d.2B(a);d.1u();d.L(c.7.K.3q)}},r);a.1g("13",o(){q(b.H&&!d.p.R){d.1p(B);d.L(c.7.K.13)}},r);a.1g("3o",o(){q(b.H&&!d.p.R){d.1p(B);d.1G();d.L(c.7.K.3o)}},r);a.1g("V",o(){q(b.H&&!d.p.R){d.1p(r);d.L(c.7.K.V)}},r);a.1g("3n",o(){q(b.H&&!d.p.R){d.35();d.L(c.7.K.3n)}},r);a.1g("3p",o(){q(b.H&&!d.p.R){a.14=d.4J(d.p.14);d.L(c.7.K.3p)}},r);a.1g("1Z",o(){q(b.H&&!d.p.R){d.35();d.L(c.7.K.1Z)}},r);a.1g("2I",o(){q(b.H&&!d.p.R){d.1G();d.L(c.7.K.2I)}},r);a.1g("3m",o(){q(b.H&&!d.p.R){d.1G();d.L(c.7.K.3m)}},r);a.1g("2J",o(){q(b.H&&!d.p.R){q(!c.7.17.4l)d.D.C.Z=0;d.D.C.V();d.1p(r);d.2B(a,B);d.1u();d.L(c.7.K.2J)}},r);a.1g("1j",o(){q(b.H&&!d.p.R){d.1p(r);d.1G();q(d.p.1k){d.p.R=B;d.p.1x=B;d.p.A&&d.z.A.t.u({Q:"12",U:"12"});d.2C(d.p.C.S)&&d.z.S.t.1s();d.u.t.15.I&&d.u.t.15.1s();d.1Q({1n:c.7.1j.1e,1o:d.p.1l,16:c.7.1R.1e,1b:c.7.1S.1e})}}},r);c.O(c.7.4a,o(f,e){a.1g(6,o(){b.H&&!d.p.R&&d.L(c.7.K[e])},r)})},2B:o(a,b){G d=0,f=0,e=0,g=0;d=a.Z;f=6.p.X>0?1f*d/6.p.X:0;q(1H a.1y==="30"&&a.1y.I>0){e=6.p.X>0?1f*a.1y.3G(a.1y.I-1)/6.p.X:1f;g=1f*a.Z/a.1y.3G(a.1y.I-1)}J{e=1f;g=f}q(b)f=g=d=0;6.p.2t=e;6.p.2u=g;6.p.2U=f;6.p.Z=d},2A:o(){6.p=c.Y({},6.p,c.7.1I.p)},L:o(a,b,d){a=c.6N(a);a.7={};a.7.W=c.Y({},6.W);a.7.p=c.Y(B,{},6.p);a.7.y=c.Y(B,{},6.y);a.7.v=c.Y(B,{},6.v);q(b)a.7.1j=c.Y({},b);q(d)a.7.1K=c.Y({},d);6.T.6O(a)},6P:o(a,b){q(a===c.7.K.1U&&!6.z.1U){6.z.1U=B;6.W.v=b.W;6.W.3u!==6.W.v&&6.1Q({1n:c.7.1j.28,1o:6.W.v,16:c.7.1R.28+6.W.v,1b:c.7.1S.28});6.L(a)}q(6.v.H)36(a){1q c.7.K.2H:6.3H(b);6.1u();6.L(a);1z;1q c.7.K.2o:6.3H(b);6.1u();6.L(a);1z;1q c.7.K.13:6.1G();6.1p(B);6.L(a);1z;1q c.7.K.V:6.1p(r);6.L(a);1z;1q c.7.K.2J:6.1p(r);6.L(a);1z;1q c.7.K.1j:6.p.R=B;6.p.1x=B;6.p.A&&6.z.v.t.u({Q:"12",U:"12"});6.2C(6.p.C.S)&&6.z.S.t.1s();6.u.t.15.I&&6.u.t.15.1s();6.p.A?6.3I(6.p.C):6.3J(6.p.C);6.1Q({1n:c.7.1j.1e,1o:b.1l,16:c.7.1R.1e,1b:c.7.1S.1e});1z;1q c.7.K.1Z:6.35();6.L(a);1z;1q c.7.K.2I:6.1G();6.L(a);1z;6Q:6.L(a)}M r},3H:o(a){6.p.2t=a.2t;6.p.2u=a.2u;6.p.2U=a.2U;6.p.Z=a.Z;6.p.X=a.X},1p:o(a){6.p.4o=!a;q(6.u.t.13.I&&6.u.t.V.I)q(a){6.u.t.13.1d();6.u.t.V.1s()}J{6.u.t.13.1s();6.u.t.V.1d()}},1u:o(){6.u.t.1r.I&&6.u.t.1r.Q(6.p.2t+"%");6.u.t.2S.I&&6.u.t.2S.Q(6.p.2u+"%");6.u.t.Z.I&&6.u.t.Z.34(c.7.3r(6.p.Z));6.u.t.X.I&&6.u.t.X.34(c.7.3r(6.p.X))},35:o(){6.u.t.1r.I&&6.u.t.1r.6R("19-1Z-4K")},1G:o(){6.u.t.1r.I&&6.u.t.1r.6S("19-1Z-4K")},3K:o(a){G b=6;6.1G();37(6.z.1N);G d=6.y.F.H,f=6.y.A.H,e=r;c.O(6.1c,o(g,i){G j=b.1a[i].C==="A";c.O(b.1W,o(n,k){q(b[k].1t[i]&&b.2C(a[i])){G l=k==="y";q(j)q(l){b.y.F.H=r;b.y.A.H=B;b.v.H=r}J{b.y.F.H=r;b.y.A.H=r;b.v.H=B}J q(l){b.y.F.H=B;b.y.A.H=r;b.v.H=r}J{b.y.F.H=r;b.y.A.H=r;b.v.H=B}q(b.v.P||b.y.P&&b.v.H||d===b.y.F.H&&f===b.y.A.H)b.4L();J q(d!==b.y.F.H&&f!==b.y.A.H){b.38();b.p.A&&b.z.A.t.u({Q:"12",U:"12"});b.2A()}q(j){q(l){b.4M(a);b.y.P=B;b.v.P=r}J{b.3I(a);b.y.P=r;b.v.P=B}b.u.t.15.I&&b.u.t.15.1s();b.p.A=B}J{q(l){b.4N(a);b.y.P=B;b.v.P=r}J{b.3J(a);b.y.P=r;b.v.P=B}b.u.t.15.I&&b.u.t.15.1d();b.p.A=r}e=B;M r}});q(e)M r});q(e){q(6.2C(a.S))q(6.D.S.1l!==a.S)6.D.S.1l=a.S;J 6.z.S.t.1s();J 6.z.S.t.1d();6.p.1k=B;6.p.C=c.Y({},a);6.1p(r);6.1u()}J{6.p.1k&&!6.p.1x&&6.V();6.y.F.H=r;6.y.A.H=r;6.v.H=r;6.y.P=r;6.v.P=r;6.2A();6.1u();6.1p(r);6.z.S.t.1d();6.y.11&&6.1F.A&&6.z.A.t.u({Q:"12",U:"12"});6.v.11&&6.z.v.t.u({Q:"12",U:"12"});6.1Q({1n:c.7.1j.29,1o:"{1M:\'"+6.E.1M+"\'}",16:c.7.1R.29,1b:c.7.1S.29})}},4L:o(){6.2A();6.1p(r);6.z.S.t.1d();37(6.z.1N);q(6.y.P)6.4O();J 6.v.P&&6.4P()},39:o(){q(6.p.1k)q(6.y.P)6.2a();J 6.v.P&&6.3a();J 6.2b("39")},13:o(a){a=1H a==="3L"?a:4Q;q(6.p.1k)q(6.y.P)6.4R(a);J 6.v.P&&6.4S(a);J 6.2b("13")},15:o(){6.13()},V:o(a){a=1H a==="3L"?a:4Q;q(6.p.1k)q(6.y.P)6.38(a);J 6.v.P&&6.3M(a);J 6.2b("V")},6T:o(){G a=6;c.O(6.2p,o(b,d){a.T!==d&&d.2n("7").p.1k&&d.7("V")})},2Q:o(){q(6.p.1k)q(6.y.P)6.38(0);J 6.v.P&&6.3M(0);J 6.2b("2Q")},3b:o(a){a=6.2Y(a,0,1f);q(6.p.1k)q(6.y.P)6.4T(a);J 6.v.P&&6.4U(a);J 6.2b("3b")},21:o(){6.p.18=B;6.y.11&&6.3N(B);6.v.11&&6.3O(B);6.33(B);6.2z(0);6.L(c.7.K.2K)},22:o(){6.p.18=r;6.y.11&&6.3N(r);6.v.11&&6.3O(r);6.33(r);6.2z(6.p.14);6.L(c.7.K.2K)},33:o(a){q(6.u.t.21.I&&6.u.t.22.I)q(a){6.u.t.21.1d();6.u.t.22.1s()}J{6.u.t.21.1s();6.u.t.22.1d()}},14:o(a){a=6.2Y(a,0,1);6.p.14=a;6.y.11&&6.4V(a);6.v.11&&6.4W(a);6.p.18||6.2z(a);6.L(c.7.K.2K)},23:o(a){q(!6.p.18&&6.u.t.23){G b=6.u.t.23.4X();a=a.4Y-b.4Z;b=6.u.t.23.Q();6.14(a/b)}},2T:o(a){6.23(a)},2z:o(a){6.u.t.2T.I&&6.u.t.2T.Q(a*1f+"%")},4J:o(a){G b=0.6U*6V.6W();M a+(a<0.5?b:-b)},6X:o(a,b){6.E.2P=a;b&&c.O(6.E.1C,o(d,f){2Z.2y(d,f)})},2y:o(a,b){G d=6;q(1H b==="2m")q(c.7.1I.E.1C[a]){6.u.t[a]&&6.u.t[a].I&&6.u.t[a].3F(".7");6.E.1C[a]=b;6.u.2X[a]=6.E.2P+" "+b;6.u.t[a]=b?c(6.u.2X[a]):[];6.u.t[a].I&&6.u.t[a].3k("6Y.7",o(f){d[a](f);c(6).6Z();M r});b&&6.u.t[a].I!==1&&6.2D({1n:c.7.1K.2c,1o:6.u.2X[a],16:c.7.2E.2c+6.u.t[a].I+" 3c 31 "+a+" 3P.",1b:c.7.2F.2c})}J 6.2D({1n:c.7.1K.2d,1o:a,16:c.7.2E.2d,1b:c.7.2F.2d});J 6.2D({1n:c.7.1K.2e,1o:b,16:c.7.2E.2e,1b:c.7.2F.2e})},1r:o(a){q(6.u.t.1r){G b=6.u.t.1r.4X();a=a.4Y-b.4Z;b=6.u.t.1r.Q();6.3b(1f*a/b)}},2S:o(a){6.1r(a)},Z:o(){},X:o(){},1J:o(a,b){G d=a;q(3h.I===0)M c.Y(B,{},6.E);q(1H a==="2m"){G f=a.3x(".");q(b===h){31(G e=c.Y(B,{},6.E),g=0;g<f.I;g++)q(e[f[g]]!==h)e=e[f[g]];J{6.2D({1n:c.7.1K.2f,1o:a,16:c.7.2E.2f,1b:c.7.2F.2f});M h}M e}e=d={};31(g=0;g<f.I;g++)q(g<f.I-1){e[f[g]]={};e=e[f[g]]}J e[f[g]]=b}6.50(d);M 6},50:o(a){G b=6;c.O(a,o(d,f){b.51(d,f)});M 6},51:o(a,b){G d=6;36(a){1q"2P":6.E[a]=b;c.O(d.E.1C,o(f,e){d.2y(f,e)});1z;1q"1C":c.O(b,o(f,e){d.2y(f,e)})}M 6},3l:o(a){6.y.P&&6.52(a);6.v.P&&6.53(a);6.L(c.7.K.3l)},70:o(){},52:o(){},53:o(a){6.z.v.t.u({Q:a.Q,U:a.U})},3Q:o(){6.p.1k&&!6.p.1x&&6.D.C.V();6.E.20!=="71"&&6.2a();6.L(c.7.K.2o)},4N:o(a){G b=6;c.O(6.1c,o(d,f){q(b.y.1t[f]&&a[f]){b.p.1l=a[f];b.p.1a[f]=B;b.p.2s=f;M r}});6.D.C=6.D.F;6.3Q()},4M:o(a){G b=6;c.O(6.1c,o(d,f){q(b.y.1t[f]&&a[f]){b.p.1l=a[f];b.p.1a[f]=B;b.p.2s=f;M r}});6.D.C=6.D.A;6.3Q()},4O:o(){q(6.D.C){6.D.C.N===6.z.A.N&&6.z.A.t.u({Q:"12",U:"12"});6.D.C.V();6.D.C.1l="";c.17.2L&&3C(c.17.W)>=9||6.D.C.39()}},2a:o(){q(6.p.R){6.p.R=r;6.D.C.1l=6.p.1l;1h{6.D.C.39()}1i(a){}}37(6.z.1N)},4R:o(a){G b=6;6.2a();6.D.C.13();q(!3R(a))1h{6.D.C.Z=a}1i(d){6.z.1N=32(o(){b.13(a)},1f);M}6.3d()},38:o(a){G b=6;a>0?6.2a():37(6.z.1N);6.D.C.V();q(!3R(a))1h{6.D.C.Z=a}1i(d){6.z.1N=32(o(){b.V(a)},1f);M}a>0&&6.3d()},4T:o(a){G b=6;6.2a();1h{q(1H 6.D.C.1y==="30"&&6.D.C.1y.I>0)6.D.C.Z=a*6.D.C.1y.3G(6.D.C.1y.I-1)/1f;J q(6.D.C.X>0&&!3R(6.D.C.X))6.D.C.Z=a*6.D.C.X/1f;J 72"e";}1i(d){6.z.1N=32(o(){b.3b(a)},1f);M}6.p.R||6.3d()},3d:o(){q(6.p.1x){6.p.1x=r;6.u.t.15.I&&6.u.t.15.1d();q(6.p.A){6.z.S.t.1d();6.z.A.t.u({Q:6.p.Q,U:6.p.U})}}},4V:o(a){q(6.y.F.1m)6.D.F.14=a;q(6.y.A.1m)6.D.A.14=a},3N:o(a){q(6.y.F.1m)6.D.F.18=a;q(6.y.A.1m)6.D.A.18=a},3J:o(a){G b=6;1h{c.O(6.1c,o(f,e){q(b.v.1t[e]&&a[e]){36(e){1q"4q":b.1v().73(a[e]);1z;1q"2N":b.1v().74(a[e])}b.p.1l=a[e];b.p.1a[e]=B;b.p.2s=e;M r}});q(6.E.20==="54"){6.3a();6.p.R=r}}1i(d){6.1A(d)}},3I:o(a){G b=6;1h{c.O(6.1c,o(f,e){q(b.v.1t[e]&&a[e]){36(e){1q"4w":b.1v().75(a[e])}b.p.1l=a[e];b.p.1a[e]=B;b.p.2s=e;M r}});q(6.E.20==="54"){6.3a();6.p.R=r}}1i(d){6.1A(d)}},4P:o(){6.z.v.t.u({Q:"12",U:"12"});1h{6.1v().76()}1i(a){6.1A(a)}},3a:o(){1h{6.1v().77()}1i(a){6.1A(a)}6.p.R=r},4S:o(a){1h{6.1v().78(a)}1i(b){6.1A(b)}6.p.R=r;6.3e()},3M:o(a){1h{6.1v().79(a)}1i(b){6.1A(b)}q(a>0){6.p.R=r;6.3e()}},4U:o(a){1h{6.1v().7a(a)}1i(b){6.1A(b)}6.p.R||6.3e()},3e:o(){q(6.p.1x){6.p.1x=r;6.u.t.15.I&&6.u.t.15.1d();q(6.p.A){6.z.S.t.1d();6.z.v.t.u({Q:6.p.Q,U:6.p.U})}}},4W:o(a){1h{6.1v().7b(a)}1i(b){6.1A(b)}},3O:o(a){1h{6.1v().7c(a)}1i(b){6.1A(b)}},1v:o(){M 1P[6.z.v.N]},4y:o(a){G b=r,d;q(4I.55)1h{3j 55("56.56."+a);b=B}1i(f){}J q(2q.3S&&2q.7d.I>0)q(d=2q.3S["57 3f"])q(2q.3S["57 3f"].7e.3y(/.*\\s(\\d+\\.\\d+).*/,"$1")>=a)b=B;M c.17.2L&&3C(c.17.W)>=9?r:b},2C:o(a){M a&&1H a==="2m"},2Y:o(a,b,d){M a<b?b:a>d?d:a},2b:o(a){6.1Q({1n:c.7.1j.2g,1o:a,16:c.7.1R.2g,1b:c.7.1S.2g})},1A:o(a){6.1Q({1n:c.7.1j.2h,1o:6.z.v.1X,16:c.7.1R.2h+a.16,1b:c.7.1S.2h})},1Q:o(a){6.L(c.7.K.1j,a);q(6.E.3v)6.3T("7f!"+(a.16?"\\n\\n"+a.16:"")+(a.1b?"\\n\\n"+a.1b:"")+"\\n\\58: "+a.1o)},2D:o(a){6.L(c.7.K.1K,h,a);q(6.E.3v)6.3T("7g!"+(a.16?"\\n\\n"+a.16:"")+(a.1b?"\\n\\n"+a.1b:"")+"\\n\\58: "+a.1o)},3T:o(a){7h("7 "+6.W.3t+" : N=\'"+6.z.2Z.N+"\' : "+a)}};c.7.1j={2h:"7i",27:"7j",29:"7k",1e:"7l",2g:"7m",28:"7n"};c.7.1R={2h:"7\'s 3f 7o 1B 2i 7p 7q, 3U a 7r 7s 7t 7u 2G 7 7v K. 7w: ",27:"7x 1V 59 3V 3c 7y 7 2j 6 17. 7z 7A 7B 3f 59 3V 11.",29:"7C 1B 2i 7D 3W 13 7E C 1a 7F 2j 3K() 7G 6 17 7H 2k 4n E.",1e:"7I 1e 7J 2i 3V 7K.",2g:"7L 3W 7M C 7N 7O, 7P 7Q C 7R 1B 5a.",28:"7 "+c.7.1I.W.3t+" 7S 3A.1X W "+c.7.1I.W.3u+" 7T 3c "};c.7.1S={2h:"2l 2k 2r 1J 3X 7U 3A.1X 1B 7V.",27:"7W 2G 7 E: 1t 3X 1M.",29:"7X 3U F 1c 7Y 2j 2G 1M 1J 7Z 80.",1e:"2l C 1e 1B 5b.",2g:"81 3K() 3W 5a 2G C 1e.",28:"82 7 83."};c.7.1K={2c:"84",2d:"85",2e:"86",2f:"87"};c.7.2E={2c:"3g 3L 88 89 3c 8a 2i 8b 8c: ",2d:"3g 8d 5c 2j 7(\'1C\') 1B 2i a 5b 7 3P.",2e:"3g 8e 5c 2j 7(\'1C\') 1B 2i a 8f 3U 1B 3w.",2f:"3g 1J 8g 2j 7(\'1J\') 1B 8h."};c.7.2F={2c:"2l 2k u 5d 3X 2G 8i.",2d:"2l 2k 3P 1T.",2e:"2l 2k u 5d 1B a 2m.",2f:"2l 2k 1J 1T."}})(8j);',62,516,"||||||this|jPlayer|||||||||||||||||function|status|if|false||jq|css|flash|||html|internal|video|true|media|htmlElement|options|audio|var|gate|length|else|event|_trigger|return|id|each|active|width|waitForLoad|poster|element|height|pause|version|duration|extend|currentTime||used|0px|play|volume|videoPlay|message|browser|muted|jp|format|hint|formats|hide|URL|100|addEventListener|try|catch|error|srcSet|src|available|type|context|_updateButtons|case|seekBar|show|support|_updateInterface|_getMovie|timeFormat|waitForPlay|seekable|break|_flashError|is|cssSelector|codec|flashCanPlay|require|_seeked|typeof|prototype|option|warning|count|supplied|htmlDlyCmdId|codecs|document|_error|errorMsg|errorHint|name|ready|solution|solutions|swf|canPlay|seeking|preload|mute|unmute|volumeBar|value|idPrefix|desired|NO_SOLUTION|VERSION|NO_SUPPORT|_html_load|_urlNotSetError|CSS_SELECTOR_COUNT|CSS_SELECTOR_METHOD|CSS_SELECTOR_STRING|OPTION_KEY|URL_NOT_SET|FLASH|not|in|your|Check|string|data|timeupdate|instances|navigator|swfPath|formatType|seekPercent|currentPercentRelative|createElement|append|param|_cssSelector|_updateVolume|_resetStatus|_getHtmlStatus|_validString|_warning|warningMsg|warningHint|the|progress|seeked|ended|volumechange|msie|exec|mp3|backgroundColor|cssSelectorAncestor|stop|bar|playBar|volumeBarValue|currentPercentAbsolute|instance|vorbis|cs|_limitValue|self|object|for|setTimeout|_updateMute|text|_seeking|switch|clearTimeout|_html_pause|load|_flash_load|playHead|found|_html_checkWaitForPlay|_flash_checkWaitForPlay|Flash|The|arguments|_init|new|bind|resize|suspend|waiting|playing|canplay|durationchange|convertTime|toLowerCase|script|needFlash|errorAlerts|empty|split|replace|attr|Jplayer|canPlayType|Number|shockwave|_addHtmlEventListeners|unbind|end|_getFlashStatus|_flash_setVideo|_flash_setAudio|setMedia|number|_flash_pause|_html_mute|_flash_mute|method|_html_initMedia|isNaN|plugins|_alert|or|be|to|and|slice|apply||destroy|loadstart|abort|emptied|stalled|loadedmetadata|loadeddata|canplaythrough|ratechange|htmlEvent|showHour|showMin|showSec|padHour|padMin|padSec|sepHour|sepMin|sepSec|uaMatch|webkit|indexOf|current|paused|_status|m4a|mp4|mp4a|ogg|wav|webm|m4v|push|_checkForFlash|macromedia|com|application|quality|high|FlashVars|allowScriptAccess|always|bgcolor|window|_volumeFix|bg|clearMedia|_html_setVideo|_html_setAudio|_html_clearMedia|_flash_clearMedia|NaN|_html_play|_flash_play|_html_playHead|_flash_playHead|_html_volume|_flash_volume|offset|pageX|left|_setOptions|_setOption|_resizeHtml|_resizeFlash|auto|ActiveXObject|ShockwaveFlash|Shockwave|nContext|can|set|valid|given|selector|fn|Array|call|null|concat|charAt|_|isFunction|remove|jPlayer_ready|jPlayer_resize|jPlayer_error|jPlayer_warning|jPlayer_loadstart|jPlayer_progress|jPlayer_suspend|jPlayer_abort|jPlayer_emptied|jPlayer_stalled|jPlayer_play|jPlayer_pause|jPlayer_loadedmetadata|jPlayer_loadeddata|jPlayer_waiting|jPlayer_playing|jPlayer_canplay|jPlayer_canplaythrough|jPlayer_seeking|jPlayer_seeked|jPlayer_timeupdate|jPlayer_ended|jPlayer_ratechange|jPlayer_durationchange|jPlayer_volumechange|Date|1E3|getUTCHours|getUTCMinutes|getUTCSeconds|opera|mozilla|rv|compatible|userAgent|unknown|js|metadata|jp_interface_1|seek|time|warningAlerts|mpeg|oga|webma|avc1|42E01E|ogv|theora|webmv|vp8|background|color|jp_|_jplayer_|_audio_|_video_|_flash_|_poster_|img|onload|escape|vol|classid|clsid|d27cdb6e|ae6d|11cf|96b8|444553540000|codebase|substring|fpdownload|pub|cabs|swflash|cab|movie|appendChild|embed|pluginspage|http|www|go|getflashplayer|removeData|enable|disable|Event|trigger|jPlayerFlashEvent|default|addClass|removeClass|pauseOthers|0010|Math|random|_cssSelectorAncestor|click|blur|_resizePoster|none|throw|fl_setAudio_m4a|fl_setAudio_mp3|fl_setVideo_m4v|fl_clearMedia|fl_load|fl_play|fl_pause|fl_play_head|fl_volume|fl_mute|mimeTypes|description|Error|Warning|alert|e_flash|e_no_solution|e_no_support|e_url|e_url_not_set|e_version|fallback|configured|correctly|command|was|issued|before|Ready|Details|No|by|Neither|HTML|nor|It|possible|any|provided|on|using|Media|could|loaded|Attempt|issue|playback|commands|while|no|url|needs|but|that|there|Review|Video|defined|are|missing|Use|Update|files|e_css_selector_count|e_css_selector_method|e_css_selector_string|e_option_key|of|methodCssSelectors|did|equal|one|methodName|methodCssSelector|String|requested|undefined|ancestor|jQuery".split("|"),0,{}));



/*
 * @author Alexander Farkas
 * v. 1.22
 */
eval(function(a,b,c,d,e,f){e=function(a){return(a<b?"":e(parseInt(a/b)))+((a=a%b)>35?String.fromCharCode(a+29):a.toString(36))};if(!"".replace(/^/,String)){while(c--)f[e(c)]=d[c]||e(c);d=[function(a){return f[a]}];e=function(){return"\\w+"};c=1}while(c--)if(d[c])a=a.replace(new RegExp("\\b"+e(c)+"\\b","g"),d[c]);return a}("(8($){6(!r.t||!r.t.K){7 e=$.m;$.m=8(a,b,c){6(b==='j-k'){b='5'}6(b!=='5'||!a.u||a.u[b]){h e.v(w,x)}7 d=a.y;6(!c&&d&&d[b]){h d[b]}h e(a,'L',c)+' '+e(a,'M',c)}}7 f=$.z.A;$.z.A=8(a){6('j-k'B a){a.5=a['j-k'];N a['j-k']}6('5'B a){a.5='('+a.5}h f.v(w,x)};8 n(a){a=a.o(/O|P/g,'p');a=a.o(/Q|R/g,'S%');a=a.o(/([0-9\\.]+)(\\s|\\)|$)/g,\"$T$2\");7 b=a.U(/(-?[0-9\\.]+)(C|\\%|D|E)\\s(-?[0-9\\.]+)(C|\\%|D|E)/);h[F(b[1],G),b[2],F(b[3],G),b[4]]}$.V.W.5=8(a){6(!a.H){7 b=$.m(a.I,'5');6(!b){b='p p'}b=n(b);a.i=[b[0],b[2]];7 c=n(a.l);a.l=[c[0],c[2]];a.q=[c[1],c[3]];a.H=X}7 d=[];d[0]=((a.l[0]-a.i[0])*a.J)+a.i[0]+a.q[0];d[1]=((a.l[1]-a.i[1])*a.J)+a.i[1]+a.q[1];a.I.y.5=d[0]+' '+d[1]}})(Y);",61,61,"|||||backgroundPosition|if|var|function|||||||||return|start|background|position|end|curCSS|toArray|replace|0px|unit|document||defaultView|currentStyle|apply|this|arguments|style|fn|animate|in|px|em|pt|parseFloat|10|bgPosReady|elem|pos|getComputedStyle|backgroundPositionX|backgroundPositionY|delete|left|top|right|bottom|100|1px|match|fx|step|true|jQuery".split("|"),0,{}));



/* Theme Scripts */
jQuery(document).ready(function(){
    jQuery('.search_line input:text').each(function(i){
        jQuery(this).focus(function(){
            if (jQuery(this).val() == 'enter keywords'){
                jQuery(this).val('');
            }
        });
        jQuery(this).blur(function(){
            if (jQuery(this).val() == '' || jQuery(this).val() == ' '){
                jQuery(this).val('enter keywords');
            }
        });
    }); //Search
	
	jQuery('.gallery.gallery-size-thumbnail').each(function(){
		var $galid = jQuery(this).attr('id');
		jQuery(this).find('a').attr({rel:'prettyPhoto['+$galid+']', title:''});
	}); //Wordpress Default Gallery Shortcode Lightbox
	
    jQuery('#contactwidget input#wname').each(function(i){
        jQuery(this).focus(function(){
            if (jQuery(this).val() == 'Name'){
                jQuery(this).val('');
            }
        });
        jQuery(this).blur(function(){
            if (jQuery(this).val() == '' || jQuery(this).val() == ' '){
                jQuery(this).val('Name');
            }
        });
    }); //Contact Widget Name
	
    jQuery('#contactwidget input#wemail').each(function(i){
        jQuery(this).focus(function(){
            if (jQuery(this).val() == 'Email'){
                jQuery(this).val('');
            }
        });
        jQuery(this).blur(function(){
            if (jQuery(this).val() == '' || jQuery(this).val() == ' '){
                jQuery(this).val('Email');
            }
        });
    }); //Contact Widget Email
	
    jQuery('#contactwidget textarea#wmessage').each(function(i){
        jQuery(this).focus(function(){
            if (jQuery(this).val() == 'Quick Message'){
                jQuery(this).val('');
            }
        });
        jQuery(this).blur(function(){
            if (jQuery(this).val() == '' || jQuery(this).val() == ' '){
                jQuery(this).val('Quick Message');
            }
        });
    }); //Contact Widget Message
	
    jQuery('ul.sitemap>li>a').css('background', 'none').wrap('<strong>');
    jQuery('a.marker').hover(function(){
        jQuery(this).stop().animate({
            paddingRight:'20px'
        }, 150);
    }, function(){
        jQuery(this).stop().animate({
            paddingRight:'15px'
        }, 150);
    });
	
    jQuery('ul.tour a').hover(function(){
        jQuery(this).stop().animate({
            paddingRight:'5px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            paddingRight:'0px'
        }, 200);
    });
	
    jQuery('.widget_links li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
    jQuery('.widget_recent_entries li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
    jQuery('ul.marker_left li').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
    jQuery('.widget_meta li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
	jQuery('.widget_categories li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
	jQuery('.widget_nav_menu li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
	jQuery('.widget_pages li').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 13px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 13px'
        }, 200);
    });
	
	jQuery('.widget_archive li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 6px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 6px'
        }, 200);
    });
	
    jQuery('.widget_custom_twitter_entries li').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 9px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 9px'
        }, 200);
    });
	
    jQuery('h6.marker').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'4px 9px'
        }, 150);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 9px'
        }, 150);
    });
	
    jQuery('a.marker_left').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 6px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 6px'
        }, 200);
    });
	
    jQuery('.map li a').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 5px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 5px'
        }, 200);
    });
	
    jQuery('a.marker_2').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 5px'
        }, 150);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'3px 5px'
        }, 150);
    });
	
    jQuery('div.jp-type-playlist div.jp-playlist li').hover(function(){
        jQuery(this).stop().animate({
            backgroundPosition:'5px 17px'
        }, 200);
    }, function(){
        jQuery(this).stop().animate({
            backgroundPosition:'0px 17px'
        }, 200);
    });
});



/* Images Hover Effect */
jQuery(document).ready(function(){
    var $container = jQuery('.image_shadow_container');
    $container.each(function(){
        jQuery('a.preloader').hover(function(){
            jQuery(this).stop().animate({
                top:'-10px'
            }, 200);
        }, function(){
            jQuery(this).stop().animate({
                top:'0'
            }, 200);
        });
        jQuery('a.preloader2').hover(function(){
            jQuery(this).stop().animate({
                top:'-10px'
            }, 200);
        }, function(){
            jQuery(this).stop().animate({
                top:'0'
            }, 200);
        });
        jQuery('a img.image_shadow').hover(function(){
            jQuery(this).stop().animate({
                top:'-10px'
            }, 200);
        }, function(){
            jQuery(this).stop().animate({
                top:'0'
            }, 200);
        });
    }); 
});



/* Header Line Show/Hide */
jQuery(document).ready(function(){
    jQuery('.header_plus').toggle(function(){
        closeAnimationPositions = [0, 1, 2, 3, 4, 5, 6];
        var positions = closeAnimationPositions.slice(0);
        jQuery(positions).each(function(i, position){
            var offset = position * -18;
            setTimeout(function() {
                jQuery('.header_plus').find('span').css({
                    backgroundPosition: "0 " + offset + "px"
                });
            }, i * 75);
        });
        jQuery('ul.header_list').slideToggle(500);
		jQuery('ul.header_icons').slideToggle(500);
        return false;
    }, function(){
        closeAnimationPositions = [6, 5, 4, 3, 2, 1, 0];
        var positions = closeAnimationPositions.slice(0);
        jQuery(positions).each(function(i, position){
            var offset = position * -18;
            setTimeout(function() {
                jQuery('.header_plus').find('span').css({
                    backgroundPosition: "0 " + offset + "px"
                });
            }, i * 75);
        });
        jQuery('ul.header_list').slideToggle(500);
		jQuery('ul.header_icons').slideToggle(500);
        return false;
    });
});



/* Flickr Lightbox */
jQuery(document).ready(function() {
    jQuery('#flickr .flickr_badge_image a, .cmsmasters_flickr_widget .flickr_badge_image a').each(function(i){
        var src = jQuery(this).find('img').attr('src');
        var title = jQuery(this).find('img').attr('title');
        var src2 = src.replace(/_s.jpg/g, '.jpg');
        jQuery(this).removeAttr('href');
        jQuery(this).attr({
            href: src2,
            title: title,
            rel: 'prettyPhoto[flickr_gal]'
        });
    });
});



/* Scroll Top */
jQuery(document).ready(function(){
    jQuery('.divider a').click(function(){
        jQuery('html, body').animate({
            scrollTop:0
        }, 'slow');
        return false;
    });
});



/* Toggle */
jQuery(document).ready(function(){
    jQuery('.togg h6.tog').click(function(i){
        var dropDown = jQuery(this).parent().find('.tab_content');
        jQuery(this).parent().find('.tab_content').not(dropDown).slideUp();
        if (jQuery(this).hasClass('current')){
            jQuery(this).removeClass('current');
        } else { 
            jQuery(this).addClass('current');
        }
        dropDown.stop(false,true).slideToggle().css({
            display:'block'
        });
        i.preventDefault();
    })
});



/* Accordion */
jQuery(document).ready(function(){
    jQuery('.accordion h6.tog').click(function(i){
        if (jQuery(this).hasClass('current')){ 
            jQuery(this).removeClass('current');
        } else { 
            jQuery(this).parent().parent().find('.tog').removeClass('current');
            jQuery(this).addClass('current');
        }
        var dropDown = jQuery(this).parent().find('.tab_content');
        jQuery(this).parent().parent().find('.tab_content').not(dropDown).slideUp();
        dropDown.stop(false,true).slideToggle().css({
            display:'block'
        });
        i.preventDefault();
    })
});



/* Tabs */
jQuery(document).ready(function(){
    jQuery('.tab ul.tabs li:first-child a').addClass('current');
    jQuery('.tab .tab_content div.tabs_tab:first-child').show();
    jQuery('.tab ul.tabs li a').click(function(e){
        $tab = jQuery(this).parent().parent().parent();
        $tab.find('ul.tabs').find('a').removeClass('current');
        jQuery(this).addClass('current');
        var $index = jQuery(this).parent().index();
        $tab.find('.tab_content').find('div.tabs_tab').not('div.tabs_tab:eq('+$index+')').slideUp();
        $tab.find('.tab_content').find('div.tabs_tab:eq('+$index+')').slideDown();
        e.preventDefault();
    })
});



/* Tour */
jQuery(document).ready(function(){
    jQuery('.tour_content ul.tour li:first-child').addClass('current');
    jQuery('.tour_content div.tour_box:first').show();
    jQuery('.tour_content ul.tour li a').click(function(e){
        $tour = jQuery(this).parent().parent().parent().parent();
        $tour.find('ul.tour').find('li').removeClass('current');
        jQuery(this).parent().addClass('current');
        var $index = jQuery('ul.tour li').index(jQuery(this).parent());
        $tour.find('div.tour_box').not('div.tour_box:eq('+$index+')').slideUp();
        $tour.find('div.tour_box:eq('+$index+')').slideDown();
        e.preventDefault();
    })
});



/* Popular and Latest Posts */
jQuery(document).ready(function(){
    jQuery('.related_posts ul li a').click(function(e){
        $rposts = jQuery(this).parent().parent().parent();
        $rposts.find('ul').find('a').removeClass('current');
        jQuery(this).addClass('current');
        var $index = jQuery(this).parent().index();
        $rposts.find('div.related_posts_content').not('div.related_posts_content:eq('+$index+')').slideUp();
        $rposts.find('div.related_posts_content:eq('+$index+')').slideDown();
        e.preventDefault();
    })
});



/* Pretty Photo Lighbox */
jQuery(document).ready(function(){
    jQuery('a[rel^="prettyPhoto"]').prettyPhoto({
        animationSpeed:'normal', 
        deeplinking:false, 
        social_tools:''
    });
});



/* Image Preloader */
jQuery(function(){
    var $imgContainerClassG = '.portfolio.gallery .post';
    var $images = jQuery($imgContainerClassG+' a img.image_shadow');
    var $max = $images.length;
    jQuery('.image_shadow_container a.preloader2').each(function(){
        jQuery('<span class="image_shadow_container_img" />').prependTo(jQuery(this));
    });
    $images.remove();
    if ($max > 0){
        LoadImage(0, $max);
    }
	
    function LoadImage(index, $max){
        if (index < $max){
            jQuery('<span id="img'+(index+1)+'" class="p_img_container" />').each(function(){
                jQuery(this).prependTo(jQuery('.post .image_shadow_container a.preloader2 .image_shadow_container_img').eq(index));
            });
            var $img = new Image();
            var $curr = jQuery('#img'+(index+1));
            jQuery($img).load(function(){
                jQuery($curr).append(this);
                jQuery(this).animate({
                    opacity: 1
                }, 200, 'easeInOutSine', function(){
                    jQuery(this).parent().parent().css({
                        backgroundImage: 'none'
                    });
                    if (index != ($max-1)){
                        LoadImage(index+1, $max);
                    }
                });
            }).error(function(){
                jQuery($curr).remove();
                LoadImage(index+1, $max);
            }).attr({
                src: jQuery($images[index]).attr('src'), 
                title: jQuery($images[index]).attr('title'), 
                alt: jQuery($images[index]).attr('alt')
            }).addClass(jQuery($images[index]).attr('class'));
        }
		
        if (index == ($max-1)){
            if (jQuery('#middle #home').find('.p_options_block').html() != null){
                LoadSorting2();
            }
        }
    }
	
    function LoadSorting2(){
        if (jQuery.browser.msie && jQuery.browser.version < 9){
            jQuery('.p_options_loader').css({
                display:'none'
            });
            jQuery('.p_options_block').css({
                display:'block'
            });
        } else {
            jQuery('.p_options_loader').css({
                display:'none'
            });
            jQuery('.portfolio').cmsmasters_portfolio_sort({
                items:'.post'
            });
        }
    }
});

jQuery(function(){
    var $imgContainerClass = '.portfolio';
    var $images = jQuery($imgContainerClass+':not(.gallery) .post a img.image_shadow');
    var $max = $images.length;
    jQuery('.image_shadow_container a.preloader').each(function(){
        jQuery('<span class="image_shadow_container_img" />').prependTo(jQuery(this));
    });
    $images.remove();
    if ($max > 0){
        LoadImage(0, $max);
    }
	
    function LoadImage(index, $max){
        if (index < $max){
            jQuery('<span id="img'+(index+1)+'" class="p_img_container" />').each(function(){
                jQuery(this).prependTo(jQuery('.post .image_shadow_container a.preloader .image_shadow_container_img').eq(index));
            });
            var $img = new Image();
            var $curr = jQuery('#img'+(index+1));
            jQuery($img).load(function(){
                jQuery($curr).append(this);
                jQuery(this).animate({
                    opacity: 1
                }, 200, 'easeInOutSine', function(){
                    jQuery(this).parent().parent().css({
                        backgroundImage: 'none'
                    });
                    if (index != ($max-1)){
                        LoadImage(index+1, $max);
                    }
                });
            }).error(function(){
                jQuery($curr).remove();
                LoadImage(index+1, $max);
            }).attr({
                src: jQuery($images[index]).attr('src'), 
                title: jQuery($images[index]).attr('title'), 
                alt: jQuery($images[index]).attr('alt')
            }).addClass(jQuery($images[index]).attr('class'));
        }
		
        if (index == ($max-1)){
            if (jQuery('#middle #home').find('.p_options_block').html() != null){
                LoadSorting();
            }
        }
    }
	
    function LoadSorting(){
        if (jQuery.browser.msie && jQuery.browser.version < 9){
            jQuery('.p_options_loader').css({
                display:'none'
            });
            jQuery('.p_options_block').css({
                display:'block'
            });
        } else {
            jQuery('.p_options_loader').css({
                display:'none'
            });
            jQuery('.portfolio').cmsmasters_portfolio_sort({
                items:'.post'
            });
        }
    }
});



/* Portfolio Sorting by Browser */
if (jQuery.browser.msie && jQuery.browser.version < 9){

    /* Portfolio Filter */
    jQuery(document).ready(function(){
        var newFilter = '', $p_item_width = 0, $p_item_all_count = 0, $p_item_count = 0, $p_item_number = 0, i = 0, j = 0, newFilterText = '';
        jQuery('ul.p_filter li:first-child a').addClass('current');
        jQuery('.p_cat_filter').attr({
            name: jQuery('ul.p_filter li.current a').attr('name')
            });
        jQuery('ul.p_filter li a').click(function(){
            newFilter = jQuery(this).attr('name');
            newFilterText = jQuery(this).text();
            jQuery('.p_cat_filter').text(newFilterText).attr({
                name: newFilter
            });
            jQuery('.portfolio div.fl').each(function(i){
                jQuery(this).removeClass('fl');
            });
            jQuery('.portfolio div.cl').each(function(i){
                jQuery(this).remove();
            });
            if (jQuery('.portfolio').hasClass('four_blocks')){
                $p_item_width = 220;
                $p_item_count = 4;
            } else {
                if (jQuery('.portfolio').hasClass('three_blocks')){
                    $p_item_width = 300;
                    $p_item_count = 3;
                } else {
                    if (jQuery('.portfolio').hasClass('two_blocks')){
                        $p_item_width = 460;
                        $p_item_count = 2;
                    } else {
                        $p_item_width = 940;
                        $p_item_count = 1;
                    }
                }
            }
            jQuery('ul.p_filter li a').removeClass('current').css('display', 'block');
            jQuery(this).addClass('current');
            jQuery('.post').not('.'+newFilter).animate({
                width: 0, 
                paddingRight: 0
            }, 500, function(){
                jQuery(this).css({
                    display: 'none'
                });
            });
            jQuery('.post').not('.gallery').find('a').find('img').parent().parent().not(jQuery(this).attr({
                rel: 'prettyPhoto[portfolio]'
            })).attr({
                rel: 'prettyPhoto[portfolio]'
            });
            jQuery('.'+newFilter).not('.gallery').find('a').find('img').parent().parent().attr({
                rel: 'prettyPhoto[portfolio'+newFilter+']'
                });
            jQuery('.'+newFilter).animate({
                width: $p_item_width, 
                paddingRight: '20px'
            }, 500, function(){
                jQuery(this).css({
                    display: 'block'
                });
            });
            $p_item_all_count = jQuery('.'+newFilter).length;
            j = Math.floor($p_item_all_count/$p_item_count)+1;
            i = 1;
            while (i < j){
                $p_item_number = ($p_item_count * i) - 1;
                jQuery('.'+newFilter).eq($p_item_number).after('<div class="cl" />');
                i++
            }
            return false;
        });
		
        var $p_filter_height = '';
        jQuery('.p_filter_container').hover(function(){
            jQuery(this).find('.p_cat_filter').addClass('hover');
            $p_filter_height = jQuery(this).find('ul.p_filter li').length * 28;
            jQuery(this).find('ul.p_filter').stop().animate({
                height: $p_filter_height + 'px', 
                paddingTop: '5px', 
                paddingBottom: '5px'
            }, 250);
        }, function(){
            jQuery(this).find('ul.p_filter').stop().animate({
                height: 0, 
                paddingTop: 0, 
                paddingBottom: 0
            }, 250);
            jQuery(this).find('.p_cat_filter').removeClass('hover');
        });
		
        jQuery('.p_cat_filter').click(function(){
            return false;
        });
    });



    /* Portfolio Sort */
    jQuery.fn.sort = (function(){
        var sort = [].sort;
        return function(comparator, getSortable){
            getSortable = getSortable || function(){
                return this;
            };
            var placements = this.map(function(){
                var sortElement = getSortable.call(this),
                parentNode = sortElement.parentNode,
                nextSibling = parentNode.insertBefore(
                    document.createTextNode(''),
                    sortElement.nextSibling
                    );
                return function(){
                    if (parentNode === this){
                        throw new Error("You can't sort elements if any one is a descendant of another.");
                    }
                    parentNode.insertBefore(this, nextSibling);
                    parentNode.removeChild(nextSibling);
                };
            });
            return sort.call(this, comparator).each(function(i){
                placements[i].call(getSortable.call(this));
            });
        };
    })();

    jQuery(document).ready(function(){
        var $date = jQuery('.p_sort a[name="p_date"]'), $name = jQuery('.p_sort a[name="p_name"]'), $p_item = jQuery('.portfolio .post'), inverse = false;
        $name.click(function(){
            jQuery('.portfolio').fadeTo(100, 0.25, function(){
                $p_item.sort(function(a, b){
                    a = jQuery(a).find('.p_name').text();
                    b = jQuery(b).find('.p_name').text();
                    return ( isNaN(a) || isNaN(b) ? a < b : +a < +b ) ? inverse ? -1 : 1 : inverse ? 1 : -1;
                });
                jQuery(this).fadeTo(300, 1);
            });
            $date.removeClass('current').removeClass('reversed');
            if (jQuery(this).hasClass('current') && jQuery(this).hasClass('reversed')){
                jQuery(this).removeClass('reversed');
            } else if (jQuery(this).hasClass('current')){
                jQuery(this).addClass('reversed');
            } else {
                jQuery(this).addClass('current').addClass('reversed');
            }
            inverse = !inverse;
            return false;
        });
        $date.click(function(){
            jQuery('.portfolio').fadeTo(100, 0.25, function(){
                $p_item.sort(function(a, b){
                    a = jQuery(a).find('.p_date').text();
                    b = jQuery(b).find('.p_date').text();
                    return ( isNaN(a) || isNaN(b) ? a > b : +a < +b ) ? inverse ? -1 : 1 : inverse ? 1 : -1;
                });			
                jQuery(this).fadeTo(300, 1);
            });
            $name.removeClass('current').removeClass('reversed');
            if (jQuery(this).hasClass('current') && jQuery(this).hasClass('reversed')){
                jQuery(this).removeClass('reversed');
            } else if (jQuery(this).hasClass('current')){
                jQuery(this).addClass('reversed');
            } else {
                jQuery(this).addClass('current').addClass('reversed');
            }
            inverse = !inverse;
            return false;
        });
    });

} else {

    /* Portfolio Filter Dropdown */
    jQuery(document).ready(function(){
        var $p_filter_height = '';
        jQuery('ul.p_filter li:first-child a').addClass('current');
        jQuery('.p_cat_filter').attr({
            name: jQuery('ul.p_filter li a.current').attr('name')
            });
		
        jQuery('ul.p_filter li a').click(function(){
            newFilter = jQuery(this).attr('name');
            newFilterText = jQuery(this).text();
            jQuery('.p_cat_filter').text(newFilterText).attr({
                title:newFilterText
            }).attr({
                name:newFilter
            });
        });
		
        jQuery('.p_filter_container').hover(function(){
            jQuery(this).find('.p_cat_filter').addClass('hover');
            $p_filter_height = jQuery(this).find('ul.p_filter li').length * 28;
            jQuery(this).find('ul.p_filter').stop().animate({
                height: $p_filter_height + 'px', 
                paddingTop: '5px', 
                paddingBottom: '5px'
            }, 250);
        }, function(){
            jQuery(this).find('ul.p_filter').stop().animate({
                height: 0, 
                paddingTop: 0, 
                paddingBottom: 0
            }, 250);
            jQuery(this).find('.p_cat_filter').removeClass('hover');
        });
		
        jQuery('.p_cat_filter').click(function(){
            return false;
        });
    });



    /* Portfolio Sorting and Filtering */
    (function($){
        $.fn.cmsmasters_portfolio_sort = function(options){
            var defaults = {
                items:'.item',
                navContainer:'.p_sort_block',
                filterNav:'.p_filter',
                sortNav:'.p_sort'
            };
            var options = $.extend(defaults, options);
			
            return this.each(function(){
                var container = $(this),
                navContainer = $(options.navContainer),
                nav = navContainer.find('a:not(.p_cat_filter)'),
                items = container.find(options.items),
                itemPadding = parseInt(items.css('paddingBottom')),
                itemMargin = parseInt(items.css('marginBottom')),
                columns = 0,
                coordinates = new Array(),
                animationArray = new Array(),
                columnPlus = new Array();
					
                container.methods = {
                    preloadingDone:function(){
                        if (navContainer.length > 0 && !($.browser.msie && $.browser.version < 7)){	
                            container.css('height',container.height());
                            items.each(function(){
                                var item = $(this),
                                itemPos = item.position();
								
                                coordinates.push(itemPos); 
                            }).each(function(i){
                                var item = $(this);
								
                                item.css({
                                    position:'absolute', 
                                    top:coordinates[i].top+'px', 
                                    left:coordinates[i].left+'px'
                                    });
                            });
							
                            for (i = 0; i < coordinates.length; i++){
                                if (coordinates[i].top == coordinates[0].top){
                                    columns++;
                                }
                            }
							
                            navContainer.parent().css({
                                opacity:0, 
                                display:'block'
                            }).animate({
                                opacity:1
                            }, 500, 'easeInOutSine');
                            container.methods.bindfunctions();
                        }
                    },
					
                    bindfunctions:function(){
                        nav.click(function(){
                            var clickedElement = $(this),
                            elementFilter = this.name;
								
                            animationArray = new Array();
                            if (clickedElement.parent().is(options.sortNav)){
                                clickedElement.parent().find('.current').removeClass('current');
                            } else {
                                clickedElement.parent().parent().find('.current').removeClass('current');							
                            }
                            this.className += ' current';
							
                            if (clickedElement.parent().parent('ul').is(options.filterNav)){
                                var arrayIndex = 0,
                                columnIndex = 0;
								
                                columnPlus = new Array();
                                items.each(function(i){
                                    var item = $(this);
									
                                    if (item.is('.'+elementFilter)){	
                                        animationArray.push({
                                            element:item, 
                                            animation:{ 
                                                opacity:1,
                                                top:coordinates[arrayIndex].top,
                                                left:coordinates[arrayIndex].left
                                            },
                                            height:item.height()
                                        });
										
                                        if (columnTop < coordinates[arrayIndex].top){
                                            columnTop = coordinates[arrayIndex].top;
                                        }
										
                                        columnIndex++;
                                        arrayIndex++;
                                    } else {
                                        animationArray.push({
                                            element:item,
                                            animation:{
                                                opacity:0,
                                                top:0
                                            },
                                            callback:true
                                        });
                                    }
									
                                    if (items.length == i+1 || columnIndex == columns){	
                                        var columnTop = 0;
										
                                        for (x = 0; x < columnIndex; x++){
                                            if (animationArray[i-x].height){
                                                if (columnTop < animationArray[i-x].height){
                                                    columnTop = animationArray[i-x].height;
                                                }
                                            } else {
                                                columnIndex++;
                                            }
                                        }
										
                                        columnPlus.push(columnTop);
                                        columnIndex = 0;
                                    }
									
                                    if (items.length == i+1){
                                        container.methods.startAnimation();
                                    }
                                });
                            } else {
                                var sortitems = items.get(),
                                reversed = false;
								
                                if (clickedElement.hasClass('reversed') && clickedElement.hasClass('current')){ 
                                    reversed = true;
                                    clickedElement.removeClass('reversed');
                                } else {
                                    $(options.sortNav).find('a').removeClass('reversed');
                                    clickedElement.addClass('reversed');
                                }
								
                                sortitems.sort(function(a, b){
                                    var compA = $(a).find('.'+elementFilter).text().toUpperCase();
                                    var compB = $(b).find('.'+elementFilter).text().toUpperCase();
									
                                    if (reversed){
                                        return (compA < compB) ? 1 : (compA > compB) ? -1 : 0;				
                                    } else {
                                        return (compA < compB) ? -1 : (compA > compB) ? 1 : 0;
                                    }
                                });
								
                                items = $(sortitems);
                                $(options.filterNav).find('.current').trigger('click');
                            }
							
                            return false;
                        });
                    },
					
                    startAnimation:function(){	
                        var heightmodifier = coordinates[0].top,
                        visibleElement = 0,
                        currentCol = 0;
						
                        for (i = 0; i < animationArray.length; i++){
							
                            if (animationArray[i].animation.top){
                                if (visibleElement % columns == 0 && visibleElement != 0){
                                    heightmodifier += columnPlus[currentCol] + itemPadding + itemMargin;
                                    currentCol++;
                                }
								
                                visibleElement++;
                            }
							
                            animationArray[i].element.css({
                                display:'block'
                            }).animate(animationArray[i].animation, 800, 'easeInOutExpo', (function(i){
                                return function(){
                                    if (animationArray[i].callback == true){
                                        animationArray[i].element.css({
                                            display:'none'
                                        });
                                    }
                                }
                            })(i));
                        }
						
                        var newContainerHeight = coordinates[0].top;
						
                        for (z = 0; z < columnPlus.length; z++){
                            newContainerHeight += columnPlus[z] + itemMargin;
                        }
						
                        container.animate({
                            height:newContainerHeight
                        }, 800, 'easeInOutSine');
                    }
                }
                container.methods.preloadingDone();
            });
        }
    })(jQuery);

}



/* Form */
function submitform() {
    document.forms['commentform'].submit();
	return false;
};



/* Twetter Widget */
function twitter(item){
    return jQuery('<li>').html('<p>'+formatString(item.description || item.title)+'<br /><small><a href="'+(item.link || item.guid)+'" target="_blank">'+relativeTime(item.pubDate)+'</a></small></p>');
}

function formatString(str){
    str = str.replace(/<[^>]+>/ig,'');
    str = ' '+str;
    str = str.replace(/((ftp|https?):\/\/([-\w\.]+)+(:\d+)?(\/([\w/_\.]*(\?\S+)?)?)?)/gm,'<a href="$1" target="_blank">$1</a>');
    str = str.replace(/([^\w])\@([\w\-]+)/gm,'$1@<a href="http://twitter.com/$2" target="_blank">$2</a>');
    str = str.replace(/([^\w])\#([\w\-]+)/gm,'$1<a href="http://twitter.com/search?q=%23$2" target="_blank">#$2</a>');
	
    return str;
}

function relativeTime(pastTime){
    var origStamp = Date.parse(pastTime);
    var curDate = new Date();
    var currentStamp = curDate.getTime();
    var difference = parseInt((currentStamp - origStamp)/1000);
    
	if (difference < 0) return false;
    
	if (difference <= 5) return 'Just now';
    
	if (difference <= 20) return 'Seconds ago';
    
	if (difference <= 60) return 'A minute ago';
    
	if (difference < 60*60) return parseInt(difference/60)+' minutes ago';
    
	if (difference <= 1.5*60*60) return 'One hour ago';
    
	if (difference < 23.5*60*60) return Math.round(difference/3600)+' hours ago';
	
    if (difference < 1.5*24*60*60) return 'One day ago';
	
    var dateArr = pastTime.split(' ');
	
    return dateArr[2]+' '+dateArr[1]+(dateArr[3]!=curDate.getFullYear()?' '+dateArr[3]:'');
} 



/* IE Fixes */
if (jQuery.browser.msie && jQuery.browser.version < 9){
    jQuery(document).ready(function(){
        jQuery('#ul.header_list li:last-child').css({
            'background':'none', 
            'padding-right':'0px'
        }); // Header Top Line
        jQuery('#navigation li:last-child').css('background-image', 'none'); // Navigation
        jQuery('#navigation li.nav_marker:last-child').css({
            'background-image':'url(../images/nav_marker.png)', 
            'background-position':'160px 13px'
        }); // Navigation
        jQuery('#navigation li.current_page_item.nav_marker:last-child').css({
            'background-image':'url(../images/nav_marker.png)', 
            'background-position':'160px -38px'
        }); // Navigation
        jQuery('#navigation li.nav_marker:last-child').hover(function(){
            jQuery(this).css({
                'background-position':'160px -38px'
            });
        }, function(){
            jQuery(this).css({
                'background-position':'160px 13px'
            });
        }); // Navigation
    });
};



if (jQuery.browser.msie && jQuery.browser.version < 8){
    jQuery(document).ready(function(){
        jQuery('blockquote').each(function(i){
            jQuery(this).wrap('<div class="blockquote_container" />');
            jQuery(this).before('<span class="blockquote_img quotation" />');
            jQuery(this).parent().find('.blockquote_img').html('&ldquo;');
        });	// Blockquote
		
        jQuery('code').each(function(i){
            jQuery(this).wrap('<div class="code" />');
            jQuery(this).before('<div class="code_inner" />');
            jQuery(this).parent().find('.code_inner').html('<span>code</span>');
        });	// Code
    });
};


