(function(){function s(f,e){if(e){for(var g in e){if(e.hasOwnProperty(g)){f[g]=e[g]}}}return f}function d(f,e){var i=[];for(var g in f){if(f.hasOwnProperty(g)){i[g]=e(f[g])}}return i}function c(f,e,i){if(t.isSupported(e.version)){f.innerHTML=t.getHTML(e,i)}else{if(e.expressInstall&&t.isSupported([6,65])){f.innerHTML=t.getHTML(s(e,{src:e.expressInstall}),{MMredirectURL:location.href,MMplayerType:"PlugIn",MMdoctitle:document.title})}else{if(!f.innerHTML.replace(/\s/g,"")){f.innerHTML="<h2>Flash version "+e.version+" or greater is required</h2><h3>"+(r[0]>0?"Your version is "+r:"You have no flash plugin installed")+"</h3>"+(f.tagName=="A"?"<p>Click here to download latest version</p>":"<p>Download latest version from <a href='"+h+"'>here</a></p>");if(f.tagName=="A"){f.onclick=function(){location.href=h}}}if(e.onFail){var g=e.onFail.call(this);if(typeof g=="string"){f.innerHTML=g}}}}if(q){window[e.id]=document.getElementById(e.id)}s(this,{getRoot:function(){return f},getOptions:function(){return e},getConf:function(){return i},getApi:function(){return f.firstChild}})}var q=document.all,h="http://www.adobe.com/go/getflashplayer",b=typeof jQuery=="function",a=/(\d+)[^\d]+(\d+)[^\d]*(\d*)/,p={width:"100%",height:"100%",id:"_"+(""+Math.random()).slice(9),allowfullscreen:true,allowscriptaccess:"always",quality:"high",version:[3,0],onFail:null,expressInstall:null,w3c:false,cachebusting:false};window.attachEvent&&window.attachEvent("onbeforeunload",function(){__flash_unloadHandler=function(){};__flash_savedUnloadHandler=function(){}});window.flashembed=function(f,e,g){if(typeof f=="string"){f=document.getElementById(f.replace("#",""))}if(f){if(typeof e=="string"){e={src:e}}return new c(f,s(s({},p),e),g)}};var t=s(window.flashembed,{conf:p,getVersion:function(){var f,e;try{e=navigator.plugins["Shockwave Flash"].description.slice(16)}catch(j){try{e=(f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.7"))&&f.GetVariable("$version")}catch(i){try{e=(f=new ActiveXObject("ShockwaveFlash.ShockwaveFlash.6"))&&f.GetVariable("$version")}catch(g){}}}return(e=a.exec(e))?[e[1],e[3]]:[0,0]},asString:function(f){if(f===null||f===undefined){return null}var e=typeof f;if(e=="object"&&f.push){e="array"}switch(e){case"string":f=f.replace(new RegExp('(["\\\\])',"g"),"\\$1");f=f.replace(/^\s?(\d+\.?\d+)%/,"$1pct");return'"'+f+'"';case"array":return"["+d(f,function(i){return t.asString(i)}).join(",")+"]";case"function":return'"function()"';case"object":e=[];for(var g in f){f.hasOwnProperty(g)&&e.push('"'+g+'":'+t.asString(f[g]))}return"{"+e.join(",")+"}"}return String(f).replace(/\s/g," ").replace(/\'/g,'"')},getHTML:function(f,e){f=s({},f);var j='<object width="'+f.width+'" height="'+f.height+'" id="'+f.id+'" name="'+f.id+'"';if(f.cachebusting){f.src+=(f.src.indexOf("?")!=-1?"&":"?")+Math.random()}j+=f.w3c||!q?' data="'+f.src+'" type="application/x-shockwave-flash"':' classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"';j+=">";if(f.w3c||q){j+='<param name="movie" value="'+f.src+'" />'}f.width=f.height=f.id=f.w3c=f.src=null;f.onFail=f.version=f.expressInstall=null;for(var i in f){if(f[i]){j+='<param name="'+i+'" value="'+f[i]+'" />'}}f="";if(e){for(var g in e){if(e[g]){i=e[g];f+=g+"="+(/function|object/.test(typeof i)?t.asString(i):i)+"&"}}f=f.slice(0,-1);j+='<param name="flashvars" value=\''+f+"' />"}j+="</object>";return j},isSupported:function(e){return r[0]>e[0]||r[0]==e[0]&&r[1]>=e[1]}}),r=t.getVersion();if(b){jQuery.tools=jQuery.tools||{version:"1.2.5"};jQuery.tools.flashembed={conf:p};jQuery.fn.flashembed=function(f,e){return this.each(function(){$(this).data("flashembed",flashembed(this,f,e))})}}})();(function(a){function e(d){if(d){var b=l.contentWindow.document;b.open().close();b.location.hash=d}}var j,l,k,c;a.tools=a.tools||{version:"1.2.5"};a.tools.history={init:function(b){if(!c){if(a.browser.msie&&a.browser.version<"8"){if(!l){l=a("<iframe/>").attr("src","javascript:false;").hide().get(0);a("body").append(l);setInterval(function(){var d=l.contentWindow.document;d=d.location.hash;j!==d&&a.event.trigger("hash",d)},100);e(location.hash||"#")}}else{setInterval(function(){var d=location.hash;d!==j&&a.event.trigger("hash",d)},100)}k=!k?b:k.add(b);b.click(function(d){var f=a(this).attr("href");l&&e(f);if(f.slice(0,1)!="#"){location.href="#"+f;return d.preventDefault()}});c=true}}};a(window).bind("hash",function(d,b){b?k.filter(function(){var f=a(this).attr("href");return f==b||f==b.replace("#","")}).trigger("history",[b]):k.eq(0).trigger("history",[b]);j=b});a.fn.history=function(b){a.tools.history.init(this);return this.bind("history",b)}})(jQuery);(function(r){function d(){if(r.browser.msie){var b=r(document).height(),c=r(window).height();return[window.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,b-c<20?c:b]}return[r(document).width(),r(document).height()]}function n(b){if(b){return b.call(r.mask)}}r.tools=r.tools||{version:"1.2.5"};var a;a=r.tools.expose={conf:{maskId:"exposeMask",loadSpeed:"slow",closeSpeed:"fast",closeOnClick:true,closeOnEsc:true,zIndex:9998,opacity:0.8,startOpacity:0,color:"#fff",onLoad:null,onClose:null}};var q,m,p,o,f;r.mask={load:function(c,e){if(p){return this}if(typeof c=="string"){c={color:c}}c=c||o;o=c=r.extend(r.extend({},a.conf),c);q=r("#"+c.maskId);if(!q.length){q=r("<div/>").attr("id",c.maskId);r("body").append(q)}var b=d();q.css({position:"absolute",top:0,left:0,width:b[0],height:b[1],display:"none",opacity:c.startOpacity,zIndex:c.zIndex});c.color&&q.css("backgroundColor",c.color);if(n(c.onBeforeLoad)===false){return this}c.closeOnEsc&&r(document).bind("keydown.mask",function(g){g.keyCode==27&&r.mask.close(g)});c.closeOnClick&&q.bind("click.mask",function(g){r.mask.close(g)});r(window).bind("resize.mask",function(){r.mask.fit()});if(e&&e.length){f=e.eq(0).css("zIndex");r.each(e,function(){var g=r(this);/relative|absolute|fixed/i.test(g.css("position"))||g.css("position","relative")});m=e.css({zIndex:Math.max(c.zIndex+1,f=="auto"?0:f)})}q.css({display:"block"}).fadeTo(c.loadSpeed,c.opacity,function(){r.mask.fit();n(c.onLoad);p="full"});p=true;return this},close:function(){if(p){if(n(o.onBeforeClose)===false){return this}q.fadeOut(o.closeSpeed,function(){n(o.onClose);m&&m.css({zIndex:f});p=false});r(document).unbind("keydown.mask");q.unbind("click.mask");r(window).unbind("resize.mask")}return this},fit:function(){if(p){var b=d();q.css({width:b[0],height:b[1]})}},getMask:function(){return q},isLoaded:function(b){return b?p=="full":p},getConf:function(){return o},getExposed:function(){return m}};r.fn.mask=function(b){r.mask.load(b);return this};r.fn.expose=function(b){r.mask.load(b,this);return this}})(jQuery);(function(a){function f(b){switch(b.type){case"mousemove":return a.extend(b.data,{clientX:b.clientX,clientY:b.clientY,pageX:b.pageX,pageY:b.pageY});case"DOMMouseScroll":a.extend(b,b.data);b.delta=-b.detail/3;break;case"mousewheel":b.delta=b.wheelDelta/120;break}b.type="wheel";return a.event.handle.call(this,b,b.delta)}a.fn.mousewheel=function(b){return this[b?"bind":"trigger"]("wheel",b)};a.event.special.wheel={setup:function(){a.event.add(this,e,f,{})},teardown:function(){a.event.remove(this,e,f)}};var e=!a.browser.mozilla?"mousewheel":"DOMMouseScroll"+(a.browser.version<"1.9"?" mousemove":"")})(jQuery);(function(b){function c(f,e,n){var l=n.relative?f.position().top:f.offset().top,m=n.relative?f.position().left:f.offset().left,k=n.position[0];l-=e.outerHeight()-n.offset[0];m+=f.outerWidth()+n.offset[1];if(/iPad/i.test(navigator.userAgent)){l-=b(window).scrollTop()}var g=e.outerHeight()+f.outerHeight();if(k=="center"){l+=g/2}if(k=="bottom"){l+=g}k=n.position[1];f=e.outerWidth()+f.outerWidth();if(k=="center"){m-=f/2}if(k=="left"){m-=f}return{top:l,left:m}}function a(A,z){var y=this,w=A.add(y),x,u=0,p=0,g=A.attr("title"),f=A.attr("data-tooltip"),e=d[z.effect],n,D=A.is(":input"),B=D&&A.is(":checkbox, :radio, select, :button, :submit"),C=A.attr("type"),o=z.events[C]||z.events[D?B?"widget":"input":"def"];if(!e){throw'Nonexistent effect "'+z.effect+'"'}o=o.split(/,\s*/);if(o.length!=2){throw"Tooltip: bad events configuration for "+C}A.bind(o[0],function(h){clearTimeout(u);if(z.predelay){p=setTimeout(function(){y.show(h)},z.predelay)}else{y.show(h)}}).bind(o[1],function(h){clearTimeout(p);if(z.delay){u=setTimeout(function(){y.hide(h)},z.delay)}else{y.hide(h)}});if(g&&z.cancelDefault){A.removeAttr("title");A.data("title",g)}b.extend(y,{show:function(i){if(!x){if(f){x=b(f)}else{if(z.tip){x=b(z.tip).eq(0)}else{if(g){x=b(z.layout).addClass(z.tipClass).appendTo(document.body).hide().append(g)}else{x=A.next();x.length||(x=A.parent().next())}}}if(!x.length){throw"Cannot find tooltip for "+A}}if(y.isShown()){return y}x.stop(true,true);var h=c(A,x,z);z.tip&&x.html(A.data("title"));i=i||b.Event();i.type="onBeforeShow";w.trigger(i,[h]);if(i.isDefaultPrevented()){return y}h=c(A,x,z);x.css({position:"absolute",top:h.top,left:h.left});n=true;e[0].call(y,function(){i.type="onShow";n="full";w.trigger(i)});h=z.events.tooltip.split(/,\s*/);if(!x.data("__set")){x.bind(h[0],function(){clearTimeout(u);clearTimeout(p)});h[1]&&!A.is("input:not(:checkbox, :radio), textarea")&&x.bind(h[1],function(j){j.relatedTarget!=A[0]&&A.trigger(o[1].split(" ")[0])});x.data("__set",true)}return y},hide:function(h){if(!x||!y.isShown()){return y}h=h||b.Event();h.type="onBeforeHide";w.trigger(h);if(!h.isDefaultPrevented()){n=false;d[z.effect][1].call(y,function(){h.type="onHide";w.trigger(h)});return y}},isShown:function(h){return h?n=="full":n},getConf:function(){return z},getTip:function(){return x},getTrigger:function(){return A}});b.each("onHide,onBeforeShow,onShow,onBeforeHide".split(","),function(i,h){b.isFunction(z[h])&&b(y).bind(h,z[h]);y[h]=function(j){j&&b(y).bind(h,j);return y}})}b.tools=b.tools||{version:"1.2.5"};b.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(f,e,g){d[f]=[e,g]}};var d={toggle:[function(f){var e=this.getConf(),g=this.getTip();e=e.opacity;e<1&&g.css({opacity:e});g.show();f.call()},function(e){this.getTip().hide();e.call()}],fade:[function(f){var e=this.getConf();this.getTip().fadeTo(e.fadeInSpeed,e.opacity,f)},function(e){this.getTip().fadeOut(this.getConf().fadeOutSpeed,e)}]};b.fn.tooltip=function(f){var e=this.data("tooltip");if(e){return e}f=b.extend(true,{},b.tools.tooltip.conf,f);if(typeof f.position=="string"){f.position=f.position.split(/,?\s/)}this.each(function(){e=new a(b(this),f);b(this).data("tooltip",e)});return f.api?e:this}})(jQuery);(function(c){var a=c.tools.tooltip;c.extend(a.conf,{direction:"up",bounce:false,slideOffset:10,slideInSpeed:200,slideOutSpeed:200,slideFade:!c.browser.msie});var b={up:["-","top"],down:["+","top"],left:["-","left"],right:["+","left"]};a.addEffect("slide",function(h){var e=this.getConf(),i=this.getTip(),d=e.slideFade?{opacity:e.opacity}:{},j=b[e.direction]||b.up;d[j[1]]=j[0]+"="+e.slideOffset;e.slideFade&&i.css({opacity:0});i.show().animate(d,e.slideInSpeed,h)},function(j){var e=this.getConf(),k=e.slideOffset,d=e.slideFade?{opacity:0}:{},l=b[e.direction]||b.up,i=""+l[0];if(e.bounce){i=i=="+"?"-":"+"}d[l[1]]=i+"="+k;this.getTip().animate(d,e.slideOutSpeed,function(){c(this).hide();j.call()})})})(jQuery);(function(d){function b(e){var i=d(window),g=i.width()+i.scrollLeft(),f=i.height()+i.scrollTop();return[e.offset().top<=i.scrollTop(),g<=e.offset().left+e.width(),f<=e.offset().top+e.height(),i.scrollLeft()>=e.offset().left]}function a(e){for(var f=e.length;f--;){if(e[f]){return false}}return true}var c=d.tools.tooltip;c.dynamic={conf:{classNames:"top right bottom left"}};d.fn.dynamic=function(e){if(typeof e=="number"){e={speed:e}}e=d.extend({},c.dynamic.conf,e);var g=e.classNames.split(/\s/),f;this.each(function(){var i=d(this).tooltip().onBeforeShow(function(k,j){k=this.getTip();var h=this.getConf();f||(f=[h.position[0],h.position[1],h.offset[0],h.offset[1],d.extend({},h)]);d.extend(h,f[4]);h.position=[f[0],f[1]];h.offset=[f[2],f[3]];k.css({visibility:"hidden",position:"absolute",top:j.top,left:j.left}).show();j=b(k);if(!a(j)){if(j[2]){d.extend(h,e.top);h.position[0]="top";k.addClass(g[0])}if(j[3]){d.extend(h,e.right);h.position[1]="right";k.addClass(g[1])}if(j[0]){d.extend(h,e.bottom);h.position[0]="bottom";k.addClass(g[2])}if(j[1]){d.extend(h,e.left);h.position[1]="left";k.addClass(g[3])}if(j[0]||j[2]){h.offset[0]*=-1}if(j[1]||j[3]){h.offset[1]*=-1}}k.css({visibility:"visible"}).hide()});i.onBeforeShow(function(){var h=this.getConf();this.getTip();setTimeout(function(){h.position=[f[0],f[1]];h.offset=[f[2],f[3]]},0)});i.onHide(function(){var h=this.getTip();h.removeClass(e.classNames)});ret=i});return e.api?ret:this}})(jQuery);(function(d){function c(g,h){var e=d(h);return e.length<2?e:g.parent().find(h)}function b(v,w){var x=this,i=v.add(x),u=v.children(),p=0,r=w.vertical;a||(a=x);if(u.length>1){u=d(w.items,v)}d.extend(x,{getConf:function(){return w},getIndex:function(){return p},getSize:function(){return x.getItems().size()},getNaviButtons:function(){return h.add(e)},getRoot:function(){return v},getItemWrap:function(){return u},getItems:function(){return u.children(w.item).not("."+w.clonedClass)},move:function(f,g){return x.seekTo(p+f,g)},next:function(f){return x.move(1,f)},prev:function(f){return x.move(-1,f)},begin:function(f){return x.seekTo(0,f)},end:function(f){return x.seekTo(x.getSize()-1,f)},focus:function(){return a=x},addItem:function(f){f=d(f);if(w.circular){u.children("."+w.clonedClass+":last").before(f);u.children("."+w.clonedClass+":first").replaceWith(f.clone().addClass(w.clonedClass))}else{u.append(f)}i.trigger("onAddItem",[f]);return x},seekTo:function(f,m,j){f.jquery||(f*=1);if(w.circular&&f===0&&p==-1&&m!==0){return x}if(!w.circular&&f<0||f>x.getSize()||f<-1){return x}var g=f;if(f.jquery){f=x.getItems().index(f)}else{g=x.getItems().eq(f)}var l=d.Event("onBeforeSeek");if(!j){i.trigger(l,[f,m]);if(l.isDefaultPrevented()||!g.length){return x}}g=r?{top:-g.position().top}:{left:-g.position().left};p=f;a=x;if(m===undefined){m=w.speed}u.animate(g,m,w.easing,j||function(){i.trigger("onSeek",[f])});return x}});d.each(["onBeforeSeek","onSeek","onAddItem"],function(f,g){d.isFunction(w[g])&&d(x).bind(g,w[g]);x[g]=function(j){j&&d(x).bind(g,j);return x}});if(w.circular){var z=x.getItems().slice(-1).clone().prependTo(u),y=x.getItems().eq(1).clone().appendTo(u);z.add(y).addClass(w.clonedClass);x.onBeforeSeek(function(f,j,g){if(!f.isDefaultPrevented()){if(j==-1){x.seekTo(z,g,function(){x.end(0)});return f.preventDefault()}else{j==x.getSize()&&x.seekTo(y,g,function(){x.begin(0)})}}});x.seekTo(0,0,function(){})}var h=c(v,w.prev).click(function(){x.prev()}),e=c(v,w.next).click(function(){x.next()});if(!w.circular&&x.getSize()>1){x.onBeforeSeek(function(f,g){setTimeout(function(){if(!f.isDefaultPrevented()){h.toggleClass(w.disabledClass,g<=0);e.toggleClass(w.disabledClass,g>=x.getSize()-1)}},1)});w.initialIndex||h.addClass(w.disabledClass)}w.mousewheel&&d.fn.mousewheel&&v.mousewheel(function(f,g){if(w.mousewheel){x.move(g<0?1:-1,w.wheelSpeed||50);return false}});if(w.touch){var k={};u[0].ontouchstart=function(f){f=f.touches[0];k.x=f.clientX;k.y=f.clientY};u[0].ontouchmove=function(f){if(f.touches.length==1&&!u.is(":animated")){var j=f.touches[0],g=k.x-j.clientX;j=k.y-j.clientY;x[r&&j>0||!r&&g>0?"next":"prev"]();f.preventDefault()}}}w.keyboard&&d(document).bind("keydown.scrollable",function(f){if(!(!w.keyboard||f.altKey||f.ctrlKey||d(f.target).is(":input"))){if(!(w.keyboard!="static"&&a!=x)){var g=f.keyCode;if(r&&(g==38||g==40)){x.move(g==38?-1:1);return f.preventDefault()}if(!r&&(g==37||g==39)){x.move(g==37?-1:1);return f.preventDefault()}}}});w.initialIndex&&x.seekTo(w.initialIndex,0,function(){})}d.tools=d.tools||{version:"1.2.5"};d.tools.scrollable={conf:{activeClass:"active",circular:false,clonedClass:"cloned",disabledClass:"disabled",easing:"swing",initialIndex:0,item:null,items:".items",keyboard:true,mousewheel:false,next:".next",prev:".prev",speed:400,vertical:false,touch:true,wheelSpeed:0}};var a;d.fn.scrollable=function(e){var g=this.data("scrollable");if(g){return g}e=d.extend({},d.tools.scrollable.conf,e);this.each(function(){g=new b(d(this),e);d(this).data("scrollable",g)});return e.api?g:this}})(jQuery);(function(a){var c=a.tools.scrollable;c.autoscroll={conf:{autoplay:true,interval:3000,autopause:true}};a.fn.autoscroll=function(f){if(typeof f=="number"){f={interval:f}}var e=a.extend({},c.autoscroll.conf,f),b;this.each(function(){var d=a(this).data("scrollable");if(d){b=d}var i,g=true;d.play=function(){if(!i){g=false;i=setInterval(function(){d.next()},e.interval)}};d.pause=function(){i=clearInterval(i)};d.stop=function(){d.pause();g=true};e.autopause&&d.getRoot().add(d.getNaviButtons()).hover(d.pause,d.play);e.autoplay&&d.play()});return e.api?b:this}})(jQuery);(function(c){function b(d,f){var e=c(f);return e.length<2?e:d.parent().find(f)}var a=c.tools.scrollable;a.navigator={conf:{navi:".navi",naviItem:null,activeClass:"active",indexed:false,idPrefix:null,history:false}};c.fn.navigator=function(d){if(typeof d=="string"){d={navi:d}}d=c.extend({},a.navigator.conf,d);var e;this.each(function(){function t(f,j,h){v.seekTo(j);if(s){if(location.hash){location.hash=f.attr("href").replace("#","")}}else{return h.preventDefault()}}function u(){return r.find(d.naviItem||"> *")}function m(f){var h=c("<"+(d.naviItem||"a")+"/>").click(function(j){t(c(this),f,j)}).attr("href","#"+f);f===0&&h.addClass(p);d.indexed&&h.text(f+1);d.idPrefix&&h.attr("id",d.idPrefix+f);return h.appendTo(r)}function i(f,h){f=u().eq(h.replace("#",""));f.length||(f=u().filter("[href="+h+"]"));f.click()}var v=c(this).data("scrollable"),r=d.navi.jquery?d.navi:b(v.getRoot(),d.navi),g=v.getNaviButtons(),p=d.activeClass,s=d.history&&c.fn.history;if(v){e=v}v.getNaviButtons=function(){return g.add(r)};u().length?u().each(function(f){c(this).click(function(h){t(c(this),f,h)})}):c.each(v.getItems(),function(f){m(f)});v.onBeforeSeek(function(f,h){setTimeout(function(){if(!f.isDefaultPrevented()){var j=u().eq(h);!f.isDefaultPrevented()&&j.length&&u().removeClass(p).eq(h).addClass(p)}},1)});v.onAddItem(function(f,h){h=m(v.getItems().index(h));s&&h.history(i)});s&&u().history(i)});return d.api?e:this}})(jQuery);(function(b){function c(u,w){var v=this,r=u.add(v),h=b(window),q,t,l,s=b.tools.expose&&(w.mask||w.expose),i=Math.random().toString().slice(10);if(s){if(typeof s=="string"){s={color:s}}s.closeOnClick=s.closeOnEsc=false}var a=w.target||u.attr("rel");t=a?b(a):u;if(!t.length){throw"Could not find Overlay: "+a}u&&u.index(t)==-1&&u.click(function(f){v.load(f);return f.preventDefault()});b.extend(v,{load:function(n){if(v.isOpened()){return v}var k=e[w.effect];if(!k){throw'Overlay: cannot find effect : "'+w.effect+'"'}w.oneInstance&&b.each(d,function(){this.close(n)});n=n||b.Event();n.type="onBeforeLoad";r.trigger(n);if(n.isDefaultPrevented()){return v}l=true;s&&b(t).expose(s);var j=w.top,m=w.left,g=t.outerWidth({margin:true}),f=t.outerHeight({margin:true});if(typeof j=="string"){j=j=="center"?Math.max((h.height()-f)/2,0):parseInt(j,10)/100*h.height()}if(m=="center"){m=Math.max((h.width()-g)/2,0)}k[0].call(v,{top:j,left:m},function(){if(l){n.type="onLoad";r.trigger(n)}});s&&w.closeOnClick&&b.mask.getMask().one("click",v.close);w.closeOnClick&&b(document).bind("click."+i,function(o){b(o.target).parents(t).length||v.close(o)});w.closeOnEsc&&b(document).bind("keydown."+i,function(o){o.keyCode==27&&v.close(o)});return v},close:function(f){if(!v.isOpened()){return v}f=f||b.Event();f.type="onBeforeClose";r.trigger(f);if(!f.isDefaultPrevented()){l=false;e[w.effect][1].call(v,function(){f.type="onClose";r.trigger(f)});b(document).unbind("click."+i).unbind("keydown."+i);s&&b.mask.close();return v}},getOverlay:function(){return t},getTrigger:function(){return u},getClosers:function(){return q},isOpened:function(){return l},getConf:function(){return w}});b.each("onBeforeLoad,onStart,onLoad,onBeforeClose,onClose".split(","),function(g,f){b.isFunction(w[f])&&b(v).bind(f,w[f]);v[f]=function(j){j&&b(v).bind(f,j);return v}});q=t.find(w.close||".close");if(!q.length&&!w.close){q=b('<a class="close"></a>');t.prepend(q)}q.click(function(f){v.close(f)});w.load&&v.load()}b.tools=b.tools||{version:"1.2.5"};b.tools.overlay={addEffect:function(f,a,g){e[f]=[a,g]},conf:{close:null,closeOnClick:true,closeOnEsc:true,closeSpeed:"fast",effect:"default",fixed:!b.browser.msie||b.browser.version>6,left:"center",load:false,mask:null,oneInstance:true,speed:"normal",target:null,top:"10%"}};var d=[],e={};b.tools.overlay.addEffect("default",function(g,a){var h=this.getConf(),f=b(window);if(!h.fixed){g.top+=f.scrollTop();g.left+=f.scrollLeft()}g.position=h.fixed?"fixed":"absolute";this.getOverlay().css(g).fadeIn(h.speed,a)},function(a){this.getOverlay().fadeOut(this.getConf().closeSpeed,a)});b.fn.overlay=function(f){var a=this.data("overlay");if(a){return a}if(b.isFunction(f)){f={onBeforeLoad:f}}f=b.extend(true,{},b.tools.overlay.conf,f);this.each(function(){a=new c(b(this),f);d.push(a);b(this).data("overlay",a)});return f.api?a:this}})(jQuery);(function(n){function l(d,p){return 32-(new Date(d,p,32)).getDate()}function k(d,p){d=""+d;for(p=p||2;d.length<p;){d="0"+d}return d}function j(d,w,p){var v=d.getDate(),s=d.getDay(),t=d.getMonth();d=d.getFullYear();var u={d:v,dd:k(v),ddd:e[p].shortDays[s],dddd:e[p].days[s],m:t+1,mm:k(t+1),mmm:e[p].shortMonths[t],mmmm:e[p].months[t],yy:String(d).slice(2),yyyy:d};w=w.replace(f,function(q){return q in u?u[q]:q.slice(1,q.length-1)});return c.html(w).html()}function o(d){return parseInt(d,10)}function i(d,p){return d.getFullYear()===p.getFullYear()&&d.getMonth()==p.getMonth()&&d.getDate()==p.getDate()}function a(d){if(d){if(d.constructor==Date){return d}if(typeof d=="string"){var p=d.split("-");if(p.length==3){return new Date(o(p[0]),o(p[1])-1,o(p[2]))}if(!/^-?\d+$/.test(d)){return}d=o(d)}p=new Date;p.setDate(p.getDate()+d);return p}}function b(ag,af){function ac(p,r,q){Z=p;U=p.getFullYear();S=p.getMonth();R=p.getDate();q=q||n.Event("api");q.type="change";P.trigger(q,[p]);if(!q.isDefaultPrevented()){ag.val(j(p,r.format,r.lang));ag.data("date",p);ad.hide(q)}}function W(p){p.type="onShow";P.trigger(p);n(document).bind("keydown.d",function(w){if(w.ctrlKey){return true}var s=w.keyCode;if(s==8){ag.val("");return ad.hide(w)}if(s==27){return ad.hide(w)}if(n(h).index(s)>=0){if(!Q){ad.show(w);return w.preventDefault()}var r=n("#"+ae.weeks+" a"),q=n("."+ae.focus),z=r.index(q);q.removeClass(ae.focus);if(s==74||s==40){z+=7}else{if(s==75||s==38){z-=7}else{if(s==76||s==39){z+=1}else{if(s==72||s==37){z-=1}}}}if(z>41){ad.addMonth();q=n("#"+ae.weeks+" a:eq("+(z-42)+")")}else{if(z<0){ad.addMonth(-1);q=n("#"+ae.weeks+" a:eq("+(z+42)+")")}else{q=r.eq(z)}}q.addClass(ae.focus);return w.preventDefault()}if(s==34){return ad.addMonth()}if(s==33){return ad.addMonth(-1)}if(s==36){return ad.today()}if(s==13){n(w.target).is("select")||n("."+ae.focus).click()}return n([16,17,18,9]).index(s)>=0});n(document).bind("click.d",function(r){var q=r.target;if(!n(q).parents("#"+ae.root).length&&q!=ag[0]&&(!x||q!=x[0])){ad.hide(r)}})}var ad=this,V=new Date,ae=af.css,T=e[af.lang],ab=n("#"+ae.root),v=ab.find("#"+ae.title),x,F,C,U,S,R,Z=ag.attr("data-value")||af.value||ag.val(),aa=ag.attr("min")||af.min,Y=ag.attr("max")||af.max,Q;if(aa===0){aa="0"}Z=a(Z)||V;aa=a(aa||af.yearRange[0]*365);Y=a(Y||af.yearRange[1]*365);if(!T){throw"Dateinput: invalid language: "+af.lang}if(ag.attr("type")=="date"){var u=n("<input/>");n.each("class,disabled,id,maxlength,name,readonly,required,size,style,tabindex,title,value".split(","),function(p,q){u.attr(q,ag.attr(q))});ag.replaceWith(u);ag=u}ag.addClass(ae.input);var P=ag.add(ad);if(!ab.length){ab=n("<div><div><a/><div/><a/></div><div><div/><div/></div></div>").hide().css({position:"absolute"}).attr("id",ae.root);ab.children().eq(0).attr("id",ae.head).end().eq(1).attr("id",ae.body).children().eq(0).attr("id",ae.days).end().eq(1).attr("id",ae.weeks).end().end().end().find("a").eq(0).attr("id",ae.prev).end().eq(1).attr("id",ae.next);v=ab.find("#"+ae.head).find("div").attr("id",ae.title);if(af.selectors){var B=n("<select/>").attr("id",ae.month),X=n("<select/>").attr("id",ae.year);v.html(B.add(X))}for(var d=ab.find("#"+ae.days),t=0;t<7;t++){d.append(n("<span/>").text(T.shortDays[(t+af.firstDay)%7]))}n("body").append(ab)}if(af.trigger){x=n("<a/>").attr("href","#").addClass(ae.trigger).click(function(p){ad.show();return p.preventDefault()}).insertAfter(ag)}var y=ab.find("#"+ae.weeks);X=ab.find("#"+ae.year);B=ab.find("#"+ae.month);n.extend(ad,{show:function(p){if(!(ag.attr("readonly")||ag.attr("disabled")||Q)){p=p||n.Event();p.type="onBeforeShow";P.trigger(p);if(!p.isDefaultPrevented()){n.each(g,function(){this.hide()});Q=true;B.unbind("change").change(function(){ad.setValue(X.val(),n(this).val())});X.unbind("change").change(function(){ad.setValue(n(this).val(),B.val())});F=ab.find("#"+ae.prev).unbind("click").click(function(){F.hasClass(ae.disabled)||ad.addMonth(-1);return false});C=ab.find("#"+ae.next).unbind("click").click(function(){C.hasClass(ae.disabled)||ad.addMonth();return false});ad.setValue(Z);var q=ag.offset();if(/iPad/i.test(navigator.userAgent)){q.top-=n(window).scrollTop()}ab.css({top:q.top+ag.outerHeight({margins:true})+af.offset[0],left:q.left+af.offset[1]});if(af.speed){ab.show(af.speed,function(){W(p)})}else{ab.show();W(p)}return ad}}},setValue:function(D,z,w){var r=o(z)>=-1?new Date(o(D),o(z),o(w||1)):D||Z;if(r<aa){r=aa}else{if(r>Y){r=Y}}D=r.getFullYear();z=r.getMonth();w=r.getDate();if(z==-1){z=11;D--}else{if(z==12){z=0;D++}}if(!Q){ac(r,af);return ad}S=z;U=D;w=new Date(D,z,1-af.firstDay);w=w.getDay();var G=l(D,z),p=l(D,z-1),s;if(af.selectors){B.empty();n.each(T.months,function(H,I){aa<new Date(D,H+1,-1)&&Y>new Date(D,H,0)&&B.append(n("<option/>").html(I).attr("value",H))});X.empty();r=V.getFullYear();for(var q=r+af.yearRange[0];q<r+af.yearRange[1];q++){aa<=new Date(q+1,-1,1)&&Y>new Date(q,0,0)&&X.append(n("<option/>").text(q))}B.val(z);X.val(D)}else{v.html(T.months[z]+" "+D)}y.empty();F.add(C).removeClass(ae.disabled);q=!w?-7:0;for(var E,A;q<(!w?35:42);q++){E=n("<a/>");if(q%7===0){s=n("<div/>").addClass(ae.week);y.append(s)}if(q<w){E.addClass(ae.off);A=p-w+q+1;r=new Date(D,z-1,A)}else{if(q>=w+G){E.addClass(ae.off);A=q-G-w+1;r=new Date(D,z+1,A)}else{A=q-w+1;r=new Date(D,z,A);if(i(Z,r)){E.attr("id",ae.current).addClass(ae.focus)}else{i(V,r)&&E.attr("id",ae.today)}}}aa&&r<aa&&E.add(F).addClass(ae.disabled);Y&&r>Y&&E.add(C).addClass(ae.disabled);E.attr("href","#"+A).text(A).data("date",r);s.append(E)}y.find("a").click(function(H){var I=n(this);if(!I.hasClass(ae.disabled)){n("#"+ae.current).removeAttr("id");I.attr("id",ae.current);ac(I.data("date"),af,H)}return false});ae.sunday&&y.find(ae.week).each(function(){var H=af.firstDay?7-af.firstDay:0;n(this).children().slice(H,H+1).addClass(ae.sunday)});return ad},setMin:function(p,q){aa=a(p);q&&Z<aa&&ad.setValue(aa);return ad},setMax:function(p,q){Y=a(p);q&&Z>Y&&ad.setValue(Y);return ad},today:function(){return ad.setValue(V)},addDay:function(p){return this.setValue(U,S,R+(p||1))},addMonth:function(p){return this.setValue(U,S+(p||1),R)},addYear:function(p){return this.setValue(U+(p||1),S,R)},hide:function(p){if(Q){p=n.Event();p.type="onHide";P.trigger(p);n(document).unbind("click.d").unbind("keydown.d");if(p.isDefaultPrevented()){return}ab.hide();Q=false}return ad},getConf:function(){return af},getInput:function(){return ag},getCalendar:function(){return ab},getValue:function(p){return p?j(Z,p,af.lang):Z},isOpen:function(){return Q}});n.each(["onBeforeShow","onShow","change","onHide"],function(p,q){n.isFunction(af[q])&&n(ad).bind(q,af[q]);ad[q]=function(r){r&&n(ad).bind(q,r);return ad}});ag.bind("focus click",ad.show).keydown(function(p){var q=p.keyCode;if(!Q&&n(h).index(q)>=0){ad.show(p);return p.preventDefault()}return p.shiftKey||p.ctrlKey||p.altKey||q==9?true:p.preventDefault()});a(ag.val())&&ac(Z,af)}n.tools=n.tools||{version:"1.2.5"};var g=[],m,h=[75,76,38,39,74,72,40,37],e={};m=n.tools.dateinput={conf:{format:"mm/dd/yy",selectors:false,yearRange:[-5,5],lang:"en",offset:[0,0],speed:0,firstDay:0,min:undefined,max:undefined,trigger:false,css:{prefix:"cal",input:"date",root:0,head:0,title:0,prev:0,next:0,month:0,year:0,days:0,body:0,weeks:0,today:0,current:0,week:0,off:0,sunday:0,focus:0,disabled:0,trigger:0}},localize:function(d,p){n.each(p,function(r,s){p[r]=s.split(",")});e[d]=p}};m.localize("en",{months:"January,February,March,April,May,June,July,August,September,October,November,December",shortMonths:"Jan,Feb,Mar,Apr,May,Jun,Jul,Aug,Sep,Oct,Nov,Dec",days:"Sunday,Monday,Tuesday,Wednesday,Thursday,Friday,Saturday",shortDays:"Sun,Mon,Tue,Wed,Thu,Fri,Sat"});var f=/d{1,4}|m{1,4}|yy(?:yy)?|"[^"]*"|'[^']*'/g,c=n("<a/>");n.expr[":"].date=function(d){var p=d.getAttribute("type");return p&&p=="date"||!!n(d).data("dateinput")};n.fn.dateinput=function(d){if(this.data("dateinput")){return this}d=n.extend(true,{},m.conf,d);n.each(d.css,function(r,s){if(!s&&r!="prefix"){d.css[r]=(d.css.prefix||"")+(s||r)}});var p;this.each(function(){var q=new b(n(this),d);g.push(q);q=q.getInput().data("dateinput",q);p=p?p.add(q):q});return p?p:this}})(jQuery);(function(g){function c(j,e){e=Math.pow(10,e);return Math.round(j*e)/e}function f(j,e){if(e=parseInt(j.css(e),10)){return e}return(j=j[0].currentStyle)&&j.width&&parseInt(j.width,10)}function h(e){return(e=e.data("events"))&&e.onSlide}function b(T,U){function R(o,k,n,l){if(n===undefined){n=k/P*e}else{if(l){n-=U.min}}if(F){n=Math.round(n/F)*F}if(k===undefined||F){k=n*P/e}if(isNaN(n)){return S}k=Math.max(0,Math.min(k,P));n=k/P*e;if(l||!M){n+=U.min}if(M){if(l){k=P-k}else{n=U.max-n}}n=c(n,C);var m=o.type=="click";if(E&&O!==undefined&&!m){o.type="onSlide";J.trigger(o,[n,k]);if(o.isDefaultPrevented()){return S}}l=m?U.speed:0;m=m?function(){o.type="change";J.trigger(o,[n])}:null;if(M){N.animate({top:k},l,m);U.progress&&G.animate({height:P-k+N.width()/2},l)}else{N.animate({left:k},l,m);U.progress&&G.animate({width:k+N.width()/2},l)}O=n;r=k;T.val(n);return S}function L(){if(M=U.vertical||f(Q,"height")>f(Q,"width")){P=f(Q,"height")-f(N,"height");y=Q.offset().top+P}else{P=f(Q,"width")-f(N,"width");y=Q.offset().left}}function x(){L();S.setValue(U.value!==undefined?U.value:U.min)}var S=this,K=U.css,Q=g("<div><div/><a href='#'/></div>").data("rangeinput",S),M,O,y,P,r;T.before(Q);var N=Q.addClass(K.slider).find("a").addClass(K.handle),G=Q.find("div").addClass(K.progress);g.each("min,max,step,value".split(","),function(l,k){l=T.attr(k);if(parseFloat(l)){U[k]=parseFloat(l,10)}});var e=U.max-U.min,F=U.step=="any"?0:U.step,C=U.precision;if(C===undefined){try{C=F.toString().split(".")[1].length}catch(j){C=0}}if(T.attr("type")=="range"){var q=g("<input/>");g.each("class,disabled,id,maxlength,name,readonly,required,size,style,tabindex,title,value".split(","),function(l,k){q.attr(k,T.attr(k))});q.val(U.value);T.replaceWith(q);T=q}T.addClass(K.input);var J=g(S).add(T),E=true;g.extend(S,{getValue:function(){return O},setValue:function(l,k){L();return R(k||g.Event("api"),undefined,l,true)},getConf:function(){return U},getProgress:function(){return G},getHandle:function(){return N},getInput:function(){return T},step:function(m,k){k=k||g.Event();var l=U.step=="any"?1:U.step;S.setValue(O+l*(m||1),k)},stepUp:function(k){return S.step(k||1)},stepDown:function(k){return S.step(-k||-1)}});g.each("onSlide,change".split(","),function(l,k){g.isFunction(U[k])&&g(S).bind(k,U[k]);S[k]=function(m){m&&g(S).bind(k,m);return S}});N.drag({drag:false}).bind("dragStart",function(){L();E=h(g(S))||h(T)}).bind("drag",function(m,k,l){if(T.is(":disabled")){return false}R(m,M?k:l)}).bind("dragEnd",function(k){if(!k.isDefaultPrevented()){k.type="change";J.trigger(k,[O])}}).click(function(k){return k.preventDefault()});Q.click(function(l){if(T.is(":disabled")||l.target==N[0]){return l.preventDefault()}L();var k=N.width()/2;R(l,M?P-y-k+l.pageY:l.pageX-y-k)});U.keyboard&&T.keydown(function(n){if(!T.attr("readonly")){var k=n.keyCode,m=g([75,76,38,33,39]).index(k)!=-1,l=g([74,72,40,34,37]).index(k)!=-1;if((m||l)&&!(n.shiftKey||n.altKey||n.ctrlKey)){if(m){S.step(k==33?10:1,n)}else{if(l){S.step(k==34?-10:-1,n)}}return n.preventDefault()}}});T.blur(function(l){var k=g(this).val();k!==O&&S.setValue(k,l)});g.extend(T[0],{stepUp:S.stepUp,stepDown:S.stepDown});x();P||g(window).load(x)}g.tools=g.tools||{version:"1.2.5"};var d;d=g.tools.rangeinput={conf:{min:0,max:100,step:"any",steps:0,value:0,precision:undefined,vertical:0,keyboard:true,progress:false,speed:100,css:{input:"range",slider:"slider",progress:"progress",handle:"handle"}}};var a,i;g.fn.drag=function(e){document.ondragstart=function(){return false};e=g.extend({x:true,y:true,drag:true},e);a=a||g(document).bind("mousedown mouseup",function(j){var l=g(j.target);if(j.type=="mousedown"&&l.data("drag")){var q=l.position(),k=j.pageX-q.left,m=j.pageY-q.top,n=true;a.bind("mousemove.drag",function(p){var r=p.pageX-k;p=p.pageY-m;var o={};if(e.x){o.left=r}if(e.y){o.top=p}if(n){l.trigger("dragStart");n=false}e.drag&&l.css(o);l.trigger("drag",[p,r]);i=l});j.preventDefault()}else{try{i&&i.trigger("dragEnd")}finally{a.unbind("mousemove.drag");i=null}}});return this.data("drag",true)};g.expr[":"].range=function(j){var e=j.getAttribute("type");return e&&e=="range"||!!g(j).filter("input").data("rangeinput")};g.fn.rangeinput=function(j){if(this.data("rangeinput")){return this}j=g.extend(true,{},d.conf,j);var e;this.each(function(){var k=new b(g(this),g.extend(true,{},j));k=k.getInput().data("rangeinput",k);e=e?e.add(k):k});return e?e:this}})(jQuery);(function(i){function n(o,e,t){var q=o.offset().top,r=o.offset().left,h=t.position.split(/,?\s+/),s=h[0];h=h[1];q-=e.outerHeight()-t.offset[0];r+=o.outerWidth()+t.offset[1];if(/iPad/i.test(navigator.userAgent)){q-=i(window).scrollTop()}t=e.outerHeight()+o.outerHeight();if(s=="center"){q+=t/2}if(s=="bottom"){q+=t}o=o.outerWidth();if(h=="center"){r-=(o+e.outerWidth())/2}if(h=="left"){r-=o}return{top:q,left:r}}function k(h){function e(){return this.getAttribute("type")==h}e.key="[type="+h+"]";return e}function m(o,e,t){function q(v,w,u){if(!(!t.grouped&&v.length)){var p;if(u===false||i.isArray(u)){p=g.messages[w.key||w]||g.messages["*"];p=p[t.lang]||g.messages["*"].en;(w=p.match(/\$\d/g))&&i.isArray(u)&&i.each(w,function(x){p=p.replace(this,u[x])})}else{p=u[t.lang]||u}v.push(p)}}var r=this,h=e.add(r);o=o.not(":button, :image, :reset, :submit");i.extend(r,{getConf:function(){return t},getForm:function(){return e},getInputs:function(){return o},reflow:function(){o.each(function(){var p=i(this),u=p.data("msg.el");if(u){p=n(p,u,t);u.css({top:p.top,left:p.left})}});return r},invalidate:function(u,v){if(!v){var p=[];i.each(u,function(x,w){x=o.filter("[name='"+x+"']");if(x.length){x.trigger("OI",[w]);p.push({input:x,messages:[w]})}});u=p;v=i.Event()}v.type="onFail";h.trigger(v,[u]);v.isDefaultPrevented()||b[t.effect][0].call(r,u,v);return r},reset:function(p){p=p||o;p.removeClass(t.errorClass).each(function(){var u=i(this).data("msg.el");if(u){u.remove();i(this).data("msg.el",null)}}).unbind(t.errorInputEvent||"");return r},destroy:function(){e.unbind(t.formEvent+".V").unbind("reset.V");o.unbind(t.inputEvent+".V").unbind("change.V");return r.reset()},checkValidity:function(v,w){v=v||o;v=v.not(":disabled");if(!v.length){return true}w=w||i.Event();w.type="onBeforeValidate";h.trigger(w,[v]);if(w.isDefaultPrevented()){return w.result}var u=[];v.not(":radio:not(:checked)").each(function(){var x=[],z=i(this).data("messages",x),y=a&&z.is(":date")?"onHide.v":t.errorInputEvent+".v";z.unbind(y);i.each(l,function(){var C=this,B=C[0];if(z.filter(B).length){C=C[1].call(r,z,z.val());if(C!==true){w.type="onBeforeFail";h.trigger(w,[z,B]);if(w.isDefaultPrevented()){return false}var A=z.attr(t.messageAttr);if(A){x=[A];return false}else{q(x,B,C)}}}});if(x.length){u.push({input:z,messages:x});z.trigger("OI",[x]);t.errorInputEvent&&z.bind(y,function(A){r.checkValidity(z,A)})}if(t.singleError&&u.length){return false}});var p=b[t.effect];if(!p){throw'Validator: cannot find effect "'+t.effect+'"'}if(u.length){r.invalidate(u,w);return false}else{p[1].call(r,v,w);w.type="onSuccess";h.trigger(w,[v]);v.unbind(t.errorInputEvent+".v")}return true}});i.each("onBeforeValidate,onBeforeFail,onFail,onSuccess".split(","),function(p,u){i.isFunction(t[u])&&i(r).bind(u,t[u]);r[u]=function(v){v&&i(r).bind(u,v);return r}});t.formEvent&&e.bind(t.formEvent+".V",function(p){if(!r.checkValidity(null,p)){return p.preventDefault()}});e.bind("reset.V",function(){r.reset()});o[0]&&o[0].validity&&o.each(function(){this.oninvalid=function(){return false}});if(e[0]){e[0].checkValidity=r.checkValidity}t.inputEvent&&o.bind(t.inputEvent+".V",function(p){r.checkValidity(i(this),p)});o.filter(":checkbox, select").filter("[required]").bind("change.V",function(p){var u=i(this);if(this.checked||u.is("select")&&i(this).val()){b[t.effect][1].call(r,u,p)}});var s=o.filter(":radio").change(function(p){r.checkValidity(s,p)});i(window).resize(function(){r.reflow()})}i.tools=i.tools||{version:"1.2.5"};var j=/\[type=([a-z]+)\]/,f=/^-?[0-9]*(\.[0-9]+)?$/,a=i.tools.dateinput,d=/^([a-z0-9_\.\-\+]+)@([\da-z\.\-]+)\.([a-z\.]{2,6})$/i,c=/^(https?:\/\/)?[\da-z\.\-]+\.[a-z\.]{2,6}[#&+_\?\/\w \.\-=]*$/i,g;g=i.tools.validator={conf:{grouped:false,effect:"default",errorClass:"invalid",inputEvent:null,errorInputEvent:"keyup",formEvent:"submit",lang:"en",message:"<div/>",messageAttr:"data-message",messageClass:"error",offset:[0,0],position:"center right",singleError:false,speed:"normal"},messages:{"*":{en:"Please correct this value"}},localize:function(h,e){i.each(e,function(p,o){g.messages[p]=g.messages[p]||{};g.messages[p][h]=o})},localizeFn:function(h,e){g.messages[h]=g.messages[h]||{};i.extend(g.messages[h],e)},fn:function(h,e,o){if(i.isFunction(e)){o=e}else{if(typeof e=="string"){e={en:e}}this.messages[h.key||h]=e}if(e=j.exec(h)){h=k(e[1])}l.push([h,o])},addEffect:function(h,e,o){b[h]=[e,o]}};var l=[],b={"default":[function(h){var e=this.getConf();i.each(h,function(q,o){q=o.input;q.addClass(e.errorClass);var p=q.data("msg.el");if(!p){p=i(e.message).addClass(e.messageClass).appendTo(document.body);q.data("msg.el",p)}p.css({visibility:"hidden"}).find("p").remove();i.each(o.messages,function(r,s){i("<p/>").html(s).appendTo(p)});p.outerWidth()==p.parent().width()&&p.add(p.find("p")).css({display:"inline"});o=n(q,p,e);p.css({visibility:"visible",position:"absolute",top:o.top,left:o.left}).fadeIn(e.speed)})},function(h){var e=this.getConf();h.removeClass(e.errorClass).each(function(){var o=i(this).data("msg.el");o&&o.css({visibility:"hidden"})})}]};i.each("email,url,number".split(","),function(h,e){i.expr[":"][e]=function(o){return o.getAttribute("type")===e}});i.fn.oninvalid=function(e){return this[e?"bind":"trigger"]("OI",e)};g.fn(":email","Please enter a valid email address",function(h,e){return !e||d.test(e)});g.fn(":url","Please enter a valid URL",function(h,e){return !e||c.test(e)});g.fn(":number","Please enter a numeric value.",function(h,e){return f.test(e)});g.fn("[max]","Please enter a value smaller than $1",function(h,e){if(e===""||a&&h.is(":date")){return true}h=h.attr("max");return parseFloat(e)<=parseFloat(h)?true:[h]});g.fn("[min]","Please enter a value larger than $1",function(h,e){if(e===""||a&&h.is(":date")){return true}h=h.attr("min");return parseFloat(e)>=parseFloat(h)?true:[h]});g.fn("[required]","Please complete this mandatory field.",function(h,e){if(h.is(":checkbox")){return h.is(":checked")}return !!e});g.fn("[pattern]",function(h){var e=new RegExp("^"+h.attr("pattern")+"$");return e.test(h.val())});i.fn.validator=function(h){var e=this.data("validator");if(e){e.destroy();this.removeData("validator")}h=i.extend(true,{},g.conf,h);if(this.is("form")){return this.each(function(){var o=i(this);e=new m(o.find(":input"),o,h);o.data("validator",e)})}else{e=new m(this,this.eq(0).closest("form"),h);return this.data("validator",e)}}})(jQuery);
(function(e){var c=e.tools.overlay,a=e(window);e.extend(c.conf,{start:{top:null,left:null},fadeInSpeed:"fast",zIndex:9999});function d(g){var h=g.offset();return{top:h.top+g.height()/2,left:h.left+g.width()/2}}var f=function(r,q){var k=this.getOverlay(),o=this.getConf(),i=this.getTrigger(),s=this,t=k.outerWidth({margin:true}),m=k.data("img"),n=o.fixed?"fixed":"absolute";if(!m){var l=k.css("backgroundImage");if(!l){throw"background-image CSS property not set for overlay"}l=l.slice(l.indexOf("(")+1,l.indexOf(")")).replace(/\"/g,"");k.css("backgroundImage","none");m=e('<img src="'+l+'"/>');m.css({border:0,display:"none"}).width(t);e("body").append(m);k.data("img",m)}var j=o.start.top||Math.round(a.height()/2),h=o.start.left||Math.round(a.width()/2);if(i){var g=d(i);j=g.top;h=g.left}if(o.fixed){j-=a.scrollTop();h-=a.scrollLeft()}else{r.top+=a.scrollTop();r.left+=a.scrollLeft()}m.css({position:"absolute",top:j,left:h,width:0,zIndex:o.zIndex}).show();r.position=n;k.css(r);m.animate({top:r.top,left:r.left,width:t},o.speed,function(){k.css("zIndex",o.zIndex+1).fadeIn(o.fadeInSpeed,function(){if(s.isOpened()&&!e(this).index(k)){q.call()}else{k.hide()}})}).css("position",n)};var b=function(g){var k=this.getOverlay().hide(),j=this.getConf(),i=this.getTrigger(),h=k.data("img"),l={top:j.start.top,left:j.start.left,width:0};if(i){e.extend(l,d(i))}if(j.fixed){h.css({position:"absolute"}).animate({top:"+="+a.scrollTop(),left:"+="+a.scrollLeft()},0)}h.animate(l,j.closeSpeed,g)};c.addEffect("apple",f,b)})(jQuery);
(function(b){b.uniform={options:{selectClass:"selector",radioClass:"radio",checkboxClass:"checker",fileClass:"uploader",filenameClass:"filename",fileBtnClass:"action",fileDefaultText:"No file selected",fileBtnText:"Choose File",checkedClass:"checked",focusClass:"focus",disabledClass:"disabled",buttonClass:"button",activeClass:"active",hoverClass:"hover",useID:true,idPrefix:"uniform",resetSelector:false,autoHide:true},elements:[]};if(b.browser.msie&&b.browser.version<7){b.support.selectOpacity=false}else{b.support.selectOpacity=true}b.fn.uniform=function(a){a=b.extend(b.uniform.options,a);var r=this;if(a.resetSelector!=false){b(a.resetSelector).mouseup(function(){function c(){b.uniform.update(r)}setTimeout(c,10)})}function l(c){$el=b(c);$el.addClass($el.attr("type"));t(c)}function o(c){b(c).addClass("uniform");t(c)}function m(f){var c=b(f);var e=b("<div>"),d=b("<span>");e.addClass(a.buttonClass);if(a.useID&&c.attr("id")!=""){e.attr("id",a.idPrefix+"-"+c.attr("id"))}var g;if(c.is("a")||c.is("button")){g=c.html()}else{if(c.is(":submit")||c.is(":reset")||c.is("input[type=button]")){g=c.attr("value")}}g=g==""?c.is(":reset")?"Reset":"Submit":g;d.html(g);c.css("opacity",0);c.wrap(e);c.wrap(d);e=c.closest("div");d=c.closest("span");if(c.is(":disabled")){e.addClass(a.disabledClass)}e.bind({"mouseenter.uniform":function(){e.addClass(a.hoverClass)},"mouseleave.uniform":function(){e.removeClass(a.hoverClass);e.removeClass(a.activeClass)},"mousedown.uniform touchbegin.uniform":function(){e.addClass(a.activeClass)},"mouseup.uniform touchend.uniform":function(){e.removeClass(a.activeClass)},"click.uniform touchend.uniform":function(h){if(b(h.target).is("span")||b(h.target).is("div")){if(f[0].dispatchEvent){var i=document.createEvent("MouseEvents");i.initEvent("click",true,true);f[0].dispatchEvent(i)}else{f[0].click()}}}});f.bind({"focus.uniform":function(){e.addClass(a.focusClass)},"blur.uniform":function(){e.removeClass(a.focusClass)}});b.uniform.noSelect(e);t(f)}function q(f){var c=b(f);var e=b("<div />"),d=b("<span />");if(!c.css("display")=="none"&&a.autoHide){e.hide()}e.addClass(a.selectClass);if(a.useID&&f.attr("id")!=""){e.attr("id",a.idPrefix+"-"+f.attr("id"))}var g=f.find(":selected:first");if(g.length==0){g=f.find("option:first")}d.html(g.html());f.css("opacity",0);f.wrap(e);f.before(d);e=f.parent("div");d=f.siblings("span");f.bind({"change.uniform":function(){d.html(f.find(":selected").html());e.removeClass(a.activeClass)},"focus.uniform":function(){e.addClass(a.focusClass)},"blur.uniform":function(){e.removeClass(a.focusClass);e.removeClass(a.activeClass)},"mousedown.uniform touchbegin.uniform":function(){e.addClass(a.activeClass)},"mouseup.uniform touchend.uniform":function(){e.removeClass(a.activeClass)},"click.uniform touchend.uniform":function(){e.removeClass(a.activeClass)},"mouseenter.uniform":function(){e.addClass(a.hoverClass)},"mouseleave.uniform":function(){e.removeClass(a.hoverClass);e.removeClass(a.activeClass)},"keyup.uniform":function(){d.html(f.find(":selected").html())}});if(b(f).attr("disabled")){e.addClass(a.disabledClass)}b.uniform.noSelect(d);t(f)}function p(f){var c=b(f);var e=b("<div />"),d=b("<span />");if(!c.css("display")=="none"&&a.autoHide){e.hide()}e.addClass(a.checkboxClass);if(a.useID&&f.attr("id")!=""){e.attr("id",a.idPrefix+"-"+f.attr("id"))}b(f).wrap(e);b(f).wrap(d);d=f.parent();e=d.parent();b(f).css("opacity",0).bind({"focus.uniform":function(){e.addClass(a.focusClass)},"blur.uniform":function(){e.removeClass(a.focusClass)},"click.uniform touchend.uniform":function(){if(!b(f).attr("checked")){d.removeClass(a.checkedClass)}else{d.addClass(a.checkedClass)}},"mousedown.uniform touchbegin.uniform":function(){e.addClass(a.activeClass)},"mouseup.uniform touchend.uniform":function(){e.removeClass(a.activeClass)},"mouseenter.uniform":function(){e.addClass(a.hoverClass)},"mouseleave.uniform":function(){e.removeClass(a.hoverClass);e.removeClass(a.activeClass)}});if(b(f).attr("checked")){d.addClass(a.checkedClass)}if(b(f).attr("disabled")){e.addClass(a.disabledClass)}t(f)}function s(f){var c=b(f);var e=b("<div />"),d=b("<span />");if(!c.css("display")=="none"&&a.autoHide){e.hide()}e.addClass(a.radioClass);if(a.useID&&f.attr("id")!=""){e.attr("id",a.idPrefix+"-"+f.attr("id"))}b(f).wrap(e);b(f).wrap(d);d=f.parent();e=d.parent();b(f).css("opacity",0).bind({"focus.uniform":function(){e.addClass(a.focusClass)},"blur.uniform":function(){e.removeClass(a.focusClass)},"click.uniform touchend.uniform":function(){if(!b(f).attr("checked")){d.removeClass(a.checkedClass)}else{var g=a.radioClass.split(" ")[0];b("."+g+" span."+a.checkedClass+":has([name='"+b(f).attr("name")+"'])").removeClass(a.checkedClass);d.addClass(a.checkedClass)}},"mousedown.uniform touchend.uniform":function(){if(!b(f).is(":disabled")){e.addClass(a.activeClass)}},"mouseup.uniform touchbegin.uniform":function(){e.removeClass(a.activeClass)},"mouseenter.uniform touchend.uniform":function(){e.addClass(a.hoverClass)},"mouseleave.uniform":function(){e.removeClass(a.hoverClass);e.removeClass(a.activeClass)}});if(b(f).attr("checked")){d.addClass(a.checkedClass)}if(b(f).attr("disabled")){e.addClass(a.disabledClass)}t(f)}function n(f){var h=b(f);var e=b("<div />"),g=b("<span>"+a.fileDefaultText+"</span>"),c=b("<span>"+a.fileBtnText+"</span>");if(!h.css("display")=="none"&&a.autoHide){e.hide()}e.addClass(a.fileClass);g.addClass(a.filenameClass);c.addClass(a.fileBtnClass);if(a.useID&&h.attr("id")!=""){e.attr("id",a.idPrefix+"-"+h.attr("id"))}h.wrap(e);h.after(c);h.after(g);e=h.closest("div");g=h.siblings("."+a.filenameClass);c=h.siblings("."+a.fileBtnClass);if(!h.attr("size")){var d=e.width();h.attr("size",d/10)}var i=function(){var j=h.val();if(j===""){j=a.fileDefaultText}else{j=j.split(/[\/\\]+/);j=j[(j.length-1)]}g.html(j)};i();h.css("opacity",0).bind({"focus.uniform":function(){e.addClass(a.focusClass)},"blur.uniform":function(){e.removeClass(a.focusClass)},"mousedown.uniform":function(){if(!b(f).is(":disabled")){e.addClass(a.activeClass)}},"mouseup.uniform":function(){e.removeClass(a.activeClass)},"mouseenter.uniform":function(){e.addClass(a.hoverClass)},"mouseleave.uniform":function(){e.removeClass(a.hoverClass);e.removeClass(a.activeClass)}});if(b.browser.msie){h.bind("click.uniform.ie7",function(){setTimeout(i,0)})}else{h.bind("change.uniform",i)}if(h.attr("disabled")){e.addClass(a.disabledClass)}b.uniform.noSelect(g);b.uniform.noSelect(c);t(f)}b.uniform.restore=function(c){if(c==undefined){c=b(b.uniform.elements)}b(c).each(function(){if(b(this).is(":checkbox")){b(this).unwrap().unwrap()}else{if(b(this).is("select")){b(this).siblings("span").remove();b(this).unwrap()}else{if(b(this).is(":radio")){b(this).unwrap().unwrap()}else{if(b(this).is(":file")){b(this).siblings("span").remove();b(this).unwrap()}else{if(b(this).is("button, :submit, :reset, a, input[type='button']")){b(this).unwrap().unwrap()}}}}}b(this).unbind(".uniform");b(this).css("opacity","1");var d=b.inArray(b(c),b.uniform.elements);b.uniform.elements.splice(d,1)})};function t(c){c=b(c).get();if(c.length>1){b.each(c,function(d,e){b.uniform.elements.push(e)})}else{b.uniform.elements.push(c)}}b.uniform.noSelect=function(d){function c(){return false}b(d).each(function(){this.onselectstart=this.ondragstart=c;b(this).mousedown(c).css({MozUserSelect:"none"})})};b.uniform.update=function(c){if(c==undefined){c=b(b.uniform.elements)}c=b(c);c.each(function(){var g=b(this);if(g.is("select")){var d=g.siblings("span");var e=g.parent("div");e.removeClass(a.hoverClass+" "+a.focusClass+" "+a.activeClass);d.html(g.find(":selected").html());if(g.is(":disabled")){e.addClass(a.disabledClass)}else{e.removeClass(a.disabledClass)}}else{if(g.is(":checkbox")){var d=g.closest("span");var e=g.closest("div");e.removeClass(a.hoverClass+" "+a.focusClass+" "+a.activeClass);d.removeClass(a.checkedClass);if(g.is(":checked")){d.addClass(a.checkedClass)}if(g.is(":disabled")){e.addClass(a.disabledClass)}else{e.removeClass(a.disabledClass)}}else{if(g.is(":radio")){var d=g.closest("span");var e=g.closest("div");e.removeClass(a.hoverClass+" "+a.focusClass+" "+a.activeClass);d.removeClass(a.checkedClass);if(g.is(":checked")){d.addClass(a.checkedClass)}if(g.is(":disabled")){e.addClass(a.disabledClass)}else{e.removeClass(a.disabledClass)}}else{if(g.is(":file")){var e=g.parent("div");var f=g.siblings(a.filenameClass);btnTag=g.siblings(a.fileBtnClass);e.removeClass(a.hoverClass+" "+a.focusClass+" "+a.activeClass);f.html(g.val());if(g.is(":disabled")){e.addClass(a.disabledClass)}else{e.removeClass(a.disabledClass)}}else{if(g.is(":submit")||g.is(":reset")||g.is("button")||g.is("a")||c.is("input[type=button]")){var e=g.closest("div");e.removeClass(a.hoverClass+" "+a.focusClass+" "+a.activeClass);if(g.is(":disabled")){e.addClass(a.disabledClass)}else{e.removeClass(a.disabledClass)}}}}}}})};return this.each(function(){if(b.support.selectOpacity){var c=b(this);if(c.is("select")){if(c.attr("multiple")!=true){if(c.attr("size")==undefined||c.attr("size")<=1){q(c)}}}else{if(c.is(":checkbox")){p(c)}else{if(c.is(":radio")){s(c)}else{if(c.is(":file")){n(c)}else{if(c.is(":text, :password, input[type='email']")){l(c)}else{if(c.is("textarea")){o(c)}else{if(c.is("a")||c.is(":submit")||c.is(":reset")||c.is("button")||c.is("input[type=button]")){m(c)}}}}}}}}})}})(jQuery);
/*!
 * jQuery Cycle Plugin (with Transition Definitions)
 * Examples and documentation at: http://jquery.malsup.com/cycle/
 * Copyright (c) 2007-2010 M. Alsup
 * Version: 2.9995 (09-AUG-2011)
 * Dual licensed under the MIT and GPL licenses.
 * http://jquery.malsup.com/license.html
 * Requires: jQuery v1.3.2 or later
 */
(function(i){var l="2.9995";if(i.support==undefined){i.support={opacity:!(i.browser.msie)}}function a(t){i.fn.cycle.debug&&f(t)}function f(){window.console&&console.log&&console.log("[cycle] "+Array.prototype.join.call(arguments," "))}i.expr[":"].paused=function(s){return s.cyclePause};i.fn.cycle=function(t,s){var u={s:this.selector,c:this.context};if(this.length===0&&t!="stop"){if(!i.isReady&&u.s){f("DOM not ready, queuing slideshow");i(function(){i(u.s,u.c).cycle(t,s)});return this}f("terminating; zero elements found by selector"+(i.isReady?"":" (DOM not ready)"));return this}return this.each(function(){var y=n(this,t,s);if(y===false){return}y.updateActivePagerLink=y.updateActivePagerLink||i.fn.cycle.updateActivePagerLink;if(this.cycleTimeout){clearTimeout(this.cycleTimeout)}this.cycleTimeout=this.cyclePause=0;var z=i(this);var A=y.slideExpr?i(y.slideExpr,this):z.children();var w=A.get();var v=k(z,A,w,y,u);if(v===false){return}if(w.length<2){f("terminating; too few slides: "+w.length);return}var x=v.continuous?10:h(w[v.currSlide],w[v.nextSlide],v,!v.backwards);if(x){x+=(v.delay||0);if(x<10){x=10}a("first timeout: "+x);this.cycleTimeout=setTimeout(function(){e(w,v,0,!y.backwards)},x)}})};function m(s,v,u){var w=i(s).data("cycle.opts");var t=!!s.cyclePause;if(t&&w.paused){w.paused(s,w,v,u)}else{if(!t&&w.resumed){w.resumed(s,w,v,u)}}}function n(s,v,t){if(s.cycleStop==undefined){s.cycleStop=0}if(v===undefined||v===null){v={}}if(v.constructor==String){switch(v){case"destroy":case"stop":var x=i(s).data("cycle.opts");if(!x){return false}s.cycleStop++;if(s.cycleTimeout){clearTimeout(s.cycleTimeout)}s.cycleTimeout=0;x.elements&&i(x.elements).stop();i(s).removeData("cycle.opts");if(v=="destroy"){r(x)}return false;case"toggle":s.cyclePause=(s.cyclePause===1)?0:1;w(s.cyclePause,t,s);m(s);return false;case"pause":s.cyclePause=1;m(s);return false;case"resume":s.cyclePause=0;w(false,t,s);m(s);return false;case"prev":case"next":var x=i(s).data("cycle.opts");if(!x){f('options not found, "prev/next" ignored');return false}i.fn.cycle[v](x);return false;default:v={fx:v}}return v}else{if(v.constructor==Number){var u=v;v=i(s).data("cycle.opts");if(!v){f("options not found, can not advance slide");return false}if(u<0||u>=v.elements.length){f("invalid slide index: "+u);return false}v.nextSlide=u;if(s.cycleTimeout){clearTimeout(s.cycleTimeout);s.cycleTimeout=0}if(typeof t=="string"){v.oneTimeFx=t}e(v.elements,v,1,u>=v.currSlide);return false}}return v;function w(z,A,y){if(!z&&A===true){var B=i(y).data("cycle.opts");if(!B){f("options not found, can not resume");return false}if(y.cycleTimeout){clearTimeout(y.cycleTimeout);y.cycleTimeout=0}e(B.elements,B,1,!B.backwards)}}}function b(s,t){if(!i.support.opacity&&t.cleartype&&s.style.filter){try{s.style.removeAttribute("filter")}catch(u){}}}function r(s){if(s.next){i(s.next).unbind(s.prevNextEvent)}if(s.prev){i(s.prev).unbind(s.prevNextEvent)}if(s.pager||s.pagerAnchorBuilder){i.each(s.pagerAnchors||[],function(){this.unbind().remove()})}s.pagerAnchors=null;if(s.destroy){s.destroy(s)}}function k(B,O,y,x,I){var G=i.extend({},i.fn.cycle.defaults,x||{},i.metadata?B.metadata():i.meta?B.data():{});var E=i.isFunction(B.data)?B.data(G.metaAttr):null;if(E){G=i.extend(G,E)}if(G.autostop){G.countdown=G.autostopCount||y.length}var t=B[0];B.data("cycle.opts",G);G.$cont=B;G.stopCount=t.cycleStop;G.elements=y;G.before=G.before?[G.before]:[];G.after=G.after?[G.after]:[];if(!i.support.opacity&&G.cleartype){G.after.push(function(){b(this,G)})}if(G.continuous){G.after.push(function(){e(y,G,0,!G.backwards)})}o(G);if(!i.support.opacity&&G.cleartype&&!G.cleartypeNoBg){g(O)}if(B.css("position")=="static"){B.css("position","relative")}if(G.width){B.width(G.width)}if(G.height&&G.height!="auto"){B.height(G.height)}if(G.startingSlide){G.startingSlide=parseInt(G.startingSlide,10)}else{if(G.backwards){G.startingSlide=y.length-1}}if(G.random){G.randomMap=[];for(var M=0;M<y.length;M++){G.randomMap.push(M)}G.randomMap.sort(function(Q,w){return Math.random()-0.5});G.randomIndex=1;G.startingSlide=G.randomMap[1]}else{if(G.startingSlide>=y.length){G.startingSlide=0}}G.currSlide=G.startingSlide||0;var A=G.startingSlide;O.css({position:"absolute",top:0,left:0}).hide().each(function(w){var Q;if(G.backwards){Q=A?w<=A?y.length+(w-A):A-w:y.length-w}else{Q=A?w>=A?y.length-(w-A):A-w:y.length-w}i(this).css("z-index",Q)});i(y[A]).css("opacity",1).show();b(y[A],G);if(G.fit){if(!G.aspect){if(G.width){O.width(G.width)}if(G.height&&G.height!="auto"){O.height(G.height)}}else{O.each(function(){var Q=i(this);var w=(G.aspect===true)?Q.width()/Q.height():G.aspect;if(G.width&&Q.width()!=G.width){Q.width(G.width);Q.height(G.width/w)}if(G.height&&Q.height()<G.height){Q.height(G.height);Q.width(G.height*w)}})}}if(G.center&&((!G.fit)||G.aspect)){O.each(function(){var w=i(this);w.css({"margin-left":G.width?((G.width-w.width())/2)+"px":0,"margin-top":G.height?((G.height-w.height())/2)+"px":0})})}if(G.center&&!G.fit&&!G.slideResize){O.each(function(){var w=i(this);w.css({"margin-left":G.width?((G.width-w.width())/2)+"px":0,"margin-top":G.height?((G.height-w.height())/2)+"px":0})})}var H=G.containerResize&&!B.innerHeight();if(H){var z=0,F=0;for(var K=0;K<y.length;K++){var s=i(y[K]),P=s[0],D=s.outerWidth(),N=s.outerHeight();if(!D){D=P.offsetWidth||P.width||s.attr("width")}if(!N){N=P.offsetHeight||P.height||s.attr("height")}z=D>z?D:z;F=N>F?N:F}if(z>0&&F>0){B.css({width:z+"px",height:F+"px"})}}var v=false;if(G.pause){B.hover(function(){v=true;this.cyclePause++;m(t,true)},function(){v&&this.cyclePause--;m(t,true)})}if(c(G)===false){return false}var u=false;x.requeueAttempts=x.requeueAttempts||0;O.each(function(){var S=i(this);this.cycleH=(G.fit&&G.height)?G.height:(S.height()||this.offsetHeight||this.height||S.attr("height")||0);this.cycleW=(G.fit&&G.width)?G.width:(S.width()||this.offsetWidth||this.width||S.attr("width")||0);if(S.is("img")){var Q=(i.browser.msie&&this.cycleW==28&&this.cycleH==30&&!this.complete);var T=(i.browser.mozilla&&this.cycleW==34&&this.cycleH==19&&!this.complete);var R=(i.browser.opera&&((this.cycleW==42&&this.cycleH==19)||(this.cycleW==37&&this.cycleH==17))&&!this.complete);var w=(this.cycleH==0&&this.cycleW==0&&!this.complete);if(Q||T||R||w){if(I.s&&G.requeueOnImageNotLoaded&&++x.requeueAttempts<100){f(x.requeueAttempts," - img slide not loaded, requeuing slideshow: ",this.src,this.cycleW,this.cycleH);setTimeout(function(){i(I.s,I.c).cycle(x)},G.requeueTimeout);u=true;return false}else{f("could not determine size of image: "+this.src,this.cycleW,this.cycleH)}}}return true});if(u){return false}G.cssBefore=G.cssBefore||{};G.cssAfter=G.cssAfter||{};G.cssFirst=G.cssFirst||{};G.animIn=G.animIn||{};G.animOut=G.animOut||{};O.not(":eq("+A+")").css(G.cssBefore);i(O[A]).css(G.cssFirst);if(G.timeout){G.timeout=parseInt(G.timeout,10);if(G.speed.constructor==String){G.speed=i.fx.speeds[G.speed]||parseInt(G.speed,10)}if(!G.sync){G.speed=G.speed/2}var J=G.fx=="none"?0:G.fx=="shuffle"?500:250;while((G.timeout-G.speed)<J){G.timeout+=G.speed}}if(G.easing){G.easeIn=G.easeOut=G.easing}if(!G.speedIn){G.speedIn=G.speed}if(!G.speedOut){G.speedOut=G.speed}G.slideCount=y.length;G.currSlide=G.lastSlide=A;if(G.random){if(++G.randomIndex==y.length){G.randomIndex=0}G.nextSlide=G.randomMap[G.randomIndex]}else{if(G.backwards){G.nextSlide=G.startingSlide==0?(y.length-1):G.startingSlide-1}else{G.nextSlide=G.startingSlide>=(y.length-1)?0:G.startingSlide+1}}if(!G.multiFx){var L=i.fn.cycle.transitions[G.fx];if(i.isFunction(L)){L(B,O,G)}else{if(G.fx!="custom"&&!G.multiFx){f("unknown transition: "+G.fx,"; slideshow terminating");return false}}}var C=O[A];if(!G.skipInitializationCallbacks){if(G.before.length){G.before[0].apply(C,[C,C,G,true])}if(G.after.length){G.after[0].apply(C,[C,C,G,true])}}if(G.next){i(G.next).bind(G.prevNextEvent,function(){return q(G,1)})}if(G.prev){i(G.prev).bind(G.prevNextEvent,function(){return q(G,0)})}if(G.pager||G.pagerAnchorBuilder){d(y,G)}j(G,y);return G}function o(s){s.original={before:[],after:[]};s.original.cssBefore=i.extend({},s.cssBefore);s.original.cssAfter=i.extend({},s.cssAfter);s.original.animIn=i.extend({},s.animIn);s.original.animOut=i.extend({},s.animOut);i.each(s.before,function(){s.original.before.push(this)});i.each(s.after,function(){s.original.after.push(this)})}function c(y){var w,u,t=i.fn.cycle.transitions;if(y.fx.indexOf(",")>0){y.multiFx=true;y.fxs=y.fx.replace(/\s*/g,"").split(",");for(w=0;w<y.fxs.length;w++){var x=y.fxs[w];u=t[x];if(!u||!t.hasOwnProperty(x)||!i.isFunction(u)){f("discarding unknown transition: ",x);y.fxs.splice(w,1);w--}}if(!y.fxs.length){f("No valid transitions named; slideshow terminating.");return false}}else{if(y.fx=="all"){y.multiFx=true;y.fxs=[];for(p in t){u=t[p];if(t.hasOwnProperty(p)&&i.isFunction(u)){y.fxs.push(p)}}}}if(y.multiFx&&y.randomizeEffects){var v=Math.floor(Math.random()*20)+30;for(w=0;w<v;w++){var s=Math.floor(Math.random()*y.fxs.length);y.fxs.push(y.fxs.splice(s,1)[0])}a("randomized fx sequence: ",y.fxs)}return true}function j(t,s){t.addSlide=function(v,w){var u=i(v),x=u[0];if(!t.autostopCount){t.countdown++}s[w?"unshift":"push"](x);if(t.els){t.els[w?"unshift":"push"](x)}t.slideCount=s.length;u.css("position","absolute");u[w?"prependTo":"appendTo"](t.$cont);if(w){t.currSlide++;t.nextSlide++}if(!i.support.opacity&&t.cleartype&&!t.cleartypeNoBg){g(u)}if(t.fit&&t.width){u.width(t.width)}if(t.fit&&t.height&&t.height!="auto"){u.height(t.height)}x.cycleH=(t.fit&&t.height)?t.height:u.height();x.cycleW=(t.fit&&t.width)?t.width:u.width();u.css(t.cssBefore);if(t.pager||t.pagerAnchorBuilder){i.fn.cycle.createPagerAnchor(s.length-1,x,i(t.pager),s,t)}if(i.isFunction(t.onAddSlide)){t.onAddSlide(u)}else{u.hide()}}}i.fn.cycle.resetState=function(t,s){s=s||t.fx;t.before=[];t.after=[];t.cssBefore=i.extend({},t.original.cssBefore);t.cssAfter=i.extend({},t.original.cssAfter);t.animIn=i.extend({},t.original.animIn);t.animOut=i.extend({},t.original.animOut);t.fxFn=null;i.each(t.original.before,function(){t.before.push(this)});i.each(t.original.after,function(){t.after.push(this)});var u=i.fn.cycle.transitions[s];if(i.isFunction(u)){u(t.$cont,i(t.elements),t)}};function e(z,s,y,B){if(y&&s.busy&&s.manualTrump){a("manualTrump in go(), stopping active transition");i(z).stop(true,true);s.busy=0}if(s.busy){a("transition active, ignoring new tx request");return}var w=s.$cont[0],D=z[s.currSlide],C=z[s.nextSlide];if(w.cycleStop!=s.stopCount||w.cycleTimeout===0&&!y){return}if(!y&&!w.cyclePause&&!s.bounce&&((s.autostop&&(--s.countdown<=0))||(s.nowrap&&!s.random&&s.nextSlide<s.currSlide))){if(s.end){s.end(s)}return}var A=false;if((y||!w.cyclePause)&&(s.nextSlide!=s.currSlide)){A=true;var x=s.fx;D.cycleH=D.cycleH||i(D).height();D.cycleW=D.cycleW||i(D).width();C.cycleH=C.cycleH||i(C).height();C.cycleW=C.cycleW||i(C).width();if(s.multiFx){if(B&&(s.lastFx==undefined||++s.lastFx>=s.fxs.length)){s.lastFx=0}else{if(!B&&(s.lastFx==undefined||--s.lastFx<0)){s.lastFx=s.fxs.length-1}}x=s.fxs[s.lastFx]}if(s.oneTimeFx){x=s.oneTimeFx;s.oneTimeFx=null}i.fn.cycle.resetState(s,x);if(s.before.length){i.each(s.before,function(E,F){if(w.cycleStop!=s.stopCount){return}F.apply(C,[D,C,s,B])})}var u=function(){s.busy=0;i.each(s.after,function(E,F){if(w.cycleStop!=s.stopCount){return}F.apply(C,[D,C,s,B])})};a("tx firing("+x+"); currSlide: "+s.currSlide+"; nextSlide: "+s.nextSlide);s.busy=1;if(s.fxFn){s.fxFn(D,C,s,u,B,y&&s.fastOnEvent)}else{if(i.isFunction(i.fn.cycle[s.fx])){i.fn.cycle[s.fx](D,C,s,u,B,y&&s.fastOnEvent)}else{i.fn.cycle.custom(D,C,s,u,B,y&&s.fastOnEvent)}}}if(A||s.nextSlide==s.currSlide){s.lastSlide=s.currSlide;if(s.random){s.currSlide=s.nextSlide;if(++s.randomIndex==z.length){s.randomIndex=0}s.nextSlide=s.randomMap[s.randomIndex];if(s.nextSlide==s.currSlide){s.nextSlide=(s.currSlide==s.slideCount-1)?0:s.currSlide+1}}else{if(s.backwards){var v=(s.nextSlide-1)<0;if(v&&s.bounce){s.backwards=!s.backwards;s.nextSlide=1;s.currSlide=0}else{s.nextSlide=v?(z.length-1):s.nextSlide-1;s.currSlide=v?0:s.nextSlide+1}}else{var v=(s.nextSlide+1)==z.length;if(v&&s.bounce){s.backwards=!s.backwards;s.nextSlide=z.length-2;s.currSlide=z.length-1}else{s.nextSlide=v?0:s.nextSlide+1;s.currSlide=v?z.length-1:s.nextSlide-1}}}}if(A&&s.pager){s.updateActivePagerLink(s.pager,s.currSlide,s.activePagerClass)}var t=0;if(s.timeout&&!s.continuous){t=h(z[s.currSlide],z[s.nextSlide],s,B)}else{if(s.continuous&&w.cyclePause){t=10}}if(t>0){w.cycleTimeout=setTimeout(function(){e(z,s,0,!s.backwards)},t)}}i.fn.cycle.updateActivePagerLink=function(s,u,t){i(s).each(function(){i(this).children().removeClass(t).eq(u).addClass(t)})};function h(x,v,w,u){if(w.timeoutFn){var s=w.timeoutFn.call(x,x,v,w,u);while(w.fx!="none"&&(s-w.speed)<250){s+=w.speed}a("calculated timeout: "+s+"; speed: "+w.speed);if(s!==false){return s}}return w.timeout}i.fn.cycle.next=function(s){q(s,1)};i.fn.cycle.prev=function(s){q(s,0)};function q(v,u){var y=u?1:-1;var t=v.elements;var x=v.$cont[0],w=x.cycleTimeout;if(w){clearTimeout(w);x.cycleTimeout=0}if(v.random&&y<0){v.randomIndex--;if(--v.randomIndex==-2){v.randomIndex=t.length-2}else{if(v.randomIndex==-1){v.randomIndex=t.length-1}}v.nextSlide=v.randomMap[v.randomIndex]}else{if(v.random){v.nextSlide=v.randomMap[v.randomIndex]}else{v.nextSlide=v.currSlide+y;if(v.nextSlide<0){if(v.nowrap){return false}v.nextSlide=t.length-1}else{if(v.nextSlide>=t.length){if(v.nowrap){return false}v.nextSlide=0}}}}var s=v.onPrevNextEvent||v.prevNextClick;if(i.isFunction(s)){s(y>0,v.nextSlide,t[v.nextSlide])}e(t,v,1,u);return false}function d(t,u){var s=i(u.pager);i.each(t,function(v,w){i.fn.cycle.createPagerAnchor(v,w,s,t,u)});u.updateActivePagerLink(u.pager,u.startingSlide,u.activePagerClass)}i.fn.cycle.createPagerAnchor=function(x,u,z,w,t){var A;if(i.isFunction(t.pagerAnchorBuilder)){A=t.pagerAnchorBuilder(x,u);a("pagerAnchorBuilder("+x+", el) returned: "+A)}else{A='<a href="#">'+(x+1)+"</a>"}if(!A){return}var v=i(A);if(v.parents("body").length===0){var y=[];if(z.length>1){z.each(function(){var D=v.clone(true);i(this).append(D);y.push(D[0])});v=i(y)}else{v.appendTo(z)}}t.pagerAnchors=t.pagerAnchors||[];t.pagerAnchors.push(v);var B=function(G){G.preventDefault();t.nextSlide=x;var F=t.$cont[0],E=F.cycleTimeout;if(E){clearTimeout(E);F.cycleTimeout=0}var D=t.onPagerEvent||t.pagerClick;if(i.isFunction(D)){D(t.nextSlide,w[t.nextSlide])}e(w,t,1,t.currSlide<x)};if(/mouseenter|mouseover/i.test(t.pagerEvent)){v.hover(B,function(){})}else{v.bind(t.pagerEvent,B)}if(!/^click/.test(t.pagerEvent)&&!t.allowPagerClickBubble){v.bind("click.cycle",function(){return false})}var C=t.$cont[0];var s=false;if(t.pauseOnPagerHover){v.hover(function(){s=true;C.cyclePause++;m(C,true,true)},function(){s&&C.cyclePause--;m(C,true,true)})}};i.fn.cycle.hopsFromLast=function(v,u){var t,s=v.lastSlide,w=v.currSlide;if(u){t=w>s?w-s:v.slideCount-s}else{t=w<s?s-w:s+v.slideCount-w}return t};function g(u){a("applying clearType background-color hack");function t(v){v=parseInt(v,10).toString(16);return v.length<2?"0"+v:v}function s(y){for(;y&&y.nodeName.toLowerCase()!="html";y=y.parentNode){var w=i.css(y,"background-color");if(w&&w.indexOf("rgb")>=0){var x=w.match(/\d+/g);return"#"+t(x[0])+t(x[1])+t(x[2])}if(w&&w!="transparent"){return w}}return"#ffffff"}u.each(function(){i(this).css("background-color",s(this))})}i.fn.cycle.commonReset=function(y,v,x,t,u,s){i(x.elements).not(y).hide();if(typeof x.cssBefore.opacity=="undefined"){x.cssBefore.opacity=1}x.cssBefore.display="block";if(x.slideResize&&t!==false&&v.cycleW>0){x.cssBefore.width=v.cycleW}if(x.slideResize&&u!==false&&v.cycleH>0){x.cssBefore.height=v.cycleH}x.cssAfter=x.cssAfter||{};x.cssAfter.display="none";i(y).css("zIndex",x.slideCount+(s===true?1:0));i(v).css("zIndex",x.slideCount+(s===true?0:1))};i.fn.cycle.custom=function(E,y,s,v,x,t){var D=i(E),z=i(y);var u=s.speedIn,C=s.speedOut,w=s.easeIn,B=s.easeOut;z.css(s.cssBefore);if(t){if(typeof t=="number"){u=C=t}else{u=C=1}w=B=null}var A=function(){z.animate(s.animIn,u,w,function(){v()})};D.animate(s.animOut,C,B,function(){D.css(s.cssAfter);if(!s.sync){A()}});if(s.sync){A()}};i.fn.cycle.transitions={fade:function(t,u,s){u.not(":eq("+s.currSlide+")").css("opacity",0);s.before.push(function(x,v,w){i.fn.cycle.commonReset(x,v,w);w.cssBefore.opacity=0});s.animIn={opacity:1};s.animOut={opacity:0};s.cssBefore={top:0,left:0}}};i.fn.cycle.ver=function(){return l};i.fn.cycle.defaults={activePagerClass:"activeSlide",after:null,allowPagerClickBubble:false,animIn:null,animOut:null,aspect:false,autostop:0,autostopCount:0,backwards:false,before:null,center:null,cleartype:!i.support.opacity,cleartypeNoBg:false,containerResize:1,continuous:0,cssAfter:null,cssBefore:null,delay:0,easeIn:null,easeOut:null,easing:null,end:null,fastOnEvent:0,fit:0,fx:"fade",fxFn:null,height:"auto",manualTrump:true,metaAttr:"cycle",next:null,nowrap:0,onPagerEvent:null,onPrevNextEvent:null,pager:null,pagerAnchorBuilder:null,pagerEvent:"click.cycle",pause:0,pauseOnPagerHover:0,prev:null,prevNextEvent:"click.cycle",random:0,randomizeEffects:1,requeueOnImageNotLoaded:true,requeueTimeout:250,rev:0,shuffle:null,skipInitializationCallbacks:false,slideExpr:null,slideResize:1,speed:1000,speedIn:null,speedOut:null,startingSlide:0,sync:1,timeout:4000,timeoutFn:null,updateActivePagerLink:null,width:null}})(jQuery);
/*!
 * jQuery Cycle Plugin Transition Definitions
 * This script is a plugin for the jQuery Cycle Plugin
 * Examples and documentation at: http://malsup.com/jquery/cycle/
 * Copyright (c) 2007-2010 M. Alsup
 * Version:	 2.73
 * Dual licensed under the MIT and GPL licenses:
 * http://www.opensource.org/licenses/mit-license.php
 * http://www.gnu.org/licenses/gpl.html
 */
(function(a){a.fn.cycle.transitions.none=function(c,d,b){b.fxFn=function(g,e,f,h){a(e).show();a(g).hide();h()}};a.fn.cycle.transitions.fadeout=function(c,d,b){d.not(":eq("+b.currSlide+")").css({display:"block",opacity:1});b.before.push(function(k,i,j,f,g,e){a(k).css("zIndex",j.slideCount+(!e===true?1:0));a(i).css("zIndex",j.slideCount+(!e===true?0:1))});b.animIn.opacity=1;b.animOut.opacity=0;b.cssBefore.opacity=1;b.cssBefore.display="block";b.cssAfter.zIndex=0};a.fn.cycle.transitions.scrollUp=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssBefore.top=b;c.cssBefore.left=0;c.cssFirst.top=0;c.animIn.top=0;c.animOut.top=-b};a.fn.cycle.transitions.scrollDown=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.height();c.cssFirst.top=0;c.cssBefore.top=-b;c.cssBefore.left=0;c.animIn.top=0;c.animOut.top=b};a.fn.cycle.transitions.scrollLeft=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=0-b};a.fn.cycle.transitions.scrollRight=function(d,e,c){d.css("overflow","hidden");c.before.push(a.fn.cycle.commonReset);var b=d.width();c.cssFirst.left=0;c.cssBefore.left=-b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=b};a.fn.cycle.transitions.scrollHorz=function(c,d,b){c.css("overflow","hidden").width();b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.left=e?(f.cycleW-1):(1-f.cycleW);g.animOut.left=e?-h.cycleW:h.cycleW});b.cssFirst.left=0;b.cssBefore.top=0;b.animIn.left=0;b.animOut.top=0};a.fn.cycle.transitions.scrollVert=function(c,d,b){c.css("overflow","hidden");b.before.push(function(h,f,g,e){if(g.rev){e=!e}a.fn.cycle.commonReset(h,f,g);g.cssBefore.top=e?(1-f.cycleH):(f.cycleH-1);g.animOut.top=e?h.cycleH:-h.cycleH});b.cssFirst.top=0;b.cssBefore.left=0;b.animIn.top=0;b.animOut.left=0};a.fn.cycle.transitions.slideX=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,false,true);f.animIn.width=e.cycleW});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.width=0;b.animIn.width="show";b.animOut.width=0};a.fn.cycle.transitions.slideY=function(c,d,b){b.before.push(function(g,e,f){a(f.elements).not(g).hide();a.fn.cycle.commonReset(g,e,f,true,false);f.animIn.height=e.cycleH});b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.height=0;b.animIn.height="show";b.animOut.height=0};a.fn.cycle.transitions.shuffle=function(e,f,d){var c,b=e.css("overflow","visible").width();f.css({left:0,top:0});d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h,true,true,true)});if(!d.speedAdjusted){d.speed=d.speed/2;d.speedAdjusted=true}d.random=0;d.shuffle=d.shuffle||{left:-b,top:15};d.els=[];for(c=0;c<f.length;c++){d.els.push(f[c])}for(c=0;c<d.currSlide;c++){d.els.push(d.els.shift())}d.fxFn=function(m,j,l,g,i){if(l.rev){i=!i}var h=i?a(m):a(j);a(j).css(l.cssBefore);var k=l.slideCount;h.animate(l.shuffle,l.speedIn,l.easeIn,function(){var o=a.fn.cycle.hopsFromLast(l,i);for(var q=0;q<o;q++){i?l.els.push(l.els.shift()):l.els.unshift(l.els.pop())}if(i){for(var r=0,n=l.els.length;r<n;r++){a(l.els[r]).css("z-index",n-r+k)}}else{var s=a(m).css("z-index");h.css("z-index",parseInt(s,10)+1+k)}h.animate({left:0,top:0},l.speedOut,l.easeOut,function(){a(i?this:m).hide();if(g){g()}})})};a.extend(d.cssBefore,{display:"block",opacity:1,top:0,left:0})};a.fn.cycle.transitions.turnUp=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.cssBefore.top=e.cycleH;f.animIn.height=e.cycleH;f.animOut.width=e.cycleW});b.cssFirst.top=0;b.cssBefore.left=0;b.cssBefore.height=0;b.animIn.top=0;b.animOut.height=0};a.fn.cycle.transitions.turnDown=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.animIn.height=e.cycleH;f.animOut.top=g.cycleH});b.cssFirst.top=0;b.cssBefore.left=0;b.cssBefore.top=0;b.cssBefore.height=0;b.animOut.height=0};a.fn.cycle.transitions.turnLeft=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.cssBefore.left=e.cycleW;f.animIn.width=e.cycleW});b.cssBefore.top=0;b.cssBefore.width=0;b.animIn.left=0;b.animOut.width=0};a.fn.cycle.transitions.turnRight=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.animIn.width=e.cycleW;f.animOut.left=g.cycleW});a.extend(b.cssBefore,{top:0,left:0,width:0});b.animIn.left=0;b.animOut.width=0};a.fn.cycle.transitions.zoom=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,false,true);f.cssBefore.top=e.cycleH/2;f.cssBefore.left=e.cycleW/2;a.extend(f.animIn,{top:0,left:0,width:e.cycleW,height:e.cycleH});a.extend(f.animOut,{width:0,height:0,top:g.cycleH/2,left:g.cycleW/2})});b.cssFirst.top=0;b.cssFirst.left=0;b.cssBefore.width=0;b.cssBefore.height=0};a.fn.cycle.transitions.fadeZoom=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,false);f.cssBefore.left=e.cycleW/2;f.cssBefore.top=e.cycleH/2;a.extend(f.animIn,{top:0,left:0,width:e.cycleW,height:e.cycleH})});b.cssBefore.width=0;b.cssBefore.height=0;b.animOut.opacity=0};a.fn.cycle.transitions.blindX=function(d,e,c){var b=d.css("overflow","hidden").width();c.before.push(function(h,f,g){a.fn.cycle.commonReset(h,f,g);g.animIn.width=f.cycleW;g.animOut.left=h.cycleW});c.cssBefore.left=b;c.cssBefore.top=0;c.animIn.left=0;c.animOut.left=b};a.fn.cycle.transitions.blindY=function(d,e,c){var b=d.css("overflow","hidden").height();c.before.push(function(h,f,g){a.fn.cycle.commonReset(h,f,g);g.animIn.height=f.cycleH;g.animOut.top=h.cycleH});c.cssBefore.top=b;c.cssBefore.left=0;c.animIn.top=0;c.animOut.top=b};a.fn.cycle.transitions.blindZ=function(e,f,d){var c=e.css("overflow","hidden").height();var b=e.width();d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h);h.animIn.height=g.cycleH;h.animOut.top=i.cycleH});d.cssBefore.top=c;d.cssBefore.left=b;d.animIn.top=0;d.animIn.left=0;d.animOut.top=c;d.animOut.left=b};a.fn.cycle.transitions.growX=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true);f.cssBefore.left=this.cycleW/2;f.animIn.left=0;f.animIn.width=this.cycleW;f.animOut.left=0});b.cssBefore.top=0;b.cssBefore.width=0};a.fn.cycle.transitions.growY=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false);f.cssBefore.top=this.cycleH/2;f.animIn.top=0;f.animIn.height=this.cycleH;f.animOut.top=0});b.cssBefore.height=0;b.cssBefore.left=0};a.fn.cycle.transitions.curtainX=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,false,true,true);f.cssBefore.left=e.cycleW/2;f.animIn.left=0;f.animIn.width=this.cycleW;f.animOut.left=g.cycleW/2;f.animOut.width=0});b.cssBefore.top=0;b.cssBefore.width=0};a.fn.cycle.transitions.curtainY=function(c,d,b){b.before.push(function(g,e,f){a.fn.cycle.commonReset(g,e,f,true,false,true);f.cssBefore.top=e.cycleH/2;f.animIn.top=0;f.animIn.height=e.cycleH;f.animOut.top=g.cycleH/2;f.animOut.height=0});b.cssBefore.height=0;b.cssBefore.left=0};a.fn.cycle.transitions.cover=function(f,g,e){var i=e.direction||"left";var b=f.css("overflow","hidden").width();var c=f.height();e.before.push(function(j,d,h){a.fn.cycle.commonReset(j,d,h);if(i=="right"){h.cssBefore.left=-b}else{if(i=="up"){h.cssBefore.top=c}else{if(i=="down"){h.cssBefore.top=-c}else{h.cssBefore.left=b}}}});e.animIn.left=0;e.animIn.top=0;e.cssBefore.top=0;e.cssBefore.left=0};a.fn.cycle.transitions.uncover=function(f,g,e){var i=e.direction||"left";var b=f.css("overflow","hidden").width();var c=f.height();e.before.push(function(j,d,h){a.fn.cycle.commonReset(j,d,h,true,true,true);if(i=="right"){h.animOut.left=b}else{if(i=="up"){h.animOut.top=-c}else{if(i=="down"){h.animOut.top=c}else{h.animOut.left=-b}}}});e.animIn.left=0;e.animIn.top=0;e.cssBefore.top=0;e.cssBefore.left=0};a.fn.cycle.transitions.toss=function(e,f,d){var b=e.css("overflow","visible").width();var c=e.height();d.before.push(function(i,g,h){a.fn.cycle.commonReset(i,g,h,true,true,true);if(!h.animOut.left&&!h.animOut.top){a.extend(h.animOut,{left:b*2,top:-c/2,opacity:0})}else{h.animOut.opacity=0}});d.cssBefore.left=0;d.cssBefore.top=0;d.animIn.left=0};a.fn.cycle.transitions.wipe=function(s,m,e){var q=s.css("overflow","hidden").width();var j=s.height();e.cssBefore=e.cssBefore||{};var g;if(e.clip){if(/l2r/.test(e.clip)){g="rect(0px 0px "+j+"px 0px)"}else{if(/r2l/.test(e.clip)){g="rect(0px "+q+"px "+j+"px "+q+"px)"}else{if(/t2b/.test(e.clip)){g="rect(0px "+q+"px 0px 0px)"}else{if(/b2t/.test(e.clip)){g="rect("+j+"px "+q+"px "+j+"px 0px)"}else{if(/zoom/.test(e.clip)){var o=parseInt(j/2,10);var f=parseInt(q/2,10);g="rect("+o+"px "+f+"px "+o+"px "+f+"px)"}}}}}}e.cssBefore.clip=e.cssBefore.clip||g||"rect(0px 0px 0px 0px)";var k=e.cssBefore.clip.match(/(\d+)/g);var u=parseInt(k[0],10),c=parseInt(k[1],10),n=parseInt(k[2],10),i=parseInt(k[3],10);e.before.push(function(w,h,t){if(w==h){return}var d=a(w),b=a(h);a.fn.cycle.commonReset(w,h,t,true,true,false);t.cssAfter.display="block";var r=1,l=parseInt((t.speedIn/13),10)-1;(function v(){var y=u?u-parseInt(r*(u/l),10):0;var z=i?i-parseInt(r*(i/l),10):0;var A=n<j?n+parseInt(r*((j-n)/l||1),10):j;var x=c<q?c+parseInt(r*((q-c)/l||1),10):q;b.css({clip:"rect("+y+"px "+x+"px "+A+"px "+z+"px)"});(r++<=l)?setTimeout(v,13):d.css("display","none")})()});a.extend(e.cssBefore,{display:"block",opacity:1,top:0,left:0});e.animIn={left:0};e.animOut={left:0}}})(jQuery);
(function(a){a.fn.ellipsis=function(){return this.each(function(){var f=a(this);if(f.css("overflow")=="hidden"){var h=f.html();var c=f.hasClass("multiline");var d=a(this.cloneNode(true)).hide().css("position","absolute").css("overflow","visible").width(c?f.width():"auto").height(c?"auto":f.height());f.after(d);function b(){return d.height()>f.height()}function e(){return d.width()>f.width()}var g=c?b:e;while(h.length>0&&g()){h=h.substr(0,h.length-1);d.html(h+"...")}f.html(d.html());d.remove()}})}})(jQuery);(function(a){a.fn.placeholder=function(b){return this.each(function(){if(!("placeholder" in document.createElement(this.tagName.toLowerCase()))){var c=a(this),d=c.attr("placeholder");c.val(d).data("color",c.css("color")).css("color","#aaa");c.focus(function(){if(a.trim(c.val())===d){c.val("").css("color",c.data("color"))}}).blur(function(){if(!a.trim(c.val())){c.val(d).data("color",c.css("color")).css("color","#aaa")}})}})}}(jQuery));var menuYloc=null;var adminCookieExpiry=365;var sortableCookie="sortable-order";var sortableName=".sortable";$(document).ready(function(){$("input.number").live("keyup",function(a){$(this).val($(this).val().replace(/[^0-9]/g,""))});$("input.telephone").live("keyup",function(a){$(this).val($(this).val().replace(/[^0-9 ]/g,""))});$("input.email").live("keyup",function(a){$(this).val($(this).val().toLowerCase())});$(".ellipsis").ellipsis();$(".action-scroll-to-bottom").live("click",function(){$("html, body").animate({scrollTop:$("#footer").offset().top},"slow")});if(typeof $("ul.sf-menu").superfish==="function"){$("ul.sf-menu").supersubs({minWidth:15,maxWidth:27,extraWidth:1}).superfish()}if(typeof prettyPrint==="function"){prettyPrint();$(".prettyprint").after('<div class="clear"></div>').hover(function(){if($(this).css("width","auto").width()<$(this).parent().width()){$(this).css("width","100%")}},function(){})}if($(".slider-gallery").length>0){$(".slider-gallery").cycle({speed:1000,fx:"scrollRight",easing:"easeOutExpo",timeout:6000,delay:6000,pause:1,pager:"#slider_gallery_navigation",random:0})}if($(".slider-products").length>0){$(".slider-products").cycle({speed:1000,fx:"scrollLeft",easing:"easeOutExpo",timeout:6000,delay:6000,pause:1,pager:"#slider_products_navigation",random:0})}if($(".display").length>0){$(".display").dataTable({bJQueryUI:true,bRetrieve:true,bDestroy:true,sPaginationType:"full_numbers"})}if($(".basic-display").length>0){$(".basic-display").dataTable({bJQueryUI:true,bSort:false,bPaginate:false,bFilter:false,bInfo:false,bRetrieve:true,bDestroy:true}).fnDraw()}initGlobalFunctions();$(".action-image-popup").live("click",function(){loadImagePopup($(this).attr("data-image-large-path"),$(this).attr("alt"),$(this).attr("data-image-size-width"),$(this).attr("data-image-size-height"))});$(".action-delete-image").live("click",function(){if(confirm("Are you sure you want to delete this image?")){$("#ajax_loading").show();var a=$(this).parent(".image-container");$.ajax({url:"/system/ajaxDeleteImage/"+$(this).attr("rel"),success:function(){a.fadeOut();$("#ajax_loading").hide()},error:function(){alert("Sorry, there was a problem deleting this image. Please try again.");$("#ajax_loading").hide()}})}});$(".action-delete-multi-image").live("click",function(){if(confirm("Are you sure you want to delete this image?")){$("#ajax_loading").show();var a=$(this).attr("rel");$.ajax({url:"/system/ajaxDeleteImage/"+a,success:function(){$("#image-f-"+a).fadeOut(function(){$("#image-f-"+a).remove()});$("#image-i-"+a).fadeOut(function(){$("#image-i-"+a).remove()});$("#ajax_loading").hide()},error:function(){alert("Sorry, there was a problem deleting this image. Please try again.");$("#ajax_loading").hide()}})}});$.fx.speeds._default=1000;$(".action-fix").live("click",function(){$(".sidebar-tabs").tabs("select",$(this).attr("rel"));$("html, body").animate({scrollTop:$("#{{ current_tab }}").offset().top},"slow")});$(".sidebar-tabs .ui-tabs-nav li a").click(function(){if($("#form-current-tab")){$("#form-current-tab").val($(this).attr("href").replace("#",""))}})});function resetGlobalFunctions(){initGlobalFunctions()}function initGlobalFunctions(){$(".button").each(function(){$(this).button({icons:{primary:$(this).attr("data-icon-primary")?$(this).attr("data-icon-primary"):null,secondary:$(this).attr("data-icon-primary")?$(this).attr("data-icon-secondary"):null},text:$(this).attr("data-icon-only")==="true"?false:true})});$(":date").datepicker({dateFormat:"dd/mm/yy"});$(".accordion").accordion();$(".tabs").tabs().find("> .ui-tabs-nav").removeClass("ui-corner-all").addClass("ui-corner-top");$(".sidebar-tabs").tabs().addClass("ui-tabs-vertical ui-helper-clearfix").find("li").removeClass("ui-corner-top").addClass("ui-corner-left").parents(".sidebar-tabs").find(".ui-tabs-nav").removeClass("ui-corner-all").addClass("ui-corner-left").parents(".sidebar-tabs").find(".ui-tabs-panel").removeClass("ui-corner-bottom").addClass("ui-corner-right");var b=[],a=$.cookie&&$.cookie("collapsedPortlets")?$.cookie("collapsedPortlets"):"";b=a.split(",");$(".portlet").each(function(){var d=$(this),e=d.attr("id"),c=$(this).hasClass("collapsible")&&b.includes(e);d.addClass("ui-widget ui-widget-content ui-corner-all"+(c?" collapsed":"")).find("> header:first").addClass("ui-widget-header ui-corner-top").parent().find("> section:last").addClass("ui-widget-content ui-corner-bottom").parent().filter(".collapsible").find("> header:first").append('<a href="#" class="portlet-collapse ui-corner-all" role="button"><span class="'+(c?"ui-icon ui-icon-circle-plus":"ui-icon ui-icon-circle-minus")+'">Expand/Collapse</span></a>').find(".portlet-collapse").hover(function(){$(this).addClass("ui-state-hover")},function(){$(this).removeClass("ui-state-hover")}).click(function(){if(d.hasClass("collapsed")){$("span",this).removeClass("ui-icon-circle-plus").addClass("ui-icon-circle-minus");d.removeClass("collapsed").find("> section").css("display","none").slideDown(500,"easeOutExpo");if(b.includes(e)){b.remove(e);saveCollapsed(b)}}else{$("span",this).removeClass("ui-icon-circle-minus").addClass("ui-icon-circle-plus");$(this).parent().next().slideUp(500,"easeOutExpo",function(){d.addClass("collapsed");if(!b.includes(e)){b.push(e);saveCollapsed(b)}})}return false})});$("input[placeholder]").placeholder();$(".buttonset input").addClass("no-uniform");$(".buttonset").addClass("ui-corner-all").buttonset();$(":checkbox:not(.no-uniform), :radio:not(.no-uniform), select:not(.no-uniform), :file:not(.no-uniform)").uniform();$(":range").each(function(){var c=this,e={animate:true,value:$(this).val(),min:$(this).attr("min")?parseInt($(this).attr("min"),10):0,max:$(this).attr("max")?parseInt($(this).attr("max"),10):100,step:$(this).attr("step")?parseInt($(this).attr("step"),10):1,disabled:$(this).is(":disabled"),orientation:$(this).attr("data-orientation")==="vertical"?"vertical":"horizontal",range:$(this).attr("data-range")==="true"?true:($(this).attr("data-range") in {min:1,max:1}?$(this).attr("data-range"):false),values:$(this).attr("data-values")?$(this).attr("data-values").split(/,/):null,slide:function(f,g){$(c).val(g.value);if($(c).attr("data-values")){$(c).attr("data-values",g.values[0]+","+g.values[1])}$(c).change()}},d=$('<div class="slider"></div>').slider(e);$(this).before(d).hide()});$(".progress").each(function(){var c=parseInt($(this).attr("data-value"),10);$(this).progressbar({value:c}).filter("[data-show-value=true]").find("div").append("<b>"+c+"%</b>")});$(".message.closeable").prepend('<span class="message-close ui-icon ui-icon-circle-close"></span>').find(".message-close").click(function(){$(this).parent().fadeOut()});$("body").append('<div class="apple_overlay black" id="overlay"><iframe class="contentWrap" style="width: 100%; height: 500px"></iframe></div>');$("a.help[rel]").overlay({effect:"apple",onBeforeLoad:function(){var c=this.getOverlay().find(".contentWrap");c.attr("src",this.getTrigger().attr("href"))}});$("input.seo-url").bind("focus keypress keyup blur",function(){$(this).val($(this).val().toLowerCase());$(this).val($(this).val().replace(/[ ]/g,"-"));$(this).val($(this).val().replace(/[^a-z0-9-]/g,""))});$("input.uppercase").bind("focus keypress keyup blur",function(){$(this).val($(this).val().toUpperCase())});$("input.lowercase").bind("focus keypress keyup blur",function(){$(this).val($(this).val().toLowerCase())});$("input.integer").bind("focus keypress keyup blur",function(){$(this).val($(this).val().replace(/[^0-9]/g,""))});$("input.decimal").bind("focus keypress keyup blur",function(){$(this).val($(this).val().replace(/[^0-9.]/g,""))});$("input.url").bind("focus keypress keyup",function(){$(this).val($(this).val().toLowerCase());$(this).val($(this).val().replace(/[ ]/g,"-"));$(this).val($(this).val().replace(/[^a-z0-9-.?+=&://]/g,""));if($(this).val().substring(0,7)!="http://"){$(this).val("http://"+$(this).val())}});$("input.url").bind("blur",function(){$(this).val($(this).val().toLowerCase());$(this).val($(this).val().replace(/[ ]/g,"-"));$(this).val($(this).val().replace(/[^a-z0-9-.?+=&://]/g,""));if($(this).val()=="http://"){$(this).val("")}});$.tools.validator.fn("[type=time]","Please supply a valid time.",function(c,d){return(/^\d\d:\d\d$/).test(d)});$.tools.validator.fn("[data-equals]","The value you entered is not equal with the value entered in the $1 field.",function(c){var d=c.attr("data-equals"),e=this.getInputs().filter("[name="+d+"]");return c.val()===e.val()?true:[d]});$.tools.validator.fn("[minlength]",function(c,e){var d=c.attr("minlength");return e.length>=d?true:{en:"Please provide at least "+d+" character"+(d>1?"s":"")+"."}});$.tools.validator.fn("[data-validation-type=postcode]","Please enter a valid post code.",function(c,d){if(d!=""){return(/^(000|GIR ?0AA|(?:[A-PR-UWYZ](?:\d|\d{2}|[A-HK-Y]\d|[A-HK-Y]\d\d|\d[A-HJKSTUW]|[A-HK-Y]\d[ABEHMNPRV-Y])) ?\d[ABD-HJLNP-UW-Z]{2})$/).test(d)}return true});$.tools.validator.fn("[data-validation-type=telephone]","Please enter a valid post code.",function(c,d){if(d!=""){return(/((\+44\s?\(0\)\s?\d{2,4})|(\+44\s?(01|02|03|07|08)\d{2,3})|(\+44\s?(1|2|3|7|8)\d{2,3})|(\(\+44\)\s?\d{3,4})|(\(\d{5}\))|((01|02|03|07|08)\d{2,3})|(\d{5}))(\s|-|.)(((\d{3,4})(\s|-)(\d{3,4}))|((\d{6,7})))/).test(d)}return true});$.tools.validator.fn("[data-validation-type=mobile]","Please enter a valid post code.",function(c,d){if(d!=""){return(/^(\+44\s?7\d{3}|\(?07\d{3}\)?)\s?\d{3}\s?\d{3}$/).test(d)}return true});$.tools.validator.localizeFn("[type=time]",{en:"Please supply a valid time."});$.tools.validator.localize("en",{":email":"The email address you have entered is not valid.",":number":"Please enter a number only.",":url":'Please enter a valid web address. The web address must start with "http://"',"[max]":"The value you enter must not be bigger than $1.","[min]":"The value you enter must not be less than $1.","[required]":"This field is required. Please enter a value."});$(".has-validation").validator({position:"bottom left",offset:[4,0],messageClass:"form-error",errorInputEvent:"blur",inputEvent:"keyup",message:"<div><em/></div>"}).attr("novalidate","novalidate");$("fieldset.fieldset-buttons > legend").each(function(){$(this).css({marginLeft:(Math.round($(this).parent().width()/2)-Math.round($(this).width()/2))+"px"})});$(".main-content").resize(function(){(typeof $(".isotope").isotope==="function")&&$(".isotope").isotope();$("fieldset.fieldset-buttons > legend").each(function(){$(this).css({marginLeft:(Math.round($(this).parent().width()/2)-Math.round($(this).width()/2))+"px"})})});if($.cookie){if($.cookie("menuCollapsed")==="1"){$(".main-section > nav").addClass("collapsed").find("a.chevron").append('<span class="ui-icon ui-icon-circle-triangle-e"></span>');$(".main-content").resize()}else{if($.cookie("menuCollapsed")==="0"){$(".main-section > nav").removeClass("collapsed").find("a.chevron").append('<span class="ui-icon ui-icon-circle-triangle-w"></span>');$(".main-content").resize()}else{if($(".main-section > nav").hasClass("collapsed")){$(".main-section > nav").find("a.chevron").append('<span class="ui-icon ui-icon-circle-triangle-e"></span>')}else{$(".main-section > nav").find("a.chevron").append('<span class="ui-icon ui-icon-circle-triangle-e"></span>')}}}}$(".main-section > nav a.chevron").click(function(){if($(this).parent().toggleClass("collapsed").hasClass("collapsed")){$("span",this).removeClass("ui-icon-circle-triangle-w").addClass("ui-icon-circle-triangle-e");$.cookie&&$.cookie("menuCollapsed","1",{expires:adminCookieExpiry,path:"/"})}else{$("span",this).removeClass("ui-icon-circle-triangle-e").addClass("ui-icon-circle-triangle-w");$.cookie&&$.cookie("menuCollapsed","0",{expires:adminCookieExpiry,path:"/"})}$(".main-content").resize();return false});if($(sortableName).sortable){$(sortableName).sortable({cursor:"move",revert:500,opacity:0.7,appendTo:"body",handle:"header",items:"[draggable=true]",placeholder:"portlet-placeholder grid_2",forcePlaceholderSize:true,update:function(c,d){$.cookie&&$.cookie(sortableCookie,$(this).sortable("toArray"),{expires:adminCookieExpiry,path:"/"})}}).disableSelection()}$("textarea.tinymce-basic, textarea.tinymce-advanced").css("width","100%");if($("textarea.tinymce-basic").length>0){$("textarea.tinymce-basic").tinymce({script_url:"/bundles/webilluminationadmin/js/tinymce/tiny_mce.js",theme:"advanced",plugins:"contextmenu,paste,fullscreen,xhtmlxtras,advlist",theme_advanced_buttons1:"fullscreen,pasteword,|,bold,italic,underline,|,justifyleft,justifycenter,justifyright,justifyfull,|,bullist,numlist,|,outdent,indent",theme_advanced_buttons2:"",theme_advanced_buttons3:"",theme_advanced_buttons4:"",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_resizing:true,content_css:"/bundles/webilluminationadmin/css/content.css"})}if($("textarea.tinymce-advanced").length>0){$("textarea.tinymce-advanced").tinymce({script_url:"/bundles/webilluminationadmin/js/tinymce/tiny_mce.js",theme:"advanced",plugins:"pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,inlinepopups,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,advlist",theme_advanced_buttons1:"save,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect,fontselect,fontsizeselect",theme_advanced_buttons2:"cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,help,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",theme_advanced_buttons3:"tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",theme_advanced_buttons4:"insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,pagebreak",theme_advanced_toolbar_location:"top",theme_advanced_toolbar_align:"left",theme_advanced_resizing:true,content_css:"/bundles/webilluminationadmin/css/content.css"})}$("input.show-tinymce").change(function(){if($(this).val()==="1"){$($(this).attr("rel")).tinymce().show()}else{$($(this).attr("rel")).tinymce().hide()}});$.cookie&&restoreOrder(sortableName,sortableCookie);$.cookie&&$.cookie("background")&&changeBackground($.cookie("background"));$.cookie&&$.cookie("css")&&changeUicolor($.cookie("css"))}function loadImagePopup(d,c,b,a){if(c==""){c="Detailed View"}$("#dialog-image-popup-image").attr("src",d).attr("alt",c).attr("width",b).attr("height",a);$("#dialog-image-popup").dialog({autoOpen:false,autoResize:true,width:"auto",height:"auto",modal:true,show:"fade",hide:"fade"}).parents(".ui-dialog").find(".ui-dialog-titlebar-close").after("<div/>");$("#ui-dialog-title-dialog-image-popup").html(c);$("#dialog-image-popup").dialog("open")}function restoreOrder(f,k){var h=$(f);if(!h){return}var b=$.cookie(k);if(!b){return}var d=b.split(","),j=h.sortable("toArray"),g=[];for(var l=0;l<j.length;l++){g[j[l]]=j[l]}for(var e=0,c=d.length;e<c;e++){var a=d[e];if(a in g){$(f).append($(f).children("#"+a))}}}function saveCollapsed(a){$.cookie&&$.cookie("collapsedPortlets",a,{expires:adminCookieExpiry,path:"/"})}function changeBackground(a){$("body").removeClass($.cookie("background")).addClass(a);$.cookie&&$.cookie("background",a,{expires:adminCookieExpiry,path:"/"})}function changeUicolor(a){$("link.uicolor").attr("href",a);$.cookie&&$.cookie("css",a,{expires:adminCookieExpiry,path:"/"})}$.easing.drop=function(e,f,a,h,g){return -h*(Math.sqrt(1-(f/=g)*f)-1)+a};$.tools.overlay.addEffect("drop",function(d,a){var c=this.getConf(),b=this.getOverlay();if(c.fixed){d.position="fixed"}else{d.top+=$(window).scrollTop();d.left+=$(window).scrollLeft();d.position="absolute"}b.css(d).show();b.animate({top:"+=55",opacity:1,width:"+=20"},400,"drop",a)},function(a){this.getOverlay().animate({top:"-=55",opacity:0,width:"-=20"},300,"drop",function(){$(this).hide();a.call()})});if(!Array.indexOf){Array.prototype.indexOf=function(b){for(var a=0;a<this.length;a++){if(this[a]===b){return a}}return -1}}Array.prototype.includes=function(b){for(var a=0;a<this.length;a++){if(this[a]===b){return true}}return false};Array.prototype.remove=function(b){var a=this.indexOf(b);if(a!==-1){this.splice(a,1)}};function ajaxFlashMessage(a,b){if(a=="success"){$("#flash_messages").html('<div class="ui-widget message closeable"><div class="ui-state-success ui-corner-all"><p><span class="ui-icon ui-icon-circle-check"></span><strong>SUCCESS:</strong> '+b+"</p></div></div>")}else{if(a=="error"){$("#flash_messages").html('<div class="ui-widget message closeable"><div class="ui-state-error ui-corner-all"><p><span class="ui-icon ui-icon-alert"></span><strong>ERROR:</strong> '+b+"</p></div></div>")}else{$("#flash_messages").html('<div class="ui-widget message closeable"><div class="ui-state-highlight ui-corner-all"><p><span class="ui-icon ui-icon-info"></span><strong>NOTICE:</strong> '+b+"</p></div></div>")}}$(".message.closeable").prepend('<span class="message-close ui-icon ui-icon-circle-close"></span>').find(".message-close").click(function(){$(this).parent().fadeOut(function(){$(this).remove()})})};
