$(function(){$('input[type=text],textarea').each(function(){var $this=$(this);var defaultVal=$this.val();$this.focus(function(){if($this.val()==defaultVal){$this.val("");}
$this.addClass('modified');}).focusout(function(){if($this.val()==""||$this.val()==defaultVal){$this.val(defaultVal);$this.removeClass('modified');}});});$('#colophon').hide();$('#colophon_toggle').toggle(function(){$('#colophon').show();return false;},function(){$('#colophon').hide();return false;});$projector_slides=$('.projector_slide');$projector_thumbs=$('.projector_thumb');$projector_captions=$('.slide_caption');$projector_slides.add($projector_captions).hide();show_slide(1);$projector_thumbs.click(function(){$this=$(this);if($this.hasClass('.active')==false){target=$(this).data('index');show_slide(target);}
return false;});function show_slide(index){$projector_slides.filter('.active').removeClass('active').fadeOut('fast')
$new_img=$('.projector_slide[data-index="'+index+'"]').children('img');$new_img.height=$new_img.attr('height');$new_img.width=$new_img.attr('width');if($new_img.height/4>$new_img.width/5){scaled_width=($new_img.width/$new_img.height)*405;$new_img.css({'height':'405px','width':'auto','position':'absolute','top':'0','left':scaled_width/-2+360});}else{scaled_height=($new_img.height/$new_img.width)*720;$new_img.css({'position':'absolute','width':'720px','height':'auto','top':scaled_height/-2+202.5,'left':'0'});}
$projector_captions.filter('.active').stop().fadeOut('fast');$projector_captions.filter('[data-index="'+index+'"]').addClass('active').stop().fadeIn('fast');$projector_thumbs.filter('.active').removeClass('active');$projector_thumbs.filter('[data-index="'+index+'"]').addClass('active');$('.projector_slide[data-index="'+index+'"]').addClass('active').fadeIn('fast');}
$("a.mailto").each(function(){var $this=$(this);var oldAddress=$this.text();var newAddress=oldAddress.replace(" ","@");$this.after("<a target='_blank' href='mailto:"+newAddress+"'>"+newAddress+"</a>");$this.remove();});$(".tooltip").each(function(){var tooltip=new Tooltip({$el:$(this),project:$(this).data("project-name"),src:$(this).data("photo-src"),});});$(".cb_subsection_slider").each(function(){var $slider=$(this);var $next_el=$(".cbss_next",$slider);var $prev_el=$(".cbss_prev",$slider);var $slides=$(".cbss_slide",$slider);$slides.hide().first().show().addClass('active');$next_el.click(function(){var $next_slide=$('.active',$slider).next('.cbss_slide');if($next_slide.length==0){$next_slide=$slides.first();}
$('.active',$slider).fadeOut().removeClass('active');$next_slide.fadeIn().addClass('active');});$prev_el.click(function(){var $prev_slide=$('.active',$slider).prev('.cbss_slide');if($prev_slide.length==0){$prev_slide=$slides.last();}
$('.active',$slider).fadeOut().removeClass('active');$prev_slide.fadeIn().addClass('active');});});$(".as_slideshow.flex_slideshow").each(function(){this.slideshow=new FlexSlideshow({$slide_container:$(this),$slides:$('.fs_slide',$(this)),timeout:-1,$next_el:$('.fs_next',$(this)),$prev_el:$('.fs_prev',$(this))});});$(".cb_subsection_slider").each(function(){this.slideshow=new FlexSlideshow({$slide_container:$(this),$slides:$('.cbss_slide'),timeout:-1,$next_el:$('.cbss_next',$(this)),$prev_el:$('.cbss_prev',$(this))});});});function FlexSlideshow(options){var slideshow=this;this.current_index=options.initial_index?options.initial_index:0;this.auto_advance=options.auto_advance?options.auto_advance:true;this.timeout=options.timeout?options.timeout:5000;this.animation_duration=options.animation_duration?options.animation_duration:500;this.$slide_container=options.$slide_container;this.$slides=options.$slides;this.$next_el=options.$next_el;this.$prev_el=options.$prev_el;this.max_index=this.$slides.size()-1;if(this.current_index>this.max_index){this.current_index=0;}
this.$slides.slice(this.current_index+1).hide();this.$active_slide=this.$slides.eq(this.current_index);this.$slide_container.max_height=0;this.$slide_container.max_width=0;this.$slides.each(function(){var $slide=$(this)
var this_height=$slide.height();if(this_height>slideshow.$slide_container.max_height){slideshow.$slide_container.max_height=this_height;}});this.$slide_container.css({'height':this.$slide_container.max_height});if(this.$next_el){this.$next_el.click(function(){slideshow.increment();slideshow.goToSlide(slideshow.current_index);});}
if(this.$prev_el){this.$prev_el.click(function(){slideshow.decrement();slideshow.goToSlide(slideshow.current_index);});}
this.setTimeout();}
FlexSlideshow.prototype.goToSlide=function(target_index){this.$active_slide.fadeOut(this.animation_duration);this.$slides.eq(target_index).fadeIn(this.animation_duration);this.$active_slide=this.$slides.eq(target_index);this.setTimeout();};FlexSlideshow.prototype.setTimeout=function(){var slideshow=this;var timeout=this.timeout;if(timeout!==-1){clearTimeout(this.timer);this.timer=setTimeout(function(){slideshow.increment();slideshow.goToSlide(slideshow.current_index);},this.timeout);}};FlexSlideshow.prototype.increment=function(){var slideshow=this;slideshow.current_index++;if(slideshow.current_index>slideshow.max_index){slideshow.current_index=0;}};FlexSlideshow.prototype.decrement=function(){var slideshow=this;slideshow.current_index--;if(slideshow.current_index<0){slideshow.current_index=slideshow.max_index;}};function Tooltip(options){this.$el=options.$el||null;this.project=options.project||null;this.src=options.src||null;if(this.src){this.$bubble=$('<div class="bubble"></div>');this.$image=$('<div class="image"></div>');this.$img=new Image();this.$img.src=this.src;this.$image.append(this.$img);this.$bubble.append(this.$image);this.$bubble.hide();this.$el.append(this.$bubble);var tooltip=this;this.$el.hover(function(){tooltip.$bubble.show().css({bottom:-10,opacity:0}).animate({bottom:10,opacity:1});},function(){tooltip.$bubble.animate({bottom:20,opacity:0});});}
return true;}
$(function(){if($('body').hasClass('refactored')){$('.ss_list_item_link').click(function(ev){$clicked=$(this);$parent=$clicked.parent();target_id=$clicked.data('target');$target=$('.subpage[id="'+target_id+'"]');$parent.siblings('.active').removeClass('active');$parent.addClass('active');$target.siblings('.active').removeClass('active');$target.addClass('active');ev.preventDefault();});}else{$subpages=$('.subpage');$subpage_links=$('.subpage_link');$subpages.not('.active').hide();$subpage_links.click(function(){$this=$(this);if($this.hasClass('active')==false){target=$(this).data('target');show_subpage(target);}
return false;});function show_subpage(target){$subpages.filter('.active').hide();$subpages.filter('[data-title="'+target+'"]').addClass('active').show();$subpage_links.filter('.active').removeClass('active');$subpage_links.filter('[data-target="'+target+'"]').addClass('active');}}});
(function($){$.extend({tablesorter:new function(){var parsers=[],widgets=[];this.defaults={cssHeader:"header",cssAsc:"headerSortUp",cssDesc:"headerSortDown",sortInitialOrder:"asc",sortMultiSortKey:"shiftKey",sortForce:null,sortAppend:null,textExtraction:"simple",parsers:{},widgets:[],widgetZebra:{css:["even","odd"]},headers:{},widthFixed:false,cancelSelection:true,sortList:[],headerList:[],dateFormat:"us",decimal:'.',debug:false};function benchmark(s,d){log(s+","+(new Date().getTime()-d.getTime())+"ms");}this.benchmark=benchmark;function log(s){if(typeof console!="undefined"&&typeof console.debug!="undefined"){console.log(s);}else{alert(s);}}function buildParserCache(table,$headers){if(table.config.debug){var parsersDebug="";}var rows=table.tBodies[0].rows;if(table.tBodies[0].rows[0]){var list=[],cells=rows[0].cells,l=cells.length;for(var i=0;i<l;i++){var p=false;if($.metadata&&($($headers[i]).metadata()&&$($headers[i]).metadata().sorter)){p=getParserById($($headers[i]).metadata().sorter);}else if((table.config.headers[i]&&table.config.headers[i].sorter)){p=getParserById(table.config.headers[i].sorter);}if(!p){p=detectParserForColumn(table,cells[i]);}if(table.config.debug){parsersDebug+="column:"+i+" parser:"+p.id+"\n";}list.push(p);}}if(table.config.debug){log(parsersDebug);}return list;};function detectParserForColumn(table,node){var l=parsers.length;for(var i=1;i<l;i++){if(parsers[i].is($.trim(getElementText(table.config,node)),table,node)){return parsers[i];}}return parsers[0];}function getParserById(name){var l=parsers.length;for(var i=0;i<l;i++){if(parsers[i].id.toLowerCase()==name.toLowerCase()){return parsers[i];}}return false;}function buildCache(table){if(table.config.debug){var cacheTime=new Date();}var totalRows=(table.tBodies[0]&&table.tBodies[0].rows.length)||0,totalCells=(table.tBodies[0].rows[0]&&table.tBodies[0].rows[0].cells.length)||0,parsers=table.config.parsers,cache={row:[],normalized:[]};for(var i=0;i<totalRows;++i){var c=table.tBodies[0].rows[i],cols=[];cache.row.push($(c));for(var j=0;j<totalCells;++j){cols.push(parsers[j].format(getElementText(table.config,c.cells[j]),table,c.cells[j]));}cols.push(i);cache.normalized.push(cols);cols=null;};if(table.config.debug){benchmark("Building cache for "+totalRows+" rows:",cacheTime);}return cache;};function getElementText(config,node){if(!node)return"";var t="";if(config.textExtraction=="simple"){if(node.childNodes[0]&&node.childNodes[0].hasChildNodes()){t=node.childNodes[0].innerHTML;}else{t=node.innerHTML;}}else{if(typeof(config.textExtraction)=="function"){t=config.textExtraction(node);}else{t=$(node).text();}}return t;}function appendToTable(table,cache){if(table.config.debug){var appendTime=new Date()}var c=cache,r=c.row,n=c.normalized,totalRows=n.length,checkCell=(n[0].length-1),tableBody=$(table.tBodies[0]),rows=[];for(var i=0;i<totalRows;i++){rows.push(r[n[i][checkCell]]);if(!table.config.appender){var o=r[n[i][checkCell]];var l=o.length;for(var j=0;j<l;j++){tableBody[0].appendChild(o[j]);}}}if(table.config.appender){table.config.appender(table,rows);}rows=null;if(table.config.debug){benchmark("Rebuilt table:",appendTime);}applyWidget(table);setTimeout(function(){$(table).trigger("sortEnd");},0);};function buildHeaders(table){if(table.config.debug){var time=new Date();}var meta=($.metadata)?true:false,tableHeadersRows=[];for(var i=0;i<table.tHead.rows.length;i++){tableHeadersRows[i]=0;};$tableHeaders=$("thead th",table);$tableHeaders.each(function(index){this.count=0;this.column=index;this.order=formatSortingOrder(table.config.sortInitialOrder);if(checkHeaderMetadata(this)||checkHeaderOptions(table,index))this.sortDisabled=true;if(!this.sortDisabled){$(this).addClass(table.config.cssHeader);}table.config.headerList[index]=this;});if(table.config.debug){benchmark("Built headers:",time);log($tableHeaders);}return $tableHeaders;};function checkCellColSpan(table,rows,row){var arr=[],r=table.tHead.rows,c=r[row].cells;for(var i=0;i<c.length;i++){var cell=c[i];if(cell.colSpan>1){arr=arr.concat(checkCellColSpan(table,headerArr,row++));}else{if(table.tHead.length==1||(cell.rowSpan>1||!r[row+1])){arr.push(cell);}}}return arr;};function checkHeaderMetadata(cell){if(($.metadata)&&($(cell).metadata().sorter===false)){return true;};return false;}function checkHeaderOptions(table,i){if((table.config.headers[i])&&(table.config.headers[i].sorter===false)){return true;};return false;}function applyWidget(table){var c=table.config.widgets;var l=c.length;for(var i=0;i<l;i++){getWidgetById(c[i]).format(table);}}function getWidgetById(name){var l=widgets.length;for(var i=0;i<l;i++){if(widgets[i].id.toLowerCase()==name.toLowerCase()){return widgets[i];}}};function formatSortingOrder(v){if(typeof(v)!="Number"){i=(v.toLowerCase()=="desc")?1:0;}else{i=(v==(0||1))?v:0;}return i;}function isValueInArray(v,a){var l=a.length;for(var i=0;i<l;i++){if(a[i][0]==v){return true;}}return false;}function setHeadersCss(table,$headers,list,css){$headers.removeClass(css[0]).removeClass(css[1]);var h=[];$headers.each(function(offset){if(!this.sortDisabled){h[this.column]=$(this);}});var l=list.length;for(var i=0;i<l;i++){h[list[i][0]].addClass(css[list[i][1]]);}}function fixColumnWidth(table,$headers){var c=table.config;if(c.widthFixed){var colgroup=$('<colgroup>');$("tr:first td",table.tBodies[0]).each(function(){colgroup.append($('<col>').css('width',$(this).width()));});$(table).prepend(colgroup);};}function updateHeaderSortCount(table,sortList){var c=table.config,l=sortList.length;for(var i=0;i<l;i++){var s=sortList[i],o=c.headerList[s[0]];o.count=s[1];o.count++;}}function multisort(table,sortList,cache){if(table.config.debug){var sortTime=new Date();}var dynamicExp="var sortWrapper = function(a,b) {",l=sortList.length;for(var i=0;i<l;i++){var c=sortList[i][0];var order=sortList[i][1];var s=(getCachedSortType(table.config.parsers,c)=="text")?((order==0)?"sortText":"sortTextDesc"):((order==0)?"sortNumeric":"sortNumericDesc");var e="e"+i;dynamicExp+="var "+e+" = "+s+"(a["+c+"],b["+c+"]); ";dynamicExp+="if("+e+") { return "+e+"; } ";dynamicExp+="else { ";}var orgOrderCol=cache.normalized[0].length-1;dynamicExp+="return a["+orgOrderCol+"]-b["+orgOrderCol+"];";for(var i=0;i<l;i++){dynamicExp+="}; ";}dynamicExp+="return 0; ";dynamicExp+="}; ";eval(dynamicExp);cache.normalized.sort(sortWrapper);if(table.config.debug){benchmark("Sorting on "+sortList.toString()+" and dir "+order+" time:",sortTime);}return cache;};function sortText(a,b){return((a<b)?-1:((a>b)?1:0));};function sortTextDesc(a,b){return((b<a)?-1:((b>a)?1:0));};function sortNumeric(a,b){return a-b;};function sortNumericDesc(a,b){return b-a;};function getCachedSortType(parsers,i){return parsers[i].type;};this.construct=function(settings){return this.each(function(){if(!this.tHead||!this.tBodies)return;var $this,$document,$headers,cache,config,shiftDown=0,sortOrder;this.config={};config=$.extend(this.config,$.tablesorter.defaults,settings);$this=$(this);$headers=buildHeaders(this);this.config.parsers=buildParserCache(this,$headers);cache=buildCache(this);var sortCSS=[config.cssDesc,config.cssAsc];fixColumnWidth(this);$headers.click(function(e){$this.trigger("sortStart");var totalRows=($this[0].tBodies[0]&&$this[0].tBodies[0].rows.length)||0;if(!this.sortDisabled&&totalRows>0){var $cell=$(this);var i=this.column;this.order=this.count++%2;if(!e[config.sortMultiSortKey]){config.sortList=[];if(config.sortForce!=null){var a=config.sortForce;for(var j=0;j<a.length;j++){if(a[j][0]!=i){config.sortList.push(a[j]);}}}config.sortList.push([i,this.order]);}else{if(isValueInArray(i,config.sortList)){for(var j=0;j<config.sortList.length;j++){var s=config.sortList[j],o=config.headerList[s[0]];if(s[0]==i){o.count=s[1];o.count++;s[1]=o.count%2;}}}else{config.sortList.push([i,this.order]);}};setTimeout(function(){setHeadersCss($this[0],$headers,config.sortList,sortCSS);appendToTable($this[0],multisort($this[0],config.sortList,cache));},1);return false;}}).mousedown(function(){if(config.cancelSelection){this.onselectstart=function(){return false};return false;}});$this.bind("update",function(){this.config.parsers=buildParserCache(this,$headers);cache=buildCache(this);}).bind("sorton",function(e,list){$(this).trigger("sortStart");config.sortList=list;var sortList=config.sortList;updateHeaderSortCount(this,sortList);setHeadersCss(this,$headers,sortList,sortCSS);appendToTable(this,multisort(this,sortList,cache));}).bind("appendCache",function(){appendToTable(this,cache);}).bind("applyWidgetId",function(e,id){getWidgetById(id).format(this);}).bind("applyWidgets",function(){applyWidget(this);});if($.metadata&&($(this).metadata()&&$(this).metadata().sortlist)){config.sortList=$(this).metadata().sortlist;}if(config.sortList.length>0){$this.trigger("sorton",[config.sortList]);}applyWidget(this);});};this.addParser=function(parser){var l=parsers.length,a=true;for(var i=0;i<l;i++){if(parsers[i].id.toLowerCase()==parser.id.toLowerCase()){a=false;}}if(a){parsers.push(parser);};};this.addWidget=function(widget){widgets.push(widget);};this.formatFloat=function(s){var i=parseFloat(s);return(isNaN(i))?0:i;};this.formatInt=function(s){var i=parseInt(s);return(isNaN(i))?0:i;};this.isDigit=function(s,config){var DECIMAL='\\'+config.decimal;var exp='/(^[+]?0('+DECIMAL+'0+)?$)|(^([-+]?[1-9][0-9]*)$)|(^([-+]?((0?|[1-9][0-9]*)'+DECIMAL+'(0*[1-9][0-9]*)))$)|(^[-+]?[1-9]+[0-9]*'+DECIMAL+'0+$)/';return RegExp(exp).test($.trim(s));};this.clearTableBody=function(table){if($.browser.msie){function empty(){while(this.firstChild)this.removeChild(this.firstChild);}empty.apply(table.tBodies[0]);}else{table.tBodies[0].innerHTML="";}};}});$.fn.extend({tablesorter:$.tablesorter.construct});var ts=$.tablesorter;ts.addParser({id:"text",is:function(s){return true;},format:function(s){return $.trim(s.toLowerCase());},type:"text"});ts.addParser({id:"digit",is:function(s,table){var c=table.config;return $.tablesorter.isDigit(s,c);},format:function(s){return $.tablesorter.formatFloat(s);},type:"numeric"});ts.addParser({id:"currency",is:function(s){return/^[£$Û?.]/.test(s);},format:function(s){return $.tablesorter.formatFloat(s.replace(new RegExp(/[^0-9.]/g),""));},type:"numeric"});ts.addParser({id:"ipAddress",is:function(s){return/^\d{2,3}[\.]\d{2,3}[\.]\d{2,3}[\.]\d{2,3}$/.test(s);},format:function(s){var a=s.split("."),r="",l=a.length;for(var i=0;i<l;i++){var item=a[i];if(item.length==2){r+="0"+item;}else{r+=item;}}return $.tablesorter.formatFloat(r);},type:"numeric"});ts.addParser({id:"url",is:function(s){return/^(https?|ftp|file):\/\/$/.test(s);},format:function(s){return jQuery.trim(s.replace(new RegExp(/(https?|ftp|file):\/\//),''));},type:"text"});ts.addParser({id:"isoDate",is:function(s){return/^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(s);},format:function(s){return $.tablesorter.formatFloat((s!="")?new Date(s.replace(new RegExp(/-/g),"/")).getTime():"0");},type:"numeric"});ts.addParser({id:"percent",is:function(s){return/\%$/.test($.trim(s));},format:function(s){return $.tablesorter.formatFloat(s.replace(new RegExp(/%/g),""));},type:"numeric"});ts.addParser({id:"usLongDate",is:function(s){return s.match(new RegExp(/^[A-Za-z]{3,10}\.? [0-9]{1,2}, ([0-9]{4}|'?[0-9]{2}) (([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(AM|PM)))$/));},format:function(s){return $.tablesorter.formatFloat(new Date(s).getTime());},type:"numeric"});ts.addParser({id:"shortDate",is:function(s){return/\d{1,2}[\/\-]\d{1,2}[\/\-]\d{2,4}/.test(s);},format:function(s,table){var c=table.config;s=s.replace(/\-/g,"/");if(c.dateFormat=="us"){s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$1/$2");}else if(c.dateFormat=="uk"){s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{4})/,"$3/$2/$1");}else if(c.dateFormat=="dd/mm/yy"||c.dateFormat=="dd-mm-yy"){s=s.replace(/(\d{1,2})[\/\-](\d{1,2})[\/\-](\d{2})/,"$1/$2/$3");}return $.tablesorter.formatFloat(new Date(s).getTime());},type:"numeric"});ts.addParser({id:"time",is:function(s){return/^(([0-2]?[0-9]:[0-5][0-9])|([0-1]?[0-9]:[0-5][0-9]\s(am|pm)))$/.test(s);},format:function(s){return $.tablesorter.formatFloat(new Date("2000/01/01 "+s).getTime());},type:"numeric"});ts.addParser({id:"metadata",is:function(s){return false;},format:function(s,table,cell){var c=table.config,p=(!c.parserMetadataName)?'sortValue':c.parserMetadataName;return $(cell).metadata()[p];},type:"numeric"});ts.addWidget({id:"zebra",format:function(table){if(table.config.debug){var time=new Date();}$("tr:visible",table.tBodies[0]).filter(':even').removeClass(table.config.widgetZebra.css[1]).addClass(table.config.widgetZebra.css[0]).end().filter(':odd').removeClass(table.config.widgetZebra.css[0]).addClass(table.config.widgetZebra.css[1]);if(table.config.debug){$.tablesorter.benchmark("Applying Zebra widget",time);}}});})(jQuery);$(function(){$('.resource_list .module_body').hide();$('.resource_list .module_header').toggle(function(){$(this).addClass('active').siblings('.module_body').addClass('active').slideDown(100);},function(){$(this).removeClass('active').siblings('.module_body').removeClass('active').slideUp(100);});});
$(function(){$('.fixed_sidebar').each(function(){$(this).scrollWithin($('#content'),20);});});$.fn.scrollWithin=function($container,offset){var $this=$(this);var width=$this.width();$this.width(width);$this.after("<div>&nbsp;</div>").width(width);$container.css({position:'relative'});var this_offset=$this.offset();var top=this_offset.top;setPos($this,$container,offset,top);$(window).scroll(function(){setPos($this,$container,offset,top);});}
function setPos($this,$container,offset,top){var scroll_top=$(window).scrollTop();var bottom=$container.innerHeight()+top-$this.outerHeight(true)-offset;if(scroll_top>bottom){$this.css({position:'absolute',top:'auto',bottom:0});}else if(scroll_top>(top-offset)){$this.css({position:'fixed',top:offset,bottom:'auto'});}else{$this.css({position:'static'});}}
$(function(){$('.link_list_horizontal').each(function(){var max=0;$('.llh_item').each(function(){current=$(this).height();if(current>max){max=current;}}).css({'height':max}).last();});});
function company_load_gmaps(){var script=document.createElement("script");script.src="http://maps.google.com/maps/api/js?sensor=false&callback=company_draw_map";document.body.appendChild(script);}
function company_draw_map(){handilift=new google.maps.LatLng(40.847428,-74.095892);map=new google.maps.Map(document.getElementById("company_map"),{zoom:10,center:handilift,mapTypeId:google.maps.MapTypeId.ROADMAP,scrollwheel:false});info_window=new google.maps.InfoWindow({content:'<strong>Handi-Lift Headquarters & Warehouse</strong><br/><p>730 Garden Street<br />Carlstadt, NJ 07072</p>',maxWidth:225});marker=new google.maps.Marker({position:handilift,map:map,title:'Handi-Lift Headquarters &amp; Warehouse'});google.maps.event.addListener(marker,'click',function(){info_window.open(map,marker);});}
$(window).load(function(){$('#company_map').css('background','url("http://handi-lift.s3.amazonaws.com/handi_resources/company_map.jpg")').bind('click.activate',function(){$(this).css('background','none').unbind('.activate');company_load_gmaps();});});;(function($){$.fn.ajaxSubmit=function(options){if(!this.length){log('ajaxSubmit: skipping submit process - no element selected');return this;}
if(typeof options=='function'){options={success:options};}
var action=this.attr('action');var url=(typeof action==='string')?$.trim(action):'';if(url){url=(url.match(/^([^#]+)/)||[])[1];}
url=url||window.location.href||'';options=$.extend(true,{url:url,type:this.attr('method')||'GET',iframeSrc:/^https/i.test(window.location.href||'')?'javascript:false':'about:blank'},options);var veto={};this.trigger('form-pre-serialize',[this,options,veto]);if(veto.veto){log('ajaxSubmit: submit vetoed via form-pre-serialize trigger');return this;}
if(options.beforeSerialize&&options.beforeSerialize(this,options)===false){log('ajaxSubmit: submit aborted via beforeSerialize callback');return this;}
var n,v,a=this.formToArray(options.semantic);if(options.data){options.extraData=options.data;for(n in options.data){if(options.data[n]instanceof Array){for(var k in options.data[n]){a.push({name:n,value:options.data[n][k]});}}
else{v=options.data[n];v=$.isFunction(v)?v():v;a.push({name:n,value:v});}}}
if(options.beforeSubmit&&options.beforeSubmit(a,this,options)===false){log('ajaxSubmit: submit aborted via beforeSubmit callback');return this;}
this.trigger('form-submit-validate',[a,this,options,veto]);if(veto.veto){log('ajaxSubmit: submit vetoed via form-submit-validate trigger');return this;}
var q=$.param(a);if(options.type.toUpperCase()=='GET'){options.url+=(options.url.indexOf('?')>=0?'&':'?')+q;options.data=null;}
else{options.data=q;}
var $form=this,callbacks=[];if(options.resetForm){callbacks.push(function(){$form.resetForm();});}
if(options.clearForm){callbacks.push(function(){$form.clearForm();});}
if(!options.dataType&&options.target){var oldSuccess=options.success||function(){};callbacks.push(function(data){var fn=options.replaceTarget?'replaceWith':'html';$(options.target)[fn](data).each(oldSuccess,arguments);});}
else if(options.success){callbacks.push(options.success);}
options.success=function(data,status,xhr){var context=options.context||options;for(var i=0,max=callbacks.length;i<max;i++){callbacks[i].apply(context,[data,status,xhr||$form,$form]);}};var fileInputs=$('input:file',this).length>0;var mp='multipart/form-data';var multipart=($form.attr('enctype')==mp||$form.attr('encoding')==mp);if(options.iframe!==false&&(fileInputs||options.iframe||multipart)){if(options.closeKeepAlive){$.get(options.closeKeepAlive,fileUpload);}
else{fileUpload();}}
else{$.ajax(options);}
this.trigger('form-submit-notify',[this,options]);return this;function fileUpload(){var form=$form[0];if($(':input[name=submit],:input[id=submit]',form).length){alert('Error: Form elements must not have name or id of "submit".');return;}
var s=$.extend(true,{},$.ajaxSettings,options);s.context=s.context||s;var id='jqFormIO'+(new Date().getTime()),fn='_'+id;window[fn]=function(){var f=$io.data('form-plugin-onload');if(f){f();window[fn]=undefined;try{delete window[fn];}catch(e){}}}
var $io=$('<iframe id="'+id+'" name="'+id+'" src="'+s.iframeSrc+'" onload="window[\'_\'+this.id]()" />');var io=$io[0];$io.css({position:'absolute',top:'-1000px',left:'-1000px'});var xhr={aborted:0,responseText:null,responseXML:null,status:0,statusText:'n/a',getAllResponseHeaders:function(){},getResponseHeader:function(){},setRequestHeader:function(){},abort:function(){this.aborted=1;$io.attr('src',s.iframeSrc);}};var g=s.global;if(g&&!$.active++){$.event.trigger("ajaxStart");}
if(g){$.event.trigger("ajaxSend",[xhr,s]);}
if(s.beforeSend&&s.beforeSend.call(s.context,xhr,s)===false){if(s.global){$.active--;}
return;}
if(xhr.aborted){return;}
var cbInvoked=false;var timedOut=0;var sub=form.clk;if(sub){var n=sub.name;if(n&&!sub.disabled){s.extraData=s.extraData||{};s.extraData[n]=sub.value;if(sub.type=="image"){s.extraData[n+'.x']=form.clk_x;s.extraData[n+'.y']=form.clk_y;}}}
function doSubmit(){var t=$form.attr('target'),a=$form.attr('action');form.setAttribute('target',id);if(form.getAttribute('method')!='POST'){form.setAttribute('method','POST');}
if(form.getAttribute('action')!=s.url){form.setAttribute('action',s.url);}
if(!s.skipEncodingOverride){$form.attr({encoding:'multipart/form-data',enctype:'multipart/form-data'});}
if(s.timeout){setTimeout(function(){timedOut=true;cb();},s.timeout);}
var extraInputs=[];try{if(s.extraData){for(var n in s.extraData){extraInputs.push($('<input type="hidden" name="'+n+'" value="'+s.extraData[n]+'" />').appendTo(form)[0]);}}
$io.appendTo('body');$io.data('form-plugin-onload',cb);form.submit();}
finally{form.setAttribute('action',a);if(t){form.setAttribute('target',t);}else{$form.removeAttr('target');}
$(extraInputs).remove();}}
if(s.forceSync){doSubmit();}
else{setTimeout(doSubmit,10);}
var data,doc,domCheckCount=50;function cb(){if(cbInvoked){return;}
$io.removeData('form-plugin-onload');var ok=true;try{if(timedOut){throw'timeout';}
doc=io.contentWindow?io.contentWindow.document:io.contentDocument?io.contentDocument:io.document;var isXml=s.dataType=='xml'||doc.XMLDocument||$.isXMLDoc(doc);log('isXml='+isXml);if(!isXml&&window.opera&&(doc.body==null||doc.body.innerHTML=='')){if(--domCheckCount){log('requeing onLoad callback, DOM not available');setTimeout(cb,250);return;}}
cbInvoked=true;xhr.responseText=doc.documentElement?doc.documentElement.innerHTML:null;xhr.responseXML=doc.XMLDocument?doc.XMLDocument:doc;xhr.getResponseHeader=function(header){var headers={'content-type':s.dataType};return headers[header];};var scr=/(json|script)/.test(s.dataType);if(scr||s.textarea){var ta=doc.getElementsByTagName('textarea')[0];if(ta){xhr.responseText=ta.value;}
else if(scr){var pre=doc.getElementsByTagName('pre')[0];var b=doc.getElementsByTagName('body')[0];if(pre){xhr.responseText=pre.textContent;}
else if(b){xhr.responseText=b.innerHTML;}}}
else if(s.dataType=='xml'&&!xhr.responseXML&&xhr.responseText!=null){xhr.responseXML=toXml(xhr.responseText);}
data=$.httpData(xhr,s.dataType);}
catch(e){log('error caught:',e);ok=false;xhr.error=e;$.handleError(s,xhr,'error',e);}
if(xhr.aborted){log('upload aborted');ok=false;}
if(ok){s.success.call(s.context,data,'success',xhr);if(g){$.event.trigger("ajaxSuccess",[xhr,s]);}}
if(g){$.event.trigger("ajaxComplete",[xhr,s]);}
if(g&&!--$.active){$.event.trigger("ajaxStop");}
if(s.complete){s.complete.call(s.context,xhr,ok?'success':'error');}
setTimeout(function(){$io.removeData('form-plugin-onload');$io.remove();xhr.responseXML=null;},100);}
function toXml(s,doc){if(window.ActiveXObject){doc=new ActiveXObject('Microsoft.XMLDOM');doc.async='false';doc.loadXML(s);}
else{doc=(new DOMParser()).parseFromString(s,'text/xml');}
return(doc&&doc.documentElement&&doc.documentElement.tagName!='parsererror')?doc:null;}}};$.fn.ajaxForm=function(options){if(this.length===0){var o={s:this.selector,c:this.context};if(!$.isReady&&o.s){log('DOM not ready, queuing ajaxForm');$(function(){$(o.s,o.c).ajaxForm(options);});return this;}
log('terminating; zero elements found by selector'+($.isReady?'':' (DOM not ready)'));return this;}
return this.ajaxFormUnbind().bind('submit.form-plugin',function(e){if(!e.isDefaultPrevented()){e.preventDefault();$(this).ajaxSubmit(options);}}).bind('click.form-plugin',function(e){var target=e.target;var $el=$(target);if(!($el.is(":submit,input:image"))){var t=$el.closest(':submit');if(t.length==0){return;}
target=t[0];}
var form=this;form.clk=target;if(target.type=='image'){if(e.offsetX!=undefined){form.clk_x=e.offsetX;form.clk_y=e.offsetY;}else if(typeof $.fn.offset=='function'){var offset=$el.offset();form.clk_x=e.pageX-offset.left;form.clk_y=e.pageY-offset.top;}else{form.clk_x=e.pageX-target.offsetLeft;form.clk_y=e.pageY-target.offsetTop;}}
setTimeout(function(){form.clk=form.clk_x=form.clk_y=null;},100);});};$.fn.ajaxFormUnbind=function(){return this.unbind('submit.form-plugin click.form-plugin');};$.fn.formToArray=function(semantic){var a=[];if(this.length===0){return a;}
var form=this[0];var els=semantic?form.getElementsByTagName('*'):form.elements;if(!els){return a;}
var i,j,n,v,el,max,jmax;for(i=0,max=els.length;i<max;i++){el=els[i];n=el.name;if(!n){continue;}
if(semantic&&form.clk&&el.type=="image"){if(!el.disabled&&form.clk==el){a.push({name:n,value:$(el).val()});a.push({name:n+'.x',value:form.clk_x},{name:n+'.y',value:form.clk_y});}
continue;}
v=$.fieldValue(el,true);if(v&&v.constructor==Array){for(j=0,jmax=v.length;j<jmax;j++){a.push({name:n,value:v[j]});}}
else if(v!==null&&typeof v!='undefined'){a.push({name:n,value:v});}}
if(!semantic&&form.clk){var $input=$(form.clk),input=$input[0];n=input.name;if(n&&!input.disabled&&input.type=='image'){a.push({name:n,value:$input.val()});a.push({name:n+'.x',value:form.clk_x},{name:n+'.y',value:form.clk_y});}}
return a;};$.fn.formSerialize=function(semantic){return $.param(this.formToArray(semantic));};$.fn.fieldSerialize=function(successful){var a=[];this.each(function(){var n=this.name;if(!n){return;}
var v=$.fieldValue(this,successful);if(v&&v.constructor==Array){for(var i=0,max=v.length;i<max;i++){a.push({name:n,value:v[i]});}}
else if(v!==null&&typeof v!='undefined'){a.push({name:this.name,value:v});}});return $.param(a);};$.fn.fieldValue=function(successful){for(var val=[],i=0,max=this.length;i<max;i++){var el=this[i];var v=$.fieldValue(el,successful);if(v===null||typeof v=='undefined'||(v.constructor==Array&&!v.length)){continue;}
v.constructor==Array?$.merge(val,v):val.push(v);}
return val;};$.fieldValue=function(el,successful){var n=el.name,t=el.type,tag=el.tagName.toLowerCase();if(successful===undefined){successful=true;}
if(successful&&(!n||el.disabled||t=='reset'||t=='button'||(t=='checkbox'||t=='radio')&&!el.checked||(t=='submit'||t=='image')&&el.form&&el.form.clk!=el||tag=='select'&&el.selectedIndex==-1)){return null;}
if(tag=='select'){var index=el.selectedIndex;if(index<0){return null;}
var a=[],ops=el.options;var one=(t=='select-one');var max=(one?index+1:ops.length);for(var i=(one?index:0);i<max;i++){var op=ops[i];if(op.selected){var v=op.value;if(!v){v=(op.attributes&&op.attributes['value']&&!(op.attributes['value'].specified))?op.text:op.value;}
if(one){return v;}
a.push(v);}}
return a;}
return $(el).val();};$.fn.clearForm=function(){return this.each(function(){$('input,select,textarea',this).clearFields();});};$.fn.clearFields=$.fn.clearInputs=function(){return this.each(function(){var t=this.type,tag=this.tagName.toLowerCase();if(t=='text'||t=='password'||tag=='textarea'){this.value='';}
else if(t=='checkbox'||t=='radio'){this.checked=false;}
else if(tag=='select'){this.selectedIndex=-1;}});};$.fn.resetForm=function(){return this.each(function(){if(typeof this.reset=='function'||(typeof this.reset=='object'&&!this.reset.nodeType)){this.reset();}});};$.fn.enable=function(b){if(b===undefined){b=true;}
return this.each(function(){this.disabled=!b;});};$.fn.selected=function(select){if(select===undefined){select=true;}
return this.each(function(){var t=this.type;if(t=='checkbox'||t=='radio'){this.checked=select;}
else if(this.tagName.toLowerCase()=='option'){var $sel=$(this).parent('select');if(select&&$sel[0]&&$sel[0].type=='select-one'){$sel.find('option').selected(false);}
this.selected=select;}});};function log(){if($.fn.ajaxSubmit.debug){var msg='[jquery.form] '+Array.prototype.join.call(arguments,'');if(window.console&&window.console.log){window.console.log(msg);}
else if(window.opera&&window.opera.postError){window.opera.postError(msg);}}};})(jQuery);(function($){$.extend($.fn,{validate:function(options){if(!this.length){options&&options.debug&&window.console&&console.warn("nothing selected, can't validate, returning nothing");return;}var validator=$.data(this[0],'validator');if(validator){return validator;}validator=new $.validator(options,this[0]);$.data(this[0],'validator',validator);if(validator.settings.onsubmit){this.find("input, button").filter(".cancel").click(function(){validator.cancelSubmit=true;});if(validator.settings.submitHandler){this.find("input, button").filter(":submit").click(function(){validator.submitButton=this;});}this.submit(function(event){if(validator.settings.debug)event.preventDefault();function handle(){if(validator.settings.submitHandler){if(validator.submitButton){var hidden=$("<input type='hidden'/>").attr("name",validator.submitButton.name).val(validator.submitButton.value).appendTo(validator.currentForm);}validator.settings.submitHandler.call(validator,validator.currentForm);if(validator.submitButton){hidden.remove();}return false;}return true;}if(validator.cancelSubmit){validator.cancelSubmit=false;return handle();}if(validator.form()){if(validator.pendingRequest){validator.formSubmitted=true;return false;}return handle();}else{validator.focusInvalid();return false;}});}return validator;},valid:function(){if($(this[0]).is('form')){return this.validate().form();}else{var valid=true;var validator=$(this[0].form).validate();this.each(function(){valid&=validator.element(this);});return valid;}},removeAttrs:function(attributes){var result={},$element=this;$.each(attributes.split(/\s/),function(index,value){result[value]=$element.attr(value);$element.removeAttr(value);});return result;},rules:function(command,argument){var element=this[0];if(command){var settings=$.data(element.form,'validator').settings;var staticRules=settings.rules;var existingRules=$.validator.staticRules(element);switch(command){case"add":$.extend(existingRules,$.validator.normalizeRule(argument));staticRules[element.name]=existingRules;if(argument.messages)settings.messages[element.name]=$.extend(settings.messages[element.name],argument.messages);break;case"remove":if(!argument){delete staticRules[element.name];return existingRules;}var filtered={};$.each(argument.split(/\s/),function(index,method){filtered[method]=existingRules[method];delete existingRules[method];});return filtered;}}var data=$.validator.normalizeRules($.extend({},$.validator.metadataRules(element),$.validator.classRules(element),$.validator.attributeRules(element),$.validator.staticRules(element)),element);if(data.required){var param=data.required;delete data.required;data=$.extend({required:param},data);}return data;}});$.extend($.expr[":"],{blank:function(a){return!$.trim(""+a.value);},filled:function(a){return!!$.trim(""+a.value);},unchecked:function(a){return!a.checked;}});$.validator=function(options,form){this.settings=$.extend(true,{},$.validator.defaults,options);this.currentForm=form;this.init();};$.validator.format=function(source,params){if(arguments.length==1)return function(){var args=$.makeArray(arguments);args.unshift(source);return $.validator.format.apply(this,args);};if(arguments.length>2&&params.constructor!=Array){params=$.makeArray(arguments).slice(1);}if(params.constructor!=Array){params=[params];}$.each(params,function(i,n){source=source.replace(new RegExp("\\{"+i+"\\}","g"),n);});return source;};$.extend($.validator,{defaults:{messages:{},groups:{},rules:{},errorClass:"error",validClass:"valid",errorElement:"label",focusInvalid:true,errorContainer:$([]),errorLabelContainer:$([]),onsubmit:true,ignore:[],ignoreTitle:false,onfocusin:function(element){this.lastActive=element;if(this.settings.focusCleanup&&!this.blockFocusCleanup){this.settings.unhighlight&&this.settings.unhighlight.call(this,element,this.settings.errorClass,this.settings.validClass);this.errorsFor(element).hide();}},onfocusout:function(element){if(!this.checkable(element)&&(element.name in this.submitted||!this.optional(element))){this.element(element);}},onkeyup:function(element){if(element.name in this.submitted||element==this.lastElement){this.element(element);}},onclick:function(element){if(element.name in this.submitted)this.element(element);else if(element.parentNode.name in this.submitted)this.element(element.parentNode);},highlight:function(element,errorClass,validClass){$(element).addClass(errorClass).removeClass(validClass);},unhighlight:function(element,errorClass,validClass){$(element).removeClass(errorClass).addClass(validClass);}},setDefaults:function(settings){$.extend($.validator.defaults,settings);},messages:{required:"This field is required.",remote:"Please fix this field.",email:"Please enter a valid email address.",url:"Please enter a valid URL.",date:"Please enter a valid date.",dateISO:"Please enter a valid date (ISO).",number:"Please enter a valid number.",digits:"Please enter only digits.",creditcard:"Please enter a valid credit card number.",equalTo:"Please enter the same value again.",accept:"Please enter a value with a valid extension.",maxlength:$.validator.format("Please enter no more than {0} characters."),minlength:$.validator.format("Please enter at least {0} characters."),rangelength:$.validator.format("Please enter a value between {0} and {1} characters long."),range:$.validator.format("Please enter a value between {0} and {1}."),max:$.validator.format("Please enter a value less than or equal to {0}."),min:$.validator.format("Please enter a value greater than or equal to {0}.")},autoCreateRanges:false,prototype:{init:function(){this.labelContainer=$(this.settings.errorLabelContainer);this.errorContext=this.labelContainer.length&&this.labelContainer||$(this.currentForm);this.containers=$(this.settings.errorContainer).add(this.settings.errorLabelContainer);this.submitted={};this.valueCache={};this.pendingRequest=0;this.pending={};this.invalid={};this.reset();var groups=(this.groups={});$.each(this.settings.groups,function(key,value){$.each(value.split(/\s/),function(index,name){groups[name]=key;});});var rules=this.settings.rules;$.each(rules,function(key,value){rules[key]=$.validator.normalizeRule(value);});function delegate(event){var validator=$.data(this[0].form,"validator"),eventType="on"+event.type.replace(/^validate/,"");validator.settings[eventType]&&validator.settings[eventType].call(validator,this[0]);}$(this.currentForm).validateDelegate(":text, :password, :file, select, textarea","focusin focusout keyup",delegate).validateDelegate(":radio, :checkbox, select, option","click",delegate);if(this.settings.invalidHandler)$(this.currentForm).bind("invalid-form.validate",this.settings.invalidHandler);},form:function(){this.checkForm();$.extend(this.submitted,this.errorMap);this.invalid=$.extend({},this.errorMap);if(!this.valid())$(this.currentForm).triggerHandler("invalid-form",[this]);this.showErrors();return this.valid();},checkForm:function(){this.prepareForm();for(var i=0,elements=(this.currentElements=this.elements());elements[i];i++){this.check(elements[i]);}return this.valid();},element:function(element){element=this.clean(element);this.lastElement=element;this.prepareElement(element);this.currentElements=$(element);var result=this.check(element);if(result){delete this.invalid[element.name];}else{this.invalid[element.name]=true;}if(!this.numberOfInvalids()){this.toHide=this.toHide.add(this.containers);}this.showErrors();return result;},showErrors:function(errors){if(errors){$.extend(this.errorMap,errors);this.errorList=[];for(var name in errors){this.errorList.push({message:errors[name],element:this.findByName(name)[0]});}this.successList=$.grep(this.successList,function(element){return!(element.name in errors);});}this.settings.showErrors?this.settings.showErrors.call(this,this.errorMap,this.errorList):this.defaultShowErrors();},resetForm:function(){if($.fn.resetForm)$(this.currentForm).resetForm();this.submitted={};this.prepareForm();this.hideErrors();this.elements().removeClass(this.settings.errorClass);},numberOfInvalids:function(){return this.objectLength(this.invalid);},objectLength:function(obj){var count=0;for(var i in obj)count++;return count;},hideErrors:function(){this.addWrapper(this.toHide).hide();},valid:function(){return this.size()==0;},size:function(){return this.errorList.length;},focusInvalid:function(){if(this.settings.focusInvalid){try{$(this.findLastActive()||this.errorList.length&&this.errorList[0].element||[]).filter(":visible").focus().trigger("focusin");}catch(e){}}},findLastActive:function(){var lastActive=this.lastActive;return lastActive&&$.grep(this.errorList,function(n){return n.element.name==lastActive.name;}).length==1&&lastActive;},elements:function(){var validator=this,rulesCache={};return $([]).add(this.currentForm.elements).filter(":input").not(":submit, :reset, :image, [disabled]").not(this.settings.ignore).filter(function(){!this.name&&validator.settings.debug&&window.console&&console.error("%o has no name assigned",this);if(this.name in rulesCache||!validator.objectLength($(this).rules()))return false;rulesCache[this.name]=true;return true;});},clean:function(selector){return $(selector)[0];},errors:function(){return $(this.settings.errorElement+"."+this.settings.errorClass,this.errorContext);},reset:function(){this.successList=[];this.errorList=[];this.errorMap={};this.toShow=$([]);this.toHide=$([]);this.currentElements=$([]);},prepareForm:function(){this.reset();this.toHide=this.errors().add(this.containers);},prepareElement:function(element){this.reset();this.toHide=this.errorsFor(element);},check:function(element){element=this.clean(element);if(this.checkable(element)){element=this.findByName(element.name)[0];}var rules=$(element).rules();var dependencyMismatch=false;for(method in rules){var rule={method:method,parameters:rules[method]};try{var result=$.validator.methods[method].call(this,element.value.replace(/\r/g,""),element,rule.parameters);if(result=="dependency-mismatch"){dependencyMismatch=true;continue;}dependencyMismatch=false;if(result=="pending"){this.toHide=this.toHide.not(this.errorsFor(element));return;}if(!result){this.formatAndAdd(element,rule);return false;}}catch(e){this.settings.debug&&window.console&&console.log("exception occured when checking element "+element.id
+", check the '"+rule.method+"' method",e);throw e;}}if(dependencyMismatch)return;if(this.objectLength(rules))this.successList.push(element);return true;},customMetaMessage:function(element,method){if(!$.metadata)return;var meta=this.settings.meta?$(element).metadata()[this.settings.meta]:$(element).metadata();return meta&&meta.messages&&meta.messages[method];},customMessage:function(name,method){var m=this.settings.messages[name];return m&&(m.constructor==String?m:m[method]);},findDefined:function(){for(var i=0;i<arguments.length;i++){if(arguments[i]!==undefined)return arguments[i];}return undefined;},defaultMessage:function(element,method){return this.findDefined(this.customMessage(element.name,method),this.customMetaMessage(element,method),!this.settings.ignoreTitle&&element.title||undefined,$.validator.messages[method],"<strong>Warning: No message defined for "+element.name+"</strong>");},formatAndAdd:function(element,rule){var message=this.defaultMessage(element,rule.method),theregex=/\$?\{(\d+)\}/g;if(typeof message=="function"){message=message.call(this,rule.parameters,element);}else if(theregex.test(message)){message=jQuery.format(message.replace(theregex,'{$1}'),rule.parameters);}this.errorList.push({message:message,element:element});this.errorMap[element.name]=message;this.submitted[element.name]=message;},addWrapper:function(toToggle){if(this.settings.wrapper)toToggle=toToggle.add(toToggle.parent(this.settings.wrapper));return toToggle;},defaultShowErrors:function(){for(var i=0;this.errorList[i];i++){var error=this.errorList[i];this.settings.highlight&&this.settings.highlight.call(this,error.element,this.settings.errorClass,this.settings.validClass);this.showLabel(error.element,error.message);}if(this.errorList.length){this.toShow=this.toShow.add(this.containers);}if(this.settings.success){for(var i=0;this.successList[i];i++){this.showLabel(this.successList[i]);}}if(this.settings.unhighlight){for(var i=0,elements=this.validElements();elements[i];i++){this.settings.unhighlight.call(this,elements[i],this.settings.errorClass,this.settings.validClass);}}this.toHide=this.toHide.not(this.toShow);this.hideErrors();this.addWrapper(this.toShow).show();},validElements:function(){return this.currentElements.not(this.invalidElements());},invalidElements:function(){return $(this.errorList).map(function(){return this.element;});},showLabel:function(element,message){var label=this.errorsFor(element);if(label.length){label.removeClass().addClass(this.settings.errorClass);label.attr("generated")&&label.html(message);}else{label=$("<"+this.settings.errorElement+"/>").attr({"for":this.idOrName(element),generated:true}).addClass(this.settings.errorClass).html(message||"");if(this.settings.wrapper){label=label.hide().show().wrap("<"+this.settings.wrapper+"/>").parent();}if(!this.labelContainer.append(label).length)this.settings.errorPlacement?this.settings.errorPlacement(label,$(element)):label.insertAfter(element);}if(!message&&this.settings.success){label.text("");typeof this.settings.success=="string"?label.addClass(this.settings.success):this.settings.success(label);}this.toShow=this.toShow.add(label);},errorsFor:function(element){var name=this.idOrName(element);return this.errors().filter(function(){return $(this).attr('for')==name;});},idOrName:function(element){return this.groups[element.name]||(this.checkable(element)?element.name:element.id||element.name);},checkable:function(element){return/radio|checkbox/i.test(element.type);},findByName:function(name){var form=this.currentForm;return $(document.getElementsByName(name)).map(function(index,element){return element.form==form&&element.name==name&&element||null;});},getLength:function(value,element){switch(element.nodeName.toLowerCase()){case'select':return $("option:selected",element).length;case'input':if(this.checkable(element))return this.findByName(element.name).filter(':checked').length;}return value.length;},depend:function(param,element){return this.dependTypes[typeof param]?this.dependTypes[typeof param](param,element):true;},dependTypes:{"boolean":function(param,element){return param;},"string":function(param,element){return!!$(param,element.form).length;},"function":function(param,element){return param(element);}},optional:function(element){return!$.validator.methods.required.call(this,$.trim(element.value),element)&&"dependency-mismatch";},startRequest:function(element){if(!this.pending[element.name]){this.pendingRequest++;this.pending[element.name]=true;}},stopRequest:function(element,valid){this.pendingRequest--;if(this.pendingRequest<0)this.pendingRequest=0;delete this.pending[element.name];if(valid&&this.pendingRequest==0&&this.formSubmitted&&this.form()){$(this.currentForm).submit();this.formSubmitted=false;}else if(!valid&&this.pendingRequest==0&&this.formSubmitted){$(this.currentForm).triggerHandler("invalid-form",[this]);this.formSubmitted=false;}},previousValue:function(element){return $.data(element,"previousValue")||$.data(element,"previousValue",{old:null,valid:true,message:this.defaultMessage(element,"remote")});}},classRuleSettings:{required:{required:true},email:{email:true},url:{url:true},date:{date:true},dateISO:{dateISO:true},dateDE:{dateDE:true},number:{number:true},numberDE:{numberDE:true},digits:{digits:true},creditcard:{creditcard:true}},addClassRules:function(className,rules){className.constructor==String?this.classRuleSettings[className]=rules:$.extend(this.classRuleSettings,className);},classRules:function(element){var rules={};var classes=$(element).attr('class');classes&&$.each(classes.split(' '),function(){if(this in $.validator.classRuleSettings){$.extend(rules,$.validator.classRuleSettings[this]);}});return rules;},attributeRules:function(element){var rules={};var $element=$(element);for(method in $.validator.methods){var value=$element.attr(method);if(value){rules[method]=value;}}if(rules.maxlength&&/-1|2147483647|524288/.test(rules.maxlength)){delete rules.maxlength;}return rules;},metadataRules:function(element){if(!$.metadata)return{};var meta=$.data(element.form,'validator').settings.meta;return meta?$(element).metadata()[meta]:$(element).metadata();},staticRules:function(element){var rules={};var validator=$.data(element.form,'validator');if(validator.settings.rules){rules=$.validator.normalizeRule(validator.settings.rules[element.name])||{};}return rules;},normalizeRules:function(rules,element){$.each(rules,function(prop,val){if(val===false){delete rules[prop];return;}if(val.param||val.depends){var keepRule=true;switch(typeof val.depends){case"string":keepRule=!!$(val.depends,element.form).length;break;case"function":keepRule=val.depends.call(element,element);break;}if(keepRule){rules[prop]=val.param!==undefined?val.param:true;}else{delete rules[prop];}}});$.each(rules,function(rule,parameter){rules[rule]=$.isFunction(parameter)?parameter(element):parameter;});$.each(['minlength','maxlength','min','max'],function(){if(rules[this]){rules[this]=Number(rules[this]);}});$.each(['rangelength','range'],function(){if(rules[this]){rules[this]=[Number(rules[this][0]),Number(rules[this][1])];}});if($.validator.autoCreateRanges){if(rules.min&&rules.max){rules.range=[rules.min,rules.max];delete rules.min;delete rules.max;}if(rules.minlength&&rules.maxlength){rules.rangelength=[rules.minlength,rules.maxlength];delete rules.minlength;delete rules.maxlength;}}if(rules.messages){delete rules.messages;}return rules;},normalizeRule:function(data){if(typeof data=="string"){var transformed={};$.each(data.split(/\s/),function(){transformed[this]=true;});data=transformed;}return data;},addMethod:function(name,method,message){$.validator.methods[name]=method;$.validator.messages[name]=message!=undefined?message:$.validator.messages[name];if(method.length<3){$.validator.addClassRules(name,$.validator.normalizeRule(name));}},methods:{required:function(value,element,param){if(!this.depend(param,element))return"dependency-mismatch";switch(element.nodeName.toLowerCase()){case'select':var val=$(element).val();return val&&val.length>0;case'input':if(this.checkable(element))return this.getLength(value,element)>0;default:return $.trim(value).length>0;}},remote:function(value,element,param){if(this.optional(element))return"dependency-mismatch";var previous=this.previousValue(element);if(!this.settings.messages[element.name])this.settings.messages[element.name]={};previous.originalMessage=this.settings.messages[element.name].remote;this.settings.messages[element.name].remote=previous.message;param=typeof param=="string"&&{url:param}||param;if(previous.old!==value){previous.old=value;var validator=this;this.startRequest(element);var data={};data[element.name]=value;$.ajax($.extend(true,{url:param,mode:"abort",port:"validate"+element.name,dataType:"json",data:data,success:function(response){validator.settings.messages[element.name].remote=previous.originalMessage;var valid=response===true;if(valid){var submitted=validator.formSubmitted;validator.prepareElement(element);validator.formSubmitted=submitted;validator.successList.push(element);validator.showErrors();}else{var errors={};var message=(previous.message=response||validator.defaultMessage(element,"remote"));errors[element.name]=$.isFunction(message)?message(value):message;validator.showErrors(errors);}previous.valid=valid;validator.stopRequest(element,valid);}},param));return"pending";}else if(this.pending[element.name]){return"pending";}return previous.valid;},minlength:function(value,element,param){return this.optional(element)||this.getLength($.trim(value),element)>=param;},maxlength:function(value,element,param){return this.optional(element)||this.getLength($.trim(value),element)<=param;},rangelength:function(value,element,param){var length=this.getLength($.trim(value),element);return this.optional(element)||(length>=param[0]&&length<=param[1]);},min:function(value,element,param){return this.optional(element)||value>=param;},max:function(value,element,param){return this.optional(element)||value<=param;},range:function(value,element,param){return this.optional(element)||(value>=param[0]&&value<=param[1]);},email:function(value,element){return this.optional(element)||/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i.test(value);},url:function(value,element){return this.optional(element)||/^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i.test(value);},date:function(value,element){return this.optional(element)||!/Invalid|NaN/.test(new Date(value));},dateISO:function(value,element){return this.optional(element)||/^\d{4}[\/-]\d{1,2}[\/-]\d{1,2}$/.test(value);},number:function(value,element){return this.optional(element)||/^-?(?:\d+|\d{1,3}(?:,\d{3})+)(?:\.\d+)?$/.test(value);},digits:function(value,element){return this.optional(element)||/^\d+$/.test(value);},creditcard:function(value,element){if(this.optional(element))return"dependency-mismatch";if(/[^0-9-]+/.test(value))return false;var nCheck=0,nDigit=0,bEven=false;value=value.replace(/\D/g,"");for(var n=value.length-1;n>=0;n--){var cDigit=value.charAt(n);var nDigit=parseInt(cDigit,10);if(bEven){if((nDigit*=2)>9)nDigit-=9;}nCheck+=nDigit;bEven=!bEven;}return(nCheck%10)==0;},accept:function(value,element,param){param=typeof param=="string"?param.replace(/,/g,'|'):"png|jpe?g|gif";return this.optional(element)||value.match(new RegExp(".("+param+")$","i"));},equalTo:function(value,element,param){var target=$(param).unbind(".validate-equalTo").bind("blur.validate-equalTo",function(){$(element).valid();});return value==target.val();}}});$.format=$.validator.format;})(jQuery);;(function($){var ajax=$.ajax;var pendingRequests={};$.ajax=function(settings){settings=$.extend(settings,$.extend({},$.ajaxSettings,settings));var port=settings.port;if(settings.mode=="abort"){if(pendingRequests[port]){pendingRequests[port].abort();}return(pendingRequests[port]=ajax.apply(this,arguments));}return ajax.apply(this,arguments);};})(jQuery);;(function($){if(!jQuery.event.special.focusin&&!jQuery.event.special.focusout&&document.addEventListener){$.each({focus:'focusin',blur:'focusout'},function(original,fix){$.event.special[fix]={setup:function(){this.addEventListener(original,handler,true);},teardown:function(){this.removeEventListener(original,handler,true);},handler:function(e){arguments[0]=$.event.fix(e);arguments[0].type=fix;return $.event.handle.apply(this,arguments);}};function handler(e){e=$.event.fix(e);e.type=fix;return $.event.handle.call(this,e);}});};$.extend($.fn,{validateDelegate:function(delegate,type,handler){return this.bind(type,function(event){var target=$(event.target);if(target.is(delegate)){return handler.apply(target,arguments);}});}});})(jQuery);
var fnames=new Array();var ftypes=new Array();fnames[0]='EMAIL';ftypes[0]='email';fnames[1]='FNAME';ftypes[1]='text';fnames[2]='LNAME';ftypes[2]='text';fnames[3]='MMERGE3';ftypes[3]='text';var err_style='';try{err_style=mc_custom_error_style;}catch(e){err_style='margin: 1em 0 0 0; padding: 1em 0.5em 0.5em 0.5em; background: ERROR_BGCOLOR none repeat scroll 0% 0%; font-weight: bold; float: left; z-index: 1; width: 80%; -moz-background-clip: -moz-initial; -moz-background-origin: -moz-initial; -moz-background-inline-policy: -moz-initial; color: ERROR_COLOR;';}
var head=document.getElementsByTagName('head')[0];var style=document.createElement('style');style.type='text/css';if(style.styleSheet){style.styleSheet.cssText='.mce_inline_error {'+err_style+'}';}else{style.appendChild(document.createTextNode('.mce_inline_error {'+err_style+'}'));}
head.appendChild(style);$(document).ready(function($){var options={errorClass:'mce_inline_error',errorElement:'div',onkeyup:function(){},onfocusout:function(){},onblur:function(){}};var mce_validator=$("#mc-embedded-subscribe-form").validate(options);options={url:'http://handi-lift.us1.list-manage.com/subscribe/post-json?u=088e85e2f42315cc2d278c542&id=88a8315759&c=?',type:'GET',dataType:'json',contentType:"application/json; charset=utf-8",beforeSubmit:function(){$('#mce_tmp_error_msg').remove();$('.datefield','#mc_embed_signup').each(function(){var txt='filled';var fields=new Array();var i=0;$(':text',this).each(function(){fields[i]=this;i++;});$(':hidden',this).each(function(){if(fields[0].value=='MM'&&fields[1].value=='DD'&&fields[2].value=='YYYY'){this.value='';}else if(fields[0].value==''&&fields[1].value==''&&fields[2].value==''){this.value='';}else{this.value=fields[0].value+'/'+fields[1].value+'/'+fields[2].value;}});});return mce_validator.form();},success:mce_success_cb};$('#mc-embedded-subscribe-form').ajaxForm(options);});function mce_success_cb(resp){$('#mce-success-response').hide();$('#mce-error-response').hide();if(resp.result=="success"){$('#mce-'+resp.result+'-response').show();$('#mce-'+resp.result+'-response').html(resp.msg);$('#mc-embedded-subscribe-form').each(function(){this.reset();});}else{var index=-1;var msg;try{var parts=resp.msg.split(' - ',2);if(parts[1]==undefined){msg=resp.msg;}else{i=parseInt(parts[0]);if(i.toString()==parts[0]){index=parts[0];msg=parts[1];}else{index=-1;msg=resp.msg;}}}catch(e){index=-1;msg=resp.msg;}
try{if(index==-1){$('#mce-'+resp.result+'-response').show();$('#mce-'+resp.result+'-response').html(msg);}else{err_id='mce_tmp_error_msg';html='<div id="'+err_id+'" style="'+err_style+'"> '+msg+'</div>';var input_id='#mc_embed_signup';var f=$(input_id);if(ftypes[index]=='address'){input_id='#mce-'+fnames[index]+'-addr1';f=$(input_id).parent().parent().get(0);}else if(ftypes[index]=='date'){input_id='#mce-'+fnames[index]+'-month';f=$(input_id).parent().parent().get(0);}else{input_id='#mce-'+fnames[index];f=$().parent(input_id).get(0);}
if(f){$(f).append(html);$(input_id).focus();}else{$('#mce-'+resp.result+'-response').show();$('#mce-'+resp.result+'-response').html(msg);}}}catch(e){$('#mce-'+resp.result+'-response').show();$('#mce-'+resp.result+'-response').html(msg);}}};(function(window,document,undefined){mti={};mti.J=function(a,b){var c=arguments.length>2?Array.prototype.slice.call(arguments,2):[];return function(){c.push.apply(c,arguments);return b.apply(a,c)}};mti.h=function(a,b){this.i=a;this.b=b};mti.h.prototype.createElement=function(a,b,c){a=this.i.createElement(a);if(b)for(var d in b)if(b.hasOwnProperty(d))if(d=="style"&&this.b.getName()=="MSIE")a.style.cssText=b[d];else a.setAttribute(d,b[d]);c&&a.appendChild(this.i.createTextNode(c));return a};function j(a,b,c){a=a.i.getElementsByTagName(b)[0];if(!a)a=document.documentElement;if(a&&a.lastChild){a.insertBefore(c,a.lastChild);return true}return false}
function q(a,b){function c(){document.body?b():setTimeout(c,0)}c()}mti.h.t=false;function r(a,b){if(mti.h.t===true)b();else if(a.b.getName()=="MSIE"){var c=a.i,d=false,e=function(){if(!d){d=true;b();mti.h.t=true}};(function(){try{c.documentElement.doScroll("left")}catch(f){setTimeout(arguments.callee,50);return}e()})();c.onreadystatechange=function(){if(c.readyState=="complete"){c.onreadystatechange=null;e()}}}else if(a.b.pa=="AppleWebKit"&&a.b.oa<525)(function(){if(["loaded","complete"].indexOf(this.i.readyState)>-1){b();mti.h.t=true}else setTimeout(arguments.callee,50)})();else if(a.i.addEventListener)a.i.addEventListener("DOMContentLoaded",function(){b();mti.h.t=true},false);else window.onload=function(){b();mti.h.t=true}}function s(a,b){if(b.parentNode){b.parentNode.removeChild(b);return true}return false}function t(a,b,c){a=b.className.split(/\s+/);for(var d=0,e=a.length;d<e;d++)if(a[d]==c)return;a.push(c);b.className=a.join(" ").replace(/^\s+/,"")}
function u(a,b,c){a=b.className.split(/\s+/);for(var d=[],e=0,f=a.length;e<f;e++)a[e]!=c&&d.push(a[e]);b.className=d.join(" ").replace(/^\s+/,"").replace(/\s+$/,"")}function w(a,b){var c="";b=b.childNodes||b;for(var d=0;d<b.length;d++)c+=b[d].nodeType!=1?b[d].nodeValue:w(a,b[d].childNodes);return c}mti.h.prototype.getElementById=function(a){return this.i.getElementById(a)};mti.l=function(a,b,c,d,e,f){this.wa=a;this.Ba=b;this.pa=c;this.oa=d;this.ya=e;this.ea=f};mti.l.prototype.getName=function(){return this.wa};mti.e=function(a){this.b=a};mti.e.f="Unknown";mti.e.la=new mti.l(mti.e.f,mti.e.f,mti.e.f,false);mti.e.prototype.parse=function(){return this.b.indexOf("MSIE")!=-1?x(this):this.b.indexOf("Opera")!=-1?z(this):this.b.indexOf("AppleWebKit")!=-1?A(this):this.b.indexOf("Gecko")!=-1?B(this):mti.e.la};function C(a){var b=F(a,a.b,/(iPod|iPad|iPhone|Android)/);if(b!="")return b;a=F(a,a.b,/(Linux|Mac_PowerPC|Macintosh|Windows)/);if(a!=""){if(a=="Mac_PowerPC")a="Macintosh";return a}return mti.e.f}
function x(a){var b=F(a,a.b,/(MSIE [\d\w\.]+)/);if(b!=""){var c=b.split(" ");b=c[0];c=c[1];return new mti.l(b,c,b,c,C(a),G(a,c)>=6)}return new mti.l("MSIE",mti.e.f,"MSIE",mti.e.f,C(a),false)}
function z(a){var b=mti.e.f,c=mti.e.f,d=F(a,a.b,/(Presto\/[\d\w\.]+)/);if(d!=""){c=d.split("/");b=c[0];c=c[1]}else{if(a.b.indexOf("Gecko")!=-1)b="Gecko";d=F(a,a.b,/rv:([^\)]+)/);if(d!="")c=d}if(a.b.indexOf("Version/")!=-1){d=F(a,a.b,/Version\/([\d\.]+)/);if(d!="")return new mti.l("Opera",d,b,c,C(a),G(a,d)>=10)}d=F(a,a.b,/Opera[\/ ]([\d\.]+)/);if(d!="")return new mti.l("Opera",d,b,c,C(a),G(a,d)>=10);return new mti.l("Opera",mti.e.f,b,c,C(a),false)}
function A(a){var b=C(a),c=F(a,a.b,/AppleWebKit\/([\d\.\+]+)/);if(c=="")c=mti.e.f;var d=mti.e.f;if(a.b.indexOf("Chrome")!=-1)d="Chrome";else if(a.b.indexOf("Safari")!=-1)d="Safari";var e=mti.e.f;if(a.b.indexOf("Version/")!=-1)e=F(a,a.b,/Version\/([\d\.\w]+)/);else if(d=="Chrome")e=F(a,a.b,/Chrome\/([\d\.]+)/);var f=F(a,c,/\d+\.(\d+)/);return new mti.l(d,e,"AppleWebKit",c,b,G(a,c)>=526||G(a,c)>=525&&parseInt(f)>=13)}
function B(a){var b=mti.e.f,c=mti.e.f,d=false;if(a.b.indexOf("Firefox")!=-1){b="Firefox";var e=F(a,a.b,/Firefox\/([\d\w\.]+)/);if(e!=""){d=F(a,e,/\d+\.(\d+)/);c=e;d=e!=""&&G(a,e)>=3&&parseInt(d)>=5}}else if(a.b.indexOf("Mozilla")!=-1)b="Mozilla";e=F(a,a.b,/rv:([^\)]+)/);if(e=="")e=mti.e.f;else if(!d){d=G(a,e);var f=parseInt(F(a,e,/\d+\.(\d+)/)),g=parseInt(F(a,e,/\d+\.\d+\.(\d+)/));d=d>1||d==1&&f>9||d==1&&f==9&&g>=2||e.match(/1\.9\.1b[123]/)!=null||e.match(/1\.9\.1\.[\d\.]+/)!=null}return new mti.l(b,c,"Gecko",e,C(a),d)}function G(a,b){a=F(a,b,/(\d+)/);if(a!="")return parseInt(a);return-1}function F(a,b,c){if((a=b.match(c))&&a[1])return a[1];return""};mti.c=function(a,b,c,d){this.a=a;this.g=b;this.W=c;this.o=d||mti.c.B;this.n=new mti.A("-")};mti.c.B="mti";mti.c.q="loading";mti.c.z="active";mti.c.C="inactive";mti.c.H="font";function H(a){t(a.a,a.g,a.n.m(a.o,mti.c.q));I(a,mti.c.q)}function J(a,b,c){u(a.a,a.g,a.n.m(a.o,b,c,mti.c.q));t(a.a,a.g,a.n.m(a.o,b,c,mti.c.z));I(a,mti.c.H+mti.c.z,b,c)}function K(a){t(a.a,a.g,a.n.m(a.o,mti.c.C));I(a,mti.c.C)}function L(a){u(a.a,a.g,a.n.m(a.o,mti.c.q));t(a.a,a.g,a.n.m(a.o,mti.c.z));I(a,mti.c.z)}
function I(a,b,c,d){a.W[b]&&a.W[b](c,d)};mti.ha=function(){this.ba={}};function M(a,b){var c=[];for(var d in b)if(b.hasOwnProperty(d)){var e=a.ba[d];e&&c.push(e(b[d]))}return c};mti.p=function(a,b,c,d,e){this.a=a;this.r=b;this.L=c;this.F=d;this.$=e;this.X=0;this.Q=this.aa=false;this.va=new mti.S;this.ra=new mti.j};mti.p.T="_,arial,helvetica";mti.p.ga="n4";mti.p.prototype.watch=function(a,b,c){for(var d=a.length,e=0;e<d;e++){var f=a[e];b[f]||(b[f]=[mti.p.ga]);this.X+=b[f].length}if(c)this.aa=c;for(e=0;e<d;e++){f=a[e];c=b[f];for(var g=0,h=c.length;g<h;g++){var m=c[g],k=O(this,mti.p.T,m),o=this.L.M(k);s(this.a,k);k=f;var l=this.r;t(l.a,l.g,l.n.m(l.o,k,m,mti.c.q));I(l,mti.c.H+mti.c.q,k,m);l=O(this,this.va.quote(k),m);if(o!=this.L.M(l)){s(this.a,l);J(this.r,k,m);this.Q=true;P(this)}else Q(this,this.$(),o,l,k,m)}}};function P(a){if(--a.X==0&&a.aa)a.Q?L(a.r):K(a.r)}mti.p.prototype.na=function(a,b,c,d,e){if(b!=this.L.M(c)){s(this.a,c);J(this.r,d,e);this.Q=true;P(this)}else if(this.$()-a<5E3)Q(this,a,b,c,d,e);else{s(this.a,c);a=this.r;u(a.a,a.g,a.n.m(a.o,d,e,mti.c.q));t(a.a,a.g,a.n.m(a.o,d,e,mti.c.C));I(a,mti.c.H+mti.c.C,d,e);P(this)}};function Q(a,b,c,d,e,f){a.F(function(g,h){return function(){h.call(g,b,c,d,e,f)}}(a,a.na),50)}
function O(a,b,c){c=a.ra.expand(c);b=a.a.createElement("span",{style:"position:absolute;top:-999px;font-size:300px;font-family:"+b+","+mti.p.T+";"+c},"Mm");j(a.a,"body",b);return b};mti.s=function(a,b,c,d,e){this.a=a;this.Z=b;this.g=c;this.F=d;this.b=e;this.N=this.O=0};mti.s.prototype.V=function(a,b){this.Z.ba[a]=b};mti.s.prototype.load=function(a){var b=new mti.c(this.a,this.g,a);this.b.ea?R(this,b,a):K(b)};mti.s.prototype.ta=function(a,b,c,d){if(d)a.load(mti.J(this,this.xa,b,c));else{a=--this.O==0;this.N--;if(a)this.N==0?K(b):H(b);c.watch([],{},a)}};mti.s.prototype.xa=function(a,b,c,d){var e=--this.O==0;e&&H(a);this.F(mti.J(this,function(f,g,h,m){setTimeout(function(){f.watch(g,h||{},m)},100)},b,c,d,e))};function R(a,b,c){c=M(a.Z,c);a.N=a.O=c.length;for(var d=new mti.p(a.a,b,{M:function(h){return h.offsetWidth}},a.F,function(){return(new Date).getTime()}),e=0,f=c.length;e<f;e++){var g=c[e];S(g,a.b,mti.J(a,a.ta,g,b,d))}};mti.A=function(a){this.ua=a||mti.A.fa};mti.A.fa="-";mti.A.prototype.m=function(){for(var a=[],b=0;b<arguments.length;b++)a.push(arguments[b].replace(/[\W_]+/g,"").toLowerCase());return a.join(this.ua)};mti.S=function(){this.da='"'};mti.S.prototype.quote=function(a){var b=[];a=a.split(/,\s*/);for(var c=0;c<a.length;c++){var d=a[c].replace(/['"]/g,"");d.indexOf(" ")==-1?b.push(d):b.push(this.da+d+this.da)}return b.join(",")};mti.j=function(){this.ca=mti.j.ka;this.w=mti.j.ma};mti.j.ka=["font-style","font-weight"];mti.j.ma={"font-style":[["n","normal"]],"font-weight":[["4","normal"]]};mti.j.U=function(a,b,c){this.sa=a;this.Aa=b;this.w=c};mti.j.U.prototype.expand=function(a,b){for(var c=0;c<this.w.length;c++)if(b==this.w[c][0]){a[this.sa]=this.Aa+":"+this.w[c][1];return}};mti.j.prototype.expand=function(a){if(a.length!=2)return null;for(var b=[null,null],c=0,d=this.ca.length;c<d;c++){var e=this.ca[c],f=a.substr(c,1);(new mti.j.U(c,e,this.w[e])).expand(b,f)}return b[0]&&b[1]?b.join(";")+";":null};window.MonoTypeWebFonts=function(){var a=(new mti.e(navigator.userAgent)).parse();return new mti.s(new mti.h(document,a),new mti.ha,document.documentElement,function(b,c){setTimeout(b,c)},a)}();window.MonoTypeWebFonts.load=window.MonoTypeWebFonts.load;window.MonoTypeWebFonts.addModule=window.MonoTypeWebFonts.V;mti.I=function(a,b,c){this.P=a;this.a=b;this.za=c;this.v={};this.K=[]};mti.I.prototype.indexOf=function(a,b){if(a.indexOf)return a.indexOf(b);else{for(var c=0;c<a.length;c++)if(a[c]==b)return c;return-1}};function T(a,b){var c=a.za,d=typeof b.currentStyle!="undefined"?b.currentStyle.fontFamily:a.a.i.defaultView.getComputedStyle(b,null).getPropertyValue("font-family");d=(d||"").replace(/^\s|\s$/g,"").replace(/'|"/g,"");if(d!=""){var e=new RegExp(d,"ig");for(i=0;i<c.length;i++){var f=c[i];if(e.test(f.fontfamily.replace(/^\s|\s$/g,""))){var g;if(b)g=typeof b.currentStyle!="undefined"?b.currentStyle.visibility:a.a.i.defaultView.getComputedStyle(b,null).getPropertyValue("visibility");if(g!="hidden")b.style.visibility="hidden";a.K.push(b);if(f.enableSubsetting)if(a.v[d])a.v[d]+=w(a.a,b);else a.v[d]=w(a.a,b)}}}}
function U(a){var b="img,select,option,script,noscript,iframe,object,style,param,embed,link,meta,head,title,br,hr".split(","),c=a.P,d=null;do{d=c.firstChild;if(d==null){c.nodeType==1&&a.indexOf(b,c.tagName.toLowerCase())<0&&T(a,c);d=c.nextSibling}if(d==null){c=c;do{d=c.parentNode;if(d==a.P)break;d.nodeType==1&&a.indexOf(b,d.tagName.toLowerCase())<0&&T(a,d);c=d;d=d.nextSibling}while(d==null)}c=d}while(c!=a.P);b=false;for(p in a.v){b=true;break}if(b)return a.v;return null};mti.k=function(a,b,c,d){this.G=a;this.b=b;this.a=c;this.d=d;this.Y=[];this.qa={}};mti.k.ja="monotype";var V="TTF";function S(a,b,c){V=W(a);var d=a.d.projectId;if(d){a.G["__mti_fntLst"+d]=function(){return a.d.pfL};a.G.mti_element_cache=[];X(a);if(a.d.reqSub)r(a.a,function(){var e=new mti.I(document.body,a.a,a.d.pfL),f=U(e);for(fontfamily in f)f[fontfamily]=Y(a,f[fontfamily]);a.G.mti_element_cache=e.K;Z(a,f)});else{Z(a);q(a.a,function(){var e=new mti.I(document.body,a.a,a.d.pfL);U(e);a.G.mti_element_cache=e.K})}c(b.ea)}else c(true)}
function W(a){var b=a.d.ffArray,c=a.b.getName();c=c.toLowerCase();if(c=="firefox")c="mozilla";if(/ipad|ipod|iphone/.test(a.b.ya.toLowerCase()))c="msafari";a=a.b.Ba;b=b[c];c="";for(p in b)if(parseFloat(a)>=parseFloat(p))c=b[p];return c}mti.k.D=300;function Z(a,b){var c=a.d.projectId,d=a.d.ec,e=a.d.fcURL,f=a.d.dfcURL,g=a.a.createElement("style",{type:"text/css",id:"mti_fontface_"+a.d.projectId});j(a.a,"head",g);var h="",m=false,k={},o={TTF:"truetype",WOFF:"woff",SVG:"svg"},l=V!=null&&V.toUpperCase()=="EOT";for(i=0;i<a.d.pfL.length;i++){var v=a.d.pfL[i],n=v.fontfamily,D=v.contentIds;a.Y.push(n);if(b&&b[n]&&b[n].length>mti.k.D){m=true;k[n]||(k[n]=[]);var N=b[n],E=(N.length-1)/mti.k.D+1;E=Math.floor(E);for(var y=1;y<=E;y++){newFontFamily=n+""+
y;k[n].push(newFontFamily);b[newFontFamily]=N.substr((y-1)*mti.k.D,mti.k.D);h+="@font-face{font-family:'"+newFontFamily+"';src:url('"+$(a,D,c,v.enableSubsetting,d,e,f,a.d.ck,newFontFamily,b)+"')";l||(h+=" format('"+o[V.toUpperCase()]+"')");h+=";}\n"}}else{h+="@font-face{font-family:'"+n+"';src:url('"+$(a,D,c,v.enableSubsetting,d,e,f,a.d.ck,n,b)+"')";if(!l){v=D[V.toUpperCase()];n=o[V.toUpperCase()];v||(n=o.TTF);h+=" format('"+n+"')"}h+=";}\n"}}if(m===true){s(a.a,a.a.getElementById("mti_stylesheet_"+
a.d.projectId)||{});X(a,k)}if(g.styleSheet)g.styleSheet.cssText=h;else{a=document.createTextNode(h);g.appendChild(a)}}
function X(a,b){var c=a.a.createElement("style",{type:"text/css",id:"mti_stylesheet_"+a.d.projectId});j(a.a,"head",c);var d="";for(i in a.d.selectorFontMap){var e=a.d.selectorFontMap[i];if(b&&b[e]&&b[e].length>0)e=b[e].join("','");d+=i+"{font-family:'"+e+"';}\n";d+="/*fout specific code:*/\n";d+="."+mti.c.B+"-loading "+i+"{visibility:hidden;}\n";d+="."+mti.c.B+"-active "+i+", ."+mti.c.B+"-inactive "+i+"{visibility: visible;}\n"}if(c.styleSheet)c.styleSheet.cssText=d;else{a=document.createTextNode(d);c.appendChild(a)}}function Y(a,b){if(b&&typeof b=="string"){b=b.replace(/\s/g,"").replace(/\n/g,"").replace(/\r/g,"");a="";for(var c=b.length,d=null,e=0;e<c;e++){d=b.charAt(e);if(a.indexOf(d)==-1)a+=d}return a}return""}
function $(a,b,c,d,e,f,g,h,m,k){var o=b[V.toUpperCase()],l="http://";if(window.location.protocol=="https:")l="https://";f=f.replace("http://","").replace("https://","");g=g.replace("http://","").replace("https://","");f=l+f;g=l+g;if(d){url=g+"?";if(e)url+=h+"&";url+="fctypeId="+a.d.fctypeArray[V]+"&fcId="+b.TTF+"&origId="+o}else url=e?o?f+o+"."+V.toLowerCase()+"?"+h:f+b.TTF+".ttf?"+h:f+"?fctypeId="+a.d.fctypeArray[V]+"&fcId="+o;url+="&projectId="+c;if(k)url+="&content="+escape((k[m]||"")+"giMm");if(V!=null&&V.toUpperCase()=="SVG")url+="#"+o;return url}mti.k.prototype.load=function(a){a(this.Y,this.qa)};mti.ia=function(a){this.u=a};mti.ia.prototype.protocol=function(){var a=["http:","https:"],b=a[0];if(this.u&&this.u.location&&this.u.location.protocol){var c=0;for(c=0;c<a.length;c++)if(this.u.location.protocol==a[c])return this.u.location.protocol}return b};mti.R=function(a,b){this.a=a;this.d=b};mti.R.prototype.appendBannerScript=function(){var a;a=new RegExp(escape("WFS_MTI_SS")+"=([^;]+)");if(a.test(document.cookie+";")){a.exec(document.cookie+";");a=unescape(RegExp.$1)}else a=false;var b=this.d.bannerHandlerURL;if(b){b+="?projectId="+this.d.projectId;if(a!==false)b+="&WFS_MTI_SS="+a;b+="&"+escape((new Date).getTime());j(this.a,"head",this.a.createElement("Script",{type:"text/javascript",src:b}))}};MonoTypeWebFonts.V(mti.k.ja,function(a){var b=(new mti.e(navigator.userAgent)).parse(),c=new mti.h(document,b);window.MonoTypeWebFonts.BannerHandler=new mti.R(c,a);return new mti.k(window,b,c,a)});})(this,document);if(window.addEventListener){window.addEventListener('load',function(){MonoTypeWebFonts.cleanup()},false);}else if(window.attachEvent){window.attachEvent('onload',function(){MonoTypeWebFonts.cleanup();});}MonoTypeWebFonts.cleanupExecuted=false;MonoTypeWebFonts.cleanup=function(){if(MonoTypeWebFonts.cleanupExecuted===true){return;}MonoTypeWebFonts.cleanupExecuted=(window['mti_element_cache'].length>0);for(i=0;i<window['mti_element_cache'].length;i++){window['mti_element_cache'][i].style.visibility="";}var className=document.documentElement.className;className=className.replace(/\b(mti\-.*?(loading|active|inactive))\b/g,'').replace(/^\s+|\s+$/g,'').replace(/\s+/g,' ');setTimeout(function(){document.documentElement.className=className+' mti-repaint';},20);if(!document.getElementById('MonoTypeFontApiFontTracker')){var fontTrackingUrl="http://fast.fonts.com/t/1.css";if(window.location.protocol=='https:'){fontTrackingUrl=fontTrackingUrl.replace(/http:/,'https:');}var head=document.getElementsByTagName('HEAD')[0];var cssEle=document.createElement('LINK');if(cssEle){cssEle.setAttribute('id','MonoTypeFontApiFontTracker');cssEle.setAttribute('type','text/css');cssEle.setAttribute('rel','stylesheet');cssEle.setAttribute('href',fontTrackingUrl+"?apiType=css&projectid=c604e366-c650-420a-bf33-2d84cf12c60a");head.appendChild(cssEle);}}window['mti_element_cache']=[];};MonoTypeWebFonts._fontActiveEventList=[];MonoTypeWebFonts._fontLoadingEventList=[];MonoTypeWebFonts._activeEventList=[];MonoTypeWebFonts._inActiveEventList=[];MonoTypeWebFonts.addEvent=function(eventName,callbackFunction){if(eventName.toLowerCase()=='fontactive'){MonoTypeWebFonts._fontActiveEventList.push(callbackFunction);}else if(eventName.toLowerCase()=='fontloading'){MonoTypeWebFonts._fontLoadingEventList.push(callbackFunction);}else if(eventName.toLowerCase()=='inactive'){MonoTypeWebFonts._inActiveEventList.push(callbackFunction);}else if(eventName.toLowerCase()=='active'){MonoTypeWebFonts._activeEventList.push(callbackFunction);}};MonoTypeWebFonts.loadFonts=function(){MonoTypeWebFonts.load({monotype:{reqSub:false,pfL:[{'fontfamily':"TradeGothicNextW01-Bold 693229",contentIds:{EOT:'678017fc-bfca-4daa-a38a-b0f41bada5e7',WOFF:'4d16ea6c-033a-41b1-8326-56a1d7392d5f',TTF:'573b39c2-10f7-4b72-a656-89a329b76560',SVG:'d079b7e1-7489-4f6d-b4c9-536742085cff'},enableSubsetting:false},{'fontfamily':"Trade Gothic Next W01",contentIds:{EOT:'8a6c3750-4927-4649-9dac-87049f5e9700',WOFF:'57625f96-ca80-4602-9644-ec1803cb3ba3',TTF:'6618d500-1727-4334-878e-1c4b95192f42',SVG:'01ebe944-ca6c-41db-a3ba-b7e2a90536d9'},enableSubsetting:false},{'fontfamily':"TradeGothicNextW01-BdCm",contentIds:{EOT:'0f67b794-9e03-4118-8ba1-fd245d393a90',WOFF:'645e0d00-e1a5-4a4f-a874-18088b350387',TTF:'42879774-35f5-4fb3-b33c-b9093f346060',SVG:'4c69e0f8-29c6-4629-8d1e-836a97e63858'},enableSubsetting:false}],selectorFontMap:{},ck:'d44f19a684109620e4841579af90e81815eac57c3142f7b7e65da4f0ac6030febca86d9e02bafce2d915eed7f68a34d99ad38479a13099333f1c65ba33d96d55511c2f40db92d6a6ff936e948b79f1fde161eae7d1ee711daef1bc970ae6e9552a30f7eafde22495b4d112aa',ec:'true',fcURL:'http://fast.fonts.com/d/',dfcURL:'http://api2.fonts.com/FontSubsetter.ashx',sO:'True',ffArray:{safari:{'3.1':'ttf'},msafari:{'1':'svg'},chrome:{'3':'svg','4':'ttf','5':'woff'},opera:{'10':'ttf'},msie:{'4':'eot','9':'woff'},mozilla:{'3.5':'ttf','3.6':'woff'}},fctypeArray:{'ttf':'1','eot':'2','woff':'3','svg':'11'},projectId:'c604e366-c650-420a-bf33-2d84cf12c60a',EOD:null},fontloading:function(fontFamily,fontDescription){for(var i=0;i<MonoTypeWebFonts._fontLoadingEventList.length;i++){MonoTypeWebFonts._fontLoadingEventList[i].call(MonoTypeWebFonts,fontFamily,fontDescription);}},fontactive:function(fontFamily,fontDescription){for(var i=0;i<MonoTypeWebFonts._fontActiveEventList.length;i++){MonoTypeWebFonts._fontActiveEventList[i].call(MonoTypeWebFonts,fontFamily,fontDescription);}},inactive:function(){MonoTypeWebFonts.cleanup();for(var i=0;i<MonoTypeWebFonts._inActiveEventList.length;i++){MonoTypeWebFonts._inActiveEventList[i].call(MonoTypeWebFonts);}},active:function(){MonoTypeWebFonts.cleanup();for(var i=0;i<MonoTypeWebFonts._activeEventList.length;i++){MonoTypeWebFonts._activeEventList[i].call(MonoTypeWebFonts);}}});};MonoTypeWebFonts.loadFonts();MonoTypeWebFonts.RefreshFonts=function(){MonoTypeWebFonts.cleanupExecuted=false;if(document.getElementById('mti_stylesheet_c604e366-c650-420a-bf33-2d84cf12c60a')!=null){var nodeToRemove1=document.getElementById('mti_stylesheet_c604e366-c650-420a-bf33-2d84cf12c60a');var parentNode1=nodeToRemove1.parentNode;parentNode1.removeChild(nodeToRemove1);}if(document.getElementById('mti_fontface_c604e366-c650-420a-bf33-2d84cf12c60a')!=null){var nodeToRemove2=document.getElementById('mti_fontface_c604e366-c650-420a-bf33-2d84cf12c60a');var parentNode2=nodeToRemove2.parentNode;parentNode2.removeChild(nodeToRemove2);}MonoTypeWebFonts.loadFonts();};setTimeout(function(){MonoTypeWebFonts.cleanup();},6000);
