/*
 Copyright (c) 2007 Paul Bakaus (paul.bakaus@googlemail.com) and Brandon Aaron (brandon.aaron@gmail.com || http://brandonaaron.net)
 Dual licensed under the MIT (http://www.opensource.org/licenses/mit-license.php)
 and GPL (http://www.opensource.org/licenses/gpl-license.php) licenses.
 $LastChangedDate: 2007-12-20 15:43:48 +0100 (Do, 20 Dez 2007) $
 $Rev: 4257 $
 Version: @VERSION
*/
// jquery.dimensions.js
(function($){$.dimensions={version:'@VERSION'};$.each(['Height','Width'],function(i,d){$.fn['inner'+d]=function(){if(!this[0])return;var a=d=='Height'?'Top':'Left',borr=d=='Height'?'Bottom':'Right';return this.is(':visible')?this[0]['client'+d]:num(this,d.toLowerCase())+num(this,'padding'+a)+num(this,'padding'+borr)};$.fn['outer'+d]=function(a){if(!this[0])return;var b=d=='Height'?'Top':'Left',borr=d=='Height'?'Bottom':'Right';a=$.extend({margin:false},a||{});var c=this.is(':visible')?this[0]['offset'+d]:num(this,d.toLowerCase())+num(this,'border'+b+'Width')+num(this,'border'+borr+'Width')+num(this,'padding'+b)+num(this,'padding'+borr);return c+(a.margin?(num(this,'margin'+b)+num(this,'margin'+borr)):0)}});$.each(['Left','Top'],function(i,b){$.fn['scroll'+b]=function(a){if(!this[0])return;return a!=undefined?this.each(function(){this==window||this==document?window.scrollTo(b=='Left'?a:$(window)['scrollLeft'](),b=='Top'?a:$(window)['scrollTop']()):this['scroll'+b]=a}):this[0]==window||this[0]==document?self[(b=='Left'?'pageXOffset':'pageYOffset')]||$.boxModel&&document.documentElement['scroll'+b]||document.body['scroll'+b]:this[0]['scroll'+b]}});$.fn.extend({position:function(){var a=0,top=0,elem=this[0],offset,parentOffset,offsetParent,results;if(elem){offsetParent=this.offsetParent();offset=this.offset();parentOffset=offsetParent.offset();offset.top-=num(elem,'marginTop');offset.left-=num(elem,'marginLeft');parentOffset.top+=num(offsetParent,'borderTopWidth');parentOffset.left+=num(offsetParent,'borderLeftWidth');results={top:offset.top-parentOffset.top,left:offset.left-parentOffset.left}}return results},offsetParent:function(){var a=this[0].offsetParent;while(a&&(!/^body|html$/i.test(a.tagName)&&$.css(a,'position')=='static'))a=a.offsetParent;return $(a)}});function num(a,b){return parseInt($.curCSS(a.jquery?a[0]:a,b,true))||0}})(jQuery);
// ui.mouse.js
(function($){$.ui=$.ui||{};$.extend($.ui,{plugin:{add:function(a,b,c){var d=$.ui[a].prototype;for(var i in c){d.plugins[i]=d.plugins[i]||[];d.plugins[i].push([b,c[i]])}},call:function(a,b,c){var d=a.plugins[b];if(!d)return;for(var i=0;i<d.length;i++){if(a.options[d[i][0]])d[i][1].apply(a.element,c)}}},cssCache:{},css:function(a){if($.ui.cssCache[a])return $.ui.cssCache[a];var b=$('<div class="ui-resizable-gen">').addClass(a).css({position:'absolute',top:'-5000px',left:'-5000px',display:'block'}).appendTo('body');$.ui.cssCache[a]=!!(((/^[1-9]/).test(b.css('height'))||(/^[1-9]/).test(b.css('width'))||!(/none/).test(b.css('backgroundImage'))||!(/transparent|rgba\(0, 0, 0, 0\)/).test(b.css('backgroundColor'))));try{$('body').get(0).removeChild(b.get(0))}catch(e){}return $.ui.cssCache[a]},disableSelection:function(e){if(!e)return;e.unselectable="on";e.onselectstart=function(){return false};if(e.style)e.style.MozUserSelect="none"},enableSelection:function(e){if(!e)return;e.unselectable="off";e.onselectstart=function(){return true};if(e.style)e.style.MozUserSelect=""}});$.fn.extend({mouseInteraction:function(o){return this.each(function(){new $.ui.mouseInteraction(this,o)})},removeMouseInteraction:function(o){return this.each(function(){if($.data(this,"ui-mouse"))$.data(this,"ui-mouse").destroy()})}});$.ui.mouseInteraction=function(a,b){var c=this;this.element=a;$.data(this.element,"ui-mouse",this);this.options=$.extend({},b);$(a).bind('mousedown.draggable',function(){return c.click.apply(c,arguments)});if($.browser.msie)$(a).attr('unselectable','on')};$.extend($.ui.mouseInteraction.prototype,{destroy:function(){$(this.element).unbind('mousedown.draggable')},trigger:function(){return this.click.apply(this,arguments)},click:function(e){if(e.which!=1||$.inArray(e.target.nodeName.toLowerCase(),this.options.dragPrevention)!=-1||(this.options.condition&&!this.options.condition.apply(this.options.executor||this,[e,this.element])))return true;var a=this;var b=function(){a._MP={left:e.pageX,top:e.pageY};$(document).bind('mouseup.draggable',function(){return a.stop.apply(a,arguments)});$(document).bind('mousemove.draggable',function(){return a.drag.apply(a,arguments)})};if(this.options.delay){if(this.timer)clearInterval(this.timer);this.timer=setTimeout(b,this.options.delay)}else{b()}return false},stop:function(e){var o=this.options;if(!this.initialized)return $(document).unbind('mouseup.draggable').unbind('mousemove.draggable');if(this.options.stop)this.options.stop.call(this.options.executor||this,e,this.element);$(document).unbind('mouseup.draggable').unbind('mousemove.draggable');this.initialized=false;return false},drag:function(e){var o=this.options;if($.browser.msie&&!e.button)return this.stop.apply(this,[e]);if(!this.initialized&&(Math.abs(this._MP.left-e.pageX)>=o.distance||Math.abs(this._MP.top-e.pageY)>=o.distance)){if(this.options.start)this.options.start.call(this.options.executor||this,e,this.element);this.initialized=true}else{if(!this.initialized)return false}if(o.drag)o.drag.call(this.options.executor||this,e,this.element);return false}})})(jQuery);
// ui.accordion.js
(function($){$.ui=$.ui||{};$.fn.extend({accordion:function(b,c){var d=Array.prototype.slice.call(arguments,1);return this.each(function(){if(typeof b=="string"){var a=$.data(this,"ui-accordion");a[b].apply(a,d)}else if(!$(this).is(".ui-accordion"))$.data(this,"ui-accordion",new $.ui.accordion(this,b))})},activate:function(a){return this.accordion("activate",a)}});$.ui.accordion=function(a,b){this.options=b=$.extend({},$.ui.accordion.defaults,b);this.element=a;$(a).addClass("ui-accordion");if(b.navigation){var c=$(a).find("a").filter(b.navigationFilter);if(c.length){if(c.filter(b.header).length){b.active=c}else{b.active=c.parent().parent().prev();c.addClass("current")}}}b.headers=$(a).find(b.header);b.active=findActive(b.headers,b.active);if(b.fillSpace){var d=$(a).parent().height();b.headers.each(function(){d-=$(this).outerHeight()});var e=0;b.headers.next().each(function(){e=Math.max(e,$(this).innerHeight()-$(this).height())}).height(d-e)}else if(b.autoheight){var d=0;b.headers.next().each(function(){d=Math.max(d,$(this).outerHeight())}).height(d)}b.headers.not(b.active||"").next().hide();b.active.parent().andSelf().addClass(b.selectedClass);if(b.event)$(a).bind((b.event||"")+".ui-accordion",clickHandler)};$.ui.accordion.prototype={activate:function(a){clickHandler.call(this.element,{target:findActive(this.options.headers,a)[0]})},enable:function(){this.options.disabled=false},disable:function(){this.options.disabled=true},destroy:function(){this.options.headers.next().css("display","");if(this.options.fillSpace||this.options.autoheight){this.options.headers.next().css("height","")}$.removeData(this.element,"ui-accordion");$(this.element).removeClass("ui-accordion").unbind(".ui-accordion")}};function scopeCallback(a,b){return function(){return a.apply(b,arguments)}};function completed(a){if(!$.data(this,"ui-accordion"))return;var b=$.data(this,"ui-accordion");var c=b.options;c.running=a?0:--c.running;if(c.running)return;if(c.clearStyle){c.toShow.add(c.toHide).css({height:"",overflow:""})}$(this).triggerHandler("change.ui-accordion",[c.data],c.change)}function toggle(a,b,c,d,e){var f=$.data(this,"ui-accordion").options;f.toShow=a;f.toHide=b;f.data=c;var g=scopeCallback(completed,this);f.running=b.size()==0?a.size():b.size();if(f.animated){if(!f.alwaysOpen&&d){$.ui.accordion.animations[f.animated]({toShow:jQuery([]),toHide:b,complete:g,down:e,autoheight:f.autoheight})}else{$.ui.accordion.animations[f.animated]({toShow:a,toHide:b,complete:g,down:e,autoheight:f.autoheight})}}else{if(!f.alwaysOpen&&d){a.toggle()}else{b.hide();a.show()}g(true)}}function clickHandler(a){var b=$.data(this,"ui-accordion").options;if(b.disabled)return false;if(!a.target&&!b.alwaysOpen){b.active.parent().andSelf().toggleClass(b.selectedClass);var c=b.active.next(),data={instance:this,options:b,newHeader:jQuery([]),oldHeader:b.active,newContent:jQuery([]),oldContent:c},f=b.active=$([]);toggle.call(this,f,c,data);return false}var d=$(a.target);if(d.parents(b.header).length)while(!d.is(b.header))d=d.parent();var e=d[0]==b.active[0];if(b.running||(b.alwaysOpen&&e))return false;if(!d.is(b.header))return;b.active.parent().andSelf().toggleClass(b.selectedClass);if(!e){d.parent().andSelf().addClass(b.selectedClass)}var f=d.next(),c=b.active.next(),data={instance:this,options:b,newHeader:d,oldHeader:b.active,newContent:f,oldContent:c},down=b.headers.index(b.active[0])>b.headers.index(d[0]);b.active=e?$([]):d;toggle.call(this,f,c,data,e,down);return false};function findActive(a,b){return b!=undefined?typeof b=="number"?a.filter(":eq("+b+")"):a.not(a.not(b)):b===false?$([]):a.filter(":eq(0)")}$.extend($.ui.accordion,{defaults:{selectedClass:"selected",alwaysOpen:true,animated:'slide',event:"click",header:"a",autoheight:true,running:0,navigationFilter:function(){return this.href.toLowerCase()==location.href.toLowerCase()}},animations:{slide:function(c,d){c=$.extend({easing:"swing",duration:300},c,d);if(!c.toHide.size()){c.toShow.animate({height:"show"},c);return}var e=c.toHide.height(),showHeight=c.toShow.height(),difference=showHeight/e;c.toShow.css({height:0,overflow:'hidden'}).show();c.toHide.filter(":hidden").each(c.complete).end().filter(":visible").animate({height:"hide"},{step:function(a){var b=(e-a)*difference;if($.browser.msie||$.browser.opera){b=Math.ceil(b)}c.toShow.height(b)},duration:c.duration,easing:c.easing,complete:function(){if(!c.autoheight){c.toShow.css("height","auto")}c.complete()}})},bounceslide:function(a){this.slide(a,{easing:a.down?"bounceout":"swing",duration:a.down?1000:200})},easeslide:function(a){this.slide(a,{easing:"easeinout",duration:700})}}})})(jQuery);
// ui.resizable.js
(function($){$.fn.resizable=function(c){return this.each(function(){var a=Array.prototype.slice.call(arguments,1);if(typeof c=="string"){var b=$.data(this,"ui-resizable");b[c].apply(b,a)}else if(!$(this).is(".ui-resizable"))new $.ui.resizable(this,c)})};$.ui.resizable=function(f,g){var h=this;this.element=$(f);$.data(f,"ui-resizable",this);this.element.addClass("ui-resizable");this.options=$.extend({preventDefault:true,transparent:false,minWidth:10,minHeight:10,aspectRatio:false,disableSelection:true,preserveCursor:true,autohide:false},g);this.options._aspectRatio=!!(this.options.aspectRatio);$(f).bind("setData.resizable",function(a,b,c){h.options[b]=c}).bind("getData.resizable",function(a,b){return h.options[b]});var o=this.options;var j='1px solid #DEDEDE';o.defaultTheme={'ui-resizable':{display:'block'},'ui-resizable-handle':{position:'absolute',background:'#F5F5F5'},'ui-resizable-n':{cursor:'n-resize',height:'4px',left:'0px',right:'0px',borderTop:j},'ui-resizable-s':{cursor:'s-resize',height:'4px',left:'0px',right:'0px',borderBottom:j},'ui-resizable-e':{cursor:'e-resize',width:'4px',top:'0px',bottom:'0px',borderRight:j},'ui-resizable-w':{cursor:'w-resize',width:'4px',top:'0px',bottom:'0px',borderLeft:j},'ui-resizable-se':{cursor:'se-resize',width:'4px',height:'4px',borderRight:j,borderBottom:j},'ui-resizable-sw':{cursor:'sw-resize',width:'4px',height:'4px',borderBottom:j,borderLeft:j},'ui-resizable-ne':{cursor:'ne-resize',width:'4px',height:'4px',borderRight:j,borderTop:j},'ui-resizable-nw':{cursor:'nw-resize',width:'4px',height:'4px',borderLeft:j,borderTop:j}};if(!o.proxy&&(this.element.css('position')=='static'||this.element.css('position')==''))this.element.css('position','relative');var k=f.nodeName;if(k.match(/textarea|input|select|button|img/i)){this.element.wrap('<div class="ui-wrapper"  style="overflow: hidden; position: relative; width: '+this.element.outerWidth()+'px; height: '+this.element.outerHeight()+';"></div>');var l=this.element;f=f.parentNode;this.element=$(f);this.element.css({marginLeft:l.css("marginLeft"),marginTop:l.css("marginTop"),marginRight:l.css("marginRight"),marginBottom:l.css("marginBottom")});l.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0});if($.browser.safari&&o.preventDefault)l.css('resize','none');o.proportionallyResize=l.css('position','static');this._proportionallyResize()}if(!o.handles)o.handles=!$('.ui-resizable-handle',f).length?"e,s,se":{n:'.ui-resizable-n',e:'.ui-resizable-e',s:'.ui-resizable-s',w:'.ui-resizable-w',se:'.ui-resizable-se',sw:'.ui-resizable-sw',ne:'.ui-resizable-ne',nw:'.ui-resizable-nw'};if(o.handles.constructor==String){if(o.handles=='all')o.handles='n,e,s,w,se,sw,ne,nw';var n=o.handles.split(",");o.handles={};o.zIndex=o.zIndex||1000;var m={handle:'overflow:hidden; position:absolute;',n:'top: 0pt; width:100%;',e:'right: 0pt; height:100%;',s:'bottom: 0pt; width:100%;',w:'left: 0pt; height:100%;',se:'bottom: 0pt; right: 0px;',sw:'bottom: 0pt; left: 0px;',ne:'top: 0pt; right: 0px;',nw:'top: 0pt; left: 0px;'};for(var i=0;i<n.length;i++){var d=jQuery.trim(n[i]),t=o.defaultTheme,hname='ui-resizable-'+d;var p=$.extend(t[hname],t['ui-resizable-handle']),axis=$(["<div class=\"",hname," ui-resizable-handle\" style=\"",m[d],m.handle,"\"></div>"].join("")).css(/sw|se|ne|nw/.test(d)?{zIndex:++o.zIndex}:{});o.handles[d]='.ui-resizable-'+d;this.element.append(axis.css(!$.ui.css(hname)?p:{}))}}this._renderAxis=function(a){a=a||this.element;for(var i in o.handles){if(o.handles[i].constructor==String)o.handles[i]=$(o.handles[i],f).show();if(o.transparent)o.handles[i].css({opacity:0});if(this.element.is('.ui-wrapper')&&k.match(/textarea|input|select|button/i)){var b=$(o.handles[i],f),padWrapper=0;padWrapper=/sw|ne|nw|se|n|s/.test(i)?b.outerHeight():b.outerWidth();var c=['padding',/ne|nw|n/.test(i)?'Top':/se|sw|s/.test(i)?'Bottom':/^e$/.test(i)?'Right':'Left'].join("");if(!o.transparent)a.css(c,padWrapper)}if(!$(o.handles[i]).length)continue}};this._renderAxis(this.element);var q=$('.ui-resizable-handle',h.element);if(o.disableSelection)q.each(function(i,e){$.ui.disableSelection(e)});q.mouseover(function(){if(!o.resizing){if(this.className)var a=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i);o.axis=a&&a[1]?a[1]:'se'}});if(o.autohide){var r=$.ui.css('ui-resizable-s')||$.ui.css('ui-resizable-e');if(!r)q.hide();$(h.element).addClass("ui-resizable-autohide").hover(function(){if(!r)q.show();$(this).removeClass("ui-resizable-autohide")},function(){if(!o.resizing){if(!r)q.hide();$(this).addClass("ui-resizable-autohide")}})}this.element.mouseInteraction({executor:this,delay:0,distance:0,dragPrevention:['input','textarea','button','select','option'],start:this.start,stop:this.stop,drag:this.drag,condition:function(e){if(this.disabled)return false;for(var i in this.options.handles){if($(this.options.handles[i])[0]==e.target)return true}return false}})};$.extend($.ui.resizable.prototype,{plugins:{},ui:function(){return{instance:this,axis:this.options.axis,options:this.options}},_proportionallyResize:function(){var o=this.options;if(!o.proportionallyResize)return;var c=o.proportionallyResize;var b=[c.css('borderTopWidth'),c.css('borderRightWidth'),c.css('borderBottomWidth'),c.css('borderLeftWidth')];var p=[c.css('paddingTop'),c.css('paddingRight'),c.css('paddingBottom'),c.css('paddingLeft')];o.borderDif=o.borderDif||$.map(b,function(v,i){var a=parseInt(v,10)||0,padding=parseInt(p[i],10)||0;return a+padding});c.css({display:'block',height:(this.element.height()-o.borderDif[0]-o.borderDif[2])+"px",width:(this.element.width()-o.borderDif[1]-o.borderDif[3])+"px"})},_renderProxy:function(){var a=this.element,o=this.options;this.offset=a.offset();if(o.proxy){this.helper=this.helper||$('<div style="overflow:hidden;"></div>');var b=($.browser.msie&&$.browser.version<7?3:0);this.helper.addClass(o.proxy).css({width:a.outerWidth(),height:a.outerHeight(),position:'absolute',left:this.offset.left-b+'px',top:this.offset.top-b+'px',zIndex:++o.zIndex});this.helper.appendTo("body");if(o.disableSelection)$.ui.disableSelection(this.helper.get(0))}else{this.helper=a}},propagate:function(n,e){$.ui.plugin.call(this,n,[e,this.ui()]);this.element.triggerHandler(n=="resize"?n:"resize"+n,[e,this.ui()],this.options[n])},destroy:function(){this.element.removeClass("ui-resizable ui-resizable-disabled").removeMouseInteraction().removeData("ui-resizable").unbind(".resizable")},enable:function(){this.element.removeClass("ui-resizable-disabled");this.disabled=false},disable:function(){this.element.addClass("ui-resizable-disabled");this.disabled=true},start:function(e){var o=this.options,iniPos=this.element.position(),el=this.element;o.resizing=true;o.documentScroll={top:$(document).scrollTop(),left:$(document).scrollLeft()};if(el.is('.ui-draggable')||(/absolute/).test(el.css('position'))){var c=$.browser.msie&&!o.containment&&(/absolute/).test(el.css('position'))&&!(/relative/).test(el.parent().css('position'));var d=c?o.documentScroll.top:0,dscrolll=c?o.documentScroll.left:0;el.css({position:'absolute',top:(iniPos.top+d),left:(iniPos.left+dscrolll)})}if(/relative/.test(el.css('position'))&&$.browser.opera)el.css({position:'relative',top:'auto',left:'auto'});this._renderProxy();var f=parseInt(this.helper.css('left'),10)||0,curtop=parseInt(this.helper.css('top'),10)||0;$.extend(o,{currentSize:{width:el.outerWidth(),height:el.outerHeight()},currentSizeDiff:{width:el.outerWidth()-el.width(),height:el.outerHeight()-el.height()},startMousePosition:{left:e.pageX,top:e.pageY},startPosition:{left:f,top:curtop},currentPosition:{left:f,top:curtop}});var g=o.currentSize.width<o.currentSize.height;o.aspectRatio=(typeof o.aspectRatio=='number')?o.aspectRatio:Math.pow(o.currentSize.width/o.currentSize.height,g?1:-1);o.aspectRatioTarget=g?"width":"height";if(o.preserveCursor)$('body').css('cursor',o.axis+'-resize');if(o.containment){var h=o.containment,ce=(h instanceof jQuery)?h.get(0):(/parent/.test(h))?el.parent().get(0):null;if(ce){var i=function(e,a){var b=/top/.test(a||"top")?'scrollTop':'scrollLeft',has=false;if(e[b]>0)return true;e[b]=1;has=e[b]>0?true:false;e[b]=0;return has};var j=$(ce).offset(),ch=$(ce).innerHeight(),cw=$(ce).innerWidth();o.cdata={e:ce,l:j.left,t:j.top,w:(i(ce,"left")?ce.scrollWidth:cw),h:(i(ce)?ce.scrollHeight:ch)}}if(/document/.test(h)||h==document)o.cdata={e:document,l:0,t:0,w:$(document).width(),h:$(document).height()}}this.propagate("start",e);return false},stop:function(e){this.options.resizing=false;var o=this.options;if(o.proxy){var a={width:(this.helper.width()-o.currentSizeDiff.width)+"px",height:(this.helper.height()-o.currentSizeDiff.height)+"px",top:((parseInt(this.element.css('top'),10)||0)+((parseInt(this.helper.css('top'),10)-this.offset.top)||0)),left:((parseInt(this.element.css('left'),10)||0)+((parseInt(this.helper.css('left'),10)-this.offset.left)||0))};this.element.css(a);if(o.proxy)this._proportionallyResize();this.helper.remove()}if(o.preserveCursor)$('body').css('cursor','auto');this.propagate("stop",e);return false},drag:function(e){var g=this.helper,o=this.options,props={},self=this,pRatio=o._aspectRatio||e.shiftKey;var h=function(a,b){var c=(a=="top"||a=="height"),ishw=(a=="width"||a=="height"),defAxis=(o.axis=="se"||o.axis=="s"||o.axis=="e");var d=(e[c?'pageY':'pageX']-o.startMousePosition[c?'top':'left'])*(b?-1:1);var f=o[ishw?'currentSize':'startPosition'][a]-d-(!o.proxy&&defAxis?o.currentSizeDiff.width:0);if(pRatio){var v=f*Math.pow(o.aspectRatio,(c?-1:1)*(o.aspectRatioTarget=='height'?1:-1)),locked=false;if(c&&v>=o.maxWidth||!c&&v>=o.maxHeight)locked=true;if(c&&v<=o.minWidth||!c&&v<=o.minHeight)locked=true;if(ishw&&!locked)g.css(c?"width":"height",v);if(a=="top"&&(o.axis=="ne"||o.axis=="nw")){return}}g.css(a,f)};var a=o.axis,tminval=0,tmaxval;if(a=="n"||a=="ne"||a=="nw")h("height");if(a=="s"||a=="se"||a=="sw")h("height",1);var i=parseInt(g.css('height'),10)||0;if(o.minHeight&&i<=o.minHeight)g.css('height',o.minHeight);if(o.maxHeight&&i>=o.maxHeight)g.css('height',o.maxHeight);if(a=="n"||a=="ne"||a=="nw")h("top",1);var j=parseInt(g.css('top'),10)||0;tminval=(o.startPosition.top+(o.currentSize.height-o.minHeight));tmaxval=(o.startPosition.top+(o.currentSize.height-o.maxHeight));if(o.minHeight&&j>=tminval)g.css('top',tminval);if(o.maxHeight&&j<=tmaxval)g.css('top',tmaxval);if(a=="e"||a=="se"||a=="ne")h("width",1);if(a=="sw"||a=="w"||a=="nw")h("width");var k=parseInt(g.css('width'),10)||0;if(o.minWidth&&k<=o.minWidth)g.css('width',o.minWidth);if(o.maxWidth&&k>=o.maxWidth)g.css('width',o.maxWidth);if(a=="sw"||a=="w"||a=="nw")h("left",1);var l=parseInt(g.css('left'),10)||0;tminval=(o.startPosition.left+(o.currentSize.width-o.minWidth));tmaxval=(o.startPosition.left+(o.currentSize.width-o.maxWidth));if(o.minWidth&&l>=tminval)g.css('left',tminval);if(o.maxWidth&&l<=tmaxval)g.css('left',tmaxval);if(o.containment&&o.cdata.e){if(l<0){g.css('left',0);g.css('width',k+l)}if(j<0){g.css('top',0);g.css('height',i+j)}if(k+o.currentSizeDiff.width+l>=o.cdata.w)g.css('width',o.cdata.w-o.currentSizeDiff.width-(l<0?0:l));if(i+o.currentSizeDiff.height+j>=o.cdata.h)g.css('height',o.cdata.h-o.currentSizeDiff.height-(j<0?0:j))}o.currentPosition={left:l,top:j};if(!o.proxy)this._proportionallyResize();this.propagate("resize",e);return false}})})(jQuery);
/*
 jQuery Tooltip plugin 1.2
  http://bassistance.de/jquery-plugins/jquery-plugin-tooltip/
  http://docs.jquery.com/Plugins/Tooltip
 Copyright (c) 2006 - 2008 Jörn Zaefferer
 $Id: jquery.tooltip.js 4569 2008-01-31 19:36:35Z joern.zaefferer $
 Dual licensed under the MIT and GPL licenses:
  http://www.opensource.org/licenses/mit-license.php
  http://www.gnu.org/licenses/gpl.html
*/
(function($){var d={},current,title,tID,IE=$.browser.msie&&/MSIE\s(5\.5|6\.)/.test(navigator.userAgent),track=false;$.tooltip={blocked:false,defaults:{delay:200,showURL:true,extraClass:"",top:15,left:15,id:"tooltip"},block:function(){$.tooltip.blocked=!$.tooltip.blocked}};$.fn.extend({tooltip:function(a){a=$.extend({},$.tooltip.defaults,a);createHelper(a);return this.each(function(){$.data(this,"tooltip-settings",a);this.tooltipText=this.title;$(this).removeAttr("title");this.alt=""}).hover(save,hide).click(hide)},fixPNG:IE?function(){return this.each(function(){var b=$(this).css('backgroundImage');if(b.match(/^url\(["']?(.*\.png)["']?\)$/i)){b=RegExp.$1;$(this).css({'backgroundImage':'none','filter':"progid:DXImageTransform.Microsoft.AlphaImageLoader(enabled=true, sizingMethod=crop, src='"+b+"')"}).each(function(){var a=$(this).css('position');if(a!='absolute'&&a!='relative')$(this).css('position','relative')})}})}:function(){return this},unfixPNG:IE?function(){return this.each(function(){$(this).css({'filter':'',backgroundImage:''})})}:function(){return this},hideWhenEmpty:function(){return this.each(function(){$(this)[$(this).html()?"show":"hide"]()})},url:function(){return this.attr('href')||this.attr('src')}});function createHelper(a){if(d.parent)return;d.parent=$('<div id="'+a.id+'"><h3></h3><div class="body"></div><div class="url"></div></div>').appendTo(document.body).hide();if($.fn.bgiframe)d.parent.bgiframe();d.title=$('h3',d.parent);d.body=$('div.body',d.parent);d.url=$('div.url',d.parent)}function settings(a){return $.data(a,"tooltip-settings")}function handle(a){if(settings(this).delay)tID=setTimeout(show,settings(this).delay);else show();track=!!settings(this).track;$(document.body).bind('mousemove',update);update(a)}function save(){if($.tooltip.blocked||this==current||(!this.tooltipText&&!settings(this).bodyHandler))return;current=this;title=this.tooltipText;if(settings(this).bodyHandler){d.title.hide();var a=settings(this).bodyHandler.call(this);if(a.nodeType||a.jquery){d.body.empty().append(a)}else{d.body.html(a)}d.body.show()}else if(settings(this).showBody){var b=title.split(settings(this).showBody);d.title.html(b.shift()).show();d.body.empty();for(var i=0,part;part=b[i];i++){if(i>0)d.body.append("<br/>");d.body.append(part)}d.body.hideWhenEmpty()}else{d.title.html(title).show();d.body.hide()}if(settings(this).showURL&&$(this).url())d.url.html($(this).url().replace('http://','')).show();else d.url.hide();d.parent.addClass(settings(this).extraClass);if(settings(this).fixPNG)d.parent.fixPNG();handle.apply(this,arguments)}function show(){tID=null;d.parent.show();update()}function update(a){if($.tooltip.blocked)return;if(!track&&d.parent.is(":visible")){$(document.body).unbind('mousemove',update)}if(current==null){$(document.body).unbind('mousemove',update);return}d.parent.removeClass("viewport-right").removeClass("viewport-bottom");var b=d.parent[0].offsetLeft;var c=d.parent[0].offsetTop;if(a){b=a.pageX+settings(current).left;c=a.pageY+settings(current).top;d.parent.css({left:b+'px',top:c+'px'})}var v=viewport(),h=d.parent[0];if(v.x+v.cx<h.offsetLeft+h.offsetWidth){b-=h.offsetWidth+20+settings(current).left;d.parent.css({left:b+'px'}).addClass("viewport-right")}if(v.y+v.cy<h.offsetTop+h.offsetHeight){c-=h.offsetHeight+20+settings(current).top;d.parent.css({top:c+'px'}).addClass("viewport-bottom")}}function viewport(){return{x:$(window).scrollLeft(),y:$(window).scrollTop(),cx:$(window).width(),cy:$(window).height()}}function hide(a){if($.tooltip.blocked)return;if(tID)clearTimeout(tID);current=null;d.parent.hide().removeClass(settings(this).extraClass);if(settings(this).fixPNG)d.parent.unfixPNG()}$.fn.Tooltip=$.fn.tooltip})(jQuery);
/*
    ColorBox v1.3.6 - a full featured, light-weight, customizable lightbox based on jQuery 1.3
*/
(function(c){function r(b,d){d=d==="x"?m.width():m.height();return typeof b==="string"?Math.round(b.match(/%/)?d/100*parseInt(b,10):parseInt(b,10)):b}function M(b){b=c.isFunction(b)?b.call(i):b;return a.photo||b.match(/\.(gif|png|jpg|jpeg|bmp)(?:\?([^#]*))?(?:#(\.*))?$/i)}function Y(){for(var b in a)if(c.isFunction(a[b])&&b.substring(0,2)!=="on")a[b]=a[b].call(i);a.rel=a.rel||i.rel;a.href=a.href||i.href;a.title=a.title||i.title}function Z(b){i=b;a=c(i).data(q);Y();if(a.rel&&a.rel!=="nofollow"){g= c(".cboxElement").filter(function(){return(c(this).data(q).rel||this.rel)===a.rel});j=g.index(i);if(j<0){g=g.add(i);j=g.length-1}}else{g=c(i);j=0}if(!B){C=B=n;N=i;N.blur();c(document).bind("keydown.cbox_close",function(d){if(d.keyCode===27){d.preventDefault();e.close()}}).bind("keydown.cbox_arrows",function(d){if(g.length>1)if(d.keyCode===37){d.preventDefault();D.click()}else if(d.keyCode===39){d.preventDefault();E.click()}});a.overlayClose&&s.css({cursor:"pointer"}).one("click",e.close);c.event.trigger(aa); a.onOpen&&a.onOpen.call(i);s.css({opacity:a.opacity}).show();a.w=r(a.initialWidth,"x");a.h=r(a.initialHeight,"y");e.position(0);O&&m.bind("resize.cboxie6 scroll.cboxie6",function(){s.css({width:m.width(),height:m.height(),top:m.scrollTop(),left:m.scrollLeft()})}).trigger("scroll.cboxie6")}P.add(D).add(E).add(t).add(Q).hide();R.html(a.close).show();e.slideshow();e.load()}var q="colorbox",F="hover",n=true,e,x=!c.support.opacity,O=x&&!window.XMLHttpRequest,aa="cbox_open",H="cbox_load",S="cbox_complete", T="resize.cbox_resize",s,k,u,p,U,V,W,X,g,m,l,I,J,K,Q,P,t,E,D,R,y,z,v,w,i,N,j,a,B,C,$={transition:"elastic",speed:350,width:false,height:false,innerWidth:false,innerHeight:false,initialWidth:"400",initialHeight:"400",maxWidth:false,maxHeight:false,scalePhotos:n,scrolling:n,inline:false,html:false,iframe:false,photo:false,href:false,title:false,rel:false,opacity:0.9,preloading:n,current:"image {current} of {total}",previous:"previous",next:"next",close:"close",open:false,overlayClose:n,slideshow:false, slideshowAuto:n,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",onOpen:false,onLoad:false,onComplete:false,onCleanup:false,onClosed:false};e=c.fn.colorbox=function(b,d){var h=this;if(!h.length)if(h.selector===""){h=c("<a/>");b.open=n}else return this;h.each(function(){var f=c.extend({},c(this).data(q)?c(this).data(q):$,b);c(this).data(q,f).addClass("cboxElement");if(d)c(this).data(q).onComplete=d});b&&b.open&&Z(h);return this};e.init=function(){function b(d){return c('<div id="cbox'+ d+'"/>')}m=c(window);k=c('<div id="colorbox"/>');s=b("Overlay").hide();u=b("Wrapper");p=b("Content").append(l=b("LoadedContent").css({width:0,height:0}),J=b("LoadingOverlay"),K=b("LoadingGraphic"),Q=b("Title"),P=b("Current"),t=b("Slideshow"),E=b("Next"),D=b("Previous"),R=b("Close"));u.append(c("<div/>").append(b("TopLeft"),U=b("TopCenter"),b("TopRight")),c("<div/>").append(V=b("MiddleLeft"),p,W=b("MiddleRight")),c("<div/>").append(b("BottomLeft"),X=b("BottomCenter"),b("BottomRight"))).children().children().css({"float":"left"}); I=c("<div style='position:absolute; top:0; left:0; width:9999px; height:0;'/>");c("body").prepend(s,k.append(u,I));if(x){k.addClass("cboxIE");O&&s.css("position","absolute")}p.children().bind("mouseover mouseout",function(){c(this).toggleClass(F)}).addClass(F);y=U.height()+X.height()+p.outerHeight(n)-p.height();z=V.width()+W.width()+p.outerWidth(n)-p.width();v=l.outerHeight(n);w=l.outerWidth(n);k.css({"padding-bottom":y,"padding-right":z}).hide();E.click(e.next);D.click(e.prev);R.click(e.close);p.children().removeClass(F); c(".cboxElement").live("click",function(d){if(d.button!==0&&typeof d.button!=="undefined")return n;else{Z(this);return false}})};e.position=function(b,d){function h(A){U[0].style.width=X[0].style.width=p[0].style.width=A.style.width;K[0].style.height=J[0].style.height=p[0].style.height=V[0].style.height=W[0].style.height=A.style.height}var f=m.height();f=Math.max(f-a.h-v-y,0)/2+m.scrollTop();var o=Math.max(document.documentElement.clientWidth-a.w-w-z,0)/2+m.scrollLeft();b=k.width()===a.w+w&&k.height()=== a.h+v?0:b;u[0].style.width=u[0].style.height="9999px";k.dequeue().animate({width:a.w+w,height:a.h+v,top:f,left:o},{duration:b,complete:function(){h(this);C=false;u[0].style.width=a.w+w+z+"px";u[0].style.height=a.h+v+y+"px";d&&d()},step:function(){h(this)}})};e.resize=function(b){function d(){a.w=a.w||l.width();a.w=a.mw&&a.mw<a.w?a.mw:a.w;return a.w}function h(){a.h=a.h||l.height();a.h=a.mh&&a.mh<a.h?a.mh:a.h;return a.h}function f(G){e.position(G,function(){if(B){if(x){A&&l.fadeIn(100);k[0].style.removeAttribute("filter")}if(a.iframe)l.append("<iframe id='cboxIframe'"+ (a.scrolling?" ":"scrolling='no'")+" name='iframe_"+(new Date).getTime()+"' frameborder=0 src='"+a.href+"' "+(x?"allowtransparency='true'":"")+" />");l.show();Q.show().html(a.title);if(g.length>1){P.html(a.current.replace(/\{current\}/,j+1).replace(/\{total\}/,g.length)).show();E.html(a.next).show();D.html(a.previous).show();a.slideshow&&t.show()}J.hide();K.hide();c.event.trigger(S);a.onComplete&&a.onComplete.call(i);a.transition==="fade"&&k.fadeTo(L,1,function(){x&&k[0].style.removeAttribute("filter")}); m.bind(T,function(){e.position(0)})}})}if(B){var o,A,L=a.transition==="none"?0:a.speed;m.unbind(T);if(b){l.remove();l=c('<div id="cboxLoadedContent"/>').html(b);l.hide().appendTo(I).css({width:d(),overflow:a.scrolling?"auto":"hidden"}).css({height:h()}).prependTo(p);c("#cboxPhoto").css({cssFloat:"none"});O&&c("select:not(#colorbox select)").filter(function(){return this.style.visibility!=="hidden"}).css({visibility:"hidden"}).one("cbox_cleanup",function(){this.style.visibility="inherit"});a.transition=== "fade"&&k.fadeTo(L,0,function(){f(0)})||f(L);if(a.preloading&&g.length>1){b=j>0?g[j-1]:g[g.length-1];o=j<g.length-1?g[j+1]:g[0];o=c(o).data(q).href||o.href;b=c(b).data(q).href||b.href;M(o)&&c("<img />").attr("src",o);M(b)&&c("<img />").attr("src",b)}}else setTimeout(function(){var G=l.wrapInner("<div style='overflow:auto'></div>").children();a.h=G.height();l.css({height:a.h});G.replaceWith(G.children());e.position(L)},1)}};e.load=function(){var b,d,h,f=e.resize;C=n;i=g[j];a=c(i).data(q);Y();c.event.trigger(H); a.onLoad&&a.onLoad.call(i);a.h=a.height?r(a.height,"y")-v-y:a.innerHeight?r(a.innerHeight,"y"):false;a.w=a.width?r(a.width,"x")-w-z:a.innerWidth?r(a.innerWidth,"x"):false;a.mw=a.w;a.mh=a.h;if(a.maxWidth){a.mw=r(a.maxWidth,"x")-w-z;a.mw=a.w&&a.w<a.mw?a.w:a.mw}if(a.maxHeight){a.mh=r(a.maxHeight,"y")-v-y;a.mh=a.h&&a.h<a.mh?a.h:a.mh}b=a.href;J.show();K.show();if(a.inline){c('<div id="cboxInlineTemp" />').hide().insertBefore(c(b)[0]).bind(H+" cbox_cleanup",function(){c(this).replaceWith(l.children())}); f(c(b))}else if(a.iframe)f(" ");else if(a.html)f(a.html);else if(M(b)){d=new Image;d.onload=function(){var o;d.onload=null;d.id="cboxPhoto";c(d).css({margin:"auto",border:"none",display:"block",cssFloat:"left"});if(a.scalePhotos){h=function(){d.height-=d.height*o;d.width-=d.width*o};if(a.mw&&d.width>a.mw){o=(d.width-a.mw)/d.width;h()}if(a.mh&&d.height>a.mh){o=(d.height-a.mh)/d.height;h()}}if(a.h)d.style.marginTop=Math.max(a.h-d.height,0)/2+"px";f(d);g.length>1&&c(d).css({cursor:"pointer"}).click(e.next); if(x)d.style.msInterpolationMode="bicubic"};d.src=b}else c("<div />").appendTo(I).load(b,function(o,A){A==="success"?f(this):f(c("<p>Request unsuccessful.</p>"))})};e.next=function(){if(!C){j=j<g.length-1?j+1:0;e.load()}};e.prev=function(){if(!C){j=j>0?j-1:g.length-1;e.load()}};e.slideshow=function(){function b(){t.text(a.slideshowStop).bind(S,function(){h=setTimeout(e.next,a.slideshowSpeed)}).bind(H,function(){clearTimeout(h)}).one("click",function(){d();c(this).removeClass(F)});k.removeClass(f+ "off").addClass(f+"on")}var d,h,f="cboxSlideshow_";t.bind("cbox_closed",function(){t.unbind();clearTimeout(h);k.removeClass(f+"off "+f+"on")});d=function(){clearTimeout(h);t.text(a.slideshowStart).unbind(S+" "+H).one("click",function(){b();h=setTimeout(e.next,a.slideshowSpeed);c(this).removeClass(F)});k.removeClass(f+"on").addClass(f+"off")};if(a.slideshow&&g.length>1)a.slideshowAuto?b():d()};e.close=function(){c.event.trigger("cbox_cleanup");a.onCleanup&&a.onCleanup.call(i);B=false;c(document).unbind("keydown.cbox_close keydown.cbox_arrows"); m.unbind(T+" resize.cboxie6 scroll.cboxie6");s.css({cursor:"auto"}).fadeOut("fast");k.stop(n,false).fadeOut("fast",function(){c("#colorbox iframe").attr("src","about:blank");l.remove();k.css({opacity:1});try{N.focus()}catch(b){}c.event.trigger("cbox_closed");a.onClosed&&a.onClosed.call(i)})};e.element=function(){return c(i)};e.settings=$;c(e.init)})(jQuery);