jQuery.fn.extend({everyTime:function(a,b,c,d,e){return this.each(function(){jQuery.timer.add(this,a,b,c,d,e)})},oneTime:function(a,b,c){return this.each(function(){jQuery.timer.add(this,a,b,c,1)})},stopTime:function(a,b){return this.each(function(){jQuery.timer.remove(this,a,b)})}}),jQuery.extend({timer:{guid:1,global:{},regex:/^([0-9]+)\s*(.*s)?$/,powers:{ms:1,cs:10,ds:100,s:1e3,das:1e4,hs:1e5,ks:1e6},timeParse:function(a){if(a==undefined||a==null)return null;var b=this.regex.exec(jQuery.trim(a.toString()));if(b[2]){var c=parseInt(b[1],10),d=this.powers[b[2]]||1;return c*d}return a},add:function(a,b,c,d,e,f){var g=0;jQuery.isFunction(c)&&(e||(e=d),d=c,c=b),b=jQuery.timer.timeParse(b);if(typeof b!="number"||isNaN(b)||b<=0)return;e&&e.constructor!=Number&&(f=!!e,e=0),e=e||0,f=f||!1,a.$timers||(a.$timers={}),a.$timers[c]||(a.$timers[c]={}),d.$timerID=d.$timerID||this.guid++;var h=function(){if(f&&this.inProgress)return;this.inProgress=!0,(++g>e&&e!==0||d.call(a,g)===!1)&&jQuery.timer.remove(a,c,d),this.inProgress=!1};h.$timerID=d.$timerID,a.$timers[c][d.$timerID]||(a.$timers[c][d.$timerID]=window.setInterval(h,b)),this.global[c]||(this.global[c]=[]),this.global[c].push(a)},remove:function(a,b,c){var d=a.$timers,e;if(d){if(!b)for(b in d)this.remove(a,b,c);else if(d[b]){if(c)c.$timerID&&(window.clearInterval(d[b][c.$timerID]),delete d[b][c.$timerID]);else for(var c in d[b])window.clearInterval(d[b][c]),delete d[b][c];for(e in d[b])break;e||(e=null,delete d[b])}for(e in d)break;e||(a.$timers=null)}}}}),jQuery.browser.msie&&jQuery(window).one("unload",function(){var a=jQuery.timer.global;for(var b in a){var c=a[b],d=c.length;while(--d)jQuery.timer.remove(c[d],b)}}),function(a){a.fn.vAlign=function(){return this.each(function(b){var c=a(this).height(),d=a(this).parent().height(),e=(d-c)/2;a(this).css("margin-top",e)})}}(jQuery),function(a){function b(b){var c;return b&&b.constructor==Array&&b.length==3?b:(c=/rgb\(\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*,\s*([0-9]{1,3})\s*\)/.exec(b))?[parseInt(c[1]),parseInt(c[2]),parseInt(c[3])]:(c=/rgb\(\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*,\s*([0-9]+(?:\.[0-9]+)?)\%\s*\)/.exec(b))?[parseFloat(c[1])*2.55,parseFloat(c[2])*2.55,parseFloat(c[3])*2.55]:(c=/#([a-fA-F0-9]{2})([a-fA-F0-9]{2})([a-fA-F0-9]{2})/.exec(b))?[parseInt(c[1],16),parseInt(c[2],16),parseInt(c[3],16)]:(c=/#([a-fA-F0-9])([a-fA-F0-9])([a-fA-F0-9])/.exec(b))?[parseInt(c[1]+c[1],16),parseInt(c[2]+c[2],16),parseInt(c[3]+c[3],16)]:d[a.trim(b).toLowerCase()]}function c(c,d){var e;do{e=a.curCSS(c,d);if(e!=""&&e!="transparent"||a.nodeName(c,"body"))break;d="backgroundColor"}while(c=c.parentNode);return b(e)}a.each(["backgroundColor","borderBottomColor","borderLeftColor","borderRightColor","borderTopColor","color","outlineColor"],function(d,e){a.fx.step[e]=function(a){a.state==0&&(a.start=c(a.elem,e),a.end=b(a.end)),a.elem.style[e]="rgb("+[Math.max(Math.min(parseInt(a.pos*(a.end[0]-a.start[0])+a.start[0]),255),0),Math.max(Math.min(parseInt(a.pos*(a.end[1]-a.start[1])+a.start[1]),255),0),Math.max(Math.min(parseInt(a.pos*(a.end[2]-a.start[2])+a.start[2]),255),0)].join(",")+")"}});var d={aqua:[0,255,255],azure:[240,255,255],beige:[245,245,220],black:[0,0,0],blue:[0,0,255],brown:[165,42,42],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgrey:[169,169,169],darkgreen:[0,100,0],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkviolet:[148,0,211],fuchsia:[255,0,255],gold:[255,215,0],green:[0,128,0],indigo:[75,0,130],khaki:[240,230,140],lightblue:[173,216,230],lightcyan:[224,255,255],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightyellow:[255,255,224],lime:[0,255,0],magenta:[255,0,255],maroon:[128,0,0],navy:[0,0,128],olive:[128,128,0],orange:[255,165,0],pink:[255,192,203],purple:[128,0,128],violet:[128,0,128],red:[255,0,0],silver:[192,192,192],white:[255,255,255],yellow:[255,255,0]}}(jQuery),$(document).ready(function(){$.fn.add_layer=function(a,b){$(this).each(function(){s=$(this).extend({},b||{}),$last=$(this).find(".add_background:last").length>0?$(this).find(".add_background:last"):$(this),$last.html('<div class="add_background"><div>'+$last.html()+"</div></div>"),$last=$(this).find(".add_background:last"),$last.css({background:a,width:"100%",height:"100%"}),$last=$(this).find(".add_background div:last"),s.insideCss&&$last.css(s.insideCss),s.insideClass&&$last.addClass(s.insideClass)})}}),function(a){a.ajaxHistory=new function(){var b="historyReset",c=location.hash,d=null,e;this.update=function(){};var f=function(){a(".remote-output").empty()};a(document).bind(b,f);if(a.browser.msie){var g,h=!1;a(function(){g=a('<iframe style="display: none;"></iframe>').appendTo(document.body).get(0);var b=g.contentWindow.document;b.open(),b.close(),c&&c!="#"&&(b.location.hash=c.replace("#",""))}),this.update=function(a){c=a;var b=g.contentWindow.document;b.open(),b.close(),b.location.hash=a.replace("#","")},e=function(){var d=g.contentWindow.document,e=d.location.hash;e!=c&&(c=e,e&&e!="#"?(a('a[@href$="'+e+'"]').click(),location.hash=e):h&&(location.hash="",a(document).trigger(b))),h=!0}}else if(a.browser.mozilla||a.browser.opera)this.update=function(a){c=a},e=function(){location.hash?c!=location.hash&&(c=location.hash,a('a[@href$="'+c+'"]').click()):c&&(c="",a(document).trigger(b))};else if(a.browser.safari){var i,j,k;a(function(){i=[],i.length=history.length,j=[]});var l=!1,h=!1;k=function(a){i.push(a),j.length=0,l=!1},this.update=function(a){c=a,k(c)},e=function(){var d=history.length-i.length;if(d){l=!1;if(d<0)for(var e=0;e<Math.abs(d);e++)j.unshift(i.pop());else for(var e=0;e<d;e++)i.push(j.shift());var f=i[i.length-1];a('a[@href$="'+f+'"]').click(),c=location.hash}else i[i.length-1]==undefined&&!l&&(document.URL.indexOf("#")>=0?a('a[@href$="#'+document.URL.split("#")[1]+'"]').click():h&&a(document).trigger(b),l=!0);h=!0}}this.initialize=function(c){typeof c=="function"&&a(document).unbind(b,f).bind(b,c),location.hash&&typeof k=="undefined"&&a('a[@href$="'+location.hash+'"]').trigger("click"),e&&d==null&&(d=setInterval(e,200))}},a.fn.remote=function(b,c,d){d=d||function(){},typeof c=="function"&&(d=c),c=a.extend({hashPrefix:"remote-"},c||{});var e=a(b).size()&&a(b)||a("<div></div>").appendTo("body");return e.addClass("remote-output"),this.each(function(b){var f=this.href,g="#"+(this.title&&this.title.replace(/\s/g,"_")||c.hashPrefix+(b+1)),h=this;this.href=g,a(this).click(function(b){e.locked||(b.clientX&&a.ajaxHistory.update(g),e.load(f,function(){e.locked=null,d.apply(h)}))})})},a.fn.history=function(b){return this.click(function(c){if(c.clientX){if(this.hash==location.hash)return!1;a.ajaxHistory.update(this.hash)}typeof b=="function"&&b.call(this)})}}(jQuery),function(a){a.fn.hoverIntent=function(b,c){var d={sensitivity:7,interval:100,timeout:0};d=a.extend(d,c?{over:b,out:c}:b);var e,f,g,h,i=function(a){e=a.pageX,f=a.pageY},j=function(b,c){c.hoverIntent_t=clearTimeout(c.hoverIntent_t);if(Math.abs(g-e)+Math.abs(h-f)<d.sensitivity)return a(c).unbind("mousemove",i),c.hoverIntent_s=1,d.over.apply(c,[b]);g=e,h=f,c.hoverIntent_t=setTimeout(function(){j(b,c)},d.interval)},k=function(a,b){return b.hoverIntent_t=clearTimeout(b.hoverIntent_t),b.hoverIntent_s=0,d.out.apply(b,[a])},l=function(b){var c=(b.type=="mouseover"?b.fromElement:b.toElement)||b.relatedTarget;while(c&&c!=this)try{c=c.parentNode}catch(b){c=this}if(c==this)return!1;var e=jQuery.extend({},b),f=this;f.hoverIntent_t&&(f.hoverIntent_t=clearTimeout(f.hoverIntent_t)),b.type=="mouseover"?(g=e.pageX,h=e.pageY,a(f).bind("mousemove",i),f.hoverIntent_s!=1&&(f.hoverIntent_t=setTimeout(function(){j(e,f)},d.interval))):(a(f).unbind("mousemove",i),f.hoverIntent_s==1&&(f.hoverIntent_t=setTimeout(function(){k(e,f)},d.timeout)))};return this.mouseover(l).mouseout(l)}}(jQuery),jQuery.easing.jswing=jQuery.easing.swing,jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(a,b,c,d,e){return jQuery.easing[jQuery.easing.def](a,b,c,d,e)},easeInQuad:function(a,b,c,d,e){return d*(b/=e)*b+c},easeOutQuad:function(a,b,c,d,e){return-d*(b/=e)*(b-2)+c},easeInOutQuad:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b+c:-d/2*(--b*(b-2)-1)+c},easeInCubic:function(a,b,c,d,e){return d*(b/=e)*b*b+c},easeOutCubic:function(a,b,c,d,e){return d*((b=b/e-1)*b*b+1)+c},easeInOutCubic:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b+c:d/2*((b-=2)*b*b+2)+c},easeInQuart:function(a,b,c,d,e){return d*(b/=e)*b*b*b+c},easeOutQuart:function(a,b,c,d,e){return-d*((b=b/e-1)*b*b*b-1)+c},easeInOutQuart:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b+c:-d/2*((b-=2)*b*b*b-2)+c},easeInQuint:function(a,b,c,d,e){return d*(b/=e)*b*b*b*b+c},easeOutQuint:function(a,b,c,d,e){return d*((b=b/e-1)*b*b*b*b+1)+c},easeInOutQuint:function(a,b,c,d,e){return(b/=e/2)<1?d/2*b*b*b*b*b+c:d/2*((b-=2)*b*b*b*b+2)+c},easeInSine:function(a,b,c,d,e){return-d*Math.cos(b/e*(Math.PI/2))+d+c},easeOutSine:function(a,b,c,d,e){return d*Math.sin(b/e*(Math.PI/2))+c},easeInOutSine:function(a,b,c,d,e){return-d/2*(Math.cos(Math.PI*b/e)-1)+c},easeInExpo:function(a,b,c,d,e){return b==0?c:d*Math.pow(2,10*(b/e-1))+c},easeOutExpo:function(a,b,c,d,e){return b==e?c+d:d*(-Math.pow(2,-10*b/e)+1)+c},easeInOutExpo:function(a,b,c,d,e){return b==0?c:b==e?c+d:(b/=e/2)<1?d/2*Math.pow(2,10*(b-1))+c:d/2*(-Math.pow(2,-10*--b)+2)+c},easeInCirc:function(a,b,c,d,e){return-d*(Math.sqrt(1-(b/=e)*b)-1)+c},easeOutCirc:function(a,b,c,d,e){return d*Math.sqrt(1-(b=b/e-1)*b)+c},easeInOutCirc:function(a,b,c,d,e){return(b/=e/2)<1?-d/2*(Math.sqrt(1-b*b)-1)+c:d/2*(Math.sqrt(1-(b-=2)*b)+1)+c},easeInElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(b==0)return c;if((b/=e)==1)return c+d;g||(g=e*.3);if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return-(h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g))+c},easeOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(b==0)return c;if((b/=e)==1)return c+d;g||(g=e*.3);if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return h*Math.pow(2,-10*b)*Math.sin((b*e-f)*2*Math.PI/g)+d+c},easeInOutElastic:function(a,b,c,d,e){var f=1.70158,g=0,h=d;if(b==0)return c;if((b/=e/2)==2)return c+d;g||(g=e*.3*1.5);if(h<Math.abs(d)){h=d;var f=g/4}else var f=g/(2*Math.PI)*Math.asin(d/h);return b<1?-0.5*h*Math.pow(2,10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)+c:h*Math.pow(2,-10*(b-=1))*Math.sin((b*e-f)*2*Math.PI/g)*.5+d+c},easeInBack:function(a,b,c,d,e,f){return f==undefined&&(f=1.70158),d*(b/=e)*b*((f+1)*b-f)+c},easeOutBack:function(a,b,c,d,e,f){return f==undefined&&(f=1.70158),d*((b=b/e-1)*b*((f+1)*b+f)+1)+c},easeInOutBack:function(a,b,c,d,e,f){return f==undefined&&(f=1.70158),(b/=e/2)<1?d/2*b*b*(((f*=1.525)+1)*b-f)+c:d/2*((b-=2)*b*(((f*=1.525)+1)*b+f)+2)+c},easeInBounce:function(a,b,c,d,e){return d-jQuery.easing.easeOutBounce(a,e-b,0,d,e)+c},easeOutBounce:function(a,b,c,d,e){return(b/=e)<1/2.75?d*7.5625*b*b+c:b<2/2.75?d*(7.5625*(b-=1.5/2.75)*b+.75)+c:b<2.5/2.75?d*(7.5625*(b-=2.25/2.75)*b+.9375)+c:d*(7.5625*(b-=2.625/2.75)*b+.984375)+c},easeInOutBounce:function(a,b,c,d,e){return b<e/2?jQuery.easing.easeInBounce(a,b*2,0,d,e)*.5+c:jQuery.easing.easeOutBounce(a,b*2-e,0,d,e)*.5+d*.5+c}}),function(a){function c(c,e){function m(b){var f=a(b);return e.globalNav?f:c.parent().find(b)}var g=this,h=a(this),i=!e.vertical,j=c.children(),k=0,l;b||(b=g),a.each(e,function(b,c){a.isFunction(c)&&h.bind(b,c)}),j.length>1&&(j=a(e.items,c)),c.data("finder",m);var n=m(e.prev),o=m(e.next),p=m(e.prevPage),q=m(e.nextPage);a.extend(g,{getIndex:function(){return k},getClickIndex:function(){var a=g.getItems();return a.index(a.filter("."+e.activeClass))},getConf:function(){return e},getSize:function(){return g.getItems().size()},getPageAmount:function(){return Math.ceil(this.getSize()/e.size)},getPageIndex:function(){return Math.ceil(k/e.size)},getNaviButtons:function(){return n.add(o).add(p).add(q)},getRoot:function(){return c},getItemWrap:function(){return j},getItems:function(){return j.children(e.item)},getVisibleItems:function(){return g.getItems().slice(k,k+e.size)},seekTo:function(c,l,m){function t(){m&&m.call(g,c),h.trigger("onSeek",[c])}c<0&&(c=0);if(k===c)return g;a.isFunction(l)&&(m=l);if(c>g.getSize()-e.size)return e.loop?g.begin():this.end();var r=g.getItems().eq(c);if(!r.length)return g;var s=a.Event("onBeforeSeek");h.trigger(s,[c]);if(s.isDefaultPrevented())return g;if(l===undefined||a.isFunction(l))l=e.speed;return i?j.animate({left:-r.position().left},l,e.easing,t):j.animate({top:-r.position().top},l,e.easing,t),b=g,k=c,s=a.Event("onStart"),h.trigger(s,[c]),s.isDefaultPrevented()?g:(n.add(p).toggleClass(e.disabledClass,c===0),o.add(q).toggleClass(e.disabledClass,c>=g.getSize()-e.size),g)},move:function(a,b,c){return l=a>0,this.seekTo(k+a,b,c)},next:function(a,b){return this.move(1,a,b)},prev:function(a,b){return this.move(-1,a,b)},movePage:function(a,b,c){l=a>0;var d=e.size*a,f=k%e.size;return f>0&&(d+=a>0?-f:e.size-f),this.move(d,b,c)},prevPage:function(a,b){return this.movePage(-1,a,b)},nextPage:function(a,b){return this.movePage(1,a,b)},setPage:function(a,b,c){return this.seekTo(a*e.size,b,c)},begin:function(a,b){return l=!1,this.seekTo(0,a,b)},end:function(a,b){l=!0;var c=this.getSize()-e.size;return c>0?this.seekTo(c,a,b):g},reload:function(){return h.trigger("onReload"),g},focus:function(){return b=g,g},click:function(a){var b=g.getItems().eq(a),c=e.activeClass,d=e.size;if(a<0||a>=g.getSize())return g;if(d==1){if(e.loop)return g.next();if(a===0||a==g.getSize()-1)l=l===undefined?!0:!l;return l===!1?g.prev():g.next()}if(d==2)return a==k&&a--,g.getItems().removeClass(c),b.addClass(c),g.seekTo(a,time,fn);if(!b.hasClass(c)){g.getItems().removeClass(c),b.addClass(c);var f=Math.floor(d/2),h=a-f;h>g.getSize()-d&&(h=g.getSize()-d);if(h!==a)return g.seekTo(h)}return g},bind:function(a,b){return h.bind(a,b),g},unbind:function(a){return h.unbind(a),g}}),a.each("onBeforeSeek,onStart,onSeek,onReload".split(","),function(a,b){g[b]=function(a){return g.bind(b,a)}}),n.addClass(e.disabledClass).click(function(){g.prev()}),o.click(function(){g.next()}),q.click(function(){g.nextPage()}),g.getSize()<e.size&&o.add(q).addClass(e.disabledClass),p.addClass(e.disabledClass).click(function(){g.prevPage()});var r=e.hoverClass,s="keydown."+Math.random().toString().substring(10);g.onReload(function(){r&&g.getItems().hover(function(){a(this).addClass(r)},function(){a(this).removeClass(r)}),e.clickable&&g.getItems().each(function(b){a(this).unbind("click.scrollable").bind("click.scrollable",function(c){if(a(c.target).is("a"))return;return g.click(b)})}),e.keyboard?a(document).unbind(s).bind(s,function(a){if(a.altKey||a.ctrlKey)return;if(e.keyboard!="static"&&b!=g)return;var c=e.keyboardSteps;return!i||a.keyCode!=37&&a.keyCode!=39?!!i||a.keyCode!=38&&a.keyCode!=40?!0:(g.move(a.keyCode==38?-c:c),a.preventDefault()):(g.move(a.keyCode==37?-c:c),a.preventDefault())}):a(document).unbind(s)}),g.reload()}a.tools=a.tools||{},a.tools.scrollable={version:"1.1.2",conf:{size:5,vertical:!1,speed:400,keyboard:!0,keyboardSteps:null,disabledClass:"disabled",hoverClass:null,clickable:!0,activeClass:"active",easing:"swing",loop:!1,items:".items",item:null,prev:".prev",next:".next",prevPage:".prevPage",nextPage:".nextPage",api:!1}};var b;a.fn.scrollable=function(b){var f=this.eq(typeof b=="number"?b:0).data("scrollable");if(f)return f;var g=a.extend({},a.tools.scrollable.conf);return b=a.extend(g,b),b.keyboardSteps=b.keyboardSteps||b.size,this.each(function(){f=new c(a(this),b),a(this).data("scrollable",f)}),b.api?f:this}}(jQuery),function(a){var b=a.tools.scrollable;b.plugins=b.plugins||{},b.plugins.circular={version:"0.5.1",conf:{api:!1,clonedClass:"cloned"}},a.fn.circular=function(e){var f=a.extend({},b.plugins.circular.conf),g;return a.extend(f,e),this.each(function(){function m(a){var b=k.eq(a);e.vertical?h.css({top:-b.position().top}):h.css({left:-b.position().left})}var b=a(this).scrollable(),d=b.getItems(),e=b.getConf(),h=b.getItemWrap(),i=0;b&&(g=b);if(d.length<e.size)return!1;d.slice(0,e.size).each(function(e){a(this).clone().appendTo(h).click(function(){b.click(d.length+e)}).addClass(f.clonedClass)});var j=a.makeArray(d.slice(-e.size)).reverse();a(j).each(function(d){a(this).clone().prependTo(h).click(function(){b.click(-d-1)}).addClass(f.clonedClass)});var k=h.children(e.item),l=e.hoverClass;l&&k.hover(function(){a(this).addClass(l)},function(){a(this).removeClass(l)}),m(e.size),a.extend(b,{move:function(a,c,f,g){var h=i+a+e.size,j=h>b.getSize()-e.size;if(h<=0||j){var l=i+e.size+(j?-d.length:d.length);m(l),h=l+a}return g&&k.removeClass(e.activeClass).eq(h+Math.floor(e.size/2)).addClass(e.activeClass),h===i+e.size?self:b.seekTo(h,c,f)},begin:function(a,b){return this.seekTo(e.size,a,b)},end:function(a,b){return this.seekTo(d.length,a,b)},click:function(a,b,c){if(!e.clickable)return self;if(e.size==1)return this.next();var d=a-i,f=e.activeClass;return d-=Math.floor(e.size/2),this.move(d,b,c,!0)},getIndex:function(){return i},setPage:function(a,b,c){return this.seekTo(a*e.size+e.size,b,c)},getPageAmount:function(){return Math.ceil(d.length/e.size)},getPageIndex:function(){if(i<0)return this.getPageAmount()-1;if(i>=d.length)return 0;var a=(i+e.size)/e.size-1;return a},getVisibleItems:function(){var a=i+e.size;return k.slice(a,a+e.size)}}),b.onStart(function(a,b){return i=b-e.size,!1}),b.getNaviButtons().removeClass(e.disabledClass)}),f.api?g:this}}(jQuery),function(a){var b=a.tools.scrollable;b.plugins=b.plugins||{},b.plugins.navigator={version:"1.0.2",conf:{navi:".navi",naviItem:null,activeClass:"active",indexed:!1,api:!1,idPrefix:null}},a.fn.navigator=function(e){var f=a.extend({},b.plugins.navigator.conf),g;return typeof e=="string"&&(e={navi:e}),e=a.extend(f,e),this.each(function(){function j(){if(!f.children().length||f.data("navi")==b){f.empty(),f.data("navi",b);for(var d=0;d<b.getPageAmount();d++)f.append(a("<"+(e.naviItem||"a")+"/>"));h=f.children().each(function(d){var f=a(this);f.click(function(a){return b.setPage(d),a.preventDefault()}),e.indexed&&f.text(d),e.idPrefix&&f.attr("id",e.idPrefix+d)})}else h=e.naviItem?f.find(e.naviItem):f.children(),h.each(function(d){var e=a(this);e.click(function(a){return b.setPage(d),a.preventDefault()})});h.eq(0).addClass(e.activeClass)}var b=a(this).scrollable(),d=b.getRoot(),f=d.data("finder").call(null,e.navi),h=null,i=b.getNaviButtons();b&&(g=b),b.getNaviButtons=function(){return i.add(f)},b.onStart(function(a,c){var d=e.activeClass;h.removeClass(d).eq(b.getPageIndex()).addClass(d)}),b.onReload(function(){j()}),j();var k=h.filter("[href="+location.hash+"]");k.length&&b.move(h.index(k))}),e.api?g:this}}(jQuery),function(a){function b(){if(a.browser.msie){var b=a(document).height(),c=a(window).height();return[window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,b-c<20?c:b]}return[a(window).width(),a(document).height()]}function c(c,f){var g=this,h=a(this),i=null,j=!1,k=0;a.each(f,function(b,c){a.isFunction(c)&&h.bind(b,c)}),a(window).resize(function(){g.fit()}),a.extend(this,{getMask:function(){return i},getExposed:function(){return c},getConf:function(){return f},isLoaded:function(){return j},load:function(o){if(j)return g;k=c.eq(0).css("zIndex"),f.maskId&&(i=a("#"+f.maskId));if(!i||!i.length){var p=b();i=a("<div/>").css({position:"absolute",top:0,left:0,width:p[0],height:p[1],display:"none",opacity:0,zIndex:f.zIndex}),f.maskId&&i.attr("id",f.maskId),a("body").append(i);var q=i.css("backgroundColor");(!q||q=="transparent"||q=="rgba(0, 0, 0, 0)")&&i.css("backgroundColor",f.color),f.closeOnEsc&&a(document).bind("keydown.unexpose",function(a){a.keyCode==27&&g.close()}),f.closeOnClick&&i.bind("click.unexpose",function(a){g.close(a)})}o=o||a.Event(),o.type="onBeforeLoad",h.trigger(o);if(o.isDefaultPrevented())return g;a.each(c,function(){var b=a(this);/relative|absolute|fixed/i.test(b.css("position"))||b.css("position","relative")}),c.css({zIndex:Math.max(f.zIndex+1,k=="auto"?0:k)});var r=i.height();return this.isLoaded()||i.css({opacity:0,display:"block"}).fadeTo(f.loadSpeed,f.opacity,function(){i.height()!=r&&i.css("height",r),o.type="onLoad",h.trigger(o)}),j=!0,g},close:function(b){return j?(b=b||a.Event(),b.type="onBeforeClose",h.trigger(b),b.isDefaultPrevented()?g:(i.fadeOut(f.closeSpeed,function(){b.type="onClose",h.trigger(b),c.css({zIndex:a.browser.msie?k:null})}),j=!1,g)):g},fit:function(){if(i){var a=b();i.css({width:a[0],height:a[1]})}},bind:function(a,b){return h.bind(a,b),g},unbind:function(a){return h.unbind(a),g}}),a.each("onBeforeLoad,onLoad,onBeforeClose,onClose".split(","),function(a,b){g[b]=function(a){return g.bind(b,a)}})}a.tools=a.tools||{},a.tools.expose={version:"1.0.5",conf:{maskId:null,loadSpeed:"slow",closeSpeed:"fast",closeOnClick:!0,closeOnEsc:!0,zIndex:9998,opacity:.8,color:"#456",api:!1}},a.fn.expose=function(b){var e=this.eq(typeof b=="number"?b:0).data("expose");if(e)return e;typeof b=="string"&&(b={color:b});var g=a.extend({},a.tools.expose.conf);return b=a.extend(g,b),this.each(function(){e=new c(a(this),b),a(this).data("expose",e)}),b.api?e:this}}(jQuery)
