(function(v,n,t,r,l){v[n]=v[n]||{};for(v[n].q=v[n].q||[];lk.attachEvent.toString().indexOf("[native code"))&&!d}function c(){t(e,function(d){d._fetched?d._defined||d.define():d.fetch()})}function a(d,k,p,u,x){if("$config"!=d){var F=v(d),z=F||new f;F||(F= l(d),e[F]=z);d&&k&&(z._fetched=!0);z.start=z.start||(new Date).getTime();z.url=z.url||d;z.dependencies=z.dependencies||k;z.config=z.config||u;z.definedCallback=z.definedCallback||p;z.isRequire=z.isRequire||x}}function b(d,k,p,u){d instanceof Array&&(u=p,p=k,k=d,d=void 0);m.addDefine({url:d,dependencies:k,definedCallback:p,config:u})}let e={},m;f.prototype={getUnresolvedDependencies:function(){let d=[];t(this.dependencies,function(k){"$config"!=k&&(k=v(k),(!k||k&&!k._defined)&&d.push(k))});return d}, getDependencies:function(){let d=this,k=[];t(d.dependencies,function(p){p="$config"==p?d.config||null:v(p).definition||null;k.push(p)});return k},define:function(){function d(x){k.definedCallback=void 0;k.definition=x;k.end=(new Date).getTime();k.timeToDefine=k.end-k.start;k._defining=!1;k._defined=!0;setTimeout(c,1)}let k=this;k.defineStartTime=k.defineStartTime||(new Date).getTime();if(!k._defining&&!k._defined&&k.dependencies)if(k._defining=!0,0 element not found on trying to load "+d,void 0);this.currentlyAddingScript=void 0}};m=new h;b.getModule=function(d){return v(d)};let q=0;extole.define=b;extole.require=function(d,k){var p=m,u=p.addDefine;q++;u.call(p,{url:"anonymous_"+q,dependencies:d,definedCallback:k,isRequire:!0})};extole.define("extole-require",[],function(){return{resolveUrl:g}}); setTimeout(function(){let d=!1,k=[];t(e,function(p){p._defined||(d=!0);k.push({defineStartTime:p.defineStartTime,dependencies:p.dependencies,end:p.end,start:p.start,isRequire:p.isRequire,timeToDefine:p.timeToDefine,url:p.url,_defined:p._defined,_defining:p._defining,_fetched:p._fetched})});d&&extole.DUMP_REQUIRE_MODULES_ON_ERROR&&extole.log("error","After 7000ms there are unresolved extole-require modules. ###"+JSON.stringify(k)+"###")},7E3)}();(function(){})(); extole.define("extole-uri-parser",["https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/collection.js","https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/uri.js"],function(v,n){let t=/^extole_(?!zone)/,r=/^extole_zone_/;return new function(){function l(f){let h={};f=f||g;v.each(f,function(c,a){t.test(a)&&(a=a.replace(t,""),h[a]=c)});return h}function w(){let f,h,c={};this.withName=function(a){f=a;return this};this.withElementId=function(a){h= a;return this};this.withData=function(a,b){c[a]=b;return this};this.build=function(){let a={};f&&(a.name=f);h&&(a.elementId=h);c&&(a.data=c);return a}}let g=n.deserialize(location.search);this.parseUriZoneDefinition=function(f){let h=new w,c,a;f=f||g;c=l(f);v.each(c,function(b,e){h.withData(e,b)});v.each(f,function(b,e){r.test(e)&&(e=e.replace(r,""),"name"===e?(a=!0,h.withName(b)):"element_id"===e?h.withElementId(b):h.withData(e,b))});return a?h.build():null};this.parseGlobalZoneParameters=l}}); (function(v,n,t,r,l){v[n]=v[n]||{};for(v[n].q=v[n].q||[];lw.indexOf(f)||0<=g.indexOf(f)||g.push(f)});return g},difference:function(l,w){let g=[];t(l,function(f){0<=w.indexOf(f)||0<=g.indexOf(f)||g.push(f)});return g}}}); extole.define("https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/cookie.js",["https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/logger.js"],function(v){function n(g){try{return decodeURIComponent(g.replace(r," "))}catch(f){return v.info("** cookie.decode ** Cookie error for: "+g,{error:f,message:f.message,stack:f.stack,cookiePart:g}),""}}function t(g){g=n(g);return 0===g.indexOf('"')?g.slice(1,-1).replace(l,'"').replace(w,"\\"):g}let r= /\+/g,l=/\\"/g,w=/\\\\/g;return function(g,f,h){if(void 0!==f){h=h||{};var c=document;g=encodeURIComponent(g);f=encodeURIComponent(f);if(h.expires){var a=h.expires;if(!a||!a.toUTCString){let b=new Date;b.setDate(b.getDate()+("number"===typeof a?a:0));a=b}a="; expires="+a.toUTCString()}else a="";return c.cookie=[g,"=",f,a,h.path?"; path="+h.path:"",h.domain?"; domain="+h.domain:"",h.samesite?"; samesite="+h.samesite:"","; secure"].join("")}a:{h=document.cookie?document.cookie.split("; "):[];c=g?null: {};for(let b=0,e=h.length;b=k.length?v.info("events.remove - Couldn't find exiting event listener for type \""+d+'" listener on element '+q):l.each(k,function(p){let u=p.index;p=p.eventListener;q.removeEventListener?q.removeEventListener(d,p.listenerWrapper,!1):q.detachEvent("on"+d,p.listenerWrapper);m.splice(u,1)})}let m=[];b.prototype={preventDefault:function(){let q=this.originalEvent;q.preventDefault? q.preventDefault():q.returnValue=!1},stopPropagation:function(){let q=this.originalEvent;q.stopPropagation&&q.stopPropagation();q.cancelBubble=!0}};return{addListener:function(q,d,k){function p(x){u&&(x=window.event);return k.call(q,new b(x))}if(0=h[extole.LOG_LEVEL_CONSOLE]&&(e=b+" "+d,window.console))if(window.console[b.toLowerCase()])window.console[b.toLowerCase()](e);else window.console.log(e);h[b]>=h[extole.LOG_LEVEL_REMOTE]&&(e=a[d],c[e]&&t(b,d+(1{var I=H.split(": ");H=I.shift();I=I.join(": ");E[H]=I});return E}catch(E){return r.error("Error parsing response headers: ",E),{}}}function q(B){C||(C=!0,r.error("Error with url "+F+"= "+p.join(","),d(B)),D.call(a,a.statusText,a.status))}function d(B){return{eventType:B&&B.type||null,options:b,readyState:a.readyState,response:a.response,responseText:a.responseText, responseType:a.responseType,responseURL:a.responseURL,responseXML:a.responseXML,status:a.status,statusText:a.statusText,timeout:a.timeout,responseHeaders:a.getAllResponseHeaders()}}function k(B){0>F.indexOf(r.LOGGING_ENDPOINT)&&r.debug("ajax request complete",d(B))}let p=Array.prototype.slice.call(arguments),u=b.headers||{},x=b.xhrFields||{},F=b.url||"",z=b.data||"",A=(b.type||"get").toUpperCase(),G=b.complete||function(){},D=b.error||function(){},y=l.get();F.includes("/api/")&&y&&!b.noAuthorizationHeader? u.Authorization=y:F.includes("/zones/")&&(y&&!b.noAuthorizationHeader&&(u.Authorization="Bearer+"+y),"GET"!==A&&"HEAD"!==A&&(z=g(u,z)));t.isPlainObject(z)&&("GET"===A?(F+=n.serialize(z),z=null):z=JSON.stringify(z));a.open(A,F,!0);v.merge(a,x);v.each(u,function(B,E){try{a.setRequestHeader(E,B)}catch(H){r.error("AJAX ERROR: Couldn't set request header "+E+" to "+B)}});let C=!1;a.onload=e;a.onreadystatechange=e;a.onerror=q;a.ontimeout=q;a.onabort=k;a.send(z)}function g(a,b){function e(q){let d={};v.each(q, function(k,p){p=0<=p.indexOf(".")?'"'+p+'"':p;t.isPlainObject(k)&&(k=e(k));d[p]=k});return d}let m=[];f(a);a["content-type"]="application/x-www-form-urlencoded";b=e(b);b=v.flatten(b);v.each(a,function(q,d){"content-type"!==d.toLowerCase()&&(m.push("::headers."+d+"="+q),delete a[d])});v.each(b,function(q,d){t.isUndefined(q)||m.push(encodeURIComponent(d)+"="+(t.isNull(q)?"":encodeURIComponent(q)))});return m.join("&")}function f(a){v.each(a,function(b,e){"content-type"===e.toLowerCase()&&delete a[e]})} function h(a){a=a||{};var b=!1;for(let e=0;ey.indexOf(C)&&C.remove()})}function F(){let y=[a.MEMORY];Object.prototype.hasOwnProperty.call(D,a.COOKIE)&&y.push(a.COOKIE);(extole.LOCAL_STORAGE_ENABLED_WHEN_CONSENTED||extole.LOCAL_STORAGE_ALWAYS_ENABLED)&&y.push(a.LOCAL_STORAGE);return y.map(function(C){return D[C]})}function z(){let y=[a.MEMORY];extole.CORE_CONFIG.cookieConsentPolicy===h.COOKIE_CONSENT_OR_SESSION_COOKIE&&Object.prototype.hasOwnProperty.call(D,a.COOKIE)&&y.push(a.COOKIE); (extole.LOCAL_STORAGE_ENABLED_WHEN_UNCONSENTED||extole.LOCAL_STORAGE_ALWAYS_ENABLED)&&y.push(a.LOCAL_STORAGE);return y.map(function(C){return D[C]})}let A,G=l.create(),D={};e();(function(){let y=t.deserialize(window.location.search);y.extole_access_token&&q(y.extole_access_token,y.extole_access_token_type)})();this.getCurrentTokenDuration=function(){return A};this.get=m;this.set=q;this.remove=function(){A=u();n.each(D,function(y){y.remove()})};this.setConsented=function(){A="YEAR";q()};this.setUnconsented= function(){A=u();q()};this.initializeStores=e;this.events=G}let h={COOKIE_CONSENT_DISABLED:"COOKIE_CONSENT_DISABLED",COOKIE_CONSENT_OR_SESSION_COOKIE:"COOKIE_CONSENT_OR_SESSION_COOKIE",COOKIE_CONSENT_OR_NO_COOKIE:"COOKIE_CONSENT_OR_NO_COOKIE"},c={NO_COOKIE:"NO_COOKIE",SESSION:"SESSION",YEAR:"YEAR"},a={MEMORY:"MEMORY",COOKIE:"COOKIE",LOCAL_STORAGE:"LOCAL_STORAGE"},b={YEAR:365,SESSION:null};extole.tokenStore=extole.tokenStore?extole.tokenStore:new f;return extole.tokenStore}); extole.define("https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/client/metric-registry.js",["https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/client/program.js","https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/ajax.js","https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/logger.js"],function(v,n,t){function r(g,f,h){t.info("Sending metric from metric registry: "+g+" "+f+" "+ h);h={metric_type:g,key:f,value:h};g={"Content-Type":"application/x-www-form-urlencoded","X-Extole-App":"javascript_sdk"};f=[v.getProtocol(),v.getProgramDomain(),"/api/v4/debug/metrics"].join("");h=n.convertToFormUrlEncoded(g,h);n({url:f,type:"POST",headers:g,data:h,xhrFields:{withCredentials:!0}})}function l(g){this.increment=function(f){r("COUNTER",g,f?f:1)}}function w(g){this.update=function(f){r("HISTOGRAM",g,f)}}return{histogram:function(g){return new w(g)},counter:function(g){return new l(g)}}}); extole.define("https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/tldts.js",[],function(){let v="co.uk gov.uk org.uk ac.uk me.uk ltd.uk plc.uk com.au net.au org.au gov.au edu.au asn.au id.au co.jp co.kr com.tw com.hk com.sg co.in co.th com.my com.ph co.id com.vn com.cn net.cn org.cn gov.cn com.br com.ar com.mx com.co com.pe com.cl com.ve co.za co.il com.eg co.ke com.tr co.nl com.pl com.es com.it com.fr com.de com.ru co.nz".split(" ");return{getDomain:function(n){if(!n|| "string"!==typeof n)return null;n=n.trim().toLowerCase();n.endsWith(".")&&(n=n.slice(0,-1));n=n.replace(/^https?:\/\//,"");n=n.split("@").pop();n=n.split(":")[0];n=n.split("/")[0];n=n.split("?")[0];n=n.split("#")[0];if(!n||-1===n.indexOf(".")||/^(\d{1,3}\.){3}\d{1,3}$/.test(n))return null;let t=n.split(".");if(2>t.length||t.some(function(l){return!l}))return null;if(2===t.length)return n;for(var r=0;r=r?t.slice(-r).join("."): n}return t.slice(-2).join(".")}}}); extole.define("ZoneBrowserContext",["https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/uri.js","https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/collection.js"],function(v,n){function t(w,g,f){this.getElement=function(){return f};this.getName=function(){return w};this.getData=function(){return g};this.getParameters=function(){return g}}function r(){this.getName=function(){return extole.PROGRAM.name};this.getProgramDomain=function(){return extole.PROGRAM.programDomain}; this.getSitePatterns=function(){return extole.PROGRAM.sitePatterns};this.getSiteRegexPatterns=function(){return extole.PROGRAM.siteRegexPatterns}}function l(){this.backendTargetingEnabled=function(){return!0};this.cookieConsentEnabled=function(){return extole.CORE_CONFIG.isCookieConsentEnabled}}return function(w,g,f,h,c){let a=new t(w,g,f),b=new r,e=new l;this.getZone=function(){return a};this.getProgram=function(){return b};this.getCreativeData=function(){let m=v.dotNotationToObject(v.deserialize(location.search)), q=v.dotNotationToObject(a.getParameters());return n.merge(m.extole_creative,q.creative)};this.getCoreConfig=function(){return e};this.getLocale=function(){return h||null};this.getContainer=function(){return c}}}); extole.define("find-element-by-id",["https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/logger.js"],function(v){function n(t,r,l){function w(){if(r())l();else{t();var f=setTimeout;g||(g=10);var h=500=g?v.debug("EXTOLE_ELEMENT_FOUND_SLOW: Scan duration: "+c+"ms, element id: "+t):!extole.isFindElementBeforeZoneRequest&&!f&&c>=w&&(f=!0,v.debug("EXTOLE_ELEMENT_NOT_YET_FOUND: Scan duration: "+c+"ms, element id: "+t));return a},function(){r(h)})}}); extole.define("ensure-element",["find-element-by-id"],function(v){function n(t){document.body?t(document.body.appendChild(document.createElement("div"))):addEventListener("DOMContentLoaded",function(){t(document.body.appendChild(document.createElement("div")))})}return function(t,r){t.element?r(t.element):t.element_id?v(t.element_id,r):n(r)}}); extole.define("pending-zone-service","https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/dom.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/type.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/logger.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/collection.js ZoneBrowserContext ensure-element".split(" "),function(v,n,t,r,l,w){function g(a,b){b=b||function(){}; let e=a.name,m=f(a.data);c(e);this.resolve=function(q,d,k,p,u){w(a,function(x){a.element=x;v.clearEventListeners(a.element);x=new l(e,m,a.element,p,u);q(x);b(null,x.getZone())})}}function f(a){a=r.merge({},a);delete a.campaign_id;delete a.extole_campaign_id;return a}let h={},c=function(){let a={};return function(b){n.isUndefined(a[b])&&(a[b]=0);a[b]++;if(5===a[b]){b="duplicate_zone_requests : "+b;var e=r.filter(extole.q.history,function(m){return m.name&&"createZone"===m.name});e=r.map(e,function(m){delete (m.args[0]|| {}).element;return m});t.warn(b,e)}}}();return{get:function(a){if(!h[a])throw Error("Pending zone does not exist for id: "+a);return h[a]},create:function(){let a=Math.floor(1E9*Math.random()),b=0;return function(e,m){b++;let q=a+"."+b;h[q]=new g(e,m);return q}}()}}); extole.define("create-zone","extole-uri-parser https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/uri.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/collection.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/dom.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/client/program.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/ajax.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/ExtoleError.js https://origin.xtlo.net/type=core:clientId=361878788:coreAssetsVersion=67/common/logger.js pending-zone-service".split(" "),function(v, n,t,r,l,w,g,f,h){let c=[];return function(a,b,e){function m(){let A={"Content-Type":"application/x-www-form-urlencoded",Accept:"text/javascript","X-Extole-App":"javascript_sdk"};k=F+"/zones/"+a.name;x&&(A["X-Extole-Jwt"]=x,delete u.jwt);z&&(A["X-Extole-Debug"]="true");w({url:k,type:"POST",headers:A,data:u,complete:function(G,D){var y=/^text\/html(;|$)/;let C=/^text\/plain(;|$)/;D=D.getResponseHeader("Content-Type");let B;/^text\/javascript(;|$)/.test(D)?B=G:y.test(D)?(y=document.createElement("div"), y.innerHTML=G,B=r.queryFirst("script",y).innerHTML):C.test(D)&&!G?f.info("No content to render"):q(new g("Received invalid content type: '"+D+"'","invalid_content_type",null,"warn"));if(B){G=B;try{let E=document.currentScript||document.querySelector('script[src*="extole"]'),H=document.createElement("script");H.nonce=E&&(E.nonce||E.getAttribute("nonce"));H.textContent=G;document.head.appendChild(H);H.parentNode.removeChild(H)}catch(E){q(new g("Error in zone script - MESSAGE: "+E.message+" STACK: "+ E.stack,"zone_script_error"))}}d()},error:function(G,D){let y;try{y=JSON.parse(this.responseText)}catch(C){y={status:D||null,statusText:G||null}}q(new g(y.message||"Ajax zone request failed",y.code||null,y))},xhrFields:{withCredentials:!0}})}function q(A){let G=t.merge({originalMessage:A.message,zoneRequestUrl:k||null,zoneDefinition:a},A.data);b(new g("Problem creating zone",A.code||"zone_request_failed",G,A.logLevel||"error"));d()}function d(){"function"===typeof e&&setTimeout(e,500)}b=b||function(){}; let k;var p=n.deserialize(location.search);let u=t.merge({},a.data||a.parameters),x=a.jwt||u.jwt||p.extole_jwt,F=[l.getProtocol(),l.getProgramDomain()].join(""),z=u.debug&&"false"!==u.debug||extole.IS_DEBUG_ENABLED;extole.isPassRefererInZoneData&&(u.referer=location.href);extole.CORE_CONFIG.isGlobalZoneParametersEnabled&&(p=v.parseGlobalZoneParameters(p),u=t.merge(u,p));if(extole.createZonePrehandler&&(p=extole.createZonePrehandler(a,u),!1===p)){f.info("Zone request cancelled by prehandler");b(new g("Zone request cancelled by prehandler", "prehandler_cancelled",{zoneDefinition:a},"info"));d();return}a.element_id&&(u.element_id=a.element_id);(function(){let A=Date.now(),G=A-6E4;c=c.filter(function(D){return D>G});60b)k();else{if(p)t[d.logLevel||"error"](d.toString());a&&a(d)}}let q;g.push(function(d){q=w(d);v(c,e,q);f&&q()})}function l(c,a,b){function e(){let m= !!c.element;extole.isFindElementBeforeZoneRequest&&!m||r(c,a,b)}b=Number(b)||0;extole.isFindElementBeforeZoneRequest?n(c,function(m){c.element=m;e()}):e()}function w(c){let a=!1;return function(){let b=Array.prototype.slice.call(arguments);a||(a=!0,c.apply(null,b))}}let g=new function(){let c=0,a=[],b=this,e=!1;this.push=function(m){a.push(m);this.next()};this.next=function(){function m(){c--;f=!0;b.next()}if(!e)for(;1>c&&a.length;)h||f||this.next(),h=!1,a.shift()(m),c++};this.start=function(){e= !1;this.next()};this.stop=function(){e=!0}},f=!1,h=!0;return{initiateExecution:l}});