function prefixStyle(n){return s$.browser.vendor===""?n:(n=n.charAt(0).toUpperCase()+n.substr(1),s$.browser.vendor+n)}function getInternetExplorerVersion(){var n=-1,t,i;return navigator.appName==="Microsoft Internet Explorer"&&(t=navigator.userAgent,i=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})"),i.exec(t)!=null&&(n=parseFloat(RegExp.$1))),n}function checkVersion(){var n=window.navigator.userAgent,t=n.indexOf("OS ");return(n.indexOf("iPhone")>-1||n.indexOf("iPad")>-1)&&t>-1?window.Number(n.substr(t+3,3).replace("_",".")):0}function TouchLayer(n,t,i,r){var u=this;u.eltarget=n;u.capturetarget=n;u.callback=i;u.type=t;u.eventType=t;u.options={onInit:function(){},onBeforeStart:function(){},onStart:function(){},onBeforeMove:function(){},onMove:function(){},onBeforeEnd:function(){},onEnd:function(){},onCancel:function(){}};extendObj(r,u.options);u.options.onInit.call(u);u.ignoreClick=!0;s$(u.capturetarget).hasClass("radiom")&&(u.ignoreClick=!1);customEvents[t]&&customEvents[t].type==="gesture"?s$(u.capturetarget).bind("gesturestart",u):!1===allEvents?s$.browser.device==="desktop"?(s$(u.capturetarget).bind("mousedown",u),s$(u.capturetarget).bind("touchstart",u)):s$(u.capturetarget).bind(s$.browser.events.start,u):s$.browser.device==="desktop"?(s$(u.capturetarget).bind("mousedown",u),s$(u.capturetarget).bind("touchstart",u),s$(u.capturetarget).bind("mousemove",u),s$(u.capturetarget).bind("touchmove",u),s$(u.capturetarget).bind("mouseup",u),s$(u.capturetarget).bind("touchend",u),s$(u.capturetarget).bind("mouseout",u),s$(u.capturetarget).bind("touchcancel",u)):(s$(u.capturetarget).bind(s$.browser.events.start,u),s$(u.capturetarget).bind(s$.browser.events.move,u),s$(u.capturetarget).bind(s$.browser.events.end,u),s$(u.capturetarget).bind(s$.browser.events.cancel,u))}function VMAttr(n,t,i){if(!(this instanceof VMAttr))return new VMAttr(n,t,i);this.viewmodel=n;this.value=t;this.parseFn=i;this._id=VM._id++}function VMArray(n,t){if(!(this instanceof VM.array))return new VM.array(n,t);this.value=t||[];this.viewmodel=n;this._id=VM._id++}function VMWrap(n,t,i){if(!(this instanceof VMWrap))return new VMWrap(n,t,i);typeof i=="function"&&(i={get:i});i.get=i.get||function(n){return n};i.set=i.set||function(n){return n};this.attr=t;this.wrapper=i;this.viewmodel=n;this._id=VM._id++;var r=this;this.attr.on("change",function(n){n=r.wrapper.get(n);r.emit.call(r,"change",n)})}function getObjectClass(n){return typeof n!="object"||n===null?!1:/(\w+)\(/.exec(n.constructor.toString())[1]}function contextChange(n,t,i){if(!gchangescreenlock&&typeof n._vmEvent!="undefined"&&typeof n._vmEvent.change!="undefined"&&typeof t!="undefined"&&typeof n._vmEvent.change[t]!="undefined")for(var r in n._vmEvent.change[t])r!="count"&&n._vmEvent.change[t][r].apply(n,i)}function contextEvent(n,t){var i=t.target;if(!delegateE){typeof t.currentTarget!="undefined"&&(i=t.currentTarget);elementElementEvent(n,t,i);return}if((!gchangescreenlock||t.type===s$.browser.events.animationend||t.type===s$.browser.events.transitionend)&&typeof n._domEvent!="undefined"&&typeof n._domEvent[t.type]!="undefined")while(i!=null)elementElementEvent(n,t,i),i=i.parentNode}function elementElementEvent(n,t,i){var u,r;if(typeof i._eventId!="undefined"&&typeof n._domEvent[t.type]!="undefined"&&typeof n._domEvent[t.type][i._eventId]!="undefined")for(u in n._domEvent[t.type][i._eventId])u!="count"&&(r=n._domEvent[t.type][i._eventId][u].callback,typeof r.handleEvent!="undefined"?r.handleEvent.call(r,t):r.call(r,t))}function screenlocktouch(n){gchangescreenlock&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1)}function getOffsetSum(n){for(var t=0,i=0;n;)t=t+parseInt(n.offsetTop,10),i=i+parseInt(n.offsetLeft,10),n=n.offsetParent;return{top:t,left:i}}function runScripts(e){if(e.nodeType===1)if(e.tagName.toLowerCase()==="script")eval(e.text);else for(var n=e.firstChild;n;)n.nodeType===1&&runScripts(n),n=n.nextSibling}function rateDevice(){s$.browser.is.iDevice&&s$.id("viewport").addClass("appledevice");s$.browser.ie&&s$.id("viewport").addClass("IE");s$.browser.is.android&&s$.id("viewport").addClass("androiddevice");s$.browser.is.firefox&&s$.id("viewport").addClass("firefox");window.opera&&s$.id("viewport").addClass("opera");s$.browser.device==="mobile"?s$.id("viewport").addClass("mobile"):s$.browser.device==="tablet"?s$.id("viewport").addClass("tablet"):s$.id("viewport").addClass("desktop");s$.browser.has.animationEnd?(s$.id("world").addClass("animationST"),s$.browser.device==="desktop"&&rateDeviceHighMediumLow("ratingHigh"),(s$.browser.device==="mobile"||s$.browser.device==="tablet")&&rateDeviceHighMediumLow("ratingMedium"),rateDeviceScreenTransition("animationST")):s$.browser.has.csstransitions&&Modernizr.csstransitions?(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("transitionST")):(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("emileST"));window.opera&&(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("emileST"));(window.opera||navigator.userAgent.match(/OS 5_[0-9_]+ like Mac OS X/i)!=null)&&(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("noST"));s$.browser.is.firefox;(window.opera||navigator.userAgent.match(/OS 5_[0-9_]+ like Mac OS X/i)!=null)&&(rateDeviceHighMediumLow("ratingMedium"),rateDeviceScreenTransition("transitionST"));s$.browser.is.android&&(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("noST"));navigator.userAgent.match(/OS 6_[0-9_]+ like Mac OS X/i)!=null&&(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("transitionST"));s$.browser.ie&&s$.browser.device==="mobile"&&(rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("transitionST"));typeof PhoneGap!="undefined"&&(s$.id("viewport").addClass("nativeapp"),rateDeviceScreenTransition("transitionST"))}function rateDeviceHighMediumLow(n){s$.id("viewport").removeClass("ratingLow").removeClass("ratingMedium").removeClass("ratingHigh");s$.id("viewport").addClass(n)}function rateDeviceScreenTransition(n){s$.id("world").removeClass("transitionST").removeClass("animationST").removeClass("emileST").removeClass("noST");s$.browser.screenTransition=n;s$.id("world").addClass(n)}function getOrdinalFromDay(n){var t="th";return(n===1||n===31||n===21)&&(t="st"),(n===2||n===22)&&(t="nd"),(n===3||n===23)&&(t="rd"),t}function getOrdinal(n){var t="th";return(n==="01"||n==="31"||n==="21")&&(t="st"),(n==="02"||n==="22")&&(t="nd"),(n==="03"||n==="23")&&(t="rd"),t}function bubbleSort(n,t){var r,i,u;if(t){do for(r=!1,i=0;i<n.length-1;i++)n[i].data<n[i+1].data?(u=n[i],n[i]=n[i+1],n[i+1]=u,n[i].index=i+1,n[i+1].index=i,r=!0):n[i].index=i;while(r)}else do for(r=!1,i=0;i<n.length-1;i++)n[i].data>n[i+1].data?(u=n[i],n[i]=n[i+1],n[i+1]=u,n[i].index=i+1,n[i+1].index=i,r=!0):n[i].index=i;while(r)}function Date_toYMD(){var i,n,t;return i=String(this.getFullYear()),n=String(this.getMonth()+1),n.length==1&&(n="0"+n),t=String(this.getDate()),t.length==1&&(t="0"+t),i+"-"+n+"-"+t}function DStringToD(n){var t,i,r;return n.indexOf("-")===-1?(r=parseInt(n.substring(0,2),10),i=parseInt(n.substring(3,5),10)-1,t=parseInt(n.substring(6,10),10)):(t=n.substring(0,4),i=parseInt(n.substring(5,7),10)-1,r=parseInt(n.substring(8,10),10)),new Date(t,i,r)}function DTStringToDT(n){var t,i,r;n.indexOf("-")===-1?(t=n.substring(0,2),i=parseInt(n.substring(3,5),10)-1,r=n.substring(6,10)):(r=n.substring(0,4),i=parseInt(n.substring(5,7),10)-1,t=parseInt(n.substring(8,10),10));var e=n.substring(11,16),u=n.substring(11,13),f=n.substring(14,16);return new Date(r,i,t,u,f,00)}function DTStringToD(n){return DStringToD(n)}function DTStringFormatDay(n){return n.indexOf("-")===-1?n.substring(0,2):n.substring(8,10)}function DTStringFormatOrdinal(n){var t;return t=n.indexOf("-")===-1?n.substring(0,2):n.substring(8,10),getOrdinal(t)}function DTStringFormatMonth(n){var t;return t=n.indexOf("-")===-1?parseInt(n.substring(3,5),10):parseInt(n.substring(5,7),10),t<10&&(t="0"+t),t}function DTStringFormatMonthName(n){var t;return t=n.indexOf("-")===-1?parseInt(n.substring(3,5),10):parseInt(n.substring(5,7),10),monthNames[t]}function DTStringFormatYear(n){return n.indexOf("-")===-1?n.substring(6,10):n.substring(0,4)}function DTStringFormatTime(n){return n.substring(11,16)}function DTStringFormatTimeAMPM(n,t){return typeof t!="undefined"&&n.substring(11,13)>12?"pm":"am"}function DStringFormatForHTMLD(n){if(!s$.browser.html5Date)return DTStringFormatDay(n)+DTStringFormatOrdinal(n)+" "+DTStringFormatMonthName(n)+" "+DTStringFormatYear(n);return DTStringFormatYear(n)+"-"+DTStringFormatMonth(n)+"-"+DTStringFormatDay(n)}function DTStringFormatText(n){return DTStringFormatDay(n)+DTStringFormatOrdinal(n)+" "+DTStringFormatMonthName(n)+" "+DTStringFormatYear(n)+" "+DTStringFormatTime(n,!0)+" "+DTStringFormatTimeAMPM(n,!0)}function DStringFormatText(n){return DTStringFormatDay(n)+DTStringFormatOrdinal(n)+" "+DTStringFormatMonthName(n)+" "+DTStringFormatYear(n)}function DTStringFormatForHTMLDT(n){if(!s$.browser.html5Date)return DTStringFormatDay(n)+DTStringFormatOrdinal(n)+" "+DTStringFormatMonthName(n)+" "+DTStringFormatYear(n)+" "+DTStringFormatTime(n,!0)+" "+DTStringFormatTimeAMPM(n,!0);return DTStringFormatYear(n)+"-"+DTStringFormatMonth(n)+"-"+DTStringFormatDay(n)+"T"+DTStringFormatTime(n,!0)+":00.8670000+00:00"}function isValidDate(n,t){var u=!1,i,r,f;return/^\d{1,4}[\.|\/|-]\d{1,2}[\.|\/|-]\d{1,4}$/.test(n)?(n=n.replace(/0*(\d*)/gi,"$1"),i=n.split(/[\.|\/|-]/),i[1]=i[1]-1,i[2].length<4&&(i[2]=parseInt(i[2])<50?2e3+parseInt(i[2]):1900+parseInt(i[2])),r=new Date(i[2],i[1],i[0]),u=r.getDate()!=i[0]||r.getMonth()!=i[1]||r.getFullYear()!=i[2]?!1:!0,typeof t!="undefined"&&(f=new Date,f>=r&&(u=!1))):u=!1,u}function scopefn(n,t){return function(){t.apply(n,arguments)}}function loadMapScripts(){var t,n,i;!1===s$.map.gAPI&&(t=new Date-window.mapsStartTime,(typeof window.mapsStartTime=="undefined"||t>15e3)&&(window.mapsStartTime=new Date,n=document.createElement("script"),n.type="text/javascript",n.src="https://maps.googleapis.com/maps/api/js?v=3.exp&libraries=places&callback=s$.map.googleAPI",i=document.getElementsByTagName("head")[0],(i||document.body).appendChild(n)))}function Map(n){this.elements=n;this.maptype=s$(this.elements).data("maptype");this.maptype===null&&(this.maptype="native");this.maptype==="native"&&typeof window.plugins.mapKit=="undefined"&&(this.maptype="google");this.callbackGeoSuccess=s$(this.elements).data("geosuccess");this.callbackGeoWatch=s$(this.elements).data("geowatch");this.callbackGeoError=s$(this.elements).data("geoerror");this.callbackGeoReverse=s$(this.elements).data("georeverse");this.callbackMarkerClick=s$(this.elements).data("markerclick");this.dontstartshow=s$(this.elements).data("dontstartshow");this.initPositionMap=!1;this.callbackGeoSuccess!==null&&(this.callbackGeoSuccess=new Function("position",this.callbackGeoSuccess+"(position)"));this.callbackGeoWatch!==null&&(this.callbackGeoSuccess=new Function("position",this.callbackGeoWatch+"(position)"),this.callbackGeoWatch=new Function("position",this.callbackGeoWatch+"(position)"));this.callbackGeoError!==null&&(this.callbackGeoError=new Function("error",this.callbackGeoError+"(error)"));this.callbackGeoReverse!==null&&(this.callbackGeoReverse=new Function("results",this.callbackGeoReverse+"(results)"));this.diameter=s$(this.elements).data("diameter");this.diameter===null&&(this.diameter=1e4);this.setup()}function Switch(n,t,i){this.switchtype=s$(n).data("type");this.switchtype==null&&(this.switchtype="flip");this.events=[];this.touchEvents=[];this.checkbox=n;this.handler=t;this.useCapture=i;this.hasTouch="ontouchstart"in window;this.setCheck=function(n){this.checkbox.checked=n};this.getCheck=function(){return this.checkbox.checked};this.destroy=function(){for(var n=this.events.length-1;n>=0;n-=1)this.events[n].destroy();this.events=this.touchEvents=this.checkbox=this.handler=this.Switch=null};this.handleEvent=function(n){switch(n.type){case this.START_EV:this.onTouchStart(n);break;case this.MOVE_EV:this.onTouchMove(n);break;case this.END_EV:this.onClick(n);break;case"click":this.onClick(n)}};this.onTouchStart=function(n){n.stopPropagation?n.stopPropagation():n.cancelBubble=!0;this.touchEvents.push(addListener(this.checkbox,this.END_EV,this,this.useCapture));this.touchEvents.push(addListener(document.body,this.MOVE_EV,this,this.useCapture));var t=this.hasTouch?n.touches[0]:n;this.offsetStart=this.checkbox.checked?0:-62;this.touchStartX=t.pageX;this.moved=!1};this.onTouchMove=function(n){if(this.checkbox.disabled==!1){var t=this.hasTouch?n.touches[0]:n;this.newX=this.offsetStart-(this.touchStartX-t.pageX);this.newX<-62&&(this.newX=-62);this.newX>0&&(this.newX=0);this.checkbox.style.backgroundPositionX=this.newX+"px";this.touchStartX-t.pageX&&(this.moved=!0)}};this.onClick=function(n){return n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,this.reset(),this.moved?(this.newX>-31?(this.checkbox.style.backgroundPositionX="0px",this.checkbox.checked=!0):(this.checkbox.style.backgroundPositionX="-62px",this.checkbox.checked=!1),this.moved=!0):this.checkbox.disabled==!1&&(this.checkbox.checked?(this.checkbox.style.backgroundPositionX="-62px",this.checkbox.checked=!1):(this.checkbox.style.backgroundPositionX="0px",this.checkbox.checked=!0)),!1};this.reset=function(){for(var n=this.touchEvents.length-1;n>=0;n-=1)this.touchEvents[n].destroy();this.touchEvents=[]};this.clickbuster=function(){};this.clickbuster.preventGhostClick=function(n,t){this.clickbuster.coordinates.push(n,t);window.setTimeout(this.clickbuster.pop,2500)};this.clickbuster.pop=function(){this.clickbuster.coordinates.splice(0,2)};this.clickbuster.onClick=function(){};isTouch}function _dateToString(n){var t="en";return(typeof calendarlanguagepack!="undefined"&&(t=calendarlanguagepack),t=="de")?_fZ(n.getDate())+"."+_fZ(n.getMonth()+1)+"."+n.getFullYear():_fZ(n.getDate())+"/"+_fZ(n.getMonth()+1)+"/"+n.getFullYear()}function _fZ(n){return(n>9?"":"0")+n}function Scroll_To(n,t){var i=n.scrollTop;if(i+=(t-i)*.3,Math.abs(i-t)<2){n.scrollTop=t;return}n.scrollTop=i;setTimeout(Scroll_To,40,n,t)}function doGetCaretPosition(n){var t=0,i;return document.selection?(n.focus(),i=document.selection.createRange(),i.moveStart("character",-n.value.length),t=i.text.length):(n.selectionStart||n.selectionStart=="0")&&(t=n.selectionStart),t}function setCaretPosition(n,t){if(n.setSelectionRange)n.focus(),n.setSelectionRange(t,t);else if(n.createTextRange){var i=n.createTextRange();i.collapse(!0);i.moveEnd("character",t);i.moveStart("character",t);i.select()}}function datecalendarclick(n){var t=n.srcElement;return t.disabled?!1:(_currentdatecalendarcontrol!==null&&_currentdatecalendarcontrol[0].calendarM!=null?_currentdatecalendarcontrol[0].calendarM.options.destroyCalendar():(_currentdatecalendarcontrol=s$(t),setCalendar(_currentdatecalendarcontrol[0]),_currentdatecalendarcontrol[0].focus()),n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1,!0)}function get_firstchild(n){for(x=n.firstChild;x.nodeType!=1;)x=x.nextSibling;return x}function getChildren(n,t){for(var i=[];n;n=n.nextSibling)n.nodeType==1&&n!=t&&i.push(n);return i}function getSiblings(n){return getChildren(n.parentNode.firstChild,n)}function uiTaps(n){var t=n.srcElement,i=s$(t);null!==i.data("radioelement")?SetUIRadio(t):i.hasClass("datecalendar")?datecalendarclick(n):fastLinky(t)&&typeof PhoneGap!="undefined"&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1)}function expandToggle(n){s$(n.capturetarget).toggleClass("ui-collapsible-content-collapsed");s$(n.capturetarget).toggleClass()}function expandMenuDD(n){var t=s$(n.capturetarget).data("menudd");if(typeof t!="undefined")return s$(n.capturetarget).toggleClass("collapsed"),s$(t).toggleClass("collapsed"),s$.id("viewport").toggleClass(t+"collapsed"),!0}function SetUIRadio(n){var t=null;do{if("radio"===n.type){t=n;break}n=n.nextSibling}while(n);t&&(t.disabled||(t.checked=!0,n.parentElement.className="radio on",s$(t).fire("change"),s$('[name="'+t.name+'"]').each(function(){var n=this;t!==n&&s$(n.parentElement).hasClass("radio")&&(n.parentElement.className="radio off",n.checked=!1,s$(n).fire("change"))})))}function toggleCheck(n){var t=n.capturetarget,i=s$(t);t.checked=!t.checked}function fastLinky(n){var t=null,i;if(null===s$(n).data("fastlink")){do{if(null!==s$(n).data("fastlink")){t=n;break}n=n.parentElement}while(n)}else t=n;return t?(i=t.getAttribute("href"),i.indexOf(".pdf")!==-1?s$.navigator.changeHash("https://docs.google.com/viewer?url="+i):s$.navigator.changeHash(i),!0):!1}function zeroCeil(n){return n<=0?Math.floor(n):Math.ceil(n)}function zeroFloor(n){return n>=0?Math.floor(n):Math.ceil(n)}function touchMove(n){overthrowlock===!0?n.preventDefault?n.preventDefault():n.returnValue=!1:touchscrolling=!0}function touchEnd(){touchscrolling=!1}function Carousel(n){function l(){t.flag={click:!1,increment:!1,loop:!1,lock:null,touched:!1};t.options={autoscroll:!0,autoscrollDelay:5e3,autoscrollForward:!0,center:!0,cloneLength:1,fill:0,typeSpin:!1,transform3d:!0,touch:!0};t.itemIndex=0;t.dots=t.$container.data("component-dots");t.dots&&(t.dots=s$(t.dots)[0]);t.prev=t.$container.data("component-prev");t.prev&&(t.prev=s$(t.prev)[0],s$(t.prev).tbind("tap",function(){s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");setTimeout(function(){t.incrementTo(1)},16)}));t.next=t.$container.data("component-next");t.next&&(t.next=s$(t.next)[0],s$(t.next).tbind("tap",function(){s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");setTimeout(function(){t.incrementTo(-1)},16)}));t.momentumJS=t.$container.data("momentum");t.flick=t.$container.data("flick");!1&&t.momentumJS!=="js"&&t.typeSpin!==!0&&s$.browser.has.csstransitions?(t.momentumJS=!1,s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms"),s$(t.slider.element).style(s$.browser.css.transitionProperty,"all")):t.momentumJS=!0;t.autoTimer=t.$container.data("autotimer");t.itemIndex=t.$container.data("itemindex");t.itemIndex=t.itemIndex===null?0:parseInt(t.itemIndex);u();var n=t.itemIndex;t.$container.data("touch")===null&&(t.typeSpin?t.$container.tbind('swipe{"distance":"1","activateon":"all","direction":"EW"}',s):t.$scroller.tbind('swipe{"distance":"1","activateon":"all","direction":"EW"}',s));t.$container.data("resize")!==null&&(s$(window).binddirect("orientationChanged",t.resizeEvent),s$(window).binddirect(s$.browser.events.resize,t.resizeEvent))}function a(){var i,r,n;if(t.dots){for(i="",r=100/t.slider.panelCount,n=0;n<t.slider.panelCount;n++)i+="<span class='carousel-dot-"+n+" 'style='width:"+r+"%;' ><\/span>";s$(t.dots)[0].innerHTML=i;s$("*",t.dots).each(function(){s$(this).removeClass("activepage")});s$(".carousel-dot-"+t.itemIndex,t.dots).addClass("activepage")}}function v(){if(t.autoTimer!==null&&t.autoTimer.length){var n=t.itemIndex+1;n=n<=t.lastIndex?n:0;i(n)}}function y(){if(typeof t.slider!="undefined"){s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");var n=t.container.offsetWidth;this.forcerefresh=!0;u()}}function u(){var i=t.container.offsetWidth,n;(t.forcerefresh==!0||typeof t.oldWidth=="undefined"||t.oldWidth!==t.visibleWidth)&&(typeof t.slider=="undefined",t.slider.fullRefresh(),t.forcerefresh=!1,t.oldWidth=i,t.lastIndex=t.slider.panelCount-1,t.itemIndex=t.lastIndex<t.itemIndex?t.lastIndex:t.itemIndex,a(),t.jumpToIndexImmediately(t.itemIndex),n=t.slider.items[0].offsetWidth/4,t.typeSpin&&(n=0),t.infinite&&(n=t.slider.panelSize),t.slider.maxOffset=-1*t.lastIndex*i-n,t.slider.minOffset=0+n)}function e(){t.prev&&(t.itemIndex===0?s$(t.prev).addClass("disabled"):s$(t.prev).removeClass("disabled"));t.next&&(t.itemIndex===t.lastIndex||typeof t.lastIndex=="undefined"?s$(t.next).addClass("disabled"):s$(t.next).removeClass("disabled"))}function p(n){var u=t.slider.getX(),r=t.itemIndex;return s$.abs(t.startingOffset-u)>t.slider.panelSize/4&&(r=t.itemIndex-n),t.infinite?r>t.lastIndex?(r=0,t.slider.setX(t.slider.getX()+t.slider.panelSize*t.slider.panelCount)):r<0&&(r=t.lastIndex,t.slider.setX(t.slider.getX()-t.slider.panelSize*t.slider.panelCount)):r>t.lastIndex?r=t.lastIndex:r<0&&(r=0),i(r),r}function o(){s$("[data-item][data-state='active']",t.$scroller).attr("data-state","inactive");s$(s$("[data-item]",t.$scroller)[t.itemIndex]).attr("data-state","active");for(var n=0;n<t.slider.panelCount;n++)n===t.itemIndex?t.lastDirection>0?s$(t.slider.items[n]).addClass("selectedIndex").addClass("left").removeClass("right"):s$(t.slider.items[n]).addClass("selectedIndex").addClass("right").removeClass("left"):s$(t.slider.items[n]).removeClass("selectedIndex").removeClass("left").removeClass("right");t.dots&&(s$("*",t.dots).each(function(){s$(this).removeClass("activepage")}),s$(".carousel-dot-"+t.itemIndex,t.dots).addClass("activepage"));e()}function i(n,i){if(clearTimeout(t.timeoutauto),t.autoTimer!==null&&t.autoTimer.length&&(t.timeoutauto=setTimeout(v,t.autoTimer)),t.slider.updateIndex(n),typeof n!="undefined"){t.itemIndex=n;var r=t.itemIndex;requestAnimationFrame(function(){var n=t.itemIndex*-t.slider.panelSize;d(n,i)})}}function s(n){switch(n.eventType){case"start_swipe":w(n);break;case"move_swipe":return b(n);case"end_swipe":k(n);break;default:alert(n.eventType)}}function w(){overthrowlock=!1;s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");t.flag.touched=!0;t.flag.lock=null;t.flag.loop=!1;t.startingOffset=t.slider.getCurrentX()}function b(n){return t.vertical?(n.absDistY>5&&(overthrowlock=!0),t.slider.setX(t.startingOffset+n.distY)):(n.absDistX>5&&(overthrowlock=!0),t.slider.setX(t.startingOffset+n.distX)),overthrowlock}function k(n){if(overthrowlock=!1,t.velocityX=t.vertical?n.velocityY:n.velocityX,t.flag.touched=!1,t.flick==="big")t.multi?(t.speed=t.velocityX,t.bigflickinter=clearInterval(t.bigflickinter),t.bigflickinter=setInterval(function(){var i=t.slider.getX(),n;t.destinationOffset=i+t.speed;t.speed=t.speed*.85;s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");t.slider.setX(t.destinationOffset);s$.abs(t.speed)<1&&(t.bigflickinter=clearInterval(t.bigflickinter),t.speed=0,n=parseInt((t.slider.getX()-t.slider.panelSize/2)/-t.slider.panelSize),t.moveTo(n))},16)):r(n.absDirX);else if(t.vertical)r(n.absDirY);else if(t.multi){var i=parseInt((t.slider.getX()-t.slider.panelSize/2)/-t.slider.panelSize);t.moveTo(i)}else r(n.absDirX);return!0}function d(n,i){if(t.momentumJS)t.destinationOffset=n,h();else{var r=t.slider.panelSize*1;typeof i=="undefined"?s$(t.slider.element).style(s$.browser.css.transitionDuration,r+"ms"):s$(t.slider.element).style(s$.browser.css.transitionDuration,"0ms");setTimeout(function(){o()},r);t.slider.setX(n)}}function h(){var i;if(typeof t.slider!="undefined"){if(t.flag.increment=!1,t.stack!==!0){var r=t.slider.getX(),u=t.destinationOffset-r,n=u-zeroFloor(u/(t.typeSpin?1.2:1.3));if(s$.abs(n)<.01&&(n=0),i=n+r,t.slider.setX(i),n==0||isNaN(i)||(t.flag.increment=!0),t.flag.increment){t.request=!0;t.timeoutMomentum=setTimeout(function(){h();t.request=!1},16);return}startingOffset=null}o()}}function r(n){t.lastDirection=n;var i=p(n)}var t=this;t.timeoutMomentum=null;t.$container=s$(n);t.container=t.$container[0];t.$scroller=s$("[data-carousel-scroll]",t.$container);t.scroller=t.$scroller[0];t.$container.data("stack")?(t.slider=new Stack(t.scroller,t.container),t.typeSpin=!1,t.stack=!0,t.infinite=!0,t.multi=!1):t.$container.data("wheel")&&s$.browser.has.transform3d&&!s$.browser.isGingerbread?(t.slider=new Spin(t.scroller,t.container),t.typeSpin=!0,t.infinite=!0,t.multi=!1):(t.infinite=t.$container.data("infinite")?!0:!1,t.vertical=null!=t.$container.data("vertical")?!0:!1,t.multi=t.$container.data("multi")?!0:!1,t.slider=new Slide(t.scroller,t.container,t.infinite,t.vertical,t.multi),t.typeSpin=!1);var c={x:0,y:0},f={x:0,y:0};t.startingOffset=null;this.incrementTo=function(n){t.startingOffset=t.slider.getX()-t.slider.panelSize;r(n)};this.moveTo=function(n){t.startingOffset=t.slider.getX()-t.slider.panelSize;i(n)};this.fullRefresh=function(){t.forcerefresh=!0;u();e()};this.resizeEvent=function(){window.clearTimeout(t.resizeTimeoutId);t.resizeTimeoutId=window.setTimeout(y,10)};this.jumpToIndex=function(n){t.moveTo(t.itemIndex-n)};this.animateToIndex=function(n){var r=n,u=r*-t.slider.panelSize;t.slider.setX(u);i(r)};this.jumpToIndexImmediately=function(n){var r=n,u=r*-t.slider.panelSize;t.slider.setX(u);i(r,!0)};l()}function Slide(n,t,i,r,u){this.element=n;this.elementcontainer=t;this.infinite=i;this.firstTime=!0;this.vertical=r;this.multi=u;this.use3d=s$.browser.has.transform3d;this.useTranslate=!1;this.sliderx=0}function Stack(n,t,i,r,u){this.element=n;this.elementcontainer=t;this.infinite=i;this.firstTime=!0;this.vertical=r;this.multi=u;this.use3d=s$.browser.has.transform3d;this.useTranslate=!1;this.updateIndexNow=0;this.firstupdate=!1}function Spin(n,t){this.element=n;this.elementcontainer=t}function getRotationDegrees(n){var t=window.getComputedStyle(n),i=t["-webkit-transform"]||t["-moz-transform"]||t.transform;if(!i||i=="none")return 0;var u=i.split(","),f=parseFloat(u[0].substr(7)),e=parseFloat(u[1]),o=Math.atan2(e,f),r=180*o/Math.PI;return r<0&&(r+=360),r}function iResizer(n){function u(){t.style.overflow="hidden";t.scrolling="no";t.contentWindow.postMessage("[iFrameSizer]ifrmOffers:0:false:false:0:false","*")}var i,r,t;n.src=s$(n).data("src");i="[iFrameSizer]";r=i.length;this.listener=function(n){function t(n){function u(){function n(n){window.requestAnimationFrame(function(){t.iframe.style[n]=t[n]+"px"})}n("height")}function f(){var i=n.substr(r).split(":");console.log("processMsg");t={iframe:document.getElementById(i[0]),height:i[1],width:i[2]}}var t={};i===n.substr(0,r)&&(f(),u())}t(n.data)};window.addEventListener?addEventListener("message",this.listener,!1):attachEvent("onmessage",this.listener);t=n;t.attachEvent?t.attachEvent("onload",u):t.onload=u}function ajaxdiv(n){var t=n,i=s$(t).data("ajaxpanel-src");i&&s$("#syncdatamodel").xhr(i,{method:"get",async:!0,error:function(){var n=s$.id("spinner-page");n.length&&n.hide();s$.network.endConnection()},callback:function(){var n=s$.id("spinner-page");n.length&&n.hide();this.responseText!=""&&s$(t).html(this.responseText);s$.network.endConnection()}})}function ajaxform(n){var i=n,t=this;t.formid=n.id;t.nodeid="#"+t.formid;s$.id(t.formid).fire("forminit");document[this.formid].onsubmit=function(n){var r,u,f,e;return s$(i).data("validationoff")==null&&s$("#"+this.formid).validate(),r=s$(i).data("formvalidate"),r!==null&&(r+="(element);",u=new Function("element",r),u()),s$("#"+t.formid+" .inputinvalid").length>0||(typeof n!="undefined"&&(n.preventDefault?n.preventDefault():n.returnValue=!1),f=document.getElementById(t.formid),e=FormSerializer.serialize(f),s$("#splash").xhr(s$("#"+t.formid)[0].action+"?partial=true",{method:"post",data:e,error:function(){},callback:function(){var updateid,cmdDestroy,successfn,returnval,cmdInit,fastclickfunction;updateid=s$("#"+t.formid).data("ajaxupdate");cmdDestroy=s$(i).data("formdestroy");cmdDestroy!==null&&(cmdDestroy+="(element);",fastclickfunction=new Function("element",cmdDestroy),fastclickfunction());s$.id(updateid).html("inner",this.responseText,!0);successfn=s$("#"+t.formid).data("ajaxsuccess");typeof successfn!="undefined"&&(returnval=eval(successfn));cmdInit=s$(i).data("forminit");cmdInit!==null&&(cmdInit+="(element);",fastclickfunction=new Function("element",cmdInit),fastclickfunction())}})),!1}}var _gaq=_gaq||[],plugins=plugins||{},Touch,allEvents,VM,delegateE,s$,actionPage,monthNames,apiLoadCount,isTouch,_currentdatecalendarcontrol,_yearrange,gchangescreenlock;plugins.googleAnalyticsPlugin=function(){var n=function(n){_gaq.push(["_setAccount",n]);_gaq.push(["_trackPageview"])},t=function(n){_gaq.push(["_trackPageview",n])},i=function(n,t,i,r){_gaq.push(["_trackEvent",n,t,i,r])};return{startTrackerWithAccountID:n,trackPageview:t,trackEvent:i}}(),function(){var n=document.createElement("script"),t;n.type="text/javascript";n.async=!0;n.src=("https:"==document.location.protocol?"https://ssl":"http://www")+".google-analytics.com/ga.js";t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(n,t)}();window.Modernizr=function(n,t,i){function nt(n){p.cssText=n}function s(n,t){return typeof n===t}function st(n,t){return!!~(""+n).indexOf(t)}function ht(n,t){var u,r;for(u in n)if(r=n[u],!st(r,"-")&&p[r]!==i)return t=="pfx"?r:!0;return!1}function ct(n,t,r){var f,u;for(f in n)if(u=t[n[f]],u!==i)return r===!1?n[f]:s(u,"function")?u.bind(r||t):u;return!1}function h(n,t,i){var r=n.charAt(0).toUpperCase()+n.slice(1),u=(n+" "+ut.join(r+" ")+r).split(" ");return s(t,"string")||s(t,"undefined")?ht(u,t):(u=(n+" "+ft.join(r+" ")+r).split(" "),ct(u,t,i))}function lt(){r.input=function(i){for(var r=0,f=i.length;r<f;r++)l[i[r]]=!!(i[r]in u);return l.list&&(l.list=!!(t.createElement("datalist")&&n.HTMLDataListElement)),l}("autocomplete autofocus list placeholder max min multiple pattern required step".split(" "));r.inputtypes=function(n){for(var f=0,r,e,s,h=n.length;f<h;f++)u.setAttribute("type",e=n[f]),r=u.type!=="text",r&&(u.value=it,u.style.cssText="position:absolute;visibility:hidden;",/^range$/.test(e)&&u.style.WebkitAppearance!==i?(o.appendChild(u),s=t.defaultView,r=s.getComputedStyle&&s.getComputedStyle(u,null).WebkitAppearance!=="textfield"&&u.offsetHeight!==0,o.removeChild(u)):/^(search|tel)$/.test(e)||(r=/^(url|email)$/.test(e)?u.checkValidity&&u.checkValidity()===!1:u.value!=it)),et[n[f]]=!!r;return et}("search tel url email datetime date month week time datetime-local number range color".split(" "))}var r={},y=!0,o=t.documentElement,e="modernizr",tt=t.createElement(e),p=tt.style,u=t.createElement("input"),it=":)",at={}.toString,c=" -webkit- -moz- -o- -ms- ".split(" "),rt="Webkit Moz O ms",ut=rt.split(" "),ft=rt.toLowerCase().split(" "),f={},et={},l={},w=[],b=w.slice,a,k=function(n,i,r,u){var l,a,c,v,f=t.createElement("div"),h=t.body,s=h||t.createElement("body");if(parseInt(r,10))while(r--)c=t.createElement("div"),c.id=u?u[r]:e+(r+1),f.appendChild(c);return l=["&#173;",'<style id="s',e,'">',n,"<\/style>"].join(""),f.id=e,(h?f:s).innerHTML+=l,s.appendChild(f),h||(s.style.background="",s.style.overflow="hidden",v=o.style.overflow,o.style.overflow="hidden",o.appendChild(s)),a=i(f,n),h?f.parentNode.removeChild(f):(s.parentNode.removeChild(s),o.style.overflow=v),!!a},ot=function(){function r(r,u){u=u||t.createElement(n[r]||"div");r="on"+r;var f=r in u;return f||(u.setAttribute||(u=t.createElement("div")),u.setAttribute&&u.removeAttribute&&(u.setAttribute(r,""),f=s(u[r],"function"),s(u[r],"undefined")||(u[r]=i),u.removeAttribute(r))),u=null,f}var n={select:"input",change:"input",submit:"form",reset:"form",error:"img",load:"img",abort:"img"};return r}(),d={}.hasOwnProperty,g,v;g=s(d,"undefined")||s(d.call,"undefined")?function(n,t){return t in n&&s(n.constructor.prototype[t],"undefined")}:function(n,t){return d.call(n,t)};Function.prototype.bind||(Function.prototype.bind=function(n){var t=this,i,r;if(typeof t!="function")throw new TypeError;return i=b.call(arguments,1),r=function(){var f,e,u;return this instanceof r?(f=function(){},f.prototype=t.prototype,e=new f,u=t.apply(e,i.concat(b.call(arguments))),Object(u)===u)?u:e:t.apply(n,i.concat(b.call(arguments)))},r});f.flexbox=function(){return h("flexWrap")};f.touch=function(){var i;return"ontouchstart"in n||n.DocumentTouch&&t instanceof DocumentTouch?i=!0:k(["@media (",c.join("touch-enabled),("),e,")","{#modernizr{top:9px;position:absolute}}"].join(""),function(n){i=n.offsetTop===9}),i};f.hashchange=function(){return ot("hashchange",n)&&(t.documentMode===i||t.documentMode>7)};f.cssanimations=function(){return h("animationName")};f.cssgradients=function(){var n="background-image:";return nt((n+"-webkit- ".split(" ").join("gradient(linear,left top,right bottom,from(#9f9),to(white));"+n)+c.join("linear-gradient(left top,#9f9, white);"+n)).slice(0,-n.length)),st(p.backgroundImage,"gradient")};f.csstransforms=function(){return!!h("transform")};f.csstransforms3d=function(){var n=!!h("perspective");return n&&"webkitPerspective"in o.style&&k("@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}",function(t){n=t.offsetLeft===9&&t.offsetHeight===3}),n};f.csstransitions=function(){return h("transition")};f.localstorage=function(){try{return localStorage.setItem(e,e),localStorage.removeItem(e),!0}catch(n){return!1}};f.sessionstorage=function(){try{return sessionStorage.setItem(e,e),sessionStorage.removeItem(e),!0}catch(n){return!1}};for(v in f)g(f,v)&&(a=v.toLowerCase(),r[a]=f[v](),w.push((r[a]?"":"no-")+a));return r.input||lt(),r.addTest=function(n,t){if(typeof n=="object")for(var u in n)g(n,u)&&r.addTest(u,n[u]);else{if(n=n.toLowerCase(),r[n]!==i)return r;t=typeof t=="function"?t():t;typeof y!="undefined"&&y&&(o.className+=" "+(t?"":"no-")+n);r[n]=t}return r},nt(""),tt=u=null,r._version="2.6.2",r._prefixes=c,r._domPrefixes=ft,r._cssomPrefixes=ut,r.hasEvent=ot,r.testProp=function(n){return ht([n])},r.testAllProps=h,r.testStyles=k,r.prefixed=function(n,t,i){return t?h(n,t,i):h(n,"pfx")},o.className=o.className.replace(/(^|\s)no-js(\s|$)/,"$1$2")+(y?" js "+w.join(" "):""),r}(this,this.document);s$=function(){var r=[],i=[],n=function(n,i){return new t(e(n,i))},e=function(i,r){return i==null?(n.console.log("qsa - empty"),null):typeof i=="object"&&(i.nodeType||"setInterval"in i)?[i]:i instanceof t?i:(r instanceof t&&(r=r[0]),(r||document).querySelectorAll(i))},t=function(n){for(var t=0,i=n.length;t<i;t++)this[t]=n[t];return this.length=n.length,this},u=function(){for(var t=0,r=i.length;t<r;t++)i[t]();i=null;n.unbind(document,n.browser.events.begin,u)},f=function(){for(var t=0,i=r.length;t<i;t++)r[t]();r=null;n.unbind(window,"load",f)};return n.id=function(n,i){return n=(i||document).getElementById(n),n=n?[n]:[],new t(n)},n.extend=function(n,i){i=i||t.prototype;for(var r in n)i[r]=n[r]},n.bind=function(t,i,r,u){var f=VM.dom.getViewModelFromElement(t);if(f){VM.viewmodel.bind(t,i,r,f,u);return}n.binddirect(t,i,r,u)},n.binddirect=function(n,t,i,r){document.addEventListener?n.addEventListener(t,i,!!r):document.attachEvent&&n.attachEvent("on"+t,i)},n.unbind=function(t,i,r,u){var f=VM.dom.getViewModelFromElement(t);if(f){VM.viewmodel.unbind(t,i,r,f);return}n.unbinddirect(t,i,r,u)},n.unbinddirect=function(n,t,i,r){document.removeEventListener?n.removeEventListener(t,i,!!r):n.detachEvent("on"+t,i)},n.begin=function(t){var f,e,t;if(i==null){t();return}if(!i.length){f=!1;function r(){f||(f=!0,u())}if(document.addEventListener)document.addEventListener(n.browser.events.begin,r,!1);else if(document.attachEvent){try{e=window.frameElement!=null}catch(s){}if(document.documentElement.doScroll&&!e){function o(){if(!f)try{document.documentElement.doScroll("left");r()}catch(n){setTimeout(o,10)}}o()}document.attachEvent("onreadystatechange",function(){document.readyState==="complete"&&r()})}else window.addEventListener?window.addEventListener("load",r,!1):window.attachEvent?window.attachEvent("onload",r):(t=window.onload,window.onload=function(){t&&t();r()})}i.push(t)},n.loaded=function(t){r.length||n.bind(window,"load",f,!1);r.push(t)},n.hasClass=function(n,t){return new RegExp("(^|\\s)"+t+"(\\s|$)").test(n.className)},n.create=function(t){return n(document.createElement(t))},t.prototype={each:function(n){for(var r=this.length,t=0,i=r;t<i;t++)n.call(this[t]);return this},first:function(){return this[0]},last:function(){return this[this.length-1]},get:function(t){var i=this.length;return t<0?t=0:t>i-1&&(t=i-1),n(this[t])},bind:function(t,i,r){return this.each(function(){n.bind(this,t,i,r)})},unbind:function(t,i,r){return this.each(function(){n.unbind(this,t,i,r)})},binddirect:function(t,i,r){return this.each(function(){n.binddirect(this,t,i,r)})},unbinddirect:function(t,i,r){return this.each(function(){n.unbinddirect(this,t,i,r)})},data:function(t,i){if(typeof t=="string"&&i===undefined)return this.length<=0?(n.console.log("data - empty"),null):this[0].getAttribute("data-"+t);this.attr("data-"+t,i)},find:function(t){return n(t,this)},attr:function(n,t){if(typeof n=="string"&&t===undefined)return this[0].getAttribute(n);if(typeof n!="object"){var i={};i[n]=t;n=i}return this.each(function(){for(var t in n)n[t].length?this.setAttribute(t,n[t]):this.removeAttribute(t)})},style:function(n,t){if(typeof n=="string"&&t===undefined)return window.getComputedStyle(this[0],null).getPropertyValue(n);if(typeof n!="object"){var i={};i[n]=t;n=i}return this.each(function(){for(var t in n)this.style[t]=n[t]})},width:function(n){return n?this.each(function(){this.style.width=n+"px"}):this[0].clientWidth},height:function(n){return n?this.each(function(){this.style.height=n+"px"}):this[0].clientHeight},hasClass:function(t){return n.hasClass(this[0],t)},addClass:function(t){var i,r;for(typeof t=="string"&&(t=[t]),i=0,r=t.length;i<r;i++)this.each(function(){t[i]&&!n.hasClass(this,t[i])&&(this.className=this.className?this.className+" "+t[i]:t[i])});return this},removeClass:function(n){var t,i;for(typeof n=="string"&&(n=[n]),t=0,i=n.length;t<i;t++)this.each(function(){this.className=this.className.replace(new RegExp("(^|\\s+)"+n[t]+"(\\s+|$)")," ")});return this},toggleClass:function(t){var i,r;for(typeof t=="string"&&(t=[t]),i=0,r=t.length;i<r;i++)this.each(function(){n.hasClass(this,t[i])?n(this).removeClass(t[i]):n(this).addClass(t[i])});return this},append:function(n){return this.each(function(){var t=this;n.each(function(){t.appendChild(this)})})},remove:function(){return this.each(function(){this.parentNode&&this.parentNode.removeChild(this)}),null},filter:function(n){var i=[];return this.each(function(){n.call(this)&&i.push(this)}),new t(i)},parent:function(t){var r,i;for(t=n(t);r=this[0].parentNode;)if(i=t.each(function(){r===this&&(i=this)}),i)return i;return undefined},empty:function(){var n=this.first();if(typeof n!="undefined")while(n.hasChildNodes())n.removeChild(n.firstChild)},val:function(n){if(arguments.length===0)return this.first().value;this.first().value=n},show:function(n){return typeof n!="undefined"?this.style("display",n):this.style("display","block")},hide:function(){return this.style("display","none")},clean:function(){var n=/\S/;this.each(function(){for(var i=this,t=i.firstChild,u=-1,r;t;)r=t.nextSibling,t.nodeType!=3||n.test(t.nodeValue)?t.nodeIndex=++u:i.removeChild(t),t=r})},html:function(n,t){var i,r,u;return(this.clean(),arguments.length===0)?(i=[],this.each(function(n){i.push(n.innerHTML)}),i):(arguments.length===1&&arguments[0]!="remove"&&(t=n,n="inner"),n!="remove"&&t&&t.each!==undefined)?(n==="inner"?(r=document.createElement("p"),t.each(function(n){r.appendChild(n)}),this.each(function(n){n.innerHTML=r.innerHTML})):(u=this,t.each(function(t){u.html(n,t)})),this):this.each(function(){var list,len,iindex=0,parent;if(n==="inner")if(typeof t=="string"||typeof t=="number")for(this.innerHTML=t,list=this.getElementsByTagName("SCRIPT"),len=list.length;iindex<len;iindex++)eval(list[iindex].text);else this.innerHTML="",this.appendChild(t);else if(n==="remove")this.parentNode.removeChild(el);else{var elArray=["outer","top","bottom"],wrappedE=wrapHelper(t,elArray.indexOf(n)>-1?el:this.parentNode),children=wrappedE.childNodes;for(n==="outer"?this.parentNode.replaceChild(wrappedE,el):n==="top"?this.insertBefore(wrappedE,this.firstChild):n==="bottom"?this.insertBefore(wrappedE,null):n==="before"?this.parentNode.insertBefore(wrappedE,el):n==="after"&&this.parentNode.insertBefore(wrappedE,this.nextSibling),parent=wrappedE.parentNode;children.length;)parent.insertBefore(children[0],wrappedE);parent.removeChild(wrappedE)}})},fire:function(n,t){return document.dispatchEvent?this.each(function(){var r=this,i;r!==document||r.dispatchEvent||(r=document.documenttihement);i=document.createEvent("HTMLEvents");i.initEvent(n,!0,!0);i.data=t||{};i.eventName=n;i.currentTarget=r;i.srcElement=r;i.target=r;this.dispatchEvent(i)}):this.each(function(){var i=this,r,u;i!==document||this.fireEvent||(i=document.documentElement);r=document.createEventObject();r.data=t||{};r.eventName=n;ieEvents.indexOf(n)>-1?i.fireEvent("on"+n,r):(u=_getRespondersForEvent(_getEventID(i),n),u.forEach(function(n){n.call(this)}))})},text:function(n){return n===undefined?this[0].innerText:this.each(function(){while(this.firstChild!==null)this.removeChild(this.firstChild);this.appendChild(document.createTextNode(n))})}},n}(),function(){for(var i=0,t=["ms","moz","webkit","o"],n=0;n<t.length&&!window.requestAnimationFrame;++n)window.requestAnimationFrame=window[t[n]+"RequestAnimationFrame"],window.cancelAnimationFrame=window[t[n]+"CancelAnimationFrame"]||window[t[n]+"CancelRequestAnimationFrame"];window.requestAnimationFrame||(window.requestAnimationFrame=function(n){var t=(new Date).getTime(),r=Math.max(0,16-(t-i)),u=window.setTimeout(function(){n(t+r)},r);return i=t+r,u});window.cancelAnimationFrame||(window.cancelAnimationFrame=function(n){clearTimeout(n)})}();s$.browser={};s$.browser.dummyStyle=null;s$.browser.is={standalone:window.navigator.standalone,android:/android \d+\.\d+/i.test(navigator.appVersion),gingerbread:/android 2\.3/i.test(navigator.userAgent),honeycombornewer:/android [3-9]/i.test(navigator.userAgent),jellybean:/android 4\.1/i.test(navigator.userAgent),iDevice:/iphone|ipad/i.test(navigator.appVersion),iPad:/ipad/i.test(navigator.appVersion),retina:window.devicePixelRatio>=2,firefox:navigator.userAgent.toLowerCase().indexOf("firefox")>-1,windowsphone:navigator.userAgent.match(new RegExp("IEMobile","i"))};s$.browser.ie=function(){var n=-1,t,i;return navigator.appName=="Microsoft Internet Explorer"&&(t=navigator.userAgent,i=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})"),i.exec(t)!=null&&(n=parseFloat(RegExp.$1))),n>-1?!0:!1}();s$.browser.has={touch:typeof window.ontouchstart!="undefined"?!0:!1};s$.browser.has.rotateY=!s$.browser.is.android;s$.browser.has.csstransitions=s$("html").hasClass("csstransitions");s$.browser.has.transform3d=s$("html").hasClass("csstransforms3d");s$.browser.has.transform=!!s$.browser.vendor;s$.browser.vendor=function(){s$.browser.dummyStyle===null&&(s$.browser.dummyStyle=document.createElement("div").style);for(var t="webkitT,MozT,t,msT,OT".split(","),i,n=0,r=t.length;n<r;n++)if(i=t[n]+"ransform",i in s$.browser.dummyStyle)return t[n].substr(0,t[n].length-1);return!1}();s$.browser.overthrow=!1;s$.browser.events={start:s$.browser.has.touch?"touchstart":"mousedown",move:s$.browser.has.touch?"touchmove":"mousemove",end:s$.browser.has.touch?"touchend":"mouseup",resize:"onorientationchange"in window?"orientationchange":"resize",cancel:s$.browser.has.touch?"touchcancel":"touchcancel",wheel:s$.browser.vendor==="Moz"?"DOMMouseScroll":"mousewheel"};s$.browser.events.begin=function(){return getInternetExplorerVersion()>0&&getInternetExplorerVersion()<9?"load":typeof PhoneGap!="undefined"?"deviceready":"DOMContentLoaded"}();s$.browser.events.transitionend=function(){if(s$.browser.vendor===!1)return!1;return{"":"transitionend",webkit:"webkitTransitionEnd",Moz:"transitionend",O:"otransitionend",ms:"MSTransitionEnd"}[s$.browser.vendor]}();s$.browser.events.animationend=function(){if(s$.browser.vendor===!1)return!1;return s$.browser.is.jellybean?"webkitAnimationEnd":{"":"animationend",webkit:"webkitAnimationEnd",Moz:"animationend",O:"oanimationend",ms:"MSAnimationEnd"}[s$.browser.vendor]}();s$.browser.has.animationEnd="WebKitAnimationEvent"in window||"AnimationEvent"in window;s$.browser.css={};s$.browser.css.vendor=s$.browser.vendor?"-"+s$.browser.vendor.toLowerCase()+"-":"";s$.browser.css.transform=prefixStyle("transform");s$.browser.css.transitionProperty=prefixStyle("transitionProperty");s$.browser.css.transitionDuration=prefixStyle("transitionDuration");s$.browser.css.transformOrigin=prefixStyle("transformOrigin");s$.browser.css.transitionTimingFunction=prefixStyle("transitionTimingFunction");s$.browser.css.transitionDelay=prefixStyle("transitionDelay");s$.browser.css.trnOpen="translate"+(s$.browser.has.transform3d?"3d(":"(");s$.browser.css.trnClose=s$.browser.has.transform3d?",0)":")";s$.browser.html5Date=function(n){return typeof n!="undefined"&&(gbhtmldate=n),typeof gbhtmldate=="undefined"&&(gbhtmldate=!1,/(iPhone|iPod|iPad)/i.test(navigator.userAgent)&&(gbhtmldate=checkVersion()<5?!1:!0)),gbhtmldate}();s$.abs=function(n){return n<0?-n:n};Touch=Touch||{};customEvents={tap:{type:"tap",options:{capturefromchild:!1}},doubletap:{type:"tap",options:{neededTaps:2}},taphold:{type:"tap",options:{retain:800}},swipe:{type:"swipe",options:{distance:1,activateon:"all"}},swipeleft:{type:"swipe",options:{distance:1,direction:"w"}},swipeup:{type:"swipe",options:{distance:1,direction:"n"}},swiperight:{type:"swipe",options:{distance:1,direction:"e"}},swipedown:{type:"swipe",options:{distance:1,direction:"s"}},pan:{type:"swipe",options:{fingers:2}},panup:{type:"swipe",options:{fingers:2,direction:["N"]}},pandown:{type:"swipe",options:{fingers:2,direction:["S"]}},gestures:{type:"gesture",options:{scale:!0,rotate:!0}},pinch:{type:"gesture",options:{scale:!0,maxScale:1,scaleThreshold:.2}},zoom:{type:"gesture",options:{scale:!0,minScale:1,scaleThreshold:.2}},scale:{type:"gesture",options:{scale:!0,scaleThreshold:.2}},rotate:{type:"gesture",options:{rotate:!0,rotateThreshold:10}}};eventFn={};eventList=[];extendObj=function(n,t){for(var i in n)t[i]=n[i]};s$.extend({tbind:function(n,t,i){var f=this,r,u;if(n=n.toLowerCase(),r={},u=n.indexOf("{"),u!==-1){var e=n.indexOf("}"),o=n.substring(u,e+1),s=JSON.parse(o);n=n.substring(0,u);extendObj(customEvents[n].options,r);extendObj(s,r)}else{if(!customEvents[n])return this.bind(n,t,i);extendObj(customEvents[n].options,r)}return f.each(function(){eventFn[customEvents[n].type](this,n,t,r)})},tunbind:function(n,t){var h=this,e,s,u,r,i,o,f;if(n){if(n=n.toLowerCase(),e=n.indexOf("{"),e!==-1&&(s=n.indexOf("}"),n=n.substring(0,e)),!customEvents[n])return this.unbind(n,t);for(u=[],i=eventList.length-1;i>=0;i--)this[0]===eventList[i].capturetarget&&(r=eventList[i],r.type===r.type&&(t&&r.fn!==t&&r.callback!==t||(u.push(r),eventList.splice(i,1))));for(i=0,o=u.length;i<o;i++)f=u[i],f.options&&f.options.onEnd,f.destroy()}},getEvents:function(){for(var r=this,i=eventList.length,t=[],n=0;n<i;n++)this[0]===eventList[n].capturetarget&&t.push(eventList[n]);return t}});allEvents=!1;TouchLayer.prototype={moveThreshold:2,neededTouches:1,handleEvent:function(n){var t=this;switch(n.type){case"click":t.ignoreClick&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1);break;case"mousedown":case"touchstart":t._start(n);break;case"mousemove":case"touchmove":t._move(n);break;case"mouseup":case"touchend":t._end(n);break;case"touchcancel":t._cancel(n);break;case"gesturestart":t._gestStart(n);break;case"gesturechange":t._gestChange(n);break;case"gestureend":case"gesturecancel":t._gestEnd(n)}},_start:function(n){var t=this,i=typeof n.touches!="undefined"?n.touches[0]:n;(t.fingers=typeof n.touches!="undefined"?n.touches.length:n.ctrlKey?2:1,t.options.onBeforeStart.call(t,n),t.fingers==t.neededTouches)&&(t.started=!0,!1===allEvents&&(s$.browser.device==="desktop"?(s$(this.capturetarget).bind("mousemove",t),s$(this.capturetarget).bind("touchmove",t),s$(this.capturetarget).bind("mouseup",t),s$(this.capturetarget).bind("touchend",t),s$(this.capturetarget).bind("mouseout",t),s$(this.capturetarget).bind("touchcancel",t)):(s$(this.capturetarget).bind(s$.browser.events.move,t),s$(this.capturetarget).bind(s$.browser.events.end,t),s$(this.capturetarget).bind(s$.browser.events.cancel,t))),t.x=i.pageX,t.y=i.pageY,t.startX=i.pageX,t.startY=i.pageY,t.deltaX=0,t.deltaY=0,t.distX=0,t.distY=0,t.absDistX=0,t.absDistY=0,t.odometerX=0,t.odometerY=0,t.dirX=0,t.dirY=0,t.absDirX=0,t.absDirY=0,t.startDir="unknown",t.startTime=n.timeStamp,t.currentTime=n.timeStamp,t.duration=0,t.moved=!1,t.expired=!1,t.options.onStart.call(t,n))},_move:function(n){var t=this,i=typeof n.changedTouches!="undefined"?n.changedTouches[0]:n,r,u;if(t.started===!0){if(t.fingers=typeof n.touches!="undefined"?n.touches.length:n.ctrlKey?2:1,t.fingers!=t.neededTouches)return;t.deltaX=t.x-i.pageX;t.deltaY=t.y-i.pageY;t.x=i.pageX;t.y=i.pageY;t.distX=t.x-t.startX;t.distY=t.y-t.startY;t.absDistX=s$.abs(t.distX);t.absDistY=s$.abs(t.distY);r=t.dirX;u=t.dirY;t.dirX=t.deltaX>0?1:-1;t.dirY=t.deltaY>0?1:-1;t.absDirX=t.distX>0?1:-1;t.absDirY=t.distY>0?1:-1;(t.absDistX>t.moveThreshold||t.absDistY>t.moveThreshold)&&t.startDir==="unknown"&&(t.moved=!0,t.absDistX>t.absDistY+t.moveThreshold/2?t.startDir=t.distX>0?"e":"w":t.absDistY>t.absDistX+t.moveThreshold/2?t.startDir=t.distY>0?"s":"n":(t.startDir=t.distY>0?"s":"n",t.startDir+=t.distX>0?"e":"w"));t.currentTime=n.timeStamp;t.options.onMove.call(t,n)}},_cancel:function(n){var t=this;!1===allEvents&&(s$.browser.device==="desktop"?(s$(this.capturetarget).unbind("mousemove",t),s$(this.capturetarget).unbind("touchmove",t),s$(this.capturetarget).unbind("mouseup",t),s$(this.capturetarget).unbind("touchend",t),s$(this.capturetarget).unbind("mouseout",t),s$(this.capturetarget).unbind("touchcancel",t)):(s$(this.capturetarget).unbind(s$.browser.events.move,t),s$(this.capturetarget).unbind(s$.browser.events.end,t),s$(this.capturetarget).unbind(s$.browser.events.cancel,t)));typeof this.options=="undefined";this.options.onCancel.call(this,n);this.startDir=""},_end:function(n){var t=this,i,r,u;(!1===allEvents&&(s$.browser.device==="desktop"?(s$(this.capturetarget).unbind("mousemove",t),s$(this.capturetarget).unbind("touchmove",t),s$(this.capturetarget).unbind("mouseup",t),s$(this.capturetarget).unbind("touchend",t),s$(this.capturetarget).unbind("mouseout",t),s$(this.capturetarget).unbind("touchcancel",t)):(s$(this.capturetarget).unbind(s$.browser.events.move,t),s$(this.capturetarget).unbind(s$.browser.events.end,t),s$(this.capturetarget).unbind(s$.browser.events.cancel,t))),t=this,i=typeof n.changedTouches!="undefined"?n.changedTouches[0]:n,t.deltaX=t.x-i.pageX,t.deltaY=t.y-i.pageY,t.x=i.pageX,t.y=i.pageY,t.distX=t.x-t.startX,t.distY=t.y-t.startY,t.absDistX=s$.abs(t.distX),t.absDistY=s$.abs(t.distY),r=t.dirX,u=t.dirY,t.dirX=t.deltaX>0?1:-1,t.dirY=t.deltaY>0?1:-1,t.absDirX=t.distX>0?1:-1,t.absDirY=t.distY>0?1:-1,t.options.onBeforeEnd.call(t,n),t.fingers=typeof n.touches!="undefined"?n.touches.length:0,t.fingers==0)&&(t.duration=n.timeStamp-t.startTime,t.velocityX=t.distX/(n.timeStamp-t.currentTime),t.velocityY=t.distY/(n.timeStamp-t.currentTime),t.started=!1,t.options.onEnd.call(t,n),t.startDir="")},_gestStart:function(n){var t=this;s$(t.capturetarget).addClass("gesturing");t.scale=1;t.rotation=0;t.transform="";t.startTime=n.timeStamp;t.duration=0;t.options.onStart.call(t,n);s$(t.capturetarget).bind("gesturechange",t);s$(t.capturetarget).bind("gestureend",t);s$(t.capturetarget).bind("gesturecancel",t)},_gestChange:function(n){var t=this;t.relScale=n.scale;t.relRotation=n.rotation;t.options.onChange.call(t,n)},_gestEnd:function(n){var t=this;s$(t.capturetarget).removeClass("gesturing");t.duration=n.timeStamp-t.startTime;s$(t.capturetarget).unbind("gesturechange",t);s$(t.capturetarget).unbind("gestureend",t);s$(t.capturetarget).unbind("gesturecancel",t);t.options.onEnd.call(t,n)},destroy:function(){var n=this;return(typeof n.type=="undefined"||typeof customEvents[n.type]=="undefined")&&alert("sgff"),customEvents[n.type].type==="gesture"?(s$(n.capturetarget).unbind("gesturestart",n),s$(n.capturetarget).unbind("gesturechange",n),s$(n.capturetarget).unbind("gestureend",n),s$(n.capturetarget).unbind("gesturecancel",n)):s$.browser.device==="desktop"?(s$(n.capturetarget).unbind("mousedown",n),s$(n.capturetarget).unbind("touchstart",n),s$(n.capturetarget).unbind("mousemove",n),s$(n.capturetarget).unbind("touchmove",n),s$(n.capturetarget).unbind("mouseup",n),s$(n.capturetarget).unbind("touchend",n),s$(n.capturetarget).unbind("mouseout",n),s$(n.capturetarget).unbind("touchcancel",n)):(s$(n.capturetarget).unbind(s$.browser.events.start,n),s$(n.capturetarget).unbind(s$.browser.events.move,n),s$(n.capturetarget).unbind(s$.browser.events.end,n),s$(n.capturetarget).unbind(s$.browser.events.cancel,n)),n.capturetarget=null,n.target=null,n.srcElement=null,delete n.callback,delete n.options,null}};eventFn.gesture=function(n,t,i,r){r=r||{};eventList.push(new TouchLayer(n,t,i,{onInit:function(){var n=this;n.ns={scaleThreshold:r.scaleThreshold||0,rotateThreshold:r.rotateThreshold||0,minScale:r.minScale||0,maxScale:r.maxScale||0,applyTransform:r.applyTransform};n.applyRotate=!!r.rotate;n.applyScale=!!r.scale},onStart:function(){this.ns.activated=!1},onChange:function(){var n=this;n.applyScale&&n.ns.minScale&&n.relScale>n.ns.minScale+n.ns.scaleThreshold?(gchangescreenlock===!1&&n.callback(n),n.ns.activated=!0):n.applyScale&&n.ns.maxScale&&n.relScale<n.ns.maxScale-n.ns.scaleThreshold?(gchangescreenlock===!1&&n.callback(n),n.ns.activated=!0):n.applyScale&&!n.ns.maxScale&&!n.ns.minScale&&s$.abs(n.relScale)>n.ns.scaleThreshold&&(gchangescreenlock===!1&&n.callback(n),n.ns.activated=!0)},onEnd:function(){var n=this;n.applyRotate&&!n.ns.activated&&s$.abs(n.relRotation)>n.ns.rotateThreshold&&gchangescreenlock===!1&&n.callback(n)}}))};eventFn.swipe=function(n,t,i,r){r=r||{};eventList.push(new TouchLayer(n,t,i,{onInit:function(){var t=this;t.target=n;t.ns={distance:r.distance||10,direction:r.direction||"NSEW",activateon:r.activateon||"end"};t.neededTouches=r.fingers||1},onStart:function(n){var t=this;t.target=n.target;t.ns.activated=!0;(t.ns.activateon==="start"||t.ns.activateon==="all")&&gchangescreenlock===!1&&(t.eventType="start_"+t.type,t.callback(t))},onMove:function(n){var t=this,i;(t.absDistX>=t.ns.distance||t.absDistY>=t.ns.distance)&&t.ns.activated&&t.ns.direction.indexOf(t.startDir)!=-1&&gchangescreenlock===!1&&(i=t.ns.activateon==="end",(t.ns.activateon==="move"||t.ns.activateon==="all")&&(t.ns.activated=!0,t.eventType="move_"+t.type,i=t.callback(t)),i===!0&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1))},onEnd:function(){var n=this;(n.absDistX>=n.ns.distance||n.absDistY>=n.ns.distance)&&n.ns.activated&&(n.ns.activateon==="end"||n.ns.activateon==="all")&&n.ns.direction.indexOf(n.startDir)!=-1&&gchangescreenlock===!1&&(n.eventType="end_"+n.type,n.callback(n));n.ns.activated=!1},onCancel:function(){var n=this;(n.absDistX>=n.ns.distance||n.absDistY>=n.ns.distance)&&n.ns.activated&&(n.ns.activateon==="end"||n.ns.activateon==="all")&&n.ns.direction.indexOf(n.startDir)!=-1&&gchangescreenlock===!1&&(n.eventType="end_"+n.type,n.callback(n));n.ns.activated=!1}}))};eventFn.tap=function(n,t,i,r){function u(n){var t=!1,n;return s$.browser.has.touch||(n||(n=window.event),n.which?t=n.which===3:n.button&&(t=n.button===2)),t}r=r||{};eventList.push(new TouchLayer(n,t,i,{onInit:function(){var n=this;n.ns={tapCount:0,anybutton:!1,capturefromchild:r.capturefromchild||!1,neededTaps:r.neededTaps||1,interval:r.interval||400};n.neededTouches=r.fingers||1},onStart:function(n){var t=this;t.notmoved=!0;t.target=n.currentTarget;gchangescreenlock===!1&&(!t.ns.anybutton&&u(n)&&(t.expired=!0),t.srcElement=n.target||n.srcElement,requestAnimationFrame(function(){s$(t.srcElement).addClass("fakeactive")}),t.ns.tapCount++)},onMove:function(){var n=this;n.notmoved&&n.capturetarget===n.srcElement&&(n.notmoved=!1)},onEnd:function(n){var t=this,i;if(t.target=null,t.ns.intervalTimeout&&clearTimeout(t.ns.intervalTimeout),t.ns.tapCount<t.ns.neededTaps){t.ns.intervalTimeout=setTimeout(function(){t.ns.tapCount=0},t.ns.interval);return}t.srcElement=n.target||n.srcElement;requestAnimationFrame(function(){t.srcElement&&s$(t.srcElement).removeClass("fakeactive")});t.absDistX<15&&t.absDistY<15&&(t.ns.capturefromchild||t.capturetarget===t.srcElement)&&(t.target=n.currentTarget,t.ns.tapCount>=t.ns.neededTaps&&(i=t.callback(t),i===!0&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1)));t.ns.tapCount=0},onCancel:function(n){var t=this;t.target=null;requestAnimationFrame(function(){s$(t.capturetarget).removeClass("fakeactive")});n.stopPropagation?n.stopPropagation():n.cancelBubble=!0;n.preventDefault?n.preventDefault():n.returnValue=!1;t.ns.tapCount=0}}))};s$.extend({xhr:function(n,t,i){function l(){r.readyState===4&&(delete s.xmlHttpRequest,r.status==200?r.handleResp():r.handleError())}var u,o;/^(inner|outer|top|bottom|before|after)$/.test(n)||(i=t,t=n,n="inner");u=i?i:{};typeof s$.xmlHttpTimeout=="undefined"&&(s$.xmlHttpTimeout=null);typeof i=="function"&&(u={},u.callback=i);var s=this,r=new XMLHttpRequest,h=u.method||"get",f=typeof u.async!="undefined"?u.async:!0,c=u.data||null,e;r.open(h,t,f);f&&(o=6e4,typeof i.timeout!="undefined"&&(o=i.timeout),typeof r.timeout!="undefined"?r.timeout=o:s$.xmlHttpTimeout=setTimeout(function(){r.abort()},o));r.queryString=c;r.setRequestHeader("X-Requested-With","XMLHttpRequest");h.toLowerCase()==="post"&&r.setRequestHeader("Content-Type","application/x-www-form-urlencoded");for(e in u.headers)u.headers.hasOwnProperty(e)&&r.setRequestHeader(e,u.headers[e]);return r.handleResp=u.callback!=null?function(){clearTimeout(s$.xmlHttpTimeout);u.callback.call(this)}:function(){clearTimeout(s$.xmlHttpTimeout);s.html(n,r.responseText)},r.handleError=u.error&&typeof u.error=="function"?function(){clearTimeout(s$.xmlHttpTimeout);u.error.call(this)}:function(){clearTimeout(s$.xmlHttpTimeout)},f&&(r.onreadystatechange=l,this.xmlHttpRequest=r),r.send(c),f||l(),this}});s$.network=function(){var n=function(n,t){this.reachableCallbackSuccess=n;this.reachableCallbackFail=t;typeof navigator.connection!="undefined"?typeof Connection!="undefined"?navigator.connection.type===Connection.UNKNOWN||navigator.connection.type===Connection.NONE?this.reachableCallbackFail():this.reachableCallbackSuccess():this.reachableCallbackSuccess():typeof navigator.onLine!="undefined"?navigator.onLine?this.reachableCallbackSuccess():this.reachableCallbackFail():this.reachableCallbackSuccess()},t=function(){var n=s$.id("spinner-page");n.length&&n.show()},i=function(){var n=s$.id("spinner-page");n.length&&n.hide()};return{checkInternetConnection:n,startConnection:t,endConnection:i}}();postifyJson=function(n,t){var i="",r=function(n,t){var u,f;for(u in n)if(f=isFinite(u)?(t!=""?t:"")+"["+u+"]":(t!=""?t+".":"")+u,n[u]instanceof VMAttr)n[u].value&&n[u].value.constructor==Array?r(n[u].value,f!=""?f:u):i+=f+"="+n[u].toJSON()+"&";else switch(typeof n[u]){case"number":case"string":case"boolean":i+=f+"="+n[u]+"&";break;case"object":r(n[u],f!=""?f:u)}};return typeof t=="undefined"&&(t=""),r(n,t),i};postifySave=function(n,t,i){var r={},u=function(n,t){var i,f;for(i in n)if(f=isFinite(i)?(t!=""?t:"")+"["+i+"]":(t!=""?t+".":"")+i,n[i]instanceof VMAttr)n[i].value&&n[i].value.constructor==Array?u(n[i].value,f!=""?f:i):r[f]=n[i].value;else switch(typeof n[i]){case"number":case"string":case"boolean":r[f]=n[i];break;case"object":u(n[i],f!=""?f:i)}};u(n,"LogOnModel");switch(typeof t){case"number":case"string":case"boolean":r[i]=t;break;case"object":u(t,i)}return r};VM=VM||{};VM={attr:VMAttr,array:VMArray,wrap:VMWrap};VMAttr.prototype.set=function(n){var t=this.value,i=n;return(n=this.parseFn?this.parseFn(n):n,this.parseFn===Number&&isNaN(i))?(n=i,this):t===n?this:(this.value=n,this.emit("change",this.get(),t),this)};VMAttr.prototype.get=function(){return this.value};VMAttr.prototype.on=function(n,t){return VM.viewmodel.bindVMEvent(this,n,t,this.viewmodel,!0),this};VMAttr.prototype.off=function(n,t){return VM.viewmodel.unbindVMEvent(this,n,t,this.viewmodel),this};VMAttr.prototype.emit=function(){var n=[].slice.call(arguments,1);return this.viewmodel.handleChange.call(this.viewmodel,this._eventId,n),this};VMAttr.prototype.valueOf=function(){return this.get()};VMAttr.prototype.toJSON=function(){return this.get()};VMAttr.prototype.toString=function(){return this.get()==null?"":this.get().toString()};VMAttr.prototype.destroy=function(){this.viewmodel=null;this.value=null;this.parseFn=null};VMArray.prototype=new VMAttr;VMArray.prototype.set=function(n,t){if(arguments.length===1)return this.replace(n);var i=this.value[n];return this.value[n]=t,this.emit("change",this.get(),(new VM.ChangeSet).remove(n,[i]).add(n,[t])),this};VMArray.prototype.get=function(n){return arguments.length===0?this.value:this.value[n]};VMArray.prototype.push=function(n){var t=this.length;return this.value.push(n),this.emit("change",this.get(),(new VM.ChangeSet).add(t,[n])),this};VMArray.prototype.unshift=function(n){return this.value.unshift(n),this.emit("change",this.get(),(new VM.ChangeSet).add(0,[n])),this};VMArray.prototype.pop=function(){var t=this.length,n=this.value.pop();return this.emit("change",this.get(),(new VM.ChangeSet).remove(t,[n])),n};VMArray.prototype.shift=function(){var n=this.value.shift();return this.emit("change",this.get(),(new VM.ChangeSet).remove(0,[n])),n};VMArray.prototype.replace=function(n){var t=this.value;return this.value=n,this.emit("change",this.get(),(new VM.ChangeSet).remove(0,t).add(0,n)),this};VMArray.prototype.remove=function(n){var t=VM.util.indexOf(this.value,n);return this.removeIndex(t)};VMArray.prototype.removeEach=function(n){for(var t=this.value.length,i=[],r;t--;)r=this.value[t],n(r)&&i.push(this.removeIndex(t));return i};VMArray.prototype.removeIndex=function(n){if(n!==-1){var t=this.value.splice(n,1)[0];return t&&this.emit("change",this.get(),(new VM.ChangeSet).remove(n,[t])),t}};VMArray.prototype.onEach=function(n,t,i){function u(r,u){for(var e,f=0;f<u.length;f++)(e=i?i(u[f]):u[f],e)&&e[r==="add"?"on":"off"](n,t)}var r;this.on("change",function(n,t){for(var i=0;i<t.length;i++)r=t[i],u(r.operation,r.items)});return u("add",this.value),this};VMArray.prototype.length=function(){return this.value.length};VMArray.prototype.destroy=function(){while(this.value.length)this.value[0].constructor==VMAttr?this.value[0].destroy():VM.destroyAttr(this.viewmodel,this.value[0]),this.value.splice(0,1);this.viewmodel=null;this.value=null;this.parseFn=null};VM.ChangeSet=function(){};VM.ChangeSet.prototype=[];VM.ChangeSet.prototype.add=function(n,t){return this.push({operation:"add",index:n,items:t}),this};VM.ChangeSet.prototype.remove=function(n,t){return this.push({operation:"remove",index:n,items:t}),this};VMWrap.prototype=new VMAttr;VMWrap.prototype.get=function(){var n=this.attr.get();return this.wrapper.get(n)};VMWrap.prototype.set=function(n){return n=this.wrapper.set(n),this.attr.set(n),this};VM.createAttr=function(n,t){for(var i in t)if(i!="viewmodel")switch(typeof t[i]){case"number":t[i]=VM.attr(n,t[i],Number);break;case"string":t[i]=VM.attr(n,t[i],String);break;case"boolean":t[i]=VM.attr(n,t[i]);break;case"object":t[i]==null?t[i]=VM.attr(n,t[i],String):t[i].constructor==Array?(VM.createAttr(n,t[i]),t[i]=VM.array(n,t[i],Text)):t[i].constructor==Date||VM.createAttr(n,t[i])}};VM.destroyAttr=function(n,t){for(var i in t)switch(typeof t[i]){case"number":delete t[i];break;case"string":delete t[i];break;case"boolean":delete t[i];break;case"object":t[i]!==null&&(t[i].constructor==Array?(VM.destroyAttr(n,t[i]),t[i].destroy(),delete t[i]):t[i].constructor==Date||(typeof t[i].destroy=="undefined"||t[i].destroy(),delete t[i]))}};VM.util={};VM.util.argumentNames=function(n){var t=n.toString().match(/^[\s\(]*function[^(]*\(([^\)]*)\)/)[1].replace(/\s+/g,"").split(",");return t.length==1&&!t[0]?[]:t};VM.util.indexOf=function(n,t,i){if(n.indexOf)return n.indexOf(t,i);for(var r=i||0,u=n.length;r<u;r++)if(n[r]===t)return r;return-1};VM.util.beget=function(n){var i=function(){},t;return i.prototype=n,t=new i,t["ivy:proto"]=n,t};VM.util.bind=function(n,t){return function(){n.call(t,arguments)}};VM=VM||{};VM.bindAttrToSelectedIndex=function(n,t,i){function e(t){if(document.activeElement===n){if(r)return;r=function(){e(n.selectedIndex);VM.dom.off(n,"blur",r,f);r=null};VM.dom.on(n,"blur",r,f)}else n.selectedIndex=t}function o(){u.set(n.selectedIndex)}var u=this.lookup(t),r,f=this.viewmodel;if(i=i||"change",VM.watchAttr(u,"change",e,t),u.set)VM.dom.on(n,i,o,f)};VM.unbindAttrToSelectedIndex=function(n,t,i){var r=this.lookup(t),u=this.viewmodel;i=i||"change";VM.dom.off(n,i);VM.dom.off(n,"blur")};VM.bindAttrToSelectedData=function(n,t,i){function e(t){if(document.activeElement===n){if(r)return;r=function(){e(n.selectedIndex);VM.dom.off(n,"blur",r,f);r=null};VM.dom.on(n,"blur",r,f)}else for(var i=0;i<n.options.length;i++)if(n.options[i].innerHTML===t){n.selectedIndex=i;break}}function o(){n.selectedIndex===-1&&u.set("");u.set(n.options[n.selectedIndex].text)}var u=this.lookup(t),r,f=this.viewmodel;if(i=i||"change",VM.watchAttr(u,"change",e,t),u.set)VM.dom.on(n,i,o,f)};VM.unbindAttrToSelectedValue=function(){};VM.unbindAttrToSelectedData=function(){};VM.bindAttrToSelectedValue=function(n,t,i){function e(t){if(document.activeElement===n){if(r)return;r=function(){e(n.options[n.selectedIndex].value);VM.dom.off(n,"blur",r,f);r=null};VM.dom.on(n,"blur",r,f)}else for(var i=0;i<n.options.length;i++)if(n.options[i].value==t){n.selectedIndex=i;break}}function o(){n.selectedIndex===-1&&u.set("");u.set(n.options[n.selectedIndex].value)}var u=this.lookup(t),r,f=this.viewmodel;if(i=i||"change",VM.watchAttr(u,"change",e,t),u.set)VM.dom.on(n,i,o,f)};VM.unbindAttrToSelectedData=function(){};VM.bindAttrToValue=function(n,t,i){function e(t){if(document.activeElement===n){if(u)return;u=function(){e(r.valueOf());VM.dom.off(n,"blur",u,f);u=null};VM.dom.on(n,"blur",u,f)}else n.value=t}function o(){r.set(n.value)}var r=this.lookup(t),u,f=this.viewmodel;if(r==null&&(r=""),i=i||"change",VM.watchAttr(r,"change",e,t),r.set)VM.dom.on(n,i,o,f)};VM.unbindAttrToValue=function(n,t,i){i=i||"change";VM.dom.off(n,i)};VM.bindAttrToChecked=function(n,t,i){function e(t){n.checked=t;u&&(n.parentElement.className=n.checked?"radio on":"radio off")}function o(){r.set(!!n.checked)}var r=this.lookup(t),u=n.type==="radio",f=this.viewmodel;if(i=i||"click",VM.watchAttr(r,"change",e,t),n.checked=r.value,u&&(n.parentElement.className=n.checked?"radio on":"radio off"),r.set)VM.dom.on(n,i,o,f)};VM.unbindAttrToChecked=function(){};VM.bindAttrToHTML=function(n,t){var i=this.lookup(t);if(0){VM.watchAttr(i,"change",r,t);function r(t){s$(n).html("inner",t)}}else typeof i.value!="undefined"?s$(n).html("inner",i.value):s$(n).html("inner",i)};VM.bindAttrToText=function(n,t,i){var r=this.lookup(t);if(typeof i!="undefined"){function u(t){VM.dom.clear(n);t===null?n.style.display="none":(n.appendChild(document.createTextNode(t)),n.style.display="inline-block")}VM.watchAttr(r,"change",u,t)}else VM.dom.clear(n),r!==null&&(n.appendChild(document.createTextNode(r)),n.style.display=n.tagName.toLowerCase()=="option"?"block":"inline-block")};VM.unbindAttrToText=function(n){VM.dom.clear(n)};VM.bindAttrToName=function(n,t){var i=this.lookup(t);n.name=i.value};VM.bindAttrToClassName=function(n,t,i,r){function o(n,t){u(n,t)}function s(n){var t=n.valueOf()?i:r,f=n.valueOf()?r:i;u(t,f)}function u(t,i){for(var e=n.className.split(/\s+/),f=[],o,r,u=0,s=e.length;u<s;u++)r=e[u],o|=r===t,r!=i&&r!=""&&f.push(r);o||f.push(t);n.className=f.join(" ")}var f=this.lookup(t),e=arguments.length===2?o:s;VM.watchAttr(f,"change",e,t)};VM.unbindAttrToClassName=function(){};VM.bindAttrToCSS=function(n,t,i){function u(t){n.style[i]=t}var r=this.lookup(t);VM.watchAttr(r,"change",u,t)};VM.unbindAttrToCSS=function(){};VM.bindAttrToDomData=function(n,t,i){function u(t){s$(n).data(i,t)}var r=this.lookup(t);VM.watchAttr(r,"change",u,t)};VM.bindAttrToDomAttr=function(n,t,i){function f(t){u?!t?n.removeAttribute(i):n.setAttribute(i,i):n.setAttribute(i,t)}var r=this.lookup(t),u=VM.bindAttrToDomAttr.booleanProperties[i];VM.watchAttr(r,"change",f,t)};VM.unbindAttrToDomData=function(){};VM.unbindAttrToDomAttr=function(){};VM.bindAttrToDomAttr.booleanProperties={disabled:!0};VM.bindAttrToFocus=function(n,t){function f(t){setTimeout(function(){t?n.focus():n.blur()})}function u(){i.set(document.activeElement===n)}var i=this.lookup(t),r=this.viewmodel;if(VM.watchAttr(i,"change",f,t),i.set){VM.dom.on(n,"blur",u,r);VM.dom.on(n,"focus",u,r)}};VM.bindAttrToEach=function(n,t,i){function e(t){var i,e,r;for(VM.dom.clear(n),i=0,e=t.length;i<e;i++)r=u.cloneNode(!0),VM.bindDom(r,t[i],f),n.appendChild(r)}var r=this.lookup(t),u=VM.dom.getTemplate(n,i),f=this.viewmodel;n.__managed=!0;VM.watchAttr(r,"change",e,t)};VM.unbindAttrToEach=function(n){VM.dom.clear(n)};VM.bindAttrToWith=function(n,t,i){function e(t){var i=f.cloneNode(!0);VM.dom.clear(n);VM.bindDom(i,t,u);n.appendChild(i)}var r=this.lookup(t),u=this.viewmodel,f=VM.dom.getTemplate(n,i);n.__managed=!0;VM.watchAttr(r,"change",e,t)};VM.bindAttrToShow=function(n,t){function u(t){n.style.display=t?r:"none"}var i=this.lookup(t),r=n.style.display;VM.watchAttr(i,"change",u,t)};VM.bindFnToEvent=function(n,t,i){var r=this.lookup(i);VM.dom.on(n,t,r)};VM.unbindFnToEvent=function(n,t){VM.dom.off(n,t)};VM.watchAttr=function(n,t,i,r){if(typeof n=="undefined"&&console.log("VM.BindingRule.prototype.lookup "+r+" - Failed"),n.on)n.on(t,i);i(n.valueOf())};VM.bindings={selectedvalue:VM.bindAttrToSelectedValue,selecteddata:VM.bindAttrToSelectedData,selectedindex:VM.bindAttrToSelectedIndex,value:VM.bindAttrToValue,checked:VM.bindAttrToChecked,text:VM.bindAttrToText,html:VM.bindAttrToHTML,attr:VM.bindAttrToDomAttr,data:VM.bindAttrToDomData,css:VM.bindAttrToCSS,name:VM.bindAttrToName,"class":VM.bindAttrToClassName,show:VM.bindAttrToShow,focus:VM.bindAttrToFocus,each:VM.bindAttrToEach,"with":VM.bindAttrToWith,on:VM.bindFnToEvent};VM.unbindings={selectedvalue:VM.unbindAttrToSelectedValue,selecteddata:VM.unbindAttrToSelectedData,selectedindex:VM.unbindAttrToSelectedIndex,value:VM.unbindAttrToValue,checked:VM.unbindAttrToChecked,text:VM.unbindAttrToText,html:VM.unbindAttrToHTML,attr:VM.unbindAttrToDomAttr,data:VM.unbindAttrToDomData,css:VM.unbindAttrToCSS,name:VM.unbindAttrToName,"class":VM.unbindAttrToClassName,show:VM.unbindAttrToShow,focus:VM.unbindAttrToFocus,each:VM.unbindAttrToEach,"with":VM.unbindAttrToWith,on:VM.unbindFnToEvent};VM.dom={};VM.dom.ELEMENT_NODE=document.ELEMENT_NODE||1;VM.dom.getViewModelFromElement=function(n){var t=n;for(typeof t=="undefined";t.parentNode;){if(typeof t.viewmodel!="undefined")return t.viewmodel;t=t.parentNode}return null};VM.dom.getsetEventID=function(n){return typeof n._eventId!="undefined"?n._eventId:n._eventId=VM.dom.nextEventID++};VM.dom.nextEventID=1;VM.dom.on=function(n,t,i,r){t==="change"?s$(n).binddirect(t,i,!0):t==="blur"||t==="focus"?s$(n).tbind(t,i,!0):s$(n).tbind(t,i,r)};VM.dom.off=function(n,t,i,r){t==="change"?s$(n).unbinddirect(t,i,!0):t==="blur"||t==="focus"?s$(n).tunbind(t,i,!0):s$(n).tunbind(t,i,r)};VM.viewmodel={};VM.viewmodel.bind=function(n,t,i,r){for(typeof r=="undefined";typeof r[".."]!="undefined";)r=r[".."];VM.dom.getsetEventID(n);typeof r._domEvent=="undefined"&&(r._domEvent={});var f=t,u=t.indexOf("{");u!==-1&&(t=t.substring(0,u));typeof r._domEvent[t]=="undefined"&&(r._domEvent[t]={},r._domEvent[t].count=0,delegateE&&n.nodeType&&s$.id(r.nodeid).binddirect(f,r.handleEvent,!0));typeof r._domEvent[t][n._eventId]=="undefined"&&(r._domEvent[t][n._eventId]={},r._domEvent[t][n._eventId].count=0);typeof r._domEvent[t][n._eventId][r._domEvent[t][n._eventId].count]=="undefined"&&(r._domEvent[t][n._eventId][r._domEvent[t][n._eventId].count]={},r._domEvent[t][n._eventId][r._domEvent[t][n._eventId].count].callback=i,r._domEvent[t][n._eventId][r._domEvent[t][n._eventId].count].element=n,r._domEvent[t][n._eventId].count++,r._domEvent[t].count++)};VM.viewmodel.unbindAll=function(n){var t,i,r;for(t in n._domEvent)for(i in n._domEvent[t])if(i!="count")for(r in n._domEvent[t][i])r!="count"&&VM.dom.off(n._domEvent[t][i][r].element,t,n._domEvent[t][i][r].callback)};VM.viewmodel.unbind=function(n,t,i,r){typeof r._domEvent[t]!="undefined"&&typeof r._domEvent[t][n._eventId]!="undefined"&&(delete r._domEvent[t][n._eventId][r._domEvent[t][n._eventId].count],r._domEvent[t][n._eventId].count--,r._domEvent[t][n._eventId].count==0&&(delete r._domEvent[t][n._eventId],r._domEvent[t].count--,r._domEvent[t].count==0&&(s$.id(r.nodeid).unbinddirect(t,r.handleEvent,!0),delete r._domEvent[t])))};VM.viewmodel.bindVMEvent=function(n,t,i,r){for(typeof r=="undefined";typeof r[".."]!="undefined";)r=r[".."];VM.dom.getsetEventID(n);typeof r._vmEvent=="undefined"&&(r._vmEvent={});var f=t,u=t.indexOf("{");u!==-1&&(t=t.substring(0,u));typeof r._vmEvent[t]=="undefined"&&(r._vmEvent[t]={},r._vmEvent[t].count=0);typeof r._vmEvent[t][n._eventId]=="undefined"&&(r._vmEvent[t][n._eventId]={},r._vmEvent[t][n._eventId].count=0);typeof r._vmEvent[t][n._eventId][r._vmEvent[t][n._eventId].count]=="undefined"&&(r._vmEvent[t][n._eventId][r._vmEvent[t][n._eventId].count]=i,r._vmEvent[t][n._eventId].count++,r._vmEvent[t].count++)};VM.viewmodel.unbindVMEvent=function(n,t,i,r){typeof r._vmEvent[t]!="undefined"&&typeof r._vmEvent[t][n._eventId]!="undefined"&&(delete r._vmEvent[t][n._eventId][r._vmEvent[t][n._eventId].count],r._vmEvent[t][n._eventId].count--,r._vmEvent[t][n._eventId].count==0&&(delete r._vmEvent[t][n._eventId],r._vmEvent[t].count--,r._vmEvent[t].count==0&&delete r._vmEvent[t]))};delegateE=!0;VM.dom.clear=function(n){for(s$(n).clean();n.hasChildNodes();)n.removeChild(n.firstChild)};VM.dom.detachChildren=function(n){for(var t=document.createDocumentFragment(),i=n.children,r=i.length;r--;)t.appendChild(i[0]);return t};VM.dom.getTemplate=function(n,t){var r,i;return t?(i=document.getElementById(t),VM.dom._template.innerHTML=i.innerText||i.textContent||i.innerHTML,r=VM.dom.detachChildren(VM.dom._template)):r=VM.dom.detachChildren(n),r};VM.dom._template=document.createElement("div");VM.fn=function(){function r(){i.set(f.apply(i,n))}for(var n=Array.prototype.slice.call(arguments),u=n.pop(),f=n.pop(),i=VMAttr(u),t=0;t<n.length;t++)n[t].on("change",r);return r(),i};VM.fnWith=function(){var t,f;typeof arguments=="undefined"&&alert("arguments -undef");var i=arguments[0],r=arguments[1],u=VM.util.argumentNames(r),n=[];for(t=0,f=u.length;t<f;t++)n.push(i[u[t]]);return n.push(r),n.push(i),VM.fn.apply(this,n)};VM.getBindings=function(n,t){var r=n.getAttribute("data-bind"),f=[],u,i,e;if(!r)return null;for(r=r.replace(/^\s*/m,""),u=r.split(/\s*;\s*/),i=0,e=u.length;i<e;i++)u[i].match(/^\s*$/)||f.push(new VM.BindingRule(u[i],t));return f};VM.trycatch=!1;VM.bindDom=function(n,t,i){var n=n||document.body,t=t||window,u,r,f;if(typeof n=="string"&&(n=document.getElementById(n)),i&&(t=VM.util.beget(t),t[".."]=i),n.nodeType===VM.dom.ELEMENT_NODE&&(u=VM.getBindings(n,t),u))for(r=0,f=u.length;r<f;r++)VM.bindElement(n,u[r]);if(!n.__managed)for(var r=0,e=n.children||n.childNodes,f=e.length;r<f;r++)VM.bindDom(e[r],t)};VM.unbindDom=function(n,t){VM.unbindDomL(n,t);VM.viewmodel.unbindAll(t)};VM.unbindDomL=function(n,t){var n=n||document.body,t=t||window,r,i,u;if(typeof n=="string"&&(n=document.getElementById(n)),n.nodeType===VM.dom.ELEMENT_NODE&&(r=VM.getBindings(n,t),r))for(i=0,u=r.length;i<u;i++)VM.unbindElement(n,r[i]);if(!n.__managed)for(var i=0,f=n.children||n.childNodes,u=f.length;i<u;i++)VM.unbindDomL(f[i],t)};VM.bindElement=function(n,t){var u=t.name,f=[n].concat(t.options),r,i;if(r=VM.bindings[u],r)if(VM.trycatch)try{r.apply(t,f)}catch(e){i=VM.util.beget(e);i.message=[e.message,"\n\tWhile binding ",n.tagName," '",u,": ",t.options.join(" "),";'"].join("");i.element=n;n.setAttribute("data-bind-error",i.message);console.log(i.message);throw i;}else r.apply(t,f);else console.warn("Unknown binding: ",u,t,"on element",n)};VM.unbindElement=function(n,t){var u=t.name,f=[n].concat(t.options),r,i;if(r=VM.unbindings[u],r)if(VM.trycatch)try{r.apply(t,f)}catch(e){i=VM.util.beget(e);i.message=[e.message,"\n\tWhile unbinding ",n.tagName," '",u,": ",t.options.join(" "),";'"].join("");i.element=n;n.setAttribute("data-bind-error",i.message);console.log(i.message);throw i;}else r.apply(t,f);else console.warn("Unknown unbinding: ",u,t,"on element",n)};VM.BindingRule=function(n,t){var r=n.replace(/^\s*/m,"").split(/\s+/),i=r.shift();if(i[i.length-1]!=":")throw new Error("Invalid syntax for binding name.\n\t"+n);this.name=i.slice(0,-1);this.options=r;this.viewmodel=t};VM.BindingRule.prototype.lookup=function(n,t){var u,i,r,f;return t=t||this.viewmodel,n==="."||n===""||n===".."?t:n.indexOf("../")===0?this.lookup(n.slice(3),t[".."]):(u=-1,i=n.split("."),i.length>1?(r=i[1].split("["),r.length>1&&(u=parseInt(r[1].substr(0,r[1].length-1)),i[1]=r[0]),u>=0)?t[i[0]][i[1]].value[u]:i.length>2?t[i[0]][i[1]][i[2]]:t[i[0]][i[1]]:(r=n.split("["),r.length>1&&(u=parseInt(r[1].substr(0,r[1].length-1))),u>=0)?t[n][u]:(f=t[n],typeof f=="undefined")?window[n]:f)};VM._id=1;VM._callers={};s$=s$||{};s$.console=function(){var n=!0,t=!1,i=function(t){n&&typeof console!="undefined"&&console.log(t)},r=function(n){t&&typeof console!="undefined"&&console.log(n)};return{log:i,logEvent:r}}();s$.loader=function(){return preloadimageindex=0,imageLoader=function(){var n=new Image;n.onload=function(){completeImageLoading()};n.onerror=function(){completeImageLoading()};n.src=s$.loader.imgList[preloadimageindex]},completeImageLoading=function(){preloadimageindex++;preloadimageindex<s$.loader.imgList.length&&imageLoader()},findImageInElement=function(n){var t="",r,i,u;if(s$(n).style("background-image")!="none"?t=s$(n).style("background-image"):typeof s$(n).attr("src")!=null&&n.nodeName.toLowerCase()=="img"&&(t=s$(n).attr("src")),typeof t!="undefined"&&t!=null&&t.length>0&&t.indexOf("gradient")==-1)for(t=t.replace(/url\(\"/g,""),t=t.replace(/url\(/g,""),t=t.replace(/\"\)/g,""),t=t.replace(/\)/g,""),r=t.split(", "),i=0;i<r.length;i++)r[i].length>0&&s$.loader.imgList.indexOf(r[i])==-1&&(u=r[i],u.indexOf("mp4")==-1&&u.indexOf("ogv")==-1&&u.indexOf("webm")==-1&&s$.loader.imgList.push(u))},_init=function(n){s$.loader.imgList=[];s$.loader.finishcallback=n;s$.loader.finishcallback("s$.loader")},{init:_init}}();s$.local=function(){var n=function(n){var t=_gAppName+n;window.localStorage.removeItem(t)},t=function(){},i=function(n){for(var t in window.localStorage)t.indexOf(n)==-1&&window.localStorage.removeItem(t)},r=function(n){var t=_gAppName+n;return window.localStorage.getItem(t)&&typeof window.localStorage.getItem(t)!="undefined"?!0:!1},u=function(n,t){var i=_gAppName+n;window.localStorage.setItem(i,JSON.stringify(t))},f=function(n){var i=_gAppName+n,t=window.localStorage.getItem(i);if(t!=null&&t!=="undefined")return JSON.parse(t)};return{init:t,nuke:i,set:u,get:f,remove:n,exists:r}}();actionPage={viewCreate:0,viewBeforeIn:1,viewIn:2,viewBeforeOut:3,viewOut:4,viewShow:5,viewHide:6,viewRefresh:7,viewOutHistory:8,viewInHistory:9,viewShowHistory:10,viewHideHistory:11,viewDestroy:12};gchangescreenlock=!1;gCleanDom=!0;gCleanWorld=!1;s$.navigator=function(){var n=[],f=function(n){var t=s$.id(n)[0],i;t.view=View[n];typeof t.view.viewCreate!="undefined"&&t.view.viewCreate();typeof t.view.viewBeforeIn!="undefined"&&t.view.viewBeforeIn();typeof t.view.viewIn!="undefined"&&t.view.viewIn();typeof t.view.viewShow!="undefined"&&t.view.viewShow();s$.navigator.direction=1;s$.navigator.s$Viewport=s$.id("viewport");s$.navigator.s$World=s$.id("world");s$.navigator.s$Pagescollection=s$.id("pagescollection");s$.navigator.changingPage=0;s$.navigator.starthash=window.location.hash;(s$.navigator.starthash==="#_=_"||s$.navigator.starthash==="_=_")&&(s$.navigator.starthash="");window.location.hash="";s$.navigator.currentHash="";s$.navigator.viewactive=s$.navigator.startPage=s$.navigator.prevpageactive=n;s$.navigator.hashqs=s$.navigator.viewactivehash=s$.navigator.prevpageactivehash="#"+n;"onhashchange"in window&&getInternetExplorerVersion()!==7?s$(window).bind("hashchange",s$.navigator.changeHashEvent):(i=location.href,setInterval(function(){var n=location.href;i!==n&&(i=n,s$.navigator.changeHashEvent(n))},100));e()},t=function(n){var t=n.id.replace("#","");typeof View[t]=="undefined"&&s$.console.log("missing imp - "+t)},d=function(){s$("[data-appview]").each(function(){t(this)})},e=function(){s$(".viewnotactive").each(function(){s$(this).data("dom")||(gCleanDom&&!s$(this).hasClass("viewactive ")?(s$.viewstore.set("page"+s$(this)[0].id,s$(this)[0].innerHTML),t(this),s$(this).empty()):t(this))})},o=function(n){typeof window.plugins.googleAnalyticsPlugin!="undefined"&&(window.plugins.googleAnalyticsPlugin.startTrackerWithAccountID(n),window.plugins.googleAnalyticsPlugin.trackPageview("/application/launch"))},r=function(){document.activeElement.blur()},s=function(){gchangescreenlock===!0&&(gchangescreenlock=!1,touchscrolling=!1)},u=function(n,t){if(!(s$.navigator.changingPage>0)&&n.length!==0&&n!=="#"&&n!=="#null"){if(n.indexOf("http")>-1||n.indexOf("https")>-1){window.open(s$.navigator.hashqs,"_blank");s$.id("blankingplate").hide();return}if(s$.navigator.viewactivehash===n){typeof s$.navigator.liveelement!="undefined"&&typeof s$.navigator.liveelement.view.viewRefresh!="undefined"&&s$.navigator.liveelement.view.viewRefresh();return}s$.viewstore.exists("page"+n.replace("#",""))||s$(n).length!==0?(s$.navigator.changingPage++,s$.navigator._queryString=t,s$.navigator._hash=n,s$.navigator.prevpageactivehash="#"+s$.navigator.viewactive,s$.navigator.prevpageactive=s$.navigator.viewactive,s$.navigator.viewactive=s$.navigator._hash.replace("#",""),s$.navigator.viewactivehash="#"+s$.navigator.viewactive,s$.navigator.prevelement=s$(s$.navigator.prevpageactivehash).first(),s$.navigator.liveelement=s$(s$.navigator.viewactivehash).first(),typeof s$.navigator.liveelement=="undefined"&&alert("Cant find html page"+s$.navigator.viewactivehash),gCleanWorld!==!1||s$(s$.navigator.liveelement).hasClass("ondemand")||gCleanDom&&s$(s$.navigator.liveelement).data("dom")===null&&!s$(s$.navigator.liveelement).hasClass("viewactive")&&s$(s$.navigator.liveelement).html("inner",s$.viewstore.get("page"+s$.navigator.viewactive)),s$.navigator.displayPageStart(),typeof window.plugins.googleAnalyticsPlugin!="undefined"&&(typeof trackEventConvertor!="undefined"?trackEventConvertor(s$.navigator._hash,"select",s$.navigator._queryString):window.plugins.googleAnalyticsPlugin.trackEvent(s$.navigator._hash,"select"))):s$.navigator.loadPage(_gAppName,n.replace("#",""),t,function(responseText){var fragment;responseText!==""&&(data=eval("("+responseText+")"));fragment=document.createDocumentFragment();s$.navigator.s$Pagescollection[0].insertAdjacentHTML("beforeEnd",data.innerHTML);for(var iindex=0,list=s$(n)[0].getElementsByTagName("SCRIPT"),len=list.length;iindex<len;iindex++)eval(list[iindex].text);s$.viewstore.set("page"+s$(n)[0].id,s$(n)[0].innerHTML);s$(n).empty();setTimeout(function(){u(n,t)},16)},s$.navigator.loadPageFail,!0)}},h=function(){r();s$.navigator.pushHistory=s$.navigator.direction===1?!0:!1;s$.navigator.popHistory=s$.navigator.direction===-1?!0:!1;s$.navigator.isPopUp=s$(s$.navigator.liveelement).data("popup")?!0:!1;s$.navigator.previousisPopUp=s$(s$.navigator.prevelement).data("popup")?!0:!1;(typeof s$.navigator.liveelement.view=="undefined"||s$.navigator.liveelement.view===null)&&(s$.navigator.liveelement.view=View[s$.navigator.viewactive],typeof s$.navigator.liveelement.view.viewCreate!="undefined"&&s$.navigator.liveelement.view.viewCreate());s$.navigator.direction===1&&(typeof s$.navigator.liveelement!="undefined"&&typeof s$.navigator.liveelement.view.viewBeforeIn!="undefined"&&s$.navigator.liveelement.view.viewBeforeIn(s$.navigator._queryString),s$.navigator.usingHistory=!1===s$.navigator.useAppHistory&&!1===s$.navigator.isPopUp&&!1===s$.navigator.previousisPopUp?!1:!0,s$.navigator.pushHistory&&s$.navigator.usingHistory&&n.push(s$.navigator.prevpageactivehash),s$.navigator.prevelement.view&&typeof s$.navigator.prevelement.view.viewBeforeOut!="undefined"&&s$.navigator.prevelement.view.viewBeforeOut(s$.navigator._queryString));s$.viewr.beforeSwap();s$.navigator.direction===-1&&(s$.navigator.liveelement.view&&typeof s$.navigator.liveelement.view.viewInHistory!="undefined"&&s$.navigator.liveelement.view.viewInHistory(),s$.navigator.prevelement&&typeof s$.navigator.prevelement.view.viewOut!="undefined"&&s$.navigator.prevelement.view.viewOut());s$.navigator.direction===1&&(s$.navigator.liveelement.view&&typeof s$.navigator.liveelement.view.viewIn!="undefined"&&s$.navigator.liveelement.view.viewIn(),s$.navigator.pushHistory?s$.navigator.prevelement.view&&typeof s$.navigator.prevelement.view.viewOutHistory!="undefined"&&s$.navigator.prevelement.view.viewOutHistory():s$.navigator.prevelement.view&&typeof s$.navigator.prevelement.view.viewOut!="undefined"&&s$.navigator.prevelement.view.viewOut());s$.viewr.swap()},c=function(){var n,t,i;s$.id("blankingplate").hide();n=!1;t=s$.navigator.direction===1;!1===t||!1===s$.navigator.usingHistory?(s$(s$.navigator.prevelement).addClass("viewnotactive").removeClass("viewactive"),s$.navigator.prevelement.view&&s$.navigator.prevelement.view.viewHide&&typeof s$.navigator.prevelement.view.viewHide!="undefined"&&s$.navigator.prevelement.view.viewHide(),n=!0):(s$.navigator.prevelement.view&&typeof s$.navigator.prevelement.view.viewHideHistory!="undefined"&&s$.navigator.prevelement.view.viewHideHistory(),s$(s$.navigator.liveelement).data("popup")||s$(s$.navigator.prevelement).addClass("viewnotactive"));i=s$.navigator.direction===-1;!1===i||!1===s$.navigator.usingHistory?typeof s$.navigator.liveelement.view.viewShow!="undefined"&&s$.navigator.liveelement.view.viewShow():typeof s$.navigator.liveelement.view.viewShowHistory!="undefined"&&s$.navigator.liveelement.view.viewShowHistory();s$.navigator.direction=1;s$.navigator.changingPage--;s$.navigator.unlockScreen();s$.navigator.prevelement.view&&typeof s$.navigator.prevelement.view.viewDestroy!="undefined"&&!0===n&&s$.navigator.prevelement.view.viewDestroy();!0===n&&gCleanWorld===!1&&(s$(s$.navigator.prevelement).empty(),s$.navigator.prevelement.view=null,null!==s$(s$.navigator.prevelement).data("no-cache")&&(s$.viewstore.remove("page"+s$.navigator.prevelement.id),s$.navigator.prevelement.parentNode.removeChild(s$.navigator.prevelement)))},l=function(){n.length&&(s$.navigator.direction=-1,i(n.pop()))},a=function(){var n=window.location.hash;n.length?i(n):window.location.hash=s$.navigator.hashqs},v=function(n){var t,r,u;if(s$.navigator.changingPage>0||n.length===0||n==="#"||n==="#null"||s$.navigator.hashqs===n){s$.id("blankingplate").hide();return}if(n.indexOf("http")>-1||n.indexOf("https")>-1){window.open(n,"_blank");s$.id("blankingplate").hide();return}s$.id("blankingplate").show();t=n;s$.navigator.changingPage===0&&(r=n.split("?"),u="",r.length>1&&(n=r[0]),!1===s$.navigator.useAppHistory&&null===s$(n).data("popup")?window.location.hash=t:i(t))},i=function(n){var t=n,i=n.split("?"),r="";i.length>1&&(t=i[0],r=n.QueryStringToJSON());s$.navigator.hashqs=n;s$.navigator.displayPage(t,r)},y=function(){return n.length},p=function(){s$(".viewactive").each(function(){typeof this.view.viewBeforeOut!="undefined"&&this.view.viewBeforeOut();typeof this.view.viewOut!="undefined"&&this.view.viewOut();typeof this.view.viewHide!="undefined"&&this.view.viewHide();typeof this.view.viewDestroy!="undefined"&&this.view.viewDestroy();this.view=null;this.viewmodel=null;s$(this).empty();s$(this).addClass("viewnotactive").removeClass("viewactive");null!==s$(this).data("no-cache")&&(s$.viewstore.remove("page"+this.id),this.parentNode.removeChild(this))});s$.navigator.viewactive=s$.navigator.startPage;s$.navigator.prevpageactivehash="#"+s$.navigator.startPage;n=[]},w=function(n){var i=[],t;for(t in n)n.hasOwnProperty(t)&&i.push(encodeURIComponent(t)+"="+encodeURIComponent(n[t]));return i.length?"?"+i.join("&"):""},b=function(n,t,i,r,u){var f=w(i);s$("html").xhr(s$.navigator.serverUrl+"/"+n+"/"+t+f,{method:"get",async:!1,data:null,error:function(){u&&u(-1,"")},callback:function(){this.responseText!==""?r&&r(this.responseText):u&&u(data.LogOnModel.ResultID,data.LogOnModel.ResultMessage)}})},k=function(){};return{loadPage:b,loadPageFail:k,setupGA:o,displayPage:u,displayPageStart:h,displayPageFinish:c,back:l,historyClear:p,historyLength:y,init:f,changeHash:v,changeHashEvent:a,unlockScreen:s,lockScreen:r,linkPage:t}}();s$.navigator.usingHistory=s$.navigator.useAppHistory=!0;s$.objects=function(){var n={},t=function(){var n=_gAppName+originalkey;delete object[n]},i=function(){},r=function(t){for(var i in n)n.hasOwnProperty(i)&&key.indexOf(t)==-1&&delete object[i]},u=function(t){var i=_gAppName+t;return n.hasOwnProperty(i)?!0:!1},f=function(t,i){var r=_gAppName+t;n[r]=i},e=function(t){var i=_gAppName+t;if(n.hasOwnProperty(i))return n[i]};return{init:i,nuke:r,set:f,get:e,remove:t,exists:u}}();s$.viewr=function(){var n=!1,t=function(t){n=!0;t.type===s$.browser.events.transitionend&&s$.navigator.prevelement!==null&&s$.navigator.liveelement!==null&&(t.target.id===s$.navigator.prevelement.id||t.target.id===s$.navigator.liveelement.id)&&(s$(document).unbind(s$.browser.events.transitionend),s$.viewr.afterSwap())},i=function(t){n=!0;t.type===s$.browser.events.animationend&&s$.navigator.prevelement!==null&&s$.navigator.liveelement!==null&&t.target.id===s$.navigator.liveelement.id&&(s$(document).unbind(s$.browser.events.animationend),s$.viewr.afterSwap())},r=function(){s$.navigator.changingPage>0&&n===!1&&(s$.browser.has.animationEnd=!1,rateDeviceHighMediumLow("ratingLow"),rateDeviceScreenTransition("noST"),s$.viewr.afterSwap(),s$(s$.navigator.liveelement)[0].display="inline-block !important")},u=function(){if(n=!0,s$.navigator.changingPage>0){var t=s$.navigator.prevelement,i=s$(s$.navigator.liveelement).data("popup");s$.navigator.displayPageFinish();s$(s$.navigator.liveelement).removeClass("viewIn").removeClass("viewOut");s$(s$.navigator.prevelement).removeClass("viewIn").removeClass("viewOut");f();s$.navigator.prevelement=null}},f=function(){s$.navigator.overrideanimate===null?s$.browser.screenTransition==="animationST"&&(s$(s$.navigator.prevelement).removeClass(outClass),s$(s$.navigator.liveelement).removeClass(inClass)):s$.navigator.s$World.removeClass(s$.navigator.overrideanimate);s$.navigator.s$World.removeClass("animWorldTo").removeClass("first").removeClass("popup").removeClass("second").removeClass("standard").removeClass("directionForwards").removeClass("directionBackwards")},e=function(){var n="",t=null;s$.navigator.overrideanimate=null;n+=" animWorldFrom";s$.navigator.previousisPopUp&&s$.navigator.isPopUp?n+=" second":(s$.navigator.previousisPopUp||s$.navigator.isPopUp)&&(n+=" first");(s$.navigator.isPopUp===!0||s$.navigator.previousisPopUp===!0)&&(n+=" popup");s$.navigator.direction===-1?(n+=" directionBackwards",t=s$(s$.navigator.prevelement).data("override-transition-animation")):(n+=" directionForwards",t=s$(s$.navigator.liveelement).data("override-transition-animation"));t!==null?(s$.navigator.overrideanimate=t,n+=" "+s$.navigator.overrideanimate):n+=" standard";s$.navigator.s$World.addClass(n)},o=function(){e();switch(s$.browser.screenTransition){case"animationST":case"transitionST":s$.navigator.prevelement&&s$(s$.navigator.prevelement).addClass("beforeviewOut");s$(s$.navigator.liveelement).hasClass("viewactive")&&s$(s$.navigator.liveelement).hasClass("viewnotactive")?s$(s$.navigator.liveelement).addClass("viewnotvisible").addClass("beforeviewIn").removeClass("viewnotactive"):s$(s$.navigator.liveelement).addClass("beforeviewIn").removeClass("viewnotactive");break;case"emileST":s$.navigator.previousisPopUp||(s$.navigator.liveelement.style.opacity=0);s$.navigator.prevelement.style.opacity=1;s$(s$.navigator.liveelement).hasClass("viewactive")||s$(s$.navigator.liveelement).addClass("viewactive");s$(s$.navigator.liveelement).hasClass("viewnotactive")&&s$(s$.navigator.liveelement).removeClass("viewnotactive");break;case"noST":default:s$(s$.navigator.liveelement).hasClass("viewactive")||s$(s$.navigator.liveelement).addClass("viewactive");s$(s$.navigator.liveelement).hasClass("viewnotactive")&&s$(s$.navigator.liveelement).removeClass("viewnotactive")}},s=function(){},h=function(){n===!1&&setTimeout(function(){r()},7500);var f="",u="";s$(s$.navigator.liveelement)[0].display="inline-block !important";s$.navigator.s$World.addClass("animWorldTo").removeClass("animWorldFrom");switch(s$.browser.screenTransition){case"animationST":f+=" viewOut ";u+=" viewIn ";outClass=inClass="";s$.navigator.overrideanimate===null&&(typeof pageAnimSelector!="undefined"&&pageAnimSelector(),f+=" "+outClass+" ",u+=" "+inClass+" ");s$(document).bind(s$.browser.events.animationend,i);requestAnimationFrame(function(){setTimeout(function(){requestAnimationFrame(function(){s$.navigator.prevelement&&s$(s$.navigator.prevelement).addClass(f).removeClass("beforeviewOut");s$(s$.navigator.liveelement).hasClass("viewactive")?s$(s$.navigator.liveelement).addClass(u).removeClass("beforeviewIn").removeClass("viewnotvisible"):s$(s$.navigator.liveelement).addClass(u).removeClass("beforeviewIn").removeClass("viewnotvisible").addClass("viewactive")})},1e3/30)});break;case"transitionST":f+=" viewOut ";u+=" viewIn ";outClass=inClass="";s$(document).bind(s$.browser.events.transitionend,t);requestAnimationFrame(function(){s$(s$.navigator.liveelement).hasClass("viewactive")?s$(s$.navigator.liveelement).removeClass("viewnotvisible"):s$(s$.navigator.liveelement).removeClass("viewnotvisible").addClass("viewactive");s$(s$.navigator.liveelement)[0].display="inline-block !important";setTimeout(function(){requestAnimationFrame(function(){s$.navigator.prevelement&&s$(s$.navigator.prevelement).addClass(f).removeClass("beforeviewOut");s$(s$.navigator.liveelement).addClass(u).removeClass("beforeviewIn")})},20)});break;case"emileST":requestAnimationFrame(function(){setTimeout(function(){s$.navigator.direction===1?s$.navigator.isPopUp?emile(s$.navigator.liveelement,"opacity: 1.0",{duration:500,after:function(){s$.viewr.afterSwap()}}):emile(s$.navigator.prevelement,"opacity: 0.0",{duration:500,after:function(){emile(s$.navigator.liveelement,"opacity: 1.0",{duration:500,after:function(){s$.viewr.afterSwap()}})}}):s$.navigator.previousisPopUp?emile(s$.navigator.prevelement,"opacity: 0.0",{duration:500,after:function(){s$.viewr.afterSwap()}}):emile(s$.navigator.prevelement,"opacity: 0.0",{duration:500,after:function(){emile(s$.navigator.liveelement,"opacity: 1.0",{duration:500,after:function(){s$.viewr.afterSwap()}})}})},1e3/30)});break;case"noST":default:setTimeout(function(){s$.viewr.afterSwap()},16);return}};return{flip:s,beforeSwap:o,swap:h,afterSwap:u}}();s$.viewstore=function(){var n={},t=function(t){var i=_gAppName+t;delete n[i]},i=function(){},r=function(t){for(var i in n)n.hasOwnProperty(i)&&key.indexOf(t)==-1&&delete object[i]},u=function(t){var i=_gAppName+t;return n.hasOwnProperty(i)?!0:!1},f=function(t,i){var r=_gAppName+t;n[r]=i},e=function(t){var i=_gAppName+t;if(n.hasOwnProperty(i))return n[i]};return{init:i,nuke:r,set:f,get:e,remove:t,exists:u}}();s$.session=function(){var n=function(n){window.sessionStorage.removeItem(n)},t=function(){},i=function(n){for(var t in window.sessionStorage)t.indexOf(n)==-1&&window.sessionStorage.removeItem(t)},r=function(n){var t=_gAppName+n;return window.sessionStorage.getItem(t)&&typeof window.sessionStorage.getItem(t)!="undefined"?!0:!1},u=function(n,t){var i=_gAppName+n;window.sessionStorage.setItem(i,JSON.stringify(t))},f=function(n){var i=_gAppName+n,t=window.sessionStorage.getItem(i);if(t!=null&&t!=="undefined")return JSON.parse(t)};return{init:t,nuke:i,set:u,get:f,remove:n,exists:r}}();String.prototype.QueryStringToJSON=function(){for(var o=this,s=o.replace(/(.*?\?)/,""),e=s.split("&"),t={},f,i=0;i<e.length;i++){var r=e[i].split("="),n=r[0],u=isNaN(r[1])?r[1]:parseFloat(r[1]);n.match(/(.*?)\[(.*?)]/)?(n=RegExp.$1,f=RegExp.$2,f?(n in t||(t[n]={}),t[n][f]=u):(n in t||(t[n]=[]),t[n].push(u))):t[n]=u}return t};Date.prototype.isValid=function(){return this.getTime()===this.getTime()};Date.prototype.toYMD=Date_toYMD;monthNames=["","JAN","FEB","MAR","APR","MAY","JUN","JUL","AUG","SEP","OCT","NOV","DEC"];s$.extend({validate:function(){s$("input",this).each(function(){var f=s$(this).data("val-required")!=null||s$(this).attr("required")!=null,r,u,n,t,i;f&&(s$(this).val().length<=0?(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid")):(s$(this).addClass("inputvalid"),s$(this).removeClass("inputinvalid")),s$(this).data("val-dateFuture")!=null&&(isValidDate(s$(this).val(),!0)?(s$(this).addClass("inputvalid"),s$(this).removeClass("inputinvalid")):(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid"))),s$(this).hasClass("datespinner")&&(isValidDate(s$(this).val())?(s$(this).addClass("inputvalid"),s$(this).removeClass("inputinvalid")):(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid"))));s$(this).data("number")!=null&&(r=Number(s$(this).val()),isNaN(r)?(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid")):(s$(this).addClass("inputvalid"),s$(this).removeClass("inputinvalid")));s$(this).data("email")!=null&&(u=/^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/,u.test(s$(this).val())?(s$(this).addClass("inputvalid"),s$(this).removeClass("inputinvalid")):(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid")));n=s$(this).data("val-equal");n!=null&&s$(this).val()!=s$(n).val()&&(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid"));t=s$(this).data("val-min-length");t!=null&&s$(this).val().length<parseInt(t)&&(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid"));i=s$(this).data("val-max-length");i!=null&&s$(this).val().length>parseInt(i)&&(s$(this).addClass("inputinvalid"),s$(this).removeClass("inputvalid"))})}});apiLoadCount=0;Map.prototype={destroy:function(){switch(currentObj.maptype){case"nokia":break;case"bing":break;case"google":break;case"native":window.plugins.mapKit.clearMapPins();window.plugins.mapKit.hideMap();break;default:alert("No Map type")}s$(currentObj.elements).empty();s$.map.cleargeowatch();currentObj.callbackGeoSuccess=null;currentObj.callbackGeoError=null;currentObj.callbackGeoReverse=null;currentObj.callbackGeoWatch=null},setup:function(){currentObj=this;this.shown=!1;!1===s$.map.gAPI?(loadMapScripts(),s$.id("spinner-maploading-page").show(),apiLoadCount++,apiLoadCount<2?setTimeout(scopefn(this,this.setup),15e3):(s$.id("spinner-maploading-page").hide(),apiLoadCount=0,s$(".mapsoffline").show())):(s$.id("spinner-maploading-page").hide(),this.show(),this.callbackGeoSuccess!=null&&this.showCurrentPosition())},show:function(n,t){var i,r,u,f;this.shown=!0;typeof n=="undefined"&&(n=s$.map.defaultLat,t=s$.map.defaultLng);switch(currentObj.maptype){case"nokia":nokia.Settings.set("appId","pBiUzWAYCQQQa1EckKwC");nokia.Settings.set("authenticationToken","VHDPJ-_bW6UlyyA5Sgn5vw");currentObj.map=new nokia.maps.map.Display(currentObj.elements,{components:[new nokia.maps.map.component.Behavior,new nokia.maps.map.component.ZoomBar],zoomLevel:7,center:[t,n]});break;case"bing":i={credentials:"AtoDS6mAEkR1L4X8n8cuW3OuSlPofE7-QcnTdJoh-Z-u2vRY5PW34CbXX75v_T0v",center:new Microsoft.Maps.Location(t,n),mapTypeId:Microsoft.Maps.MapTypeId.road,zoom:7};currentObj.map=new Microsoft.Maps.Map(currentObj.elements,i);break;case"google":typeof google!="undefined"&&(r=new google.maps.LatLng(n,t),u={zoom:10,center:r,mapTypeControl:!1,navigationControl:!1,navigationControlOptions:{style:google.maps.NavigationControlStyle.ANDROID},mapTypeId:google.maps.MapTypeId.ROADMAP},currentObj.map=new google.maps.Map(currentObj.elements,u));break;case"native":f={buttonCallback:currentObj.callbackMarkerClick,height:currentObj.elements.offsetHeight,width:currentObj.elements.offsetWidth,diameter:currentObj.diameter,offsetTop:currentObj.elements.offsetTop,offsetLeft:currentObj.elements.offsetLeft,lat:n,lon:t};window.plugins.mapKit.showMap();window.plugins.mapKit.setMapData(f);break;default:alert("No Map type")}},hide:function(){switch(currentObj.maptype){case"nokia":break;case"bing":break;case"google":break;case"native":window.plugins.mapKit.hideMap();break;default:alert("No Map type")}},showCurrentPosition:function(){s$.map.geocode(this.geoSuccess,this.geoError,this.geoReverse)},setupWatchCurrentPosition:function(){s$.map.geowatch(this.geoWatch,this.geoError,this.geoReverse)},positionMap:function(n,t,i){var r,u;if(this.shown==!0)if(typeof n=="undefined")n=currentObj.currentLat,t=currentObj.currentLng;else{typeof i!="undefined"&&(currentObj.diameter=i);switch(currentObj.maptype){case"nokia":break;case"bing":break;case"google":typeof google!="undefined"&&(r=new google.maps.LatLng(n,t),currentObj.map.setCenter(r));break;case"native":u={buttonCallback:currentObj.callbackMarkerClick,height:currentObj.elements.offsetHeight,width:currentObj.elements.offsetWidth,diameter:currentObj.diameter,offsetTop:currentObj.elements.offsetTop,offsetLeft:currentObj.elements.offsetLeft,lat:n,lon:t};window.plugins.mapKit.setMapData(u);break;default:alert("No Map type")}}else this.show(n,t)},clearAllMarkers:function(){switch(currentObj.maptype){case"nokia":break;case"bing":break;case"google":break;case"native":window.plugins.mapKit.clearMapPins();break;default:alert("No Map type")}},addMarker:function(n,t,i,r,u,f,e){var s,h,o,c;switch(currentObj.maptype){case"nokia":break;case"bing":break;case"google":typeof google!="undefined"&&(s=new google.maps.LatLng(n,t),typeof f!="undefined"?(h=new google.maps.MarkerImage(f,new google.maps.Size(61,26),new google.maps.Point(0,0),new google.maps.Point(0,0)),o=new google.maps.Marker({position:s,map:currentObj.map,title:i,icon:h})):o=new google.maps.Marker({position:s,map:currentObj.map,title:i}),typeof e!="undefined"&&google.maps.event.addListener(o,"click",function(){eval(e)}));break;case"native":c=[{lat:n,lon:t,title:i,subTitle:r,pinColor:"blue",selected:u}];window.plugins.mapKit.addMapPins(c);break;default:alert("No Map type")}},geoSuccess:function(n){currentObj.currentLat=n.coords.latitude;currentObj.currentLng=n.coords.longitude;currentObj.addMarker(n.coords.latitude,n.coords.longitude,"You are here!","",!0);currentObj.initPositionMap==!1&&(currentObj.positionMap(n.coords.latitude,n.coords.longitude),currentObj.initPositionMap=!0);currentObj.callbackGeoSuccess!==null&&currentObj.callbackGeoSuccess(n);currentObj.callbackGeoWatch!==null&&currentObj.setupWatchCurrentPosition()},geoWatch:function(n){currentObj.currentLat=n.coords.latitude;currentObj.currentLng=n.coords.longitude;currentObj.initPositionMap==!1&&(currentObj.positionMap(n.coords.latitude,n.coords.longitude),currentObj.initPositionMap=!0);currentObj.callbackGeoWatch!==null&&currentObj.callbackGeoWatch(n)},geoError:function(n){currentObj.callbackGeoError!==null&&currentObj.callbackGeoError(n)},geoReverse:function(n){currentObj.callbackGeoReverse!==null&&currentObj.callbackGeoReverse(n)}};s$.map=function(){var t,n,r,i,s=function(){s$.map.gAPI=!0},h=function(n,t,i,r,u){var e=Math.PI*n/180,o=Math.PI*i/180,c=Math.PI*t/180,l=Math.PI*r/180,s=t-r,h=Math.PI*s/180,f=Math.sin(e)*Math.sin(o)+Math.cos(e)*Math.cos(o)*Math.cos(h);return f=Math.acos(f),f=f*180/Math.PI,f=f*60*1.1515,f=f*1.609344,u=="M"&&(f=f*.621371192237334),Math.round(f*Math.pow(10,2))/Math.pow(10,2)},u=function(n){t!==null&&t(n);i!==null&&e(n.coords.latitude,n.coords.longitude)},v=function(n){(this.prev_lat!=n.coords.latitude||this.prev_long!=n.coords.longitude)&&(this.prev_lat=n.coords.latitude,this.prev_long=n.coords.longitude,r!==null&&r(n),i!==null&&e(n.coords.latitude,n.coords.longitude))},f=function(t){switch(t.code){}n!==null&&n(t)},y=function(){},e=function(n,t){var r=new google.maps.LatLng(n,t),u=new google.maps.Geocoder;u.geocode({latLng:r},function(n,t){if(t==google.maps.GeocoderStatus.OK&&n[1])return i!==null&&i(n),n})},o=function(){this.wpid&&(navigator.geolocation.clearWatch(this.wpid),this.wpid=!1)},c=function(r,e,s){t=r;n=e;i=s;navigator.geolocation&&(o(),this.wpid=navigator.geolocation.watchPosition(u,f,{enableHighAccuracy:!0,maximumAge:3e4,timeout:27e3}))},l=function(r,e,o){if(t=r,n=e,i=o,navigator.geolocation){var s=null;navigator.geolocation&&(s=window.chrome?{enableHighAccuracy:!1,maximumAge:15e3,timeout:1e4}:{maximumAge:6e4,timeout:5e3,enableHighAccuracy:!0},navigator.geolocation.getCurrentPosition(u,f,s))}},a=function(i,r,u){t=r;n=u;s$.id("index").xhr(s$.navigator.serverUrl+"/service/GeoForward?address="+i,{method:"post",async:!0,error:function(){n()},callback:function(){var data;this.responseText!=""&&(data=eval("("+this.responseText+")"));null!=data&&(data.status=="OK"?t(data):n())}})};return{distance:h,geocode:l,geoforward:a,geowatch:c,cleargeowatch:o,googleAPI:s,gAPI:!1}}();isTouch="ontouchstart"in window,function(){var r=function(t,i,r){if(r||(r={}),h(i)){this.compact=!1;var f="Clear",u="en";typeof calendarlanguagepack!="undefined"&&(u=calendarlanguagepack);u=="de"&&(f="Schließen");n(this,{options:n({parent:t,range:!1,lang:u,enabled:!0,firstDayOfWeek:1,selected:!1,filter:!1,templatebody:'<div class="header"><div class="cell"><div class="calheadercancel appicon appiconpopupcancel"><\/div><div class="calfooterclear"><h2 class="calfooterclear" style="color: #fff;line-height: 46px;" unselectable="on">'+f+'<\/h2><\/div><div class="calheaderdone appicon appiconpopupaction"><\/div><\/div><\/div><div class="calcontainer overthrow scroll-content"><div class=""><div class="dayselectortype">#dayselectortype#<\/div><div class="otherselectortype"><ul class="calmonthnav"><li class="calprevmonth  appicon3state appiconprev "><\/li><li class="calmontharea"><select class="calmonthselect  month editable lmtext year" ><\/select><\/li><li class="calnextmonth  appicon3state appiconnext "><\/li><\/ul><ul class="calyearnav"><li class="calprevyear  appicon3state appiconprev "><\/li><li class="calyeararea"><select class="calyearselect  editable lmtext year" ><\/select><\/li><li class="calnextyear  appicon3state appiconnext "><\/li><\/ul><ul class="calfooternav"><br style="clear:both;"><\/ul><br style="clear:both;"><\/div><br style="clear:both;"><\/div><\/div>',templatecalendar:'<ul class="calweekdays"><li><span>#wd0<\/span><\/li><li><span>#wd1<\/span><\/li><li><span>#wd2<\/span><\/li><li><span>#wd3<\/span><\/li><li><span>#wd4<\/span><\/li><li><span>#wd5<\/span><\/li><li><span>#wd6<\/span><\/li><\/ul><div class="calbody"><ul><li#cls00><span>#d00<\/span><\/li><li#cls01><span>#d01<\/span><\/li><li#cls02><span>#d02<\/span><\/li><li#cls03><span>#d03<\/span><\/li><li#cls04><span>#d04<\/span><\/li><li#cls05><span>#d05<\/span><\/li><li#cls06><span>#d06<\/span><\/li><\/ul><ul><li#cls07><span>#d07<\/span><\/li><li#cls08><span>#d08<\/span><\/li><li#cls09><span>#d09<\/span><\/li><li#cls10><span>#d10<\/span><\/li><li#cls11><span>#d11<\/span><\/li><li#cls12><span>#d12<\/span><\/li><li#cls13><span>#d13<\/span><\/li><\/ul><ul><li#cls14><span>#d14<\/span><\/li><li#cls15><span>#d15<\/span><\/li><li#cls16><span>#d16<\/span><\/li><li#cls17><span>#d17<\/span><\/li><li#cls18><span>#d18<\/span><\/li><li#cls19><span>#d19<\/span><\/li><li#cls20><span>#d20<\/span><\/li><\/ul><ul><li#cls21><span>#d21<\/span><\/li><li#cls22><span>#d22<\/span><\/li><li#cls23><span>#d23<\/span><\/li><li#cls24><span>#d24<\/span><\/li><li#cls25><span>#d25<\/span><\/li><li#cls26><span>#d26<\/span><\/li><li#cls27><span>#d27<\/span><\/li><\/ul><ul><li#cls28><span>#d28<\/span><\/li><li#cls29><span>#d29<\/span><\/li><li#cls30><span>#d30<\/span><\/li><li#cls31><span>#d31<\/span><\/li><li#cls32><span>#d32<\/span><\/li><li#cls33><span>#d33<\/span><\/li><li#cls34><span>#d34<\/span><\/li><\/ul><ul><li#cls35><span>#d35<\/span><\/li><li#cls36><span>#d36<\/span><\/li><li#cls37><span>#d37<\/span><\/li><li#cls38><span>#d38<\/span><\/li><li#cls39><span>#d39<\/span><\/li><li#cls40><span>#d40<\/span><\/li><li#cls41><span>#d41<\/span><\/li><\/ul><\/div>',templatecompact:'<div class="calcontainer"><ul class="caldaynav"><li class="calprevday  appicon3state appiconprev "><\/li><li class="caldayarea"><select class="caldayselect  editable lmtext day" ><\/select><\/li><li class="calnextday  appicon3state appiconnext "><\/li><br style="clear:both;"><\/ul><br style="clear:both;"><\/div>',classes:n({calendar:"ccal",navDomClear:".calfooterclear",navDomDone:".calheaderdone",navDomCancel:".calheadercancel",navDomPrevDay:".calprevday",navDomNextDay:".calnextday",navDomPrevMonth:".calprevmonth",navDomNextMonth:".calnextmonth",navDomPrevYear:".calprevyear",navDomNextYear:".calnextyear",calendarBody:"calbody",selected:"selected",preSelected:"preselected",today:"today",month:".month",prevMonthDate:"calprev",nextMonthDate:"calnext",disabled:"disabled",originCalendar:"origincal"},r.classes?r.classes:{}),navDomContent:{prev:"<",next:">"},monthNames:n({en:["January","February","March","April","May","June","July","August","September","October","November","December"],fr:["Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Août","Septembre","Octobre","Novembre","Décembre"],it:["Gennaio","Febbraio","Marzo","Aprile","Maggio","Giugno","Luglio","Agosto","Settembre","Ottobre","Novembre","Dicembre"],es:["Enero","Febrero","Marzo","Abril","Mayo","Junio","Julio","Augosto","Septiembre","Octubre","Noviembre","Diciembre"],de:["Januar","Februar","März","April","Mai","Juni","Juli","August","September","Oktober","November","Dezember"]},r.monthNames?r.monthNames:{}),weekDays:n({en:["Su","Mo","Tu","We","Th","Fi","Sa"],fr:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],it:["Dom","Lun","Mar","Mer","Gio","Ven","Sab"],es:["Dom","Lun","Mar","Mie","Jue","Vie","Sab"],de:["So","Mo","Di","Mi","Do","Fr","Sa"]},r.weekDays),switchMonthOnHoverDelay:800},r),displayedCalendarElement:!1,preSelection:!1,selecting:!1,created:!1,element:i,isChild:function(n){while(n){if(n==i||n==r.inputelement)return!0;n=n.parentNode}return!1},destroy:function(){s$(".calendar-canvas").tunbind(s$.browser.events.start);s$(".calendar-canvas",this.displayedCalendarElement).tunbind("tap");s$(".dayselectortype",this.displayedCalendarElement).tunbind("tap");s$(document).unbind("keydown",this,!1);s$(document).unbind(s$.browser.events.start,this,!1);s$(document).unbind(s$.browser.events.move,this,!1);s$(document).unbind(s$.browser.events.end,this,!1)},handleEvent:function(n){var o=typeof n.touches!="undefined"?n.touches[0]:n,r=n.target.parentNode,h=s$(r),t,e;switch(n.type){case"keydown":t=_currentdatecalendarcontrol[0].value;setCaretPosition(_currentdatecalendarcontrol[0],t.length);var f=t.length,u=window.event?n.keyCode:n.which,s=String.fromCharCode(u),c=new RegExp("[0123456789]");f<=9&&c.test(s)&&(_currentdatecalendarcontrol[0].value=t+s);(u==191||u==189)&&(f==2||f==5)&&(_currentdatecalendarcontrol[0].value=t+"/");u==13&&(n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1,setTimeout(this.options.destroyCalendar,150));u==8&&(_currentdatecalendarcontrol[0].value=t.substring(0,t.length-1));f==9&&(e=DStringToD(_currentdatecalendarcontrol[0].value),e.isValid()&&this.setSelected({begin:e,end:e}));n.stopPropagation?n.stopPropagation():n.cancelBubble=!0;n.preventDefault?n.preventDefault():n.returnValue=!1;break;case s$.browser.events.start:r!=null&&h.hasClass("calday")&&(this.selecting=!0,this.selectingDay=r,this.startX=o.pageX,this.startY=o.pageY,n.stopPropagation?n.stopPropagation():n.cancelBubble=!0,n.preventDefault?n.preventDefault():n.returnValue=!1);s$(document).bind(s$.browser.events.end,this);break;case s$.browser.events.end:r==this.selectingDay&&(this._beginPreselection(r),this._completePreselection(r),this.selecting=!1);s$(".preselected",i).removeClass("preselected");this.selectingClose=!1;this.selectingDay=null;s$(document).unbind(s$.browser.events.end,this);break;case s$.browser.events.resize:alert("resize")}}});this.enabled=this.options.enabled;this.setSelected(this.options.selected)}};r.prototype={disable:function(){this.enabled=!1;l(t(this.element,this.options.classes.calendar)[0],this.options.classes.disabled)},enable:function(){this.enabled=!0;o(t(this.element,this.options.classes.calendar)[0],this.options.classes.disabled)},clear:function(){this.enabled&&(_currentdatecalendarcontrol[0].value="",setTimeout(this.options.destroyCalendar,150))},done:function(){var n,t;this.enabled&&(n=null,_currentdatecalendarcontrol.data("date-future")?(n=new Date,t=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,n.setDate(n.getDate()+t),this._getDisplayedDate()<n&&(_currentdatecalendarcontrol[0].value="")):_currentdatecalendarcontrol[0].value=_dateToString(this._getDisplayedDate()),setTimeout(this.options.destroyCalendar,150))},cancel:function(){this.enabled&&setTimeout(this.options.destroyCalendar,150)},showNextDay:function(){this.enabled&&this._incDisplayedDay()},showPreviousDay:function(){this.enabled&&this._decDisplayedDay()},showNextMonth:function(){this.enabled&&this._incDisplayedMonth()},showPreviousMonth:function(){this.enabled&&this._decDisplayedMonth()},showNextYear:function(){this.enabled&&this._incDisplayedYear()},showPreviousYear:function(){this.enabled&&this._decDisplayedYear()},setSelected:function(n,t){n?(typeof n.begin=="undefined"&&(n={begin:n,end:n}),typeof t=="undefined"&&(t=!0),this.selection=n.begin>n.end?{begin:n.end,end:n.begin}:n,this.selection&&t?this._setDisplayedDate(new Date(this.selection.begin.getTime())):this._renderSelection(this.selection)):(this.selection=!1,this._setDisplayedDate(new Date),this._renderCalendar())},_getSelected:function(){return typeof this.selection=="undefined"&&(this.selection=!1),this.selection},_getSelectedElements:function(){return t(t(this.displayedCalendarElement,this.options.classes.calendarBody)[0],this.options.classes.selected)},_applyBehavior:function(){var n=this;s$(".calendar-canvas").tbind(s$.browser.events.start,function(t){var i=t.target||t.srcElement;s$(i).hasClass("calendar-canvas")&&n.cancel();s$(i).hasClass("calprevday")&&n.showPreviousDay();s$(i).hasClass("calnextday")&&n.showNextDay();s$(i).hasClass("calprevmonth")&&n.showPreviousMonth();s$(i).hasClass("calnextmonth")&&n.showNextMonth();s$(i).hasClass("calprevyear")&&n.showPreviousYear();s$(i).hasClass("calnextyear")&&n.showNextYear();s$(i).hasClass("calfooterclear")&&n.clear();s$(i).hasClass("calheaderdone")&&n.done();s$(i).hasClass("calheadercancel")&&n.cancel()});s$(".dayselectortype",this.displayedCalendarElement).tbind('tap{ "capturefromchild": true }',function(t){var i=t.srcElement.parentNode;i!==null&&s$(i).hasClass("calday")&&!s$(i).hasClass("notavailable")&&(n._beginPreselection(i),n._completePreselection(i))});s$(document).bind("keydown",this)},_selectMonth:function(){if(this.enabled){var n=this._getDisplayedDate();if(this.setSelected({begin:new Date(n.getFullYear(),n.getMonth(),1),end:new Date(n.getFullYear(),n.getMonth()+1,0)}),this._renderCalendar(),typeof this.options.onSelect!="undefined")this.options.onSelect(this.selection)}},_preventDefaultBodyMove:function(n){n.preventDefault&&n.preventDefault()},_beginPreselection:function(n){this.selection=!1;this.currentListItem=n;this.anchorDate=this._getDateFromElement(n);this.preSelection={begin:this.anchorDate,end:this.anchorDate};this._renderSelection(this.preSelection,!0)},_completePreselection:function(){if(this.currentListItem=!1,this.setSelected(this.preSelection,!1),this._renderSelection(this.selection),this.preSelection=!1,typeof this.options.onSelect!="undefined")this.options.onSelect(this.selection);this._clearHoverTimer()},_switchMonthOnTimer:function(n,t){var r=!1,u=this,f=u._getDisplayedDate().getMonth()==t.getMonth();switch(i(n.parentNode)){case 0:i(n)!=0&&f||(r="prev");break;case 4:f||(r="next");break;case 5:i(n)!=6&&f||(r="next")}r?typeof this.hoverTimer=="undefined"&&(this.hoverTimer=setTimeout(function(){r=="next"?u.showNextMonth():r=="prev"&&u.showPreviousMonth();u._clearHoverTimer()},this.options.switchMonthOnHoverDelay)):this._clearHoverTimer()},_clearHoverTimer:function(){this.hoverTimer&&clearTimeout(this.hoverTimer);this.hoverTimer=undefined},_getDateFromElement:function(n){if(this.compact)return this._getDisplayedDate();var u=i(n.parentNode),t=0,r=parseInt(n.getElementsByTagName("span")[0].innerHTML,10),f=this._getDisplayedDate();return u==0&&r>10&&(t=-1),u>=4&&r<12&&(t=1),new Date(f.getFullYear(),f.getMonth()+t,r)},_incDisplayedYear:function(){var n=this._getDisplayedDate();n.getFullYear()>=2019||(n.setFullYear(n.getFullYear()+1),this._setDisplayedDate(n))},_decDisplayedYear:function(){var n=this._getDisplayedDate(),t=null,i;_currentdatecalendarcontrol.data("date-future")&&(t=new Date,i=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,t.setDate(t.getDate()+i),n.getFullYear()<=t.getFullYear())||(n.setFullYear(n.getFullYear()-1),this._setDisplayedDate(n))},_incDisplayedDay:function(){var n=this._getDisplayedDate();n.setDate(n.getDate()+1);this._setDisplayedDate(n)},_decDisplayedDay:function(){var n=this._getDisplayedDate();n.setDate(n.getDate()-1);this._setDisplayedDate(n)},_incDisplayedMonth:function(){var n=this._getDisplayedDate(),t,i;n.setMonth(n.getMonth()+1);this._setDisplayedDate(n);t=null;_currentdatecalendarcontrol.data("date-future")&&(t=new Date,i=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,t.setDate(t.getDate()+i),this._getDisplayedDate().getFullYear()>=2019&&(n.setFullYear(t.getFullYear()),this._setDisplayedDate(n)))},_decDisplayedMonth:function(){var t=this._getDisplayedDate(),n,i;t.setMonth(t.getMonth()-1);this._setDisplayedDate(t);n=null;_currentdatecalendarcontrol.data("date-future")&&(n=new Date,i=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,n.setDate(n.getDate()+i),this._getDisplayedDate().getFullYear()<=n.getFullYear()&&(t.setFullYear(n.getFullYear()),this._setDisplayedDate(t)))},_setDisplayedDate:function(n){this.displayedMonth=n;this._renderCalendar()},_getDisplayedDate:function(){return typeof this.displayedMonth=="undefined"&&(this.displayedMonth=new Date),this.displayedMonth},_clearSelectionRender:function(){var n=this;this.displayedCalendarElement&&u(t(t(this.displayedCalendarElement,this.options.classes.calendarBody)[0],this.options.classes.selected),function(t){o(t,n.options.classes.selected)})},_renderSelection:function(n,i){var s;if(this.displayedCalendarElement){var f=!1,h=0,e,r=this,c=r._getDisplayedDate().getMonth(),i=typeof i=="undefined"?!1:i,o=null;_currentdatecalendarcontrol.data("date-future")&&(o=new Date,s=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,o.setDate(o.getDate()+s));u(t(this.displayedCalendarElement,this.options.classes.calendarBody)[0].getElementsByTagName("li"),function(t){e=[];f?f.setDate(f.getDate()+1):f=r._getDateFromElement(t);r._isWithinRange(f,n)&&e.push(i?r.options.classes.preSelected:r.options.classes.selected);r._isToday(f)&&e.push(r.options.classes.today);f.getMonth()!=c&&e.push(r.options.classes[h++<7?"prevMonthDate":"nextMonthDate"]);r.options.filter&&(e=r.options.filter(f,e));t.className=e.join(" ")+" calday";o&&f.getDate()<o&&(t.className+=" notavailable")})}},_generateCalendarHTML:function(n){var t,i=this.options.templatecalendar,u,f,o=0,c=this._getSelected(),h=this._getMonthStack(n.getMonth(),n.getFullYear()),e=null,l,s,r;for(_currentdatecalendarcontrol.data("date-future")&&(e=new Date,l=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,e.setDate(e.getDate()+l)),t=0;t<h.length;t++){if(u=new RegExp("#d"+(t>9?"":"0")+t),i=i.replace(u,h[t]),s=parseInt(h[t],10),r=[],u=new RegExp("#cls"+(t>9?"":"0")+t),o=0,t<7&&s>10?(r.push(this.options.classes.prevMonthDate),o=-1):t>27&&s<=12&&(r.push(this.options.classes.nextMonthDate),o=1),f=new Date(n.getFullYear(),n.getMonth()+o,s),c&&this._isWithinRange(f,c)&&r.push(this.options.classes.selected),this._isToday(f)&&r.push(this.options.classes.today),this.options.filter&&this.options.filter(f,r),e!==null&&f<e){i=i.replace(u,' class=" calday notavailable '+r.join(" ")+'"');continue}i=i.replace(u,' class=" calday '+r.join(" ")+'"')}for(t=0;t<7;t++)u=new RegExp("#wd"+t),i=i.replace(u,this.options.weekDays[this.options.lang][(t+this.options.firstDayOfWeek)%7]);return i},_renderCalendar:function(){var o=this._getDisplayedDate(),s,e,r,n,u,i;if(this.created)this.compact?(this.populateDaySelector(),this.dayselectElement.options.selectedIndex=this._getDisplayedDate().getDate()-1):(i=s$(".dayselectortype")[0],i.innerHTML=this._generateCalendarHTML(o)),this.yearselectElement.options.selectedIndex=this._getDisplayedDate().getFullYear()-this.startRange,this.monthselectElement.options.selectedIndex=this._getDisplayedDate().getMonth();else{for(this.created=!0,i=document.createElement("div"),i.className=this.options.classes.calendar+" popupcalendarcontainer",s=this.compact?this.options.templatebody.replace("#dayselectortype#",this.options.templatecompact):this.options.templatebody.replace("#dayselectortype#",this._generateCalendarHTML(o)),i.innerHTML=s,this.element.appendChild(i),this.displayedCalendarElement=t(this.element,this.options.classes.calendar)[0],this.yearselectElement=s$(".calyearselect")[0],this.startRange=1920,e=null,_currentdatecalendarcontrol.data("date-future")&&(e=new Date,this.startRange=e.getFullYear()),r=this.startRange;r<2020;r++)this.yearselectElement.options[this.yearselectElement.options.length]=new Option(r,r);for(this.yearselectElement.options.selectedIndex=this._getDisplayedDate().getFullYear()-this.startRange,n=this,this.yearselectElement.onchange=function(){var i=n.yearselectElement.options[n.yearselectElement.selectedIndex].value,t=n._getDisplayedDate();t.setYear(i);n._setDisplayedDate(t)},typeof calendarlanguagepack!="undefined"&&(this.options.lang=calendarlanguagepack),this.monthselectElement=s$(".calmonthselect")[0],u=0;u<12;u++)this.monthselectElement.options[this.monthselectElement.options.length]=new Option(this.options.monthNames[this.options.lang][u],u);this.monthselectElement.options.selectedIndex=this._getDisplayedDate().getMonth();this.monthselectElement.onchange=function(){var i=n.monthselectElement.options[n.monthselectElement.selectedIndex].value,t=n._getDisplayedDate();t.setMonth(i);n._setDisplayedDate(t)};this.compact&&(this.dayselectElement=s$(".caldayselect")[0],this.populateDaySelector(),this.dayselectElement.options.selectedIndex=this._getDisplayedDate().getDate()-1,this.dayselectElement.onchange=function(){var i=n.dayselectElement.options[n.dayselectElement.selectedIndex].value,t=n._getDisplayedDate();t.setDate(i);n._setDisplayedDate(t)});this._applyBehavior()}f(this.element)},populateDaySelector:function(){var r=this._getDisplayedDate(),u=r.getMonth(),f=r.getFullYear(),i=new Date(f,u+1,0),e,n,o,t;for(e=i.getDate(),this.dayselectElement.options.length=0,n=null,_currentdatecalendarcontrol.data("date-future")&&(n=new Date,o=parseInt(_currentdatecalendarcontrol.data("date-future"))-1,n.setDate(n.getDate()+o)),t=0;t<e;t++)i=new Date(f,u,t+1),dayofweek=this.options.weekDays[this.options.lang][i.getDay()],this.dayselectElement.options[this.dayselectElement.options.length]=new Option(dayofweek+" "+(t+1)+getOrdinalFromDay(i.getDate()),t+1),n&&i<n&&(this.dayselectElement.options[this.dayselectElement.options.length-1].disabled=!0)},_getMonthStack:function(n,t){for(var r=[],i=new Date(t,n+1,0),f,u=i.getDate();u--;)r.unshift(u+1+"");if(i=new Date(t,n,1),i.getDay()>0)while(i.getDay()>this.options.firstDayOfWeek)i.setDate(i.getDate()-1),r.unshift(i.getDate()+"");else for(f=6;f>0;)i.setDate(i.getDate()-1),r.unshift(i.getDate()+""),f--;for(i=new Date(t,n+1,0);r.length<42;)i.setDate(i.getDate()+1),r.push(i.getDate()+"");return r},_isToday:function(n){return typeof this.today=="undefined"&&(this.today=(new Date).toDateString()),n.toDateString()==this.today},_isWithinRange:function(n,t){var i=n.toDateString(),r={begin:t.begin.toDateString(),end:t.end.toDateString()};return i==r.begin||i==r.end?!0:n>=t.begin&&n<=t.end?!0:!1},_getActualListItem:function(n){return n}};var s=function(t,i){var u,e=!1,o=function(){i=n({inputelement:t,onSelect:l,destroyCalendar:f,separator:" - ",canvasClass:"calendar-canvas animateIn",offset:{top:0,left:0}},i?i:{});s()},s=function(){e=!0;u||c();var f=t.offsetLeft+i.offset.left,r=0;this.displaymode=="inline"&&(r=t.offsetTop+t.offsetHeight+i.offset.top);n(u.style,{position:"absolute",top:r+"px",left:f+"px"});t.blur()},h=function(){f()},c=function(){var f,n;_currentdatecalendarcontrol.data("theme")&&(this.skintheme=_currentdatecalendarcontrol.data("theme"));_currentdatecalendarcontrol.data("display-mode")&&(this.displaymode=_currentdatecalendarcontrol.data("display-mode"));typeof this.displaymode=="undefined"&&(this.displaymode="modal");u=document.createElement("div");u.className=i.canvasClass+" "+this.displaymode;u.style.position="absolute";t.parentNode.style.position||(t.parentNode.style.position="relative");this.displaymode=="inline"?t.parentNode.appendChild(u):s$.navigator.liveelement.appendChild(u);s$(u).show();t.calendarM=new r(this,u,i);t.calendarM.displaymode=this.displaymode;f=t.value;f.length>0&&(n=DStringToD(f),n.isValid()&&t.calendarM.setSelected({begin:n,end:n}));this.displaymode=="inline"&&setTimeout(function(){_currentdatecalendarcontrol[0].scrollIntoView(!0)},150)},f=function(){u&&(s$(u).removeClass("animateIn").addClass("animateOut"),setTimeout(function(){typeof t.calendarM!="undefined"&&(t.calendarM.destroy(),delete t.calendarM);u&&(this.created=!1,this.displaymode=="inline"?t.parentNode.removeChild(u):s$.navigator.liveelement.removeChild(u));u=null},500));_currentdatecalendarcontrol=null},l=function(n){var r,u;t.value=_dateToString(n.begin)+(n.begin!=n.end?i.separator+_dateToString(n.end):"");setTimeout(h,150);s$(t).fire("blur");r=s$(t).data("validate");r!==null&&(r+="(element);",u=new Function("element",r),u())};o()},n=function(){for(var t,n=1;n<arguments.length;n++)for(t in arguments[n])arguments[n].hasOwnProperty(t)&&(arguments[0][t]=arguments[n][t]);return arguments[0]},t=function(n,t){for(var u=[],e=new RegExp("(^| )"+t+"( |$)"),r=n.getElementsByTagName("*"),i=0,f=r.length;i<f;i++)e.test(r[i].className)&&u.push(r[i]);return u},h=function(n){return typeof HTMLElement=="object"?n instanceof HTMLElement:n&&typeof n=="object"&&n.nodeType===1&&typeof n.nodeName=="string"},u=function(n,t){for(var i=0;i<n.length;i++)t(n[i])},f=function(n){n.nodeType==1&&n.setAttribute("unselectable","on");for(var t=n.firstChild;t;)f(t),t=t.nextSibling},c=function(n){for(n=n.previousSibling;n&&n.nodeType!=1;)n=n.previousSibling;return n},i=function(n){for(var t=0;(n=c(n))!=null;)t++;return t},e=function(n,t){return(" "+n.className+" ").indexOf(" "+t+" ")>-1},l=function(n,t){e(n,t)||(n.className=n.className+" "+t)},o=function(n,t){if(e(n,t)){var i=new RegExp(t,"g");n.className=n.className.replace(i,"")}},a=function(){return window.pageYOffset>0?window.document.elementFromPoint(0,window.pageYOffset+window.innerHeight-1)==null:window.pageXOffset>0?window.document.elementFromPoint(window.pageXOffset+window.innerWidth-1,0)==null:!1},v=function(n,t){return a()?window.document.elementFromPoint(n-window.pageXOffset,t-window.pageYOffset):window.document.elementFromPoint(n,t)};n(window,{Calendar:r,setCalendar:s})}();_currentdatecalendarcontrol=null;_yearrange=0;s$.extend({ajaxform:function(){return this.each(function(){typeof this.ajaxform!="undefined"&&(this.ajaxform.destroy(),this.ajaxform=null);this.ajaxform=new ajaxform(this)})},unajaxform:function(){return this.each(function(){typeof this.ajaxform!="undefined"&&(this.ajaxform.destroy(),this.ajaxform=null)})},ajaxdiv:function(){return this.each(function(){typeof this.ajaxdiv!="undefined"&&(this.ajaxdiv.destroy(),this.ajaxdiv=null);this.ajaxdiv=new ajaxdiv(this)})},unajaxdiv:function(){return this.each(function(){typeof this.ajaxdiv!="undefined"&&(this.ajaxdiv.destroy(),this.ajaxdiv=null)})},iResizer:function(){return this.each(function(){typeof this.iResizer!="undefined"&&(this.iResizer.destroy(),this.iResizer=null);this.iResizer=new iResizer(this)})},uniResizer:function(){return this.each(function(){typeof this.iResizer!="undefined"&&(this.iResizer.destroy(),this.iResizer=null)})},carousel:function(){return this.each(function(){typeof this.carouselM!="undefined"&&(this.carouselM.destroy(),this.carouselM=null);this.carouselM=new Carousel(this)})},unCarousel:function(){return this.each(function(){typeof this.carouselM!="undefined"&&(this.carouselM.destroy(),this.carouselM=null)})},onMap:function(){return this.each(function(){typeof this.uimap!="undefined"&&(this.uimap.destroy(),this.uimap=null);this.uimap=new Map(this)})},unMap:function(){return this.each(function(){typeof this.uimap!="undefined"&&(this.uimap=null)})}});s$.UI=function(){var n=function(){s$("html").tbind('tap{ "capturefromchild": true }',uiTaps)};return{init:n}}();s$.extend({onControls:function(){s$("[data-geoautocomplete]",this).each(function(){this.autocomplete=new google.maps.places.Autocomplete(this)});s$("[data-ajaxform]",this).each(function(){this.style.display!=="none"&&s$(this).ajaxform()});s$("[data-ajaxpanel]",this).each(function(){this.style.display!=="none"&&s$(this).ajaxdiv()});s$("[data-iframeresize]",this).each(function(){s$(this).iResizer()});s$("[data-menudd]",this).each(function(){s$(this).tbind('tap{"capturefromchild":true}',expandMenuDD)});s$("[data-collapsible]",this).each(function(){s$(this).tbind('tap{"capturefromchild":true}',expandToggle)});Placeholders.nativeSupport||s$("input",this).each(function(){this.attributes.placeholder&&Placeholders.newElement(this)});s$("[data-fastclick]",this).each(function(){var n=s$(this).data("fastclick"),t;n!==null&&(n+="(element);",t=new Function("element",n),s$(this).tbind("tap",t))});s$("[data-geocode]",this).each(function(){s$(this).onGeoLocation()});s$("[data-map]",this).each(function(){s$(this).onMap()});s$(".radio",this).each(function(){var t=null,n=get_firstchild(this);do{if("radio"===n.type){t=n;break}n=n.nextSibling}while(n);t&&(this.className=t.checked||s$(t).data("val")==="true"?"radio on":"radio off")});s$("[data-carousel]",this).each(function(){s$(this).carousel()});s$(".datecalendar",this).each(function(){s$(this)[0].readOnly=!0})},unControls:function(){s$("[data-ajaxform]",this).each(function(){s$(this).unajaxform()});s$("[data-ajaxpanel]",this).each(function(){s$(this).unajaxdiv()});s$("[data-iframeresize]",this).each(function(){s$(this).uniResizer()});s$("[data-menudd]",this).each(function(){s$(this).tunbind("tap")});s$(".ui-collapsible-heading-toggle",this).each(function(){s$(this).tunbind("tap")});Placeholders.nativeSupport||s$("input",this).each(function(){this.attributes.placeholder});s$("[data-fastclick]",this).each(function(){s$(this).tunbind("tap")});s$("[data-geocode]",this).each(function(){s$(this).unGeoLocation()});s$("[data-map]",this).each(function(){s$(this).unMap()});s$(".radio",this).each(function(){});s$("[data-carousel]",this).each(function(){s$(this).unCarousel()});s$(".datecalendar",this).each(function(){})}});var overthrowlock=!1,touchscrolling=!1,touchBlockingSetUp=!1;Carousel.prototype.handleEvent=function(){};Carousel.prototype.destroy=function(){this.$container.data("resize")!==null&&(s$(window).unbinddirect("orientationChanged",this.resizeEvent),s$(window).unbinddirect(s$.browser.events.resize,this.resizeEvent));typeof this.scroller!="undefined"&&this.$container.data("touch")===null&&(this.typeSpin?this.$container.tunbind("swipe"):this.$scroller.tunbind("swipe"));this.prev&&s$(this.prev).tunbind("tap");this.next&&s$(this.next).tunbind("tap");clearInterval(this.bigflickinter);clearTimeout(this.timeoutauto);clearTimeout(this.timeoutMomentum);delete this.slider};Slide.prototype.fullRefresh=function(){var n,t,i;for(this.items=s$("[data-item]",this.elementcontainer).filter(function(){return this.style.display!="none"}),this.panelCount=this.items.length,this.isHorizontal=!0,this.panelSize=this.elementcontainer.offsetWidth,this.step=this.vertical?this.elementcontainer.offsetHeight:this.panelSize,(this.panelSize===0||typeof this.panelSize=="undefined")&&(this.panelSize=320),this.element.style.width=this.panelCount*this.step+"px",t=0;t<this.panelCount;t++)n=this.items[t],n.positionindex=t,i=s$(n).data("position"),i&&(n.positionindex=parseInt(i)),n.style.display="inline-block",n.style.width=this.panelSize+"px",this.vertical?n.style.top=n.positionindex*this.step+"px":(n.style.top="0px",n.style.left=n.positionindex*this.step+"px"),n.style.position=n.positionindex===0?"relative":"absolute"};Slide.prototype.refresh=function(n){var i,t;if(this.doneRA=!1,typeof n=="undefined"&&(n=0),this.infinite)for(i=0;i<this.panelCount;i++)t=this.items[i],t.style.left=n==1&&t.positionindex===0?this.panelCount*this.step+"px":n==-1&&t.positionindex===this.panelCount-1?-1*this.step+"px":t.positionindex*this.step+"px",t.style.position=t.positionindex===0?"relative":"absolute";this.wrap=n};Slide.prototype.setX=function(n){var t=this;n<t.maxOffset?(n=t.maxOffset,t.elementcontainer.carouselM.speed=0):n>t.minOffset&&(n=t.minOffset,t.elementcontainer.carouselM.speed=0);t.sliderxReal=n;this.multi&&(t.sliderxReal=t.sliderxReal+(this.panelSize/2-this.panelSize/2));t.sliderx=n;t.nextFrame()};Slide.prototype.updateIndex=function(n){var t=this,i;t.nextFrame();i=0;t.infinite&&(n==0&&(i=-1),n==t.panelCount-1&&(i=1),t.refresh(i))};Slide.prototype.nextFrame=function(){this.vertical?this.use3d?s$(this.element).style(s$.browser.css.transform,"translate3d(0px,"+this.sliderxReal+"px, 0px)"):this.element.style.top=this.sliderxReal+"px":this.use3d?s$(this.element).style(s$.browser.css.transform,"translate3d("+this.sliderxReal+"px, 0px, 0px)"):this.useTranslate?s$(this.element).style(s$.browser.css.transform,"translateX("+this.sliderxReal+"px)"):this.element.style.left=this.sliderxReal+"px";this.doneRA=!1};Slide.prototype.getX=function(){return this.sliderx};Slide.prototype.getCurrentX=function(){if(this.elementcontainer.carouselM.momentumJS)return this.sliderx;var t=0,n;return this.use3d?(n=window.getComputedStyle(this.element,null)[s$.browser.css.transform].replace(/[^0-9-.,]/g,"").split(","),t=+(n[12]||n[4])):this.useTranslate?(n=window.getComputedStyle(this.element,null)[s$.browser.css.transform].replace(/[^0-9-.,]/g,"").split(","),t=+(n[12]||n[4])):t=window.getComputedStyle(this.element,null).left.replace(/[^0-9-]/g,"")*1,t};Stack.prototype.fullRefresh=function(){var n,t,i;for(this.items=s$("[data-item]",this.elementcontainer).filter(function(){return this.style.display!="none"}),this.panelCount=this.items.length,this.isHorizontal=!0,this.panelSize=this.elementcontainer.offsetWidth,this.step=this.vertical?this.elementcontainer.offsetHeight:this.panelSize,(this.panelSize===0||typeof this.panelSize=="undefined")&&(this.panelSize=320),this.element.style.width=this.panelCount*this.step+"px",t=0;t<this.panelCount;t++)n=this.items[t],n.positionindex=t,i=s$(n).data("position"),i&&(n.positionindex=parseInt(i)),n.style.display="inline-block",n.style.width=this.panelSize+"px",n.style.left="0px",n.style.position=n.positionindex===0?"relative":"absolute",t==this.updateIndexNow?this.firstupdate!==!1&&(n.style.visibility="visible"):n.style.visibility="hidden"};Stack.prototype.refresh=function(){};Stack.prototype.setX=function(){};Stack.prototype.updateIndex=function(n){if(this.updateIndexNow=n,this.firstupdate!==!1){for(i=0;i<this.panelCount;i++)panel=this.items[i],i==n&&(panel.style.visibility="visible");setTimeout(function(){for(i=0;i<this.panelCount;i++)panel=this.items[i],panel.style.visibility=i==n?"visible":"hidden"},500)}this.firstupdate=!0};Stack.prototype.nextFrame=function(){this.doneRA=!1};Stack.prototype.getX=function(){return 0};Stack.prototype.getCurrentX=function(){return 0};Spin.prototype.fullRefresh=function(){this.refresh()};Spin.prototype.refresh=function(){var n,i,t;for(console.log("Spin.prototype.refresh"),this.items=s$("[data-item]",this.elementcontainer).filter(function(){return this.style.display!="none"}),this.panelCount=this.items.length,this.isHorizontal=!0,this.panelSize=this.elementcontainer.offsetWidth,this.step=this.vertical?this.elementcontainer.offsetHeight:this.panelSize,(this.panelSize===0||typeof this.panelSize=="undefined")&&(this.panelSize=320),this.element.style.width=this.panelCount*this.step+"px",this.doneRA=!1,this.element.parentNode.style["-webkit-perspective"]="1200px",this.element.parentNode.style.perspective="1200px",this.element.style["-webkit-transform-style"]="preserve-3d",this.element.style["transform-style"]="preserve-3d",this.element.style["-webkit-transform-origin"]="50% 50%",this.element.style["transform-origin"]="50% 50%",this.element.style.width=this.panelSize+"px",s$(this.element).style(s$.browser.css.transitionDuration,"0ms"),s$(this.element).style(s$.browser.css.transitionProperty,"all"),s$(this.element).style(s$.browser.css.transitionTimingFunction,"ease-in-out"),this.rotation=0,this.theta=0,this.rotateFn=this.isHorizontal?"rotateY":"rotateX",this.theta=360/this.panelCount,this.radius=Math.round(this.panelSize/2/Math.tan(Math.PI/this.panelCount)),t=0;t<this.panelCount;t++)n=this.items[t],i=this.theta*t,n.style.opacity=1,n.style.top="0px",n.style.display="block",n.style.position="absolute",n.style.width=this.panelSize+"px",n.style["-webkit-backface-visibility"]="hidden",t==0&&(n.style.position="relative"),n.setAttribute("disabled","disabled"),s$(n).style(s$.browser.css.transform,this.rotateFn+"("+i+"deg) translateZ("+this.radius+"px)");this.rotation=Math.round(this.rotation/this.theta)*this.theta;this.setX(0)};Spin.prototype.setX=function(n){var t=this;this.movex=n;this.rotation=n/(this.panelSize*this.panelCount)*360;requestAnimationFrame(function(){t.nextFrame()})};Spin.prototype.getX=function(){return this.movex};Spin.prototype.getCurrentX=function(){return this.movex};Spin.prototype.updateIndex=function(n){var t=this;requestAnimationFrame(function(){t.nextFrame();var i=0;t.infinite&&(n==0&&(i=-1),n==t.panelCount-1&&(i=1),t.refresh(i))})};Spin.prototype.nextFrame=function(){s$(this.element).style(s$.browser.css.transform,"translateZ(-"+this.radius+"px) "+this.rotateFn+"("+this.rotation+"deg)");this.doneRA=!1};iResizer.prototype.destroy=function(){window.addEventListener?removeEventListener("message",this.listener):detachEvent("onmessage",this.listener)};ajaxdiv.prototype.destroy=function(){},function(n,t){function l(n,t,i){return(n+(t-n)*i).toFixed(3)}function i(n,t,i){return n.substr(t,i||1)}function a(n,t,r){for(var s=2,f,u,o,e=[],h=[];f=3,u=arguments[s-1],s--;)if(i(u,0)=="r")for(u=u.match(/\d+/g);f--;)e.push(~~u[f]);else for(u.length==4&&(u="#"+i(u,1)+i(u,1)+i(u,2)+i(u,2)+i(u,3)+i(u,3));f--;)e.push(parseInt(i(u,1+f*2,2),16));while(f--)o=~~(e[f+3]+(e[f]-e[f+3])*r),h.push(o<0?0:o>255?255:o);return"rgb("+h.join(",")+")"}function s(n){var t=parseFloat(n),i=n.replace(/^[\-\d\.]+/,"");return isNaN(t)?{v:i,f:a,u:""}:{v:t,f:l,u:i}}function v(n){var i,f={},t=u.length,e;for(r.innerHTML='<div style="'+n+'"><\/div>',i=r.childNodes[0].style;t--;)(e=i[u[t]])&&(f[u[t]]=s(e));return f}var r=document.createElement("div"),u="backgroundColor borderBottomColor borderBottomWidth borderLeftColor borderLeftWidth borderRightColor borderRightWidth borderSpacing borderTopColor borderTopWidth bottom color fontSize fontWeight height left letterSpacing lineHeight marginBottom marginLeft marginRight marginTop maxHeight maxWidth minHeight minWidth opacity outlineColor outlineOffset outlineWidth paddingBottom paddingLeft paddingRight paddingTop right textIndent top width wordSpacing zIndex".split(" "),h=typeof r.style.opacity=="string",c=typeof r.style.filter=="string",f=/alpha\(opacity=([^\)]+)\)/,e=function(){},o=function(){return"1"};h?(e=function(n,t){n.style.opacity=t},o=function(n){return n.opacity}):c&&(e=function(n,t){var i=n.style;f.test(i.filter)?(t=t>=.9999?"":"alpha(opacity="+t*100+")",i.filter=i.filter.replace(f,t)):i.filter+=" alpha(opacity="+t*100+")"},o=function(n){var t=n.filter.match(f);return(t?t[1]/100:1)+""});t[n]=function(n,t,i){n=typeof n=="string"?document.getElementById(n):n;i=i||{};var u=v(t),h=n.currentStyle?n.currentStyle:getComputedStyle(n,null),r,c={},l=+new Date,a=i.duration||200,y=l+a,p,w=i.easing||function(n){return-Math.cos(n*Math.PI)/2+.5},f;for(r in u)c[r]=s(r==="opacity"?o(h):h[r]);p=setInterval(function(){var t=+new Date,o=t>y?1:(t-l)/a;for(r in u)f=u[r].f(c[r].v,u[r].v,w(o))+u[r].u,r==="opacity"?e(n,f):n.style[r]=f;t>y&&(clearInterval(p),i.after&&i.after())},10)}}("emile",this);ajaxform.prototype.destroy=function(){},function(n,t){var i=n.document,r=i.documentElement,h="overthrow-enabled",u="ontouchmove"in i,f="WebkitOverflowScrolling"in r.style||!u&&n.screen.width>1200||function(){var t=n.navigator.userAgent,i=t.match(/AppleWebKit\/([0-9]+)/),u=i&&i[1],r=i&&u>=534;return t.match(/Android ([0-9]+)/)&&RegExp.$1>=3&&r||t.match(/ Version\/([0-9]+)/)&&RegExp.$1>=0&&n.blackberry&&r||t.indexOf(/PlayBook/)>-1&&RegExp.$1>=0&&r||t.match(/Fennec\/([0-9]+)/)&&RegExp.$1>=4||t.match(/wOSBrowser\/([0-9]+)/)&&RegExp.$1>=233&&r||t.match(/NokiaBrowser\/([0-9\.]+)/)&&parseFloat(RegExp.$1)===7.3&&i&&u>=533}(),c=function(n,t,i,r){return i*((n=n/r-1)*n*n+1)+t},e=!1,l,a=function(i,r){var h=0,c=i.scrollLeft,a=i.scrollTop,u={top:"+0",left:"+0",duration:100,easing:n.overthrow.easing},f,e,o;if(r)for(o in u)r[o]!==t&&(u[o]=r[o]);return typeof u.left=="string"?(u.left=parseFloat(u.left),f=u.left+c):(f=u.left,u.left=u.left-c),typeof u.top=="string"?(u.top=parseFloat(u.top),e=u.top+a):(e=u.top,u.top=u.top-a),l=setInterval(function(){h++<u.duration?(i.scrollLeft=u.easing(h,c,u.left,u.duration),i.scrollTop=u.easing(h,a,u.top,u.duration)):(f!==i.scrollLeft&&(i.scrollLeft=f),e!==i.scrollTop&&(i.scrollTop=e),s())},1),{top:e,left:f,duration:u.duration,easing:u.easing}},o=function(n,t){return!t&&n.className&&n.className.indexOf("overthrow")>-1&&n||o(n.parentNode)},s=function(){clearInterval(l)},v=function(){if(!e&&(e=!0,(f||u)&&(r.className+=" "+h),n.overthrow.forget=function(){r.className=r.className.replace(h,"");i.removeEventListener&&i.removeEventListener("touchstart",d,!1);n.overthrow.easing=c;e=!1},!f&&u)){var t,l=[],v=[],y,p,b=function(){l=[];y=null},k=function(){v=[];p=null},g=function(){var n=(l[0]-l[l.length-1])*8,i=(v[0]-v[v.length-1])*8,r=Math.max(Math.abs(i),Math.abs(n))/8;n=(n>0?"+":"")+n;i=(i>0?"+":"")+i;!isNaN(r)&&r>0&&(Math.abs(i)>80||Math.abs(n)>80)&&a(t,{left:i,top:n,duration:r})},w=function(){},nt=function(){},d=function(n){if(s(),b(),k(),t=o(n.target),t&&t!==r&&!(n.touches.length>1)){w("none");var f=n,e=t.scrollTop,h=t.scrollLeft,c=t.offsetHeight,a=t.offsetWidth,d=n.touches[0].pageY,tt=n.touches[0].pageX,it=t.scrollHeight,rt=t.scrollWidth,i=function(n){var i=e+d-n.touches[0].pageY,r=h+tt-n.touches[0].pageX,u=i>=(l.length?l[0]:0),o=r>=(v.length?v[0]:0);i>0&&i<it-c||r>0&&r<rt-a?n.preventDefault():nt(f);y&&u!==y&&b();p&&o!==p&&k();y=u;p=o;t.scrollTop=i;t.scrollLeft=r;l.unshift(i);v.unshift(r);l.length>3&&l.pop();v.length>3&&v.pop()},u=function(){g();w("auto");setTimeout(function(){w("none")},450);t.removeEventListener("touchmove",i,!1);t.removeEventListener("touchend",u,!1)};t.addEventListener("touchmove",i,!1);t.addEventListener("touchend",u,!1)}};i.addEventListener("touchstart",d,!1)}};n.overthrow={set:v,forget:function(){},easing:c,toss:a,intercept:s,closest:o,support:f?"native":u&&"polyfilled"||"none"};v()}(this);gchangescreenlock=!1,function(n){"use strict";function t(n,t,i){return n.addEventListener?n.addEventListener(t,i,!1):n.attachEvent?n.attachEvent("on"+t,i):void 0}function i(n,t){for(var i=0,r=n.length;i<r;i++)if(n[i]===t)return!0;return!1}function r(n,t){var i;n.createTextRange?(i=n.createTextRange(),i.move("character",t),i.select()):n.selectionStart&&(n.focus(),n.setSelectionRange(t,t))}function u(n,t){try{return n.type=t,!0}catch(i){return!1}}n.Placeholders={Utils:{addEventListener:t,inArray:i,moveCaret:r,changeType:u}}}(this),function(n){"use strict";function s(){}function y(n){var t;return n.value===n.attributes.placeholder.value&&n.getAttribute(u)==="true"?(n.setAttribute(u,"false"),n.value="",n.className=n.className.replace(l,""),t=n.getAttribute(f),t&&(n.type=t),!0):!1}function h(n){var i,r=n.attributes.placeholder.value;return n.value===""&&r?(n.setAttribute(u,"true"),n.value=r,n.className+=" "+c,i=n.getAttribute(f),i?n.type="text":n.type==="password"&&t.changeType(n,"text")&&n.setAttribute(f,"password"),!0):!1}function p(n,t){var r,u,f,o,i;if(n&&n.getAttribute(e))t(n);else for(r=n?n.getElementsByTagName("input"):g,u=n?n.getElementsByTagName("textarea"):nt,i=0,o=r.length+u.length;i<o;i++)f=i<r.length?r[i]:u[i-r.length],t(f)}function w(n){p(n,y)}function it(n){p(n,h)}function rt(n){return function(){v&&n.value===n.attributes.placeholder.value&&n.getAttribute(u)==="true"?t.moveCaret(n,0):y(n)}}function ut(n){return function(){h(n)}}function ft(n){return function(i){return o=n.value,n.getAttribute(u)==="true"&&o===n.getAttribute(e)&&t.inArray(d,i.keyCode)?(i.preventDefault&&i.preventDefault(),!1):void 0}}function et(n){return function(){var i;n.getAttribute(u)==="true"&&n.value!==o&&(n.className=n.className.replace(l,""),n.value=n.value.replace(n.getAttribute(e),""),n.setAttribute(u,!1),i=n.getAttribute(f),i&&(n.type=i));n.value===""&&(n.blur(),t.moveCaret(n,0))}}function ot(n){return function(){n===document.activeElement&&n.value===n.attributes.placeholder.value&&n.getAttribute(u)==="true"&&t.moveCaret(n,0)}}function b(n){i.nativeSupport||(t.addEventListener(n,"focus",rt(n)),t.addEventListener(n,"blur",ut(n)),v&&(t.addEventListener(n,"keydown",ft(n)),t.addEventListener(n,"keyup",et(n)),t.addEventListener(n,"click",ot(n))),n.setAttribute(a,"true"),n.setAttribute(e,r),h(n))}var k=["text","search","url","tel","email","password","number","textarea"],d=[27,33,34,35,36,37,38,39,40,8,46],c="placeholdersjs",l=new RegExp("(?:^|\\s)"+c+"(?!\\S)"),g,nt,e="data-placeholder-value",u="data-placeholder-active",f="data-placeholder-type",a="data-placeholder-bound",tt=document.createElement("input"),st=document.getElementsByTagName("head")[0],ht=document.documentElement,i=n.Placeholders,t=i.Utils,v,o,r;i.nativeSupport=tt.placeholder!==void 0;i.disable=i.nativeSupport?s:w;i.enable=i.nativeSupport?s:it;i.newElement=i.nativeSupport?s:b}(this)