(function(n){typeof define=="function"&&define.amd?define(["jquery"],n):n(jQuery)})(function(n){function p(n){for(var t=n.css("visibility");t==="inherit";)n=n.parent(),t=n.css("visibility");return t!=="hidden"}function b(n){for(var t,i;n.length&&n[0]!==document;){if(t=n.css("position"),(t==="absolute"||t==="relative"||t==="fixed")&&(i=parseInt(n.css("zIndex"),10),!isNaN(i)&&i!==0))return i;n=n.parent()}return 0}function s(){this._curInst=null;this._keyEvent=!1;this._disabledInputs=[];this._datepickerShowing=!1;this._inDialog=!1;this._mainDivId="ui-datepicker-div";this._inlineClass="ui-datepicker-inline";this._appendClass="ui-datepicker-append";this._triggerClass="ui-datepicker-trigger";this._dialogClass="ui-datepicker-dialog";this._disableClass="ui-datepicker-disabled";this._unselectableClass="ui-datepicker-unselectable";this._currentClass="ui-datepicker-current-day";this._dayOverClass="ui-datepicker-days-cell-over";this.regional=[];this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""};this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1};n.extend(this._defaults,this.regional[""]);this.regional.en=n.extend(!0,{},this.regional[""]);this.regional["en-US"]=n.extend(!0,{},this.regional.en);this.dpDiv=h(n("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'><\/div>"))}function h(t){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return t.on("mouseout",i,function(){n(this).removeClass("ui-state-hover");this.className.indexOf("ui-datepicker-prev")!==-1&&n(this).removeClass("ui-datepicker-prev-hover");this.className.indexOf("ui-datepicker-next")!==-1&&n(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",i,c)}function c(){n.datepicker._isDisabledDatepicker(t.inline?t.dpDiv.parent()[0]:t.input[0])||(n(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),n(this).addClass("ui-state-hover"),this.className.indexOf("ui-datepicker-prev")!==-1&&n(this).addClass("ui-datepicker-prev-hover"),this.className.indexOf("ui-datepicker-next")!==-1&&n(this).addClass("ui-datepicker-next-hover"))}function i(t,i){n.extend(t,i);for(var r in i)i[r]==null&&(t[r]=i[r]);return t}var y,w,t,k;n.ui=n.ui||{};var d=n.ui.version="1.12.1",v=0,o=Array.prototype.slice;n.cleanData=function(t){return function(i){for(var r,u,f=0;(u=i[f])!=null;f++)try{r=n._data(u,"events");r&&r.remove&&n(u).triggerHandler("remove")}catch(e){}t(i)}}(n.cleanData);n.widget=function(t,i,r){var f,u,o,h={},e=t.split(".")[0],s;return t=t.split(".")[1],s=e+"-"+t,r||(r=i,i=n.Widget),n.isArray(r)&&(r=n.extend.apply(null,[{}].concat(r))),n.expr[":"][s.toLowerCase()]=function(t){return!!n.data(t,s)},n[e]=n[e]||{},f=n[e][t],u=n[e][t]=function(n,t){if(!this._createWidget)return new u(n,t);arguments.length&&this._createWidget(n,t)},n.extend(u,f,{version:r.version,_proto:n.extend({},r),_childConstructors:[]}),o=new i,o.options=n.widget.extend({},o.options),n.each(r,function(t,r){if(!n.isFunction(r)){h[t]=r;return}h[t]=function(){function n(){return i.prototype[t].apply(this,arguments)}function u(n){return i.prototype[t].apply(this,n)}return function(){var i=this._super,f=this._superApply,t;return this._super=n,this._superApply=u,t=r.apply(this,arguments),this._super=i,this._superApply=f,t}}()}),u.prototype=n.widget.extend(o,{widgetEventPrefix:f?o.widgetEventPrefix||t:t},h,{constructor:u,namespace:e,widgetName:t,widgetFullName:s}),f?(n.each(f._childConstructors,function(t,i){var r=i.prototype;n.widget(r.namespace+"."+r.widgetName,u,i._proto)}),delete f._childConstructors):i._childConstructors.push(u),n.widget.bridge(t,u),u};n.widget.extend=function(t){for(var f=o.call(arguments,1),u=0,e=f.length,i,r;u<e;u++)for(i in f[u])r=f[u][i],f[u].hasOwnProperty(i)&&r!==undefined&&(t[i]=n.isPlainObject(r)?n.isPlainObject(t[i])?n.widget.extend({},t[i],r):n.widget.extend({},r):r);return t};n.widget.bridge=function(t,i){var r=i.prototype.widgetFullName||t;n.fn[t]=function(u){var s=typeof u=="string",e=o.call(arguments,1),f=this;return s?this.length||u!=="instance"?this.each(function(){var i,o=n.data(this,r);return u==="instance"?(f=o,!1):o?!n.isFunction(o[u])||u.charAt(0)==="_"?n.error("no such method '"+u+"' for "+t+" widget instance"):(i=o[u].apply(o,e),i!==o&&i!==undefined?(f=i&&i.jquery?f.pushStack(i.get()):i,!1):void 0):n.error("cannot call methods on "+t+" prior to initialization; attempted to call method '"+u+"'")}):f=undefined:(e.length&&(u=n.widget.extend.apply(null,[u].concat(e))),this.each(function(){var t=n.data(this,r);t?(t.option(u||{}),t._init&&t._init()):n.data(this,r,new i(u,this))})),f}};n.Widget=function(){};n.Widget._childConstructors=[];n.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,i){i=n(i||this.defaultElement||this)[0];this.element=n(i);this.uuid=v++;this.eventNamespace="."+this.widgetName+this.uuid;this.bindings=n();this.hoverable=n();this.focusable=n();this.classesElementLookup={};i!==this&&(n.data(i,this.widgetFullName,this),this._on(!0,this.element,{remove:function(n){n.target===i&&this.destroy()}}),this.document=n(i.style?i.ownerDocument:i.document||i),this.window=n(this.document[0].defaultView||this.document[0].parentWindow));this.options=n.widget.extend({},this.options,this._getCreateOptions(),t);this._create();this.options.disabled&&this._setOptionDisabled(this.options.disabled);this._trigger("create",null,this._getCreateEventData());this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:n.noop,_create:n.noop,_init:n.noop,destroy:function(){var t=this;this._destroy();n.each(this.classesElementLookup,function(n,i){t._removeClass(i,n)});this.element.off(this.eventNamespace).removeData(this.widgetFullName);this.widget().off(this.eventNamespace).removeAttr("aria-disabled");this.bindings.off(this.eventNamespace)},_destroy:n.noop,widget:function(){return this.element},option:function(t,i){var e=t,r,u,f;if(arguments.length===0)return n.widget.extend({},this.options);if(typeof t=="string")if(e={},r=t.split("."),t=r.shift(),r.length){for(u=e[t]=n.widget.extend({},this.options[t]),f=0;f<r.length-1;f++)u[r[f]]=u[r[f]]||{},u=u[r[f]];if(t=r.pop(),arguments.length===1)return u[t]===undefined?null:u[t];u[t]=i}else{if(arguments.length===1)return this.options[t]===undefined?null:this.options[t];e[t]=i}return this._setOptions(e),this},_setOptions:function(n){for(var t in n)this._setOption(t,n[t]);return this},_setOption:function(n,t){return n==="classes"&&this._setOptionClasses(t),this.options[n]=t,n==="disabled"&&this._setOptionDisabled(t),this},_setOptionClasses:function(t){var i,u,r;for(i in t)(r=this.classesElementLookup[i],t[i]!==this.options.classes[i]&&r&&r.length)&&(u=n(r.get()),this._removeClass(r,i),u.addClass(this._classes({element:u,keys:i,classes:t,add:!0})))},_setOptionDisabled:function(n){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!n);n&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(t){function u(u,f){for(var o,e=0;e<u.length;e++)o=r.classesElementLookup[u[e]]||n(),o=t.add?n(n.unique(o.get().concat(t.element.get()))):n(o.not(t.element).get()),r.classesElementLookup[u[e]]=o,i.push(u[e]),f&&t.classes[u[e]]&&i.push(t.classes[u[e]])}var i=[],r=this;return t=n.extend({element:this.element,classes:this.options.classes||{}},t),this._on(t.element,{remove:"_untrackClassesElement"}),t.keys&&u(t.keys.match(/\S+/g)||[],!0),t.extra&&u(t.extra.match(/\S+/g)||[]),i.join(" ")},_untrackClassesElement:function(t){var i=this;n.each(i.classesElementLookup,function(r,u){n.inArray(t.target,u)!==-1&&(i.classesElementLookup[r]=n(u.not(t.target).get()))})},_removeClass:function(n,t,i){return this._toggleClass(n,t,i,!1)},_addClass:function(n,t,i){return this._toggleClass(n,t,i,!0)},_toggleClass:function(n,t,i,r){r=typeof r=="boolean"?r:i;var u=typeof n=="string"||n===null,f={extra:u?t:i,keys:u?n:t,element:u?this.element:n,add:r};return f.element.toggleClass(this._classes(f),r),this},_on:function(t,i,r){var f,u=this;typeof t!="boolean"&&(r=i,i=t,t=!1);r?(i=f=n(i),this.bindings=this.bindings.add(i)):(r=i,i=this.element,f=this.widget());n.each(r,function(r,e){function o(){if(t||u.options.disabled!==!0&&!n(this).hasClass("ui-state-disabled"))return(typeof e=="string"?u[e]:e).apply(u,arguments)}typeof e!="string"&&(o.guid=e.guid=e.guid||o.guid||n.guid++);var s=r.match(/^([\w:-]*)\s*(.*)$/),h=s[1]+u.eventNamespace,c=s[2];if(c)f.on(h,c,o);else i.on(h,o)})},_off:function(t,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace;t.off(i).off(i);this.bindings=n(this.bindings.not(t).get());this.focusable=n(this.focusable.not(t).get());this.hoverable=n(this.hoverable.not(t).get())},_delay:function(n,t){function r(){return(typeof n=="string"?i[n]:n).apply(i,arguments)}var i=this;return setTimeout(r,t||0)},_hoverable:function(t){this.hoverable=this.hoverable.add(t);this._on(t,{mouseenter:function(t){this._addClass(n(t.currentTarget),null,"ui-state-hover")},mouseleave:function(t){this._removeClass(n(t.currentTarget),null,"ui-state-hover")}})},_focusable:function(t){this.focusable=this.focusable.add(t);this._on(t,{focusin:function(t){this._addClass(n(t.currentTarget),null,"ui-state-focus")},focusout:function(t){this._removeClass(n(t.currentTarget),null,"ui-state-focus")}})},_trigger:function(t,i,r){var u,f,e=this.options[t];if(r=r||{},i=n.Event(i),i.type=(t===this.widgetEventPrefix?t:this.widgetEventPrefix+t).toLowerCase(),i.target=this.element[0],f=i.originalEvent,f)for(u in f)u in i||(i[u]=f[u]);return this.element.trigger(i,r),!(n.isFunction(e)&&e.apply(this.element[0],[i].concat(r))===!1||i.isDefaultPrevented())}};n.each({show:"fadeIn",hide:"fadeOut"},function(t,i){n.Widget.prototype["_"+t]=function(r,u,f){typeof u=="string"&&(u={effect:u});var o,e=u?u===!0||typeof u=="number"?i:u.effect||i:t;u=u||{};typeof u=="number"&&(u={duration:u});o=!n.isEmptyObject(u);u.complete=f;u.delay&&r.delay(u.delay);o&&n.effects&&n.effects.effect[e]?r[t](u):e!==t&&r[e]?r[e](u.duration,u.easing,f):r.queue(function(i){n(this)[t]();f&&f.call(r[0]);i()})}});y=n.widget,function(){function c(n,t,i){return[parseFloat(n[0])*(h.test(n[0])?t/100:1),parseFloat(n[1])*(h.test(n[1])?i/100:1)]}function r(t,i){return parseInt(n.css(t,i),10)||0}function a(t){var i=t[0];return i.nodeType===9?{width:t.width(),height:t.height(),offset:{top:0,left:0}}:n.isWindow(i)?{width:t.width(),height:t.height(),offset:{top:t.scrollTop(),left:t.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:t.outerWidth(),height:t.outerHeight(),offset:t.offset()}}var u,i=Math.max,t=Math.abs,f=/left|center|right/,e=/top|center|bottom/,o=/[\+\-]\d+(\.[\d]+)?%?/,s=/^\w+/,h=/%$/,l=n.fn.position;n.position={scrollbarWidth:function(){if(u!==undefined)return u;var r,i,t=n("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'><\/div><\/div>"),f=t.children()[0];return n("body").append(t),r=f.offsetWidth,t.css("overflow","scroll"),i=f.offsetWidth,r===i&&(i=t[0].clientWidth),t.remove(),u=r-i},getScrollInfo:function(t){var i=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),r=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),u=i==="scroll"||i==="auto"&&t.width<t.element[0].scrollWidth,f=r==="scroll"||r==="auto"&&t.height<t.element[0].scrollHeight;return{width:f?n.position.scrollbarWidth():0,height:u?n.position.scrollbarWidth():0}},getWithinInfo:function(t){var i=n(t||window),r=n.isWindow(i[0]),u=!!i[0]&&i[0].nodeType===9,f=!r&&!u;return{element:i,isWindow:r,isDocument:u,offset:f?n(t).offset():{left:0,top:0},scrollLeft:i.scrollLeft(),scrollTop:i.scrollTop(),width:i.outerWidth(),height:i.outerHeight()}}};n.fn.position=function(u){if(!u||!u.of)return l.apply(this,arguments);u=n.extend({},u);var w,h,v,p,y,k,d=n(u.of),nt=n.position.getWithinInfo(u.within),tt=n.position.getScrollInfo(nt),b=(u.collision||"flip").split(" "),g={};return k=a(d),d[0].preventDefault&&(u.at="left top"),h=k.width,v=k.height,p=k.offset,y=n.extend({},p),n.each(["my","at"],function(){var n=(u[this]||"").split(" "),t,i;n.length===1&&(n=f.test(n[0])?n.concat(["center"]):e.test(n[0])?["center"].concat(n):["center","center"]);n[0]=f.test(n[0])?n[0]:"center";n[1]=e.test(n[1])?n[1]:"center";t=o.exec(n[0]);i=o.exec(n[1]);g[this]=[t?t[0]:0,i?i[0]:0];u[this]=[s.exec(n[0])[0],s.exec(n[1])[0]]}),b.length===1&&(b[1]=b[0]),u.at[0]==="right"?y.left+=h:u.at[0]==="center"&&(y.left+=h/2),u.at[1]==="bottom"?y.top+=v:u.at[1]==="center"&&(y.top+=v/2),w=c(g.at,h,v),y.left+=w[0],y.top+=w[1],this.each(function(){var a,k,e=n(this),o=e.outerWidth(),s=e.outerHeight(),it=r(this,"marginLeft"),rt=r(this,"marginTop"),ut=o+it+r(this,"marginRight")+tt.width,ft=s+rt+r(this,"marginBottom")+tt.height,f=n.extend({},y),l=c(g.my,e.outerWidth(),e.outerHeight());u.my[0]==="right"?f.left-=o:u.my[0]==="center"&&(f.left-=o/2);u.my[1]==="bottom"?f.top-=s:u.my[1]==="center"&&(f.top-=s/2);f.left+=l[0];f.top+=l[1];a={marginLeft:it,marginTop:rt};n.each(["left","top"],function(t,i){n.ui.position[b[t]]&&n.ui.position[b[t]][i](f,{targetWidth:h,targetHeight:v,elemWidth:o,elemHeight:s,collisionPosition:a,collisionWidth:ut,collisionHeight:ft,offset:[w[0]+l[0],w[1]+l[1]],my:u.my,at:u.at,within:nt,elem:e})});u.using&&(k=function(n){var r=p.left-f.left,a=r+h-o,c=p.top-f.top,y=c+v-s,l={target:{element:d,left:p.left,top:p.top,width:h,height:v},element:{element:e,left:f.left,top:f.top,width:o,height:s},horizontal:a<0?"left":r>0?"right":"center",vertical:y<0?"top":c>0?"bottom":"middle"};h<o&&t(r+a)<h&&(l.horizontal="center");v<s&&t(c+y)<v&&(l.vertical="middle");l.important=i(t(r),t(a))>i(t(c),t(y))?"horizontal":"vertical";u.using.call(this,n,l)});e.offset(n.extend(f,{using:k}))})};n.ui.position={fit:{left:function(n,t){var e=t.within,u=e.isWindow?e.scrollLeft:e.offset.left,o=e.width,s=n.left-t.collisionPosition.marginLeft,r=u-s,f=s+t.collisionWidth-o-u,h;t.collisionWidth>o?r>0&&f<=0?(h=n.left+r+t.collisionWidth-o-u,n.left+=r-h):n.left=f>0&&r<=0?u:r>f?u+o-t.collisionWidth:u:r>0?n.left+=r:f>0?n.left-=f:n.left=i(n.left-s,n.left)},top:function(n,t){var o=t.within,u=o.isWindow?o.scrollTop:o.offset.top,e=t.within.height,s=n.top-t.collisionPosition.marginTop,r=u-s,f=s+t.collisionHeight-e-u,h;t.collisionHeight>e?r>0&&f<=0?(h=n.top+r+t.collisionHeight-e-u,n.top+=r-h):n.top=f>0&&r<=0?u:r>f?u+e-t.collisionHeight:u:r>0?n.top+=r:f>0?n.top-=f:n.top=i(n.top-s,n.top)}},flip:{left:function(n,i){var r=i.within,y=r.offset.left+r.scrollLeft,c=r.width,o=r.isWindow?r.scrollLeft:r.offset.left,l=n.left-i.collisionPosition.marginLeft,a=l-o,v=l+i.collisionWidth-c-o,u=i.my[0]==="left"?-i.elemWidth:i.my[0]==="right"?i.elemWidth:0,f=i.at[0]==="left"?i.targetWidth:i.at[0]==="right"?-i.targetWidth:0,e=-2*i.offset[0],s,h;a<0?(s=n.left+u+f+e+i.collisionWidth-c-y,(s<0||s<t(a))&&(n.left+=u+f+e)):v>0&&(h=n.left-i.collisionPosition.marginLeft+u+f+e-o,(h>0||t(h)<v)&&(n.left+=u+f+e))},top:function(n,i){var r=i.within,y=r.offset.top+r.scrollTop,c=r.height,o=r.isWindow?r.scrollTop:r.offset.top,l=n.top-i.collisionPosition.marginTop,a=l-o,v=l+i.collisionHeight-c-o,p=i.my[1]==="top",u=p?-i.elemHeight:i.my[1]==="bottom"?i.elemHeight:0,f=i.at[1]==="top"?i.targetHeight:i.at[1]==="bottom"?-i.targetHeight:0,e=-2*i.offset[1],s,h;a<0?(h=n.top+u+f+e+i.collisionHeight-c-y,(h<0||h<t(a))&&(n.top+=u+f+e)):v>0&&(s=n.top-i.collisionPosition.marginTop+u+f+e-o,(s>0||t(s)<v)&&(n.top+=u+f+e))}},flipfit:{left:function(){n.ui.position.flip.left.apply(this,arguments);n.ui.position.fit.left.apply(this,arguments)},top:function(){n.ui.position.flip.top.apply(this,arguments);n.ui.position.fit.top.apply(this,arguments)}}}}();var g=n.ui.position,nt=n.extend(n.expr[":"],{data:n.expr.createPseudo?n.expr.createPseudo(function(t){return function(i){return!!n.data(i,t)}}):function(t,i,r){return!!n.data(t,r[3])}}),tt=n.fn.extend({disableSelection:function(){var n="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(n+".ui-disableSelection",function(n){n.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});n.ui.focusable=function(t,i){var u,f,e,r,o,s=t.nodeName.toLowerCase();return"area"===s?(u=t.parentNode,f=u.name,!t.href||!f||u.nodeName.toLowerCase()!=="map")?!1:(e=n("img[usemap='#"+f+"']"),e.length>0&&e.is(":visible")):(/^(input|select|textarea|button|object)$/.test(s)?(r=!t.disabled,r&&(o=n(t).closest("fieldset")[0],o&&(r=!o.disabled))):r="a"===s?t.href||i:i,r&&n(t).is(":visible")&&p(n(t)))};n.extend(n.expr[":"],{focusable:function(t){return n.ui.focusable(t,n.attr(t,"tabindex")!=null)}});var it=n.ui.focusable,rt=n.fn.form=function(){return typeof this[0].form=="string"?this.closest("form"):n(this[0].form)},ut=n.ui.formResetMixin={_formResetHandler:function(){var t=n(this);setTimeout(function(){var i=t.data("ui-form-reset-instances");n.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var n=this.form.data("ui-form-reset-instances")||[];if(!n.length)this.form.on("reset.ui-form-reset",this._formResetHandler);n.push(this);this.form.data("ui-form-reset-instances",n)}},_unbindFormResetHandler:function(){if(this.form.length){var t=this.form.data("ui-form-reset-instances");t.splice(n.inArray(this,t),1);t.length?this.form.data("ui-form-reset-instances",t):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},ft=n.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},et=n.ui.escapeSelector=function(){var n=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(t){return t.replace(n,"\\$1")}}(),ot=n.fn.labels=function(){var t,r,u,i,f;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(i=this.eq(0).parents("label"),u=this.attr("id"),u&&(t=this.eq(0).parents().last(),f=t.add(t.length?t.siblings():this.siblings()),r="label[for='"+n.ui.escapeSelector(u)+"']",i=i.add(f.find(r).addBack(r))),this.pushStack(i))},st=n.fn.scrollParent=function(t){var i=this.css("position"),u=i==="absolute",f=t?/(auto|scroll|hidden)/:/(auto|scroll)/,r=this.parents().filter(function(){var t=n(this);return u&&t.css("position")==="static"?!1:f.test(t.css("overflow")+t.css("overflow-y")+t.css("overflow-x"))}).eq(0);return i==="fixed"||!r.length?n(this[0].ownerDocument||document):r},ht=n.extend(n.expr[":"],{tabbable:function(t){var i=n.attr(t,"tabindex"),r=i!=null;return(!r||i>=0)&&n.ui.focusable(t,r)}}),ct=n.fn.extend({uniqueId:function(){var n=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++n)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&n(this).removeAttr("id")})}}),lt=n.ui.safeActiveElement=function(n){var t;try{t=n.activeElement}catch(i){t=n.body}return t||(t=n.body),t.nodeName||(t=n.body),t},at=n.widget("ui.menu",{version:"1.12.1",defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element;this.mouseHandled=!1;this.element.uniqueId().attr({role:this.options.role,tabIndex:0});this._addClass("ui-menu","ui-widget ui-widget-content");this._on({"mousedown .ui-menu-item":function(n){n.preventDefault()},"click .ui-menu-item":function(t){var i=n(t.target),r=n(n.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(t),t.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(t):!this.element.is(":focus")&&r.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&this.active.parents(".ui-menu").length===1&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(t){if(!this.previousFilter){var r=n(t.target).closest(".ui-menu-item"),i=n(t.currentTarget);r[0]===i[0]&&(this._removeClass(i.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(t,i))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(n,t){var i=this.active||this.element.find(this.options.items).eq(0);t||this.focus(n,i)},blur:function(t){this._delay(function(){var i=!n.contains(this.element[0],n.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(t)})},keydown:"_keydown"});this.refresh();this._on(this.document,{click:function(n){this._closeOnDocumentClick(n)&&this.collapseAll(n);this.mouseHandled=!1}})},_destroy:function(){var t=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=t.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show();i.children().each(function(){var t=n(this);t.data("ui-menu-submenu-caret")&&t.remove()})},_keydown:function(t){var i,u,r,f,e=!0;switch(t.keyCode){case n.ui.keyCode.PAGE_UP:this.previousPage(t);break;case n.ui.keyCode.PAGE_DOWN:this.nextPage(t);break;case n.ui.keyCode.HOME:this._move("first","first",t);break;case n.ui.keyCode.END:this._move("last","last",t);break;case n.ui.keyCode.UP:this.previous(t);break;case n.ui.keyCode.DOWN:this.next(t);break;case n.ui.keyCode.LEFT:this.collapse(t);break;case n.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(t);break;case n.ui.keyCode.ENTER:case n.ui.keyCode.SPACE:this._activate(t);break;case n.ui.keyCode.ESCAPE:this.collapse(t);break;default:e=!1;u=this.previousFilter||"";f=!1;r=t.keyCode>=96&&t.keyCode<=105?(t.keyCode-96).toString():String.fromCharCode(t.keyCode);clearTimeout(this.filterTimer);r===u?f=!0:r=u+r;i=this._filterMenuItems(r);i=f&&i.index(this.active.next())!==-1?this.active.nextAll(".ui-menu-item"):i;i.length||(r=String.fromCharCode(t.keyCode),i=this._filterMenuItems(r));i.length?(this.focus(t,i),this.previousFilter=r,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}e&&t.preventDefault()},_activate:function(n){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(n):this.select(n))},refresh:function(){var u,t,f,i,e,r=this,s=this.options.icons.submenu,o=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length);f=o.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var t=n(this),i=t.prev(),u=n("<span>").data("ui-menu-submenu-caret",!0);r._addClass(u,"ui-menu-icon","ui-icon "+s);i.attr("aria-haspopup","true").prepend(u);t.attr("aria-labelledby",i.attr("id"))});this._addClass(f,"ui-menu","ui-widget ui-widget-content ui-front");u=o.add(this.element);t=u.find(this.options.items);t.not(".ui-menu-item").each(function(){var t=n(this);r._isDivider(t)&&r._addClass(t,"ui-menu-divider","ui-widget-content")});i=t.not(".ui-menu-item, .ui-menu-divider");e=i.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()});this._addClass(i,"ui-menu-item")._addClass(e,"ui-menu-item-wrapper");t.filter(".ui-state-disabled").attr("aria-disabled","true");this.active&&!n.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(n,t){if(n==="icons"){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,t.submenu)}this._super(n,t)},_setOptionDisabled:function(n){this._super(n);this.element.attr("aria-disabled",String(n));this._toggleClass(null,"ui-state-disabled",!!n)},focus:function(n,t){var i,r,u;this.blur(n,n&&n.type==="focus");this._scrollIntoView(t);this.active=t.first();r=this.active.children(".ui-menu-item-wrapper");this._addClass(r,null,"ui-state-active");this.options.role&&this.element.attr("aria-activedescendant",r.attr("id"));u=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper");this._addClass(u,null,"ui-state-active");n&&n.type==="keydown"?this._close():this.timer=this._delay(function(){this._close()},this.delay);i=t.children(".ui-menu");i.length&&n&&/^mouse/.test(n.type)&&this._startOpening(i);this.activeMenu=t.parent();this._trigger("focus",n,{item:t})},_scrollIntoView:function(t){var e,o,i,r,u,f;this._hasScroll()&&(e=parseFloat(n.css(this.activeMenu[0],"borderTopWidth"))||0,o=parseFloat(n.css(this.activeMenu[0],"paddingTop"))||0,i=t.offset().top-this.activeMenu.offset().top-e-o,r=this.activeMenu.scrollTop(),u=this.activeMenu.height(),f=t.outerHeight(),i<0?this.activeMenu.scrollTop(r+i):i+f>u&&this.activeMenu.scrollTop(r+i-u+f))},blur:function(n,t){(t||clearTimeout(this.timer),this.active)&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",n,{item:this.active}),this.active=null)},_startOpening:function(n){(clearTimeout(this.timer),n.attr("aria-hidden")==="true")&&(this.timer=this._delay(function(){this._close();this._open(n)},this.delay))},_open:function(t){var i=n.extend({of:this.active},this.options.position);clearTimeout(this.timer);this.element.find(".ui-menu").not(t.parents(".ui-menu")).hide().attr("aria-hidden","true");t.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(t,i){clearTimeout(this.timer);this.timer=this._delay(function(){var r=i?this.element:n(t&&t.target).closest(this.element.find(".ui-menu"));r.length||(r=this.element);this._close(r);this.blur(t);this._removeClass(r.find(".ui-state-active"),null,"ui-state-active");this.activeMenu=r},this.delay)},_close:function(n){n||(n=this.active?this.active.parent():this.element);n.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(t){return!n(t.target).closest(".ui-menu").length},_isDivider:function(n){return!/[^\-\u2014\u2013\s]/.test(n.text())},collapse:function(n){var t=this.active&&this.active.parent().closest(".ui-menu-item",this.element);t&&t.length&&(this._close(),this.focus(n,t))},expand:function(n){var t=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();t&&t.length&&(this._open(t.parent()),this._delay(function(){this.focus(n,t)}))},next:function(n){this._move("next","first",n)},previous:function(n){this._move("prev","last",n)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(n,t,i){var r;this.active&&(r=n==="first"||n==="last"?this.active[n==="first"?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[n+"All"](".ui-menu-item").eq(0));r&&r.length&&this.active||(r=this.activeMenu.find(this.options.items)[t]());this.focus(i,r)},nextPage:function(t){var i,r,u;if(!this.active){this.next(t);return}this.isLastItem()||(this._hasScroll()?(r=this.active.offset().top,u=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=n(this),i.offset().top-r-u<0}),this.focus(t,i)):this.focus(t,this.activeMenu.find(this.options.items)[this.active?"last":"first"]()))},previousPage:function(t){var i,r,u;if(!this.active){this.next(t);return}this.isFirstItem()||(this._hasScroll()?(r=this.active.offset().top,u=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=n(this),i.offset().top-r+u>0}),this.focus(t,i)):this.focus(t,this.activeMenu.find(this.options.items).first()))},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(t){this.active=this.active||n(t.target).closest(".ui-menu-item");var i={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(t,!0);this._trigger("select",t,i)},_filterMenuItems:function(t){var i=t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),r=new RegExp("^"+i,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return r.test(n.trim(n(this).children(".ui-menu-item-wrapper").text()))})}});n.widget("ui.autocomplete",{version:"1.12.1",defaultElement:"<input>",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var t,i,r,u=this.element[0].nodeName.toLowerCase(),f=u==="textarea",e=u==="input";this.isMultiLine=f||!e&&this._isContentEditable(this.element);this.valueMethod=this.element[f||e?"val":"text"];this.isNewMenu=!0;this._addClass("ui-autocomplete-input");this.element.attr("autocomplete","off");this._on(this.element,{keydown:function(u){if(this.element.prop("readOnly")){t=!0;r=!0;i=!0;return}t=!1;r=!1;i=!1;var f=n.ui.keyCode;switch(u.keyCode){case f.PAGE_UP:t=!0;this._move("previousPage",u);break;case f.PAGE_DOWN:t=!0;this._move("nextPage",u);break;case f.UP:t=!0;this._keyEvent("previous",u);break;case f.DOWN:t=!0;this._keyEvent("next",u);break;case f.ENTER:this.menu.active&&(t=!0,u.preventDefault(),this.menu.select(u));break;case f.TAB:this.menu.active&&this.menu.select(u);break;case f.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(u),u.preventDefault());break;default:i=!0;this._searchTimeout(u)}},keypress:function(r){if(t){t=!1;(!this.isMultiLine||this.menu.element.is(":visible"))&&r.preventDefault();return}if(!i){var u=n.ui.keyCode;switch(r.keyCode){case u.PAGE_UP:this._move("previousPage",r);break;case u.PAGE_DOWN:this._move("nextPage",r);break;case u.UP:this._keyEvent("previous",r);break;case u.DOWN:this._keyEvent("next",r)}}},input:function(n){if(r){r=!1;n.preventDefault();return}this._searchTimeout(n)},focus:function(){this.selectedItem=null;this.previous=this._value()},blur:function(n){if(this.cancelBlur){delete this.cancelBlur;return}clearTimeout(this.searching);this.close(n);this._change(n)}});this._initSource();this.menu=n("<ul>").appendTo(this._appendTo()).menu({role:null}).hide().menu("instance");this._addClass(this.menu.element,"ui-autocomplete","ui-front");this._on(this.menu.element,{mousedown:function(t){t.preventDefault();this.cancelBlur=!0;this._delay(function(){delete this.cancelBlur;this.element[0]!==n.ui.safeActiveElement(this.document[0])&&this.element.trigger("focus")})},menufocus:function(t,i){var r,u;if(this.isNewMenu&&(this.isNewMenu=!1,t.originalEvent&&/^mouse/.test(t.originalEvent.type))){this.menu.blur();this.document.one("mousemove",function(){n(t.target).trigger(t.originalEvent)});return}u=i.item.data("ui-autocomplete-item");!1!==this._trigger("focus",t,{item:u})&&t.originalEvent&&/^key/.test(t.originalEvent.type)&&this._value(u.value);r=i.item.attr("aria-label")||u.value;r&&n.trim(r).length&&(this.liveRegion.children().hide(),n("<div>").text(r).appendTo(this.liveRegion))},menuselect:function(t,i){var r=i.item.data("ui-autocomplete-item"),u=this.previous;this.element[0]!==n.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=u,this._delay(function(){this.previous=u;this.selectedItem=r}));!1!==this._trigger("select",t,{item:r})&&this._value(r.value);this.term=this._value();this.close(t);this.selectedItem=r}});this.liveRegion=n("<div>",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body);this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible");this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching);this.element.removeAttr("autocomplete");this.menu.element.remove();this.liveRegion.remove()},_setOption:function(n,t){this._super(n,t);n==="source"&&this._initSource();n==="appendTo"&&this.menu.element.appendTo(this._appendTo());n==="disabled"&&t&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(t){var i=this.menu.element[0];return t.target===this.element[0]||t.target===i||n.contains(i,t.target)},_closeOnClickOutside:function(n){this._isEventTargetInWidget(n)||this.close()},_appendTo:function(){var t=this.options.appendTo;return t&&(t=t.jquery||t.nodeType?n(t):this.document.find(t).eq(0)),t&&t[0]||(t=this.element.closest(".ui-front, dialog")),t.length||(t=this.document[0].body),t},_initSource:function(){var i,r,t=this;n.isArray(this.options.source)?(i=this.options.source,this.source=function(t,r){r(n.ui.autocomplete.filter(i,t.term))}):typeof this.options.source=="string"?(r=this.options.source,this.source=function(i,u){t.xhr&&t.xhr.abort();t.xhr=n.ajax({url:r,data:i,dataType:"json",success:function(n){u(n)},error:function(){u([])}})}):this.source=this.options.source},_searchTimeout:function(n){clearTimeout(this.searching);this.searching=this._delay(function(){var t=this.term===this._value(),i=this.menu.element.is(":visible"),r=n.altKey||n.ctrlKey||n.metaKey||n.shiftKey;t&&(!t||i||r)||(this.selectedItem=null,this.search(null,n))},this.options.delay)},search:function(n,t){return(n=n!=null?n:this._value(),this.term=this._value(),n.length<this.options.minLength)?this.close(t):this._trigger("search",t)===!1?void 0:this._search(n)},_search:function(n){this.pending++;this._addClass("ui-autocomplete-loading");this.cancelSearch=!1;this.source({term:n},this._response())},_response:function(){var t=++this.requestIndex;return n.proxy(function(n){t===this.requestIndex&&this.__response(n);this.pending--;this.pending||this._removeClass("ui-autocomplete-loading")},this)},__response:function(n){n&&(n=this._normalize(n));this._trigger("response",null,{content:n});!this.options.disabled&&n&&n.length&&!this.cancelSearch?(this._suggest(n),this._trigger("open")):this._close()},close:function(n){this.cancelSearch=!0;this._close(n)},_close:function(n){this._off(this.document,"mousedown");this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",n))},_change:function(n){this.previous!==this._value()&&this._trigger("change",n,{item:this.selectedItem})},_normalize:function(t){return t.length&&t[0].label&&t[0].value?t:n.map(t,function(t){return typeof t=="string"?{label:t,value:t}:n.extend({},t,{label:t.label||t.value,value:t.value||t.label})})},_suggest:function(t){var i=this.menu.element.empty();this._renderMenu(i,t);this.isNewMenu=!0;this.menu.refresh();i.show();this._resizeMenu();i.position(n.extend({of:this.element},this.options.position));this.options.autoFocus&&this.menu.next();this._on(this.document,{mousedown:"_closeOnClickOutside"})},_resizeMenu:function(){var n=this.menu.element;n.outerWidth(Math.max(n.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(t,i){var r=this;n.each(i,function(n,i){r._renderItemData(t,i)})},_renderItemData:function(n,t){return this._renderItem(n,t).data("ui-autocomplete-item",t)},_renderItem:function(t,i){return n("<li>").append(n("<div>").text(i.label)).appendTo(t)},_move:function(n,t){if(!this.menu.element.is(":visible")){this.search(null,t);return}if(this.menu.isFirstItem()&&/^previous/.test(n)||this.menu.isLastItem()&&/^next/.test(n)){this.isMultiLine||this._value(this.term);this.menu.blur();return}this.menu[n](t)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(n,t){(!this.isMultiLine||this.menu.element.is(":visible"))&&(this._move(n,t),t.preventDefault())},_isContentEditable:function(n){if(!n.length)return!1;var t=n.prop("contentEditable");return t==="inherit"?this._isContentEditable(n.parent()):t==="true"}});n.extend(n.ui.autocomplete,{escapeRegex:function(n){return n.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(t,i){var r=new RegExp(n.ui.autocomplete.escapeRegex(i),"i");return n.grep(t,function(n){return r.test(n.label||n.value||n)})}});n.widget("ui.autocomplete",n.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(n){return n+(n>1?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(t){var i;(this._superApply(arguments),this.options.disabled||this.cancelSearch)||(i=t&&t.length?this.options.messages.results(t.length):this.options.messages.noResults,this.liveRegion.children().hide(),n("<div>").text(i).appendTo(this.liveRegion))}});w=n.ui.autocomplete;n.extend(n.ui,{datepicker:{version:"1.12.1"}});n.extend(s.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(n){return i(this._defaults,n||{}),this},_attachDatepicker:function(t,i){var r,f,u;r=t.nodeName.toLowerCase();f=r==="div"||r==="span";t.id||(this.uuid+=1,t.id="dp"+this.uuid);u=this._newInst(n(t),f);u.settings=n.extend({},i||{});r==="input"?this._connectDatepicker(t,u):f&&this._inlineDatepicker(t,u)},_newInst:function(t,i){var r=t[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:r,input:t,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:i,dpDiv:i?h(n("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'><\/div>")):this.dpDiv}},_connectDatepicker:function(t,i){var r=n(t);if(i.append=n([]),i.trigger=n([]),!r.hasClass(this.markerClassName)){this._attachments(r,i);r.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp);this._autoSize(i);n.data(t,"datepicker",i);i.settings.disabled&&this._disableDatepicker(t)}},_attachments:function(t,i){var u,r,f,e=this._get(i,"appendText"),o=this._get(i,"isRTL");if(i.append&&i.append.remove(),e&&(i.append=n("<span class='"+this._appendClass+"'>"+e+"<\/span>"),t[o?"before":"after"](i.append)),t.off("focus",this._showDatepicker),i.trigger&&i.trigger.remove(),u=this._get(i,"showOn"),u==="focus"||u==="both")t.on("focus",this._showDatepicker);if(u==="button"||u==="both"){r=this._get(i,"buttonText");f=this._get(i,"buttonImage");i.trigger=n(this._get(i,"buttonImageOnly")?n("<img/>").addClass(this._triggerClass).attr({src:f,alt:r,title:r}):n("<button type='button'><\/button>").addClass(this._triggerClass).html(f?n("<img/>").attr({src:f,alt:r,title:r}):r));t[o?"before":"after"](i.trigger);i.trigger.on("click",function(){return n.datepicker._datepickerShowing&&n.datepicker._lastInput===t[0]?n.datepicker._hideDatepicker():n.datepicker._datepickerShowing&&n.datepicker._lastInput!==t[0]?(n.datepicker._hideDatepicker(),n.datepicker._showDatepicker(t[0])):n.datepicker._showDatepicker(t[0]),!1})}},_autoSize:function(n){if(this._get(n,"autoSize")&&!n.inline){var r,u,f,t,i=new Date(2009,11,20),e=this._get(n,"dateFormat");e.match(/[DM]/)&&(r=function(n){for(u=0,f=0,t=0;t<n.length;t++)n[t].length>u&&(u=n[t].length,f=t);return f},i.setMonth(r(this._get(n,e.match(/MM/)?"monthNames":"monthNamesShort"))),i.setDate(r(this._get(n,e.match(/DD/)?"dayNames":"dayNamesShort"))+20-i.getDay()));n.input.attr("size",this._formatDate(n,i).length)}},_inlineDatepicker:function(t,i){var r=n(t);r.hasClass(this.markerClassName)||(r.addClass(this.markerClassName).append(i.dpDiv),n.data(t,"datepicker",i),this._setDate(i,this._getDefaultDate(i),!0),this._updateDatepicker(i),this._updateAlternate(i),i.settings.disabled&&this._disableDatepicker(t),i.dpDiv.css("display","block"))},_dialogDatepicker:function(t,r,u,f,e){var s,h,c,l,a,o=this._dialogInst;if(!o){this.uuid+=1;s="dp"+this.uuid;this._dialogInput=n("<input type='text' id='"+s+"' style='position: absolute; top: -100px; width: 0px;'/>");this._dialogInput.on("keydown",this._doKeyDown);n("body").append(this._dialogInput);o=this._dialogInst=this._newInst(this._dialogInput,!1);o.settings={};n.data(this._dialogInput[0],"datepicker",o)}return i(o.settings,f||{}),r=r&&r.constructor===Date?this._formatDate(o,r):r,this._dialogInput.val(r),this._pos=e?e.length?e:[e.pageX,e.pageY]:null,this._pos||(h=document.documentElement.clientWidth,c=document.documentElement.clientHeight,l=document.documentElement.scrollLeft||document.body.scrollLeft,a=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[h/2-100+l,c/2-150+a]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),o.settings.onSelect=u,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),n.blockUI&&n.blockUI(this.dpDiv),n.data(this._dialogInput[0],"datepicker",o),this},_destroyDatepicker:function(i){var r,u=n(i),f=n.data(i,"datepicker");u.hasClass(this.markerClassName)&&(r=i.nodeName.toLowerCase(),n.removeData(i,"datepicker"),r==="input"?(f.append.remove(),f.trigger.remove(),u.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):(r==="div"||r==="span")&&u.removeClass(this.markerClassName).empty(),t===f&&(t=null))},_enableDatepicker:function(t){var i,r,u=n(t),f=n.data(t,"datepicker");u.hasClass(this.markerClassName)&&(i=t.nodeName.toLowerCase(),i==="input"?(t.disabled=!1,f.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):(i==="div"||i==="span")&&(r=u.children("."+this._inlineClass),r.children().removeClass("ui-state-disabled"),r.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=n.map(this._disabledInputs,function(n){return n===t?null:n}))},_disableDatepicker:function(t){var i,r,u=n(t),f=n.data(t,"datepicker");u.hasClass(this.markerClassName)&&(i=t.nodeName.toLowerCase(),i==="input"?(t.disabled=!0,f.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):(i==="div"||i==="span")&&(r=u.children("."+this._inlineClass),r.children().addClass("ui-state-disabled"),r.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=n.map(this._disabledInputs,function(n){return n===t?null:n}),this._disabledInputs[this._disabledInputs.length]=t)},_isDisabledDatepicker:function(n){if(!n)return!1;for(var t=0;t<this._disabledInputs.length;t++)if(this._disabledInputs[t]===n)return!0;return!1},_getInst:function(t){try{return n.data(t,"datepicker")}catch(i){throw"Missing instance data for this datepicker";}},_optionDatepicker:function(t,r,u){var e,h,o,s,f=this._getInst(t);if(arguments.length===2&&typeof r=="string")return r==="defaults"?n.extend({},n.datepicker._defaults):f?r==="all"?n.extend({},f.settings):this._get(f,r):null;e=r||{};typeof r=="string"&&(e={},e[r]=u);f&&(this._curInst===f&&this._hideDatepicker(),h=this._getDateDatepicker(t,!0),o=this._getMinMaxDate(f,"min"),s=this._getMinMaxDate(f,"max"),i(f.settings,e),o!==null&&e.dateFormat!==undefined&&e.minDate===undefined&&(f.settings.minDate=this._formatDate(f,o)),s!==null&&e.dateFormat!==undefined&&e.maxDate===undefined&&(f.settings.maxDate=this._formatDate(f,s)),"disabled"in e&&(e.disabled?this._disableDatepicker(t):this._enableDatepicker(t)),this._attachments(n(t),f),this._autoSize(f),this._setDate(f,h),this._updateAlternate(f),this._updateDatepicker(f))},_changeDatepicker:function(n,t,i){this._optionDatepicker(n,t,i)},_refreshDatepicker:function(n){var t=this._getInst(n);t&&this._updateDatepicker(t)},_setDateDatepicker:function(n,t){var i=this._getInst(n);i&&(this._setDate(i,t),this._updateDatepicker(i),this._updateAlternate(i))},_getDateDatepicker:function(n,t){var i=this._getInst(n);return i&&!i.inline&&this._setDateFromField(i,t),i?this._getDate(i):null},_doKeyDown:function(t){var u,e,f,i=n.datepicker._getInst(t.target),r=!0,o=i.dpDiv.is(".ui-datepicker-rtl");if(i._keyEvent=!0,n.datepicker._datepickerShowing)switch(t.keyCode){case 9:n.datepicker._hideDatepicker();r=!1;break;case 13:return f=n("td."+n.datepicker._dayOverClass+":not(."+n.datepicker._currentClass+")",i.dpDiv),f[0]&&n.datepicker._selectDay(t.target,i.selectedMonth,i.selectedYear,f[0]),u=n.datepicker._get(i,"onSelect"),u?(e=n.datepicker._formatDate(i),u.apply(i.input?i.input[0]:null,[e,i])):n.datepicker._hideDatepicker(),!1;case 27:n.datepicker._hideDatepicker();break;case 33:n.datepicker._adjustDate(t.target,t.ctrlKey?-n.datepicker._get(i,"stepBigMonths"):-n.datepicker._get(i,"stepMonths"),"M");break;case 34:n.datepicker._adjustDate(t.target,t.ctrlKey?+n.datepicker._get(i,"stepBigMonths"):+n.datepicker._get(i,"stepMonths"),"M");break;case 35:(t.ctrlKey||t.metaKey)&&n.datepicker._clearDate(t.target);r=t.ctrlKey||t.metaKey;break;case 36:(t.ctrlKey||t.metaKey)&&n.datepicker._gotoToday(t.target);r=t.ctrlKey||t.metaKey;break;case 37:(t.ctrlKey||t.metaKey)&&n.datepicker._adjustDate(t.target,o?1:-1,"D");r=t.ctrlKey||t.metaKey;t.originalEvent.altKey&&n.datepicker._adjustDate(t.target,t.ctrlKey?-n.datepicker._get(i,"stepBigMonths"):-n.datepicker._get(i,"stepMonths"),"M");break;case 38:(t.ctrlKey||t.metaKey)&&n.datepicker._adjustDate(t.target,-7,"D");r=t.ctrlKey||t.metaKey;break;case 39:(t.ctrlKey||t.metaKey)&&n.datepicker._adjustDate(t.target,o?-1:1,"D");r=t.ctrlKey||t.metaKey;t.originalEvent.altKey&&n.datepicker._adjustDate(t.target,t.ctrlKey?+n.datepicker._get(i,"stepBigMonths"):+n.datepicker._get(i,"stepMonths"),"M");break;case 40:(t.ctrlKey||t.metaKey)&&n.datepicker._adjustDate(t.target,7,"D");r=t.ctrlKey||t.metaKey;break;default:r=!1}else t.keyCode===36&&t.ctrlKey?n.datepicker._showDatepicker(this):r=!1;r&&(t.preventDefault(),t.stopPropagation())},_doKeyPress:function(t){var i,r,u=n.datepicker._getInst(t.target);if(n.datepicker._get(u,"constrainInput"))return i=n.datepicker._possibleChars(n.datepicker._get(u,"dateFormat")),r=String.fromCharCode(t.charCode==null?t.keyCode:t.charCode),t.ctrlKey||t.metaKey||r<" "||!i||i.indexOf(r)>-1},_doKeyUp:function(t){var r,i=n.datepicker._getInst(t.target);if(i.input.val()!==i.lastVal)try{r=n.datepicker.parseDate(n.datepicker._get(i,"dateFormat"),i.input?i.input.val():null,n.datepicker._getFormatConfig(i));r&&(n.datepicker._setDateFromField(i),n.datepicker._updateAlternate(i),n.datepicker._updateDatepicker(i))}catch(u){}return!0},_showDatepicker:function(t){if(t=t.target||t,t.nodeName.toLowerCase()!=="input"&&(t=n("input",t.parentNode)[0]),!n.datepicker._isDisabledDatepicker(t)&&n.datepicker._lastInput!==t){var r,o,s,u,f,e,h;(r=n.datepicker._getInst(t),n.datepicker._curInst&&n.datepicker._curInst!==r&&(n.datepicker._curInst.dpDiv.stop(!0,!0),r&&n.datepicker._datepickerShowing&&n.datepicker._hideDatepicker(n.datepicker._curInst.input[0])),o=n.datepicker._get(r,"beforeShow"),s=o?o.apply(t,[t,r]):{},s!==!1)&&(i(r.settings,s),r.lastVal=null,n.datepicker._lastInput=t,n.datepicker._setDateFromField(r),n.datepicker._inDialog&&(t.value=""),n.datepicker._pos||(n.datepicker._pos=n.datepicker._findPos(t),n.datepicker._pos[1]+=t.offsetHeight),u=!1,n(t).parents().each(function(){return u|=n(this).css("position")==="fixed",!u}),f={left:n.datepicker._pos[0],top:n.datepicker._pos[1]},n.datepicker._pos=null,r.dpDiv.empty(),r.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),n.datepicker._updateDatepicker(r),f=n.datepicker._checkOffset(r,f,u),r.dpDiv.css({position:n.datepicker._inDialog&&n.blockUI?"static":u?"fixed":"absolute",display:"none",left:f.left+"px",top:f.top+"px"}),r.inline||(e=n.datepicker._get(r,"showAnim"),h=n.datepicker._get(r,"duration"),r.dpDiv.css("z-index",b(n(t))+1),n.datepicker._datepickerShowing=!0,n.effects&&n.effects.effect[e]?r.dpDiv.show(e,n.datepicker._get(r,"showOptions"),h):r.dpDiv[e||"show"](e?h:null),n.datepicker._shouldFocusInput(r)&&r.input.trigger("focus"),n.datepicker._curInst=r))}},_updateDatepicker:function(i){this.maxRows=4;t=i;i.dpDiv.empty().append(this._generateHTML(i));this._attachHandlers(i);var r,u=this._getNumberOfMonths(i),f=u[1],e=i.dpDiv.find("."+this._dayOverClass+" a");e.length>0&&c.apply(e.get(0));i.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width("");f>1&&i.dpDiv.addClass("ui-datepicker-multi-"+f).css("width",17*f+"em");i.dpDiv[(u[0]!==1||u[1]!==1?"add":"remove")+"Class"]("ui-datepicker-multi");i.dpDiv[(this._get(i,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl");i===n.datepicker._curInst&&n.datepicker._datepickerShowing&&n.datepicker._shouldFocusInput(i)&&i.input.trigger("focus");i.yearshtml&&(r=i.yearshtml,setTimeout(function(){r===i.yearshtml&&i.yearshtml&&i.dpDiv.find("select.ui-datepicker-year:first").replaceWith(i.yearshtml);r=i.yearshtml=null},0))},_shouldFocusInput:function(n){return n.input&&n.input.is(":visible")&&!n.input.is(":disabled")&&!n.input.is(":focus")},_checkOffset:function(t,i,r){var u=t.dpDiv.outerWidth(),f=t.dpDiv.outerHeight(),h=t.input?t.input.outerWidth():0,o=t.input?t.input.outerHeight():0,e=document.documentElement.clientWidth+(r?0:n(document).scrollLeft()),s=document.documentElement.clientHeight+(r?0:n(document).scrollTop());return i.left-=this._get(t,"isRTL")?u-h:0,i.left-=r&&i.left===t.input.offset().left?n(document).scrollLeft():0,i.top-=r&&i.top===t.input.offset().top+o?n(document).scrollTop():0,i.left-=Math.min(i.left,i.left+u>e&&e>u?Math.abs(i.left+u-e):0),i.top-=Math.min(i.top,i.top+f>s&&s>f?Math.abs(f+o):0),i},_findPos:function(t){for(var i,r=this._getInst(t),u=this._get(r,"isRTL");t&&(t.type==="hidden"||t.nodeType!==1||n.expr.filters.hidden(t));)t=t[u?"previousSibling":"nextSibling"];return i=n(t).offset(),[i.left,i.top]},_hideDatepicker:function(t){var r,f,u,e,i=this._curInst;i&&(!t||i===n.data(t,"datepicker"))&&this._datepickerShowing&&(r=this._get(i,"showAnim"),f=this._get(i,"duration"),u=function(){n.datepicker._tidyDialog(i)},n.effects&&(n.effects.effect[r]||n.effects[r])?i.dpDiv.hide(r,n.datepicker._get(i,"showOptions"),f,u):i.dpDiv[r==="slideDown"?"slideUp":r==="fadeIn"?"fadeOut":"hide"](r?f:null,u),r||u(),this._datepickerShowing=!1,e=this._get(i,"onClose"),e&&e.apply(i.input?i.input[0]:null,[i.input?i.input.val():"",i]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),n.blockUI&&(n.unblockUI(),n("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(n){n.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(t){if(n.datepicker._curInst){var i=n(t.target),r=n.datepicker._getInst(i[0]);(i[0].id===n.datepicker._mainDivId||i.parents("#"+n.datepicker._mainDivId).length!==0||i.hasClass(n.datepicker.markerClassName)||i.closest("."+n.datepicker._triggerClass).length||!n.datepicker._datepickerShowing||n.datepicker._inDialog&&n.blockUI)&&(!i.hasClass(n.datepicker.markerClassName)||n.datepicker._curInst===r)||n.datepicker._hideDatepicker()}},_adjustDate:function(t,i,r){var f=n(t),u=this._getInst(f[0]);this._isDisabledDatepicker(f[0])||(this._adjustInstDate(u,i+(r==="M"?this._get(u,"showCurrentAtPos"):0),r),this._updateDatepicker(u))},_gotoToday:function(t){var r,u=n(t),i=this._getInst(u[0]);this._get(i,"gotoCurrent")&&i.currentDay?(i.selectedDay=i.currentDay,i.drawMonth=i.selectedMonth=i.currentMonth,i.drawYear=i.selectedYear=i.currentYear):(r=new Date,i.selectedDay=r.getDate(),i.drawMonth=i.selectedMonth=r.getMonth(),i.drawYear=i.selectedYear=r.getFullYear());this._notifyChange(i);this._adjustDate(u)},_selectMonthYear:function(t,i,r){var f=n(t),u=this._getInst(f[0]);u["selected"+(r==="M"?"Month":"Year")]=u["draw"+(r==="M"?"Month":"Year")]=parseInt(i.options[i.selectedIndex].value,10);this._notifyChange(u);this._adjustDate(f)},_selectDay:function(t,i,r,u){var f,e=n(t);n(u).hasClass(this._unselectableClass)||this._isDisabledDatepicker(e[0])||(f=this._getInst(e[0]),f.selectedDay=f.currentDay=n("a",u).html(),f.selectedMonth=f.currentMonth=i,f.selectedYear=f.currentYear=r,this._selectDate(t,this._formatDate(f,f.currentDay,f.currentMonth,f.currentYear)))},_clearDate:function(t){var i=n(t);this._selectDate(i,"")},_selectDate:function(t,i){var u,f=n(t),r=this._getInst(f[0]);i=i!=null?i:this._formatDate(r);r.input&&r.input.val(i);this._updateAlternate(r);u=this._get(r,"onSelect");u?u.apply(r.input?r.input[0]:null,[i,r]):r.input&&r.input.trigger("change");r.inline?this._updateDatepicker(r):(this._hideDatepicker(),this._lastInput=r.input[0],typeof r.input[0]!="object"&&r.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(t){var i,r,u,f=this._get(t,"altField");f&&(i=this._get(t,"altFormat")||this._get(t,"dateFormat"),r=this._getDate(t),u=this.formatDate(i,r,this._getFormatConfig(t)),n(f).val(u))},noWeekends:function(n){var t=n.getDay();return[t>0&&t<6,""]},iso8601Week:function(n){var i,t=new Date(n.getTime());return t.setDate(t.getDate()+4-(t.getDay()||7)),i=t.getTime(),t.setMonth(0),t.setDate(1),Math.floor(Math.round((i-t)/864e5)/7)+1},parseDate:function(t,i,r){if(t==null||i==null)throw"Invalid arguments";if(i=typeof i=="object"?i.toString():i+"",i==="")return null;for(var a,v,f=0,y=(r?r.shortYearCutoff:null)||this._defaults.shortYearCutoff,d=typeof y!="string"?y:(new Date).getFullYear()%100+parseInt(y,10),g=(r?r.dayNamesShort:null)||this._defaults.dayNamesShort,nt=(r?r.dayNames:null)||this._defaults.dayNames,tt=(r?r.monthNamesShort:null)||this._defaults.monthNamesShort,it=(r?r.monthNames:null)||this._defaults.monthNames,e=-1,s=-1,h=-1,p=-1,w=!1,u,l=function(n){var i=o+1<t.length&&t.charAt(o+1)===n;return i&&o++,i},c=function(n){var u=l(n),r=n==="@"?14:n==="!"?20:n==="y"&&u?4:n==="o"?3:2,e=n==="y"?r:1,o=new RegExp("^\\d{"+e+","+r+"}"),t=i.substring(f).match(o);if(!t)throw"Missing number at position "+f;return f+=t[0].length,parseInt(t[0],10)},k=function(t,r,u){var e=-1,o=n.map(l(t)?u:r,function(n,t){return[[t,n]]}).sort(function(n,t){return-(n[1].length-t[1].length)});if(n.each(o,function(n,t){var r=t[1];if(i.substr(f,r.length).toLowerCase()===r.toLowerCase())return e=t[0],f+=r.length,!1}),e!==-1)return e+1;throw"Unknown name at position "+f;},b=function(){if(i.charAt(f)!==t.charAt(o))throw"Unexpected literal at position "+f;f++},o=0;o<t.length;o++)if(w)t.charAt(o)!=="'"||l("'")?b():w=!1;else switch(t.charAt(o)){case"d":h=c("d");break;case"D":k("D",g,nt);break;case"o":p=c("o");break;case"m":s=c("m");break;case"M":s=k("M",tt,it);break;case"y":e=c("y");break;case"@":u=new Date(c("@"));e=u.getFullYear();s=u.getMonth()+1;h=u.getDate();break;case"!":u=new Date((c("!")-this._ticksTo1970)/1e4);e=u.getFullYear();s=u.getMonth()+1;h=u.getDate();break;case"'":l("'")?b():w=!0;break;default:b()}if(f<i.length&&(v=i.substr(f),!/^\s+/.test(v)))throw"Extra/unparsed characters found in date: "+v;if(e===-1?e=(new Date).getFullYear():e<100&&(e+=(new Date).getFullYear()-(new Date).getFullYear()%100+(e<=d?0:-100)),p>-1){s=1;h=p;do{if(a=this._getDaysInMonth(e,s-1),h<=a)break;s++;h-=a}while(1)}if(u=this._daylightSavingAdjust(new Date(e,s-1,h)),u.getFullYear()!==e||u.getMonth()+1!==s||u.getDate()!==h)throw"Invalid date";return u},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:(718685+Math.floor(1970/4)-Math.floor(1970/100)+Math.floor(1970/400))*864e9,formatDate:function(n,t,i){if(!t)return"";var u,h=(i?i.dayNamesShort:null)||this._defaults.dayNamesShort,c=(i?i.dayNames:null)||this._defaults.dayNames,l=(i?i.monthNamesShort:null)||this._defaults.monthNamesShort,a=(i?i.monthNames:null)||this._defaults.monthNames,f=function(t){var i=u+1<n.length&&n.charAt(u+1)===t;return i&&u++,i},e=function(n,t,i){var r=""+t;if(f(n))while(r.length<i)r="0"+r;return r},s=function(n,t,i,r){return f(n)?r[t]:i[t]},r="",o=!1;if(t)for(u=0;u<n.length;u++)if(o)n.charAt(u)!=="'"||f("'")?r+=n.charAt(u):o=!1;else switch(n.charAt(u)){case"d":r+=e("d",t.getDate(),2);break;case"D":r+=s("D",t.getDay(),h,c);break;case"o":r+=e("o",Math.round((new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()-new Date(t.getFullYear(),0,0).getTime())/864e5),3);break;case"m":r+=e("m",t.getMonth()+1,2);break;case"M":r+=s("M",t.getMonth(),l,a);break;case"y":r+=f("y")?t.getFullYear():(t.getFullYear()%100<10?"0":"")+t.getFullYear()%100;break;case"@":r+=t.getTime();break;case"!":r+=t.getTime()*1e4+this._ticksTo1970;break;case"'":f("'")?r+="'":o=!0;break;default:r+=n.charAt(u)}return r},_possibleChars:function(n){for(var i="",r=!1,u=function(i){var r=t+1<n.length&&n.charAt(t+1)===i;return r&&t++,r},t=0;t<n.length;t++)if(r)n.charAt(t)!=="'"||u("'")?i+=n.charAt(t):r=!1;else switch(n.charAt(t)){case"d":case"m":case"y":case"@":i+="0123456789";break;case"D":case"M":return null;case"'":u("'")?i+="'":r=!0;break;default:i+=n.charAt(t)}return i},_get:function(n,t){return n.settings[t]!==undefined?n.settings[t]:this._defaults[t]},_setDateFromField:function(n,t){if(n.input.val()!==n.lastVal){var f=this._get(n,"dateFormat"),r=n.lastVal=n.input?n.input.val():null,u=this._getDefaultDate(n),i=u,e=this._getFormatConfig(n);try{i=this.parseDate(f,r,e)||u}catch(o){r=t?"":r}n.selectedDay=i.getDate();n.drawMonth=n.selectedMonth=i.getMonth();n.drawYear=n.selectedYear=i.getFullYear();n.currentDay=r?i.getDate():0;n.currentMonth=r?i.getMonth():0;n.currentYear=r?i.getFullYear():0;this._adjustInstDate(n)}},_getDefaultDate:function(n){return this._restrictMinMax(n,this._determineDate(n,this._get(n,"defaultDate"),new Date))},_determineDate:function(t,i,r){var f=function(n){var t=new Date;return t.setDate(t.getDate()+n),t},e=function(i){try{return n.datepicker.parseDate(n.datepicker._get(t,"dateFormat"),i,n.datepicker._getFormatConfig(t))}catch(h){}for(var o=(i.toLowerCase().match(/^c/)?n.datepicker._getDate(t):null)||new Date,f=o.getFullYear(),e=o.getMonth(),r=o.getDate(),s=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,u=s.exec(i);u;){switch(u[2]||"d"){case"d":case"D":r+=parseInt(u[1],10);break;case"w":case"W":r+=parseInt(u[1],10)*7;break;case"m":case"M":e+=parseInt(u[1],10);r=Math.min(r,n.datepicker._getDaysInMonth(f,e));break;case"y":case"Y":f+=parseInt(u[1],10);r=Math.min(r,n.datepicker._getDaysInMonth(f,e))}u=s.exec(i)}return new Date(f,e,r)},u=i==null||i===""?r:typeof i=="string"?e(i):typeof i=="number"?isNaN(i)?r:f(i):new Date(i.getTime());return u=u&&u.toString()==="Invalid Date"?r:u,u&&(u.setHours(0),u.setMinutes(0),u.setSeconds(0),u.setMilliseconds(0)),this._daylightSavingAdjust(u)},_daylightSavingAdjust:function(n){return n?(n.setHours(n.getHours()>12?n.getHours()+2:0),n):null},_setDate:function(n,t,i){var u=!t,f=n.selectedMonth,e=n.selectedYear,r=this._restrictMinMax(n,this._determineDate(n,t,new Date));n.selectedDay=n.currentDay=r.getDate();n.drawMonth=n.selectedMonth=n.currentMonth=r.getMonth();n.drawYear=n.selectedYear=n.currentYear=r.getFullYear();f===n.selectedMonth&&e===n.selectedYear||i||this._notifyChange(n);this._adjustInstDate(n);n.input&&n.input.val(u?"":this._formatDate(n))},_getDate:function(n){return!n.currentYear||n.input&&n.input.val()===""?null:this._daylightSavingAdjust(new Date(n.currentYear,n.currentMonth,n.currentDay))},_attachHandlers:function(t){var r=this._get(t,"stepMonths"),i="#"+t.id.replace(/\\\\/g,"\\");t.dpDiv.find("[data-handler]").map(function(){var t={prev:function(){n.datepicker._adjustDate(i,-r,"M")},next:function(){n.datepicker._adjustDate(i,+r,"M")},hide:function(){n.datepicker._hideDatepicker()},today:function(){n.datepicker._gotoToday(i)},selectDay:function(){return n.datepicker._selectDay(i,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return n.datepicker._selectMonthYear(i,this,"M"),!1},selectYear:function(){return n.datepicker._selectMonthYear(i,this,"Y"),!1}};n(this).on(this.getAttribute("data-event"),t[this.getAttribute("data-handler")])})},_generateHTML:function(n){var b,s,rt,h,ut,k,ft,et,ri,c,ot,ui,fi,ei,oi,st,g,si,ht,nt,o,y,ct,p,lt,l,u,at,vt,yt,pt,tt,wt,i,bt,kt,d,a,it,dt=new Date,gt=this._daylightSavingAdjust(new Date(dt.getFullYear(),dt.getMonth(),dt.getDate())),f=this._get(n,"isRTL"),li=this._get(n,"showButtonPanel"),hi=this._get(n,"hideIfNoPrevNext"),ni=this._get(n,"navigationAsDateFormat"),e=this._getNumberOfMonths(n),ai=this._get(n,"showCurrentAtPos"),ci=this._get(n,"stepMonths"),ti=e[0]!==1||e[1]!==1,ii=this._daylightSavingAdjust(n.currentDay?new Date(n.currentYear,n.currentMonth,n.currentDay):new Date(9999,9,9)),w=this._getMinMaxDate(n,"min"),v=this._getMinMaxDate(n,"max"),t=n.drawMonth-ai,r=n.drawYear;if(t<0&&(t+=12,r--),v)for(b=this._daylightSavingAdjust(new Date(v.getFullYear(),v.getMonth()-e[0]*e[1]+1,v.getDate())),b=w&&b<w?w:b;this._daylightSavingAdjust(new Date(r,t,1))>b;)t--,t<0&&(t=11,r--);for(n.drawMonth=t,n.drawYear=r,s=this._get(n,"prevText"),s=ni?this.formatDate(s,this._daylightSavingAdjust(new Date(r,t-ci,1)),this._getFormatConfig(n)):s,rt=this._canAdjustMonth(n,-1,r,t)?"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='"+s+"'><span class='ui-icon ui-icon-circle-triangle-"+(f?"e":"w")+"'>"+s+"<\/span><\/a>":hi?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+s+"'><span class='ui-icon ui-icon-circle-triangle-"+(f?"e":"w")+"'>"+s+"<\/span><\/a>",h=this._get(n,"nextText"),h=ni?this.formatDate(h,this._daylightSavingAdjust(new Date(r,t+ci,1)),this._getFormatConfig(n)):h,ut=this._canAdjustMonth(n,1,r,t)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+h+"'><span class='ui-icon ui-icon-circle-triangle-"+(f?"w":"e")+"'>"+h+"<\/span><\/a>":hi?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+h+"'><span class='ui-icon ui-icon-circle-triangle-"+(f?"w":"e")+"'>"+h+"<\/span><\/a>",k=this._get(n,"currentText"),ft=this._get(n,"gotoCurrent")&&n.currentDay?ii:gt,k=ni?this.formatDate(k,ft,this._getFormatConfig(n)):k,et=n.inline?"":"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>"+this._get(n,"closeText")+"<\/button>",ri=li?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(f?et:"")+(this._isInRange(n,ft)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+k+"<\/button>":"")+(f?"":et)+"<\/div>":"",c=parseInt(this._get(n,"firstDay"),10),c=isNaN(c)?0:c,ot=this._get(n,"showWeek"),ui=this._get(n,"dayNames"),fi=this._get(n,"dayNamesMin"),ei=this._get(n,"monthNames"),oi=this._get(n,"monthNamesShort"),st=this._get(n,"beforeShowDay"),g=this._get(n,"showOtherMonths"),si=this._get(n,"selectOtherMonths"),ht=this._getDefaultDate(n),nt="",y=0;y<e[0];y++){for(ct="",this.maxRows=4,p=0;p<e[1];p++){if(lt=this._daylightSavingAdjust(new Date(r,t,n.selectedDay)),l=" ui-corner-all",u="",ti){if(u+="<div class='ui-datepicker-group",e[1]>1)switch(p){case 0:u+=" ui-datepicker-group-first";l=" ui-corner-"+(f?"right":"left");break;case e[1]-1:u+=" ui-datepicker-group-last";l=" ui-corner-"+(f?"left":"right");break;default:u+=" ui-datepicker-group-middle";l=""}u+="'>"}for(u+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+l+"'>"+(/all|left/.test(l)&&y===0?f?ut:rt:"")+(/all|right/.test(l)&&y===0?f?rt:ut:"")+this._generateMonthYearHeader(n,t,r,w,v,y>0||p>0,ei,oi)+"<\/div><table class='ui-datepicker-calendar'><thead><tr>",at=ot?"<th class='ui-datepicker-week-col'>"+this._get(n,"weekHeader")+"<\/th>":"",o=0;o<7;o++)vt=(o+c)%7,at+="<th scope='col'"+((o+c+6)%7>=5?" class='ui-datepicker-week-end'":"")+"><span title='"+ui[vt]+"'>"+fi[vt]+"<\/span><\/th>";for(u+=at+"<\/tr><\/thead><tbody>",yt=this._getDaysInMonth(r,t),r===n.selectedYear&&t===n.selectedMonth&&(n.selectedDay=Math.min(n.selectedDay,yt)),pt=(this._getFirstDayOfMonth(r,t)-c+7)%7,tt=Math.ceil((pt+yt)/7),wt=ti?this.maxRows>tt?this.maxRows:tt:tt,this.maxRows=wt,i=this._daylightSavingAdjust(new Date(r,t,1-pt)),bt=0;bt<wt;bt++){for(u+="<tr>",kt=ot?"<td class='ui-datepicker-week-col'>"+this._get(n,"calculateWeek")(i)+"<\/td>":"",o=0;o<7;o++)d=st?st.apply(n.input?n.input[0]:null,[i]):[!0,""],a=i.getMonth()!==t,it=a&&!si||!d[0]||w&&i<w||v&&i>v,kt+="<td class='"+((o+c+6)%7>=5?" ui-datepicker-week-end":"")+(a?" ui-datepicker-other-month":"")+(i.getTime()===lt.getTime()&&t===n.selectedMonth&&n._keyEvent||ht.getTime()===i.getTime()&&ht.getTime()===lt.getTime()?" "+this._dayOverClass:"")+(it?" "+this._unselectableClass+" ui-state-disabled":"")+(a&&!g?"":" "+d[1]+(i.getTime()===ii.getTime()?" "+this._currentClass:"")+(i.getTime()===gt.getTime()?" ui-datepicker-today":""))+"'"+((!a||g)&&d[2]?" title='"+d[2].replace(/'/g,"&#39;")+"'":"")+(it?"":" data-handler='selectDay' data-event='click' data-month='"+i.getMonth()+"' data-year='"+i.getFullYear()+"'")+">"+(a&&!g?"&#xa0;":it?"<span class='ui-state-default'>"+i.getDate()+"<\/span>":"<a class='ui-state-default"+(i.getTime()===gt.getTime()?" ui-state-highlight":"")+(i.getTime()===ii.getTime()?" ui-state-active":"")+(a?" ui-priority-secondary":"")+"' href='#'>"+i.getDate()+"<\/a>")+"<\/td>",i.setDate(i.getDate()+1),i=this._daylightSavingAdjust(i);u+=kt+"<\/tr>"}t++;t>11&&(t=0,r++);u+="<\/tbody><\/table>"+(ti?"<\/div>"+(e[0]>0&&p===e[1]-1?"<div class='ui-datepicker-row-break'><\/div>":""):"");ct+=u}nt+=ct}return nt+=ri,n._keyEvent=!1,nt},_generateMonthYearHeader:function(n,t,i,r,u,f,e,o){var k,d,h,v,y,p,s,a,w=this._get(n,"changeMonth"),b=this._get(n,"changeYear"),g=this._get(n,"showMonthAfterYear"),c="<div class='ui-datepicker-title'>",l="";if(f||!w)l+="<span class='ui-datepicker-month'>"+e[t]+"<\/span>";else{for(k=r&&r.getFullYear()===i,d=u&&u.getFullYear()===i,l+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",h=0;h<12;h++)(!k||h>=r.getMonth())&&(!d||h<=u.getMonth())&&(l+="<option value='"+h+"'"+(h===t?" selected='selected'":"")+">"+o[h]+"<\/option>");l+="<\/select>"}if(g||(c+=l+(f||!(w&&b)?"&#xa0;":"")),!n.yearshtml)if(n.yearshtml="",f||!b)c+="<span class='ui-datepicker-year'>"+i+"<\/span>";else{for(v=this._get(n,"yearRange").split(":"),y=(new Date).getFullYear(),p=function(n){var t=n.match(/c[+\-].*/)?i+parseInt(n.substring(1),10):n.match(/[+\-].*/)?y+parseInt(n,10):parseInt(n,10);return isNaN(t)?y:t},s=p(v[0]),a=Math.max(s,p(v[1]||"")),s=r?Math.max(s,r.getFullYear()):s,a=u?Math.min(a,u.getFullYear()):a,n.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";s<=a;s++)n.yearshtml+="<option value='"+s+"'"+(s===i?" selected='selected'":"")+">"+s+"<\/option>";n.yearshtml+="<\/select>";c+=n.yearshtml;n.yearshtml=null}return c+=this._get(n,"yearSuffix"),g&&(c+=(f||!(w&&b)?"&#xa0;":"")+l),c+"<\/div>"},_adjustInstDate:function(n,t,i){var u=n.selectedYear+(i==="Y"?t:0),f=n.selectedMonth+(i==="M"?t:0),e=Math.min(n.selectedDay,this._getDaysInMonth(u,f))+(i==="D"?t:0),r=this._restrictMinMax(n,this._daylightSavingAdjust(new Date(u,f,e)));n.selectedDay=r.getDate();n.drawMonth=n.selectedMonth=r.getMonth();n.drawYear=n.selectedYear=r.getFullYear();(i==="M"||i==="Y")&&this._notifyChange(n)},_restrictMinMax:function(n,t){var i=this._getMinMaxDate(n,"min"),r=this._getMinMaxDate(n,"max"),u=i&&t<i?i:t;return r&&u>r?r:u},_notifyChange:function(n){var t=this._get(n,"onChangeMonthYear");t&&t.apply(n.input?n.input[0]:null,[n.selectedYear,n.selectedMonth+1,n])},_getNumberOfMonths:function(n){var t=this._get(n,"numberOfMonths");return t==null?[1,1]:typeof t=="number"?[1,t]:t},_getMinMaxDate:function(n,t){return this._determineDate(n,this._get(n,t+"Date"),null)},_getDaysInMonth:function(n,t){return 32-this._daylightSavingAdjust(new Date(n,t,32)).getDate()},_getFirstDayOfMonth:function(n,t){return new Date(n,t,1).getDay()},_canAdjustMonth:function(n,t,i,r){var f=this._getNumberOfMonths(n),u=this._daylightSavingAdjust(new Date(i,r+(t<0?t:f[0]*f[1]),1));return t<0&&u.setDate(this._getDaysInMonth(u.getFullYear(),u.getMonth())),this._isInRange(n,u)},_isInRange:function(n,t){var i,f,e=this._getMinMaxDate(n,"min"),o=this._getMinMaxDate(n,"max"),r=null,u=null,s=this._get(n,"yearRange");return s&&(i=s.split(":"),f=(new Date).getFullYear(),r=parseInt(i[0],10),u=parseInt(i[1],10),i[0].match(/[+\-].*/)&&(r+=f),i[1].match(/[+\-].*/)&&(u+=f)),(!e||t.getTime()>=e.getTime())&&(!o||t.getTime()<=o.getTime())&&(!r||t.getFullYear()>=r)&&(!u||t.getFullYear()<=u)},_getFormatConfig:function(n){var t=this._get(n,"shortYearCutoff");return t=typeof t!="string"?t:(new Date).getFullYear()%100+parseInt(t,10),{shortYearCutoff:t,dayNamesShort:this._get(n,"dayNamesShort"),dayNames:this._get(n,"dayNames"),monthNamesShort:this._get(n,"monthNamesShort"),monthNames:this._get(n,"monthNames")}},_formatDate:function(n,t,i,r){t||(n.currentDay=n.selectedDay,n.currentMonth=n.selectedMonth,n.currentYear=n.selectedYear);var u=t?typeof t=="object"?t:this._daylightSavingAdjust(new Date(r,i,t)):this._daylightSavingAdjust(new Date(n.currentYear,n.currentMonth,n.currentDay));return this.formatDate(this._get(n,"dateFormat"),u,this._getFormatConfig(n))}});n.fn.datepicker=function(t){if(!this.length)return this;if(!n.datepicker.initialized){n(document).on("mousedown",n.datepicker._checkExternalClick);n.datepicker.initialized=!0}n("#"+n.datepicker._mainDivId).length===0&&n("body").append(n.datepicker.dpDiv);var i=Array.prototype.slice.call(arguments,1);return typeof t=="string"&&(t==="isDisabled"||t==="getDate"||t==="widget")?n.datepicker["_"+t+"Datepicker"].apply(n.datepicker,[this[0]].concat(i)):t==="option"&&arguments.length===2&&typeof arguments[1]=="string"?n.datepicker["_"+t+"Datepicker"].apply(n.datepicker,[this[0]].concat(i)):this.each(function(){typeof t=="string"?n.datepicker["_"+t+"Datepicker"].apply(n.datepicker,[this].concat(i)):n.datepicker._attachDatepicker(this,t)})};n.datepicker=new s;n.datepicker.initialized=!1;n.datepicker.uuid=(new Date).getTime();n.datepicker.version="1.12.1";var vt=n.datepicker,yt=n.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase()),r=!1;n(document).on("mouseup",function(){r=!1});var pt=n.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var t=this;this.element.on("mousedown."+this.widgetName,function(n){return t._mouseDown(n)}).on("click."+this.widgetName,function(i){if(!0===n.data(i.target,t.widgetName+".preventClickEvent"))return n.removeData(i.target,t.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1});this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName);this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(t){if(!r){this._mouseMoved=!1;this._mouseStarted&&this._mouseUp(t);this._mouseDownEvent=t;var i=this,u=t.which===1,f=typeof this.options.cancel=="string"&&t.target.nodeName?n(t.target).closest(this.options.cancel).length:!1;if(!u||f||!this._mouseCapture(t))return!0;if(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(t)&&this._mouseDelayMet(t)&&(this._mouseStarted=this._mouseStart(t)!==!1,!this._mouseStarted))return t.preventDefault(),!0;!0===n.data(t.target,this.widgetName+".preventClickEvent")&&n.removeData(t.target,this.widgetName+".preventClickEvent");this._mouseMoveDelegate=function(n){return i._mouseMove(n)};this._mouseUpDelegate=function(n){return i._mouseUp(n)};this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate);return t.preventDefault(),r=!0,!0}},_mouseMove:function(t){if(this._mouseMoved){if(n.ui.ie&&(!document.documentMode||document.documentMode<9)&&!t.button)return this._mouseUp(t);if(!t.which)if(t.originalEvent.altKey||t.originalEvent.ctrlKey||t.originalEvent.metaKey||t.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(t)}return((t.which||t.button)&&(this._mouseMoved=!0),this._mouseStarted)?(this._mouseDrag(t),t.preventDefault()):(this._mouseDistanceMet(t)&&this._mouseDelayMet(t)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,t)!==!1,this._mouseStarted?this._mouseDrag(t):this._mouseUp(t)),!this._mouseStarted)},_mouseUp:function(t){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate);this._mouseStarted&&(this._mouseStarted=!1,t.target===this._mouseDownEvent.target&&n.data(t.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(t));this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer);this.ignoreMissingWhich=!1;r=!1;t.preventDefault()},_mouseDistanceMet:function(n){return Math.max(Math.abs(this._mouseDownEvent.pageX-n.pageX),Math.abs(this._mouseDownEvent.pageY-n.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),wt=n.widget("ui.progressbar",{version:"1.12.1",options:{classes:{"ui-progressbar":"ui-corner-all","ui-progressbar-value":"ui-corner-left","ui-progressbar-complete":"ui-corner-right"},max:100,value:0,change:null,complete:null},min:0,_create:function(){this.oldValue=this.options.value=this._constrainedValue();this.element.attr({role:"progressbar","aria-valuemin":this.min});this._addClass("ui-progressbar","ui-widget ui-widget-content");this.valueDiv=n("<div>").appendTo(this.element);this._addClass(this.valueDiv,"ui-progressbar-value","ui-widget-header");this._refreshValue()},_destroy:function(){this.element.removeAttr("role aria-valuemin aria-valuemax aria-valuenow");this.valueDiv.remove()},value:function(n){if(n===undefined)return this.options.value;this.options.value=this._constrainedValue(n);this._refreshValue()},_constrainedValue:function(n){return n===undefined&&(n=this.options.value),this.indeterminate=n===!1,typeof n!="number"&&(n=0),this.indeterminate?!1:Math.min(this.options.max,Math.max(this.min,n))},_setOptions:function(n){var t=n.value;delete n.value;this._super(n);this.options.value=this._constrainedValue(t);this._refreshValue()},_setOption:function(n,t){n==="max"&&(t=Math.max(this.min,t));this._super(n,t)},_setOptionDisabled:function(n){this._super(n);this.element.attr("aria-disabled",n);this._toggleClass(null,"ui-state-disabled",!!n)},_percentage:function(){return this.indeterminate?100:100*(this.options.value-this.min)/(this.options.max-this.min)},_refreshValue:function(){var t=this.options.value,i=this._percentage();this.valueDiv.toggle(this.indeterminate||t>this.min).width(i.toFixed(0)+"%");this._toggleClass(this.valueDiv,"ui-progressbar-complete",null,t===this.options.max)._toggleClass("ui-progressbar-indeterminate",null,this.indeterminate);this.indeterminate?(this.element.removeAttr("aria-valuenow"),this.overlayDiv||(this.overlayDiv=n("<div>").appendTo(this.valueDiv),this._addClass(this.overlayDiv,"ui-progressbar-overlay"))):(this.element.attr({"aria-valuemax":this.options.max,"aria-valuenow":t}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null));this.oldValue!==t&&(this.oldValue=t,this._trigger("change"));t===this.options.max&&this._trigger("complete")}}),u="ui-effects-",f="ui-effects-style",e="ui-effects-animated",l=n;n.effects={effect:{}},function(n,t){function e(n,t,i){var r=s[t.type]||{};return n==null?i||!t.def?null:t.def:(n=r.floor?~~n:parseFloat(n),isNaN(n))?t.def:r.mod?(n+r.mod)%r.mod:0>n?0:r.max<n?r.max:n}function l(t){var e=i(),o=e._rgba=[];return(t=t.toLowerCase(),r(v,function(n,i){var r,s=i.re.exec(t),h=s&&i.parse(s),f=i.space||"rgba";if(h)return r=e[f](h),e[u[f].cache]=r[u[f].cache],o=e._rgba=r._rgba,!1}),o.length)?(o.join()==="0,0,0,0"&&n.extend(o,f.transparent),e):f[t]}function o(n,t,i){return(i=(i+1)%1,i*6<1)?n+(t-n)*i*6:i*2<1?t:i*3<2?n+(t-n)*(2/3-i)*6:n}var a=/^([\-+])=\s*(\d+\.?\d*)/,v=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(n){return[n[1],n[2],n[3],n[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(n){return[n[1]*2.55,n[2]*2.55,n[3]*2.55,n[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(n){return[parseInt(n[1],16),parseInt(n[2],16),parseInt(n[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(n){return[parseInt(n[1]+n[1],16),parseInt(n[2]+n[2],16),parseInt(n[3]+n[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(n){return[n[1],n[2]/100,n[3]/100,n[4]]}}],i=n.Color=function(t,i,r,u){return new n.Color.fn.parse(t,i,r,u)},u={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},s={byte:{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},h=i.support={},c=n("<p>")[0],f,r=n.each;c.style.cssText="background-color:rgba(1,1,1,.5)";h.rgba=c.style.backgroundColor.indexOf("rgba")>-1;r(u,function(n,t){t.cache="_"+n;t.props.alpha={idx:3,type:"percent",def:1}});i.fn=n.extend(i.prototype,{parse:function(o,s,h,c){if(o===t)return this._rgba=[null,null,null,null],this;(o.jquery||o.nodeType)&&(o=n(o).css(s),s=t);var a=this,v=n.type(o),y=this._rgba=[];return(s!==t&&(o=[o,s,h,c],v="array"),v==="string")?this.parse(l(o)||f._default):v==="array"?(r(u.rgba.props,function(n,t){y[t.idx]=e(o[t.idx],t)}),this):v==="object"?(o instanceof i?r(u,function(n,t){o[t.cache]&&(a[t.cache]=o[t.cache].slice())}):r(u,function(t,i){var u=i.cache;r(i.props,function(n,t){if(!a[u]&&i.to){if(n==="alpha"||o[n]==null)return;a[u]=i.to(a._rgba)}a[u][t.idx]=e(o[n],t,!0)});a[u]&&n.inArray(null,a[u].slice(0,3))<0&&(a[u][3]=1,i.from&&(a._rgba=i.from(a[u])))}),this):void 0},is:function(n){var e=i(n),t=!0,f=this;return r(u,function(n,i){var o,u=e[i.cache];return u&&(o=f[i.cache]||i.to&&i.to(f._rgba)||[],r(i.props,function(n,i){if(u[i.idx]!=null)return t=u[i.idx]===o[i.idx]})),t}),t},_space:function(){var n=[],t=this;return r(u,function(i,r){t[r.cache]&&n.push(i)}),n.pop()},transition:function(n,t){var f=i(n),c=f._space(),o=u[c],l=this.alpha()===0?i("transparent"):this,a=l[o.cache]||o.to(l._rgba),h=a.slice();return f=f[o.cache],r(o.props,function(n,i){var c=i.idx,r=a[c],u=f[c],o=s[i.type]||{};u!==null&&(r===null?h[c]=u:(o.mod&&(u-r>o.mod/2?r+=o.mod:r-u>o.mod/2&&(r-=o.mod)),h[c]=e((u-r)*t+r,i)))}),this[c](h)},blend:function(t){if(this._rgba[3]===1)return this;var r=this._rgba.slice(),u=r.pop(),f=i(t)._rgba;return i(n.map(r,function(n,t){return(1-u)*f[t]+u*n}))},toRgbaString:function(){var i="rgba(",t=n.map(this._rgba,function(n,t){return n==null?t>2?1:0:n});return t[3]===1&&(t.pop(),i="rgb("),i+t.join()+")"},toHslaString:function(){var i="hsla(",t=n.map(this.hsla(),function(n,t){return n==null&&(n=t>2?1:0),t&&t<3&&(n=Math.round(n*100)+"%"),n});return t[3]===1&&(t.pop(),i="hsl("),i+t.join()+")"},toHexString:function(t){var i=this._rgba.slice(),r=i.pop();return t&&i.push(~~(r*255)),"#"+n.map(i,function(n){return n=(n||0).toString(16),n.length===1?"0"+n:n}).join("")},toString:function(){return this._rgba[3]===0?"transparent":this.toRgbaString()}});i.fn.parse.prototype=i.fn;u.hsla.to=function(n){if(n[0]==null||n[1]==null||n[2]==null)return[null,null,null,n[3]];var i=n[0]/255,r=n[1]/255,f=n[2]/255,s=n[3],u=Math.max(i,r,f),e=Math.min(i,r,f),t=u-e,o=u+e,h=o*.5,c,l;return c=e===u?0:i===u?60*(r-f)/t+360:r===u?60*(f-i)/t+120:60*(i-r)/t+240,l=t===0?0:h<=.5?t/o:t/(2-o),[Math.round(c)%360,l,h,s==null?1:s]};u.hsla.from=function(n){if(n[0]==null||n[1]==null||n[2]==null)return[null,null,null,n[3]];var r=n[0]/360,u=n[1],t=n[2],e=n[3],i=t<=.5?t*(1+u):t+u-t*u,f=2*t-i;return[Math.round(o(f,i,r+1/3)*255),Math.round(o(f,i,r)*255),Math.round(o(f,i,r-1/3)*255),e]};r(u,function(u,f){var s=f.props,o=f.cache,h=f.to,c=f.from;i.fn[u]=function(u){if(h&&!this[o]&&(this[o]=h(this._rgba)),u===t)return this[o].slice();var l,a=n.type(u),v=a==="array"||a==="object"?u:arguments,f=this[o].slice();return r(s,function(n,t){var i=v[a==="object"?n:t.idx];i==null&&(i=f[t.idx]);f[t.idx]=e(i,t)}),c?(l=i(c(f)),l[o]=f,l):i(f)};r(s,function(t,r){i.fn[t]||(i.fn[t]=function(i){var f=n.type(i),h=t==="alpha"?this._hsla?"hsla":"rgba":u,o=this[h](),s=o[r.idx],e;return f==="undefined"?s:(f==="function"&&(i=i.call(this,s),f=n.type(i)),i==null&&r.empty)?this:(f==="string"&&(e=a.exec(i),e&&(i=s+parseFloat(e[2])*(e[1]==="+"?1:-1))),o[r.idx]=i,this[h](o))})})});i.hook=function(t){var u=t.split(" ");r(u,function(t,r){n.cssHooks[r]={set:function(t,u){var o,f,e="";if(u!=="transparent"&&(n.type(u)!=="string"||(o=l(u)))){if(u=i(o||u),!h.rgba&&u._rgba[3]!==1){for(f=r==="backgroundColor"?t.parentNode:t;(e===""||e==="transparent")&&f&&f.style;)try{e=n.css(f,"backgroundColor");f=f.parentNode}catch(s){}u=u.blend(e&&e!=="transparent"?e:"_default")}u=u.toRgbaString()}try{t.style[r]=u}catch(s){}}};n.fx.step[r]=function(t){t.colorInit||(t.start=i(t.elem,r),t.end=i(t.end),t.colorInit=!0);n.cssHooks[r].set(t.elem,t.start.transition(t.end,t.pos))}})};i.hook("backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor");n.cssHooks.borderColor={expand:function(n){var t={};return r(["Top","Right","Bottom","Left"],function(i,r){t["border"+r+"Color"]=n}),t}};f=n.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(l),function(){function t(t){var r,u,i=t.ownerDocument.defaultView?t.ownerDocument.defaultView.getComputedStyle(t,null):t.currentStyle,f={};if(i&&i.length&&i[0]&&i[i[0]])for(u=i.length;u--;)r=i[u],typeof i[r]=="string"&&(f[n.camelCase(r)]=i[r]);else for(r in i)typeof i[r]=="string"&&(f[r]=i[r]);return f}function u(t,i){var e={},u,f;for(u in i)f=i[u],t[u]!==f&&(r[u]||(n.fx.step[u]||!isNaN(parseFloat(f)))&&(e[u]=f));return e}var i=["add","remove","toggle"],r={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};n.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(t,i){n.fx.step[i]=function(n){(n.end==="none"||n.setAttr)&&(n.pos!==1||n.setAttr)||(l.style(n.elem,i,n.end),n.setAttr=!0)}});n.fn.addBack||(n.fn.addBack=function(n){return this.add(n==null?this.prevObject:this.prevObject.filter(n))});n.effects.animateClass=function(r,f,e,o){var s=n.speed(f,e,o);return this.queue(function(){var e=n(this),h=e.attr("class")||"",o,f=s.children?e.find("*").addBack():e;f=f.map(function(){var i=n(this);return{el:i,start:t(this)}});o=function(){n.each(i,function(n,t){r[t]&&e[t+"Class"](r[t])})};o();f=f.map(function(){return this.end=t(this.el[0]),this.diff=u(this.start,this.end),this});e.attr("class",h);f=f.map(function(){var i=this,t=n.Deferred(),r=n.extend({},s,{queue:!1,complete:function(){t.resolve(i)}});return this.el.animate(this.diff,r),t.promise()});n.when.apply(n,f.get()).done(function(){o();n.each(arguments,function(){var t=this.el;n.each(this.diff,function(n){t.css(n,"")})});s.complete.call(e[0])})})};n.fn.extend({addClass:function(t){return function(i,r,u,f){return r?n.effects.animateClass.call(this,{add:i},r,u,f):t.apply(this,arguments)}}(n.fn.addClass),removeClass:function(t){return function(i,r,u,f){return arguments.length>1?n.effects.animateClass.call(this,{remove:i},r,u,f):t.apply(this,arguments)}}(n.fn.removeClass),toggleClass:function(t){return function(i,r,u,f,e){return typeof r=="boolean"||r===undefined?u?n.effects.animateClass.call(this,r?{add:i}:{remove:i},u,f,e):t.apply(this,arguments):n.effects.animateClass.call(this,{toggle:i},r,u,f)}}(n.fn.toggleClass),switchClass:function(t,i,r,u,f){return n.effects.animateClass.call(this,{add:i,remove:t},r,u,f)}})}(),function(){function t(t,i,r,u){return n.isPlainObject(t)&&(i=t,t=t.effect),t={effect:t},i==null&&(i={}),n.isFunction(i)&&(u=i,r=null,i={}),(typeof i=="number"||n.fx.speeds[i])&&(u=r,r=i,i={}),n.isFunction(r)&&(u=r,r=null),i&&n.extend(t,i),r=r||i.duration,t.duration=n.fx.off?0:typeof r=="number"?r:r in n.fx.speeds?n.fx.speeds[r]:n.fx.speeds._default,t.complete=u||i.complete,t}function i(t){return!t||typeof t=="number"||n.fx.speeds[t]?!0:typeof t=="string"&&!n.effects.effect[t]?!0:n.isFunction(t)?!0:typeof t=="object"&&!t.effect?!0:!1}function r(n,t){var r=t.outerWidth(),u=t.outerHeight(),i=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/.exec(n)||["",0,r,u,0];return{top:parseFloat(i[1])||0,right:i[2]==="auto"?r:parseFloat(i[2]),bottom:i[3]==="auto"?u:parseFloat(i[3]),left:parseFloat(i[4])||0}}n.expr&&n.expr.filters&&n.expr.filters.animated&&(n.expr.filters.animated=function(t){return function(i){return!!n(i).data(e)||t(i)}}(n.expr.filters.animated));n.uiBackCompat!==!1&&n.extend(n.effects,{save:function(n,t){for(var i=0,r=t.length;i<r;i++)t[i]!==null&&n.data(u+t[i],n[0].style[t[i]])},restore:function(n,t){for(var r,i=0,f=t.length;i<f;i++)t[i]!==null&&(r=n.data(u+t[i]),n.css(t[i],r))},setMode:function(n,t){return t==="toggle"&&(t=n.is(":hidden")?"show":"hide"),t},createWrapper:function(t){if(t.parent().is(".ui-effects-wrapper"))return t.parent();var i={width:t.outerWidth(!0),height:t.outerHeight(!0),float:t.css("float")},u=n("<div><\/div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),f={width:t.width(),height:t.height()},r=document.activeElement;try{r.id}catch(e){r=document.body}return t.wrap(u),(t[0]===r||n.contains(t[0],r))&&n(r).trigger("focus"),u=t.parent(),t.css("position")==="static"?(u.css({position:"relative"}),t.css({position:"relative"})):(n.extend(i,{position:t.css("position"),zIndex:t.css("z-index")}),n.each(["top","left","bottom","right"],function(n,r){i[r]=t.css(r);isNaN(parseInt(i[r],10))&&(i[r]="auto")}),t.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),t.css(f),u.css(i).show()},removeWrapper:function(t){var i=document.activeElement;return t.parent().is(".ui-effects-wrapper")&&(t.parent().replaceWith(t),(t[0]===i||n.contains(t[0],i))&&n(i).trigger("focus")),t}});n.extend(n.effects,{version:"1.12.1",define:function(t,i,r){return r||(r=i,i="effect"),n.effects.effect[t]=r,n.effects.effect[t].mode=i,r},scaledDimensions:function(n,t,i){if(t===0)return{height:0,width:0,outerHeight:0,outerWidth:0};var r=i!=="horizontal"?(t||100)/100:1,u=i!=="vertical"?(t||100)/100:1;return{height:n.height()*u,width:n.width()*r,outerHeight:n.outerHeight()*u,outerWidth:n.outerWidth()*r}},clipToBox:function(n){return{width:n.clip.right-n.clip.left,height:n.clip.bottom-n.clip.top,left:n.clip.left,top:n.clip.top}},unshift:function(n,t,i){var r=n.queue();t>1&&r.splice.apply(r,[1,0].concat(r.splice(t,i)));n.dequeue()},saveStyle:function(n){n.data(f,n[0].style.cssText)},restoreStyle:function(n){n[0].style.cssText=n.data(f)||"";n.removeData(f)},mode:function(n,t){var i=n.is(":hidden");return t==="toggle"&&(t=i?"show":"hide"),(i?t==="hide":t==="show")&&(t="none"),t},getBaseline:function(n,t){var i,r;switch(n[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=n[0]/t.height}switch(n[1]){case"left":r=0;break;case"center":r=.5;break;case"right":r=1;break;default:r=n[1]/t.width}return{x:r,y:i}},createPlaceholder:function(t){var i,r=t.css("position"),f=t.position();return t.css({marginTop:t.css("marginTop"),marginBottom:t.css("marginBottom"),marginLeft:t.css("marginLeft"),marginRight:t.css("marginRight")}).outerWidth(t.outerWidth()).outerHeight(t.outerHeight()),/^(static|relative)/.test(r)&&(r="absolute",i=n("<"+t[0].nodeName+">").insertAfter(t).css({display:/^(inline|ruby)/.test(t.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:t.css("marginTop"),marginBottom:t.css("marginBottom"),marginLeft:t.css("marginLeft"),marginRight:t.css("marginRight"),float:t.css("float")}).outerWidth(t.outerWidth()).outerHeight(t.outerHeight()).addClass("ui-effects-placeholder"),t.data(u+"placeholder",i)),t.css({position:r,left:f.left,top:f.top}),i},removePlaceholder:function(n){var t=u+"placeholder",i=n.data(t);i&&(i.remove(),n.removeData(t))},cleanUp:function(t){n.effects.restoreStyle(t);n.effects.removePlaceholder(t)},setTransition:function(t,i,r,u){return u=u||{},n.each(i,function(n,i){var f=t.cssUnit(i);f[0]>0&&(u[i]=f[0]*r+f[1])}),u}});n.fn.extend({effect:function(){function a(t){function l(){s.removeData(e);n.effects.cleanUp(s);i.mode==="hide"&&s.hide();h()}function h(){n.isFunction(f)&&f.call(s[0]);n.isFunction(t)&&t()}var s=n(this);i.mode=c.shift();n.uiBackCompat===!1||u?i.mode==="none"?(s[r](),h()):o.call(s[0],i,l):(s.is(":hidden")?r==="hide":r==="show")?(s[r](),h()):o.call(s[0],i,h)}var i=t.apply(this,arguments),o=n.effects.effect[i.effect],u=o.mode,s=i.queue,h=s||"fx",f=i.complete,r=i.mode,c=[],l=function(t){var f=n(this),i=n.effects.mode(f,r)||u;f.data(e,!0);c.push(i);u&&(i==="show"||i===u&&i==="hide")&&f.show();u&&i==="none"||n.effects.saveStyle(f);n.isFunction(t)&&t()};return n.fx.off||!o?r?this[r](i.duration,f):this.each(function(){f&&f.call(this)}):s===!1?this.each(l).each(a):this.queue(h,l).queue(h,a)},show:function(n){return function(r){if(i(r))return n.apply(this,arguments);var u=t.apply(this,arguments);return u.mode="show",this.effect.call(this,u)}}(n.fn.show),hide:function(n){return function(r){if(i(r))return n.apply(this,arguments);var u=t.apply(this,arguments);return u.mode="hide",this.effect.call(this,u)}}(n.fn.hide),toggle:function(n){return function(r){if(i(r)||typeof r=="boolean")return n.apply(this,arguments);var u=t.apply(this,arguments);return u.mode="toggle",this.effect.call(this,u)}}(n.fn.toggle),cssUnit:function(t){var i=this.css(t),r=[];return n.each(["em","px","%","pt"],function(n,t){i.indexOf(t)>0&&(r=[parseFloat(i),t])}),r},cssClip:function(n){return n?this.css("clip","rect("+n.top+"px "+n.right+"px "+n.bottom+"px "+n.left+"px)"):r(this.css("clip"),this)},transfer:function(t,i){var u=n(this),r=n(t.to),f=r.css("position")==="fixed",e=n("body"),o=f?e.scrollTop():0,s=f?e.scrollLeft():0,h=r.offset(),l={top:h.top-o,left:h.left-s,height:r.innerHeight(),width:r.innerWidth()},c=u.offset(),a=n("<div class='ui-effects-transfer'><\/div>").appendTo("body").addClass(t.className).css({top:c.top-o,left:c.left-s,height:u.innerHeight(),width:u.innerWidth(),position:f?"fixed":"absolute"}).animate(l,t.duration,t.easing,function(){a.remove();n.isFunction(i)&&i()})}});n.fx.step.clip=function(t){t.clipInit||(t.start=n(t.elem).cssClip(),typeof t.end=="string"&&(t.end=r(t.end,t.elem)),t.clipInit=!0);n(t.elem).cssClip({top:t.pos*(t.end.top-t.start.top)+t.start.top,right:t.pos*(t.end.right-t.start.right)+t.start.right,bottom:t.pos*(t.end.bottom-t.start.bottom)+t.start.bottom,left:t.pos*(t.end.left-t.start.left)+t.start.left})}}(),function(){var t={};n.each(["Quad","Cubic","Quart","Quint","Expo"],function(n,i){t[i]=function(t){return Math.pow(t,n+2)}});n.extend(t,{Sine:function(n){return 1-Math.cos(n*Math.PI/2)},Circ:function(n){return 1-Math.sqrt(1-n*n)},Elastic:function(n){return n===0||n===1?n:-Math.pow(2,8*(n-1))*Math.sin(((n-1)*80-7.5)*Math.PI/15)},Back:function(n){return n*n*(3*n-2)},Bounce:function(n){for(var t,i=4;n<((t=Math.pow(2,--i))-1)/11;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((t*3-2)/22-n,2)}});n.each(t,function(t,i){n.easing["easeIn"+t]=i;n.easing["easeOut"+t]=function(n){return 1-i(1-n)};n.easing["easeInOut"+t]=function(n){return n<.5?i(n*2)/2:1-i(n*-2+2)/2}})}();var a=n.effects,bt=n.effects.define("bounce",function(t,i){var e,o,a,u=n(this),p=t.mode,s=p==="hide",w=p==="show",h=t.direction||"up",r=t.distance,v=t.times||5,b=v*2+(w||s?1:0),c=t.duration/b,l=t.easing,f=h==="up"||h==="down"?"top":"left",y=h==="up"||h==="left",k=0,d=u.queue().length;for(n.effects.createPlaceholder(u),a=u.css(f),r||(r=u[f==="top"?"outerHeight":"outerWidth"]()/3),w&&(o={opacity:1},o[f]=a,u.css("opacity",0).css(f,y?-r*2:r*2).animate(o,c,l)),s&&(r=r/Math.pow(2,v-1)),o={},o[f]=a;k<v;k++)e={},e[f]=(y?"-=":"+=")+r,u.animate(e,c,l).animate(o,c,l),r=s?r*2:r/2;s&&(e={opacity:0},e[f]=(y?"-=":"+=")+r,u.animate(e,c,l));u.queue(i);n.effects.unshift(u,d,b+1)}),kt=n.effects.define("fade","toggle",function(t,i){var r=t.mode==="show";n(this).css("opacity",r?0:1).animate({opacity:r?1:0},{queue:!1,duration:t.duration,easing:t.easing,complete:i})}),dt=n.effects.define("size",function(t,i){var l,r,p,u=n(this),v=["fontSize"],s=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],h=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],w=t.mode,y=w!=="effect",c=t.scale||"both",b=t.origin||["middle","center"],k=u.css("position"),a=u.position(),o=n.effects.scaledDimensions(u),f=t.from||o,e=t.to||n.effects.scaledDimensions(u,0);n.effects.createPlaceholder(u);w==="show"&&(p=f,f=e,e=p);r={from:{y:f.height/o.height,x:f.width/o.width},to:{y:e.height/o.height,x:e.width/o.width}};(c==="box"||c==="both")&&(r.from.y!==r.to.y&&(f=n.effects.setTransition(u,s,r.from.y,f),e=n.effects.setTransition(u,s,r.to.y,e)),r.from.x!==r.to.x&&(f=n.effects.setTransition(u,h,r.from.x,f),e=n.effects.setTransition(u,h,r.to.x,e)));(c==="content"||c==="both")&&r.from.y!==r.to.y&&(f=n.effects.setTransition(u,v,r.from.y,f),e=n.effects.setTransition(u,v,r.to.y,e));b&&(l=n.effects.getBaseline(b,o),f.top=(o.outerHeight-f.outerHeight)*l.y+a.top,f.left=(o.outerWidth-f.outerWidth)*l.x+a.left,e.top=(o.outerHeight-e.outerHeight)*l.y+a.top,e.left=(o.outerWidth-e.outerWidth)*l.x+a.left);u.css(f);(c==="content"||c==="both")&&(s=s.concat(["marginTop","marginBottom"]).concat(v),h=h.concat(["marginLeft","marginRight"]),u.find("*[width]").each(function(){var i=n(this),u=n.effects.scaledDimensions(i),f={height:u.height*r.from.y,width:u.width*r.from.x,outerHeight:u.outerHeight*r.from.y,outerWidth:u.outerWidth*r.from.x},e={height:u.height*r.to.y,width:u.width*r.to.x,outerHeight:u.height*r.to.y,outerWidth:u.width*r.to.x};r.from.y!==r.to.y&&(f=n.effects.setTransition(i,s,r.from.y,f),e=n.effects.setTransition(i,s,r.to.y,e));r.from.x!==r.to.x&&(f=n.effects.setTransition(i,h,r.from.x,f),e=n.effects.setTransition(i,h,r.to.x,e));y&&n.effects.saveStyle(i);i.css(f);i.animate(e,t.duration,t.easing,function(){y&&n.effects.restoreStyle(i)})}));u.animate(e,{queue:!1,duration:t.duration,easing:t.easing,complete:function(){var t=u.offset();e.opacity===0&&u.css("opacity",f.opacity);y||(u.css("position",k==="static"?"relative":k).offset(t),n.effects.saveStyle(u));i()}})}),gt=n.effects.define("scale",function(t,i){var u=n(this),f=t.mode,e=parseInt(t.percent,10)||(parseInt(t.percent,10)===0?0:f!=="effect"?0:100),r=n.extend(!0,{from:n.effects.scaledDimensions(u),to:n.effects.scaledDimensions(u,e,t.direction||"both"),origin:t.origin||["middle","center"]},t);t.fade&&(r.from.opacity=1,r.to.opacity=0);n.effects.effect.size.call(this,r,i)}),ni=n.effects.define("slide","show",function(t,i){var s,o,u=n(this),h={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},c=t.mode,f=t.direction||"left",e=f==="up"||f==="down"?"top":"left",l=f==="up"||f==="left",a=t.distance||u[e==="top"?"outerHeight":"outerWidth"](!0),r={};n.effects.createPlaceholder(u);s=u.cssClip();o=u.position()[e];r[e]=(l?-1:1)*a+o;r.clip=u.cssClip();r.clip[h[f][1]]=r.clip[h[f][0]];c==="show"&&(u.cssClip(r.clip),u.css(e,r[e]),r.clip=s,r[e]=o);u.animate(r,{queue:!1,duration:t.duration,easing:t.easing,complete:i})});n.uiBackCompat!==!1&&(a=n.effects.define("transfer",function(t,i){n(this).transfer(t,i)}));k=a});!function(n,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(n="undefined"!=typeof globalThis?globalThis:n||self).flatpickr=t()}(this,function(){"use strict";function nt(){for(var t,i,u=0,n=0,f=arguments.length;n<f;n++)u+=arguments[n].length;for(t=Array(u),i=0,n=0;n<f;n++)for(var e=arguments[n],r=0,o=e.length;r<o;r++,i++)t[i]=e[r];return t}function tt(n,t){var i;return function(){var r=this;clearTimeout(i);i=setTimeout(function(){return n.apply(r,arguments)},t)}}function r(n,t,i){if(!0===i)return n.classList.add(t);n.classList.remove(t)}function n(n,t,i){var r=window.document.createElement(n);return t=t||"",i=i||"",r.className=t,void 0!==i&&(r.textContent=i),r}function a(n){for(;n.firstChild;)n.removeChild(n.firstChild)}function it(n,t){return t(n)?n:n.parentNode?it(n.parentNode,t):void 0}function v(t,i){var u=n("div","numInputWrapper"),r=n("input","numInput "+t),e=n("span","arrowUp"),o=n("span","arrowDown"),f;if(-1===navigator.userAgent.indexOf("MSIE 9.0")?r.type="number":(r.type="text",r.pattern="\\d*"),void 0!==i)for(f in i)r.setAttribute(f,i[f]);return u.appendChild(r),u.appendChild(e),u.appendChild(o),u}function f(n){try{return"function"==typeof n.composedPath?n.composedPath()[0]:n.target}catch(t){return n.target}}function e(n,t,i){return void 0===i&&(i=!0),!1!==i?new Date(n.getTime()).setHours(0,0,0,0)-new Date(t.getTime()).setHours(0,0,0,0):n.getTime()-t.getTime()}function g(n){var t=n.defaultHour,i=n.defaultMinute,r=n.defaultSeconds,f,o;if(void 0!==n.minDate){var u=n.minDate.getHours(),e=n.minDate.getMinutes(),s=n.minDate.getSeconds();t<u&&(t=u);t===u&&i<e&&(i=e);t===u&&i===e&&r<s&&(r=n.minDate.getSeconds())}return void 0!==n.maxDate&&(f=n.maxDate.getHours(),o=n.maxDate.getMinutes(),(t=Math.min(t,f))===f&&(i=Math.min(o,i)),t===f&&i===o&&(r=n.maxDate.getSeconds())),{hours:t,minutes:i,seconds:r}}function et(h,l){function vi(n){return n.bind(b)}function yi(){var n=b.config;!1===n.weekNumbers&&1===n.showMonths||!0!==n.noCalendar&&window.requestAnimationFrame(function(){if(void 0!==b.calendarContainer&&(b.calendarContainer.style.visibility="hidden",b.calendarContainer.style.display="block"),void 0!==b.daysContainer){var t=(b.days.offsetWidth+1)*n.showMonths;b.daysContainer.style.width=t+"px";b.calendarContainer.style.width=t+(void 0!==b.weekWrapper?b.weekWrapper.offsetWidth:0)+"px";b.calendarContainer.style.removeProperty("visibility");b.calendarContainer.style.removeProperty("display")}})}function ht(n){var t,i,r;0===b.selectedDates.length&&(t=void 0===b.config.minDate||e(new Date,b.config.minDate)>=0?new Date:new Date(b.config.minDate.getTime()),i=g(b.config),t.setHours(i.hours,i.minutes,i.seconds,t.getMilliseconds()),b.selectedDates=[t],b.latestSelectedDateObj=t);void 0!==n&&"blur"!==n.type&&function(n){var r,c;n.preventDefault();var v="keydown"===n.type,l=f(n),t=l;void 0!==b.amPM&&l===b.amPM&&(b.amPM.textContent=b.l10n.amPM[o(b.amPM.textContent===b.l10n.amPM[0])]);var a=parseFloat(t.getAttribute("min")),e=parseFloat(t.getAttribute("max")),s=parseFloat(t.getAttribute("step")),h=parseInt(t.value,10),y=n.delta||(v?38===n.which?1:-1:0),i=h+s*y;void 0!==t.value&&2===t.value.length&&(r=t===b.hourElement,c=t===b.minuteElement,i<a?(i=e+i+o(!r)+(o(r)&&o(!b.amPM)),c&&ui(void 0,-1,b.hourElement)):i>e&&(i=t===b.hourElement?i-e-o(!b.amPM):a,c&&ui(void 0,1,b.hourElement)),b.amPM&&r&&(1===s?i+h===23:Math.abs(i-h)>s)&&(b.amPM.textContent=b.l10n.amPM[o(b.amPM.textContent===b.l10n.amPM[0])]),t.value=u(i))}(n);r=b._input.value;yt();ot();b._input.value!==r&&b._debouncedChange()}function yt(){var h,r,i;if(void 0!==b.hourElement&&void 0!==b.minuteElement){var f,s,n=(parseInt(b.hourElement.value.slice(-2),10)||0)%24,t=(parseInt(b.minuteElement.value,10)||0)%60,u=void 0!==b.secondElement?(parseInt(b.secondElement.value,10)||0)%60:0;void 0!==b.amPM&&(f=n,s=b.amPM.textContent,n=f%12+12*o(s===b.l10n.amPM[1]));h=void 0!==b.config.minTime||b.config.minDate&&b.minDateHasTime&&b.latestSelectedDateObj&&0===e(b.latestSelectedDateObj,b.config.minDate,!0);(void 0!==b.config.maxTime||b.config.maxDate&&b.maxDateHasTime&&b.latestSelectedDateObj&&0===e(b.latestSelectedDateObj,b.config.maxDate,!0))&&(r=void 0!==b.config.maxTime?b.config.maxTime:b.config.maxDate,(n=Math.min(n,r.getHours()))===r.getHours()&&(t=Math.min(t,r.getMinutes())),t===r.getMinutes()&&(u=Math.min(u,r.getSeconds())));h&&(i=void 0!==b.config.minTime?b.config.minTime:b.config.minDate,(n=Math.max(n,i.getHours()))===i.getHours()&&t<i.getMinutes()&&(t=i.getMinutes()),t===i.getMinutes()&&(u=Math.max(u,i.getSeconds())));ii(n,t,u)}}function pt(n){var t=n||b.latestSelectedDateObj;t&&ii(t.getHours(),t.getMinutes(),t.getSeconds())}function ii(n,t,i){void 0!==b.latestSelectedDateObj&&b.latestSelectedDateObj.setHours(n%24,t,i||0,0);b.hourElement&&b.minuteElement&&!b.isMobile&&(b.hourElement.value=u(b.config.time_24hr?n:(12+n)%12+12*o(n%12==0)),b.minuteElement.value=u(t),void 0!==b.amPM&&(b.amPM.textContent=b.l10n.amPM[o(n>=12)]),void 0!==b.secondElement&&(b.secondElement.value=u(i)))}function fr(n){var i=f(n),t=parseInt(i.value)+(n.delta||0);(t/1e3>1||"Enter"===n.key&&!/[^\d]/.test(t.toString()))&&dt(t)}function ut(n,t,i,r){return t instanceof Array?t.forEach(function(t){return ut(n,t,i,r)}):n instanceof Array?n.forEach(function(n){return ut(n,t,i,r)}):(n.addEventListener(t,i,r),void b._handlers.push({remove:function(){return n.removeEventListener(t,i)}}))}function ri(){et("onChange")}function wt(n,t){var i=void 0!==n?b.parseDate(n):b.latestSelectedDateObj||(b.config.minDate&&b.config.minDate>b.now?b.config.minDate:b.config.maxDate&&b.config.maxDate<b.now?b.config.maxDate:b.now),r=b.currentYear,u=b.currentMonth;try{void 0!==i&&(b.currentYear=i.getFullYear(),b.currentMonth=i.getMonth())}catch(n){n.message="Invalid date supplied: "+i;b.config.errorHandler(n)}t&&b.currentYear!==r&&(et("onYearChange"),ct());!t||b.currentYear===r&&b.currentMonth===u||et("onMonthChange");b.redraw()}function er(n){var t=f(n);~t.className.indexOf("arrow")&&ui(n,t.classList.contains("arrowUp")?1:-1)}function ui(n,t,i){var r=n&&f(n),u=i||r&&r.parentNode&&r.parentNode.firstChild,e=li("increment");e.delta=t;u&&u.dispatchEvent(e)}function fi(t,i,u,f){var s=st(i,!0),o=n("span","flatpickr-day "+t,i.getDate().toString());return o.dateObj=i,o.$i=f,o.setAttribute("aria-label",b.formatDate(i,b.config.ariaDateFormat)),-1===t.indexOf("hidden")&&0===e(i,b.now)&&(b.todayDateElem=o,o.classList.add("today"),o.setAttribute("aria-current","date")),s?(o.tabIndex=-1,ai(i)&&(o.classList.add("selected"),b.selectedDateElem=o,"range"===b.config.mode&&(r(o,"startRange",b.selectedDates[0]&&0===e(i,b.selectedDates[0],!0)),r(o,"endRange",b.selectedDates[1]&&0===e(i,b.selectedDates[1],!0)),"nextMonthDay"===t&&o.classList.add("inRange")))):o.classList.add("flatpickr-disabled"),"range"===b.config.mode&&function(n){return!("range"!==b.config.mode||b.selectedDates.length<2)&&e(n,b.selectedDates[0])>=0&&e(n,b.selectedDates[1])<=0}(i)&&!ai(i)&&o.classList.add("inRange"),b.weekNumbers&&1===b.config.showMonths&&"prevMonthDay"!==t&&u%7==1&&b.weekNumbers.insertAdjacentHTML("beforeend","<span class='flatpickr-day'>"+b.config.getWeek(i)+"<\/span>"),et("onDayCreate",o),o}function ei(n){n.focus();"range"===b.config.mode&&hi(n)}function bt(n){for(var t,f=n>0?0:b.config.showMonths-1,e=n>0?b.config.showMonths:-1,i=f;i!=e;i+=n)for(var r=b.daysContainer.children[i],o=n>0?0:r.children.length-1,s=n>0?r.children.length:-1,u=o;u!=s;u+=n)if(t=r.children[u],-1===t.className.indexOf("hidden")&&st(t.dateObj))return t}function at(n,t){var r=gt(document.activeElement||document.body),i=void 0!==n?n:r?document.activeElement:void 0!==b.selectedDateElem&&gt(b.selectedDateElem)?b.selectedDateElem:void 0!==b.todayDateElem&&gt(b.todayDateElem)?b.todayDateElem:bt(t>0?1:-1);void 0===i?b._input.focus():r?function(n,t){for(var f,o=-1===n.className.indexOf("Month")?n.dateObj.getMonth():b.currentMonth,h=t>0?b.config.showMonths:-1,r=t>0?1:-1,u=o-b.currentMonth;u!=h;u+=r)for(var e=b.daysContainer.children[u],c=o-b.currentMonth===u?n.$i+t:t<0?e.children.length-1:0,s=e.children.length,i=c;i>=0&&i<s&&i!=(t>0?s:-1);i+=r)if(f=e.children[i],-1===f.className.indexOf("hidden")&&st(f.dateObj)&&Math.abs(n.$i-i)>=Math.abs(t))return ei(f);b.changeMonth(r);at(bt(r),0)}(i,t):ei(i)}function or(t,i){for(var f,s,h=(new Date(t,i,1).getDay()-b.l10n.firstDayOfWeek+7)%7,c=b.utils.getDaysInMonth((i- -11)%12,t),o=b.utils.getDaysInMonth(i,t),e=window.document.createDocumentFragment(),l=b.config.showMonths>1,a=l?"prevMonthDay hidden":"prevMonthDay",v=l?"nextMonthDay hidden":"nextMonthDay",r=c+1-h,u=0;r<=c;r++,u++)e.appendChild(fi(a,new Date(t,i-1,r),r,u));for(r=1;r<=o;r++,u++)e.appendChild(fi("",new Date(t,i,r),r,u));for(f=o+1;f<=42-h&&(1===b.config.showMonths||u%7!=0);f++,u++)e.appendChild(fi(v,new Date(t,i+1,f%o),f,u));return s=n("div","dayContainer"),s.appendChild(e),s}function kt(){var i,n,t;if(void 0!==b.daysContainer){for(a(b.daysContainer),b.weekNumbers&&a(b.weekNumbers),i=document.createDocumentFragment(),n=0;n<b.config.showMonths;n++)t=new Date(b.currentYear,b.currentMonth,1),t.setMonth(b.currentMonth+n),i.appendChild(or(t.getFullYear(),t.getMonth()));b.daysContainer.appendChild(i);b.days=b.daysContainer.firstChild;"range"===b.config.mode&&1===b.selectedDates.length&&hi()}}function ct(){var r,t,i;if(!(b.config.showMonths>1||"dropdown"!==b.config.monthSelectorType))for(r=function(n){return!(void 0!==b.config.minDate&&b.currentYear===b.config.minDate.getFullYear()&&n<b.config.minDate.getMonth())&&!(void 0!==b.config.maxDate&&b.currentYear===b.config.maxDate.getFullYear()&&n>b.config.maxDate.getMonth())},b.monthsDropdownContainer.tabIndex=-1,b.monthsDropdownContainer.innerHTML="",t=0;t<12;t++)r(t)&&(i=n("option","flatpickr-monthDropdown-month"),i.value=new Date(b.currentYear,t).getMonth().toString(),i.textContent=y(t,b.config.shorthandCurrentMonth,b.l10n),i.tabIndex=-1,b.currentMonth===t&&(i.selected=!0),b.monthsDropdownContainer.appendChild(i))}function sr(){var i,e=n("div","flatpickr-month"),o=window.document.createDocumentFragment(),u,t,r;return b.config.showMonths>1||"static"===b.config.monthSelectorType?i=n("span","cur-month"):(b.monthsDropdownContainer=n("select","flatpickr-monthDropdown-months"),b.monthsDropdownContainer.setAttribute("aria-label",b.l10n.monthAriaLabel),ut(b.monthsDropdownContainer,"change",function(n){var t=f(n),i=parseInt(t.value,10);b.changeMonth(i-b.currentMonth);et("onMonthChange")}),ct(),i=b.monthsDropdownContainer),u=v("cur-year",{tabindex:"-1"}),t=u.getElementsByTagName("input")[0],t.setAttribute("aria-label",b.l10n.yearAriaLabel),b.config.minDate&&t.setAttribute("min",b.config.minDate.getFullYear().toString()),b.config.maxDate&&(t.setAttribute("max",b.config.maxDate.getFullYear().toString()),t.disabled=!!b.config.minDate&&b.config.minDate.getFullYear()===b.config.maxDate.getFullYear()),r=n("div","flatpickr-current-month"),r.appendChild(i),r.appendChild(u),o.appendChild(r),e.appendChild(o),{container:e,yearElement:t,monthElement:i}}function pi(){var t,n;for(a(b.monthNav),b.monthNav.appendChild(b.prevMonthNav),b.config.showMonths&&(b.yearElements=[],b.monthElements=[]),t=b.config.showMonths;t--;)n=sr(),b.yearElements.push(n.yearElement),b.monthElements.push(n.monthElement),b.monthNav.appendChild(n.container);b.monthNav.appendChild(b.nextMonthNav)}function wi(){var t,i;for(b.weekdayContainer?a(b.weekdayContainer):b.weekdayContainer=n("div","flatpickr-weekdays"),t=b.config.showMonths;t--;)i=n("div","flatpickr-weekdaycontainer"),b.weekdayContainer.appendChild(i);return bi(),b.weekdayContainer}function bi(){var t,n,i;if(b.weekdayContainer)for(t=b.l10n.firstDayOfWeek,n=nt(b.l10n.weekdays.shorthand),t>0&&t<n.length&&(n=nt(n.splice(t,n.length),n.splice(0,t))),i=b.config.showMonths;i--;)b.weekdayContainer.children[i].innerHTML="\n      <span class='flatpickr-weekday'>\n        "+n.join("<\/span><span class='flatpickr-weekday'>")+"\n      <\/span>\n      "}function oi(n,t){void 0===t&&(t=!0);var i=t?n:n-b.currentMonth;i<0&&!0===b._hidePrevMonthArrow||i>0&&!0===b._hideNextMonthArrow||(b.currentMonth+=i,(b.currentMonth<0||b.currentMonth>11)&&(b.currentYear+=b.currentMonth>11?1:-1,b.currentMonth=(b.currentMonth+12)%12,et("onYearChange"),ct()),kt(),et("onMonthChange"),ti())}function lt(n){return!(!b.config.appendTo||!b.config.appendTo.contains(n))||b.calendarContainer.contains(n)}function si(n){if(b.isOpen&&!b.config.inline){var t=f(n),r=lt(t),i=t===b.input||t===b.altInput||b.element.contains(t)||n.path&&n.path.indexOf&&(~n.path.indexOf(b.input)||~n.path.indexOf(b.altInput)),u="blur"===n.type?i&&n.relatedTarget&&!lt(n.relatedTarget):!i&&!r&&!lt(n.relatedTarget),e=!b.config.ignoredFocusElements.some(function(n){return n.contains(t)});u&&e&&(void 0!==b.timeContainer&&void 0!==b.minuteElement&&void 0!==b.hourElement&&""!==b.input.value&&void 0!==b.input.value&&ht(),b.close(),b.config&&"range"===b.config.mode&&1===b.selectedDates.length&&(b.clear(!1),b.redraw()))}}function dt(n){if(!(!n||b.config.minDate&&n<b.config.minDate.getFullYear()||b.config.maxDate&&n>b.config.maxDate.getFullYear())){var t=n,i=b.currentYear!==t;b.currentYear=t||b.currentYear;b.config.maxDate&&b.currentYear===b.config.maxDate.getFullYear()?b.currentMonth=Math.min(b.config.maxDate.getMonth(),b.currentMonth):b.config.minDate&&b.currentYear===b.config.minDate.getFullYear()&&(b.currentMonth=Math.max(b.config.minDate.getMonth(),b.currentMonth));i&&(b.redraw(),et("onYearChange"),ct())}}function st(n,t){var f,i,s;if(void 0===t&&(t=!0),i=b.parseDate(n,void 0,t),b.config.minDate&&i&&e(i,b.config.minDate,void 0!==t?t:!b.minDateHasTime)<0||b.config.maxDate&&i&&e(i,b.config.maxDate,void 0!==t?t:!b.maxDateHasTime)>0)return!1;if(!b.config.enable&&0===b.config.disable.length)return!0;if(void 0===i)return!1;for(var u=!!b.config.enable,h=null!==(f=b.config.enable)&&void 0!==f?f:b.config.disable,o=0,r=void 0;o<h.length;o++){if("function"==typeof(r=h[o])&&r(i)||r instanceof Date&&void 0!==i&&r.getTime()===i.getTime())return u;if("string"==typeof r)return s=b.parseDate(r,void 0,!0),s&&s.getTime()===i.getTime()?u:!u;if("object"==typeof r&&void 0!==i&&r.from&&r.to&&i.getTime()>=r.from.getTime()&&i.getTime()<=r.to.getTime())return u}return!u}function gt(n){return void 0!==b.daysContainer&&-1===n.className.indexOf("hidden")&&-1===n.className.indexOf("flatpickr-disabled")&&b.daysContainer.contains(n)}function hr(n){n.target===b._input&&(b.selectedDates.length>0||b._input.value.length>0)&&(!n.relatedTarget||!lt(n.relatedTarget))&&b.setDate(b._input.value,!0,n.target===b.altInput?b.config.altFormat:b.config.dateFormat)}function cr(n){var t=f(n),i=b.config.wrap?h.contains(t):t===b._input,u=b.config.allowInput,a=b.isOpen&&(!u||!i),v=b.config.inline&&i&&!u,r,o,e,s,c,l;if(13===n.keyCode&&i){if(u)return b.setDate(b._input.value,!0,t===b.altInput?b.config.altFormat:b.config.dateFormat),t.blur();b.open()}else if(lt(t)||a||v){r=!!b.timeContainer&&b.timeContainer.contains(t);switch(n.keyCode){case 13:r?(n.preventDefault(),ht(),ci()):tr(n);break;case 27:n.preventDefault();ci();break;case 8:case 46:i&&!b.config.allowInput&&(n.preventDefault(),b.clear());break;case 37:case 39:r||i?b.hourElement&&b.hourElement.focus():(n.preventDefault(),void 0!==b.daysContainer&&(!1===u||document.activeElement&&gt(document.activeElement)))&&(o=39===n.keyCode?1:-1,n.ctrlKey?(n.stopPropagation(),oi(o),at(bt(1),0)):at(void 0,o));break;case 38:case 40:n.preventDefault();e=40===n.keyCode?1:-1;b.daysContainer&&void 0!==t.$i||t===b.input||t===b.altInput?n.ctrlKey?(n.stopPropagation(),dt(b.currentYear-e),at(bt(1),0)):r||at(void 0,7*e):t===b.currentYearElement?dt(b.currentYear-e):b.config.enableTime&&(!r&&b.hourElement&&b.hourElement.focus(),ht(n),b._debouncedChange());break;case 9:r?(s=[b.hourElement,b.minuteElement,b.secondElement,b.amPM].concat(b.pluginElements).filter(function(n){return n}),c=s.indexOf(t),-1!==c&&(l=s[c+(n.shiftKey?-1:1)],n.preventDefault(),(l||b._input).focus())):!b.config.noCalendar&&b.daysContainer&&b.daysContainer.contains(t)&&n.shiftKey&&(n.preventDefault(),b._input.focus())}}if(void 0!==b.amPM&&t===b.amPM)switch(n.key){case b.l10n.amPM[0].charAt(0):case b.l10n.amPM[0].charAt(0).toLowerCase():b.amPM.textContent=b.l10n.amPM[0];yt();ot();break;case b.l10n.amPM[1].charAt(0):case b.l10n.amPM[1].charAt(0).toLowerCase():b.amPM.textContent=b.l10n.amPM[1];yt();ot()}(i||lt(t))&&et("onKeyDown",n)}function hi(n){var e;if(1===b.selectedDates.length&&(!n||n.classList.contains("flatpickr-day")&&!n.classList.contains("flatpickr-disabled"))){for(var u=n?n.dateObj.getTime():b.days.firstElementChild.dateObj.getTime(),i=b.parseDate(b.selectedDates[0],void 0,!0).getTime(),h=Math.min(u,b.selectedDates[0].getTime()),c=Math.max(u,b.selectedDates[0].getTime()),o=!1,f=0,r=0,t=h;t<c;t+=ft)st(new Date(t),!0)||(o=o||t>h&&t<c,t<i&&(!f||t>f)?f=t:t>i&&(!r||t<r)&&(r=t));for(e=0;e<b.config.showMonths;e++)for(var l=b.daysContainer.children[e],a=function(t){var a,h,c,e=l.children[t],s=e.dateObj.getTime(),v=f>0&&s<f||r>0&&s>r;return v?(e.classList.add("notAllowed"),["inRange","startRange","endRange"].forEach(function(n){e.classList.remove(n)}),"continue"):o&&!v?"continue":(["startRange","inRange","endRange","notAllowed"].forEach(function(n){e.classList.remove(n)}),void(void 0!==n&&(n.classList.add(u<=b.selectedDates[0].getTime()?"startRange":"endRange"),i<u&&s===i?e.classList.add("startRange"):i>u&&s===i&&e.classList.add("endRange"),s>=f&&(0===r||s<=r)&&(h=i,c=u,(a=s)>Math.min(h,c)&&a<Math.max(h,c))&&e.classList.add("inRange"))))},s=0,v=l.children.length;s<v;s++)a(s)}}function lr(){!b.isOpen||b.config.static||b.config.inline||ni()}function ki(n){return function(t){var i=b.config["_"+n+"Date"]=b.parseDate(t,b.config.dateFormat),r=b.config["_"+("min"===n?"max":"min")+"Date"];void 0!==i&&(b["min"===n?"minDateHasTime":"maxDateHasTime"]=i.getHours()>0||i.getMinutes()>0||i.getSeconds()>0);b.selectedDates&&(b.selectedDates=b.selectedDates.filter(function(n){return st(n)}),b.selectedDates.length||"min"!==n||pt(i),ot());b.daysContainer&&(nr(),void 0!==i?b.currentYearElement[n]=i.getFullYear().toString():b.currentYearElement.removeAttribute(n),b.currentYearElement.disabled=!!r&&void 0!==i&&r.getFullYear()===i.getFullYear())}}function di(){return b.config.wrap?h.querySelector("[data-input]"):h}function gi(){"object"!=typeof b.config.locale&&void 0===t.l10ns[b.config.locale]&&b.config.errorHandler(new Error("flatpickr: invalid locale "+b.config.locale));b.l10n=i(i({},t.l10ns.default),"object"==typeof b.config.locale?b.config.locale:"default"!==b.config.locale?t.l10ns[b.config.locale]:void 0);k.K="("+b.l10n.amPM[0]+"|"+b.l10n.amPM[1]+"|"+b.l10n.amPM[0].toLowerCase()+"|"+b.l10n.amPM[1].toLowerCase()+")";void 0===i(i({},l),JSON.parse(JSON.stringify(h.dataset||{}))).time_24hr&&void 0===t.defaultConfig.time_24hr&&(b.config.time_24hr=b.l10n.time_24hr);b.formatDate=rt(b);b.parseDate=d({config:b.config,l10n:b.l10n})}function ni(n){var f;if("function"!=typeof b.config.position){if(void 0!==b.calendarContainer){et("onPreCalendarPosition");var l=n||b._positionElement,e=Array.prototype.reduce.call(b.calendarContainer.children,function(n,t){return n+t.offsetHeight},0),i=b.calendarContainer.offsetWidth,o=b.config.position.split(" "),a=o[0],v=o.length>1?o[1]:null,t=l.getBoundingClientRect(),w=window.innerHeight-t.bottom,s="above"===a||"below"!==a&&w<e&&t.top>e,k=window.pageYOffset+t.top+(s?-e-2:l.offsetHeight+2);if(r(b.calendarContainer,"arrowTop",!s),r(b.calendarContainer,"arrowBottom",s),!b.config.inline){var u=window.pageXOffset+t.left,h=!1,c=!1;"center"===v?(u-=(i-t.width)/2,h=!0):"right"===v&&(u-=i-t.width,c=!0);r(b.calendarContainer,"arrowLeft",!h&&!c);r(b.calendarContainer,"arrowCenter",h);r(b.calendarContainer,"arrowRight",c);var y=window.document.body.offsetWidth-(window.pageXOffset+t.right),p=u+i>window.document.body.offsetWidth,d=y+i>window.document.body.offsetWidth;if(r(b.calendarContainer,"rightMost",p),!b.config.static)if(b.calendarContainer.style.top=k+"px",p)if(d){if(f=function(){for(var i,r,n=null,t=0;t<document.styleSheets.length;t++){i=document.styleSheets[t];try{i.cssRules}catch(n){continue}n=i;break}return null!=n?n:(r=document.createElement("style"),document.head.appendChild(r),r.sheet)}(),void 0===f)return;var g=window.document.body.offsetWidth,nt=Math.max(0,g/2-i/2),tt=f.cssRules.length,it="{left:"+t.left+"px;right:auto;}";r(b.calendarContainer,"rightMost",!1);r(b.calendarContainer,"centerMost",!0);f.insertRule(".flatpickr-calendar.centerMost:before,.flatpickr-calendar.centerMost:after"+it,tt);b.calendarContainer.style.left=nt+"px";b.calendarContainer.style.right="auto"}else b.calendarContainer.style.left="auto",b.calendarContainer.style.right=y+"px";else b.calendarContainer.style.left=u+"px",b.calendarContainer.style.right="auto"}}}else b.config.position(b,n)}function nr(){b.config.noCalendar||b.isMobile||(ct(),ti(),kt())}function ci(){b._input.focus();-1!==window.navigator.userAgent.indexOf("MSIE")||void 0!==navigator.msMaxTouchPoints?setTimeout(b.close,0):b.close()}function tr(n){var i,u,s,h,c;if(n.preventDefault(),n.stopPropagation(),i=it(f(n),function(n){return n.classList&&n.classList.contains("flatpickr-day")&&!n.classList.contains("flatpickr-disabled")&&!n.classList.contains("notAllowed")}),void 0!==i){var r=i,t=b.latestSelectedDateObj=new Date(r.dateObj.getTime()),o=(t.getMonth()<b.currentMonth||t.getMonth()>b.currentMonth+b.config.showMonths-1)&&"range"!==b.config.mode;(b.selectedDateElem=r,"single"===b.config.mode)?b.selectedDates=[t]:"multiple"===b.config.mode?(u=ai(t),u?b.selectedDates.splice(parseInt(u),1):b.selectedDates.push(t)):"range"===b.config.mode&&(2===b.selectedDates.length&&b.clear(!1,!1),b.latestSelectedDateObj=t,b.selectedDates.push(t),0!==e(t,b.selectedDates[0],!0)&&b.selectedDates.sort(function(n,t){return n.getTime()-t.getTime()}));(yt(),o)&&(s=b.currentYear!==t.getFullYear(),b.currentYear=t.getFullYear(),b.currentMonth=t.getMonth(),s&&(et("onYearChange"),ct()),et("onMonthChange"));(ti(),kt(),ot(),o||"range"===b.config.mode||1!==b.config.showMonths?void 0!==b.selectedDateElem&&void 0===b.hourElement&&b.selectedDateElem&&b.selectedDateElem.focus():ei(r),void 0!==b.hourElement&&void 0!==b.hourElement&&b.hourElement.focus(),b.config.closeOnSelect)&&(h="single"===b.config.mode&&!b.config.enableTime,c="range"===b.config.mode&&2===b.selectedDates.length&&!b.config.enableTime,(h||c)&&ci());ri()}}function ir(n,t){var i=[];if(n instanceof Array)i=n.map(function(n){return b.parseDate(n,t)});else if(n instanceof Date||"number"==typeof n)i=[b.parseDate(n,t)];else if("string"==typeof n)switch(b.config.mode){case"single":case"time":i=[b.parseDate(n,t)];break;case"multiple":i=n.split(b.config.conjunction).map(function(n){return b.parseDate(n,t)});break;case"range":i=n.split(b.l10n.rangeSeparator).map(function(n){return b.parseDate(n,t)})}else b.config.errorHandler(new Error("Invalid date supplied: "+JSON.stringify(n)));b.selectedDates=b.config.allowInvalidPreload?i:i.filter(function(n){return n instanceof Date&&st(n,!1)});"range"===b.config.mode&&b.selectedDates.sort(function(n,t){return n.getTime()-t.getTime()})}function rr(n){return n.slice().map(function(n){return"string"==typeof n||"number"==typeof n||n instanceof Date?b.parseDate(n,void 0,!0):n&&"object"==typeof n&&n.from&&n.to?{from:b.parseDate(n.from,void 0),to:b.parseDate(n.to,void 0)}:n}).filter(function(n){return n})}function et(n,t){var i,r;if(void 0!==b.config){if(i=b.config[n],void 0!==i&&i.length>0)for(r=0;i[r]&&r<i.length;r++)i[r](b.selectedDates,b.input.value,b,t);"onChange"===n&&(b.input.dispatchEvent(li("change")),b.input.dispatchEvent(li("input")))}}function li(n){var t=document.createEvent("Event");return t.initEvent(n,!0,!0),t}function ai(n){for(var t=0;t<b.selectedDates.length;t++)if(0===e(b.selectedDates[t],n))return""+t;return!1}function ti(){b.config.noCalendar||b.isMobile||!b.monthNav||(b.yearElements.forEach(function(n,t){var i=new Date(b.currentYear,b.currentMonth,1);i.setMonth(b.currentMonth+t);b.config.showMonths>1||"static"===b.config.monthSelectorType?b.monthElements[t].textContent=y(i.getMonth(),b.config.shorthandCurrentMonth,b.l10n)+" ":b.monthsDropdownContainer.value=i.getMonth().toString();n.value=i.getFullYear().toString()}),b._hidePrevMonthArrow=void 0!==b.config.minDate&&(b.currentYear===b.config.minDate.getFullYear()?b.currentMonth<=b.config.minDate.getMonth():b.currentYear<b.config.minDate.getFullYear()),b._hideNextMonthArrow=void 0!==b.config.maxDate&&(b.currentYear===b.config.maxDate.getFullYear()?b.currentMonth+1>b.config.maxDate.getMonth():b.currentYear>b.config.maxDate.getFullYear()))}function ur(n){return b.selectedDates.map(function(t){return b.formatDate(t,n)}).filter(function(n,t,i){return"range"!==b.config.mode||b.config.enableTime||i.indexOf(n)===t}).join("range"!==b.config.mode?b.config.conjunction:b.l10n.rangeSeparator)}function ot(n){void 0===n&&(n=!0);void 0!==b.mobileInput&&b.mobileFormatStr&&(b.mobileInput.value=void 0!==b.latestSelectedDateObj?b.formatDate(b.latestSelectedDateObj,b.mobileFormatStr):"");b.input.value=ur(b.config.dateFormat);void 0!==b.altInput&&(b.altInput.value=ur(b.config.altFormat));!1!==n&&et("onValueUpdate")}function ar(n){var t=f(n),i=b.prevMonthNav.contains(t),r=b.nextMonthNav.contains(t);i||r?oi(i?-1:1):b.yearElements.indexOf(t)>=0?t.select():t.classList.contains("arrowUp")?b.changeYear(b.currentYear+1):t.classList.contains("arrowDown")&&b.changeYear(b.currentYear-1)}var b={config:i(i({},s),t.defaultConfig),l10n:c},vt;return b.parseDate=d({config:b.config,l10n:b.l10n}),b._handlers=[],b.pluginElements=[],b.loadedPlugins=[],b._bind=ut,b._setHoursFromDate=pt,b._positionCalendar=ni,b.changeMonth=oi,b.changeYear=dt,b.clear=function(n,t){if(void 0===n&&(n=!0),void 0===t&&(t=!0),b.input.value="",void 0!==b.altInput&&(b.altInput.value=""),void 0!==b.mobileInput&&(b.mobileInput.value=""),b.selectedDates=[],b.latestSelectedDateObj=void 0,!0===t&&(b.currentYear=b._initialDate.getFullYear(),b.currentMonth=b._initialDate.getMonth()),!0===b.config.enableTime){var i=g(b.config),r=i.hours,u=i.minutes,f=i.seconds;ii(r,u,f)}b.redraw();n&&et("onChange")},b.close=function(){b.isOpen=!1;b.isMobile||(void 0!==b.calendarContainer&&b.calendarContainer.classList.remove("open"),void 0!==b._input&&b._input.classList.remove("active"));et("onClose")},b._createElement=n,b.destroy=function(){var t,n;for(void 0!==b.config&&et("onDestroy"),t=b._handlers.length;t--;)b._handlers[t].remove();if(b._handlers=[],b.mobileInput)b.mobileInput.parentNode&&b.mobileInput.parentNode.removeChild(b.mobileInput),b.mobileInput=void 0;else if(b.calendarContainer&&b.calendarContainer.parentNode)if(b.config.static&&b.calendarContainer.parentNode){if(n=b.calendarContainer.parentNode,n.lastChild&&n.removeChild(n.lastChild),n.parentNode){for(;n.firstChild;)n.parentNode.insertBefore(n.firstChild,n);n.parentNode.removeChild(n)}}else b.calendarContainer.parentNode.removeChild(b.calendarContainer);b.altInput&&(b.input.type="text",b.altInput.parentNode&&b.altInput.parentNode.removeChild(b.altInput),delete b.altInput);b.input&&(b.input.type=b.input._type,b.input.classList.remove("flatpickr-input"),b.input.removeAttribute("readonly"));["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","monthsDropdownContainer","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach(function(n){try{delete b[n]}catch(n){}})},b.isEnabled=st,b.jumpToDate=wt,b.open=function(n,t){var i,r;if(void 0===t&&(t=b._positionElement),!0===b.isMobile)return n&&(n.preventDefault(),i=f(n),i&&i.blur()),void 0!==b.mobileInput&&(b.mobileInput.focus(),b.mobileInput.click()),void et("onOpen");b._input.disabled||b.config.inline||(r=b.isOpen,b.isOpen=!0,r||(b.calendarContainer.classList.add("open"),b._input.classList.add("active"),et("onOpen"),ni(t)),!0===b.config.enableTime&&!0===b.config.noCalendar&&(!1!==b.config.allowInput||void 0!==n&&b.timeContainer.contains(n.relatedTarget)||setTimeout(function(){return b.hourElement.select()},50)))},b.redraw=nr,b.set=function(n,t){if(null!==n&&"object"==typeof n)for(var i in Object.assign(b.config,n),n)void 0!==vt[i]&&vt[i].forEach(function(n){return n()});else b.config[n]=t,void 0!==vt[n]?vt[n].forEach(function(n){return n()}):p.indexOf(n)>-1&&(b.config[n]=w(t));b.redraw();ot(!0)},b.setDate=function(n,t,i){if(void 0===t&&(t=!1),void 0===i&&(i=b.config.dateFormat),0!==n&&!n||n instanceof Array&&0===n.length)return b.clear(t);ir(n,i);b.latestSelectedDateObj=b.selectedDates[b.selectedDates.length-1];b.redraw();wt(void 0,t);pt();0===b.selectedDates.length&&b.clear(!1);ot(t);t&&et("onChange")},b.toggle=function(n){if(!0===b.isOpen)return b.close();b.open(n)},vt={locale:[gi,bi],showMonths:[pi,yi,wi],minDate:[wt],maxDate:[wt],clickOpens:[function(){!0===b.config.clickOpens?(ut(b._input,"focus",b.open),ut(b._input,"click",b.open)):(b._input.removeEventListener("focus",b.open),b._input.removeEventListener("click",b.open))}]},function(){b.element=b.input=h;b.isOpen=!1,function(){var e=["wrap","weekNumbers","allowInput","allowInvalidPreload","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],n=i(i({},JSON.parse(JSON.stringify(h.dataset||{}))),l),c={},f,v,y,a,r,o,u;for(b.config.parseDate=n.parseDate,b.config.formatDate=n.formatDate,Object.defineProperty(b.config,"enable",{get:function(){return b.config._enable},set:function(n){b.config._enable=rr(n)}}),Object.defineProperty(b.config,"disable",{get:function(){return b.config._disable},set:function(n){b.config._disable=rr(n)}}),f="time"===n.mode,!n.dateFormat&&(n.enableTime||f)&&(v=t.defaultConfig.dateFormat||s.dateFormat,c.dateFormat=n.noCalendar||f?"H:i"+(n.enableSeconds?":S":""):v+" H:i"+(n.enableSeconds?":S":"")),n.altInput&&(n.enableTime||f)&&!n.altFormat&&(y=t.defaultConfig.altFormat||s.altFormat,c.altFormat=n.noCalendar||f?"h:i"+(n.enableSeconds?":S K":" K"):y+" h:i"+(n.enableSeconds?":S":"")+" K"),Object.defineProperty(b.config,"minDate",{get:function(){return b.config._minDate},set:ki("min")}),Object.defineProperty(b.config,"maxDate",{get:function(){return b.config._maxDate},set:ki("max")}),a=function(n){return function(t){b.config["min"===n?"_minTime":"_maxTime"]=b.parseDate(t,"H:i:S")}},Object.defineProperty(b.config,"minTime",{get:function(){return b.config._minTime},set:a("min")}),Object.defineProperty(b.config,"maxTime",{get:function(){return b.config._maxTime},set:a("max")}),"time"===n.mode&&(b.config.noCalendar=!0,b.config.enableTime=!0),Object.assign(b.config,c,n),r=0;r<e.length;r++)b.config[e[r]]=!0===b.config[e[r]]||"true"===b.config[e[r]];for(p.filter(function(n){return void 0!==b.config[n]}).forEach(function(n){b.config[n]=w(b.config[n]||[]).map(vi)}),b.isMobile=!b.config.disableMobile&&!b.config.inline&&"single"===b.config.mode&&!b.config.disable.length&&!b.config.enable&&!b.config.weekNumbers&&/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),r=0;r<b.config.plugins.length;r++){o=b.config.plugins[r](b)||{};for(u in o)p.indexOf(u)>-1?b.config[u]=w(o[u]).map(vi).concat(b.config[u]):void 0===n[u]&&(b.config[u]=o[u])}n.altInputClass||(b.config.altInputClass=di().className+" "+b.config.altInputClass);et("onParseConfig")}();gi(),function(){if(b.input=di(),!b.input)return void b.config.errorHandler(new Error("Invalid input element specified"));b.input._type=b.input.type;b.input.type="text";b.input.classList.add("flatpickr-input");b._input=b.input;b.config.altInput&&(b.altInput=n(b.input.nodeName,b.config.altInputClass),b._input=b.altInput,b.altInput.placeholder=b.input.placeholder,b.altInput.disabled=b.input.disabled,b.altInput.required=b.input.required,b.altInput.tabIndex=b.input.tabIndex,b.altInput.type="text",b.input.setAttribute("type","hidden"),!b.config.static&&b.input.parentNode&&b.input.parentNode.insertBefore(b.altInput,b.input.nextSibling));b.config.allowInput||b._input.setAttribute("readonly","readonly");b._positionElement=b.config.positionElement||b._input}(),function(){b.selectedDates=[];b.now=b.parseDate(b.config.now)||new Date;var n=b.config.defaultDate||("INPUT"!==b.input.nodeName&&"TEXTAREA"!==b.input.nodeName||!b.input.placeholder||b.input.value!==b.input.placeholder?b.input.value:null);n&&ir(n,b.config.dateFormat);b._initialDate=b.selectedDates.length>0?b.selectedDates[0]:b.config.minDate&&b.config.minDate.getTime()>b.now.getTime()?b.config.minDate:b.config.maxDate&&b.config.maxDate.getTime()<b.now.getTime()?b.config.maxDate:b.now;b.currentYear=b._initialDate.getFullYear();b.currentMonth=b._initialDate.getMonth();b.selectedDates.length>0&&(b.latestSelectedDateObj=b.selectedDates[0]);void 0!==b.config.minTime&&(b.config.minTime=b.parseDate(b.config.minTime,"H:i"));void 0!==b.config.maxTime&&(b.config.maxTime=b.parseDate(b.config.maxTime,"H:i"));b.minDateHasTime=!!b.config.minDate&&(b.config.minDate.getHours()>0||b.config.minDate.getMinutes()>0||b.config.minDate.getSeconds()>0);b.maxDateHasTime=!!b.config.maxDate&&(b.config.maxDate.getHours()>0||b.config.maxDate.getMinutes()>0||b.config.maxDate.getSeconds()>0)}();b.utils={getDaysInMonth:function(n,t){return void 0===n&&(n=b.currentMonth),void 0===t&&(t=b.currentYear),1===n&&(t%4==0&&t%100!=0||t%400==0)?29:b.l10n.daysInMonth[n]}};b.isMobile||function(){var i=window.document.createDocumentFragment(),s,t;if(b.calendarContainer=n("div","flatpickr-calendar"),b.calendarContainer.tabIndex=-1,!b.config.noCalendar){if(i.appendChild((b.monthNav=n("div","flatpickr-months"),b.yearElements=[],b.monthElements=[],b.prevMonthNav=n("span","flatpickr-prev-month"),b.prevMonthNav.innerHTML=b.config.prevArrow,b.nextMonthNav=n("span","flatpickr-next-month"),b.nextMonthNav.innerHTML=b.config.nextArrow,pi(),Object.defineProperty(b,"_hidePrevMonthArrow",{get:function(){return b.__hidePrevMonthArrow},set:function(n){b.__hidePrevMonthArrow!==n&&(r(b.prevMonthNav,"flatpickr-disabled",n),b.__hidePrevMonthArrow=n)}}),Object.defineProperty(b,"_hideNextMonthArrow",{get:function(){return b.__hideNextMonthArrow},set:function(n){b.__hideNextMonthArrow!==n&&(r(b.nextMonthNav,"flatpickr-disabled",n),b.__hideNextMonthArrow=n)}}),b.currentYearElement=b.yearElements[0],ti(),b.monthNav)),b.innerContainer=n("div","flatpickr-innerContainer"),b.config.weekNumbers){var f=function(){var t,i;return b.calendarContainer.classList.add("hasWeeks"),t=n("div","flatpickr-weekwrapper"),t.appendChild(n("span","flatpickr-weekday",b.l10n.weekAbbreviation)),i=n("div","flatpickr-weeks"),t.appendChild(i),{weekWrapper:t,weekNumbers:i}}(),e=f.weekWrapper,h=f.weekNumbers;b.innerContainer.appendChild(e);b.weekNumbers=h;b.weekWrapper=e}b.rContainer=n("div","flatpickr-rContainer");b.rContainer.appendChild(wi());b.daysContainer||(b.daysContainer=n("div","flatpickr-days"),b.daysContainer.tabIndex=-1);kt();b.rContainer.appendChild(b.daysContainer);b.innerContainer.appendChild(b.rContainer);i.appendChild(b.innerContainer)}b.config.enableTime&&i.appendChild(function(){var t,e,i,r,f;return b.calendarContainer.classList.add("hasTime"),b.config.noCalendar&&b.calendarContainer.classList.add("noCalendar"),t=g(b.config),b.timeContainer=n("div","flatpickr-time"),b.timeContainer.tabIndex=-1,e=n("span","flatpickr-time-separator",":"),i=v("flatpickr-hour",{"aria-label":b.l10n.hourAriaLabel}),b.hourElement=i.getElementsByTagName("input")[0],r=v("flatpickr-minute",{"aria-label":b.l10n.minuteAriaLabel}),b.minuteElement=r.getElementsByTagName("input")[0],b.hourElement.tabIndex=b.minuteElement.tabIndex=-1,b.hourElement.value=u(b.latestSelectedDateObj?b.latestSelectedDateObj.getHours():b.config.time_24hr?t.hours:function(n){switch(n%24){case 0:case 12:return 12;default:return n%12}}(t.hours)),b.minuteElement.value=u(b.latestSelectedDateObj?b.latestSelectedDateObj.getMinutes():t.minutes),b.hourElement.setAttribute("step",b.config.hourIncrement.toString()),b.minuteElement.setAttribute("step",b.config.minuteIncrement.toString()),b.hourElement.setAttribute("min",b.config.time_24hr?"0":"1"),b.hourElement.setAttribute("max",b.config.time_24hr?"23":"12"),b.hourElement.setAttribute("maxlength","2"),b.minuteElement.setAttribute("min","0"),b.minuteElement.setAttribute("max","59"),b.minuteElement.setAttribute("maxlength","2"),b.timeContainer.appendChild(i),b.timeContainer.appendChild(e),b.timeContainer.appendChild(r),b.config.time_24hr&&b.timeContainer.classList.add("time24hr"),b.config.enableSeconds&&(b.timeContainer.classList.add("hasSeconds"),f=v("flatpickr-second"),b.secondElement=f.getElementsByTagName("input")[0],b.secondElement.value=u(b.latestSelectedDateObj?b.latestSelectedDateObj.getSeconds():t.seconds),b.secondElement.setAttribute("step",b.minuteElement.getAttribute("step")),b.secondElement.setAttribute("min","0"),b.secondElement.setAttribute("max","59"),b.secondElement.setAttribute("maxlength","2"),b.timeContainer.appendChild(n("span","flatpickr-time-separator",":")),b.timeContainer.appendChild(f)),b.config.time_24hr||(b.amPM=n("span","flatpickr-am-pm",b.l10n.amPM[o((b.latestSelectedDateObj?b.hourElement.value:b.config.defaultHour)>11)]),b.amPM.title=b.l10n.toggleTitle,b.amPM.tabIndex=-1,b.timeContainer.appendChild(b.amPM)),b.timeContainer}());r(b.calendarContainer,"rangeMode","range"===b.config.mode);r(b.calendarContainer,"animate",!0===b.config.animate);r(b.calendarContainer,"multiMonth",b.config.showMonths>1);b.calendarContainer.appendChild(i);s=void 0!==b.config.appendTo&&void 0!==b.config.appendTo.nodeType;(b.config.inline||b.config.static)&&(b.calendarContainer.classList.add(b.config.inline?"inline":"static"),b.config.inline&&(!s&&b.element.parentNode?b.element.parentNode.insertBefore(b.calendarContainer,b._input.nextSibling):void 0!==b.config.appendTo&&b.config.appendTo.appendChild(b.calendarContainer)),b.config.static)&&(t=n("div","flatpickr-wrapper"),b.element.parentNode&&b.element.parentNode.insertBefore(t,b.element),t.appendChild(b.element),b.altInput&&t.appendChild(b.altInput),t.appendChild(b.calendarContainer));b.config.static||b.config.inline||(void 0!==b.config.appendTo?b.config.appendTo:window.document.body).appendChild(b.calendarContainer)}(),function(){var t,i;if(b.config.wrap&&["open","close","toggle","clear"].forEach(function(n){Array.prototype.forEach.call(b.element.querySelectorAll("[data-"+n+"]"),function(t){return ut(t,"click",b[n])})}),b.isMobile)return void function(){var t=b.config.enableTime?b.config.noCalendar?"time":"datetime-local":"date";b.mobileInput=n("input",b.input.className+" flatpickr-mobile");b.mobileInput.tabIndex=1;b.mobileInput.type=t;b.mobileInput.disabled=b.input.disabled;b.mobileInput.required=b.input.required;b.mobileInput.placeholder=b.input.placeholder;b.mobileFormatStr="datetime-local"===t?"Y-m-d\\TH:i:S":"date"===t?"Y-m-d":"H:i:S";b.selectedDates.length>0&&(b.mobileInput.defaultValue=b.mobileInput.value=b.formatDate(b.selectedDates[0],b.mobileFormatStr));b.config.minDate&&(b.mobileInput.min=b.formatDate(b.config.minDate,"Y-m-d"));b.config.maxDate&&(b.mobileInput.max=b.formatDate(b.config.maxDate,"Y-m-d"));b.input.getAttribute("step")&&(b.mobileInput.step=String(b.input.getAttribute("step")));b.input.type="hidden";void 0!==b.altInput&&(b.altInput.type="hidden");try{b.input.parentNode&&b.input.parentNode.insertBefore(b.mobileInput,b.input.nextSibling)}catch(t){}ut(b.mobileInput,"change",function(n){b.setDate(f(n).value,!1,b.mobileFormatStr);et("onChange");et("onClose")})}();t=tt(lr,50);b._debouncedChange=tt(ri,300);b.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&ut(b.daysContainer,"mouseover",function(n){"range"===b.config.mode&&hi(f(n))});ut(window.document.body,"keydown",cr);b.config.inline||b.config.static||ut(window,"resize",t);void 0!==window.ontouchstart?ut(window.document,"touchstart",si):ut(window.document,"mousedown",si);ut(window.document,"focus",si,{capture:!0});!0===b.config.clickOpens&&(ut(b._input,"focus",b.open),ut(b._input,"click",b.open));void 0!==b.daysContainer&&(ut(b.monthNav,"click",ar),ut(b.monthNav,["keyup","increment"],fr),ut(b.daysContainer,"click",tr));void 0!==b.timeContainer&&void 0!==b.minuteElement&&void 0!==b.hourElement&&(i=function(n){return f(n).select()},ut(b.timeContainer,["increment"],ht),ut(b.timeContainer,"blur",ht,{capture:!0}),ut(b.timeContainer,"click",er),ut([b.hourElement,b.minuteElement],["focus","click"],i),void 0!==b.secondElement&&ut(b.secondElement,"focus",function(){return b.secondElement&&b.secondElement.select()}),void 0!==b.amPM&&ut(b.amPM,"click",function(n){ht(n);ri()}));b.config.allowInput&&ut(b._input,"blur",hr)}();(b.selectedDates.length||b.config.noCalendar)&&(b.config.enableTime&&pt(b.config.noCalendar?b.latestSelectedDateObj:void 0),ot(!1));yi();var e=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);!b.isMobile&&e&&ni();et("onReady")}(),b}function h(n,t){for(var i,f=Array.prototype.slice.call(n).filter(function(n){return n instanceof HTMLElement}),r=[],u=0;u<f.length;u++){i=f[u];try{if(null!==i.getAttribute("data-fp-omit"))continue;void 0!==i._flatpickr&&(i._flatpickr.destroy(),i._flatpickr=void 0);i._flatpickr=et(i,t||{});r.push(i._flatpickr)}catch(n){console.error(n)}}return 1===r.length?r[0]:r}var i=function(){return(i=Object.assign||function(n){for(var r,i,t=1,u=arguments.length;t<u;t++)for(i in r=arguments[t])Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i]);return n}).apply(this,arguments)},p=["onChange","onClose","onDayCreate","onDestroy","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange","onPreCalendarPosition"],s={_disable:[],allowInput:!1,allowInvalidPreload:!1,altFormat:"F j, Y",altInput:!1,altInputClass:"form-control input",animate:"object"==typeof window&&-1===window.navigator.userAgent.indexOf("MSIE"),ariaDateFormat:"F j, Y",autoFillDefaultTime:!0,clickOpens:!0,closeOnSelect:!0,conjunction:", ",dateFormat:"Y-m-d",defaultHour:12,defaultMinute:0,defaultSeconds:0,disable:[],disableMobile:!1,enableSeconds:!1,enableTime:!1,errorHandler:function(n){return"undefined"!=typeof console&&console.warn(n)},getWeek:function(n){var t=new Date(n.getTime()),i;return t.setHours(0,0,0,0),t.setDate(t.getDate()+3-(t.getDay()+6)%7),i=new Date(t.getFullYear(),0,4),1+Math.round(((t.getTime()-i.getTime())/864e5-3+(i.getDay()+6)%7)/7)},hourIncrement:1,ignoredFocusElements:[],inline:!1,locale:"default",minuteIncrement:5,mode:"single",monthSelectorType:"dropdown",nextArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g><\/g><path d='M13.207 8.472l-7.854 7.854-0.707-0.707 7.146-7.146-7.146-7.148 0.707-0.707 7.854 7.854z' /><\/svg>",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g><\/g><path d='M5.207 8.471l7.146 7.147-0.707 0.707-7.853-7.854 7.854-7.853 0.707 0.707-7.147 7.146z' /><\/svg>",shorthandCurrentMonth:!1,showMonths:1,"static":!1,time_24hr:!1,weekNumbers:!1,wrap:!1},c={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:function(n){var t=n%100;if(t>3&&t<21)return"th";switch(t%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},u=function(n,t){return void 0===t&&(t=2),("000"+n).slice(-1*t)},o=function(n){return!0===n?1:0},w=function(n){return n instanceof Array?n:[n]},b=function(){},y=function(n,t,i){return i.months[t?"shorthand":"longhand"][n]},ut={D:b,F:function(n,t,i){n.setMonth(i.months.longhand.indexOf(t))},G:function(n,t){n.setHours(parseFloat(t))},H:function(n,t){n.setHours(parseFloat(t))},J:function(n,t){n.setDate(parseFloat(t))},K:function(n,t,i){n.setHours(n.getHours()%12+12*o(new RegExp(i.amPM[1],"i").test(t)))},M:function(n,t,i){n.setMonth(i.months.shorthand.indexOf(t))},S:function(n,t){n.setSeconds(parseFloat(t))},U:function(n,t){return new Date(1e3*parseFloat(t))},W:function(n,t,i){var u=parseInt(t),r=new Date(n.getFullYear(),0,2+7*(u-1),0,0,0,0);return r.setDate(r.getDate()-r.getDay()+i.firstDayOfWeek),r},Y:function(n,t){n.setFullYear(parseFloat(t))},Z:function(n,t){return new Date(t)},d:function(n,t){n.setDate(parseFloat(t))},h:function(n,t){n.setHours(parseFloat(t))},i:function(n,t){n.setMinutes(parseFloat(t))},j:function(n,t){n.setDate(parseFloat(t))},l:b,m:function(n,t){n.setMonth(parseFloat(t)-1)},n:function(n,t){n.setMonth(parseFloat(t)-1)},s:function(n,t){n.setSeconds(parseFloat(t))},u:function(n,t){return new Date(parseFloat(t))},w:b,y:function(n,t){n.setFullYear(2e3+parseFloat(t))}},k={D:"(\\w+)",F:"(\\w+)",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"",M:"(\\w+)",S:"(\\d\\d|\\d)",U:"(.+)",W:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"(\\w+)",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",u:"(.+)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},l={Z:function(n){return n.toISOString()},D:function(n,t,i){return t.weekdays.shorthand[l.w(n,t,i)]},F:function(n,t,i){return y(l.n(n,t,i)-1,!1,t)},G:function(n,t,i){return u(l.h(n,t,i))},H:function(n){return u(n.getHours())},J:function(n,t){return void 0!==t.ordinal?n.getDate()+t.ordinal(n.getDate()):n.getDate()},K:function(n,t){return t.amPM[o(n.getHours()>11)]},M:function(n,t){return y(n.getMonth(),!0,t)},S:function(n){return u(n.getSeconds())},U:function(n){return n.getTime()/1e3},W:function(n,t,i){return i.getWeek(n)},Y:function(n){return u(n.getFullYear(),4)},d:function(n){return u(n.getDate())},h:function(n){return n.getHours()%12?n.getHours()%12:12},i:function(n){return u(n.getMinutes())},j:function(n){return n.getDate()},l:function(n,t){return t.weekdays.longhand[n.getDay()]},m:function(n){return u(n.getMonth()+1)},n:function(n){return n.getMonth()+1},s:function(n){return n.getSeconds()},u:function(n){return n.getTime()},w:function(n){return n.getDay()},y:function(n){return String(n.getFullYear()).substring(2)}},rt=function(n){var i=n.config,t=void 0===i?s:i,r=n.l10n,f=void 0===r?c:r,u=n.isMobile,e=void 0!==u&&u;return function(n,i,r){var u=r||f;return void 0===t.formatDate||e?i.split("").map(function(i,r,f){return l[i]&&"\\"!==f[r-1]?l[i](n,u,t):"\\"!==i?i:""}).join(""):t.formatDate(n,i,u)}},d=function(n){var i=n.config,t=void 0===i?s:i,r=n.l10n,u=void 0===r?c:r;return function(n,i,r,f){var e,y,p,o,c,v;if(0===n||n){if(y=f||u,p=n,n instanceof Date)e=new Date(n.getTime());else if("string"!=typeof n&&void 0!==n.toFixed)e=new Date(n);else if("string"==typeof n)if(o=i||(t||s).dateFormat,c=String(n).trim(),"today"===c)e=new Date,r=!0;else if(/Z$/.test(c)||/GMT$/.test(c))e=new Date(n);else if(t&&t.parseDate)e=t.parseDate(n,o);else{e=t&&t.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0);for(var w=void 0,b=[],l=0,g=0,a="";l<o.length;l++){var h=o[l],d="\\"===h,nt="\\"===o[l-1]||d;k[h]&&!nt?(a+=k[h],v=new RegExp(a).exec(n),v&&(w=!0)&&b["Y"!==h?"push":"unshift"]({fn:ut[h],val:v[++g]})):d||(a+=".");b.forEach(function(n){var t=n.fn,i=n.val;return e=t(e,i,y)||e})}e=w?e:void 0}if(e instanceof Date&&!isNaN(e.getTime()))return!0===r&&e.setHours(0,0,0,0),e;t.errorHandler(new Error("Invalid date provided: "+p))}}},ft=864e5,t;return"function"!=typeof Object.assign&&(Object.assign=function(n){for(var f,i=[],t=1;t<arguments.length;t++)i[t-1]=arguments[t];if(!n)throw TypeError("Cannot convert undefined or null to object");for(var e=function(t){t&&Object.keys(t).forEach(function(i){return n[i]=t[i]})},r=0,u=i;r<u.length;r++)f=u[r],e(f);return n}),"undefined"!=typeof HTMLElement&&"undefined"!=typeof HTMLCollection&&"undefined"!=typeof NodeList&&(HTMLCollection.prototype.flatpickr=NodeList.prototype.flatpickr=function(n){return h(this,n)},HTMLElement.prototype.flatpickr=function(n){return h([this],n)}),t=function(n,t){return"string"==typeof n?h(window.document.querySelectorAll(n),t):n instanceof Node?h([n],t):h(n,t)},t.defaultConfig={},t.l10ns={en:i({},c),"default":i({},c)},t.localize=function(n){t.l10ns.default=i(i({},t.l10ns.default),n)},t.setDefaults=function(n){t.defaultConfig=i(i({},t.defaultConfig),n)},t.parseDate=d({}),t.formatDate=rt({}),t.compareDates=e,"undefined"!=typeof jQuery&&void 0!==jQuery.fn&&(jQuery.fn.flatpickr=function(n){return h(this,n)}),Date.prototype.fp_incr=function(n){return new Date(this.getFullYear(),this.getMonth(),this.getDate()+("string"==typeof n?parseInt(n,10):n))},"undefined"!=typeof window&&(window.flatpickr=t),t}),function(n){var t=0;jQuery.fn.ClassyLoupe=function(i){if(t++,this.length>1)return this.each(function(){n(this).ClassyLoupe(i)}),this;var i=n.extend({trigger:"mouseenter",shape:"circle",roundedCorners:10,loupeToggleSpeed:"medium",loupeToggleEasing:"linear",size:200,minSize:150,maxSize:250,glossy:!0,shadow:!0,resize:!0,sizeSnap:10,resizeAnimationSpeed:"medium",resizeAnimationEasing:"easeOutBack",canZoom:!0,zoomKey:90,zoom:100,minZoom:50,maxZoom:200,zoomSnap:5,zoomAnimationSpeed:"medium",zoomAnimationEasing:"easeOutBack",overlay:!0,overlayOpacity:.5,overlayEffectSpeed:"slow",overlayEffectEasing:"easeOutBack",overlayClassName:""},i||{}),o=jQuery(this),r="classyloupe-"+t,v="classyloupe_overlay-"+t,f=i.size,e,p=null,w=0,b=0,d=0,g=0,l=0,a=0,k=!1,c=!1,y=i.zoom,s=0,h=0,u,nt=!1;return this.each(function(){function t(){var o=f-2*n("#"+r+" .lglossy").css("marginTop"),e=f/2,t=0,u=0;i.shape==="circle"?u=t=e:i.shape==="rounded"&&(t=parseInt(n("#"+r).css("border-top-width")),u=t=i.roundedCorners-t);n("#"+r+" .glossy").stop().animate({width:o+"px",height:e+"px","-webkit-border-top-left-radius":t+"px","-webkit-border-top-right-radius":u+"px","-moz-border-radius-topleft":t+"px","-moz-border-radius-topright":u+"px","border-top-left-radius":t+"px","border-top-right-radius":u+"px"},{queue:!1,easing:i.resizeAnimationEasing,duration:i.resizeAnimationSpeed})}function tt(u,c){var p;if(k&&i.canZoom)y+i.zoomSnap*u>i.maxZoom||y+i.zoomSnap*u<i.minZoom||(y+=i.zoomSnap*u,l+=Math.round(d*i.zoomSnap/100)*u,a+=Math.round(g*i.zoomSnap/100)*u,p=c.pageY-this.offsetTop,s=Math.round(l/w*(c.pageX-this.offsetLeft))*-1+f/2,h=Math.round(a/b*p)*-1+f/2,n("#"+r).animate({"background-position":s+"px "+h+"px","background-size":l+"px "+a+"px"},{queue:!1,easing:i.zoomAnimationEasing,duration:i.zoomAnimationSpeed,complete:function(){e=n("#"+r).outerWidth();var t=new jQuery.Event("mousemove",{pageX:nt+e/2,pageY:tt+e/2});o.trigger(t)}}));else if(i.resize&&!k&&(p=u*i.sizeSnap,!(f+p>i.maxSize||f+p<i.minSize))){f+=p;var v=0,nt=Math.round(n("#"+r).offset().left-p),tt=Math.round(n("#"+r).offset().top-p);s+=p;h+=p;n("#"+r).stop();i.shape==="circle"?(v=f/2,n("#"+r).animate({width:f+"px",height:f+"px","-webkit-border-top-left-radius":v+"px","-webkit-border-top-right-radius":v+"px","-webkit-border-bottom-left-radius":v+"px","-webkit-border-bottom-right-radius":v+"px","-moz-border-radius-topleft":v+"px","-moz-border-radius-topright":v+"px","-moz-border-radius-bottomleft":v+"px","-moz-border-radius-bottomright":v+"px","border-top-left-radius":v+"px","border-top-right-radius":v+"px","border-bottom-left-radius":v+"px","border-bottom-right-radius":v+"px","background-position":s+"px "+h+"px",left:nt+"px",top:tt+"px"},{queue:!1,easing:i.resizeAnimationEasing,duration:i.resizeAnimationSpeed,complete:function(){e=n("#"+r).outerWidth();var t=new jQuery.Event("mousemove",{pageX:nt+e/2,pageY:tt+e/2});o.trigger(t)}})):i.shape==="rounded"?n("#"+r).animate({width:f+"px",height:f+"px","-webkit-border-radius":i.roundedCorners,"-moz-border-radius":i.roundedCorners,"border-radius":i.roundedCorners,"background-position":s+"px "+h+"px",left:nt+"px",top:tt+"px"},{queue:!1,easing:i.resizeAnimationEasing,duration:i.resizeAnimationSpeed,complete:function(){e=n("#"+r).outerWidth();var t=new jQuery.Event("mousemove",{pageX:nt+e/2,pageY:tt+e/2});o.trigger(t)}}):i.shape==="square"&&n("#"+r).animate({width:f+"px",height:f+"px","background-position":s+"px "+h+"px",left:nt+"px",top:tt+"px"},{queue:!1,easing:i.resizeAnimationEasing,duration:i.resizeAnimationSpeed,complete:function(){e=n("#"+r).outerWidth();var t=new jQuery.Event("mousemove",{pageX:nt+e/2,pageY:tt+e/2});o.trigger(t)}});i.glossy&&t()}}(function(){o.is("a")?(p=o.attr("href"),u=o.find("img")):(o.is("img")||o.is('input[type="image"]'))&&(p=o.attr("src"),u=o);w=u.width();b=u.height();n("body").append('<div class="classyloupe" id="'+r+'"><\/div>');var t=new Image;t.onload=function(){d=this.width;g=this.height;l=Math.round(d*y/100);a=Math.round(g*y/100);var t=f/2;n("#"+r).css({width:f+"px",height:f+"px","background-image":"url("+p+")","background-size":l+"px "+a+"px"});i.shape==="circle"?n("#"+r).css({"-webkit-border-radius":t+"px","-moz-border-radius":t+"px","border-radius":t+"px"}):i.shape==="rounded"&&n("#"+r).css({"-webkit-border-radius":i.roundedCorners,"-moz-border-radius":i.roundedCorners,"border-radius":i.roundedCorners+"px"});e=n("#"+r).outerWidth();i.glossy&&n("#"+r).append('<div class="lglossy"><\/div>');i.overlay&&(n("body").append("<div class='loverlay "+i.overlayClassName+"' id='"+v+"'><\/div>"),n("#"+v).css({top:u.offset().top+"px",left:u.offset().left+"px",width:u.outerWidth()+"px",height:u.outerHeight()+"px"}));i.shadow&&n("#"+r).addClass("lshadow")};t.src=p})();(i.resize||i.canZoom)&&!nt&&n.event.special.mousewheel&&n("#"+r).bind("mousewheel",function(n,t){return tt(t,n),!1});u.bind(i.trigger,function(u){return c?(n("#"+r).fadeOut(i.loupeToggleSpeed,i.loupeToggleEasing),c=!1,i.overlay&&n("#"+v).fadeOut(i.overlayEffectSpeed,i.overlayEffectEasing)):(n("#"+r).fadeIn(i.loupeToggleSpeed,i.loupeToggleEasing),c=!0,i.overlay&&n("#"+v).fadeTo(i.overlayEffectSpeed,i.overlayOpacity,i.overlayEffectEasing),t()),u.type==="click"?(u.preventDefault?u.preventDefault():u.returnValue=!1,!1):void 0});n("#"+r).bind("click",function(){u.trigger("click")});n(document).bind("mousemove",function(t){if(!c)return!0;var p=parseInt(u.css("border-left-width"))+parseInt(u.css("padding-left")),k=parseInt(u.css("border-top-width"))+parseInt(u.css("padding-top")),d=parseInt(u.css("border-right-width"))+parseInt(u.css("padding-right")),g=parseInt(u.css("border-bottom-width"))+parseInt(u.css("padding-bottom")),o=t.pageX-u.offset().left-p,y=t.pageY-u.offset().top-k,nt=Math.round(t.pageX-e/2),t=Math.round(t.pageY-e/2);s=Math.round(l/w*o)*-1+f/2;h=Math.round(a/b*y)*-1+f/2;n("#"+r).css({"background-position":s+"px "+h+"px"});n("#"+r).css({left:nt+"px",top:t+"px"});(o<-p||y<-k||o>w+d||y>b+g)&&(n("#"+r).fadeOut(i.loupeToggleSpeed),c=!1,i.overlay&&n("#"+v).fadeOut(i.overlayEffectSpeed))});n(document).keyup(function(n){if(n.which==i.zoomKey&&c)return k=!1,n.preventDefault?n.preventDefault():n.returnValue=!1,!1}).keydown(function(n){if(n.which==i.zoomKey&&c)return k=!0,n.preventDefault?n.preventDefault():n.returnValue=!1,!1})})}}(jQuery);jQuery.easing.jswing=jQuery.easing.swing;jQuery.extend(jQuery.easing,{def:"easeOutQuad",swing:function(n,t,i,r,u){return jQuery.easing[jQuery.easing.def](n,t,i,r,u)},easeInQuad:function(n,t,i,r,u){return r*(t/=u)*t+i},easeOutQuad:function(n,t,i,r,u){return-r*(t/=u)*(t-2)+i},easeInOutQuad:function(n,t,i,r,u){return(t/=u/2)<1?r/2*t*t+i:-r/2*(--t*(t-2)-1)+i},easeInCubic:function(n,t,i,r,u){return r*(t/=u)*t*t+i},easeOutCubic:function(n,t,i,r,u){return r*((t=t/u-1)*t*t+1)+i},easeInOutCubic:function(n,t,i,r,u){return(t/=u/2)<1?r/2*t*t*t+i:r/2*((t-=2)*t*t+2)+i},easeInQuart:function(n,t,i,r,u){return r*(t/=u)*t*t*t+i},easeOutQuart:function(n,t,i,r,u){return-r*((t=t/u-1)*t*t*t-1)+i},easeInOutQuart:function(n,t,i,r,u){return(t/=u/2)<1?r/2*t*t*t*t+i:-r/2*((t-=2)*t*t*t-2)+i},easeInQuint:function(n,t,i,r,u){return r*(t/=u)*t*t*t*t+i},easeOutQuint:function(n,t,i,r,u){return r*((t=t/u-1)*t*t*t*t+1)+i},easeInOutQuint:function(n,t,i,r,u){return(t/=u/2)<1?r/2*t*t*t*t*t+i:r/2*((t-=2)*t*t*t*t+2)+i},easeInSine:function(n,t,i,r,u){return-r*Math.cos(t/u*(Math.PI/2))+r+i},easeOutSine:function(n,t,i,r,u){return r*Math.sin(t/u*(Math.PI/2))+i},easeInOutSine:function(n,t,i,r,u){return-r/2*(Math.cos(Math.PI*t/u)-1)+i},easeInExpo:function(n,t,i,r,u){return t==0?i:r*Math.pow(2,10*(t/u-1))+i},easeOutExpo:function(n,t,i,r,u){return t==u?i+r:r*(-Math.pow(2,-10*t/u)+1)+i},easeInOutExpo:function(n,t,i,r,u){return t==0?i:t==u?i+r:(t/=u/2)<1?r/2*Math.pow(2,10*(t-1))+i:r/2*(-Math.pow(2,-10*--t)+2)+i},easeInCirc:function(n,t,i,r,u){return-r*(Math.sqrt(1-(t/=u)*t)-1)+i},easeOutCirc:function(n,t,i,r,u){return r*Math.sqrt(1-(t=t/u-1)*t)+i},easeInOutCirc:function(n,t,i,r,u){return(t/=u/2)<1?-r/2*(Math.sqrt(1-t*t)-1)+i:r/2*(Math.sqrt(1-(t-=2)*t)+1)+i},easeInElastic:function(n,t,i,r,u){var o=1.70158,f=0,e=r;return t==0?i:(t/=u)==1?i+r:(f||(f=u*.3),e<Math.abs(r)?(e=r,o=f/4):o=f/(2*Math.PI)*Math.asin(r/e),-(e*Math.pow(2,10*(t-=1))*Math.sin((t*u-o)*2*Math.PI/f))+i)},easeOutElastic:function(n,t,i,r,u){var o=1.70158,f=0,e=r;return t==0?i:(t/=u)==1?i+r:(f||(f=u*.3),e<Math.abs(r)?(e=r,o=f/4):o=f/(2*Math.PI)*Math.asin(r/e),e*Math.pow(2,-10*t)*Math.sin((t*u-o)*2*Math.PI/f)+r+i)},easeInOutElastic:function(n,t,i,r,u){var o=1.70158,f=0,e=r;return t==0?i:(t/=u/2)==2?i+r:(f||(f=u*.3*1.5),e<Math.abs(r)?(e=r,o=f/4):o=f/(2*Math.PI)*Math.asin(r/e),t<1)?-.5*e*Math.pow(2,10*(t-=1))*Math.sin((t*u-o)*2*Math.PI/f)+i:e*Math.pow(2,-10*(t-=1))*Math.sin((t*u-o)*2*Math.PI/f)*.5+r+i},easeInBack:function(n,t,i,r,u,f){return f==undefined&&(f=1.70158),r*(t/=u)*t*((f+1)*t-f)+i},easeOutBack:function(n,t,i,r,u,f){return f==undefined&&(f=1.70158),r*((t=t/u-1)*t*((f+1)*t+f)+1)+i},easeInOutBack:function(n,t,i,r,u,f){return(f==undefined&&(f=1.70158),(t/=u/2)<1)?r/2*t*t*(((f*=1.525)+1)*t-f)+i:r/2*((t-=2)*t*(((f*=1.525)+1)*t+f)+2)+i},easeInBounce:function(n,t,i,r,u){return r-jQuery.easing.easeOutBounce(n,u-t,0,r,u)+i},easeOutBounce:function(n,t,i,r,u){return(t/=u)<1/2.75?r*7.5625*t*t+i:t<2/2.75?r*(7.5625*(t-=1.5/2.75)*t+.75)+i:t<2.5/2.75?r*(7.5625*(t-=2.25/2.75)*t+.9375)+i:r*(7.5625*(t-=2.625/2.75)*t+.984375)+i},easeInOutBounce:function(n,t,i,r,u){return t<u/2?jQuery.easing.easeInBounce(n,t*2,0,r,u)*.5+i:jQuery.easing.easeOutBounce(n,t*2-u,0,r,u)*.5+r*.5+i}}),function(n){n.fn.equalHeights=function(t){var t=n.extend({minHeight:0,maxHeight:!1,overflow:"auto",extra:0},t),i=t.minHeight?t.minHeight:0;return this.each(function(){var t=n(this).height();t>i&&(i=t)}),t.maxHeight&&i>t.maxHeight&&(i=t.maxHeight),i+=t.extra,this.each(function(){n(this).height(i).css("overflow",t.overflow)})}}(jQuery),function(n){n.fn.flexisel=function(t){var v=n.extend({visibleItems:4,itemsToScroll:3,animationSpeed:400,infinite:!0,navigationTargetSelector:null,autoPlay:{enable:!1,interval:5e3,pauseOnHover:!0},responsiveBreakpoints:{portrait:{changePoint:480,visibleItems:1,itemsToScroll:1},landscape:{changePoint:640,visibleItems:2,itemsToScroll:2},tablet:{changePoint:768,visibleItems:3,itemsToScroll:3}},loaded:function(){},before:function(){},after:function(){},resize:function(){}},t),i=n(this),r=n.extend(v,t),f,e=!0,c,h=r.visibleItems,o=r.itemsToScroll,s=[],l,a,u={init:function(){return this.each(function(){u.appendHTML();u.setEventHandlers();u.initializeItems()})},initializeItems:function(){var e=r.responsiveBreakpoints,o,t;for(o in e)s.push(e[o]);s.sort(function(n,t){return n.changePoint-t.changePoint});t=i.children();t.first().addClass("index");f=u.getCurrentItemWidth();c=t.length;t.width(f);r.infinite&&(u.offsetItemsToBeginning(Math.floor(t.length/2)),i.css({left:-f*Math.floor(t.length/2)}));n(window).trigger("resize");i.fadeIn();r.loaded.call(this,i)},appendHTML:function(){if(i.addClass("nbs-flexisel-ul"),i.wrap("<div class='nbs-flexisel-container'><div class='nbs-flexisel-inner'><\/div><\/div>"),i.find("li").addClass("nbs-flexisel-item"),r.navigationTargetSelector&&n(r.navigationTargetSelector).length>0?n("<div class='nbs-flexisel-nav-left'><\/div><div class='nbs-flexisel-nav-right'><\/div>").appendTo(r.navigationTargetSelector):(r.navigationTargetSelector=i.parent(),n("<div class='nbs-flexisel-nav-left'><\/div><div class='nbs-flexisel-nav-right'><\/div>").insertAfter(i)),r.infinite){var t=i.children(),u=t.clone(),f=t.clone();i.prepend(u);i.append(f)}},setEventHandlers:function(){var o=this,t=i.children();n(window).on("resize",function(){e=!1;clearTimeout(l);l=setTimeout(function(){e=!0;u.calculateDisplay();f=u.getCurrentItemWidth();t.width(f);r.infinite?i.css({left:-f*Math.floor(t.length/2)}):(u.clearDisabled(),n(r.navigationTargetSelector).find(".nbs-flexisel-nav-left").addClass("disabled"),i.css({left:0}));r.resize.call(o,i)},100)});n(r.navigationTargetSelector).find(".nbs-flexisel-nav-left").on("click",function(){u.scroll(!0)});n(r.navigationTargetSelector).find(".nbs-flexisel-nav-right").on("click",function(){u.scroll(!1)});if(r.autoPlay.enable&&(u.setAutoplayInterval(),r.autoPlay.pauseOnHover===!0))i.on({mouseenter:function(){e=!1},mouseleave:function(){e=!0}});i[0].addEventListener("touchstart",u.touchHandler.handleTouchStart,!1);i[0].addEventListener("touchmove",u.touchHandler.handleTouchMove,!1)},calculateDisplay:function(){var i=n("html").width(),u=s[s.length-1].changePoint;for(var t in s)if(i>=u){h=r.visibleItems;o=r.itemsToScroll;break}else if(i<s[t].changePoint){h=s[t].visibleItems;o=s[t].itemsToScroll;break}else continue},scroll:function(n){if(typeof n=="undefined"&&(n=!0),e==!0){if(e=!1,r.before.call(this,i),f=u.getCurrentItemWidth(),r.autoPlay.enable&&clearInterval(a),r.infinite)i.animate({left:n?"+="+f*o:"-="+f*o},r.animationSpeed,function(){r.after.call(this,i);e=!0;n?u.offsetItemsToBeginning(o):u.offsetItemsToEnd(o);u.offsetSliderPosition(n)});else{var t=f*o;n?i.animate({left:u.calculateNonInfiniteLeftScroll(t)},r.animationSpeed,function(){r.after.call(this,i);e=!0}):i.animate({left:u.calculateNonInfiniteRightScroll(t)},r.animationSpeed,function(){r.after.call(this,i);e=!0})}r.autoPlay.enable&&u.setAutoplayInterval()}},touchHandler:{xDown:null,yDown:null,handleTouchStart:function(n){this.xDown=n.touches[0].clientX;this.yDown=n.touches[0].clientY},handleTouchMove:function(n){if(this.xDown&&this.yDown){var i=n.touches[0].clientX,r=n.touches[0].clientY,t=this.xDown-i,f=this.yDown-r;Math.abs(t)>0&&(t>0?u.scroll(!1):u.scroll(!0));this.xDown=null;this.yDown=null;e=!0}}},getCurrentItemWidth:function(){return i.parent().width()/h},offsetItemsToBeginning:function(n){typeof n=="undefined"&&(n=1);for(var t=0;t<n;t++)i.children().last().insertBefore(i.children().first())},offsetItemsToEnd:function(n){typeof n=="undefined"&&(n=1);for(var t=0;t<n;t++)i.children().first().insertAfter(i.children().last())},offsetSliderPosition:function(n){var t=parseInt(i.css("left").replace("px",""));t=n?t-f*o:t+f*o;i.css({left:t})},getOffsetPosition:function(){return parseInt(i.css("left").replace("px",""))},calculateNonInfiniteLeftScroll:function(t){return u.clearDisabled(),u.getOffsetPosition()+t>=0?(n(r.navigationTargetSelector).find(".nbs-flexisel-nav-left").addClass("disabled"),0):u.getOffsetPosition()+t},calculateNonInfiniteRightScroll:function(t){u.clearDisabled();var i=c*f-h*f;return u.getOffsetPosition()-t<=-i?(n(r.navigationTargetSelector).find(".nbs-flexisel-nav-right").addClass("disabled"),-i):u.getOffsetPosition()-t},setAutoplayInterval:function(){a=setInterval(function(){e&&u.scroll(!1)},r.autoPlay.interval)},clearDisabled:function(){var t=n(r.navigationTargetSelector);t.find(".nbs-flexisel-nav-left").removeClass("disabled");t.find(".nbs-flexisel-nav-right").removeClass("disabled")}};if(u[t])return u[t].apply(this,Array.prototype.slice.call(arguments,1));if(typeof t!="object"&&t)n.error('Method "'+method+'" does not exist in flexisel plugin!');else return u.init.apply(this)}}(jQuery),function(n){n.fn.frameAnimation=function(t){var i={endWithFrameOne:!1,delay:50,repeat:1,mouseOut:!0,hoverMode:!0,reverse:!0,startFrame:1};return t&&n.extend(i,t),t=i,this.each(function(){function p(n){return bgPos=n.css("background-position"),typeof bgPos=="undefined"&&(bgPos=n.css("background-position-x")+" "+n.css("background-position-y")),bgPos}var e=parseInt(n(this).outerHeight()),s=parseInt(p(n(this)).split(" ")[1]),i=s,a;t.imageHeight!=undefined&&(a=t.imageHeight,t.reverse==!0?(s=e-a,i=t.startFrame*e-a):(s=e-a,i=(t.startFrame-1)*e),n(this).css("background-position-y",i+"px"));var w=t.delay,o=t.repeat,h=t.repeat;t.numRepeatOut!=undefined&&(h=t.numRepeatOut);var r=1,v,u=!1,f=!1,y=t.hoverMode;var b=function(n){i+=e;n.css("background-position","0px "+i+"px")},k=function(n){i-=e;n.css("background-position","0px "+i+"px")},c=function(n,e){if(u!=!0){if(i=parseInt(p(n).split(" ")[1]),v=null,i>=0){if(i=s,r==e){e<h&&t.hoverMode==!0&&t.mouseOut==!0&&(r=h);t.mouseOut==!1&&(r=1,n.css("background-position","0px "+i+"px"));t.endWithFrameOne==!0&&y==!1&&(n.css("background-position","0px "+i+"px"),r=0);f=!1;return}r++}u==!1&&b(n);v=setTimeout(function(){c(n,e)},w)}},l=function(n,e){if(r>e&&(r=e),f!=!0){if(i=parseInt(p(n).split(" ")[1]),v=null,i<=s){if(i=0,r<=1){t.mouseOut==!1&&(r=1,n.css("background-position-y",i+"px"));u=!1;return}r--}f==!1&&k(n);v=setTimeout(function(){l(n,e)},w)}};y==!0&&t.mouseOut!=!1?t.reverse==!0?n(this).hover(function(t){return u=!1,f=!0,c(n(t.target),o),!1},function(t){return f=!1,u=!0,l(n(t.target),h),!1}):t.reverse==!1&&t.imageHeight!=undefined&&n(this).hover(function(t){return f=!1,u=!0,l(n(t.target),h),!1},function(t){return u=!1,f=!0,c(n(t.target),o),!1}):y==!0&&t.mouseOut==!1?t.reverse==!0?n(this).hover(function(t){return f==!1&&(f=!0,c(n(t.target),o)),!1},function(){return!1}):t.reverse==!1&&t.imageHeight!=undefined&&n(this).hover(function(t){return u==!1&&(u=!0,l(n(t.target),o)),!1},function(){return!1}):t.reverse==!0?c(n(this),o):t.reverse==!1&&t.imageHeight!=undefined&&l(n(this),o)}),this}}(jQuery),function(n){n.fn.hoverIntent=function(t,i,r){var u={interval:100,sensitivity:6,timeout:0};u=typeof t=="object"?n.extend(u,t):n.isFunction(i)?n.extend(u,{over:t,out:i,selector:r}):n.extend(u,{over:t,out:t,selector:i});var f,e,o,s,h=function(n){f=n.pageX;e=n.pageY},c=function(t,i){if(i.hoverIntent_t=clearTimeout(i.hoverIntent_t),Math.sqrt((o-f)*(o-f)+(s-e)*(s-e))<u.sensitivity)return n(i).off("mousemove.hoverIntent",h),i.hoverIntent_s=!0,u.over.apply(i,[t]);o=f;s=e;i.hoverIntent_t=setTimeout(function(){c(t,i)},u.interval)},a=function(n,t){return t.hoverIntent_t=clearTimeout(t.hoverIntent_t),t.hoverIntent_s=!1,u.out.apply(t,[n])},l=function(t){var r=n.extend({},t),i=this;if(i.hoverIntent_t&&(i.hoverIntent_t=clearTimeout(i.hoverIntent_t)),t.type==="mouseenter"){o=r.pageX;s=r.pageY;n(i).on("mousemove.hoverIntent",h);i.hoverIntent_s||(i.hoverIntent_t=setTimeout(function(){c(r,i)},u.interval))}else n(i).off("mousemove.hoverIntent",h),i.hoverIntent_s&&(i.hoverIntent_t=setTimeout(function(){a(r,i)},u.timeout))};return this.on({"mouseenter.hoverIntent":l,"mouseleave.hoverIntent":l},u.selector)}}(jQuery),function(n){n.fn.jclip=function(t,i,r,u){function e(){if(t=="remove"){f.parent().hasClass("__jclip_posobj")&&(f.parent().replaceWith(f),f.parent().hasClass("__jclip_wrapper")&&f.parent().replaceWith(f));return}if(t!=null&&i!=null){(r==null||u==null)&&(r=t,u=i,t=0,i=0);var s=!f.parent().hasClass("__jclip_posobj")||!f.parent().parent().hasClass("__jclip_wrapper"),o=null,e=null;s?(o=n(document.createElement("div")),o.css("overflow","hidden").addClass("__jclip_wrapper"),e=n(document.createElement("div")),e.css("position","relative").addClass("__jclip_posobj")):(e=f.parent(),o=e.parent());o.width(r).height(u).css("position","relative");e.css("left",t*-1).css("top",i*-1);s&&f.wrap(o).wrap(e)}}var f=n(this);e()}}(jQuery),function(n){var t=function(t,i){var u=n.extend({},n.fn.nivoSlider.defaults,i),v,p,r={currentSlide:0,currentImage:"",totalSlides:0,running:!1,paused:!1,stop:!1,controlNavEl:!1},f=n(t),e,o,y,s,h,l;if(f.data("nivo:vars",r).addClass("nivoSlider"),e=f.children(),e.each(function(){var t=n(this),i="",u,f;t.is("img")||(t.is("a")&&(t.addClass("nivo-imageLink"),i=t),t=t.find("img:first"));u=u===0?t.attr("width"):t.width();f=f===0?t.attr("height"):t.height();i!==""&&i.css("display","none");t.css("display","none");r.totalSlides++}),u.randomStart&&(u.startSlide=Math.floor(Math.random()*r.totalSlides)),u.startSlide>0&&(u.startSlide>=r.totalSlides&&(u.startSlide=r.totalSlides-1),r.currentSlide=u.startSlide),r.currentImage=n(e[r.currentSlide]).is("img")?n(e[r.currentSlide]):n(e[r.currentSlide]).find("img:first"),n(e[r.currentSlide]).is("a")&&n(e[r.currentSlide]).css("display","block"),o=n("<img/>").addClass("nivo-main-image").attr("slide",0),o.attr("src",r.currentImage.attr("src")).css({display:"block"}),f.append(o),n(window).resize(function(){f.children("img").width(f.width());n("img.nivo-main-image").stop().height("auto");n(".nivo-slice").remove();n(".nivo-box").remove()}),f.append(n('<div class="nivo-caption"><\/div>')),y=function(t){var u=n(".nivo-caption",f),i;r.currentImage.attr("title")!=""&&r.currentImage.attr("title")!=undefined?(i=r.currentImage.attr("title"),i.substr(0,1)=="#"&&(i=n(i).html()),u.css("display")=="block"?setTimeout(function(){u.html(i)},t.animSpeed):(u.html(i),u.stop().fadeIn(t.animSpeed))):u.stop().fadeOut(t.animSpeed)},y(u),s=0,!u.manualAdvance&&e.length>1&&(s=setInterval(function(){a(f,e,u,!1)},u.pauseTime)),u.directionNav){f.append('<div class="nivo-directionNav"><a class="nivo-prevNav">'+u.prevText+'<\/a><a class="nivo-nextNav">'+u.nextText+"<\/a><\/div>");n(f).on("click","a.nivo-prevNav",function(){if(r.running)return!1;clearInterval(s);s="";r.currentSlide-=2;a(f,e,u,"prev")});n(f).on("click","a.nivo-nextNav",function(){if(r.running)return!1;clearInterval(s);s="";a(f,e,u,"next")})}if(u.controlNav){for(r.controlNavEl=n('<div class="nivo-controlNav"><\/div>'),f.after(r.controlNavEl),h=0;h<e.length;h++)u.controlNavThumbs?(r.controlNavEl.addClass("nivo-thumbs-enabled"),l=e.eq(h),l.is("img")||(l=l.find("img:first")),l.attr("data-thumb")&&r.controlNavEl.append('<a class="nivo-control" rel="'+h+'"><img src="'+l.attr("data-thumb")+'" alt="" /><\/a>')):r.controlNavEl.append('<a class="nivo-control" rel="'+h+'">'+(h+1)+"<\/a>");n("a:eq("+r.currentSlide+")",r.controlNavEl).addClass("active");n("a",r.controlNavEl).bind("click",function(){if(r.running||n(this).hasClass("active"))return!1;clearInterval(s);s="";n("img.nivo-main-image").height("auto");r.currentSlide=n(this).attr("rel")-1;a(f,e,u,"control")})}u.pauseOnHover&&f.hover(function(){r.paused=!0;clearInterval(s);s=""},function(){r.paused=!1;s!==""||u.manualAdvance||(s=setInterval(function(){a(f,e,u,!1)},u.pauseTime))});f.bind("nivo:animFinished",function(){n("img.nivo-main-image").hide().height("auto");o.show().css({display:"block"});r.running=!1;n(e).each(function(){n(this).is("a")&&n(this).css("display","none")});n(e[r.currentSlide]).is("a")&&n(e[r.currentSlide]).css("display","block");s!==""||r.paused||u.manualAdvance||(s=setInterval(function(){a(f,e,u,!1)},u.pauseTime));u.afterChange.call(this)});var c=function(t,i,r){var s,u,f,e,h;for(n(r.currentImage).parent().is("a")&&n(r.currentImage).parent().css("display","block"),n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").width(t.width()).css("visibility","hidden").show(),s=n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").parent().is("a")?n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").parent().height():n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").height(),u=0;u<i.slices;u++)f=Math.round(t.width()/i.slices),h=f+"px",u===i.slices-1&&(h=t.width()-f*u+"px"),n("div.nivo-slice[slide="+r.currentSlide+"][name="+u+"]").length==0?(e=n('<div class="nivo-slice" slide="'+r.currentSlide+'" name="'+u+'"><img src="'+r.currentImage.attr("src")+'" style="position:absolute; width:'+t.width()+"px; height:auto; display:block !important; top:0; left:-"+(f+u*f-f)+'px;" /><\/div>'),t.append(e)):(e=n("div.nivo-slice[slide="+r.currentSlide+"][name="+u+"]"),e.show(),e.children("img").attr("style","position:absolute; width:"+t.width()+"px; height:auto; display:block !important; top:0; left:-"+(f+u*f-f)+"px;")),e.css({left:f*u+"px",width:h,height:s+"px",opacity:"0",overflow:"hidden"});n("img.nivo-main-image[slide="+r.currentSlide+"]").length==0?(o=n("<img/>").addClass("nivo-main-image").attr("slide",r.currentSlide),o.attr("src",r.currentImage.attr("src")),t.append(o)):o=n("img.nivo-main-image[slide="+r.currentSlide+"]");n(".nivo-slice",t).height(s);o.hide();n("img.nivo-main-image[slide="+v+"]").stop().animate({height:n(r.currentImage).height()},i.animSpeed);p=n(r.currentImage).height();v=r.currentSlide},w=function(t,i,r){var e,h,f,u,s,c;for(n(r.currentImage).parent().is("a")&&n(r.currentImage).parent().css("display","block"),n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").width(t.width()).css("visibility","hidden").show(),e=Math.round(t.width()/i.boxCols),h=Math.round(n('img[src="'+r.currentImage.attr("src")+'"]',t).not(".nivo-main-image,.nivo-control img").height()/i.boxRows),f=0;f<i.boxRows;f++)for(u=0;u<i.boxCols;u++)c=e+"px",u===i.boxCols-1&&(c=t.width()-e*u+"px"),n("div.nivo-box[slide="+r.currentSlide+"][name="+u+"][rel="+f+"]").length==0?(s=n('<div class="nivo-box" slide="'+r.currentSlide+'" name="'+u+'" rel="'+f+'"><img src="'+r.currentImage.attr("src")+'" style="position:absolute; width:'+t.width()+"px; height:auto; display:block; top:-"+h*f+"px; left:-"+e*u+'px;" /><\/div>'),t.append(s)):(s=n("div.nivo-slice[slide="+r.currentSlide+"][name="+u+"][rel="+f+"]"),s.show(),s.children("img").attr("style","position:absolute; width:"+t.width()+"px; height:auto; display:block !important; top:-"+h*f+"px; left:-"+e*u+"px;")),s.css({opacity:0,left:e*u+"px",top:h*f+"px",width:c}),n(".nivo-box[slide="+r.currentSlide+'][name="'+u+'"]',t).height(n('.nivo-box[name="'+u+'"] img',t).height()+"px");n("img.nivo-main-image[slide="+r.currentSlide+"]").length==0?(o=n("<img/>").addClass("nivo-main-image").attr("slide",r.currentSlide),o.attr("src",r.currentImage.attr("src")),t.append(o)):o=n("img.nivo-main-image[slide="+r.currentSlide+"]");o.hide();n("img.nivo-main-image[slide="+v+"]").stop().animate({height:n(r.currentImage).height()},i.animSpeed);p=n(r.currentImage).height();v=r.currentSlide},a=function(t,i,r,u){var f=t.data("nivo:vars"),e,v,ut,it,b,rt;if(f&&f.currentSlide===f.totalSlides-1&&r.lastSlide.call(this),(!f||f.stop)&&!u)return!1;r.beforeChange.call(this);u?(u==="prev"&&(o=n("img.nivo-main-image[slide="+f.currentSlide+"]")),u==="next"&&(o=n("img.nivo-main-image[slide="+f.currentSlide+"]"))):o=n("img.nivo-main-image[slide="+f.currentSlide+"]");f.currentSlide++;f.currentSlide===f.totalSlides&&(f.currentSlide=0,r.slideshowEnd.call(this));f.currentSlide<0&&(f.currentSlide=f.totalSlides-1);f.currentImage=n(i[f.currentSlide]).is("img")?n(i[f.currentSlide]):n(i[f.currentSlide]).find("img:first");r.controlNav&&(n("a",f.controlNavEl).removeClass("active"),n("a:eq("+f.currentSlide+")",f.controlNavEl).addClass("active"));y(r);n(".nivo-slice",t).hide();n(".nivo-box",t).hide();e=r.effect;v="";r.effect==="random"&&(v=["sliceDownRight","sliceDownLeft","sliceUpRight","sliceUpLeft","sliceUpDown","sliceUpDownLeft","fold","fade","boxRandom","boxRain","boxRainReverse","boxRainGrow","boxRainGrowReverse"],e=v[Math.floor(Math.random()*(v.length+1))],e===undefined&&(e="fade"));r.effect.indexOf(",")!==-1&&(v=r.effect.split(","),e=v[Math.floor(Math.random()*v.length)],e===undefined&&(e="fade"));f.currentImage.attr("data-transition")&&(e=f.currentImage.attr("data-transition"));f.running=!0;var s=0,h=0,a="",l="",d="",p="";if(e==="sliceDown"||e==="sliceDownRight"||e==="sliceDownLeft")c(t,r,f),s=0,h=0,a=n(".nivo-slice[slide="+f.currentSlide+"]",t),e==="sliceDownLeft"&&(a=n(".nivo-slice[slide="+f.currentSlide+"]",t)._reverse()),a.each(function(){var i=n(this);i.css({top:"0px"});h===r.slices-1?setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed,"",function(){t.trigger("nivo:animFinished")})},100+s):setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed)},100+s);s+=50;h++});else if(e==="sliceUp"||e==="sliceUpRight"||e==="sliceUpLeft")c(t,r,f),s=0,h=0,a=n(".nivo-slice[slide="+f.currentSlide+"]",t),e==="sliceUpLeft"&&(a=n(".nivo-slice[slide="+f.currentSlide+"]",t)._reverse()),a.each(function(){var i=n(this);i.css({bottom:"0px"});h===r.slices-1?setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed,"",function(){t.trigger("nivo:animFinished")})},100+s):setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed)},100+s);s+=50;h++});else if(e==="sliceUpDown"||e==="sliceUpDownRight"||e==="sliceUpDownLeft")c(t,r,f),s=0,h=0,ut=0,a=n(".nivo-slice[slide="+f.currentSlide+"]",t),e==="sliceUpDownLeft"&&(a=n(".nivo-slice[slide="+f.currentSlide+"]",t)._reverse()),a.each(function(){var i=n(this);h===0?(i.css("top","0px"),h++):(i.css("bottom","0px"),h=0);ut===r.slices-1?setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed,"",function(){t.trigger("nivo:animFinished")})},100+s):setTimeout(function(){i.animate({opacity:"1.0"},r.animSpeed)},100+s);s+=50;ut++});else if(e==="fold")c(t,r,f),s=0,h=0,n(".nivo-slice[slide="+f.currentSlide+"]",t).each(function(){var i=n(this),u=i.width();i.css({top:"0px",width:"0px"});h===r.slices-1?setTimeout(function(){i.animate({width:u,opacity:"1.0"},r.animSpeed,"",function(){t.trigger("nivo:animFinished")})},100+s):setTimeout(function(){i.animate({width:u,opacity:"1.0"},r.animSpeed)},100+s);s+=50;h++});else if(e==="fade")c(t,r,f),l=n("div.nivo-slice[slide="+f.currentSlide+"]:first",t),l.css({width:t.width()+"px"}),l.animate({opacity:"1.0"},r.animSpeed*2,"",function(){t.trigger("nivo:animFinished")});else if(e==="slideInRight")c(t,r,f),l=n(".nivo-slice[slide="+f.currentSlide+"]:first",t),l.css({width:"0px",opacity:"1"}),l.animate({width:t.width()+"px"},r.animSpeed*2,"",function(){t.trigger("nivo:animFinished")});else if(e==="slideInLeft")c(t,r,f),l=n(".nivo-slice[slide="+f.currentSlide+"]:first",t),l.css({width:"0px",opacity:"1",left:"",right:"0px"}),l.animate({width:t.width()+"px"},r.animSpeed*2,"",function(){l.css({left:"0px",right:""});t.trigger("nivo:animFinished")});else if(e==="boxRandom")w(t,r,f),d=r.boxCols*r.boxRows,h=0,s=0,p=k(n(".nivo-box[slide="+f.currentSlide+"]",t)),p.each(function(){var i=n(this);h===d-1?setTimeout(function(){i.animate({opacity:"1"},r.animSpeed,"",function(){t.trigger("nivo:animFinished")})},100+s):setTimeout(function(){i.animate({opacity:"1"},r.animSpeed)},100+s);s+=20;h++});else if(e==="boxRain"||e==="boxRainReverse"||e==="boxRainGrow"||e==="boxRainGrowReverse"){w(t,r,f);d=r.boxCols*r.boxRows;h=0;s=0;var g=0,nt=0,tt=[];for(tt[g]=[],p=n(".nivo-box[slide="+f.currentSlide+"]",t),(e==="boxRainReverse"||e==="boxRainGrowReverse")&&(p=n(".nivo-box[slide="+f.currentSlide+"]",t)._reverse()),p.each(function(){tt[g][nt]=n(this);nt++;nt===r.boxCols&&(g++,nt=0,tt[g]=[])}),it=0;it<r.boxCols*2;it++){for(b=it,rt=0;rt<r.boxRows;rt++)b>=0&&b<r.boxCols&&(function(i,u,f,o,s){var h=n(tt[i][u]),c=h.width(),l=h.height();(e==="boxRainGrow"||e==="boxRainGrowReverse")&&h.width(0).height(0);o===s-1?setTimeout(function(){h.animate({opacity:"1",width:c,height:l},r.animSpeed/1.3,"",function(){t.trigger("nivo:animFinished")})},100+f):setTimeout(function(){h.animate({opacity:"1",width:c,height:l},r.animSpeed/1.3)},100+f)}(rt,b,s,h,d),h++),b--;s+=100}}},k=function(n){for(var i,r,t=n.length;t;i=parseInt(Math.random()*t,10),r=n[--t],n[t]=n[i],n[i]=r);return n},b=function(n){this.console&&typeof console.log!="undefined"&&console.log(n)};return this.stop=function(){n(t).data("nivo:vars").stop||(n(t).data("nivo:vars").stop=!0,b("Stop Slider"))},this.start=function(){n(t).data("nivo:vars").stop&&(n(t).data("nivo:vars").stop=!1,b("Start Slider"))},u.afterLoad.call(this),this};n.fn.nivoSlider=function(i){return this.each(function(){var r=n(this),u;if(r.data("nivoslider"))return r.data("nivoslider");u=new t(this,i);r.data("nivoslider",u)})};n.fn.nivoSlider.defaults={effect:"random",slices:15,boxCols:8,boxRows:4,animSpeed:500,pauseTime:3e3,startSlide:0,directionNav:!0,controlNav:!0,controlNavThumbs:!1,pauseOnHover:!0,manualAdvance:!1,prevText:"Prev",nextText:"Next",randomStart:!1,beforeChange:function(){},afterChange:function(){},slideshowEnd:function(){},lastSlide:function(){},afterLoad:function(){}};n.fn._reverse=[].reverse}(jQuery),function(n){var t=n(window),i=t.height();t.resize(function(){i=t.height()});n.fn.parallax=function(r,u,f){function o(){var f=t.scrollTop();e.each(function(){var t=n(this),o=t.offset().top,c=s(t);o+c<f||o>f+i||e.css("backgroundPosition",r+" "+Math.round((h-f)*u)+"px")})}var e=n(this),s,h;e.each(function(){h=e.offset().top});s=f?function(n){return n.outerHeight(!0)}:function(n){return n.height()};(arguments.length<1||r===null)&&(r="50%");(arguments.length<2||u===null)&&(u=.1);(arguments.length<3||f===null)&&(f=!0);t.bind("scroll",o).resize(o);o()}}(jQuery),function(n){function i(i,f){if(this.element=i,this.options=n.extend({},r,f),n(this.element).data("max-height",this.options.maxHeight),n(this.element).data("height-margin",this.options.heightMargin),delete this.options.maxHeight,this.options.embedCSS&&!u){var e=".readmore-js-toggle, .readmore-js-section { "+this.options.sectionCSS+" } .readmore-js-section { overflow: hidden; }";(function(n,t){var i=n.createElement("style");i.type="text/css";i.styleSheet?i.styleSheet.cssText=t:i.appendChild(n.createTextNode(t));n.getElementsByTagName("head")[0].appendChild(i)})(document,e);u=!0}this._defaults=r;this._name=t;this.init()}var t="readmore",r={speed:100,maxHeight:200,heightMargin:16,moreLink:'<a href="#">Read More<\/a>',lessLink:'<a href="#">Close<\/a>',embedCSS:!0,sectionCSS:"display: block; width: 100%;",startOpen:!1,expandedClass:"readmore-js-expanded",collapsedClass:"readmore-js-collapsed",beforeToggle:function(){},afterToggle:function(){}},u=!1;i.prototype={init:function(){var t=this;n(this.element).each(function(){var i=n(this),r=i.css("max-height").replace(/[^-\d\.]/g,"")>i.data("max-height")?i.css("max-height").replace(/[^-\d\.]/g,""):i.data("max-height"),f=i.data("height-margin"),u;if(i.css("max-height")!="none"&&i.css("max-height","none"),t.setBoxHeight(i),i.outerHeight(!0)<=r+f)return!0;i.addClass("readmore-js-section "+t.options.collapsedClass).data("collapsedHeight",r);u=t.options.startOpen?t.options.lessLink:t.options.moreLink;i.after(n(u).on("click",function(n){t.toggleSlider(this,i,n)}).addClass("readmore-js-toggle"));t.options.startOpen||i.css({height:r})});n(window).on("resize",function(){t.resizeBoxes()})},toggleSlider:function(t,i,r){r.preventDefault();var u=this,f=newLink=sectionClass="",e=!1,o=n(i).data("collapsedHeight");n(i).height()<=o?(f=n(i).data("expandedHeight")+"px",newLink="lessLink",e=!0,sectionClass=u.options.expandedClass):(f=o,newLink="moreLink",sectionClass=u.options.collapsedClass);u.options.beforeToggle(t,i,e);n(i).animate({height:f},{duration:u.options.speed,complete:function(){u.options.afterToggle(t,i,e);n(t).replaceWith(n(u.options[newLink]).on("click",function(n){u.toggleSlider(this,i,n)}).addClass("readmore-js-toggle"));n(this).removeClass(u.options.collapsedClass+" "+u.options.expandedClass).addClass(sectionClass)}})},setBoxHeight:function(n){var t=n.clone().css({height:"auto",width:n.width(),overflow:"hidden"}).insertAfter(n),i=t.outerHeight(!0);t.remove();n.data("expandedHeight",i)},resizeBoxes:function(){var t=this;n(".readmore-js-section").each(function(){var i=n(this);t.setBoxHeight(i);(i.height()>i.data("expandedHeight")||i.hasClass(t.options.expandedClass)&&i.height()<i.data("expandedHeight"))&&i.css("height",i.data("expandedHeight"))})},destroy:function(){var t=this;n(this.element).each(function(){var i=n(this);i.removeClass("readmore-js-section "+t.options.collapsedClass+" "+t.options.expandedClass).css({"max-height":"",height:"auto"}).next(".readmore-js-toggle").remove();i.removeData()})}};n.fn[t]=function(r){var u=arguments;return r===undefined||typeof r=="object"?this.each(function(){if(n.data(this,"plugin_"+t)){var u=n.data(this,"plugin_"+t);u.destroy.apply(u)}n.data(this,"plugin_"+t,new i(this,r))}):typeof r=="string"&&r[0]!=="_"&&r!=="init"?this.each(function(){var f=n.data(this,"plugin_"+t);f instanceof i&&typeof f[r]=="function"&&f[r].apply(f,Array.prototype.slice.call(u,1))}):void 0}}(jQuery),function(n){n.fn.rotateTableCellContent=function(t){var u=(t?t.className:!1)||"vertical",i=n("."+u,this),r=[];i.each(function(){var t=n(this),u=t.text(),e=t.height(),o=t.width(),i=n("<div>"),f=n("<div>",{text:u,"class":"rotated"});i.append(f);r.push(i)});i.each(function(t){n(this).html(r[t])})}}(jQuery),function(n,t){"use strict";typeof define=="function"&&define.amd?define(["jquery"],function(i){return t(i,n,n.document)}):typeof module=="object"&&module.exports?module.exports=t(require("jquery"),n,n.document):t(jQuery,n,n.document)}(typeof window!="undefined"?window:this,function(n,t,i,r){"use strict";function ft(){return s.height()+u.offset}function a(i,r,f,e){if(et===i&&(f=!1),w===!0)return!0;if(v[i]){if(tt=!1,it===!0&&(u.afterRender(),it=!1),f&&typeof u.before=="function"&&u.before(i,y)===!1)return!0;if(b=1,ut=o[i],it===!1&&et>i&&e===!1&&p[i]&&(l=ft(),b=parseInt(y[i].outerHeight()/l),ut=parseInt(o[i])+(y[i].outerHeight()-l)),u.updateHash&&u.sectionName&&!(it===!0&&i===0))if(history.pushState)try{history.replaceState(null,null,v[i])}catch(s){t.console&&console.warn("Scrollify warning: BasePage must be hosted to manipulate the hash value.")}else t.location.hash=v[i];if(et=i,r)n(u.target).stop().scrollTop(ut),f&&u.after(i,y);else{if(g=!0,n().velocity?n(u.target).stop().velocity("scroll",{duration:u.scrollSpeed,easing:u.easing,offset:ut,mobileHA:!1}):n(u.target).stop().animate({scrollTop:ut},u.scrollSpeed,u.easing),t.location.hash.length&&u.sectionName&&t.console)try{n(t.location.hash).length&&console.warn("Scrollify warning: ID matches hash value - this will cause the page to anchor.")}catch(s){}n(u.target).promise().done(function(){g=!1;it=!1;f&&u.after(i,y)})}}}function vt(n){function t(t){for(var r=0,u=n.slice(Math.max(n.length-t,1)),i=0;i<u.length;i++)r+=u[i];return Math.ceil(r/t)}var i=t(10),r=t(70);return i>=r?!0:!1}function yt(n,t){for(var i=v.length;i>=0;i--)typeof n=="string"?v[i]===n&&(f=i,a(i,t,!0,!0)):i===n&&(f=i,a(i,t,!0,!0))}var o=[],v=[],y=[],p=[],f=0,et=0,b=1,ht=!1,ot,ct,s=n(t),l,k=s.scrollTop(),tt=!1,g=!1,st=!1,h,e,d,w=!1,nt=[],lt=(new Date).getTime(),it=!0,rt=!1,ut=0,at="onwheel"in i?"wheel":i.onmousewheel!==r?"mousewheel":"DOMMouseScroll",u={section:".section",sectionName:"section-name",interstitialSection:"",easing:"easeOutExpo",scrollSpeed:1100,offset:0,scrollbars:!0,target:"html,body",standardScrollElements:!1,setHeights:!0,overflowScroll:!0,updateHash:!0,touchScroll:!0,before:function(){},after:function(){},afterResize:function(){},afterRender:function(){}},c=function(r){function c(t){n().velocity?n(u.target).stop().velocity("scroll",{duration:u.scrollSpeed,easing:u.easing,offset:t,mobileHA:!1}):n(u.target).stop().animate({scrollTop:t},u.scrollSpeed,u.easing)}function et(t){t&&(k=s.scrollTop());var i=u.section;p=[];u.interstitialSection.length&&(i+=","+u.interstitialSection);u.scrollbars===!1&&(u.overflowScroll=!1);l=ft();n(i).each(function(t){var i=n(this);u.setHeights?i.is(u.interstitialSection)?p[t]=!1:i.css("height","auto").outerHeight()<l||i.css("overflow")==="hidden"?(i.css({height:l}),p[t]=!1):(i.css({height:i.height()}),p[t]=u.overflowScroll?!0:!1):p[t]=i.outerHeight()<l||u.overflowScroll===!1?!1:!0});t&&s.scrollTop(k)}function yt(i){var r=u.section;u.interstitialSection.length&&(r+=","+u.interstitialSection);o=[];v=[];y=[];n(r).each(function(i){var e=n(this);o[i]=i>0?parseInt(e.offset().top)+u.offset:parseInt(e.offset().top);u.sectionName&&e.data(u.sectionName)?v[i]="#"+e.data(u.sectionName).toString().replace(/ /g,"-"):e.is(u.interstitialSection)===!1?v[i]="#"+(i+1):(v[i]="#",i===n(r).length-1&&i>1&&(o[i]=o[i-1]+(parseInt(n(n(r)[i-1]).outerHeight())-parseInt(n(t).height()))+parseInt(e.outerHeight())));y[i]=e;try{n(v[i]).length&&t.console&&console.warn("Scrollify warning: Section names can't match IDs - this will cause the browser to anchor.")}catch(s){}t.location.hash===v[i]&&(f=i,ht=!0)});!0===i&&a(f,!1,!1,!1)}function it(){return p[f]?(k=s.scrollTop(),k>parseInt(o[f])?!1:!0):!0}function ut(){return p[f]?(k=s.scrollTop(),l=ft(),k<parseInt(o[f])+(y[f].outerHeight()-l)-28?!1:!0):!0}if(rt=!0,n.easing.easeOutExpo=function(n,t,i,r,u){return t==u?i+r:r*(-Math.pow(2,-10*t/u)+1)+i},h={handleMousedown:function(){if(w===!0)return!0;tt=!1;st=!1},handleMouseup:function(){if(w===!0)return!0;tt=!0;st&&h.calculateNearest(!1,!0)},handleScroll:function(){if(w===!0)return!0;ot&&clearTimeout(ot);ot=setTimeout(function(){if(st=!0,tt===!1)return!1;tt=!1;h.calculateNearest(!1,!0)},200)},calculateNearest:function(n,t){k=s.scrollTop();for(var i=1,h=o.length,r=0,e=Math.abs(o[0]-k),u;i<h;i++)u=Math.abs(o[i]-k),u<e&&(e=u,r=i);(ut()&&r>f||it())&&(f=r,a(r,n,t,!1))},wheelHandler:function(i){var r,e,s;if(w===!0||u.standardScrollElements&&(n(i.target).is(u.standardScrollElements)||n(i.target).closest(u.standardScrollElements).length))return!0;if(p[f]||i.preventDefault(),r=(new Date).getTime(),i=i||t.event,e=i.originalEvent.wheelDelta||-i.originalEvent.deltaY||-i.originalEvent.detail,s=Math.max(-1,Math.min(1,e)),nt.length>149&&nt.shift(),nt.push(Math.abs(e)),r-lt>200&&(nt=[]),lt=r,g)return!1;if(s<0){if(f<o.length-1&&ut())if(vt(nt))i.preventDefault(),f++,g=!0,a(f,!1,!0,!1);else return!1}else if(s>0&&f>0&&it())if(vt(nt))i.preventDefault(),f--,g=!0,a(f,!1,!0,!1);else return!1},keyHandler:function(t){if(w===!0||i.activeElement.readOnly===!1||u.standardScrollElements&&(n(t.target).is(u.standardScrollElements)||n(t.target).closest(u.standardScrollElements).length))return!0;if(g===!0)return!1;t.keyCode==38||t.keyCode==33?f>0&&it()&&(t.preventDefault(),f--,a(f,!1,!0,!1)):(t.keyCode==40||t.keyCode==34)&&f<o.length-1&&ut()&&(t.preventDefault(),f++,a(f,!1,!0,!1))},init:function(){if(u.scrollbars){s.on("mousedown",h.handleMousedown);s.on("mouseup",h.handleMouseup);s.on("scroll",h.handleScroll)}else n("body").css({overflow:"hidden"});s.on(at,h.wheelHandler);s.on("keydown",h.keyHandler)}},e={touches:{touchstart:{y:-1,x:-1},touchmove:{y:-1,x:-1},touchend:!1,direction:"undetermined"},options:{distance:30,timeGap:800,timeStamp:(new Date).getTime()},touchHandler:function(t){if(w===!0||u.standardScrollElements&&(n(t.target).is(u.standardScrollElements)||n(t.target).closest(u.standardScrollElements).length))return!0;var i;if(typeof t!="undefined"&&typeof t.touches!="undefined"){i=t.touches[0];switch(t.type){case"touchstart":e.touches.touchstart.y=i.pageY;e.touches.touchmove.y=-1;e.touches.touchstart.x=i.pageX;e.touches.touchmove.x=-1;e.options.timeStamp=(new Date).getTime();e.touches.touchend=!1;case"touchmove":e.touches.touchmove.y=i.pageY;e.touches.touchmove.x=i.pageX;e.touches.touchstart.y!==e.touches.touchmove.y&&Math.abs(e.touches.touchstart.y-e.touches.touchmove.y)>Math.abs(e.touches.touchstart.x-e.touches.touchmove.x)&&(t.preventDefault(),e.touches.direction="y",e.options.timeStamp+e.options.timeGap<(new Date).getTime()&&e.touches.touchend==!1&&(e.touches.touchend=!0,e.touches.touchstart.y>-1&&Math.abs(e.touches.touchmove.y-e.touches.touchstart.y)>e.options.distance&&(e.touches.touchstart.y<e.touches.touchmove.y?e.up():e.down())));break;case"touchend":e.touches[t.type]===!1&&(e.touches[t.type]=!0,e.touches.touchstart.y>-1&&e.touches.touchmove.y>-1&&e.touches.direction==="y"&&(Math.abs(e.touches.touchmove.y-e.touches.touchstart.y)>e.options.distance&&(e.touches.touchstart.y<e.touches.touchmove.y?e.up():e.down()),e.touches.touchstart.y=-1,e.touches.touchstart.x=-1,e.touches.direction="undetermined"))}}},down:function(){f<o.length&&(ut()&&f<o.length-1?(f++,a(f,!1,!0,!1)):(l=ft(),Math.floor(y[f].height()/l)>b?(c(parseInt(o[f])+l*b),b+=1):c(parseInt(o[f])+(y[f].outerHeight()-l))))},up:function(){f>=0&&(it()&&f>0?(f--,a(f,!1,!0,!1)):b>2?(l=ft(),b-=1,c(parseInt(o[f])+l*b)):(b=1,c(parseInt(o[f]))))},init:function(){if(i.addEventListener&&u.touchScroll){var n={passive:!1};i.addEventListener("touchstart",e.touchHandler,n);i.addEventListener("touchmove",e.touchHandler,n);i.addEventListener("touchend",e.touchHandler,n)}}},d={refresh:function(n,t){clearTimeout(ct);ct=setTimeout(function(){et(!0);yt(t,!1);n&&u.afterResize()},400)},handleUpdate:function(){d.refresh(!1,!1)},handleResize:function(){d.refresh(!0,!1)},handleOrientation:function(){d.refresh(!0,!0)}},u=n.extend(u,r),et(!1),yt(!1,!0),!0===ht?a(f,!1,!0,!0):setTimeout(function(){h.calculateNearest(!0,!1)},200),o.length){h.init();e.init();s.on("resize",d.handleResize);i.addEventListener&&t.addEventListener("orientationchange",d.handleOrientation,!1)}};return c.move=function(t){if(t===r)return!1;t.originalEvent&&(t=n(this).attr("href"));yt(t,!1)},c.instantMove=function(n){if(n===r)return!1;yt(n,!0)},c.next=function(){f<v.length&&(f+=1,a(f,!1,!0,!0))},c.previous=function(){f>0&&(f-=1,a(f,!1,!0,!0))},c.instantNext=function(){f<v.length&&(f+=1,a(f,!0,!0,!0))},c.instantPrevious=function(){f>0&&(f-=1,a(f,!0,!0,!0))},c.destroy=function(){if(!rt)return!1;u.setHeights&&n(u.section).each(function(){n(this).css("height","auto")});s.off("resize",d.handleResize);u.scrollbars&&(s.off("mousedown",h.handleMousedown),s.off("mouseup",h.handleMouseup),s.off("scroll",h.handleScroll));s.off(at,h.wheelHandler);s.off("keydown",h.keyHandler);i.addEventListener&&u.touchScroll&&(i.removeEventListener("touchstart",e.touchHandler,!1),i.removeEventListener("touchmove",e.touchHandler,!1),i.removeEventListener("touchend",e.touchHandler,!1));o=[];v=[];y=[];p=[]},c.update=function(){if(!rt)return!1;d.handleUpdate()},c.current=function(){return y[f]},c.currentIndex=function(){return f},c.disable=function(){w=!0},c.enable=function(){w=!1;rt&&h.calculateNearest(!1,!1)},c.isDisabled=function(){return w},c.setOptions=function(i){if(!rt)return!1;typeof i=="object"?(u=n.extend(u,i),d.handleUpdate()):t.console&&console.warn("Scrollify warning: setOptions expects an object.")},n.scrollify=c,c}),function(n){"use strict";typeof define=="function"&&define.amd?define(["jquery"],n):typeof module!="undefined"&&module.exports?module.exports=n(require("jquery")):n(jQuery)}(function(n){"use strict";function r(t){return!t.nodeName||n.inArray(t.nodeName.toLowerCase(),["iframe","#document","html","body"])!==-1}function i(t){return n.isFunction(t)||n.isPlainObject(t)?t:{top:t,left:t}}var t=n.scrollTo=function(t,i,r){return n(window).scrollTo(t,i,r)};return t.defaults={axis:"xy",duration:0,limit:!0},n.fn.scrollTo=function(u,f,e){typeof f=="object"&&(e=f,f=0);typeof e=="function"&&(e={onAfter:e});u==="max"&&(u=9e9);e=n.extend({},t.defaults,e);f=f||e.duration;var o=e.queue&&e.axis.length>1;return o&&(f/=2),e.offset=i(e.offset),e.over=i(e.over),this.each(function(){function p(t){var i=n.extend({},e,{queue:!0,duration:f,complete:t&&function(){t.call(c,s,e)}});a.animate(h,i)}var y;if(u!==null){var l=r(this),c=l?this.contentWindow||window:this,a=n(c),s=u,h={},v;switch(typeof s){case"number":case"string":if(/^([+-]=?)?\d+(\.\d+)?(px|%)?$/.test(s)){s=i(s);break}s=l?n(s):n(s,c);case"object":if(s.length===0)return;(s.is||s.style)&&(v=(s=n(s)).offset())}y=n.isFunction(e.offset)&&e.offset(c,s)||e.offset;n.each(e.axis.split(""),function(n,i){var w=i==="x"?"Left":"Top",u=w.toLowerCase(),r="scroll"+w,b=a[r](),k=t.max(c,i),f;v?(h[r]=v[u]+(l?0:b-a.offset()[u]),e.margin&&(h[r]-=parseInt(s.css("margin"+w),10)||0,h[r]-=parseInt(s.css("border"+w+"Width"),10)||0),h[r]+=y[u]||0,e.over[u]&&(h[r]+=s[i==="x"?"width":"height"]()*e.over[u])):(f=s[u],h[r]=f.slice&&f.slice(-1)==="%"?parseFloat(f)/100*k:f);e.limit&&/^\d+$/.test(h[r])&&(h[r]=h[r]<=0?0:Math.min(h[r],k));!n&&e.axis.length>1&&(b===h[r]?h={}:o&&(p(e.onAfterFirst),h={}))});p(e.onAfter)}})},t.max=function(t,i){var u=i==="x"?"Width":"Height",f="scroll"+u;if(!r(t))return t[f]-n(t)[u.toLowerCase()]();var e="client"+u,o=t.ownerDocument||t.document,s=o.documentElement,h=o.body;return Math.max(s[f],h[f])-Math.min(s[e],h[e])},n.Tween.propHooks.scrollLeft=n.Tween.propHooks.scrollTop={get:function(t){return n(t.elem)[t.prop]()},set:function(t){var r=this.get(t),i;if(t.options.interrupt&&t._last&&t._last!==r)return n(t.elem).stop();i=Math.round(t.now);r!==i&&(n(t.elem)[t.prop](i),t._last=this.get(t))}},t}),function(n){typeof define=="function"&&define.amd?define(["jquery"],n):n(jQuery)}(function(n){var r=[],e=n(document),u=navigator.userAgent.toLowerCase(),f=n(window),i=[],t={ieQuirks:null,msie:/msie/.test(u)&&!/opera/.test(u),opera:/opera/.test(u)};t.ie6=t.msie&&/msie 6./.test(u)&&typeof XMLHttpRequest!="object";t.ie7=t.msie&&/msie 7.0/.test(u);n.modal=function(t,i){return n.modal.impl.init(t,i)};n.modal.close=function(){n.modal.impl.close()};n.modal.focus=function(t){n.modal.impl.focus(t)};n.modal.setContainerDimensions=function(){n.modal.impl.setContainerDimensions()};n.modal.setPosition=function(){n.modal.impl.setPosition()};n.modal.update=function(t,i){n.modal.impl.update(t,i)};n.fn.modal=function(t){return n.modal.impl.init(this,t)};n.modal.defaults={appendTo:"body",focus:!0,opacity:50,overlayId:"simplemodal-overlay",overlayCss:{},containerId:"simplemodal-container",containerCss:{},dataId:"simplemodal-data",dataCss:{},minHeight:null,minWidth:null,maxHeight:null,maxWidth:null,autoResize:!1,autoPosition:!0,zIndex:1e3,close:!0,closeHTML:'<a class="modalCloseImg" title="Close"><\/a>',closeClass:"simplemodal-close",escClose:!0,overlayClose:!1,fixed:!0,position:null,persist:!1,modal:!0,onOpen:null,onShow:null,onClose:null};n.modal.impl={d:{},init:function(i,r){var u=this;if(u.d.data)return!1;if(t.ieQuirks=t.msie&&!n.support.boxModel,u.o=n.extend({},n.modal.defaults,r),u.zIndex=u.o.zIndex,u.occb=!1,typeof i=="object")i=i instanceof n?i:n(i),u.d.placeholder=!1,i.parent().parent().length>0&&(i.before(n("<span><\/span>").attr("id","simplemodal-placeholder").css({display:"none"})),u.d.placeholder=!0,u.display=i.css("display"),u.o.persist||(u.d.orig=i.clone(!0)));else if(typeof i=="string"||typeof i=="number")i=n("<div><\/div>").html(i);else return alert("SimpleModal Error: Unsupported data type: "+typeof i),u;return u.create(i),i=null,u.open(),n.isFunction(u.o.onShow)&&u.o.onShow.apply(u,[u.d]),u},create:function(u){var f=this;f.getDimensions();f.o.modal&&t.ie6&&(f.d.iframe=n('<iframe src="javascript:false;"><\/iframe>').css(n.extend(f.o.iframeCss,{display:"none",opacity:0,position:"fixed",height:i[0],width:i[1],zIndex:f.o.zIndex,top:0,left:0})).appendTo(f.o.appendTo));f.d.overlay=n("<div><\/div>").attr("id",f.o.overlayId).addClass("simplemodal-overlay").css(n.extend(f.o.overlayCss,{display:"none",opacity:f.o.opacity/100,height:f.o.modal?r[0]:0,width:f.o.modal?r[1]:0,position:"fixed",left:0,top:0,zIndex:f.o.zIndex+1})).appendTo(f.o.appendTo);f.d.container=n("<div><\/div>").attr("id",f.o.containerId).addClass("simplemodal-container").css(n.extend({position:f.o.fixed?"fixed":"absolute"},f.o.containerCss,{display:"none",zIndex:f.o.zIndex+2})).append(f.o.close&&f.o.closeHTML?n(f.o.closeHTML).addClass(f.o.closeClass):"").appendTo(f.o.appendTo);f.d.wrap=n("<div><\/div>").attr("tabIndex",-1).addClass("simplemodal-wrap").css({height:"100%",outline:0,width:"100%"}).appendTo(f.d.container);f.d.data=u.attr("id",u.attr("id")||f.o.dataId).addClass("simplemodal-data").css(n.extend(f.o.dataCss,{display:"none"})).appendTo("body");u=null;f.setContainerDimensions();f.d.data.appendTo(f.d.wrap);(t.ie6||t.ieQuirks)&&f.fixIE()},bindEvents:function(){var u=this;n("."+u.o.closeClass).bind("click.simplemodal",function(n){n.preventDefault();u.close()});u.o.modal&&u.o.close&&u.o.overlayClose&&u.d.overlay.bind("click.simplemodal",function(n){n.preventDefault();u.close()});e.bind("keydown.simplemodal",function(n){u.o.modal&&n.keyCode===9?u.watchTab(n):u.o.close&&u.o.escClose&&n.keyCode===27&&(n.preventDefault(),u.close())});f.bind("resize.simplemodal orientationchange.simplemodal",function(){u.getDimensions();u.o.autoResize?u.setContainerDimensions():u.o.autoPosition&&u.setPosition();t.ie6||t.ieQuirks?u.fixIE():u.o.modal&&(u.d.iframe&&u.d.iframe.css({height:i[0],width:i[1]}),u.d.overlay.css({height:r[0],width:r[1]}))})},unbindEvents:function(){n("."+this.o.closeClass).unbind("click.simplemodal");e.unbind("keydown.simplemodal");f.unbind(".simplemodal");this.d.overlay.unbind("click.simplemodal")},fixIE:function(){var i=this,t=i.o.position;n.each([i.d.iframe||null,i.o.modal?i.d.overlay:null,i.d.container.css("position")==="fixed"?i.d.container:null],function(n,i){var a,v,s,h;if(i){var e="document.body.clientHeight",o="document.body.clientWidth",y="document.body.scrollHeight",c="document.body.scrollLeft",l="document.body.scrollTop",p="document.body.scrollWidth",w="document.documentElement.clientHeight",b="document.documentElement.clientWidth",u="document.documentElement.scrollLeft",f="document.documentElement.scrollTop",r=i[0].style;r.position="absolute";n<2?(r.removeExpression("height"),r.removeExpression("width"),r.setExpression("height",""+y+" > "+e+" ? "+y+" : "+e+' + "px"'),r.setExpression("width",""+p+" > "+o+" ? "+p+" : "+o+' + "px"')):(t&&t.constructor===Array?(s=t[0]?typeof t[0]=="number"?t[0].toString():t[0].replace(/px/,""):i.css("top").replace(/px/,""),a=s.indexOf("%")===-1?s+" + (t = "+f+" ? "+f+" : "+l+') + "px"':parseInt(s.replace(/%/,""))+" * (("+w+" || "+e+") / 100) + (t = "+f+" ? "+f+" : "+l+') + "px"',t[1]&&(h=typeof t[1]=="number"?t[1].toString():t[1].replace(/px/,""),v=h.indexOf("%")===-1?h+" + (t = "+u+" ? "+u+" : "+c+') + "px"':parseInt(h.replace(/%/,""))+" * (("+b+" || "+o+") / 100) + (t = "+u+" ? "+u+" : "+c+') + "px"')):(a="("+w+" || "+e+") / 2 - (this.offsetHeight / 2) + (t = "+f+" ? "+f+" : "+l+') + "px"',v="("+b+" || "+o+") / 2 - (this.offsetWidth / 2) + (t = "+u+" ? "+u+" : "+c+') + "px"'),r.removeExpression("top"),r.removeExpression("left"),r.setExpression("top",a),r.setExpression("left",v))}})},focus:function(t){var i=this,u=t&&n.inArray(t,["first","last"])!==-1?t:"first",r=n(":input:enabled:visible:"+u,i.d.wrap);setTimeout(function(){r.length>0?r.focus():i.d.wrap.focus()},10)},getDimensions:function(){var t=this,n=typeof innerHeight=="undefined"?f.height():window.innerHeight;r=[e.height(),e.width()];i=[n,f.width()]},getVal:function(n,t){return n?typeof n=="number"?n:n==="auto"?0:n.indexOf("%")>0?parseInt(n.replace(/%/,""))/100*(t==="h"?i[0]:i[1]):parseInt(n.replace(/px/,"")):null},update:function(n,t){var i=this;if(!i.d.data)return!1;i.d.origHeight=i.getVal(n,"h");i.d.origWidth=i.getVal(t,"w");i.d.data.hide();n&&i.d.container.css("height",n);t&&i.d.container.css("width",t);i.setContainerDimensions();i.d.data.show();i.o.focus&&i.focus();i.unbindEvents();i.bindEvents()},setContainerDimensions:function(){var n=this,v=t.ie6||t.ie7,r=n.d.origHeight?n.d.origHeight:t.opera?n.d.container.height():n.getVal(v?n.d.container[0].currentStyle.height:n.d.container.css("height"),"h"),u=n.d.origWidth?n.d.origWidth:t.opera?n.d.container.width():n.getVal(v?n.d.container[0].currentStyle.width:n.d.container.css("width"),"w"),o=n.d.data.outerHeight(!0),s=n.d.data.outerWidth(!0),f;n.d.origHeight=n.d.origHeight||r;n.d.origWidth=n.d.origWidth||u;var l=n.o.maxHeight?n.getVal(n.o.maxHeight,"h"):null,a=n.o.maxWidth?n.getVal(n.o.maxWidth,"w"):null,h=l&&l<i[0]?l:i[0],c=a&&a<i[1]?a:i[1],e=n.o.minHeight?n.getVal(n.o.minHeight,"h"):"auto";r=r?n.o.autoResize&&r>h?h:r<e?e:r:o?o>h?h:n.o.minHeight&&e!=="auto"&&o<e?e:o:e;f=n.o.minWidth?n.getVal(n.o.minWidth,"w"):"auto";u=u?n.o.autoResize&&u>c?c:u<f?f:u:s?s>c?c:n.o.minWidth&&f!=="auto"&&s<f?f:s:f;n.d.container.css({height:r,width:u});n.d.wrap.css({overflow:o>r||s>u?"auto":"visible"});n.o.autoPosition&&n.setPosition()},setPosition:function(){var n=this,t,r,u=i[0]/2-n.d.container.outerHeight(!0)/2,e=i[1]/2-n.d.container.outerWidth(!0)/2,o=n.d.container.css("position")!=="fixed"?f.scrollTop():0;n.o.position&&Object.prototype.toString.call(n.o.position)==="[object Array]"?(t=o+(n.o.position[0]||u),r=n.o.position[1]||e):(t=o+u,r=e);n.d.container.css({left:r,top:t})},watchTab:function(t){var i=this,r;n(t.target).parents(".simplemodal-container").length>0?(i.inputs=n(":input:enabled:visible:first, :input:enabled:visible:last",i.d.data[0]),(!t.shiftKey&&t.target===i.inputs[i.inputs.length-1]||t.shiftKey&&t.target===i.inputs[0]||i.inputs.length===0)&&(t.preventDefault(),r=t.shiftKey?"last":"first",i.focus(r))):(t.preventDefault(),i.focus())},open:function(){var t=this;t.d.iframe&&t.d.iframe.show();n.isFunction(t.o.onOpen)?t.o.onOpen.apply(t,[t.d]):(t.d.overlay.show(),t.d.container.show(),t.d.data.show());t.o.focus&&t.focus();t.bindEvents()},close:function(){var t=this,i;if(!t.d.data)return!1;t.unbindEvents();n.isFunction(t.o.onClose)&&!t.occb?(t.occb=!0,t.o.onClose.apply(t,[t.d])):(t.d.placeholder?(i=n("#simplemodal-placeholder"),t.o.persist?i.replaceWith(t.d.data.removeClass("simplemodal-data").css("display",t.display)):(t.d.data.hide().remove(),i.replaceWith(t.d.orig))):t.d.data.hide().remove(),t.d.container.hide().remove(),t.d.overlay.hide(),t.d.iframe&&t.d.iframe.hide().remove(),t.d.overlay.remove(),t.d={})}}}),function(n){typeof define=="function"&&define.amd?define(["jquery"],n):typeof module=="object"&&module.exports?module.exports=n(require("jquery")):n(jQuery)}(function(n){var e=Array.prototype.slice,h=Array.prototype.splice,u={topSpacing:0,bottomSpacing:0,className:"is-sticky",wrapperClassName:"sticky-wrapper",center:!1,getWidthFrom:"",widthFromWrapper:!0,responsiveWidth:!1,zIndex:"inherit"},f=n(window),c=n(document),i=[],o=f.height(),r=function(){for(var r,u,h,y,e=f.scrollTop(),l=c.height(),a=l-o,v=e>a?a-e:0,s=0,p=i.length;s<p;s++){var t=i[s],w=t.stickyWrapper.offset().top,b=w-t.topSpacing-v;t.stickyWrapper.css("height",t.stickyElement.outerHeight());e<=b?t.currentTop!==null&&(t.stickyElement.css({width:"",position:"",top:"","z-index":""}),t.stickyElement.parent().removeClass(t.className),t.stickyElement.trigger("sticky-end",[t]),t.currentTop=null):(r=l-t.stickyElement.outerHeight()-t.topSpacing-t.bottomSpacing-e-v,r=r<0?r+t.topSpacing:t.topSpacing,t.currentTop!==r&&(t.getWidthFrom?(padding=t.stickyElement.innerWidth()-t.stickyElement.width(),u=n(t.getWidthFrom).width()-padding||null):t.widthFromWrapper&&(u=t.stickyWrapper.width()),u==null&&(u=t.stickyElement.width()),t.stickyElement.css("width",u).css("position","fixed").css("top",r).css("z-index",t.zIndex),t.stickyElement.parent().addClass(t.className),t.currentTop===null?t.stickyElement.trigger("sticky-start",[t]):t.stickyElement.trigger("sticky-update",[t]),t.currentTop===t.topSpacing&&t.currentTop>r||t.currentTop===null&&r<t.topSpacing?t.stickyElement.trigger("sticky-bottom-reached",[t]):t.currentTop!==null&&r===t.topSpacing&&t.currentTop<r&&t.stickyElement.trigger("sticky-bottom-unreached",[t]),t.currentTop=r),h=t.stickyWrapper.parent(),y=t.stickyElement.offset().top+t.stickyElement.outerHeight()>=h.offset().top+h.outerHeight()&&t.stickyElement.offset().top<=t.topSpacing,y?t.stickyElement.css("position","absolute").css("top","").css("bottom",0).css("z-index",""):t.stickyElement.css("position","fixed").css("top",r).css("bottom","").css("z-index",t.zIndex))}},s=function(){var u,e,t,r;for(o=f.height(),u=0,e=i.length;u<e;u++)t=i[u],r=null,t.getWidthFrom?t.responsiveWidth&&(r=n(t.getWidthFrom).width()):t.widthFromWrapper&&(r=t.stickyWrapper.width()),r!=null&&t.stickyElement.css("width",r)},t={init:function(r){return this.each(function(){var e=n.extend({},u,r),f=n(this),s=f.attr("id"),h=s?s+"-"+u.wrapperClassName:u.wrapperClassName,c=n("<div><\/div>").attr("id",h).addClass(e.wrapperClassName),o;f.wrapAll(function(){if(n(this).parent("#"+h).length==0)return c});o=f.parent();e.center&&o.css({width:f.outerWidth(),marginLeft:"auto",marginRight:"auto"});f.css("float")==="right"&&f.css({float:"none"}).parent().css({float:"right"});e.stickyElement=f;e.stickyWrapper=o;e.currentTop=null;i.push(e);t.setWrapperHeight(this);t.setupChangeListeners(this)})},setWrapperHeight:function(t){var i=n(t),r=i.parent();r&&r.css("height",i.outerHeight())},setupChangeListeners:function(n){if(window.MutationObserver){var i=new window.MutationObserver(function(i){(i[0].addedNodes.length||i[0].removedNodes.length)&&t.setWrapperHeight(n)});i.observe(n,{subtree:!0,childList:!0})}else window.addEventListener?(n.addEventListener("DOMNodeInserted",function(){t.setWrapperHeight(n)},!1),n.addEventListener("DOMNodeRemoved",function(){t.setWrapperHeight(n)},!1)):window.attachEvent&&(n.attachEvent("onDOMNodeInserted",function(){t.setWrapperHeight(n)}),n.attachEvent("onDOMNodeRemoved",function(){t.setWrapperHeight(n)}))},update:r,unstick:function(){return this.each(function(){for(var r=this,u=n(r),f=-1,t=i.length;t-->0;)i[t].stickyElement.get(0)===r&&(h.call(i,t,1),f=t);f!==-1&&(u.unwrap(),u.css({width:"",position:"",top:"",float:"","z-index":""}))})}};window.addEventListener?(window.addEventListener("scroll",r,!1),window.addEventListener("resize",s,!1)):window.attachEvent&&(window.attachEvent("onscroll",r),window.attachEvent("onresize",s));n.fn.sticky=function(i){if(t[i])return t[i].apply(this,e.call(arguments,1));if(typeof i!="object"&&i)n.error("Method "+i+" does not exist on jQuery.sticky");else return t.init.apply(this,arguments)};n.fn.unstick=function(i){if(t[i])return t[i].apply(this,e.call(arguments,1));if(typeof i!="object"&&i)n.error("Method "+i+" does not exist on jQuery.sticky");else return t.unstick.apply(this,arguments)};n(function(){setTimeout(r,0)})}),function(n,t){typeof exports=="object"&&typeof module!="undefined"?module.exports=t():typeof define=="function"&&define.amd?define(t):n.MicroModal=t()}(this,function(){"use strict";var t="0.3.1",i=function(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function");},r=function(){function n(n,t){for(var i,r=0;r<t.length;r++)i=t[r],i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,i.key,i)}return function(t,i,r){return i&&n(t.prototype,i),r&&n(t,r),t}}(),n=function(n){if(Array.isArray(n)){for(var t=0,i=Array(n.length);t<n.length;t++)i[t]=n[t];return i}return Array.from(n)};return function(){var o=["a[href]","area[href]",'input:not([disabled]):not([type="hidden"]):not([aria-hidden])',"select:not([disabled]):not([aria-hidden])","textarea:not([disabled]):not([aria-hidden])","button:not([disabled]):not([aria-hidden])","iframe","object","embed","[contenteditable]",'[tabindex]:not([tabindex^="-"])'],f=function(){function t(r){var y=r.targetModal,u=r.triggers,f=u===undefined?[]:u,e=r.onShow,p=e===undefined?function(){}:e,o=r.onClose,w=o===undefined?function(){}:o,s=r.openTrigger,b=s===undefined?"data-micromodal-trigger":s,h=r.closeTrigger,k=h===undefined?"data-micromodal-close":h,c=r.disableScroll,d=c===undefined?!1:c,l=r.disableFocus,g=l===undefined?!1:l,a=r.awaitCloseAnimation,nt=a===undefined?!1:a,v=r.debugMode,tt=v===undefined?!1:v;i(this,t);this.modal=document.getElementById(y);this.config={debugMode:tt,disableScroll:d,openTrigger:b,closeTrigger:k,onShow:p,onClose:w,awaitCloseAnimation:nt,disableFocus:g};f.length>0&&this.registerTriggers.apply(this,n(f));this.onClick=this.onClick.bind(this);this.onKeydown=this.onKeydown.bind(this)}return r(t,[{key:"registerTriggers",value:function(){for(var r=this,t=arguments.length,i=Array(t),n=0;n<t;n++)i[n]=arguments[n];i.forEach(function(n){n.addEventListener("click",function(){return r.showModal()})})}},{key:"showModal",value:function(){this.activeElement=document.activeElement;this.modal.setAttribute("aria-hidden","false");this.modal.classList.add("is-open");this.setFocusToFirstNode();this.scrollBehaviour("disable");this.addEventListeners();this.config.onShow(this.modal)}},{key:"closeModal",value:function(){var n=this.modal;this.modal.setAttribute("aria-hidden","true");this.removeEventListeners();this.scrollBehaviour("enable");this.activeElement.focus();this.config.onClose(this.modal);this.config.awaitCloseAnimation?this.modal.addEventListener("animationend",function t(){n.classList.remove("is-open");n.removeEventListener("animationend",t,!1)},!1):n.classList.remove("is-open")}},{key:"scrollBehaviour",value:function(n){if(this.config.disableScroll){var t=document.querySelector("body");switch(n){case"enable":Object.assign(t.style,{overflow:"initial",height:"initial"});break;case"disable":Object.assign(t.style,{overflow:"hidden",height:"100vh"})}}}},{key:"addEventListeners",value:function(){this.modal.addEventListener("touchstart",this.onClick);this.modal.addEventListener("click",this.onClick);document.addEventListener("keydown",this.onKeydown)}},{key:"removeEventListeners",value:function(){this.modal.removeEventListener("touchstart",this.onClick);this.modal.removeEventListener("click",this.onClick);document.removeEventListener("keydown",this.onKeydown)}},{key:"onClick",value:function(n){n.target.hasAttribute(this.config.closeTrigger)&&(this.closeModal(),n.preventDefault())}},{key:"onKeydown",value:function(n){n.keyCode===27&&this.closeModal(n);n.keyCode===9&&this.maintainFocus(n)}},{key:"getFocusableNodes",value:function(){var n=this.modal.querySelectorAll(o);return Object.keys(n).map(function(t){return n[t]})}},{key:"setFocusToFirstNode",value:function(){if(!this.config.disableFocus){var n=this.getFocusableNodes();n.length&&n[0].focus()}}},{key:"maintainFocus",value:function(n){var t=this.getFocusableNodes(),i;this.modal.contains(document.activeElement)?(i=t.indexOf(document.activeElement),n.shiftKey&&i===0&&(t[t.length-1].focus(),n.preventDefault()),n.shiftKey||i!==t.length-1||(t[0].focus(),n.preventDefault())):t[0].focus()}}]),t}(),u=null,s=function(n,t){var i=[];return n.forEach(function(n){var r=n.attributes[t].value;i[r]===undefined&&(i[r]=[]);i[r].push(n)}),i},e=function(n){if(!document.getElementById(n))return console.warn("MicroModal v"+t+": ❗Seems like you have missed %c'"+n+"'","background-color: #f8f9fa;color: #50596c;font-weight: bold;","ID somewhere in your code. Refer example below to resolve it."),console.warn("%cExample:","background-color: #f8f9fa;color: #50596c;font-weight: bold;",'<div class="modal" id="'+n+'"><\/div>'),!1},h=function(n){if(n.length<=0)return console.warn("MicroModal v"+t+": ❗Please specify at least one %c'micromodal-trigger'","background-color: #f8f9fa;color: #50596c;font-weight: bold;","data attribute."),console.warn("%cExample:","background-color: #f8f9fa;color: #50596c;font-weight: bold;",'<a href="#" data-micromodal-trigger="my-modal"><\/a>'),!1},c=function(n,t){if(h(n),!t)return!0;for(var i in t)e(i);return!0},l=function(t){var i=Object.assign({},{openTrigger:"data-micromodal-trigger"},t),e=[].concat(n(document.querySelectorAll("["+i.openTrigger+"]"))),r=s(e,i.openTrigger),u,o;if(i.debugMode!==!0||c(e,r)!==!1)for(u in r)o=r[u],i.targetModal=u,i.triggers=[].concat(n(o)),new f(i)},a=function(n,t){var i=t||{};(i.targetModal=n,i.debugMode!==!0||e(n)!==!1)&&(u=new f(i),u.showModal())},v=function(){u.closeModal()};return{init:l,show:a,close:v}}()});!function(n,t){"function"==typeof define&&define.amd?define([],t(n)):"object"==typeof exports?module.exports=t(n):n.tabby=t(n)}("undefined"!=typeof global?global:this.window||this.global,function(n){"use strict";var i,t,r={},v="querySelector"in document&&"addEventListener"in n&&"classList"in document.createElement("_")&&"onhashchange"in n,o={selectorToggle:"[data-tab]",selectorToggleGroup:"[data-tabs]",selectorContent:"[data-tabs-pane]",selectorContentGroup:"[data-tabs-content]",toggleActiveClass:"active",contentActiveClass:"active",initClass:"js-tabby",stopVideo:!0,callback:function(){}},s=function(n,t,i){var u,r,f;if("[object Object]"===Object.prototype.toString.call(n))for(u in n)Object.prototype.hasOwnProperty.call(n,u)&&t.call(i,n[u],u,n);else for(r=0,f=n.length;r<f;r++)t.call(i,n[r],r,n)},f=function(){var n={},i=!1,t=0,e=arguments.length,r,u;for("[object Boolean]"===Object.prototype.toString.call(arguments[0])&&(i=arguments[0],t++),r=function(t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(n[r]=i&&"[object Object]"===Object.prototype.toString.call(t[r])?f(!0,n[r],t[r]):t[r])};t<e;t++)u=arguments[t],r(u);return n},u=function(n,t){for(Element.prototype.matches||(Element.prototype.matches=Element.prototype.matchesSelector||Element.prototype.mozMatchesSelector||Element.prototype.msMatchesSelector||Element.prototype.oMatchesSelector||Element.prototype.webkitMatchesSelector||function(n){for(var i=(this.document||this.ownerDocument).querySelectorAll(n),t=i.length;--t>=0&&i.item(t)!==this;);return t>-1});n&&n!==document;n=n.parentNode)if(n.matches(t))return n;return null},h=function(n){"#"===n.charAt(0)&&(n=n.substr(1));for(var t,r=String(n),f=r.length,i=-1,u="",e=r.charCodeAt(0);++i<f;){if(t=r.charCodeAt(i),0===t)throw new InvalidCharacterError("Invalid character: the input contains U+0000.");u+=t>=1&&t<=31||127==t||0===i&&t>=48&&t<=57||1===i&&t>=48&&t<=57&&45===e?"\\"+t.toString(16)+" ":t>=128||45===t||95===t||t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122?r.charAt(i):"\\"+r.charAt(i)}return"#"+u},y=function(n,t){var i,r,u;t.stopVideo&&!n.classList.contains(t.contentActiveClass)&&(i=n.querySelector("iframe"),r=n.querySelector("video"),i&&(u=i.src,i.src=u),r&&r.pause())},c=function(t,i){if(!t.hasAttribute("data-tab-no-focus")){if(!t.classList.contains(i.contentActiveClass))return void(t.hasAttribute("data-tab-focused")&&t.removeAttribute("tabindex"));var r={x:n.pageXOffset,y:n.pageYOffset};t.focus();document.activeElement.id!==t.id&&(t.setAttribute("tabindex","-1"),t.setAttribute("data-tab-focused",!0),t.focus());n.scrollTo(r.x,r.y)}},p=function(n,t){var r=u(n,t.selectorToggleGroup),i,f;r&&(f=r.querySelectorAll(t.selectorToggle),s(f,function(r){return r.hash===n.hash?(r.classList.add(t.toggleActiveClass),i=u(r,"li"),void(i&&i.classList.add(t.toggleActiveClass))):(r.classList.remove(t.toggleActiveClass),i=u(r,"li"),void(i&&i.classList.remove(t.toggleActiveClass)))}))},w=function(n,t){var r=document.querySelector(h(n)),i,f;r&&(i=u(r,t.selectorContentGroup),i&&(f=i.querySelectorAll(t.selectorContent),s(f,function(i){return i.id===n.substring(1)?(i.classList.add(t.contentActiveClass),void c(i,t)):(i.classList.remove(t.contentActiveClass),y(i,t),void c(i,t))})))};r.toggleTab=function(n,t,r){var u=f(i||o,r||{}),e=document.querySelectorAll(h(n));w(n,u);t&&p(t,u);u.callback(e,t)};var e=function(){var u=n.location.hash,f;(t&&(t.id=t.getAttribute("data-tab-id"),t=null),u)&&(f=document.querySelector(i.selectorToggle+'[href*="'+u+'"]'),r.toggleTab(u,f))},l=function(r){if(0===r.button&&!r.metaKey&&!r.ctrlKey){var f=u(r.target,i.selectorToggle);if(f&&f.hash){if(f.hash===n.location.hash)return void r.preventDefault();t=document.querySelector(f.hash);t&&(t.setAttribute("data-tab-id",t.id),t.id="")}}},a=function(n){if(t=u(n.target,i.selectorContent),t&&!t.classList.contains(i.contentActiveClass)){var r=t.id;t.setAttribute("data-tab-id",r);t.setAttribute("data-tab-no-focus",!0);t.id="";location.hash=r}};return r.destroy=function(){i&&(document.documentElement.classList.remove(i.initClass),document.removeEventListener("click",l,!1),document.removeEventListener("focus",a,!0),n.removeEventListener("hashchange",e,!1),i=null,t=null)},r.init=function(t){v&&(r.destroy(),i=f(o,t||{}),document.documentElement.classList.add(i.initClass),document.addEventListener("click",l,!1),document.addEventListener("focus",a,!0),n.addEventListener("hashchange",e,!1),e())},r});SetNav();MicroModal.init()