var requirejs,require,define;!function(global){function isFunction(e){return"[object Function]"===ostring.call(e)}function isArray(e){return"[object Array]"===ostring.call(e)}function each(e,t){if(e)for(var n=0;n").css("cssText","display:block !important")).appendTo(o.documentElement))[0].contentWindow||We[0].contentDocument).document).write("
"),o.close(),s=D(a,o),We.detach()),Be[a]=s),s)))):l[u]||(i=b(r),(n&&"none"!==n||!i)&&he.set(r,"olddisplay",i?n:ge.css(r,"display"))));for(u=0;u)[^>]*|#([\w-]*))$/,te=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,ne=/^-ms-/,re=/-([\da-z])/gi,ie=function(){j.removeEventListener("DOMContentLoaded",ie,!1),p.removeEventListener("load",ie,!1),ge.ready()};ge.fn=ge.prototype={jquery:V,constructor:ge,init:function(e,t,n){var r,i;if(!e)return this;if("string"!=typeof e)return e.nodeType?(this.context=this[0]=e,this.length=1,this):ge.isFunction(e)?n.ready(e):(e.selector!==k&&(this.selector=e.selector,this.context=e.context),ge.makeArray(e,this));if(!(r="<"===e.charAt(0)&&">"===e.charAt(e.length-1)&&3<=e.length?[null,e,null]:ee.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof ge?t[0]:t,ge.merge(this,ge.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:j,!0)),te.test(r[1])&&ge.isPlainObject(t))for(r in t)ge.isFunction(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=j.getElementById(r[2]))&&i.parentNode&&(this.length=1,this[0]=i),this.context=j,this.selector=e,this},selector:"",length:0,toArray:function(){return G.call(this)},get:function(e){return null==e?this.toArray():e<0?this[this.length+e]:this[e]},pushStack:function(e){var t=ge.merge(this.constructor(),e);return t.prevObject=this,t.context=this.context,t},each:function(e,t){return ge.each(this,e,t)},ready:function(e){return ge.ready.promise().done(e),this},slice:function(){return this.pushStack(G.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n_.cacheLength&&delete n[r.shift()],n[e]=t}var r=[];return n}function f(e){return e[O]=!0,e}function r(e){var t=S.createElement("div");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function t(e,t){for(var n=e.split("|"),r=e.length;r--;)_.attrHandle[n[r]]=t}function u(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&(~t.sourceIndex||1<<31)-(~e.sourceIndex||1<<31);if(r)return r;if(n)for(;n=n.nextSibling;)if(n===t)return-1;return e?1:-1}function a(o){return f(function(a){return a=+a,f(function(e,t){for(var n,r=o([],e.length,a),i=r.length;i--;)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function o(){}function p(e,t){var n,r,i,a,o,s,l,u=N[e+" "];if(u)return t?0:u.slice(0);for(o=e,s=[],l=_.preFilter;o;){for(a in n&&!(r=ne.exec(o))||(r&&(o=o.slice(r[0].length)||o),s.push(i=[])),n=!1,(r=re.exec(o))&&(n=r.shift(),i.push({value:n,type:r[0].replace(te," ")}),o=o.slice(n.length)),_.filter)!(r=le[a].exec(o))||l[a]&&!(r=l[a](r))||(n=r.shift(),i.push({value:n,type:a,matches:r}),o=o.slice(n.length));if(!n)break}return t?o.length:o?x.error(e):N(e,s).slice(0)}function m(e){for(var t=0,n=e.length,r="";t+~]|"+Z+")"+Z+"*"),ie=new RegExp(Z+"*[+~]"),ae=new RegExp("="+Z+"*([^\\]'\"]*)"+Z+"*\\]","g"),oe=new RegExp(ee),se=new RegExp("^"+Q+"$"),le={ID:new RegExp("^#("+J+")"),CLASS:new RegExp("^\\.("+J+")"),TAG:new RegExp("^("+J.replace("w","w*")+")"),ATTR:new RegExp("^"+K),PSEUDO:new RegExp("^"+ee),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+Z+"*(even|odd|(([+-]|)(\\d*)n|)"+Z+"*(?:([+-]|)"+Z+"*(\\d+)|))"+Z+"*\\)|)","i"),bool:new RegExp("^(?:"+X+")$","i"),needsContext:new RegExp("^"+Z+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+Z+"*((?:-\\d)?\\d*)"+Z+"*\\)|)(?=[^-]|$)","i")},ue=/^[^{]+\{\s*\[native \w/,ce=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,de=/^(?:input|select|textarea|button)$/i,fe=/^h\d$/i,he=/'|\\/g,pe=new RegExp("\\\\([\\da-f]{1,6}"+Z+"?|("+Z+")|.)","ig"),me=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(65536+r):String.fromCharCode(r>>10|55296,1023&r|56320)};try{B.apply(H=G.call(I.childNodes),I.childNodes),H[I.childNodes.length].nodeType}catch(e){B={apply:H.length?function(e,t){U.apply(e,G.call(t))}:function(e,t){for(var n=e.length,r=0;e[n++]=t[r++];);e.length=n-1}}}for(s in c=x.isXML=function(e){var t=e&&(e.ownerDocument||e).documentElement;return!!t&&"HTML"!==t.nodeName},g=x.support={},y=x.setDocument=function(e){var l=e?e.ownerDocument||e:I,t=l.defaultView;return l!==S&&9===l.nodeType&&l.documentElement?(b=(S=l).documentElement,w=!c(l),t&&t.attachEvent&&t!==t.top&&t.attachEvent("onbeforeunload",function(){y()}),g.attributes=r(function(e){return e.className="i",!e.getAttribute("className")}),g.getElementsByTagName=r(function(e){return e.appendChild(l.createComment("")),!e.getElementsByTagName("*").length}),g.getElementsByClassName=r(function(e){return e.innerHTML="",e.firstChild.className="i",2===e.getElementsByClassName("i").length}),g.getById=r(function(e){return b.appendChild(e).id=O,!l.getElementsByName||!l.getElementsByName(O).length}),g.getById?(_.find.ID=function(e,t){if(typeof t.getElementById!=q&&w){var n=t.getElementById(e);return n&&n.parentNode?[n]:[]}},_.filter.ID=function(e){var t=e.replace(pe,me);return function(e){return e.getAttribute("id")===t}}):(delete _.find.ID,_.filter.ID=function(e){var n=e.replace(pe,me);return function(e){var t=typeof e.getAttributeNode!=q&&e.getAttributeNode("id");return t&&t.value===n}}),_.find.TAG=g.getElementsByTagName?function(e,t){if(typeof t.getElementsByTagName!=q)return t.getElementsByTagName(e)}:function(e,t){var n,r=[],i=0,a=t.getElementsByTagName(e);if("*"!==e)return a;for(;n=a[i++];)1===n.nodeType&&r.push(n);return r},_.find.CLASS=g.getElementsByClassName&&function(e,t){if(typeof t.getElementsByClassName!=q&&w)return t.getElementsByClassName(e)},M=[],T=[],(g.qsa=ue.test(l.querySelectorAll))&&(r(function(e){e.innerHTML="",e.querySelectorAll("[selected]").length||T.push("\\["+Z+"*(?:value|"+X+")"),e.querySelectorAll(":checked").length||T.push(":checked")}),r(function(e){var t=l.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("t",""),e.querySelectorAll("[t^='']").length&&T.push("[*^$]="+Z+"*(?:''|\"\")"),e.querySelectorAll(":enabled").length||T.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),T.push(",.*:")})),(g.matchesSelector=ue.test(E=b.webkitMatchesSelector||b.mozMatchesSelector||b.oMatchesSelector||b.msMatchesSelector))&&r(function(e){g.disconnectedMatch=E.call(e,"div"),E.call(e,"[s!='']:x"),M.push("!=",ee)}),T=T.length&&new RegExp(T.join("|")),M=M.length&&new RegExp(M.join("|")),A=ue.test(b.contains)||b.compareDocumentPosition?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!!r&&1===r.nodeType&&!!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r))}:function(e,t){if(t)for(;t=t.parentNode;)if(t===e)return!0;return!1},W=b.compareDocumentPosition?function(e,t){if(e===t)return L=!0,0;var n=t.compareDocumentPosition&&e.compareDocumentPosition&&e.compareDocumentPosition(t);return n?1&n||!g.sortDetached&&t.compareDocumentPosition(e)===n?e===l||A(I,e)?-1:t===l||A(I,t)?1:d?z.call(d,e)-z.call(d,t):0:4&n?-1:1:e.compareDocumentPosition?-1:1}:function(e,t){var n,r=0,i=e.parentNode,a=t.parentNode,o=[e],s=[t];if(e===t)return L=!0,0;if(!i||!a)return e===l?-1:t===l?1:i?-1:a?1:d?z.call(d,e)-z.call(d,t):0;if(i===a)return u(e,t);for(n=e;n=n.parentNode;)o.unshift(n);for(n=t;n=n.parentNode;)s.unshift(n);for(;o[r]===s[r];)r++;return r?u(o[r],s[r]):o[r]===I?-1:s[r]===I?1:0},l):S},x.matches=function(e,t){return x(e,null,null,t)},x.matchesSelector=function(e,t){if((e.ownerDocument||e)!==S&&y(e),t=t.replace(ae,"='$1']"),g.matchesSelector&&w&&(!M||!M.test(t))&&(!T||!T.test(t)))try{var n=E.call(e,t);if(n||g.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(pe,me),e[3]=(e[4]||e[5]||"").replace(pe,me),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||x.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&x.error(e[0]),e},PSEUDO:function(e){var t,n=!e[5]&&e[2];return le.CHILD.test(e[0])?null:(e[3]&&e[4]!==i?e[2]=e[4]:n&&oe.test(n)&&(t=p(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(pe,me).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=R[e+" "];return t||(t=new RegExp("(^|"+Z+")"+e+"("+Z+"|$)"))&&R(e,function(e){return t.test("string"==typeof e.className&&e.className||typeof e.getAttribute!=q&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=x.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1]*)\/>/gi,Ee=/<([\w:]+)/,Ae=/<|?\w+;/,Oe=/<(?:script|style|link)/i,Ie=/^(?:checkbox|radio)$/i,Fe=/checked\s*(?:[^=]|=\s*.checked.)/i,Pe=/^$|\/(?:java|ecma)script/i,Re=/^true\/(.*)/,Ne=/^\s*\s*$/g,je={option:[1,""],thead:[1,""],col:[2,""],tr:[2,""],td:[3,""],_default:[0,"",""]};je.optgroup=je.option,je.tbody=je.tfoot=je.colgroup=je.caption=je.thead,je.th=je.td,ge.fn.extend({text:function(e){return ge.access(this,function(e){return e===k?ge.text(this):this.empty().append((this[0]&&this[0].ownerDocument||j).createTextNode(e))},null,e,arguments.length)},append:function(){return this.domManip(arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||i(this,e).appendChild(e)})},prepend:function(){return this.domManip(arguments,function(e){var t;1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(t=i(this,e)).insertBefore(e,t.firstChild)})},before:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return this.domManip(arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},remove:function(e,t){for(var n,r=e?ge.filter(e,this):this,i=0;null!=(n=r[i]);i++)t||1!==n.nodeType||ge.cleanData(y(n)),n.parentNode&&(t&&ge.contains(n.ownerDocument,n)&&v(y(n,"script")),n.parentNode.removeChild(n));return this},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(ge.cleanData(y(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return ge.clone(this,e,t)})},html:function(e){return ge.access(this,function(e){var t=this[0]||{},n=0,r=this.length;if(e===k&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Oe.test(e)&&!je[(Ee.exec(e)||["",""])[1].toLowerCase()]){e=e.replace(Me,"<$1>$2>");try{for(;n$2>")+s[2],u=s[0];u--;)a=a.lastChild;ge.merge(h,a.childNodes),(a=f.firstChild).textContent=""}else h.push(t.createTextNode(i));for(f.textContent="",c=0;i=h[c++];)if((!r||-1===ge.inArray(i,r))&&(l=ge.contains(i.ownerDocument,i),a=y(f.appendChild(i),"script"),l&&v(a),n))for(u=0;i=a[u++];)Pe.test(i.type||"")&&n.push(i);return f},cleanData:function(e){for(var t,n,r,i,a,o,s=ge.event.special,l=0;(n=e[l])!==k;l++){if(u.accepts(n)&&(a=n[he.expando])&&(t=he.cache[a])){if((r=Object.keys(t.events||{})).length)for(o=0;(i=r[o])!==k;o++)s[i]?ge.event.remove(n,i):ge.removeEvent(n,i,t.handle);he.cache[a]&&delete he.cache[a]}delete fe.cache[n[fe.expando]]}},_evalUrl:function(e){return ge.ajax({url:e,type:"GET",dataType:"script",async:!1,global:!1,throws:!0})}}),ge.fn.extend({wrapAll:function(t){var e;return ge.isFunction(t)?this.each(function(e){ge(this).wrapAll(t.call(this,e))}):(this[0]&&(e=ge(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var e=this;e.firstElementChild;)e=e.firstElementChild;return e}).append(this)),this)},wrapInner:function(n){return ge.isFunction(n)?this.each(function(e){ge(this).wrapInner(n.call(this,e))}):this.each(function(){var e=ge(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=ge.isFunction(t);return this.each(function(e){ge(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(){return this.parent().each(function(){ge.nodeName(this,"body")||ge(this).replaceWith(this.childNodes)}).end()}});var Le,We,qe=/^(none|table(?!-c[ea]).+)/,Ye=/^margin/,He=new RegExp("^("+Q+")(.*)$","i"),Ve=new RegExp("^("+Q+")(?!px)[a-z%]+$","i"),Ue=new RegExp("^([+-])=("+Q+")","i"),Be={BODY:"block"},Ge={position:"absolute",visibility:"hidden",display:"block"},ze={letterSpacing:0,fontWeight:400},Xe=["Top","Right","Bottom","Left"],Ze=["Webkit","O","Moz","ms"];ge.fn.extend({css:function(e,t){return ge.access(this,function(e,t,n){var r,i,a={},o=0;if(ge.isArray(t)){for(r=h(e),i=t.length;o").append(ge.parseHTML(e)).find(r):e)}).complete(n&&function(e,t){o.each(n,a||[e.responseText,t,e])}),this},ge.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){ge.fn[t]=function(e){return this.on(t,e)}}),ge.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:rt,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(nt[1]),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":mt,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/xml/,html:/html/,json:/json/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":ge.parseJSON,"text xml":ge.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$($(e,ge.ajaxSettings),t):$(ge.ajaxSettings,e)},ajaxPrefilter:C(ht),ajaxTransport:C(pt),ajax:function(e,t){function n(e,t,n,r){var i,a,o,s,l,u=t;2!==x&&(x=2,h&&clearTimeout(h),c=k,f=r||"",D.readyState=0").prop({async:!0,charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),j.head.appendChild(r[0])},abort:function(){i&&i()}}});var gt=[],vt=/(=)\?(?=&|$)|\?\?/;ge.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=gt.pop()||ge.expando+"_"+it++;return this[e]=!0,e}}),ge.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,a,o=!1!==e.jsonp&&(vt.test(e.url)?"url":"string"==typeof e.data&&!(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&vt.test(e.data)&&"data");if(o||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=ge.isFunction(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,o?e[o]=e[o].replace(vt,"$1"+r):!1!==e.jsonp&&(e.url+=(at.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return a||ge.error(r+" was not called"),a[0]},e.dataTypes[0]="json",i=p[r],p[r]=function(){a=arguments},n.always(function(){p[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,gt.push(r)),a&&ge.isFunction(i)&&i(a[0]),a=i=k}),"script"}),ge.ajaxSettings.xhr=function(){try{return new XMLHttpRequest}catch(e){}};var yt=ge.ajaxSettings.xhr(),bt={0:200,1223:204},wt=0,xt={};p.ActiveXObject&&ge(p).on("unload",function(){for(var e in xt)xt[e]();xt=k}),ge.support.cors=!!yt&&"withCredentials"in yt,ge.support.ajax=yt=!!yt,ge.ajaxTransport(function(a){var o;if(ge.support.cors||yt&&!a.crossDomain)return{send:function(e,t){var n,r,i=a.xhr();if(i.open(a.type,a.url,a.async,a.username,a.password),a.xhrFields)for(n in a.xhrFields)i[n]=a.xhrFields[n];for(n in a.mimeType&&i.overrideMimeType&&i.overrideMimeType(a.mimeType),a.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)i.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(delete xt[r],o=i.onload=i.onerror=null,"abort"===e?i.abort():"error"===e?t(i.status||404,i.statusText):t(bt[i.status]||i.status,i.statusText,"string"==typeof i.responseText?{text:i.responseText}:k,i.getAllResponseHeaders()))}},i.onload=o(),i.onerror=o("error"),o=xt[r=wt++]=o("abort"),i.send(a.hasContent&&a.data||null)},abort:function(){o&&o()}}});var Dt,kt,Ct=/^(?:toggle|show|hide)$/,_t=new RegExp("^(?:([+-])=|)("+Q+")([a-z%]*)$","i"),$t=/queueHooks$/,St=[function(t,e,n){var r,i,a,o,s,l,u=this,c={},d=t.style,f=t.nodeType&&b(t),h=he.get(t,"fxshow");for(r in n.queue||(null==(s=ge._queueHooks(t,"fx")).unqueued&&(s.unqueued=0,l=s.empty.fire,s.empty.fire=function(){s.unqueued||l()}),s.unqueued++,u.always(function(){u.always(function(){s.unqueued--,ge.queue(t,"fx").length||s.empty.fire()})})),1===t.nodeType&&("height"in e||"width"in e)&&(n.overflow=[d.overflow,d.overflowX,d.overflowY],"inline"===ge.css(t,"display")&&"none"===ge.css(t,"float")&&(d.display="inline-block")),n.overflow&&(d.overflow="hidden",u.always(function(){d.overflow=n.overflow[0],d.overflowX=n.overflow[1],d.overflowY=n.overflow[2]})),e)if(i=e[r],Ct.exec(i)){if(delete e[r],a=a||"toggle"===i,i===(f?"hide":"show")){if("show"!==i||!h||h[r]===k)continue;f=!0}c[r]=h&&h[r]||ge.style(t,r)}if(!ge.isEmptyObject(c))for(r in h?"hidden"in h&&(f=h.hidden):h=he.access(t,"fxshow",{}),a&&(h.hidden=!f),f?ge(t).show():u.done(function(){ge(t).hide()}),u.done(function(){for(var e in he.remove(t,"fxshow"),c)ge.style(t,e,c[e])}),c)o=T(f?h[r]:0,r,u),r in h||(h[r]=o.start,f&&(o.end=o.start,o.start="width"===r||"height"===r?1:0))}],Tt={"*":[function(e,t){var n=this.createTween(e,t),r=n.cur(),i=_t.exec(t),a=i&&i[3]||(ge.cssNumber[e]?"":"px"),o=(ge.cssNumber[e]||"px"!==a&&+r)&&_t.exec(ge.css(n.elem,e)),s=1,l=20;if(o&&o[3]!==a)for(a=a||o[3],i=i||[],o=+r||1;o/=s=s||".5",ge.style(n.elem,e,o+a),s!==(s=n.cur()/r)&&1!==s&&--l;);return i&&(o=n.start=+o||+r||0,n.unit=a,n.end=i[1]?o+(i[1]+1)*i[2]:+i[2]),n}]};ge.Animation=ge.extend(M,{tweener:function(e,t){for(var n,r=0,i=(e=ge.isFunction(e)?(t=e,["*"]):e.split(" ")).length;r>16,e>>8&255,255&e]:(","===e.charAt(e.length-1)&&(e=e.substr(0,e.length-1)),ue[e]?ue[e]:"#"===e.charAt(0)?(4===e.length&&(e="#"+(t=e.charAt(1))+t+(n=e.charAt(2))+n+(r=e.charAt(3))+r),[(e=parseInt(e.substr(1),16))>>16,e>>8&255,255&e]):("hsl"===e.substr(0,3)?(e=e.match(I),i=Number(e[0])%360/360,a=Number(e[1])/100,t=2*(o=Number(e[2])/100)-(n=o<=.5?o*(1+a):o+a-o*a),3a",!!(t=r.getElementsByTagName("a")[0])&&/^0.55/.test(t.style.opacity)),J="",Q="",re=B.defaultView?B.defaultView.getComputedStyle:function(){},ie=K.getStyle=function(e,t,n,r,i){var a;return Z||"opacity"!==t?(!r&&e.style[t]?a=e.style[t]:(n=n||re(e,null))?a=n[t]||n.getPropertyValue(t)||n.getPropertyValue(t.replace(d,"-$1").toLowerCase()):e.currentStyle&&(a=e.currentStyle[t]),null==i||a&&"none"!==a&&"auto"!==a&&"auto auto"!==a?a:i):s(e)},ae=i.convertToPixels=function(e,t,n,r,i){if("px"===r||!r)return n;if("auto"===r||!n)return 0;var a,o,s,l=Y.test(t),u=e,c=G.style,d=n<0;if(d&&(n=-n),"%"===r&&-1!==t.indexOf("border"))a=n/100*(l?e.clientWidth:e.clientHeight);else{if(c.cssText="border:0 solid red;position:"+ie(e,"position")+";line-height:0;","%"!==r&&u.appendChild)c[l?"borderLeftWidth":"borderTopWidth"]=n+r;else{if(o=(u=e.parentNode||B.body)._gsCache,s=f.ticker.frame,o&&l&&o.time===s)return o.width*n/100;c[l?"width":"height"]=n+r}u.appendChild(G),a=parseFloat(G[l?"offsetWidth":"offsetHeight"]),u.removeChild(G),l&&"%"===r&&!1!==K.cacheWidths&&((o=u._gsCache=u._gsCache||{}).time=s,o.width=a/n*100),0!==a||i||(a=ae(e,t,n,r,!0))}return d?-a:a},oe=i.calculateOffset=function(e,t,n){if("absolute"!==ie(e,"position",n))return 0;var r="left"===t?"Left":"Top",i=ie(e,"margin"+r,n);return e["offset"+r]-(ae(e,t,parseFloat(i),i.replace(R,""))||0)},se={width:["Left","Right"],height:["Top","Bottom"]},le=["marginLeft","marginRight","marginTop","marginBottom"],ue={aqua:[0,255,255],lime:[0,255,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,255],navy:[0,0,128],white:[255,255,255],fuchsia:[255,0,255],olive:[128,128,0],yellow:[255,255,0],orange:[255,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[255,0,0],pink:[255,192,203],cyan:[0,255,255],transparent:[255,255,255,0]},ce="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#.+?\\b";for(e in ue)ce+="|"+e+"\\b";function de(e,t,a,o){if(null==e)return function(e){return e};var s,l=t?(e.match(ce)||[""])[0]:"",u=e.split(l).join("").match(P)||[],c=e.substr(0,e.indexOf(u[0])),d=")"===e.charAt(e.length-1)?")":"",f=-1!==e.indexOf(" ")?" ":",",h=u.length,p=0r--)for(;++rr--)for(;++r>0];return r.parse(e,o,i,a)}}ce=new RegExp(ce+")","gi"),i._setPluginRatio=function(e){this.plugin.setRatio(e);for(var t,n,r,i,a=this.data,o=a.proxy,s=a.firstMPT;s;)t=o[s.v],s.r?t=Math.round(t):t<1e-6&&-1e-6s.length?l.length:s.length,o=0;o-z&&(B[o]=0);return n&&(e._gsTransform=B),B},Se=i.set3DTransformRatio=function(e){var t,n,r,i,a,o,s,l,u,c,d,f,h,p,m,g,v,y,b,w,x,D,k,C=this.data,_=this.t.style,$=C.rotation*te,S=C.scaleX,T=C.scaleY,M=C.scaleZ,E=C.perspective;if(A&&(S<1e-4&&-1e-4i.pr;)a=a._next;(i._prev=a?a._prev:s)?i._prev._next=i:o=i,(i._next=a)?a._prev=i:s=i,i=l}this._firstPT=o}return!0},e.parse=function(e,t,n,r){var i,a,o,s,l,u,c,d,f,h,p=e.style;for(i in t)u=t[i],(a=m[i])?n=a.parse(e,u,i,this,n,r,t):(l=ie(e,i,_)+"",f="string"==typeof u,"color"===i||"fill"===i||"stroke"===i||-1!==i.indexOf("Color")||f&&L.test(u)?(f||(u=(3<(u=T(u)).length?"rgba(":"rgb(")+u.join(",")+")"),n=me(p,i,l,u,!0,"transparent",n,0,r)):!f||-1===u.indexOf(" ")&&-1===u.indexOf(",")?(c=(o=parseFloat(l))||0===o?l.substr((o+"").length):"",""!==l&&"auto"!==l||(c="width"===i||"height"===i?(o=function(e,t,n){var r=parseFloat("width"===t?e.offsetWidth:e.offsetHeight),i=se[t],a=i.length;for(n=n||re(e,null);-1<--a;)r-=parseFloat(ie(e,"padding"+i[a],n,!0))||0,r-=parseFloat(ie(e,"border"+i[a]+"Width",n,!0))||0;return r}(e,i,_),"px"):"left"===i||"top"===i?(o=oe(e,i,_),"px"):(o="opacity"!==i?0:1,"")),""===(d=(h=f&&"="===u.charAt(1))?(s=parseInt(u.charAt(0)+"1",10),u=u.substr(2),s*=parseFloat(u),u.replace(R,"")):(s=parseFloat(u),f&&u.substr((s+"").length)||""))&&(d=i in C?C[i]:c),u=s||0===s?(h?s+o:s)+d:t[i],c!==d&&""!==d&&(s||0===s)&&o&&(o=ae(e,i,o,c),"%"===d?(o/=ae(e,i,100,"%")/100,!0!==t.strictUnits&&(l=o+"%")):"em"===d?o/=ae(e,i,1,"em"):"px"!==d&&(s=ae(e,i,s,d),d="px"),h&&(s||0===s)&&(u=s+o+d)),h&&(s+=o),!o&&0!==o||!s&&0!==s?void 0!==p[i]&&(u||u+""!="NaN"&&null!=u)?(n=new pe(p,i,s||o||0,0,n,-1,i,!1,0,l,u)).xs0="none"!==u||"display"!==i&&-1===i.indexOf("Style")?u:l:g("invalid "+i+" tween value: "+t[i]):(n=new pe(p,i,o,s-o,n,0,i,!1!==M&&("px"===d||"zIndex"===i),0,l,u)).xs0=d):n=me(p,i,l,u,!0,null,n,0,r)),r&&n&&!n.plugin&&(n.plugin=r);return n},e.setRatio=function(e){var t,n,r,i=this._firstPT;if(1!==e||this._tween._time!==this._tween._duration&&0!==this._tween._time)if(e||this._tween._time!==this._tween._duration&&0!==this._tween._time||-1e-6===this._tween._rawPrevTime)for(;i;){if(t=i.c*e+i.s,i.r?t=Math.round(t):t<1e-6&&-1e-6=n&ðis._duration?this._duration:e,t)):this._time},U.totalTime=function(e,t,n){if(d||M.wake(),!arguments.length)return this._totalTime;if(this._timeline){if(e<0&&!n&&(e+=this.totalDuration()),this._timeline.smoothChildTiming){this._dirty&&this.totalDuration();var r=this._totalDuration,i=this._timeline;if(ra;)i=i._prev;return i?(e._next=i._next,i._next=e):(e._next=this._first,this._first=e),e._next?e._next._prev=e:this._last=e,e._prev=i,this._timeline&&this._uncache(!0),this},U._remove=function(e,t){return e.timeline===this&&(t||e._enabled(!1,!0),e.timeline=null,e._prev?e._prev._next=e._next:this._first===e&&(this._first=e._next),e._next?e._next._prev=e._prev:this._last===e&&(this._last=e._prev),this._timeline&&this._uncache(!0)),this},U.render=function(e,t,n){var r,i=this._first;for(this._totalTime=this._time=this._rawPrevTime=e;i;)r=i._next,(i._active||e>=i._startTime&&!i._paused)&&(i._reversed?i.render((i._dirty?i.totalDuration():i._totalDuration)-(e-i._startTime)*i._timeScale,t,n):i.render((e-i._startTime)*i._timeScale,t,n)),i=r},U.rawTime=function(){return d||M.wake(),this._totalTime};var A=w("TweenLite",function(e,t,n){if(T.call(this,t,n),this.render=A.prototype.render,null==e)throw"Cannot tween a null target.";this.target=e="string"==typeof e&&A.selector(e)||e;var r,i,a,o=e.jquery||e.length&&e!==f&&e[0]&&(e[0]===f||e[0].nodeType&&e[0].style&&!e.nodeType),s=this.vars.overwrite;if(this._overwrite=s=null==s?j[A.defaultOverwrite]:"number"==typeof s?s>>0:j[s],(o||e instanceof Array||e.push&&c(e))&&"number"!=typeof e[0])for(this._targets=a=l.call(e,0),this._propLookup=[],this._siblings=[],r=0;ru&&((f||!o._initted)&&u-o._startTime<=2e-10||(c[d++]=o)));for(h=d;-1<--h;)o=c[h],2===r&&o._kill(n,e)&&(a=!0),(2!==r||!o._firstPT&&o._initted)&&o._enabled(!1,!1)&&(a=!0);return a},H=function(e,t,n){for(var r=e._timeline,i=r._timeScale,a=e._startTime;r._timeline;){if(a+=r._startTime,i*=r._timeScale,r._paused)return-100;r=r._timeline}return t<(a/=i)?a-t:n&&a===t||!e._initted&&a-t<2*g?g:(a+=e.totalDuration()/e._timeScale/i)>t+g?0:a-t-g};U._init=function(){var e,t,n,r,i=this.vars,a=this._overwrittenProps,o=this._duration,s=i.immediateRender,l=i.ease;if(i.startAt){if(this._startAt&&this._startAt.render(-1,!0),i.startAt.overwrite=0,i.startAt.immediateRender=!0,this._startAt=A.to(this.target,0,i.startAt),s)if(0s.pr;)r=r._next;(s._prev=r?r._prev:a)?s._prev._next=s:i=s,(s._next=r)?r._prev=s:a=s,s=o}s=t._firstPT=i}for(;s;)s.pg&&"function"==typeof s.t[e]&&s.t[e]()&&(n=!0),s=s._next;return n},V.activate=function(e){for(var t=e.length;-1<--t;)e[t].API===V.API&&(F[(new e[t])._propName]=e[t]);return!0},r.plugin=function(e){if(!(e&&e.propName&&e.init&&e.API))throw"illegal plugin definition.";var t,n=e.propName,r=e.priority||0,i=e.overwriteProps,a={init:"_onInitTween",set:"setRatio",kill:"_kill",round:"_roundProps",initAll:"_onInitAllProps"},o=w("plugins."+n.charAt(0).toUpperCase()+n.substr(1)+"Plugin",function(){V.call(this,n,r),this._overwriteProps=i||[]},!0===e.global),s=o.prototype=new V(n);for(t in(s.constructor=o).API=e.API,a)"function"==typeof e[t]&&(s[a[t]]=e[t]);return o.version=e.version,V.activate([o]),o},a=f._gsQueue){for(o=0;o=e.width[0],n=!e.width[1]||o.width<=e.width[1]),e.height&&(r=o.height>=e.height[0],i=!e.height[1]||o.height<=e.height[1]),t&&n&&r&&i)}),a.update()})},t,e)}}return p||(window.addEventListener("resize",s()),window.addEventListener("orientationchange",s())),i.prototype={current:function(){var e=this.viewports.filter(function(e){return this.vps[e.name]&&this.vps[e.name].mql.matches},this).pop();return this.vps[e&&e.name]||n},is:function(e){return this.current().name===e},matches:function(e){return this.vps[e]&&this.vps[e].mql.matches},subscribe:function(e,t){if(e in this.vps||"*"===e)return this.state.tokenUid=this.state.tokenUid+1,this.state.channels[e]||(this.state.channels[e]=[]),this.state.channels[e].push({token:this.state.tokenUid,method:t}),e===this.state.present.name&&t(!0,this.state.present),"*"===e&&(this.state.previous.name||this.state.present.name)&&t(this.state.present,this.state.previous),this.state.tokenUid;throw new Error('The viewport "'+e+'" does not match any configured viewports.')},unsubscribe:function(e){var t,n;for(n in this.state.channels)if(t=this.state.channels[n])for(var r=0,i=t.length;r');this.videoContainers=[],this.init=function(){l(this.initVideoManager.bind(this))},this.initVideoManager=function(){s.css("display","none"),l(document.body).append(s)},this.createS7Video=function(e,t,n,r){var i={autoplay:"false",playback:"auto",asset:t.source,serverurl:t.imageUrl,videoserverurl:t.videoUrl,stageSize:"0,0"};t.caption&&t.contentUrl&&""!==t.caption&&""!==t.contentUrl&&(i.contentUrl=t.contentUrl,i.caption=t.caption);var a=new o({containerId:e.id,params:i,handlers:{trackEvent:n,initComplete:r}});return a.init(),a},this.createVideo=function(r){var e=r.source,t=r.eventListener||function(){},n=r.onPlayerInit||function(){};if(this.videoContainers[e])return this.videoContainers[e].eventListener=t,this.videoContainers[e].isActive=!0,setTimeout(n,0),this.videoContainers[e];var i,a={id:"ManagedVideo_"+Object.keys(this.videoContainers).length,isActive:!0},o=l("");return s.append(o),o.attr("id",a.id),o.addClass("mgmri-s7video"),a.listenerFunction=function(e,t,n,r,i){this.eventListener(e,t,n,r,i)}.bind(a),a.eventListener=t,i=this.createS7Video(o[0],r,a.listenerFunction,n),a.videoElement=o,a.videoObject=i,a.play=function(){var e,t,n;this.isActive&&this.videoObject.videoplayer&&(this.videoObject.videoplayer.play(),e=l(this.videoObject.videoplayer.component.container),t=r.videoDescription,(n=e&&e.find(".s7iconeffect"))&&t&&n.attr({"aria-label":t,tabindex:0}))}.bind(a),a.stop=function(){this.videoObject.videoplayer&&this.videoObject.videoplayer.stop()}.bind(a),a.remove=function(){this.removeVideo(e)}.bind(this),this.videoContainers[e]=a,this.videoContainers[e]},this.loadVideo=function(e){return this.createVideo(e)},this.removeVideo=function(e){this.videoContainers[e]&&(this.videoContainers[e].videoObject.videoplayer&&this.videoContainers[e].videoObject.videoplayer.stop(),s.append(this.videoContainers[e].videoElement),this.videoContainers[e].isActive=!1)},this.init()}}),Function.prototype.bind||(Function.prototype.bind=function(e){if("function"!=typeof this)throw new TypeError("Function.prototype.bind - what is trying to be bound is not callable");function t(){}function n(){return i.apply(this instanceof t&&e?this:e,r.concat(Array.prototype.slice.call(arguments)))}var r=Array.prototype.slice.call(arguments,1),i=this;return t.prototype=this.prototype,n.prototype=new t,n}),"function"!=typeof Object.create&&function(){function t(){}Object.create=function(e){if(1n.curTileLength-i?n.curTileLength-i:e<0?0:e,o=Math.ceil(e/i),s=o+1,l=e===n.curTileLength-i,u={index:e,offset:n.tileWidth*e,prevIndex:n.index,prevTile:n.curTile,curTile:l&&n.tileDelta&&"frame"===r.incrementMode?n.tileArr[e+n.tileDelta]:n.tileArr[e],curFrame:Array.prototype.slice.call(n.tileArr,e,i+e),prevFrame:n.curFrame,frameIndex:o,frameNumber:s,prevFrameIndex:n.frameIndex,prevFrameNumber:n.frameNumber};return this.updateState(u),t?this.animate():this.updatePosition(n.index),this.x.publish(this.ns+"/syncState/after",a,e),n}},updatePosition:function(e){var t=this.element,n=this.state,r="translateX(-"+n.tilePercent*e+"%)",i=this.cache("supportsTransitions"),a=this.cache("transitionData"),o=a&&void 0!==a.prefix?a.prefix:"",s=o+"transform",l=o+"transition";i?(t.style.transition="",t.style[l]="",t.style.transform=r,t.style[s]=r):"msTransform"in t.style&&(t.style.msTransform=r),this.toggleAria(n.tileArr,"add"),this.toggleAria(n.curFrame,"remove")},updateDimensions:function(){var e=this.state,t=e.tileArr,n=e.tilePercent+"%",r=e.trackPercent+"%";this.carousel.style.width=r;for(var i=0;i=t.curTileLength;r.preventNavDisable||(i?(e.prevBtn.disabled=!0,e.nextBtn.focus()):e.prevBtn.disabled=!1,a?(e.nextBtn.disabled=!0,e.prevBtn.focus()):e.nextBtn.disabled=!1)},handleNavigation:function(e){var t,n=e.target||e.srcElement;"button"===n.nodeName.toLowerCase()&&((t=n.hasAttribute("data-next")?"nextFrame":!!n.hasAttribute("data-prev")&&"prevFrame")&&this[t](),this.wrapper.focus())},prevFrame:function(){this.x.publish(this.ns+"/prevFrame/before");var e=this.state.index;return"tile"===this.options.incrementMode?e--:e-=this.options.tilesPerFrame,this.syncState(e,!0),this.x.publish(this.ns+"/prevFrame/after"),t("/prevFrame/after").publish(e),this.carousel},nextFrame:function(){this.x.publish(this.ns+"/nextFrame/before");var e=this.state.index;if(!(e+this.options.tilesPerFrame>=this.state.curTileLength))return"tile"===this.options.incrementMode?e++:e+=this.options.tilesPerFrame,this.syncState(e,!0),this.x.publish(this.ns+"/nextFrame/after"),t("/nextFrame/after").publish(e),this.carousel},jumpToFrame:function(e){var t=this.state,n=this.options,e=parseInt(e,10),r=this.options.tilesPerFrame,i=(i="frame"===n.incrementMode?e*r:e)<0?0:i;return("tile"===n.incrementMode||"frame"===n.incrementMode)&&i===t.index||"frame"===n.incrementMode&&e>t.curFrameLength||this.syncState(i,!0),this.carousel},reset:function(){return this.state.index,this.options,this.syncState(0,!0),this.carousel},toggleAria:function(e,t,n){if(this.options.accessible){for(var r,i,a=0,o=(this.state,e.length),s=" state-hidden",l=/\sstate-hidden/,u=/\sstate-visible/,c=/carousel-tile-spacer/,d="add"===t,n=n?" "+n:"",f=this.cache("hasAriaInited");a{frameText}'.replace(u,o[x]).replace(f,r).replace(c,o[x]).replace(d,a).replace(h,i).replace(p,m));this.pagination.insertAdjacentHTML("afterbegin",l.join("")),this.paginationLinks=v.querySelectorAll("li"),this.centerControls(),this.updatePagination(),this.api.addEvent(this.pagination,"click",this.handlePagination.bind(this)),this.api.publish(k+"/buildPagination/after")},centerControls:function(){var e;this.options.center&&this.options.wrapControls&&(e=this.api.outerWidth(this.dom.controls),this.dom.controls.style.position="relative",this.dom.controls.style.left="50%",this.dom.controls.style.marginLeft="-"+e/2+"px")},handlePagination:function(e){var t=e.target||e.srcElement,n=parseInt(t.getAttribute("data-frame"),10),r="frame"===this.api.getOption("incrementMode")?this.api.getState("frameIndex"):this.api.getState("index");if("frame"===this.api.getOption("incrementMode")?this.api.getState("frameNumber"):this.api.getState("index"),!isNaN(n))return"preventDefault"in e&&e.preventDefault(),"returnValue"in e&&(e.returnValue=!1),r!==n&&!this.dom.carousel.className.match(i)&&!t.className.match(s)&&void this.api.trigger("jumpToFrame",n)},updatePagination:function(){this.api.publish(k+"/updatePagination/before");for(var e,t,n,r=[],i=this.api.trigger("cache",k+"/newFrameIndex"),a=0;at.carousel.tilesPerFrame&&(t.pluginInited||(t.origTileDom=t.carousel.tileArr,t.api.subscribe(t.api.ns+"/syncState/after",t.checkLoop.bind(t)),t.api.subscribe(t.api.ns+"/animate/after",t.reposition.bind(t)),t.api.subscribe(t.api.ns+"/reinit/before",t.resetLoopDom.bind(t)),t.api.subscribe(o+"/buildPagination/before",t.loadPagination.bind(t)),t.api.subscribe(o+"/updatePagination/before",t.funcs.updatePagination),t.api.trigger("updateOptions",{preventNavDisable:!0}),t.pluginInited=!0),t.createLoopDom.call(t)))})},resetLoopDom:function(){for(var e=this.carousel.dom.carousel,t=e.children,n=Array.prototype.slice.call(t),r=0;r\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",n=a.console&&(a.console.warn||a.console.log);return n&&n.call(a.console,i,t),r.apply(this,arguments)}}function t(e,t,n){var r=t.prototype,i=e.prototype=Object.create(r);i.constructor=e,i._super=r,n&&ne(i,n)}function i(e,t){return function(){return e.apply(t,arguments)}}function u(e,t){return typeof e==Q?e.apply(t&&t[0]||E,t):e}function n(e,t){return e===E?t:e}function c(t,e,n){o(h(e),function(e){t.addEventListener(e,n,!1)})}function d(t,e,n){o(h(e),function(e){t.removeEventListener(e,n,!1)})}function A(e,t){for(;e;){if(e==t)return!0;e=e.parentNode}return!1}function f(e,t){return-1t[n]}):r.sort()),r}function v(e,t){for(var n,r,i=t[0].toUpperCase()+t.slice(1),a=0;aee(T.y)?T.x:T.y,t.scale=f?(S=f.pointers,R(r[0],r[1],ke)/R(S[0],S[1],ke)):1,t.rotation=f?($=f.pointers,N(r[1],r[0],ke)+N($[1],$[0],ke)):0,t.maxPointers=!n.prevInput||t.pointers.length>n.prevInput.maxPointers?t.pointers.length:n.prevInput.maxPointers,g=t,C=(m=n).lastInterval||g,_=g.timeStamp-C.timeStamp,g.eventType!=he&&(ce<_||C.velocity===E)?(y=(k=F(_,x=g.deltaX-C.deltaX,D=g.deltaY-C.deltaY)).x,b=k.y,v=ee(k.x)>ee(k.y)?k.x:k.y,w=P(x,D),m.lastInterval=g):(v=C.velocity,y=C.velocityX,b=C.velocityY,w=C.direction),g.velocity=v,g.velocityX=y,g.velocityY=b,g.direction=w;var M=e.element;A(t.srcEvent.target,M)&&(M=t.srcEvent.target),t.target=M}(e,n),e.emit("hammer.input",n),e.recognize(n),e.session.prevInput=n}function O(e){for(var t=[],n=0;n=ee(t)?e<0?me:ge:t<0?ve:ye}function R(e,t,n){var r=t[(n=n||De)[0]]-e[n[0]],i=t[n[1]]-e[n[1]];return Math.sqrt(r*r+i*i)}function N(e,t,n){var r=t[(n=n||De)[0]]-e[n[0]],i=t[n[1]]-e[n[1]];return 180*Math.atan2(i,r)/Math.PI}function x(){this.evEl=_e,this.evWin=$e,this.pressed=!1,b.apply(this,arguments)}function D(){this.evEl=Me,this.evWin=Ee,b.apply(this,arguments),this.store=this.manager.session.pointerEvents=[]}function k(){this.evTarget="touchstart",this.evWin="touchstart touchmove touchend touchcancel",this.started=!1,b.apply(this,arguments)}function C(){this.evTarget=Ie,this.targetIds={},b.apply(this,arguments)}function _(){b.apply(this,arguments);var e=i(this.handler,this);this.touch=new C(this.manager,e),this.mouse=new x(this.manager,e),this.primaryTouch=null,this.lastTouches=[]}function $(e){var t,n,r=e.changedPointers[0];r.identifier===this.primaryTouch&&(t={x:r.clientX,y:r.clientY},this.lastTouches.push(t),n=this.lastTouches,setTimeout(function(){var e=n.indexOf(t);-1t.threshold&&i&t.direction},attrTest:function(e){return W.prototype.attrTest.call(this,e)&&(2&this.state||!(2&this.state)&&this.directionTest(e))},emit:function(e){this.pX=e.deltaX,this.pY=e.deltaY;var t=j(e.direction);t&&(e.additionalEvent=this.options.event+t),this._super.emit.call(this,e)}}),t(Y,W,{defaults:{event:"pinch",threshold:0,pointers:2},getTouchAction:function(){return[Ne]},attrTest:function(e){return this._super.attrTest.call(this,e)&&(Math.abs(e.scale-1)>this.options.threshold||2&this.state)},emit:function(e){var t;1!==e.scale&&(t=e.scale<1?"in":"out",e.additionalEvent=this.options.event+t),this._super.emit.call(this,e)}}),t(H,T,{defaults:{event:"press",pointers:1,time:251,threshold:9},getTouchAction:function(){return["auto"]},process:function(e){var t=this.options,n=e.pointers.length===t.pointers,r=e.distancet.time;if(this._input=e,!r||!n||e.eventType&(fe|he)&&!i)this.reset();else if(e.eventType&de)this.reset(),this._timer=l(function(){this.state=8,this.tryEmit()},t.time,this);else if(e.eventType&fe)return 8;return 32},reset:function(){clearTimeout(this._timer)},emit:function(e){8===this.state&&(e&&e.eventType&fe?this.manager.emit(this.options.event+"up",e):(this._input.timeStamp=te(),this.manager.emit(this.options.event,this._input)))}}),t(V,W,{defaults:{event:"rotate",threshold:0,pointers:2},getTouchAction:function(){return[Ne]},attrTest:function(e){return this._super.attrTest.call(this,e)&&(Math.abs(e.rotation)>this.options.threshold||2&this.state)}}),t(U,W,{defaults:{event:"swipe",threshold:10,velocity:.3,direction:be|we,pointers:1},getTouchAction:function(){return q.prototype.getTouchAction.call(this)},attrTest:function(e){var t,n=this.options.direction;return n&(be|we)?t=e.overallVelocity:n&be?t=e.overallVelocityX:n&we&&(t=e.overallVelocityY),this._super.attrTest.call(this,e)&&n&e.offsetDirection&&e.distance>this.options.threshold&&e.maxPointers==this.options.pointers&&ee(t)>this.options.velocity&&e.eventType&fe},emit:function(e){var t=j(e.offsetDirection);t&&this.manager.emit(this.options.event+t,e),this.manager.emit(this.options.event,e)}}),t(B,T,{defaults:{event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},getTouchAction:function(){return[Re]},process:function(e){var t=this.options,n=e.pointers.length===t.pointers,r=e.distancepane_width/2?"right"==e.gesture.direction?this.api.trigger("prevFrame"):this.api.trigger("nextFrame"):this.showPane(current_pane,!0)}}},e.plugin("touch",function(e,t){new r(e,t)})}),define("modules/canvas",["vendor/TweenLite","modules/global-vps","modules/pubsub","modules/video-manager","vendor/carousel","vendor/carousel.pagination","vendor/carousel.loop","vendor/carousel.touch","jquery"],function(g,v,k,o,f,e,t,n,C){function _(e){for(var t=arguments.length,n=1;n');switch(j&&this.destroyMediaContent(j),j={},e.media){case"carousel":case"mixed-media":n=t;break;case"image":n=C('');break;case"virtual-tour":n=C('');break;case"youtube":n=C('');break;case"video":var a={source:t,videoUrl:e.videoUrl,imageUrl:e.imageUrl,videoDescription:e.videoDescription,onPlayerInit:function(){r.play()}};e.caption&&e.contentUrl&&""!==e.caption&&""!==e.contentUrl&&(a.contentUrl=e.contentUrl,a.caption=e.caption),n=(r=o.loadVideo(a)).videoElement,j.videoObject=r;break;default:n=C("")}return i.addClass(e.media),i.append(n),j.options=e,j.element=i[0],j},destroyMediaContent:function(){!1!==j&&"video"===j.options.media&&j.videoObject&&j.videoObject.remove&&j.videoObject.remove(),j=!1},stopPropagation:function(e){return e.stopPropagation(),e.stopImmediatePropagation(),!1},replaceElem:function(e,t){var n=this,r="parseContent/"+e,i=n.cache(r+"/elem"),a=n.cache(r+"/parentNode"),o=n.cache(r+"/siblingNode");i&&a&&(o&&C.contains(a,o)?a.insertBefore(i,o):a.appendChild(i),i.style.display=t?"none":""),n.cache(r+"/elem","undefined"),n.cache(r+"/parentNode","undefined"),n.cache(r+"/siblingNode","undefined")},movePage:function(e){var t,n,r,i=x.getBoundingClientRect(),a=l||u,o=window.getComputedStyle(a).getPropertyValue("position"),s=this.cache("openCanvas/dir");e="-"+e,l?this.cache("movePage/navPos",o):u&&"fixed"===o&&(u.style.position="absolute",T(c,{position:"absolute",width:b.width/16+"rem",marginLeft:"-"+i.left/16+"rem"}),this.cache("movePage/navPos",o)),C(d).hasClass("fixed")&&(r=1440{pageNumber} / {total}"},autorotate:i,loop:!1,touch:!0})),l.curtainClass&&(o.className+=" "+l.curtainClass),l.scrollableModal&&!b.height&&(b={vp:v.current().name,width:window.innerWidth,height:window.innerHeight}),l.scrollableModal?T(a.curtain,{width:b.width/16+"rem"}):T(a.curtain,{width:b.width/16+"rem",height:"100%"}),v.is("small")||l.scrollableModal||(s.style.maxHeight=.85*b.height/16+"rem"),M(E.documentElement,P,!0),a.state&&a.state.scrollableModal&&M(E.documentElement,R,!0),a.state.modalOpen=!0}k("canvas/enforceFocus").publish(C(s)),a.trig=e||w,C(a.modal).focus(),x&&x.setAttribute("aria-hidden","true"),C(".wrapper *:not(.sign-modal *)").on("focus",function(){C(a.modal).focus()})}},callbackCloseModal:function(e){e&&e.preventDefault(),L&&L(),this.closeModal()},keyPressOnModalCurtain:function(e){27===event.keyCode&&this.state&&this.state.scrollableModal&&this.callbackCloseModal(e)},closeModal:function(){var e,t,n,r;k("canvas/enforceFocus/off").publish(),this.state.modalOpen&&(this.destroyMediaContent(),t=(e=this).curtain,n=e.scrollableCurtain,r=e.modal,h(t,"click",e.callbackCloseModal.bind(e)),h(r,"click",e.stopPropagation),r.className=p,t.className=s,r.style.maxHeight="",M(E.documentElement,P,!1),e.state&&e.state.scrollableModal&&(h(w,"keydown",e.keyPressOnModalCurtain.bind(e)),h(n,"click",e.callbackCloseModal.bind(e)),M(E.documentElement,R,!1),e.state.scrollableModal=!1),t.removeChild(r),e.replaceElem("modal"),e.state.modalOpen=!1,x&&x.setAttribute("aria-hidden","false"),e.trig.focus())},openSecondCanvas:function(e,t,n,r,i,a){function o(){d.state.offcanvasOpen=!0,r&&"[object Function]"===S(r)&&r(),v.is("small")&&C(x).hide()}var s,l,u,c,d=this,f=d.container,h=d.cache("openCanvas/elemHidden"),p=d.cache("window/scrollPos"),m=_({},d.options);if(d.trig=e||w,!a)for(;f.firstChild;)f.removeChild(f.firstChild);M(E.documentElement,O,!1),d.replaceElem("canvas",h),f.className=D,T(f,{display:"",left:""}),d.state.curtainOpen&&d.closeCurtain(),"small"===b.vp&&(p&&window.scrollTo(0,p),d.cache("window/scrollPos","undefined")),d.cache("openCanvas/elemHidden","undefined"),d.cache("openCanvas/dir","undefined"),r&&"[object Function]"===S(r)&&r(),d.state.offcanvasOpen=!1,d.trig.focus(),d.state.offcanvasOpen&&(s="left"===n?"100%":"-100%","small"!==b.vp&&(x&&x.setAttribute("aria-hidden","false"),d.resetPage()),g.to(f,d.options.transTime,{left:s,ease:Quad.easeIn,onComplete:o})),(l=d.parseContent(t,"canvas"))&&y(l)&&((i&&"[object Object]"===S(i)||r&&"[object Object]"===S(r))&&_(m,i=i&&"[object Object]"===S(i)?i:r),f.style.display="block",0e.parentNode.offsetLeft&&(i=e.offsetLeft-e.parentNode.offsetLeft),e.style.marginLeft="-"+i/16+"rem");else if("[object Array]"===S(e)&&0(window.innerWidth||E.documentElement.clientWidth))&&(d.left<0?b=10:d.right>(window.innerWidth||E.documentElement.clientWidth)&&(b=(window.innerWidth||E.documentElement.clientWidth)-(d.width||function(e){e=void 0!==e&&e;var t=window.getComputedStyle(x).getPropertyValue("width");return e&&(t=parseInt(t,0)),t}(!0))-10),d.top<0&&Math.abs(d.top)>e&&(o=o+d.height+40,x.className+=" bottom"),T(x,{left:b/16+"rem",top:o/16+"rem"}),f!==b&&(g="calc(50% - 0.5rem - "+(b-f)+"px)",x.arrow.style.left="-webkit-"+g,x.arrow.style.left=g)),M(E.documentElement,N,!0),x.focus(),w.state.tooltipOpen=!0}function a(){p.focus(),w.closeTooltip(!0)}if(e&&e.preventDefault&&(e.preventDefault(),e.stopPropagation(),e.stopImmediatePropagation()),this.state.tooltipOpen){if(this.closeTooltip(),""===e||e.name&&e.name===this.targetName)return;k("tooltip/continueOpen").publish()}var o,s,l,u,c,d,f,h,p,m,g,v,y,b,w=this,x=w.tooltip,D=_({},w.options);if(w.tooltip.style.display="block",e&&e.name&&(w.targetName=e.name),n&&void 0!==n.trigX&&void 0!==n.trigY){if(t){if(!(s=w.parseContent(t,"tooltip")))return;x.insertBefore(s,w.tooltip.closeBtn)}return r(),b=n.trigX-x.offsetWidth/2,o=n.topTip?n.trigY+15:n.trigY-x.offsetHeight,T(x,{left:b/16+"rem",top:o/16+"rem"}),i(),void w.tooltip.focus()}if(h=(p=e.currentTarget).getBoundingClientRect(),p.setAttribute("aria-expanded","true"),m=w.tooltip.trig=p,w.cache("openTooltip/trigger"),t){if(!(s=w.parseContent(t,"tooltip")))return;x.appendChild(s)}else{for(;m&&-1===m.className.search(/\btooltip-wrapper\b/);)m=m.parentNode;if(!m)return;c=m.querySelector("[data-tooltip-content]"),x.insertAdjacentHTML("beforeend",c.innerHTML),0").attr("name",n.submitButton.name).val(u(n.submitButton).val()).appendTo(n.currentForm)),n.settings.submitHandler.call(n,n.currentForm,t),n.submitButton&&e.remove(),!1)}return n.settings.debug&&t.preventDefault(),n.cancelSubmit?(n.cancelSubmit=!1,e()):n.form()?n.pendingRequest?!(n.formSubmitted=!0):e():(n.focusInvalid(),!1)})),n)}e&&e.debug&&window.console&&console.warn("Nothing selected, can't validate, returning nothing.")},valid:function(){var e,t;return u(this[0]).is("form")?e=this.validate().form():(e=!0,t=u(this[0].form).validate(),this.each(function(){e=t.element(this)&&e})),e},removeAttrs:function(e){var n={},r=this;return u.each(e.split(/\s/),function(e,t){n[t]=r.attr(t),r.removeAttr(t)}),n},rules:function(e,t){var n,r,i,a,o,s,l=this[0];if(e)switch(r=(n=u.data(l.form,"validator").settings).rules,i=u.validator.staticRules(l),e){case"add":u.extend(i,u.validator.normalizeRule(t)),delete i.messages,r[l.name]=i,t.messages&&(n.messages[l.name]=u.extend(n.messages[l.name],t.messages));break;case"remove":return t?(s={},u.each(t.split(/\s/),function(e,t){s[t]=i[t],delete i[t],"required"===t&&u(l).removeAttr("aria-required")}),s):(delete r[l.name],i)}return(a=u.validator.normalizeRules(u.extend({},u.validator.classRules(l),u.validator.attributeRules(l),u.validator.dataRules(l),u.validator.staticRules(l)),l)).required&&(o=a.required,delete a.required,a=u.extend({required:o},a),u(l).attr("aria-required","true")),a.remote&&(o=a.remote,delete a.remote,a=u.extend(a,{remote:o})),a}}),u.extend(u.expr[":"],{blank:function(e){return!u.trim(""+u(e).val())},filled:function(e){return!!u.trim(""+u(e).val())},unchecked:function(e){return!u(e).prop("checked")}}),u.validator=function(e,t){this.settings=u.extend(!0,{},u.validator.defaults,e),this.currentForm=t,this.init()},u.validator.format=function(n,e){return 1===arguments.length?function(){var e=u.makeArray(arguments);return e.unshift(n),u.validator.format.apply(this,e)}:(2Warning: No message defined for "+e.name+"")},formatAndAdd:function(e,t){var n=this.defaultMessage(e,t.method),r=/\$?\{(\d+)\}/g;"function"==typeof n?n=n.call(this,t.parameters,e):r.test(n)&&(n=u.validator.format(n.replace(r,"{$1}"),t.parameters)),this.errorList.push({message:n,element:e,method:t.method}),this.errorMap[e.name]=n,this.submitted[e.name]=n},addWrapper:function(e){return this.settings.wrapper&&(e=e.add(e.parent(this.settings.wrapper))),e},defaultShowErrors:function(){for(var e,t,n=0;this.errorList[n];n++)t=this.errorList[n],this.settings.highlight&&this.settings.highlight.call(this,t.element,this.settings.errorClass,this.settings.validClass),this.showLabel(t.element,t.message);if(this.errorList.length&&(this.toShow=this.toShow.add(this.containers)),this.settings.success)for(n=0;this.successList[n];n++)this.showLabel(this.successList[n]);if(this.settings.unhighlight)for(n=0,e=this.validElements();e[n];n++)this.settings.unhighlight.call(this,e[n],this.settings.errorClass,this.settings.validClass);this.toHide=this.toHide.not(this.toShow),this.hideErrors(),this.addWrapper(this.toShow).show()},validElements:function(){return this.currentElements.not(this.invalidElements())},invalidElements:function(){return u(this.errorList).map(function(){return this.element})},showLabel:function(e,t){var n=this.errorsFor(e);n.length?(n.removeClass(this.settings.validClass).addClass(this.settings.errorClass),n.html(t)):(n=u("<"+this.settings.errorElement+">").attr("for",this.idOrName(e)).addClass(this.settings.errorClass).html(t||""),this.settings.wrapper&&(n=n.hide().show().wrap("<"+this.settings.wrapper+"/>").parent()),this.labelContainer.append(n).length||(this.settings.errorPlacement?this.settings.errorPlacement(n,u(e)):n.insertAfter(e))),!t&&this.settings.success&&(n.text(""),"string"==typeof this.settings.success?n.addClass(this.settings.success):this.settings.success(n,e)),this.toShow=this.toShow.add(n)},errorsFor:function(e){var t=this.idOrName(e);return this.errors().filter(function(){return u(this).attr("for")===t})},idOrName:function(e){return this.groups[e.name]||!this.checkable(e)&&e.id||e.name},validationTargetFor:function(e){return this.checkable(e)&&(e=this.findByName(e.name).not(this.settings.ignore)[0]),e},checkable:function(e){return/radio|checkbox/i.test(e.type)},findByName:function(e){return u(this.currentForm).find("[name='"+e+"']")},getLength:function(e,t){switch(t.nodeName.toLowerCase()){case"select":return u("option:selected",t).length;case"input":if(this.checkable(t))return this.findByName(t.name).filter(":checked").length}return e.length},depend:function(e,t){return!this.dependTypes[typeof e]||this.dependTypes[typeof e](e,t)},dependTypes:{boolean:function(e){return e},string:function(e,t){return!!u(e,t.form).length},function:function(e,t){return e(t)}},optional:function(e){var t=this.elementValue(e);return!u.validator.methods.required.call(this,t,e)&&"dependency-mismatch"},startRequest:function(e){this.pending[e.name]||(this.pendingRequest++,this.pending[e.name]=!0)},stopRequest:function(e,t){this.pendingRequest--,this.pendingRequest<0&&(this.pendingRequest=0),delete this.pending[e.name],t&&0===this.pendingRequest&&this.formSubmitted&&this.form()?(u(this.currentForm).submit(),this.formSubmitted=!1):!t&&0===this.pendingRequest&&this.formSubmitted&&(u(this.currentForm).triggerHandler("invalid-form",[this]),this.formSubmitted=!1)},previousValue:function(e){return u.data(e,"previousValue")||u.data(e,"previousValue",{old:null,valid:!0,message:this.defaultMessage(e,"remote")})}},classRuleSettings:{required:{required:!0},email:{email:!0},url:{url:!0},date:{date:!0},dateISO:{dateISO:!0},number:{number:!0},digits:{digits:!0},creditcard:{creditcard:!0}},addClassRules:function(e,t){e.constructor===String?this.classRuleSettings[e]=t:u.extend(this.classRuleSettings,e)},classRules:function(e){var t={},n=u(e).attr("class");return n&&u.each(n.split(" "),function(){this in u.validator.classRuleSettings&&u.extend(t,u.validator.classRuleSettings[this])}),t},attributeRules:function(e){var t,n,r={},i=u(e),a=e.getAttribute("type");for(t in u.validator.methods)n="required"===t?(""===(n=e.getAttribute(t))&&(n=!0),!!n):i.attr(t),/min|max/.test(t)&&(null===a||/number|range|text/.test(a))&&(n=Number(n)),n||0===n?r[t]=n:a===t&&"range"!==a&&(r[t]=!0);return r.maxlength&&/-1|2147483647|524288/.test(r.maxlength)&&delete r.maxlength,r},dataRules:function(e){var t,n,r={},i=u(e);for(t in u.validator.methods)void 0!==(n=i.data("rule"+t[0].toUpperCase()+t.substring(1).toLowerCase()))&&(r[t]=n);return r},staticRules:function(e){var t={},n=u.data(e.form,"validator");return n&&n.settings.rules&&(t=u.validator.normalizeRule(n.settings.rules[e.name])||{}),t},normalizeRules:function(r,i){return u.each(r,function(e,t){if(!1!==t){if(t.param||t.depends){var n=!0;switch(typeof t.depends){case"string":n=!!u(t.depends,i.form).length;break;case"function":n=t.depends.call(i,i)}n?r[e]=void 0===t.param||t.param:delete r[e]}}else delete r[e]}),u.each(r,function(e,t){r[e]=u.isFunction(t)?t(i):t}),u.each(["minlength","maxlength"],function(){r[this]&&(r[this]=Number(r[this]))}),u.each(["rangelength","range"],function(){var e;r[this]&&(u.isArray(r[this])?r[this]=[Number(r[this][0]),Number(r[this][1])]:"string"==typeof r[this]&&(e=r[this].split(/[\s,]+/),r[this]=[Number(e[0]),Number(e[1])]))}),u.validator.autoCreateRanges&&(r.min&&r.max&&(r.range=[r.min,r.max],delete r.min,delete r.max),r.minlength&&r.maxlength&&(r.rangelength=[r.minlength,r.maxlength],delete r.minlength,delete r.maxlength)),r},normalizeRule:function(e){var t;return"string"==typeof e&&(t={},u.each(e.split(/\s/),function(){t[this]=!0}),e=t),e},addMethod:function(e,t,n){u.validator.methods[e]=t,u.validator.messages[e]=void 0!==n?n:u.validator.messages[e],t.length<3&&u.validator.addClassRules(e,u.validator.normalizeRule(e))},methods:{required:function(e,t,n){if(!this.depend(n,t))return"dependency-mismatch";if("select"!==t.nodeName.toLowerCase())return this.checkable(t)?0=n[0]&&r<=n[1]},min:function(e,t,n){return this.optional(t)||n<=e},max:function(e,t,n){return this.optional(t)||e<=n},range:function(e,t,n){return this.optional(t)||e>=n[0]&&e<=n[1]},alpha:function(e,t,n){return this.optional(t)||e==e.match(/^[a-zA-Z ]*$/)},equalTo:function(e,t,n){var r=u(n);return this.settings.onfocusout&&r.unbind(".validate-equalTo").bind("blur.validate-equalTo",function(){u(t).valid()}),e===r.val()},remote:function(a,o,e){if(this.optional(o))return"dependency-mismatch";var s,t,l=this.previousValue(o);return this.settings.messages[o.name]||(this.settings.messages[o.name]={}),l.originalMessage=this.settings.messages[o.name].remote,this.settings.messages[o.name].remote=l.message,e="string"==typeof e?{url:e}:e,l.old===a?l.valid:(l.old=a,(s=this).startRequest(o),(t={})[o.name]=a,u.ajax(u.extend(!0,{url:e,mode:"abort",port:"validate"+o.name,dataType:"json",data:t,context:s.currentForm,success:function(e){var t,n,r,i=!0===e||"true"===e;s.settings.messages[o.name].remote=l.originalMessage,i?(r=s.formSubmitted,s.prepareElement(o),s.formSubmitted=r,s.successList.push(o),delete s.invalid[o.name],s.showErrors()):(t={},n=e||s.defaultMessage(o,"remote"),t[o.name]=l.message=u.isFunction(n)?n(a):n,s.invalid[o.name]=!0,s.showErrors(t)),l.valid=i,s.stopRequest(o,i)}},e)),"pending")}}}),u.format=function(){throw"$.format has been deprecated. Please use $.validator.format instead."},o={},(r=e).ajaxPrefilter?r.ajaxPrefilter(function(e,t,n){var r=e.port;"abort"===e.mode&&(o[r]&&o[r].abort(),o[r]=n)}):(a=r.ajax,r.ajax=function(e){var t=("mode"in e?e:r.ajaxSettings).mode,n=("port"in e?e:r.ajaxSettings).port;return"abort"===t?(o[n]&&o[n].abort(),o[n]=a.apply(this,arguments),o[n]):a.apply(this,arguments)}),(i=e).extend(i.fn,{validateDelegate:function(n,e,r){return this.bind(e,function(e){var t=i(e.target);if(t.is(n))return r.apply(t,arguments)})}})}).call(t)})}(this),define("modules/validate",["jquery","vendor/jquery.validate"],function(d,e){var u="#validation-errors",a="aria-describedby",f={init:function(){this.setDefaultMessages(),this.extendValidationAPI(),this.setDefaultSettings(),this.addCustomMethods()},handleGroupErrorDescription:function(e){var t=e.find(".field-select"),n=t.length;if(n)for(var r=0;r").addClass(n.settings.errorClass).addClass("label").html(a||"").attr({id:o,generated:!0}),n.settings.errorPlacement(c,i),u.hide()),"input"===i[0].tagName.toLowerCase()&&i.attr({"aria-label":i[0].classList.contains("error")?a:""}),!i.data("validator-group")||(r=i.parent().parents(".input-group"))&&f.handleGroupErrorDescription(r),!t&&n.settings.success&&(c.text(""),"string"==typeof n.settings.success?c.addClass(n.settings.success):n.settings.success(c)),n.toShow=n.toShow.add(c)},defaultShowErrors:function(a){var e,t,o=a.errorList;if(o.forEach(function(t,e){var n,r,i;a.settings.highlight&&(a.settings.highlight.call(a,t.element,a.settings.errorClass,a.settings.validClass),d(t.element).data("validator-group")&&(r=(n=d(t.element).parent().parents(".input-group")).find("label").attr("id"),i=n.find('*[aria-describedby~="'+r+'"]'),d.each(i,function(e,n){var r=!0;n!==t.element&&(o.forEach(function(e,t){e.element===n&&(r=!1)}),r&&a.settings.highlight.call(a,n,a.settings.errorClass,a.settings.validClass))}))),f.showLabel(t.element,t.message,a)}),o.length&&(a.toShow=a.toShow.add(a.containers)),a.settings.success||a.successList.length)for(e=0;a.successList[e];e++)f.showLabel(a.successList[e],"",a);if(a.settings.unhighlight)for(e=0,t=a.validElements();t[e];e++)a.settings.unhighlight.call(a,t[e],a.settings.errorClass,a.settings.validClass);a.toHide=a.toHide.not(a.toShow),a.toHide&&a.toHide.remove(),a.addWrapper(a.toShow).show()},handleInputErrors:function(){var e=d(this.currentForm);f.defaultShowErrors(this),!1===this.settings.showSummary&&"sign-in-widget"!==this.settings.formName&&e.find("."+this.settings.errorClass+":first").focus()},buildErrorList:function(e,n){var r,i=d("
");return d.each(e,function(e,t){r=d(""),d(''+t.message+"").on("click",function(e){e.preventDefault(),n.find("#"+t.element.id).focus()}).appendTo(r),i.append(r)}),i},buildErrorTitle:function(e,t){var n,r=d('');return 1new Date(t.toLocaleDateString())?{isValid:!1,error:"pastDate",value:t}:{isValid:l,error:"invalidDate",value:t}}(e).isValid}}};f.init()}),define("modules/global-footer",["jquery","modules/canvas","modules/global-vps","modules/directions-map","modules/validate"],function(s,l,u,d,e){function t(e){var t,n,r=s(".contact-info .mail-us"),i=s("footer li.awards-logo"),a=s(".footer-oc li.awards-logo"),c=l(),o=this;if(f=new d(r,60,20),this.state={},!(t=!!MGMRI.footer&&MGMRI.footer.form.validation.footerFormValidate))return!1;!u.is("small")||(n=s("#footer-mgm-resorts-hdr"))&&n[0]&&(n[0].setAttribute("role","menu"),n[0].setAttribute("aria-labelledby","footer-mgm-resorts-hdr")),s("#mobile-offer-form").length&&s("#mobile-offer-form").validate(t),s(".promotions #mobileID").on("click",function(e){e.preventDefault();var i=s(e.target);s("#mobile-offer-form #phoneNumber").val(""),l().openModal(i,s("#sms-popup-wrapper")),s("#mobile-offer-form #sign-up-btn").on("click",function(e){var t,n,r;e.preventDefault(),s("#mobile-offer-form").valid()&&(t=MGMRI.data.smsSignUp,n=MGMRI.services.smsSignUp,r={phoneNumber:s("#mobile-offer-form #phoneNumber").val(),formName:t.formName,formId:t.formId,clientId:t.clientId,postUrl:t.postUrl},s.post(n,r,function(){}).done(function(){l().closeModal(),l().openModal(i,s("#success-message-wrapper")),s("#success-message-wrapper #close-btn").on("click",function(e){l().closeModal()})}))}),s("#mobile-offer-form #cancel-btn").on("click",function(e){var t=s("#mobile-offer-form").data("validator");e.preventDefault(),t&&t.resetForm(),l().closeModal()})}),s(".btn-footer-oc").on("click",function(e){var t=e.target.parentNode,n=t.hasAttribute("data-mlife")?"footer-oc footer-black-oc":"footer-oc",r=document.createElement("div"),i=document.createElement("button"),a=document.createElement("span"),o=t.querySelector(".btn-footer-oc").innerHTML,s=t.querySelector(".btn-footer-oc").getAttribute("data-close-text");i.setAttribute("data-focus","first"),i.setAttribute("class","btn-footer-oc"),i.appendChild(document.createTextNode(o)),a.setAttribute("class","screen-reader"),a.appendChild(document.createTextNode(s)),i.appendChild(a),r.appendChild(i);var l,u=t.querySelector("ul,.footer-offcanvas").cloneNode(!0);u&&(u.setAttribute("role","menu"),(l=u.getAttribute("data-label"))&&u.setAttribute("aria-labelledby",l.replace(/\s/g,""))),r.appendChild(u),i.addEventListener("click",function(){c.closeCanvas()}),c.openCanvas(e.target,r,"left",{customClass:n})}),this.state.footerInView=this.fireIfElementVisible(r,this.displayMap),!1!==this.state.footerInView&&s(window).on("DOMContentLoaded load resize scroll",this.state.footerInView),this.rotateAwards(i,a),this.setMapHeight(),u.subscribe("*",function(e){o.setMapHeight.call(o)})}var f=null;return t.prototype={rotateAwards:function(e,t){var n,r,i,a,o;e.length&&(n=s(".awards-container ul.awards").attr("data-animation-duration"),r=s(e).length,i=parseInt(n,10),u.is("small")?s(t).css("opacity",1):1i.oldScroll,n=t?i.forward:i.backward;return l.each(r.waypoints[e],function(e,t){var n,r;return i.oldScroll<(n=t.offset)&&n<=i.newScroll||i.newScroll<(r=t.offset)&&r<=i.oldScroll?a.push(t):void 0}),a.sort(function(e,t){return e.offset-t.offset}),t||a.reverse(),l.each(a,function(e,t){if(t.options.continuous||e===a.length-1)return t.trigger([n])})}),this.oldScroll={x:e.horizontal.newScroll,y:e.vertical.newScroll}},b.prototype.refresh=function(){var e,t=this,n=l.isWindow(this.element),r=this.$element.offset();return this.doScroll(),e={horizontal:{contextOffset:n?0:r.left,contextScroll:n?0:this.oldScroll.x,contextDimension:this.$element.width(),oldScroll:this.oldScroll.x,forward:"right",backward:"left",offsetProp:"left"},vertical:{contextOffset:n?0:r.top,contextScroll:n?0:this.oldScroll.y,contextDimension:n?l[y]("viewportHeight"):this.$element.height(),oldScroll:this.oldScroll.y,forward:"down",backward:"up",offsetProp:"top"}},l.each(e,function(e,s){return l.each(t.waypoints[e],function(e,t){var n,r,i=t.options.offset,a=t.offset,o=l.isWindow(t.element)?0:t.$element.offset()[s.offsetProp];if(l.isFunction(i)?i=i.apply(t.element):"string"==typeof i&&(i=parseFloat(i),-1(r=s.oldScroll)&&r>=t.offset||null===a&&s.oldScroll>=t.offset?t.trigger([s.forward]):void 0})})},b.prototype.checkEmpty=function(){if(l.isEmptyObject(this.waypoints.horizontal)&&l.isEmptyObject(this.waypoints.vertical))return this.$element.unbind([h,p].join(" ")),delete d[this.id]},o=b,e.prototype.trigger=function(e){if(this.enabled)return null!=this.callback&&this.callback.apply(this.element,e),this.options.triggerOnce?this.destroy():void 0},e.prototype.disable=function(){return this.enabled=!1},e.prototype.enable=function(){return this.context.refresh(),this.enabled=!0},e.prototype.destroy=function(){return delete c[this.axis][this.id],delete this.context.waypoints[this.axis][this.id],this.context.checkEmpty()},e.getWaypointsByElement=function(e){var t,n=e[g];return n?(t=l.extend({},c.horizontal,c.vertical),l.map(n,function(e){return t[e]})):[]},s=e,n={init:function(e,i){return null==(i=l.extend({},l.fn[v].defaults,i)).handler&&(i.handler=e),this.each(function(){var e,t,n=l(this),r=null!=(t=i.context)?t:l.fn[v].defaults.context;return l.isWindow(r)||(r=n.closest(r)),r=l(r),e=d[r[0][f]]||new o(r),new s(n,e,i)}),l[y]("refresh"),this},disable:function(){return n._invoke.call(this,"disable")},enable:function(){return n._invoke.call(this,"enable")},destroy:function(){return n._invoke.call(this,"destroy")},prev:function(e,t){return n._traverse.call(this,e,t,function(e,t,n){if(0e.oldScroll.y})},left:function(e){return null==e&&(e=a),u._filter(e,"horizontal",function(e,t){return t.offset<=e.oldScroll.x})},right:function(e){return null==e&&(e=a),u._filter(e,"horizontal",function(e,t){return t.offset>e.oldScroll.x})},enable:function(){return u._invoke("enable")},disable:function(){return u._invoke("disable")},destroy:function(){return u._invoke("destroy")},extendFn:function(e,t){return n[e]=t},_invoke:function(n){var e=l.extend({},c.vertical,c.horizontal);return l.each(e,function(e,t){return t[n](),!0})},_filter:function(e,t,n){var r,i=d[l(e)[0][f]];return i?(r=[],l.each(i.waypoints[t],function(e,t){if(n(i,t))return r.push(t)}),r.sort(function(e,t){return e.offset-t.offset}),l.map(r,function(e){return e.element})):[]}},l[y]=function(){var e=arguments[0],t=2<=arguments.length?x.call(arguments,1):[];return u[e]?u[e].apply(null,t):u.aggregate.call(null,e)},l[y].settings={resizeThrottle:100,scrollThrottle:30},t.on("load.waypoints",function(){return l[y]("refresh")});function e(e,t,n){var r,i;"bottom-in-view"===n.offset&&(n.offset=function(){var e=l[y]("viewportHeight");return l.isWindow(t.element)||(e=t.$element.height()),e-l(this).outerHeight()}),this.$element=e,this.element=e[0],this.axis=n.horizontal?"horizontal":"vertical",this.callback=n.handler,this.context=t,this.enabled=n.enabled,this.id="waypoints"+m++,this.offset=null,this.options=n,t.waypoints[this.axis][this.id]=this,(r=null!=(i=(c[this.axis][this.id]=this).element[g])?i:[]).push(this.id),this.element[g]=r}function b(e){var t=this;this.$element=e,this.element=e[0],this.didResize=!1,this.didScroll=!1,this.id="context"+r++,this.oldScroll={x:e.scrollLeft(),y:e.scrollTop()},this.waypoints={horizontal:{},vertical:{}},this.element[f]=this.id,d[this.id]=this,e.bind(p,function(){var e;if(!t.didScroll&&!i)return t.didScroll=!0,e=function(){return t.doScroll(),t.didScroll=!1},a.setTimeout(e,l[y].settings.scrollThrottle)}),e.bind(h,function(){var e;if(!t.didResize)return t.didResize=!0,e=function(){return l[y]("refresh"),t.didResize=!1},a.setTimeout(e,l[y].settings.resizeThrottle)})}};"function"==typeof define&&define.amd?define("waypoints",["jquery"],function(e){return n(e,t)}):n(t.jQuery,t)}.call(this),define("modules/scroll",["jquery","modules/pubsub"],function(i,e){function t(e){this.options=i.extend({},n,e),this.init()}var r=i("html, body"),n={scrollThrottle:250,scrollDuration:200,context:null,delta:500,location:0,callback:null,template:'"};return t.prototype={init:function(){var n=this,r=!1;n.options.template?(i(window).scroll(function(){r=!0}),setInterval(function(){var e,t;r&&(r=!1,e=window.pageYOffset>n.options.delta,t=i("#back-to-top"),e?t.length?t.show():i("body").append(n.options.template).show():t.length&&t.hide())},n.options.scrollThrottle),i("body").on("click","#back-to-top",function(){n.doScroll(n.options.location)})):n.doScroll(n.options.location),e("scroll/scroll").subscribe(function(e){"function"==typeof e&&e()})},doScroll:function(e){var t=this,n=(isNaN(e),e);r.animate({scrollTop:n},t.options.scrollDuration,function(){"function"==typeof t.options.callback&&t.options.callback()})}},function(e){return new t(e)}}),define("modules/poptart",["jquery","vendor/TweenLite"],function(l,e){function t(e){this.options=l.extend({},n,e),this.container=this.options.container,this.items=this.options.menuItems,this.menuButton=this.options.menuButton,this.targetItem=this.options.targetItem,this.persist=!!this.options.persist||null,this.toggleBtn=this.persist?this.options.persist.toggleBtn:null,this.addPrstElems=this.persist?this.options.persist.addPrstElems:null,this.context=this.options.context?this.options.context:r,this.namespace="click"+this.container,this.namespaceTouch="touchstart"+this.container,this.specialEvents=this.options.specialEvents||!1,this.type=this.options.type||"",this.state={isOpen:!1,currentPop:null,currentTrig:null,firstClickableElem:null},this.init()}var r=l("body"),n={container:null,persist:null};return t.prototype={init:function(){var e=this;e.specialEvents&&(e.context.on("keydown",this.items,l.proxy(e.menuItemKeyDownHandler,e)),e.context.on("keydown",this.menuButton,l.proxy(e.menuButtonKeyDownHandler,e))),e.context.on("click",this.container,l.proxy(e.clickHandler,e))},clickHandler:function(e){if("keyup"!==e.type||13===e.keyCode){var t=this,n=l(e.target),r=n.parents(t.container),i=t.isSame(r),a=this.persist?t.isBtn(n):null;if(n.hasClass("label")&&e.stopPropagation(),t.state.isOpen){if(this.persist&&i&&!a)return;if(t.closeCurrentPop(),i)return void t.toggleOutsideClick("off")}t.state.currentPop=l(e.currentTarget),t.state.currentPop.addClass("open"),t.state.currentTrig=l(e.currentTarget).find("> button"),t.state.currentTrig.attr("aria-expanded","true"),t.state.isOpen=!0,t.toggleOutsideClick("on")}},outsideClickHandler:function(e){var t=l(e.target),n=t.parents(this.container),r=this.isSame(n),i=1<=this.checkPrstElem(t);!this.state.isOpen||r||i||this.closeCurrentPop()},blurHandler:function(){this.state.isOpen=!1,l(this.state.currentPop).removeClass("open");var e=this.state.currentTrig;setTimeout(function(){e.attr("aria-expanded","false"),e.focus()},100),this.state.currentPop=null,this.toggleOutsideClick("off")},toggleOutsideClick:function(e){var n=this;"on"===e?(r.on(n.namespace,l.proxy(n.outsideClickHandler,n)),r.on(n.namespaceTouch,l.proxy(n.outsideClickHandler,n)),r.on("keyup",function(e){var t;if(27===e.keyCode&&(n.blurHandler(),n.state.currentTrig.focus()),9===e.which){if((t=l(e.target).parents()).hasClass("open")||null!==n.persist||n.blurHandler(),t.hasClass("off-canvas-open")&&n.persist)return;!t.hasClass("open")&&n.persist&&n.blurHandler()}})):(r.off(n.namespace),r.off(n.namespaceTouch),r.off("keyup"))},checkPrstElem:function(e){return this.addPrstElems?e.parents(this.addPrstElems).length:0},isSame:function(e){return e.hasClass("open")},isBtn:function(e){return e.is(this.toggleBtn)||e.parents(this.toggleBtn).is(this.toggleBtn)},closeCurrentPop:function(){this.state.isOpen=!1,this.state.currentPop.removeClass("open");var e=this.state.currentTrig;setTimeout(function(){e.attr("aria-expanded","false"),e.focus()},100),this.state.currentPop=null,this.state.currentTrig=null,this.state.firstClickableElem=null,this.toggleOutsideClick("off")},handleUpDownArrows:function(e,t){var n=l(this.container+".open"),r=l(n).find(this.items),i=l(r).find(this.targetItem)[t];i&&i.focus()},getIndexOfItem:function(n){var e=l(this.container+".open"),r=l(e).find(this.items),t=r.map(function(e,t){if((r[e]&&r[e].textContent?r[e].textContent.trim():"").charAt(0).toLowerCase()===n.toLowerCase())return e});return t&&1<=t.length?t[0]:0},menuItemKeyDownHandler:function(e){var t,n,r,i,a,o,s;"keydown"!==e.type||40!==e.keyCode&&38!==e.keyCode&&32!==e.keyCode||(e.preventDefault(),t=e.which||e.keyCode,n=e.currentTarget,r=l(n).parents("ul"),o="filters"===this.type?l(this.container+".open").find("button"):l(r).siblings("button"),40===t&&(i=l(n).next(),a=l(i[0]).find(this.targetItem)[0],0'},this.throttleResize=function(){clearTimeout(n),n=setTimeout(v.proxy(this.navigationEventHandlers,this),200)},this.setXLNav=function(){h||(m.wrap(this.config.stickyTmpl),h=m.parent());var e,t=m[0].getBoundingClientRect();p?(e=v(".site-message")[0].getBoundingClientRect(),g?h.height(t.height+e.height):m.css("overflow","initial")):g?h.height(t.height):m.css("overflow","initial")},this.clearXLNav=function(){h.css("height","auto"),m.attr("style","")},this.init=function(){var n=this,e=v(t).find("#header-wrapper");i.renderUniversalComponent("HeaderWrapper",v(e)[0],{debugMode:!0,propertyId:r}),o.subscribe("xlarge",function(e,t){e?n.setXLNav():n.clearXLNav()}),y("/hide/header").subscribe(function(e){var t=v(".nav-container");e.visible?t.show():t.hide()}),v(window).on("resize",v.proxy(n.throttleResize,n)),this.siteMessageCheck(),setTimeout(function(){n.setXLNav()},0)},this.siteMessageCheck=function(){function t(e){p=!1,r.hide(),m.css({marginTop:"0"}),g&&(h.height(m.outerHeight()),m.hasClass("collapsed-nav")?m.css({top:-r.outerHeight(!0)}):m.css({top:"0"})),"true"!==s&&"click"!==e||(f.messageClosed=!0,localStorage.setObject("siteMessage",f)),y("/update/scroll").publish(),clearInterval(n)}function e(){r.show(),f.msgTime=d,p=!0,localStorage.setObject("siteMessage",f);var e=r.outerHeight(!0);m.css({marginTop:e}),g&&h.height(m.outerHeight()+e),n=setInterval(function(){t()},o)}var n,r=v(".site-message"),i=v(".site-message").find(".msg-close"),a=parseInt(r.attr("data-msg-time")),o=1e3*parseInt(r.attr("data-dismiss-sec")),s=r.attr("data-display-once"),l=localStorage.getObject("siteMessage"),u=!!l&&l.msgTime,c=!!l&&l.messageClosed,d=a,f={};h||(m.wrap(this.config.stickyTmpl),h=m.parent()),i.click(function(){t("click")}),u&&0!==r.length?(u").append(e).html();try{return 3===e[0].nodeType?Nt(t):t.match(/^(<[^>]+>)/)[1].replace(/^<([\w\-]+)/,function(e,t){return"<"+Nt(t)})}catch(e){return Nt(t)}}function v(e){try{return decodeURIComponent(e)}catch(e){}}function y(e){var n,r,i={};return oe((e||"").split("&"),function(e){var t;e&&(n=e.split("="),W(r=v(n[0]))&&(t=!W(n[1])||v(n[1]),i[r]?ce(i[r])?i[r].push(t):i[r]=[i[r],t]:i[r]=t))}),i}function x(e){var n=[];return oe(e,function(e,t){ce(e)?oe(e,function(e){n.push(F(t,!0)+(!0===e?"":"="+F(e,!0)))}):n.push(F(t,!0)+(!0===e?"":"="+F(e,!0)))}),n.length?n.join("&"):""}function I(e){return F(e,!0).replace(/%26/gi,"&").replace(/%3D/gi,"=").replace(/%2B/gi,"+")}function F(e,t){return encodeURIComponent(e).replace(/%40/gi,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,t?"%20":"+")}function P(n,r){function t(){if((n=Wt(n)).injector()){var e=n[0]===ie?"document":me(n);throw Bt("btstrpd","App Already Bootstrapped with this Element '{0}'",e)}(r=r||[]).unshift(["$provide",function(e){e.value("$rootElement",n)}]),r.unshift("ng");var t=xe(r);return t.invoke(["$rootScope","$rootElement","$compile","$injector","$animate",function(e,t,n,r,i){e.$apply(function(){t.data("$injector",r),n(t)(e)})}]),t}var e=/^NG_DEFER_BOOTSTRAP!/;if(f&&!e.test(f.name))return t();f.name=f.name.replace(e,""),Gt.resumeBootstrap=function(e){oe(e,function(e){r.push(e)}),t()}}function ge(e,n){return n=n||"_",e.replace(Qt,function(e,t){return(t?n:"")+e.toLowerCase()})}function ve(e,t,n){if(!e)throw Bt("areq","Argument '{0}' is {1}",t||"?",n||"required");return e}function R(e,t,n){return n&&ce(e)&&(e=e[e.length-1]),ve(de(e),t,"not a function, got "+(e&&"object"==typeof e?e.constructor.name||"Object":typeof e)),e}function N(e,t){if("hasOwnProperty"===e)throw Bt("badname","hasOwnProperty is not a valid {0} name",t)}function j(e,t,n){if(!t)return e;for(var r,i=t.split("."),a=e,o=i.length,s=0;s "+e,t.removeChild(t.firstChild),Q(this,t.childNodes),Wt(ie.createDocumentFragment()).append(this)):Q(this,e)}function ye(e){return e.cloneNode(!0)}function V(e){B(e);for(var t=0,n=e.childNodes||[];t 4096 bytes)!")},a.defer=function(e,t){var n;return h++,n=c(function(){delete f[n],i(e)},t||0),f[n]=!0,n},a.defer.cancel=function(e){return!!f[e]&&(delete f[e],d(e),i(_),!0)}}function _e(){this.$get=["$window","$log","$sniffer","$document",function(e,t,n,r){return new Ce(e,r,t,n)}]}function $e(){this.$get=function(){function e(e,t){function n(e){e!=u&&(c?c==e&&(c=e.n):c=e,r(e.n,e.p),r(e,u),(u=e).n=null)}function r(e,t){e!=t&&(e&&(e.p=t),t&&(t.n=e))}if(e in d)throw D("$cacheFactory")("iid","CacheId '{0}' is already taken!",e);var i=0,a=se({},t,{id:e}),o={},s=t&&t.capacity||Number.MAX_VALUE,l={},u=null,c=null;return d[e]={put:function(e,t){if(s]*)?>/i,T=/^(on[a-z]+|formaction)$/;this.directive=function e(o,t){return N(o,"directive"),ue(o)?(ve(t,"directiveFactory"),h.hasOwnProperty(o)||(h[o]=[],n.factory(o+"Directive",["$injector","$exceptionHandler",function(r,i){var a=[];return oe(h[o],function(e,t){try{var n=r.invoke(e);de(n)?n={compile:M(n)}:!n.compile&&n.link&&(n.compile=M(n.link)),n.priority=n.priority||0,n.index=t,n.name=n.name||o,n.require=n.require||n.controller&&n.name,n.restrict=n.restrict||"A",a.push(n)}catch(e){i(e)}}),a}])),h[o].push(t)):oe(o,p(e)),this},this.aHrefSanitizationWhitelist=function(e){return W(e)?(t.aHrefSanitizationWhitelist(e),this):t.aHrefSanitizationWhitelist()},this.imgSrcSanitizationWhitelist=function(e){return W(e)?(t.imgSrcSanitizationWhitelist(e),this):t.imgSrcSanitizationWhitelist()},this.$get=["$injector","$interpolate","$exceptionHandler","$http","$templateCache","$parse","$controller","$rootScope","$document","$sce","$animate","$$sanitizeUri",function(f,R,N,j,L,W,q,a,e,Y,i,s){function H(s,e,t,n,r){s instanceof Wt||(s=Wt(s)),oe(s,function(e,t){3==e.nodeType&&e.nodeValue.match(/\S+/)&&(s[t]=e=Wt(e).wrap("").parent()[0])});var l=U(s,e,s,t,n,r);return V(s,"ng-scope"),function(e,t,n){ve(e,"scope");var r=t?un.clone.call(s):s;oe(n,function(e,t){r.data("$"+t+"Controller",e)});for(var i=0,a=r.length;il.priority)break;if((f=l.scope)&&(s=s||l,l.templateUrl||(K("new/isolated scope",k,l,g),le(f)&&(k=l))),u=l.name,!l.templateUrl&&l.controller&&(f=l.controller,K("'"+u+"' controller",(D=D||{})[u],l,g),D[u]=l),(f=l.transclude)&&(m=!0,l.$$tlb||(K("transclusion",p,l,g),p=l),T="element"==f?(_=!0,h=l.priority,c=z(v,A,O),g=y.$$element=Wt(ie.createComment(" "+u+": "+y[u]+" ")),v=g[0],ee(n,Wt(pe(c)),v),H(c,t,h,$&&$.name,{nonTlbTranscludeDirective:p})):(c=Wt(ye(v)).contents(),g.empty(),H(c,t))),l.template)if(K("template",C,l,g),f=de((C=l).template)?l.template(g,y):l.template,f=re(f),l.replace){if($=l,c=Q(f),v=c[0],1!=c.length||1!==v.nodeType)throw xn("tplrt","Template for directive '{0}' must have exactly one root element. {1}",u,"");ee(n,g,v);var I={$attr:{}},F=G(v,[],I),P=e.splice(M+1,e.length-(M+1));k&&Z(F),e=e.concat(F).concat(P),J(y,I),E=e.length}else g.html(f);if(l.templateUrl)K("template",C,l,g),(C=l).replace&&($=l),o=function(f,h,p,m,g,v,y,b){var w,x,D=[],k=h[0],C=f.shift(),_=se({},C,{templateUrl:null,transclude:null,replace:null,$$originalDirective:C}),$=de(C.templateUrl)?C.templateUrl(h,p):C.templateUrl;return h.empty(),j.get(Y.getTrustedResourceUrl($),{cache:L}).success(function(e){var n,t,r,i;if(e=re(e),C.replace){if(r=Q(e),n=r[0],1!=r.length||1!==n.nodeType)throw xn("tplrt","Template for directive '{0}' must have exactly one root element. {1}",C.name,$);t={$attr:{}},ee(m,h,n);var a=G(n,[],t);le(C.scope)&&Z(a),f=a.concat(f),J(p,t)}else n=k,h.html(e);for(f.unshift(_),w=S(f,n,p,g,h,C,v,y,b),oe(m,function(e,t){e==n&&(m[t]=h[0])}),x=U(h[0].childNodes,g);D.length;){var o,s=D.shift(),l=D.shift(),u=D.shift(),c=D.shift(),d=h[0];l!==k&&(o=l.className,b.hasElementTranscludeDirective&&C.replace||(d=ye(n)),ee(u,Wt(l),d),V(Wt(d),o)),i=w.transclude?B(s,w.transclude):c,w(x,s,d,m,i)}D=null}).error(function(e,t,n,r){throw xn("tpload","Failed to load template: {0}",r.url)}),function(e,t,n,r,i){D?(D.push(t),D.push(n),D.push(r),D.push(i)):w(x,t,n,r,i)}}(e.splice(M,e.length-M),g,y,n,T,b,w,{controllerDirectives:D,newIsolateScopeDirective:k,templateDirective:C,nonTlbTranscludeDirective:p}),E=e.length;else if(l.compile)try{de(d=l.compile(g,y,T))?a(null,d,A,O):d&&a(d.pre,d.post,A,O)}catch(e){N(e,me(g))}l.terminal&&(o.terminal=!0,h=Math.max(h,l.priority))}return o.scope=s&&!0===s.scope,o.transclude=m&&T,i.hasElementTranscludeDirective=_,o}(o,e[d],a,m,t,null,[],[],i):null)&&s.scope&&V(Wt(e[d]),"ng-scope"),u=s&&s.terminal||!(l=e[d].childNodes)||!l.length?null:U(l,s?s.transclude:m),g.push(s,u),c=c||s||u,i=null;return c?function(e,t,n,r){for(var i,a,o,s,l,u,c,d,f=t.length,h=new Array(f),p=0;pl.priority)&&-1!=l.restrict.indexOf(n)&&(a&&(l=m(l,{$$start:a,$$end:o})),e.push(l),s=l)}catch(e){N(e)}return s}}function J(n,r){var i=r.$attr,a=n.$attr,o=n.$$element;oe(n,function(e,t){"$"!=t.charAt(0)&&(r[t]&&(e+=("style"===t?";":" ")+r[t]),n.$set(t,e,!0,i[t]))}),oe(r,function(e,t){"class"==t?(V(o,e),n.class=(n.class?n.class+" ":"")+e):"style"==t?(o.attr("style",o.attr("style")+";"+e),n.style=(n.style?n.style+";":"")+e):"$"==t.charAt(0)||n.hasOwnProperty(t)||(n[t]=e,a[t]=i[t])})}function Q(e){var t;if(e=Zt(e),t=o.exec(e)){t=t[1].toLowerCase();var n=Wt(""),r=n.children("tbody"),i=/(td|th)/.test(t)&&n.find("tr");return r.length&&"tbody"!==t&&(n=r),i&&i.length&&(n=i),n.contents()}return Wt(""+e+"
").contents()}function C(e,t){var n=t.priority-e.priority;return 0!=n?n:e.name!==t.name?e.name to the top of your HTML document. See http://docs.angularjs.org/api/ng.$sce for more information.");var i=S(Rn);i.isEnabled=function(){return s},i.trustAs=n.trustAs,i.getTrusted=n.getTrusted,i.valueOf=n.valueOf,s||(i.trustAs=i.getTrusted=function(e,t){return t},i.valueOf=u),i.parseAs=function(n,e){var r=t(e);return r.literal&&r.constant?r:function(e,t){return i.getTrusted(n,r(e,t))}};var r=i.parseAs,a=i.getTrusted,o=i.trustAs;return oe(Rn,function(t,e){var n=Nt(e);i[Y("parse_as_"+n)]=function(e){return r(t,e)},i[Y("get_trusted_"+n)]=function(e){return a(t,e)},i[Y("trust_as_"+n)]=function(e){return o(t,e)}}),i}]}function mt(){this.$get=["$window","$document",function(e,t){var n,r,i={},a=b((/android (\d+)/.exec(Nt((e.navigator||{}).userAgent))||[])[1]),o=/Boxee/i.test((e.navigator||{}).userAgent),s=t[0]||{},l=s.documentMode,u=/^(Moz|webkit|O|ms)(?=[A-Z])/,c=s.body&&s.body.style,d=!1,f=!1;if(c){for(var h in c)if(r=u.exec(h)){n=(n=r[0]).substr(0,1).toUpperCase()+n.substr(1);break}n=n||"WebkitOpacity"in c&&"webkit",d="transition"in c||n+"Transition"in c,f="animation"in c||n+"Animation"in c,!a||d&&f||(d=ue(s.body.style.webkitTransition),f=ue(s.body.style.webkitAnimation))}return{history:!(!e.history||!e.history.pushState||a<4||o),hashchange:"onhashchange"in e&&(!l||7i+1?s="0":(l=s,c=!0)),c)0=v+y)for(g=p.length-v,f=0;fe.length?t=e.length:t<-e.length&&(t=-e.length),r=0=p,e)},i.$parsers.push(m),i.$formatters.push(m)),t.ngMaxlength&&(g=b(t.ngMaxlength),v=function(e){return Ft(i,"maxlength",i.$isEmpty(e)||e.length<=g,e)},i.$parsers.push(v),i.$formatters.push(v))}function Rt(s,l){return s="ngClass"+s,function(){return{restrict:"AC",link:function(i,e,a){function t(e){var t;!0!==l&&i.$index%2!==l||(t=o(e||""),n?he(e,n)||a.$updateClass(t,o(n)):a.$addClass(t)),n=S(e)}function o(e){if(ce(e))return e.join(" ");if(le(e)){var n=[];return oe(e,function(e,t){e&&n.push(t)}),n.join(" ")}return e}var n;i.$watch(a[s],t,!0),a.$observe("class",function(e){t(i.$eval(a[s]))}),"ngClass"!==s&&i.$watch("$index",function(e,t){var n,r=1&e;r!==t&1&&(n=o(i.$eval(a[s])),r===l?a.$addClass(n):a.$removeClass(n))})}}}}var Nt=function(e){return ue(e)?e.toLowerCase():e},jt=Object.prototype.hasOwnProperty,Lt=function(e){return ue(e)?e.toUpperCase():e};"i"!=="I".toLowerCase()&&(Nt=function(e){return ue(e)?e.replace(/[A-Z]/g,function(e){return String.fromCharCode(32|e.charCodeAt(0))}):e},Lt=function(e){return ue(e)?e.replace(/[a-z]/g,function(e){return String.fromCharCode(-33&e.charCodeAt(0))}):e});var Wt,qt,Yt,Ht=[].slice,Vt=[].push,Ut=Object.prototype.toString,Bt=D("ng"),Gt=(f.angular,f.angular||(f.angular={})),zt=["0","0","0"],Xt=b((/msie (\d+)/.exec(Nt(navigator.userAgent))||[])[1]);isNaN(Xt)&&(Xt=b((/trident\/.*; rv:(\d+)/.exec(Nt(navigator.userAgent))||[])[1])),_.$inject=[],u.$inject=[];var Zt=String.prototype.trim?function(e){return ue(e)?e.trim():e}:function(e){return ue(e)?e.replace(/^\s\s*/,"").replace(/\s\s*$/,""):e},Jt=Xt<9?function(e){return(e=e.nodeName?e:e[0]).scopeName&&"HTML"!=e.scopeName?Lt(e.scopeName+":"+e.nodeName):e.nodeName}:function(e){return e.nodeName?e.nodeName:e[0].nodeName},Qt=/[A-Z]/g,Kt={full:"1.2.14",major:1,minor:2,dot:14,codeName:"feisty-cryokinesis"},en=H.cache={},tn=H.expando="ng-"+(new Date).getTime(),nn=1,rn=f.document.addEventListener?function(e,t,n){e.addEventListener(t,n,!1)}:function(e,t,n){e.attachEvent("on"+t,n)},an=f.document.removeEventListener?function(e,t,n){e.removeEventListener(t,n,!1)}:function(e,t,n){e.detachEvent("on"+t,n)},on=(H._data=function(e){return this.cache[e[this.expando]]||{}},/([\:\-\_]+(.))/g),sn=/^moz([A-Z])/,ln=D("jqLite"),un=H.prototype={ready:function(e){function t(){n||(n=!0,e())}var n=!1;"complete"===ie.readyState?setTimeout(t):(this.on("DOMContentLoaded",t),H(f).on("load",t))},toString:function(){var t=[];return oe(this,function(e){t.push(""+e)}),"["+t.join(", ")+"]"},eq:function(e){return Wt(0<=e?this[e]:this[this.length+e])},length:0,push:Vt,sort:[].sort,splice:[].splice},cn={};oe("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(e){cn[Nt(e)]=e});var dn,fn={};function hn(e,t){var n=dn[e.nodeType];if($(t))return n?e[n]:"";e[n]=t}oe("input,select,option,textarea,button,form,details".split(","),function(e){fn[Lt(e)]=!0}),oe({data:z,inheritedData:ee,scope:function(e){return Wt(e).data("$scope")||ee(e.parentNode||e,["$isolateScope","$scope"])},isolateScope:function(e){return Wt(e).data("$isolateScope")||Wt(e).data("$isolateScopeNoTemplate")},controller:K,injector:function(e){return ee(e,"$injector")},removeAttr:function(e,t){e.removeAttribute(t)},hasClass:X,css:function(e,t,n){var r;if(t=Y(t),!W(n))return Xt<=8&&""===(r=e.currentStyle&&e.currentStyle[t])&&(r="auto"),r=r||e.style[t],Xt<=8&&(r=""===r?ae:r),r;e.style[t]=n},attr:function(e,t,n){var r=Nt(t);if(cn[r]){if(!W(n))return e[t]||(e.attributes.getNamedItem(t)||_).specified?r:ae;n?(e[t]=!0,e.setAttribute(t,r)):(e[t]=!1,e.removeAttribute(r))}else if(W(n))e.setAttribute(t,n);else if(e.getAttribute){var i=e.getAttribute(t,2);return null===i?ae:i}},prop:function(e,t,n){if(!W(n))return e[t];e[t]=n},text:(dn=[],Xt<9?(dn[1]="innerText",dn[3]="nodeValue"):dn[1]=dn[3]="textContent",hn.$dv="",hn),val:function(e,t){if($(t)){if("SELECT"===Jt(e)&&e.multiple){var n=[];return oe(e.options,function(e){e.selected&&n.push(e.value||e.text)}),0===n.length?null:n}return e.value}e.value=t},html:function(e,t){if($(t))return e.innerHTML;for(var n=0,r=e.childNodes;n":function(e,t,n,r){return n(e,t)>r(e,t)},"<=":function(e,t,n,r){return n(e,t)<=r(e,t)},">=":function(e,t,n,r){return n(e,t)>=r(e,t)},"&&":function(e,t,n,r){return n(e,t)&&r(e,t)},"||":function(e,t,n,r){return n(e,t)||r(e,t)},"&":function(e,t,n,r){return n(e,t)&r(e,t)},"|":function(e,t,n,r){return r(e,t)(e,t,n(e,t))},"!":function(e,t,n){return!n(e,t)}},On={n:"\n",f:"\f",r:"\r",t:"\t",v:"\v","'":"'",'"':'"'};Sn.prototype={constructor:Sn,lex:function(e){this.text=e,this.index=0,this.ch=ae,this.lastCh=":",this.tokens=[];for(var t,n=[];this.index","<=",">="))&&(t=this.binaryFn(t,e.fn,this.relational())),t},additive:function(){for(var e,t=this.multiplicative();e=this.expect("+","-");)t=this.binaryFn(t,e.fn,this.multiplicative());return t},multiplicative:function(){for(var e,t=this.unary();e=this.expect("*","/","%");)t=this.binaryFn(t,e.fn,this.unary());return t},unary:function(){var e;return this.expect("+")?this.primary():(e=this.expect("-"))?this.binaryFn(In.ZERO,e.fn,this.unary()):(e=this.expect("!"))?this.unaryFn(e.fn,this.unary()):this.primary()},fieldAccess:function(r){var i=this,a=this.expect().text,o=ot(a,this.options,this.text);return se(function(e,t,n){return o(n||r(e,t))},{assign:function(e,t,n){return it(r(e,n),a,t,i.text,i.options)}})},objectIndex:function(o){var s=this,l=this.expression();return this.consume("]"),se(function(e,t){var n,r,i=o(e,t),a=l(e,t);return i?((n=rt(i[a],s.text))&&n.then&&s.options.unwrapPromises&&("$$v"in(r=n)||(r.$$v=ae,r.then(function(e){r.$$v=e})),n=n.$$v),n):ae},{assign:function(e,t,n){var r=l(e,n);return rt(o(e,n),s.text)[r]=t}})},functionCall:function(o,s){var l=[];if(")"!==this.peekToken().text)for(;l.push(this.expression()),this.expect(","););this.consume(")");var u=this;return function(e,t){for(var n=[],r=s?s(e,t):e,i=0;ic;)i.pop().element.remove()}for(;F.length>u;)F.pop()[0].element.remove()}var t;if(!(t=m.match(D)))throw Nr("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",m,me(_));var S=x(t[2]||t[1]),T=t[4]||t[6],M=t[5],E=x(t[3]||""),A=x(t[2]?t[1]:T),O=x(t[7]),I=t[8]?x(t[8]):null,F=[[{element:_,label:""}]];R&&(w(R)(C),R.removeClass("ng-scope"),R.remove()),_.empty(),_.on("change",function(){C.$apply(function(){var e,t,n,r,i,a,o,s,l,u=O(C)||[],c={};if(P){for(n=[],a=0,s=F.length;a@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide{display:none !important;}ng\\:form{display:block;}.ng-animate-block-transitions{transition:0s all!important;-webkit-transition:0s all!important;}'),function(t,H,y){H.module("ngAnimate",["ng"]).factory("$$animateReflow",["$$rAF","$document",function(t,e){var n=e[0].body;return function(e){return t(function(){n.offsetWidth,e()})}}]).config(["$provide","$animateProvider",function(e,n){function W(e){for(var t=0;t=g&&p<=r&&a()}var t=W(r),n=r.data(E);if(-1!=t.getAttribute("class").indexOf(i)&&n){var s="";Y(i.split(" "),function(e,t){s+=(0V(e)?(a=e+1,o-V(e)):(a=e,o);return{year:a,dayOfYear:s}}function X(e,t,n){var r,i,a=G(e.year(),t,n),o=Math.floor((e.dayOfYear()-a-1)/7)+1;return o<1?r=o+Z(i=e.year()-1,t,n):o>Z(e.year(),t,n)?(r=o-Z(e.year(),t,n),i=e.year()+1):(i=e.year(),r=o),{week:r,year:i}}function Z(e,t,n){var r=G(e,t,n),i=G(e+1,t,n);return(V(e)-r+i)/7}function J(){function e(e,t){return t.length-e.length}for(var t,n,r,i,a=[],o=[],s=[],l=[],u=0;u<7;u++)t=p([2e3,1]).day(u),n=this.weekdaysMin(t,""),r=this.weekdaysShort(t,""),i=this.weekdays(t,""),a.push(n),o.push(r),s.push(i),l.push(n),l.push(r),l.push(i);for(a.sort(e),o.sort(e),s.sort(e),l.sort(e),u=0;u<7;u++)o[u]=N(o[u]),s[u]=N(s[u]),l[u]=N(l[u]);this._weekdaysRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+o.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function Q(){return this.hours()%12||12}function K(e,t){I(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function ee(e,t){return t._meridiemParse}function te(e){return e?e.toLowerCase().replace("_","-"):e}function ne(e){var t;if(!Ut[e]&&"undefined"!=typeof module&&module&&module.exports)try{t=Yt._abbr,require("./locale/"+e),re(t)}catch(e){}return Ut[e]}function re(e,t){var n;return e&&(n=a(t)?ae(e):ie(e,t))&&(Yt=n),Yt._abbr}function ie(e,t){if(null===t)return delete Ut[e],null;var n=Vt;if(t.abbr=e,null!=Ut[e])_("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),n=Ut[e]._config;else if(null!=t.parentLocale){if(null==Ut[t.parentLocale])return Bt[t.parentLocale]||(Bt[t.parentLocale]=[]),Bt[t.parentLocale].push({name:e,config:t}),null;n=Ut[t.parentLocale]._config}return Ut[e]=new S(i(n,t)),Bt[e]&&Bt[e].forEach(function(e){ie(e.name,e.config)}),re(e),Ut[e]}function ae(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return Yt;if(!u(e)){if(t=ne(e))return t;e=[e]}return function(e){for(var t,n,r,i,a=0;a=t&&o(i,n,!0)>=t-1)break;t--}a++}return null}(e)}function oe(e){var t,n=e._a;return n&&-2===w(e).overflow&&(t=n[xt]<0||11W(n[wt],n[xt])?Dt:n[kt]<0||24Z(u,f,h)?w(s)._overflowWeeks=!0:null!=m?w(s)._overflowWeekday=!0:(p=z(u,c,d,f,h),s._a[wt]=p.year,s._dayOfYear=p.dayOfYear)),e._dayOfYear&&(i=le(e._a[wt],r[wt]),e._dayOfYear>V(i)&&(w(e)._overflowDayOfYear=!0),n=B(i,0,e._dayOfYear),e._a[xt]=n.getUTCMonth(),e._a[Dt]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=v[t]=r[t];for(;t<7;t++)e._a[t]=v[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[kt]&&0===e._a[Ct]&&0===e._a[_t]&&0===e._a[$t]&&(e._nextDay=!0,e._a[kt]=0),e._d=(e._useUTC?B:function(e,t,n,r,i,a,o){var s=new Date(e,t,n,r,i,a,o);return e<100&&0<=e&&isFinite(s.getFullYear())&&s.setFullYear(e),s}).apply(null,v),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[kt]=24)}}function ce(e){if(e._f===y.ISO_8601)return se(e),0;e._a=[],w(e).empty=!0;for(var t,n,r,i,a,o,s,l,u,c,d,f,h=""+e._i,p=h.length,m=0,g=P(e._f,e._locale).match(Qe)||[],v=0;v>>0,r=0;rn.valueOf():n.valueOf()this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},hn.isLocal=function(){return!!this.isValid()&&!this._isUTC},hn.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},hn.isUtc=De,hn.isUTC=De,hn.zoneAbbr=function(){return this._isUTC?"UTC":""},hn.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},hn.dates=e("dates accessor is deprecated. Use date instead.",ln),hn.months=e("months accessor is deprecated. Use month instead",Y),hn.years=e("years accessor is deprecated. Use year instead",Pt),hn.zone=e("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()}),hn.isDSTShifted=e("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",function(){if(!a(this._isDSTShifted))return this._isDSTShifted;var e,t={};return v(t,this),(t=de(t))._a?(e=(t._isUTC?p:he)(t._a),this._isDSTShifted=this.isValid()&&0>>1;n(e[o])/g,evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,variable:""},Se||(v=function(e){var t;return _(e)&&(Ne.prototype=e,t=new Ne,Ne.prototype=null),t||fe.Object()}),y(arguments)||(y=function(e){return e&&"object"==typeof e&&"number"==typeof e.length&&Ce.call(e,"callee")&&!$e.call(e,"callee")||!1});var je=Te||function(e){return e&&"object"==typeof e&&"number"==typeof e.length&&we.call(e)==ie||!1},Le=Ae?function(e){return _(e)?Ae(e):[]}:function(e){var t,n=e,r=[];if(!n)return r;if(!ce[typeof e])return r;for(t in n)Ce.call(n,t)&&r.push(t);return r},We={"&":"&","<":"<",">":">",'"':""","'":"'"},qe=D(We),Ye=RegExp("("+Le(qe).join("|")+")","g"),He=RegExp("["+Le(We).join("")+"]","g"),Ve=function(e,t){var n,r=e,i=r;if(!r)return i;if(!ce[typeof r])return i;for(n in r)if(t(r[n],n,e)===K)return i;return i},Ue=function(e,t){var n,r=e,i=r;if(!r)return i;if(!ce[typeof r])return i;for(n in r)if(Ce.call(r,n)&&t(r[n],n,e)===K)return i;return i};C(/x/)&&(C=function(e){return"function"==typeof e&&"[object Function]"==we.call(e)});var Be=e(function(e,t,n){Ce.call(e,n)?e[n]++:e[n]=1}),Ge=e(function(e,t,n){(Ce.call(e,n)?e[n]:e[n]=[]).push(t)}),ze=e(function(e,t,n){e[n]=t}),Xe=F,Ze=n(Ze=Date.now)&&Ze||function(){return(new Date).getTime()};m.after=function(e,t){if(!C(t))throw new TypeError;return function(){if(--e<1)return t.apply(this,arguments)}},m.bind=B,m.bindAll=function(e){for(var t=1r&&(e=(n=(n=e.substr(0,r)).substr(0,Math.min(n.length,n.lastIndexOf(" "))))+"..."),i.trustAsHtml(e)}}])}),define("services/form-utility-service",["vendor/angular-custom"],function(e){return e.module("formUtility.service",[]).factory("formUtility",function(){return this.util={},this.util.isCnByEmail=function(e){var t=e&&0<=e.indexOf("@")?e.replace(/.*@/,""):"";return"CA"===(t&&t.split(".")[1]?t.split(".")[1]:"").toUpperCase()},this.util.fieldSerialize=function(e,t){var r=String(t).split(",").map(function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")});return String(e).split("&").map(function(e){var t=e.substring(0,e.indexOf("=")),n=e.substring(e.indexOf("=")+1,e.length);return t&&n&&-1!==r.indexOf(t)&&(e=t+"="+n),e}).join("&")},this.util.getCountryCode=function(e,t){var n=t?Object.keys(t):[],r=e.get("country-code");return r&&~n.indexOf(r.trim().toUpperCase())?r.trim().toUpperCase():"US"},this.util.verifyEmail=function(e){return/^((([a-z]|\d|[!#\$'\*\+\-\/\?\_\]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$'\*\+\-\/=\?\_\]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?$/i.test(e.trim())},this.util})}),define("controllers/sign-in-widget-controller",["jquery","modules/pubsub","modules/cookies","vendor/angular-custom","factories/json-factory","factories/log-out","modules/validate","modules/getuserdetails","filters/custom-filters","modules/global-vps","modules/canvas","modules/error-handling","services/form-utility-service"],function(A,O,I,e,t,n,r,F,i,P,R,N,a){return e.module("SignInWidget.controllers",["JsonFactory","LogOut","Custom.filters","formUtility.service"]).controller("SignInWidgetController",["$scope","$rootScope","$window","$parse","$location","json","logout","$filter","formUtility",function(c,t,d,e,s,a,n,l,r){function i(){c.authenticated=F.isAuthView(),f()}function f(){var e=c.$root.$$phase;"$apply"!==e&&"$digest"!==e&&c.$apply()}var o,u,h,p,m=A("#signin-widget-form"),g=MGMRI.services.accounts.signIn,v=m.find('button[type="submit"]').attr("data-redirect"),y=m.attr("data-cookie-names")?m.attr("data-cookie-names").split(","):[],b=(I.get(y[0]),MGMRI.data.navigation.widget.mlifeSignIn),w=MGMRI.data&&MGMRI.data.accounts&&MGMRI.data.accounts.redirectToAccountPage||!1,x=!1,D=!1,k=R();c.remWidget=!1;function C(e,t){var n,r,i,a,o=!(!MGMRI.data.booking||!MGMRI.data.booking.bookAll);!1!==(u=N.checkErrors(e,t,"",!0))?(u._existing_patron_profile&&sessionStorage.setItem("email",c.eId),c.errDiv=u,A.each(u,function(e,t){E(e,"response")})):"object"==typeof e&&(r=d.location.origin+MGMRI.data.urls.accounts.profile,i=s.search(),e.response&&(I.get(y[0]),"undefined"!=typeof _satellite&&_satellite.track("successfulLogin"),n=MGMRI.OKTA&&MGMRI.OKTA.loginSessionCookie?MGMRI.OKTA.loginSessionCookie.replace("{sessionToken}",e.response.cookieToken):"",o&&sessionStorage.setItem("step3LogIn","true"),A(".confirmation-section-container").length&&(p=d.location.origin+MGMRI.data.booking.itinerary),i.errorCode&&(window.location.hash,a=(-1parseInt(f.depart.year,10),l=n>parseInt(f.depart.num,10)&&t===parseInt(f.depart.year,10),u=r>parseInt(f.depart.date,10)&&n===parseInt(f.depart.num,10);if(s||l||u)return;f.flow&&"ticketing"===f.flow||f.displayCheckInDate||(c.defaultSelect=!0,c.currentState="selected",h(d).hasClass("offer")&&(f.roomOfferSelectedCounter++,f.roomOfferSelectedCounter+1>=f.offer.minimumDays?f.offerCheckValid=!0:f.offer&&"segment"!==f.offer.offerType&&(f.offerCheckValid=!1)),f.minNightsOffer&&!h(d).hasClass("sold-out")&&(f.offerCheckValid=!0))}}})}}}])}),define("controllers/calendar-controller",["jquery","modules/calendar-date-conversion","modules/canvas","modules/global-vps","vendor/moment.min","modules/in-view","modules/pubsub","directives/calendar-directive","services/model-service","vendor/angular-custom"],function(W,q,Y,H,V,U,B,e,t,G){return G.module("Calendar.controllers",["Calendar.directive","Model.service"]).controller("CalendarController",["$scope","$http","model","$element","$timeout",function(y,e,b,g,w){function x(e){for(var t in e)if(e.hasOwnProperty(t))return;return 1}function t(){var e,t,n,r,i,a;E=!(A=[]),y.offer=null,y.length=0,y.initDates={found:!1,record:!1,defaultArray:[]},y.allResults=b,y.length=b.calendar.length,y.max=T,!x(b.offer)&&b.offer.minimumDays&&(y.min=parseInt(b.offer.minimumDays,10)),b.arrive?b.depart||"range"!==b.calendarSelectType||(b.arrive=q(b.request.checkInDate,MGMRI.data.date.day,MGMRI.data.date.month),b.depart=q(b.request.checkOutDate,MGMRI.data.date.day,MGMRI.data.date.month),$()):(b.arrive=q(b.request.checkInDate,MGMRI.data.date.day,MGMRI.data.date.month),b.depart=q(b.request.checkOutDate,MGMRI.data.date.day,MGMRI.data.date.month),y.currentDate=b.arrive,$()),"range"===b.calendarSelectType?(y.months=b.calendar,e=parseInt(y.allResults.calendar[0].num,10),t=parseInt(y.allResults.calendar[0].year,10),n=parseInt(b.depart.num,10),r=parseInt(b.depart.year,10),i=n-e,a=W.noop,t!==r?i=12-e+1+n:i>=y.limit&&(y.limit=i+1),o(),a(),o()):(y.limit=4,y.months=y.allResults.calendar),o()}function r(e,t,n){var r=W('td[data-complete-date="'+e.num+"/"+e.date+"/"+e.year+'"]');n?(f=f||r).trigger(t):(h=h||r).trigger(t)}function D(e,t,n,r,i,a){var o,s=b.arrive.num||0;b.flow&&"ticketing"===b.flow?(b.selectedDate.year=t,b.selectedDate.month=n,b.selectedDate.num=r.toString(),b.selectedDate.date=i.toString(),b.selectedDate.weekday=a,b.selectedStringDates=[],b.selectedStringDates[0]=b.selectedDate.num+"/"+b.selectedDate.date+"/"+b.selectedDate.year):b.arrive={year:t,month:n,num:r.toString(),date:i.toString(),weekday:a},"range"===b.calendarSelectType&&(b.calendarSession.arrive=W.extend(!0,{},b.arrive)),(s!==n?l:u)(e),(o=e.closest(j.date)).addClass("selected"),"room"!==b.flow||o.find("state-close").length||(o.addClass("state-active"),o.find("button").after('')),B("calendar/selected/arrive").publish(e),B("booking/sidebar/select/arrive").publish(),S("arrive")}function l(e){var t=(t=(s=e.closest(j.calendar)).next().next(j.calendar)).find(j.dateNonBlank);s="amenities"===b.flow||"filterDateRange"===b.calendarView?W(j.calendar).find(j.dateNonBlank):W.merge(s.find(j.dateNonBlank),t),u(e)}function u(e){var t,n,r=e.closest(j.date);T=MGMRI.data.calendar.maxNights||14,n=(t=s.index(r))+T+1,"ticketing"===b.flow&&(n=t+c),A="amenities"===b.flow||"filterDateRange"===b.calendarView?s.slice(t,s.length):s.slice(t,n),b.flow&&"ticketing"===b.flow&&"2"===b.step||(b.nextDefaultDay=W(A[1]))}function k(e){e?(A.addClass("selected"),"room"===b.flow&&(A.removeClass("state-active"),A.find(".state-close").remove(),W("#calendar").find(".between-date").removeClass("between-date"))):0=a,i=A.length<=(MGMRI.data.calendar.maxNights+1||15),x(b.offer))R=!(r=!0);else if(!0===n&&b.offer.minimumDays&&"room"===b.flow){for(var d=0;d .trip-dates");e&&e.is(":visible")&&e.focus()},10));"arrive"===c||"max-invalid"===c?d=(d=I.max).replace("{num}",y.max):"sold-out"===c||"range-sold-out"===c&&v?(d=I.out,b.offerCheckValid=!1,P=!1):"no-arrival"===c?d=I.arrive:"invalid-offer-dates"===c&&(d=I.offerInvalidDates),_(e,d),C(),B("booking/calendar/offerWarning").publish(P)}else{if("sold-out"!==o)return k(!1),D(g,t,n,r,i,a),void(b.errorShowing&&_(e));_(e,I.out)}else D(g,t,n,r,i,a),b.offerCheckValid=!1,!b.depart.year&&b.calendarSession.depart&&(b.calendarSession.depart.num=b.nextDefaultDay.attr("data-month"),b.calendarSession.depart.month=MGMRI.data.date.month[b.calendarSession.depart.num],b.calendarSession.depart.date=b.nextDefaultDay.attr("data-date"),b.calendarSession.depart.year=b.nextDefaultDay.attr("data-year"),b.calendarSession.depart.weekday=b.nextDefaultDay.attr("data-weekday")),b.errorShowing&&_(e);else B("booking/calendar/dining/error").publish(o),_(e,I.unavailable);else _(e,I.arrive);else _(e,I.out),b.offerCheckValid=!1}},B("booking/calendar/minNightMessage").subscribe(function(){b.filters.bookingRefresh&&B("booking/calendar/offerWarning").publish(!0)}),y.calendarMouseEnter=function(e,t,n,r,i,a,o,s){var l,u,c,d,f,h,p,m=b.arrive;if(b.arrive.year&&"room"===b.flow&&!("room"===b.flow&&b.depart.year||"available"!==o&&"offer"!==o&&"no-arrival"!==o||parseInt(t)<=parseInt(b.arrive.year)&&parseInt(r)<=parseInt(b.arrive.num)&&parseInt(i)=b.calendar.length?d.removeEvent():(y.limit+=2,o())})).load(),void 0===b.calendar?"2"!==b.step&&(b.isShowV2?B("booking/json/request").publish("availability",b.filters):B("booking/json/request").publish("calendar",b.filters)):("dining"===b.calendarView?(b.calendarSelectType="single",b.arrive=q(b.arrive,MGMRI.data.date.day,MGMRI.data.date.month),y.legend.soldOut=MGMRI.data.dining.soldOut):"request"===b.calendarView?T=31*parseInt(MGMRI.data.dateRangeOffCanvas.calendarMonthsLimit,10):"filterDateRange"===b.calendarView?(b.calendarSelectType="range",y.legend.soldOut=""):""===b.calendarView?(b.calendarSelectType="range",y.legend.soldOut=MGMRI.data.booking.room.soldOut):void 0===b.calendarView&&H.is("small")&&"room"===b.flow&&"1"===b.step&&w(function(){p=W(".calendar #c-"+b.arrive.date+"-"+b.arrive.num+"-"+b.arrive.year),m=W(".calendar #c-"+b.depart.date+"-"+b.depart.num+"-"+b.depart.year),p.length&&m.length&&!b.filters.bookingRefresh&&(p.trigger("click"),b.displayCheckInDate||W(m).trigger("click"))}),t(),o()),b.calendarInit=!0,W(document.body).on({mouseenter:function(e){var t;e.stopImmediatePropagation(),"room"!==b.flow||""===v||!H.is("large")&&!H.is("xlarge")||!W(this).hasClass("between-date")||W(this).hasClass("blank")||W(this).hasClass("past-date")||(t=W(this).find(".date-rate"),W.data(this,"spanText",t.text()),t.css("fontSize","12px").text(v))},mouseleave:function(e){var t,n;e.stopImmediatePropagation(),"room"===b.flow&&(H.is("large")||H.is("xlarge"))&&(t=W.data(this,"spanText"),n=W(this).find(".date-rate").text(),t!==v&&""!==t&&(W(this).find(".date-rate").text(t).css("fontSize","17.9px"),W.data(this,"spanText","")),n===v&&W(this).find(".date-rate").text(t).css("fontSize","17.9px"))},touchstart:function(e){L=!0}},"#calendar .date-wrapper"),W(document.body).on("click","#calendar .state-active .state-close",function(e){B("booking/calendar/restore/dates").publish(),B("booking/calendar/state/close").publish()})}])}),define("modules/calendar-json-conversion",[],function(){var a,o,s,l,u,c,d=0,f="price",h="pricePts",r={init:function(e){var t={calendar:[]};a=e,o=MGMRI.data.date.day,s=MGMRI.data.date.month,c&&(f="memberPrice",h="memberPricePts");var n=a[0].date.split("/"),r=new Date(n[2],n[0]-1,n[1]),i=parseInt(n[1],10);return l=r.getDay(),1s.getMonth()&&i.getDate()>s.getDate()&&(l=i.getFullYear+1),e.trigger("input"),d(function(){var n,e=c,t=1+a,r=o,i=l;(n=he(H).find(".month[data-month="+t+"]").next().find("[data-date="+r+"]"))&&1ue&&(h.errorShowing=!0,h.error=oe.max,h.arrive=null,h.depart=null,o=!1,E()),o?(e.date&&e.date.isBefore(n.date)?(r=xe.copy(n),n=e):r=e,b.calendarCheckInCheckOutLabel=String(n.date.format("MMM DD, YYYY"))+" - "+String(r.date.format("MMM DD, YYYY")),b.calendarCheckInCheckOutLabelSmall=String(n.date.format("MMM DD"))+" - "+String(r.date.format("MMM DD")),b.calendarCheckInDate=String(n.date.format("MMM DD")),b.calendarCheckOutDate=String(r.date.format("MMM DD")),m({arrive:n,depart:r,checkInDate:n.date.format(ce),checkOutDate:r.date.format(ce)}),b.bookingWidgetPop=!1,ge.is("small")&&Q.closeCanvas()):m({arrive:null,depart:null}),he(".booking-widget-dropdown.duration-dropdown").attr("role","listbox"),_(he(".booking-widget-dropdown-button.travel-date-selector"))),b.firstClick=!b.firstClick))},b.inSelectedMode=function(e){var t=!1,n=h.bookingWidgetData.arrive,r=h.bookingWidgetData.depart;return(n&&n.date&&e.date.isSame(n.date)||r&&r.date&&e.date.isSame(r.date)||n&&n.date&&r&&r.date&&e.date.isBetween(n.date,r.date))&&(t=!0),t},b.handleMonthsDisplay=function(e){var t,n;"selection"===e&&(t=we(),n=we(b.selected),b.miniCalendarMonthStart=b.selected?Math.floor(n.diff(t,"months",!0)):b.miniCalendarMonthStart,b.miniCalendarMonthEnd=parseInt(b.miniCalendarMonthStart+1)),(-2<=e||e<=2)&&(b.miniCalendarMonthStart+=e,b.miniCalendarMonthEnd+=e),b.miniCalendarMonthStart<0&&(b.miniCalendarMonthStart=0,b.miniCalendarMonthEnd=1),u(),b.showCalendar=!0,b.showAllDate=!1,b.disablePrevious=b.miniCalendarMonthStart<1,b.disableNext=b.miniCalendarMonthEnd+1>=b.calendarMaxMonths+1,E()},b.getDropdownOpen=function(e,t){var n,r,i,p;!1!==$(e)&&("duration"===t&&((n=he(".booking-widget-dropdown.duration-dropdown")).attr("role","menu"),r=n,h.bookingWidgetData.depart?_((i=r.find(".date-wrapper.selected"))[i.length-1]):_(r.find(".arrow-right")[0]),(p=n).on("keydown",function(e){var t,n,r,i,a,o,s,l,u,c,d,f,h;9===e.keyCode&&(t=p.find(".arrow-icon"),n=he(".month-wrapper")[0].querySelector(".date-wrapper:not(.past)"),r=he(".month-wrapper")[1].querySelector(".date-wrapper:not(.past)"),i=he(".month-wrapper")[0].querySelectorAll(".date-wrapper:not(.past)")[he(".month-wrapper")[0].querySelectorAll(".date-wrapper:not(.past)").length-1],a=p.find('a, button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])'),o=e.target===a[0],s=e.target===a[a.length-1],l=e.target===t[0],u=e.target===t[1],c=e.target===n,d=e.target===r,f=e.target===i,h=e.shiftKey,o&&h?(e.preventDefault(),_(a[a.length-1])):s&&!h?(e.preventDefault(),_(a[0])):l&&!h?(e.preventDefault(),_(t[1])):u&&h?(e.preventDefault(),_(t[0])):u&&!h?(e.preventDefault(),_(n)):c&&h?(e.preventDefault(),_(t[1])):d&&h?(e.preventDefault(),_(i)):f&&!h&&(e.preventDefault(),_(r)))})),b.bookingWidgetPop=b.bookingWidgetPop!==t&&t,"region"===b.bookingWidgetPop&&(b.resortLive=!1),a(),M())},b.getRegionSelect=function(e,t){!1!==$(e)&&(b.enableAllRegions=!(!b.variantV1||!de||t.id!==de&&"las-vegas"!==t.id),b.locationDropDefault=t,b.selectedPropertyName=t.subItems?t.subItems[0].name:"",b.bookingWidgetPop=!1,b.selectedRegionSmall=t,b.enableAllRegions&&ge.is("small")&&(b.selectedPropertyName=b.propertyFieldValue),b.selectedPropertyName=!1,b.selectedResortSmall=!1,b.availabilityStartingDate=p(t),u(),l(),b.enableAllRegions&&h.bookingWidgetData.selectedRegion!==se.regionFieldValue?m({selectedRegion:!1,selectedPropertyId:!1}):m({selectedRegion:B?t.id:t.name,selectedPropertyId:!1}),_(he(".booking-widget-dropdown-button.region-selector")))},b.getResortSelectSmall=function(e,t){var n,r,i,a;!1!==$(e)&&(-1!==t.indexOf("::")&&(r=(n=t.split("::"))[0],i=n[1],a=n[2]),b.selectedPropertyName=r,b.selectedResortSmall=r,b.bookingWidgetPop=!1,u(),l(),b.enableAllRegions&&r&&m({selectedRegion:i,selectedPropertyId:a}))},b.getResortSelect=function(e,t,n){!1!==$(e)&&(_(he(".booking-widget-dropdown-button.resort-selector")),b.resortLive=!0,b.selectedPropertyName=t.name,b.selectedResortSmall=t,b.bookingWidgetPop=!1,b.availabilityStartingDate=p(t),u(),l(),b.enableAllRegions&&n?m({selectedRegion:n,selectedPropertyId:t.propertyId}):m({selectedPropertyId:t.propertyId}))},b.getDurationSelect=function(e){b.handleMonthsDisplay()},b.getGuestSelect=function(e,t){var n;!1!==$(e)&&(_(he(".booking-widget-dropdown-button.guest-selector")),n=t.value,b.bookingWidgetPop=!1,b.numAdultsSmall=b.guestOptions[n-1],m({numAdults:t.value}))},b.getDurationOffCanvas=function(e){Q.openCanvas(e.target,he("#bookingWidgetCalendarSmall"),"left")},b.closeDurationOffCanvas=function(e){a(),Q.closeCanvas()},b.findRooms=function(e){var t,n,r;!1!==$(e)&&(t=MGMRI.data.urls.booking.room,r="",n=MGMRI.data.urls.booking.roomDefaultHash,r=!h.bookingWidgetData.selectedRegion&&b.enableAllRegions?"":f(),h.bookingWidgetData.selectedPropertyId&&(r=r+"&"+Z+"="+h.bookingWidgetData.selectedPropertyId),h.bookingWidgetData.selectedRegion&&(r=r+"&"+J+"="+h.bookingWidgetData.selectedRegion),r=B?t+r:String(t).split("#")[0]+"#/"+n+r,s(),fe(),setTimeout(function(){i.location.href=r},500))};var fe=function(){var e,t,n,r=[];r[0]={eventInfo:{eventName:"find rooms click event"},attributes:{}},e=we(b.bookingWidgetData.checkInDate),t=we(b.bookingWidgetData.checkOutDate),r[0].attributes.regionName=b.locationDropDefault.name,r[0].attributes.resortName=b.selectedPropertyName||b.propertyFieldValue,r[0].attributes.daysBeforeArrival=e.startOf("day").diff(we().startOf("day"),"days"),r[0].attributes.numberOfNights=t.diff(e,"days"),r[0].attributes.numberOfGuests=b.bookingWidgetData.numAdults,n={eventName:"findRooms",event:r},be.updateAnalytics(n,"bookingWidget")};b.clearDates=function(e){!1!==$(e)&&(a(!0),b.getDropdownOpen(e,!1),ge.is("small")&&he(".months-wrapper").animate({scrollTop:10},100))},function(){var e,t,n,r,i,a,o,s,l,u;if(he("html").hasClass("no-sessionstorage")?b.sessionStorage=!1:null!==(e=sessionStorage.getObject("booking-room"))&&(Y=he.extend(!0,{},e)),A=he(".mgmri-booking-widget-component"),he(".date-selector input").on("keydown",function(e){var t=he(this),n=t.closest(".date-selector").hasClass("arrive");13===e.keyCode&&(n?he(".depart-date input").focus():t.blur())}),me("calendar/selected/arrive").subscribe(function(e){var t,n,r,i;"dining"!==h.calendarView&&"filterDateRange"!==h.calendarView&&(V=e.closest(".date-wrapper"),b.formatted.arrive=x(h.arrive.month,h.arrive.date,h.arrive.year),n=(t=h.nextDefaultDay).attr("data-date"),i=(r=t.closest("table").prev()).find(".year").html(),r=r.attr("data-month"),b.formatted.depart=x(K[r],n,i),C())}),me("calendar/selected/depart").subscribe(function(){"dining"!==h.calendarView&&"filterDateRange"!==h.calendarView&&(b.formatted.depart=x(h.depart.month,h.depart.date,h.depart.year),k(),"request"!==h.calendarView&&v())}),me("globalNavigation/dropdown/booking").subscribe(function(){var e=g(b.availabilityStartingDate);h.calendarView="",h.calendarSelectType="range",H=document.querySelector(".non-rate-calendar"),b.arriveSelected=!0,b.formatted.arrive=we(e).format("MMM DD, YYYY"),b.formatted.depart=we(e).add(1,"days").format("MMM DD, YYYY")}),me("booking/calendar/error").subscribe(function(){b.arriveSelected=!0,b.formatted.depart=void 0,b.formatted={}}),ge.subscribe("*",function(){b.viewPort=ge.current().name,ae&&b.handleMonthsDisplay()}),he("#booking-widget").on("keyup",function(e){13===e.which&&(ie=!1)}),ae){h.bookingWidgetData={},b.miniCalendarMonthStart=0,b.miniCalendarMonthEnd=1,b.firstClick=!0,b.calendarCheckInCopy=se.checkInCopy||"",b.calendarCheckOutCopy=se.checkOutCopy||"",b.calendarCheckInLabel="",b.calendarCheckOutLabel="",b.homeBookingTitle=se.homeBookingTitle,b.calendarDropdownTitle=se.calendarDropdownTitle,b.propertyFieldValue=se.propertyFieldValue,b.selectResortValue=se.selectResortValue,b.pluralGuestLabel=se.pluralGuestLabel,b.singularGuestLabel1=se.singularGuestLabel1,b.selectDates=se.selectDates,b.ctaLabel=se.ctaLabel,b.clearDatesLabel=se.clearDatesLabel||"",b.guestOptions=[],b.newVariant=!!(b.variantV1&&de&&b.selectResortValue);var c=se.dateTypes;!c||"fixeddates"!==c.type&&"rollingdates"!==c.type||(r="fixeddates"===(t=c).type?(n=we(t.checkInDate).startOf("day"),we(t.checkOutDate).startOf("day")):(n=we().isoWeekday()<=(i=we().day(t.day).day())?we().isoWeekday(i).startOf("day"):we().add(1,"weeks").isoWeekday(i).startOf("day"),we(n).add(t.duration,"days").startOf("day")),we().startOf("day")<=n&&(l=n,u=r,b.calendarCheckInCheckOutLabel=l.format("MMM DD, YYYY")+" - "+u.format("MMM DD, YYYY"),b.calendarCheckInCheckOutLabelSmall=l.format("MMM DD")+" - "+u.format("MMM DD"),m({arrive:a={date:n,day:n.date(),isCurrentMonth:n.isSame(we(),"month"),isPastDay:we().startOf("day")>n,isToday:n.isSame(we(),"day"),name:n.format("dd").charAt(0),number:n.date(),status:"available",weekday:n.format("dddd")},depart:o={date:r,day:r.date(),isCurrentMonth:r.isSame(we(),"month"),isPastDay:we().startOf("day")>n,isToday:r.isSame(we(),"day"),name:r.format("dd").charAt(0),number:r.date(),status:"available",weekday:r.format("dddd")},checkInDate:a.date.format(ce),checkOutDate:o.date.format(ce)})));for(var d=1;d<=Number(se.maxGuests);d++)1===d?b.guestOptions.push({value:d,name:d+" "+se.singularGuestLabel1}):b.guestOptions.push({value:d,name:d+" "+se.pluralGuestLabel});b.newVariant&&function(){var e=pe.filter(le,function(e){return"las-vegas"===e.id}),t=pe.filter(le,function(e){return"las-vegas"!==e.id}),n=pe.sortBy(t,function(e){return e.name.toLowerCase()});e&&e[0]&&(e[0].subItems=pe.sortBy(e[0].subItems,function(e){return e.name.toLowerCase()}),n.unshift(e[0])),le=n;for(var r=0;r=l.calendarMaxMonths+1,l.tabIndexPrevious=0,l.tabIndexNext=0,l.disablePrevious&&(l.tabIndexPrevious=-1),l.disableNext&&(l.tabIndexNext=-1)}function v(){c.propertyWidgetData.depart||(y({arrive:null,depart:null,checkInDate:null,checkOutDate:null}),l.calendarCheckInCheckOutLabel=!1,l.calendarCheckInCheckOutLabelSmall=!1,l.calendarCheckInDate="",l.calendarCheckOutDate="",l.propertyfirstClick=!0)}function y(e){e&&(c.propertyWidgetData=V.extend({},c.propertyWidgetData,e),l.propertyWidgetData=c.propertyWidgetData),b()}function b(){l.$$phase||l.$apply()}function w(){c.propertyErrorShowing=!1}function x(){var e=Number(c.propertyWidgetData.numAdults)||l.defaultGuests;1===Number(e)?l.selectedGuestLabel=e+" "+E.singularGuestLabel1:l.selectedGuestLabel=e+" "+E.pluralGuestLabel,l.numAdultsSmall=l.guestOptions[e-1]}function D(e){return!W.is("xlarge")||13===(e.which||e.keyCode)||"click"===e.type}function k(e){return e&&0O&&(c.propertyErrorShowing=!0,f(),c.propertyError=M.max,c.arrive=null,c.depart=null,i=!1,b()),i?(e.date&&e.date.isBefore(a.date)?(o=V.copy(a),a=e):o=e,l.calendarCheckInCheckOutLabel=String(a.date.format("ddd, MMM DD"))+" - "+String(o.date.format("ddd, MMM DD")),l.calendarCheckInCheckOutLabelSmall=String(a.date.format("ddd, MMM DD"))+" - "+String(o.date.format("ddd, MMM DD, YYYY")),l.calendarCheckInDate=String(a.date.format("ddd, MMM DD")),l.calendarCheckOutDate=String(o.date.format("ddd, MMM DD")),y({arrive:a,depart:o,checkInDate:a.date.format(I),checkOutDate:o.date.format(I)}),s(function(){l.propertyWidgetPop=!1},500),W.is("small")&&(T.closeCanvas(),w())):y({arrive:null,depart:null}),L(".property-widget-dropdown.duration-dropdown").attr("role","listbox"),h(L(".property-widget-dropdown-button.travel-date-selector"))),void(l.propertyfirstClick=!l.propertyfirstClick));v()}},l.getDateOffCanvas=function(e){T.openCanvas(e.target,L("#propertyWidgetCalendarSmall"),"left"),s(function(){var e,t;0