!function(){"use strict";((e,i)=>{var n,c;null!==(n=(c=window.marfeel.config).experiences)&&void 0!==n||(c.experiences={}),window.marfeel.config=Object.assign(Object.assign({},e),window.marfeel.config),Object.assign(window.marfeel.config.experiences,{preflight:i})})({},{"active":true,"recommender":{"enabled":true,"personalizedContent":false,"curatedContent":true},"preflight":{"experiments":[{"name":"AB","group":2,"groups":2}],"compass":{},"targeting":{},"inline":{}}})}(); var e,t,r,n,i={539:(e,t,r)=>{r.d(t,{C:()=>i});var n=r(796);const i=e=>{void 0!==document.addEventListener&&void 0!==document.hidden&&document.addEventListener("visibilitychange",(()=>{"hidden"===document.visibilityState&&e()})),window.addEventListener("pagehide",(()=>{e()}),{capture:!0}),n.TK&&addEventListener("beforeunload",e,!0)}},796:(e,t,r)=>{r.d(t,{RX:()=>i,jn:()=>o,TK:()=>n});const n="undefined"!=typeof window&&/^((?!chrome|android).)*safari/i.test(window.navigator.userAgent)&&((e=window.navigator.userAgent)=>{const t=function(e,t){const r=(e||window.navigator.userAgent).match(/version\/(\d+(\.\d+)?)/i);return r&&r.length>1&&r[1]||""}(e),r=parseInt(t.split(".")[0],10);return!isNaN(r)&&r})()<13,i=(()=>{try{return"keepalive"in new Request("https://www.google.com/")}catch(e){return!1}})(),o="undefined"!=typeof window&&void 0!==window.navigator.sendBeacon},595:(e,t,r)=>{r.d(t,{N:()=>u});const n={childList:!0,subtree:!0};let i,o=[];const a=[],s=e=>{a.forEach((t=>{t(e)}))};function c(e){return new MutationObserver((t=>{t.forEach((t=>{"childList"===t.type&&e(t.target)}))}))}const u=(e,t=document.body)=>{const r=t===document.body;if(e){const l=((e,t)=>{let r;return function(...t){clearTimeout(r),r=setTimeout((()=>{e(...t)}),400)}})(e);if("undefined"!=typeof MutationObserver)if(r)u=()=>{l(document.body)},a.push(u),i||(i=c(s),i.observe(document.body,n));else{const e=c(l);o.push(e),e.observe(t,n)}}var u}},181:function(e,t){var r=this&&this.__assign||function(){return r=Object.assign||function(e){for(var t,r=1,n=arguments.length;r0)&&!(n=o.next()).done;)a.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=o.return)&&r.call(o)}finally{if(i)throw i.error}}return a},i=this&&this.__spreadArray||function(e,t,r){if(r||2===arguments.length)for(var n,i=0,o=t.length;i{var n;r.d(t,{Z:()=>l});var i=new Uint8Array(16);function o(){if(!n&&!(n="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return n(i)}const a=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var s=[],c=0;c<256;++c)s.push((c+256).toString(16).substr(1));const u=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(s[e[t+0]]+s[e[t+1]]+s[e[t+2]]+s[e[t+3]]+"-"+s[e[t+4]]+s[e[t+5]]+"-"+s[e[t+6]]+s[e[t+7]]+"-"+s[e[t+8]]+s[e[t+9]]+"-"+s[e[t+10]]+s[e[t+11]]+s[e[t+12]]+s[e[t+13]]+s[e[t+14]]+s[e[t+15]]).toLowerCase();if(!function(e){return"string"==typeof e&&a.test(e)}(r))throw TypeError("Stringified UUID is invalid");return r},l=function(e,t,r){var n=(e=e||{}).random||(e.rng||o)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){r=r||0;for(var i=0;i<16;++i)t[r+i]=n[i];return t}return u(n)}}},o={};function a(e){var t=o[e];if(void 0!==t)return t.exports;var r=o[e]={id:e,loaded:!1,exports:{}};return i[e].call(r.exports,r,r.exports,a),r.loaded=!0,r.exports}a.m=i,a.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return a.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,a.t=function(r,n){if(1&n&&(r=this(r)),8&n)return r;if("object"==typeof r&&r){if(4&n&&r.__esModule)return r;if(16&n&&"function"==typeof r.then)return r}var i=Object.create(null);a.r(i);var o={};e=e||[null,t({}),t([]),t(t)];for(var s=2&n&&r;"object"==typeof s&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach((e=>o[e]=()=>r[e]));return o.default=()=>r,a.d(i,o),i},a.d=(e,t)=>{for(var r in t)a.o(t,r)&&!a.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},a.f={},a.e=e=>Promise.all(Object.keys(a.f).reduce(((t,r)=>(a.f[r](e,t),t)),[])),a.u=e=>({360:"d31ef6f2918eede5697b",374:"6a3550ee36c828162b5f",376:"74d2269d24ec52e4971b",401:"db6992b145b90a7b6412",512:"544b6d39dadb4f09c7b3"}[e]+".js"),a.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),a.hmd=e=>((e=Object.create(e)).children||(e.children=[]),Object.defineProperty(e,"exports",{enumerable:!0,set:()=>{throw new Error("ES Modules may not assign module.exports or exports.*, Use ESM export syntax, instead: "+e.id)}}),e),a.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r={},n="@marfeel/marfeel-sdk:",a.l=(e,t,i,o)=>{if(r[e])r[e].push(t);else{var s,c;if(void 0!==i)for(var u=document.getElementsByTagName("script"),l=0;l{s.onerror=s.onload=null,clearTimeout(f);var i=r[e];if(delete r[e],s.parentNode&&s.parentNode.removeChild(s),i&&i.forEach((e=>e(n))),t)return t(n)},f=setTimeout(p.bind(null,void 0,{type:"timeout",target:s}),12e4);s.onerror=p.bind(null,s.onerror),s.onload=p.bind(null,s.onload),c&&document.head.appendChild(s)}},a.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.p="https://sdk.mrf.io/statics/",(()=>{a.b=document.baseURI||self.location.href;var e={179:0};a.f.j=(t,r)=>{var n=a.o(e,t)?e[t]:void 0;if(0!==n)if(n)r.push(n[2]);else{var i=new Promise(((r,i)=>n=e[t]=[r,i]));r.push(n[2]=i);var o=a.p+a.u(t),s=new Error;a.l(o,(r=>{if(a.o(e,t)&&(0!==(n=e[t])&&(e[t]=void 0),n)){var i=r&&("load"===r.type?"missing":r.type),o=r&&r.target&&r.target.src;s.message="Loading chunk "+t+" failed.\n("+i+": "+o+")",s.name="ChunkLoadError",s.type=i,s.request=o,n[1](s)}}),"chunk-"+t,t)}};var t=(t,r)=>{var n,i,[o,s,c]=r,u=0;if(o.some((t=>0!==e[t]))){for(n in s)a.o(s,n)&&(a.m[n]=s[n]);c&&c(a)}for(t&&t(r);u{var e=function(){try{var e;if(-1!==location.hash.indexOf("mrfdebug")||null!==(e=window.localStorage)&&void 0!==e&&e.getItem("mrfdebug")){for(var t=arguments.length,r=new Array(t),n=0;n{try{t(e)}catch(e){console.error(e)}}))}},s=class{constructor(){i(this,"dependencies",{})}get(e,t){var r="string"==typeof e?[e]:e,n=new Array(e.length),i=e.length;i?r.forEach(((e,r)=>{this.dependencies[e]||(this.dependencies[e]=new o),this.dependencies[e].get((e=>{n[r]=e,0==--i&&t(...n)}))})):t(...n)}register(e,t){this.dependencies[e]?this.dependencies[e].resolve(t):this.dependencies[e]=new o(t)}};var c=[];function u(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function l(e){for(var t=1;t{p&&performance.mark(e)},h=(e,t,r)=>{p&&(f(t),((e,t,r)=>{if(p){var n=performance.measure("".concat(e," to ").concat(t),e,t);!function(){try{if(p){for(var e=arguments.length,t=new Array(e),r=0;re.forEach((e=>this.getSDKs(...e)));r(e.cmd.splice(0)),e.cmd.push=function(){for(var e=arguments.length,t=new Array(e),n=0;n{if((!(a=t.origin)||"null"===a||a===window.location.origin||c.includes(a))&&(o=t.data)&&"__MRF_SDK__"===o.app){var{sdkName:r,methodName:n,args:i}=t.data;e.cmd.push([r,e=>{e[n].apply(e,i)}])}var o,a}))}(e)}registerSDK(e,t,n){var i=this;return r((function*(){i.dependenciesContainer.get(t,(function(){for(var t=arguments.length,r=new Array(t),o=0;o{i.dependenciesContainer.register(e,new t(i.config,...r))})).catch((()=>{}))}))}))()}addConfig(e){var t=this;return r((function*(){t.config=l(l({},t.config),e)}))()}getSDKs(){for(var e=arguments.length,t=new Array(e),r=0;r0&&void 0!==arguments[0])||arguments[0];i(this,"onChangeCallbacks",void 0),i(this,"onReadyCallbacks",void 0),i(this,"consent",void 0),i(this,"features",void 0),i(this,"state",void 0),i(this,"isEnabled",void 0),this.consent=e,this.features={},this.onReadyCallbacks=[],this.onChangeCallbacks=[],this.isEnabled=!0,e&&(this.state=y.ANSWERED)}isInitiated(){return!this.isEnabled||this.state===y.ANSWERED}setCMPLoaded(){this.state=y.READY;var e=this.onReadyCallbacks.slice();this.onReadyCallbacks=[],e.forEach((e=>e()))}setCMPNotApplies(){this.isEnabled=!1,this.consent=!0,this.setCMPLoaded()}isActive(){return this.isEnabled}onReady(e){this.isInitiated()?e():this.onReadyCallbacks.push(e)}onChange(e){var t;null===(t=this.onChangeCallbacks)||void 0===t||t.push(e)}callOnChange(){this.onChangeCallbacks.forEach((e=>e()))}getConsent(e){return e&&this.features&&void 0!==this.features[e]?this.features[e]:this.consent}setConsentFeatures(e){e.forEach((e=>{var{feature:t,consent:r}=e;this.features[g(t)]=r})),this.state||this.setCMPLoaded(),this.callOnChange(),this.state=y.ANSWERED}setConsent(e,t){this.features[g(e)]=t,this.callOnChange()}hasToPromptForConsent(e){e(!1)}hasConsentForVendor(e){return this.getConsent()}hasConsentForPurpose(e){return this.getConsent()}}var w=["tcloaded","useractioncomplete"],O={cookies:{vendors:[943],purposes:[1,7,8,9,10]},personalization:{vendors:[943],purposes:[1,5,6,7,8,9,10]}};class P{constructor(){i(this,"tcData",void 0),i(this,"isReady",!1),this.onReady((()=>{this.isReady=!0}).bind(this)),this.onChange((e=>{this.tcData=e}).bind(this))}isInitiated(){return arguments.length>0&&void 0!==arguments[0]&&!arguments[0]?this.isReady:!!this.tcData}isActive(){var e;return!(null==this||null===(e=this.tcData)||void 0===e||!e.gdprApplies)}hasToPromptForConsent(e){this.addEventListener((t=>{var r,n,{cmpStatus:i}=t;"loaded"===i&&(null===(r=(n=window).__tcfapi)||void 0===r||r.call(n,"ping",2,(t=>{var{displayStatus:r}=t;return e("disabled"!==r)})))}))}hasConsentForVendor(e){var t,r;return!0===(null===(t=this.tcData)||void 0===t||null===(r=t.vendor)||void 0===r?void 0:r.consents[e])}hasConsentForPurpose(e){var t,r;return!0===(null===(t=this.tcData)||void 0===t||null===(r=t.purpose)||void 0===r?void 0:r.consents[e])}matchRequirements(e){return!!e&&!!this.tcData&&e.vendors.every(this.hasConsentForVendor.bind(this))&&e.purposes.every(this.hasConsentForPurpose.bind(this))}onChange(e){this.addEventListener(((t,r)=>{!r||!w.includes(t.eventStatus)&&t.gdprApplies||e(t)}))}onReady(e){this.isInitiated(!1)?e():this.addEventListener((t=>{var r,n,{cmpStatus:i,listenerId:o}=t;"loaded"===i&&(e(),null===(r=(n=window).__tcfapi)||void 0===r||r.call(n,"removeEventListener",2,(()=>{}),o))}))}getConsent(e){return!(!this.tcData||this.tcData.gdprApplies)||this.matchRequirements(O[e])}addEventListener(e){var t,r;window.__tcfapi?null===(t=(r=window).__tcfapi)||void 0===t||t.call(r,"addEventListener",2,e):setTimeout((()=>this.addEventListener(e)),100)}}var E=a(571),k="flagConsentReady";function S(e,t,r,n){return j.apply(this,arguments)}function j(){return(j=r((function*(e,t,r,n){var i="".concat(k,"_").concat((0,E.Z)());return t.onReady((()=>{!function(e,t,r){if(e){var n=()=>!!t.getConsent("cookies")&&(r(),!0);n()||t.onChange(n)}else r()}(e.blockOnNoConsent,t,(()=>r.resolve(i)))})),!e.blockOnNoConsent&&void 0===e.manualConsent&&n&&setTimeout((()=>r.resolve(i)),n),r.wait(i)}))).apply(this,arguments)}class C{constructor(e){i(this,"handler",void 0),this.handler=function(e){return void 0!==e.gdpr&&!e.gdpr||!window.__tcfapi&&!window.gdprAppliesGlobally?new b(!e.manualConsent):new P}(e)}isInitiated(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];return this.handler.isInitiated(e)}isActive(){return this.handler.isActive()}setCMPLoaded(){this.handler.setCMPLoaded()}setCMPNotApplies(){this.handler.setCMPNotApplies()}onChange(e){this.handler.onChange(e)}onReady(e){this.handler.onReady(e)}getConsent(e){return this.handler.getConsent(e)}setConsentFeatures(e,t){this.handler instanceof b||(this.handler=new b),this.handler.setConsentFeatures(e,t)}setConsent(e,t){this.handler instanceof b||(this.handler=new b),this.handler.setConsent(e,t)}hasToPromptForConsent(e){this.handler.hasToPromptForConsent(e)}hasConsentForVendor(e){return this.handler.hasConsentForVendor(e)}hasConsentForPurpose(e){return this.handler.hasConsentForPurpose(e)}}v("consent",[],(()=>Promise.resolve(C)));function T(){return T=r((function*(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;ne())),o=(yield Promise.all(i)).some((e=>e)),s=window.top===window.self;o&&s&&(e=>{a.e(374).then(a.bind(a,374)).then((t=>{var{default:r,saveActiveOverlay:n}=t;new r(e),n()}))})(e)})),T.apply(this,arguments)}function A(e){return r((function*(){return!!new URL(window.location.href).searchParams.get(e)}))}const I="undefined"!=typeof window&&/^((?!chrome|android).)*safari/i.test(window.navigator.userAgent)&&((e=window.navigator.userAgent)=>{const t=function(e,t){const r=(e||window.navigator.userAgent).match(/version\/(\d+(\.\d+)?)/i);return r&&r.length>1&&r[1]||""}(e),r=parseInt(t.split(".")[0],10);return!isNaN(r)&&r})()<13,D=(()=>{try{return"keepalive"in new Request("https://www.google.com/")}catch(e){return!1}})(),_="undefined"!=typeof window&&void 0!==window.navigator.sendBeacon,N=e=>{void 0!==document.addEventListener&&void 0!==document.hidden&&document.addEventListener("visibilitychange",(()=>{"hidden"===document.visibilityState&&e()})),window.addEventListener("pagehide",(()=>{e()}),{capture:!0}),I&&addEventListener("beforeunload",e,!0)},L=e=>{void 0!==document.addEventListener&&void 0!==document.hidden&&document.addEventListener("visibilitychange",(()=>{"hidden"!==document.visibilityState&&e()})),window.addEventListener("pageshow",(()=>{e()}),{capture:!0})},R=(e,t,r,n,i=!0)=>{const o=new XMLHttpRequest;o.open("POST",e,i),n&&o.setRequestHeader("Content-Type",n),o.withCredentials=!0,o.onreadystatechange=()=>{4===o.readyState&&200===o.status&&r&&r(o.responseText)},o.send(t)},x=(e,t,{needsXHR:r,contentType:n,sync:i,keepalive:o=!0}={needsXHR:!1,sync:!1},a)=>{r||I?R(e,t,a,n):o&&D?((e,t,r)=>{let n=t;return r&&(n=new Blob([t],{type:r})),fetch(e,{method:"POST",body:n,keepalive:!0})})(e,t,n).catch((()=>{})):_?((e,t,r)=>{let n=t;r&&(n=new Blob([t],{type:r})),window.navigator.sendBeacon(e,n)})(e,t,n):R(e,t,a,n,!i)},M={childList:!0,subtree:!0};let U;const V=[],q=e=>{V.forEach((t=>{t(e)}))};function F(e){return new MutationObserver((t=>{t.forEach((t=>{"childList"===t.type&&e(t.target)}))}))}const z=(e,t=document.body)=>{const r=t===document.body;if(e){const i=((e,t)=>{let r;return function(...t){clearTimeout(r),r=setTimeout((()=>{e(...t)}),400)}})(e);"undefined"!=typeof MutationObserver&&(r?(n=()=>{i(document.body)},V.push(n),U||(U=F(q),U.observe(document.body,M))):F(i).observe(t,M))}var n};let H={};const B=e=>"fbia"===e?window.ia_document.shareURL:window.location.href,K=e=>{const t=(e=>"fbia"===e?window.ia_document.referrer:document.referrer)(e);if(t)try{if(new URL(t).pathname.endsWith(".js"))return null}catch(e){}return t},G=RegExp("^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])");function W(e,{cache:t=!0,readonly:r=!0}={}){try{if(!r)return new URL(e,document.baseURI);if(!H[e]){const{host:r,hostname:n,pathname:i,port:o,protocol:a,search:s,hash:c,href:u,origin:l}=new URL(e,document.baseURI),d={host:r,hostname:n,pathname:i,port:o,protocol:a,search:s,hash:c,href:u,origin:l};if(!t)return d;H[e]=d}return Object.assign({},H[e])}catch(e){return{}}}const J="data-mrf-link";function X(e,t,r=!0){const n=e;(r||!n.mrfLink)&&(n.mrfLink=t),(r||!e.hasAttribute(J))&&e.setAttribute(J,t)}const Q=e=>W(e).href,$=e=>{try{const t=new URL(e);return t.host.includes("mrf.io")&&t.searchParams.get("url")||e}catch(t){return e}};var Y,Z=new Uint8Array(16);function ee(){if(!Y&&!(Y="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return Y(Z)}var te=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;function re(e){return"string"==typeof e&&te.test(e)}for(var ne=[],ie=0;ie<256;++ie)ne.push((ie+256).toString(16).substr(1));function oe(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=(ne[e[t+0]]+ne[e[t+1]]+ne[e[t+2]]+ne[e[t+3]]+"-"+ne[e[t+4]]+ne[e[t+5]]+"-"+ne[e[t+6]]+ne[e[t+7]]+"-"+ne[e[t+8]]+ne[e[t+9]]+"-"+ne[e[t+10]]+ne[e[t+11]]+ne[e[t+12]]+ne[e[t+13]]+ne[e[t+14]]+ne[e[t+15]]).toLowerCase();if(!re(r))throw TypeError("Stringified UUID is invalid");return r}function ae(e,t,r){var n=(e=e||{}).random||(e.rng||ee)();if(n[6]=15&n[6]|64,n[8]=63&n[8]|128,t){r=r||0;for(var i=0;i<16;++i)t[r+i]=n[i];return t}return oe(n)}function se(e,t,r,n){switch(e){case 0:return t&r^~t&n;case 1:case 3:return t^r^n;case 2:return t&r^t&n^r&n}}function ce(e,t){return e<>>32-t}var ue=function(e,t,r){function n(e,t,r,n){if("string"==typeof e&&(e=function(e){e=unescape(encodeURIComponent(e));for(var t=[],r=0;r>>24,r[1]=t>>>16&255,r[2]=t>>>8&255,r[3]=255&t,r[4]=(t=parseInt(e.slice(9,13),16))>>>8,r[5]=255&t,r[6]=(t=parseInt(e.slice(14,18),16))>>>8,r[7]=255&t,r[8]=(t=parseInt(e.slice(19,23),16))>>>8,r[9]=255&t,r[10]=(t=parseInt(e.slice(24,36),16))/1099511627776&255,r[11]=t/4294967296&255,r[12]=t>>>24&255,r[13]=t>>>16&255,r[14]=t>>>8&255,r[15]=255&t,r}(t)),16!==t.length)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");var i=new Uint8Array(16+e.length);if(i.set(t),i.set(e,t.length),(i=function(e){var t=[1518500249,1859775393,2400959708,3395469782],r=[1732584193,4023233417,2562383102,271733878,3285377520];if("string"==typeof e){var n=unescape(encodeURIComponent(e));e=[];for(var i=0;i>>0;b=y,y=g,g=ce(v,30)>>>0,v=m,m=P}r[0]=r[0]+m>>>0,r[1]=r[1]+v>>>0,r[2]=r[2]+g>>>0,r[3]=r[3]+y>>>0,r[4]=r[4]+b>>>0}return[r[0]>>24&255,r[0]>>16&255,r[0]>>8&255,255&r[0],r[1]>>24&255,r[1]>>16&255,r[1]>>8&255,255&r[1],r[2]>>24&255,r[2]>>16&255,r[2]>>8&255,255&r[2],r[3]>>24&255,r[3]>>16&255,r[3]>>8&255,255&r[3],r[4]>>24&255,r[4]>>16&255,r[4]>>8&255,255&r[4]]}(i))[6]=15&i[6]|80,i[8]=63&i[8]|128,r){n=n||0;for(var o=0;o<16;++o)r[n+o]=i[o];return r}return oe(i)}try{n.name="v5"}catch(e){}return n.DNS="6ba7b810-9dad-11d1-80b4-00c04fd430c8",n.URL="6ba7b811-9dad-11d1-80b4-00c04fd430c8",n}();const le=e=>!!e&&re(e),de=()=>{try{return ae()}catch(e){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){const t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}},pe=e=>(()=>{const e=document.querySelector('meta[property="mrf:canonical"][content]'),t=null==e?void 0:e.getAttribute("content");return!!t&&Q(t)||null})()||(()=>{const e=document.querySelector('link[rel="canonical"][href]'),t=null==e?void 0:e.getAttribute("href");return!!t&&Q(t)||null})()||(e=>{if("fbia"===e){const e=document.createElement("a");return e.href=window.ia_document.shareURL,e.origin+e.pathname}return window.location.origin+window.location.pathname})(e),fe={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"},he="scrollHeight",me=document.documentElement,ve=[{qs:".mrf-current .mrf-detailsBody",max:999},{qs:".mrf-current .mrf-sectionPart",max:999},{qs:".mrf-article-body",max:999},{qs:"article",max:1}];let ge,ye=0;const be=(e,t=0,r=!0,n=!1)=>{let i;try{e&&(ge=r||!ge?ve.reduce(((e,t)=>{if(e)return e;const r=document.querySelectorAll(t.qs);return r&&r.length<=t.max?(e=>{const t=[];return e.forEach((e=>(e=>{const t=e.getBoundingClientRect();if(!t.width&&!t.height)return!1;const r=window.innerHeight||document.documentElement.clientHeight,n=window.innerWidth||document.documentElement.clientWidth,i=t.top<=r&&t.top+t.height>=0,o=t.left<=n&&t.left+t.width>=0;return i&&o})(e)&&t.push(e))),t.length>0?t.sort(((e,t)=>t.offsetTop-e.offsetTop))[0]:null})(Array.from(r)):null}),null):ge,ye=0);const n=(e=>{const t=(()=>{const e=document.body;return me.scrollTop||!!e&&e.scrollTop||0})();return e?t-e.offsetTop:t})(ge),o=(e=>{const t=document.body;return e?e.offsetHeight:me[he]||!!t&&t[he]||0})(ge),a=me.clientHeight;i=t?(n+t)/o*100:n/(o-a)*100,i>ye?ye=i:i=ye}catch(e){i=50}return n?i:isNaN(i)?50:i>100?100:i<0?0:i},we={},Oe=(()=>{try{const e="__test_session_storage__";return window.sessionStorage.setItem(e,e),window.sessionStorage.removeItem(e),!0}catch(e){return!1}})(),Pe=(e,t)=>{try{Oe?window.sessionStorage.setItem(e,t):we[e]=t}catch(e){}},Ee=e=>{try{return Oe?window.sessionStorage.getItem(e):we[e]}catch(e){return null}},ke=(e,t)=>{const r=JSON.stringify(t);Pe(e,r)};let Se,je=!0;const Ce={getConsent:()=>je,isInitiated:()=>!0,setConsent:(e,t)=>{var r;je=!0===(r=t)||"true"===r,Pe("__nrCookieConsent",je),Se&&Se()},onChange:e=>{Se=e}};function Te(e){return e||!1===e}function Ae(e){var t;return e.isInitiated()?null!=e&&null!==(t=e.isActive)&&void 0!==t&&t.call(e)?e.getConsent("cookies")?1:0:3:2}class Ie{static wait(){return Promise.resolve(!0)}static resolve(){}}class De{static emitRecirculation(){}}function _e(e,t){return(void 0!==e[t]||null===e[t])&&e[t]}function Ne(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Date;return Math.floor(e.getTime()/1e3)}const Le=e=>{const t=document.cookie.indexOf(e+"="),r=t+e.length+1;if(!t&&e!==document.cookie.substring(0,e.length))return null;if(-1===t)return null;let n=document.cookie.indexOf(";",r);return-1===n&&(n=document.cookie.length),unescape(document.cookie.substring(r,n))},Re=(e,t,r,n,i)=>{const o=i?[i,".".concat(i)]:[""],a=new Date;a.setTime(a.getTime());const s="https:"===window.location.protocol;o.forEach((i=>{document.cookie=e+"="+escape(t)+(r?";expires="+r:"")+(n?";path="+n:"")+(i?";domain="+i:"")+(s?";secure":"")}))},xe={score:"-1"},Me="".concat("https://compassdynamicpaywall.mrf.io","/score/"),Ue="".concat("https://compassdynamicpaywall.mrf.io","/predict/"),Ve=e=>{let{accountId:t,userId:r,siteUserId:n,totalPageviews:i,sessionDuration:o}=e;const a=new URLSearchParams(window.location.search),s=a.get("utm_medium"),c=a.get("utm_source"),u=["ac=".concat(t),"url=".concat(encodeURIComponent(window.location.href)),"u=".concat(r),"pp=".concat(document.referrer)];return n&&u.push("sui=".concat(n)),s&&u.push("utm_medium=".concat(s)),c&&u.push("utm_source=".concat(c)),i&&u.push("tp=".concat(i)),o&&u.push("sd=".concat(o)),u.join("&")};let qe;const Fe={rfv:"-1"},ze=(e,t)=>{const r={rfv:e,ts:new Date};return Pe("".concat("compass_rfv","_").concat(t),JSON.stringify(r)),e},He=(e,t,r)=>{const n=new FormData;return n.append("u",t),n.append("ac",e),n.append("sui",r||""),n},Be=e=>{const{ts:t,rfv:r}=(e=>{const t=Ee("".concat("compass_rfv","_").concat(e));let r={ts:null,rfv:null};if(t)try{r=JSON.parse(t)}catch(e){}return r})(e);return(e=>{if(!e)return!0;const t=new Date(e);return t.setMinutes(t.getMinutes()+30),t{try{const e="__test_local_storage__";return window.localStorage.setItem(e,e),window.localStorage.removeItem(e),!0}catch(e){return!1}})(),We=(e,t)=>{try{Ge?window.localStorage.setItem(e,t):Ke[e]=t}catch(e){}},Je=["data-mrf-recirculation","data-dtm-region","dtm-region"],Xe=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";const t=e?" ".concat(e):e;return Je.map((e=>"[".concat(e,"]").concat(t))).join(",")};function Qe(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $e(e){for(var t=1;te&&e.split("?")[0].split("#")[0],Ze=()=>[...document.body.querySelectorAll(Xe())].filter((e=>e.shadowRoot)),et=e=>null!==e.getAttribute("data-mrf-layout")&&null===e.getAttribute("data-mrf-layout-anchor")?e.querySelector("[".concat("data-mrf-layout-anchor","]")):e,tt=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const r=et(e);if(!r)return null;if(r!==e)return tt(r,t);const n=function(e,t){let r=null;if(r=t?e.getAttribute(t):"mrfLink"in e&&e.mrfLink||e.getAttribute(J)||e.getAttribute("href")||e.getAttribute("data-mrf-uri"),null===r)return null;const n=W(r||"");return"null"===n.origin?null:n.href}(e,t);return n?(e=>!!e&&W(e).host===window.location.host)(n)?n&&Ye(n):n:null};function rt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}const nt=()=>(e=>{const t=(e=>{try{return Ge?window.localStorage.getItem(e):Ke[e]}catch(e){return null}})("___m_rec");if(t)try{return JSON.parse(t)}catch(e){}return null})(),it=(e,t)=>{if(Ge){const r=function(e){for(var t=1;te.hasAttribute("cmp-ltrk"),at=e=>e.hasAttribute("data-mrf-recirculation-skip"),st=e=>e.getAttribute("cmp-ltrk-idx"),ct=(e,t,r)=>{e.setAttribute("cmp-ltrk",t),e.setAttribute("cmp-ltrk-idx","".concat(r))},ut=e=>"[".concat("cmp-ltrk",'="').concat(e,'"]'),lt=(e,t,r)=>{const n=e.map((e=>function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"all";const r=function(){for(var e=arguments.length,r=new Array(e),n=0;n!Boolean(e))))return;const a="missing"===t?":not([".concat(o,"])"):"",s=i.join(" ");return Xe("".concat(s).concat(a))};return{element:r(e.element,"data-mrf-layout"),anchor:e.anchor?r(e.element,e.anchor,"data-mrf-layout-anchor"):r(e.element,"data-mrf-layout-anchor"),img:r(e.element,e.img,"data-mrf-layout-img"),title:r(e.element,e.title,"data-mrf-layout-title")}}(e,"missing")[t])).filter(Boolean).join(",");n&&Array.from(document.querySelectorAll(n)).forEach((e=>e.setAttribute(r,"")))},dt=e=>{e.length&&(lt(e,"element","data-mrf-layout"),lt(e,"anchor","data-mrf-layout-anchor"),lt(e,"img","data-mrf-layout-img"),lt(e,"title","data-mrf-layout-title"))},pt=e=>{const t={};return e.reduce(((e,r)=>{const{el:n}=r,i=(e=>{try{const t=st(e);if(t)return parseInt(t,10)}catch(e){}})(n);return void 0!==i&&t[i]||(e.push(r),t[i]=!0),e}),[])},ft=(e,t)=>{let{el:r}=e;const n={url:tt(r,t)},i=st(r);return i&&(n.p=i),r.getAttribute("data-mrf-experiment")&&(n.tv=r.getAttribute("data-mrf-experiment")),n},ht=(e,t)=>e.map(((e,r)=>{const n=ft(e,t);return parseInt(n.p,10)===r&&delete n.p,n.tv||n.p?n:n.url}));let mt;const vt={};class gt{constructor(){this.timer=null}callOnTimer(e,t){this.timer=setTimeout((()=>{e()}),t)}cleanAndCallTimer(e,t){this.cleanTimer(),this.timer=setTimeout((()=>{e()}),t)}cleanTimer(){null!==this.timer&&(clearTimeout(this.timer),this.timer=null)}}class yt{constructor(){this.store={}}push(e,t){this.store[e]?this.store[e].push(t):this.store[e]=[t]}clear(e){delete this.store[e]}contains(e,t){var r;return null===(r=this.store[e])||void 0===r?void 0:r.includes(t)}forEach(e){return Object.entries(this.store).forEach(e)}}const bt=new gt,wt=new yt,Ot=new yt,Pt=e=>{const t=[];wt.forEach((e=>{let[r,n]=e;t.push({module:r,links:n}),wt.clear(r)})),Object.keys(t).length>0&&e("impression",t)},Et=(e,t)=>{e.forEach((e=>{let{links:r,urlAttr:n,name:i}=e;i&&r.forEach((e=>{const r=ft(e,n);!function(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const n="IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype&&"isIntersecting"in window.IntersectionObserverEntry.prototype?Promise.resolve():a.e(360).then(a.t.bind(a,360,23));e.setAttribute("mrfObservableId",de()),vt[e.getAttribute("mrfObservableId")]=t,n.then((()=>{mt=mt||new IntersectionObserver((e=>{e.filter((e=>e.isIntersecting)).forEach((e=>{let{target:t}=e;const n=t.getAttribute("mrfObservableId");var i;n?(null===(i=vt[n])||void 0===i||i.call(vt,t),r||(mt.unobserve(t),delete vt[n])):mt.unobserve(t)}))})),mt.observe(e)}))}(e.el,(()=>{((e,t)=>{Ot.contains(e,t.p)||(wt.push(e,t),Ot.push(e,t.p))})(i,r),bt.cleanAndCallTimer((()=>Pt(t)),1e3)}))}))})),Pt(t)};function kt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function St(e){for(var t=1;t{const r=e.map((e=>{let{name:t,links:r,urlAttr:n}=e;return{module:t,links:ht(r,n)}}));r.length&&t("elegible",r)},Ct=(e,t)=>{e.forEach((e=>{let{name:r,links:n,urlAttr:i}=e;n.forEach((e=>{e.el.addEventListener("click",(n=>{const o=e.el,a=tt(o,i);var s,c;s=e.el,!n.__mrfTracked&&!0!==(null===(c=et(s))||void 0===c?void 0:c.__mrfTracked)&&a&&(((e,t)=>{const r=et(e);t.__mrfTracked=!0,r&&(r.__mrfTracked=!0)})(e.el,n),it(r||"",a),t("click",[{module:r,links:ht([e],i)}],!1))}))}))}))},Tt=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:()=>!0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document.body,r=arguments.length>2?arguments[2]:void 0;const n=r?"a":Je.map((e=>"[".concat(e,"] a[href], a[href][").concat(e,"], [").concat(e,"] article[data-mrf-uri], [").concat(e,"] [").concat("data-mrf-layout","]"))).join(","),i=Array.from(t.querySelectorAll(n)).reduce(((t,n)=>{const i=(e=>e&&e.closest(Xe()))(n)||r,o=(e=>{var t;return null===(t=Je.reduce(((t,r)=>t||(null==e?void 0:e.getAttribute(r))),void 0))||void 0===t?void 0:t.replace(/"/g,'\\"')})(i),a=(null==i?void 0:i.getAttribute("data-mrf-recirculation-url-attribute"))||"",s=n,c=tt(s,a);if(c&&X(s,c,!1),!o||!c||!e(o,s))return t;const u=t[o]||{links:[]};return St(St({},t),{},{[o]:St(St({},u),{},{links:[...u.links,{el:s,root:i}],urlAttr:a})})}),{});return(e=>{const t=Ze();Object.entries(e).forEach((e=>{let[r,{links:n,urlAttr:i}]=e;const o=(e=>Number(e.map((e=>e.getAttribute("cmp-ltrk-idx"))).filter(Boolean).map(parseInt).reduce(((e,t)=>isNaN(e)||e{const r=t.filter((t=>{return r=e,n=t,Je.some((e=>{var t;return(null===(t=n.getAttribute(e))||void 0===t?void 0:t.toLowerCase())===r.toLowerCase()}));var r,n})).reduce(((t,r)=>{var n;return[...t,...(null===(n=r.shadowRoot)||void 0===n?void 0:n.querySelectorAll(ut(e)))||[]]}),[]);return[...document.querySelectorAll(ut(e)),...r]})(r,t));let a=isNaN(o)?0:o+1;n.forEach((e=>{const{el:t,root:o}=e,s=tt(t,i);if(at(t)||ot(t)||!s)return;ct(t,r,a);const c=n.filter((e=>{let{el:r,root:n}=e;return r!==t&&n===o&&!at(r)&&!ot(r)&&tt(r,i)===s}));c.length&&(c.forEach((e=>{let{el:t}=e;return ct(t,r,a)})),(e=>{["data-mrf-experiment"].forEach((t=>{const r=e.find((e=>{let{el:t}=e;return t.hasAttribute("data-mrf-experiment")}));if(r){const n=r.el.getAttribute("data-mrf-experiment");e.forEach((e=>{let{el:r}=e;r.getAttribute("data-mrf-experiment")!==n&&r.setAttribute(t,n||"")}))}}))})([...c,e])),a++}))}))})(i),Object.entries(i).map((e=>{let[t,r]=e;return{name:t,links:r.links,urlAttr:r.urlAttr}}))},At=e=>e.map((e=>{let{links:t,name:r,urlAttr:n}=e;return{name:r,urlAttr:n,links:pt(t)}}));function It(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:()=>{},t=arguments.length>1?arguments[1]:void 0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{parentNode:n,layouts:i=[]}=r;dt(i);const o=Tt(((e,t)=>!ot(t)&&!at(t)),t,n),a=At(o);return jt(a,e),Et(o,e),Ct(o,e),o.length}function Dt(e,t,r,n){It(e,t,r)&&n(),z((t=>{It(e,t,r)&&n()}),t)}const _t=async()=>{document&&"loading"===document.readyState&&await new Promise((e=>{document.addEventListener("DOMContentLoaded",e)}))},Nt=(e,t)=>{e&&t&&it("fc:".concat(e),t)},Lt=e=>{let{modules:t,blacklist:r,redirectionLinks:n}=e,i=!1;return r.forEach((e=>{let{selector:t}=e;const r=document.querySelectorAll(t);Array.from(r).forEach((e=>{e instanceof HTMLElement&&!e.hasAttribute("data-mrf-recirculation-skip")&&e.setAttribute("data-mrf-recirculation-skip","")}))})),null==n||n.forEach((e=>{let{selector:t,queryParam:r}=e;const n=document.querySelectorAll(t);Array.from(n).forEach((e=>{if(!e.hasAttribute("data-mrf-recirculation-skip"))try{const n=(t=new URL(decodeURIComponent(decodeURIComponent(e.href))).search).length?t.slice(1).split("&").map((e=>e.split("="))).reduce(((e,t)=>{let[r,n]=t;return $e($e({},e),{},{[r]:n})}),{}):{};n[r]&&X(e,decodeURIComponent(n[r]))}catch(e){}var t}))})),t.forEach((e=>{const t="selector"in e?e.selector:"[".concat(e.attr,"]"),r="name"in e?()=>e.name:t=>t.getAttribute(e.attr),n=document.querySelectorAll(t),o=e.urlAttribute;Array.from(n).forEach((e=>{(e=>(e=>(null===window||void 0===window?void 0:window.HTMLElementOrig)?e instanceof window.HTMLElementOrig:e instanceof HTMLElement)(e)&&!e.hasAttribute("data-mrf-recirculation-skip")&&!e.hasAttribute("data-mrf-recirculation")&&!e.closest("[data-mrf-experience]"))(e)&&(e.setAttribute("data-mrf-recirculation",r(e)),o&&e.setAttribute("data-mrf-recirculation-url-attribute",o),i=!0)}))})),i};var Rt,xt,Mt,Ut,Vt,qt=function(){return window.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]},Ft=function(e){if("loading"===document.readyState)return"loading";var t=qt();if(t){if(e(t||100)-1)return r||i;if(r=r?i+">"+r:i,n.id)break;e=n.parentNode}}catch(e){}return r},Bt=-1,Kt=function(){return Bt},Gt=function(e){addEventListener("pageshow",(function(t){t.persisted&&(Bt=t.timeStamp,e(t))}),!0)},Wt=function(){var e=qt();return e&&e.activationStart||0},Jt=function(e,t){var r=qt(),n="navigate";return Kt()>=0?n="back-forward-cache":r&&(document.prerendering||Wt()>0?n="prerender":document.wasDiscarded?n="restore":r.type&&(n=r.type.replace(/_/g,"-"))),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:"v3-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12),navigationType:n}},Xt=function(e,t,r){try{if(PerformanceObserver.supportedEntryTypes.includes(e)){var n=new PerformanceObserver((function(e){Promise.resolve().then((function(){t(e.getEntries())}))}));return n.observe(Object.assign({type:e,buffered:!0},r||{})),n}}catch(e){}},Qt=function(e,t,r,n){var i,o;return function(a){t.value>=0&&(a||n)&&((o=t.value-(i||0))||void 0===i)&&(i=t.value,t.delta=o,t.rating=function(e,t){return e>t[1]?"poor":e>t[0]?"needs-improvement":"good"}(t.value,r),e(t))}},$t=function(e){requestAnimationFrame((function(){return requestAnimationFrame((function(){return e()}))}))},Yt=function(e){var t=function(t){"pagehide"!==t.type&&"hidden"!==document.visibilityState||e(t)};addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0)},Zt=function(e){var t=!1;return function(r){t||(e(r),t=!0)}},er=-1,tr=function(){return"hidden"!==document.visibilityState||document.prerendering?1/0:0},rr=function(e){"hidden"===document.visibilityState&&er>-1&&(er="visibilitychange"===e.type?e.timeStamp:0,ir())},nr=function(){addEventListener("visibilitychange",rr,!0),addEventListener("prerenderingchange",rr,!0)},ir=function(){removeEventListener("visibilitychange",rr,!0),removeEventListener("prerenderingchange",rr,!0)},or=function(){return er<0&&(er=tr(),nr(),Gt((function(){setTimeout((function(){er=tr(),nr()}),0)}))),{get firstHiddenTime(){return er}}},ar=function(e){document.prerendering?addEventListener("prerenderingchange",(function(){return e()}),!0):e()},sr=[1800,3e3],cr=function(e,t){t=t||{},ar((function(){var r,n=or(),i=Jt("FCP"),o=Xt("paint",(function(e){e.forEach((function(e){"first-contentful-paint"===e.name&&(o.disconnect(),e.startTime=0&&xt1e12?new Date:performance.now())-e.timeStamp;"pointerdown"==e.type?function(e,t){var r=function(){pr(e,t),i()},n=function(){i()},i=function(){removeEventListener("pointerup",r,lr),removeEventListener("pointercancel",n,lr)};addEventListener("pointerup",r,lr),addEventListener("pointercancel",n,lr)}(t,e):pr(t,e)}},mr=function(e){["mousedown","keydown","touchstart","pointerdown"].forEach((function(t){return e(t,hr,lr)}))},vr=[100,300],gr=0,yr=1/0,br=0,wr=function(e){e.forEach((function(e){e.interactionId&&(yr=Math.min(yr,e.interactionId),br=Math.max(br,e.interactionId),gr=br?(br-yr)/7+1:0)}))},Or=function(){return Vt?gr:performance.interactionCount||0},Pr=[200,500],Er=0,kr=function(){return Or()-Er},Sr=[],jr={},Cr=function(e){var t=Sr[Sr.length-1],r=jr[e.interactionId];if(r||Sr.length<10||e.duration>t.latency){if(r)r.entries.push(e),r.latency=Math.max(r.latency,e.duration);else{var n={id:e.interactionId,latency:e.duration,entries:[e]};jr[n.id]=n,Sr.push(n)}Sr.sort((function(e,t){return t.latency-e.latency})),Sr.splice(10).forEach((function(e){delete jr[e.id]}))}},Tr=[2500,4e3],Ar={};class Ir{constructor(){this.cls=0,this.lcp=0,this.fid=0,this.fcp=0,this.wv=0,this.tbt=0,this.inp=0,this.lcpOffender=null,this.clsOffender=null,this.inpOffender=null,this.setTbt(),this.setINP(),this.setLCP(),this.setFCP(),this.setFID(),this.setCLS()}hasWebVitals(){return this.lcp||this.fcp||this.cls||this.fid||this.inp?1:0}setLCP(){var e;e=e=>{var t;this.lcp=e.value,this.lcp>2500&&null!==(t=e.attribution)&&void 0!==t&&t.element&&(this.lcpOffender=e.attribution.element)},function(e,t){t=t||{},ar((function(){var r,n=or(),i=Jt("LCP"),o=function(e){var t=e[e.length-1];t&&t.startTimethis.fcp=e.value,cr((function(t){!function(e){if(e.entries.length){var t=qt(),r=e.entries[e.entries.length-1];if(t){var n=t.activationStart||0,i=Math.max(0,t.responseStart-n);return void(e.attribution={timeToFirstByte:i,firstByteToFCP:e.value-i,loadState:Ft(e.entries[0].startTime),navigationEntry:t,fcpEntry:r})}}e.attribution={timeToFirstByte:0,firstByteToFCP:e.value,loadState:Ft(Kt())}}(t),e(t)}),void 0)}setFID(){var e;e=e=>this.fid=e.value,function(e,t){t=t||{},ar((function(){var r,n=or(),i=Jt("FID"),o=function(e){e.startTime{var t,r;this.inp=e.value,this.inp>200&&null!==(t=e.attribution)&&void 0!==t&&t.eventTarget&&(this.inpOffender="".concat(null===(r=e.attribution)||void 0===r?void 0:r.eventType,"::").concat(e.attribution.eventTarget),this.inpOffenderStatus=e.attribution.loadState)},function(e,t){t=t||{},ar((function(){"interactionCount"in performance||Vt||(Vt=Xt("event",wr,{type:"event",buffered:!0,durationThreshold:0}));var r,n=Jt("INP"),i=function(e){e.forEach((function(e){e.interactionId&&Cr(e),"first-input"===e.entryType&&!Sr.some((function(t){return t.entries.some((function(t){return e.duration===t.duration&&e.startTime===t.startTime}))}))&&Cr(e)}));var t,i=(t=Math.min(Sr.length-1,Math.floor(kr()/50)),Sr[t]);i&&i.latency!==n.value&&(n.value=i.latency,n.entries=i.entries,r())},o=Xt("event",i,{durationThreshold:t.durationThreshold||40});r=Qt(e,n,Pr,t.reportAllChanges),o&&(o.observe({type:"first-input",buffered:!0}),Yt((function(){i(o.takeRecords()),n.value<0&&kr()>0&&(n.value=0,n.entries=[]),r(!0)})),Gt((function(){Sr=[],Er=Or(),n=Jt("INP"),r=Qt(e,n,Pr,t.reportAllChanges)})))}))}((function(t){!function(e){if(e.entries.length){var t=e.entries.sort((function(e,t){return t.duration-e.duration||t.processingEnd-t.processingStart-(e.processingEnd-e.processingStart)}))[0];e.attribution={eventTarget:Ht(t.target),eventType:t.name,eventTime:t.startTime,eventEntry:t,loadState:Ft(t.startTime)}}else e.attribution={}}(t),e(t)}),void 0)}setTbt(){return!!((e,t)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver((e=>{e.getEntries().map((e=>t(e)))}));return r.observe({type:e,buffered:!0}),r}}catch(e){}})("longtask",(e=>{this.tbt+=e.duration-50}))}setCLS(){var e;e=e=>{var t;this.cls=e.value,this.cls>.1&&null!==(t=e.attribution)&&void 0!==t&&t.largestShiftTarget&&(this.clsOffender=e.attribution.largestShiftTarget,this.clsOffenderStatus=e.attribution.loadState)},function(e,t){t=t||{},cr(Zt((function(){var r,n=Jt("CLS",0),i=0,o=[],a=function(e){e.forEach((function(e){if(!e.hadRecentInput){var t=o[0],r=o[o.length-1];i&&e.startTime-r.startTime<1e3&&e.startTime-t.startTime<5e3?(i+=e.value,o.push(e)):(i=e.value,o=[e])}})),i>n.value&&(n.value=i,n.entries=o,r())},s=Xt("layout-shift",a);s&&(r=Qt(e,n,ur,t.reportAllChanges),Yt((function(){a(s.takeRecords()),r(!0)})),Gt((function(){i=0,n=Jt("CLS",0),r=Qt(e,n,ur,t.reportAllChanges),$t((function(){return r()}))})),setTimeout(r,0))})))}((function(t){!function(e){if(e.entries.length){var t=e.entries.reduce((function(e,t){return e&&e.value>t.value?e:t}));if(t&&t.sources&&t.sources.length){var r=(n=t.sources).find((function(e){return e.node&&1===e.node.nodeType}))||n[0];if(r)return void(e.attribution={largestShiftTarget:Ht(r.node),largestShiftTime:t.startTime,largestShiftValue:t.value,largestShiftSource:r,largestShiftEntry:t,loadState:Ft(t.startTime)})}}var n;e.attribution={}}(t),e(t)}),void 0)}}function Dr(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function _r(e){for(var t=1;t{Nr.cleanTimer()},xr=(e,t)=>{Nr.callOnTimer(t,e)},{userIdPromise:Mr,resolveFinalUserId:Ur}=(()=>{let e=()=>{};return{userIdPromise:new Promise((t=>{e=t})),resolveFinalUserId:e}})();class Vr{constructor(e){this.compassTracker=e}getUserId(){return{userIdPromise:Mr,actualUserId:this.compassTracker.permanentCookie.userId}}processIngestResponse(e){e&&(le(e.uid)&&(this.compassTracker.permanentCookie.userId=e.uid,this.compassTracker.markAsModified("permanent")),le(e.sid)&&(this.compassTracker.temporalCookie.sessionId=e.sid,this.compassTracker.markAsModified("temporal")),this.compassTracker.saveCookies()),le(this.compassTracker.permanentCookie.userId)&&Ur(this.compassTracker.permanentCookie.userId)}}const qr={web:0,fbia:2,iosapp:3,androidapp:4,flowcards:5,pressreader:6,app:7,applenews:8,pressreaderandroid:11,pressreaderios:12},Fr=e=>{if(isNaN(e)){const t=e.toLowerCase().replace(/ /g,"");return void 0!==qr[t]?qr[t]:null}return e};function zr(e,t,r){if(null==r||""===r){let r=0;for(;r{zr(Hr,e,t)};let Kr=null;const Gr=()=>Kr=null,Wr=e=>{const t=e.parentElement;t&&(t.addEventListener("mouseenter",(()=>(e=>{Kr=e})(e))),t.addEventListener("mouseleave",Gr))},Jr=(e,t,r)=>{const n=Array.from(e).filter((e=>!e.hasAttribute("cmp-cnvtrk")));for(const e of n)e.addEventListener(t,(()=>{const t=e.dataset.mrfConversion;t&&r(t)})),e.setAttribute("cmp-cnvtrk","true")},Xr=e=>{const t=document.querySelectorAll("iframe[data-mrf-conversion]"),r=document.querySelectorAll("form[data-mrf-conversion]"),n=document.querySelectorAll("button[data-mrf-conversion], a[data-mrf-conversion]");Jr(r,"submit",e),Jr(n,"click",e),(e=>{const t=Array.from(e).filter((e=>!e.hasAttribute("cmp-cnvtrk")));for(const e of t)Wr(e),e.setAttribute("cmp-cnvtrk","true")})(t)},Qr=e=>{z((()=>{Xr(e)})),Xr(e)};var $r;function Yr(e){return e.update=Date.now(),function(e,t){try{return window.localStorage.setItem("marfeel-sdk-store",t),!0}catch(e){return!1}}(0,btoa(JSON.stringify(e)))}function Zr(){return void 0===$r&&($r=function(){var e=function(e){try{return window.localStorage.getItem("marfeel-sdk-store")}catch(e){return null}}();if(e)return JSON.parse(atob(e));var t={creation:Date.now(),update:Date.now(),entries:{}};return Yr(t),t}()),$r}const en="compass-conversions-counter-entry",tn=e=>{let t=(null!=e?e:"").toString();return!t.startsWith("/")&&t.includes("/")&&(t="/".concat(t)),t.split("/").map((e=>e.split(",").shift())).join("/")};class rn{constructor(){this.newAds=[],this.newAdUnitPaths=[],this.visibilityChangedSlots=[]}setInterstitialSlot(e){this.interstitialSlot=e}trackAdEvent(e,t){const r=this.mustBeTracked(e,t);if(r){const r=t.getAdUnitPath(),n=t.getResponseInformation()&&t.getResponseInformation().lineItemId;this.trackAdRenderedInternal(n||r,r),"slotVisibilityChanged"===e&&this.visibilityChangedSlots.push(t)}return r}trackAdEventLegacy(e,t,r){return"slotRenderEnded"===e&&(this.trackAdRenderedInternal(t||r,r),!0)}trackAdRenderedInternal(e,t){this.newAds.push(tn(e)),t&&this.newAdUnitPaths.push(tn(t))}getAds(){return this.newAds.splice(0)}getAdUnits(){return this.newAdUnitPaths.splice(0)}mustBeTracked(e,t){let r=!1;return"slotRenderEnded"===e&&(r=t!==this.interstitialSlot),"slotVisibilityChanged"===e&&(r=t===this.interstitialSlot&&!this.visibilityChangedSlots.includes(t)),r}}function nn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function on(e){for(var t=1;t{((e,t)=>{const r={requests:{ads:e},triggers:{renderEnd:{on:"ad-render-end",request:"ads",selector:"body",extraUrlParams:on(on({},t),{},{l:"${totalEngagedTime}",sc:be(!1),a:"-1",ps:"${navTiming(navigationStart)}",n:"${timestamp}",ads:"$IF(${adSlot}, ${adSlot}, -1)amp",ampFirst:"true"})}},transport:{beacon:!0,xhrpost:!0,image:!1}},n=()=>{document.body.appendChild((e=>{const t=document.createElement("amp-analytics"),r=document.createElement("script");return r.type="application/json",r.innerText=JSON.stringify(e),t.appendChild(r),t})(r))};"loading"===document.readyState?window.addEventListener("load",(()=>n())):n()})(e,t)};class sn{constructor(){this.events={}}on(e,t){void 0===this.events[e]&&(this.events[e]={listeners:[]}),this.events[e].listeners.push(t)}remove(e,t){this.events[e].listeners=this.events[e].listeners.filter((e=>e.toString()!==t.toString()))}dispatch(e,t){this.events[e]&&this.events[e].listeners.forEach((e=>{e(t)}))}}function cn(e,t){try{const r=[...t],n=r.shift();let i;if(Array.isArray(e)){const r=e.map((e=>cn(e,t))).filter(Boolean);i=r.length&&r[0]}else i=e[n];return 0===r.length?i?null==i?void 0:i.toString():null:cn(i,r)}catch(e){return null}}const un=(e,t)=>"@id"in e&&e["@id"]===t,ln=["Article","NewsArticle","Recipe","BlogPosting","LiveBlogPosting","ReportageNewsArticle","OpinionNewsArticle","AdvertiserContentArticle","Report","SatiricalArticle","ScholarlyArticle","SocialMediaPosting","TechArticle","AnalysisNewsArticle","AskPublicNewsArticle","BackgroundNewsArticle","ReviewNewsArticle"];var dn=Object.freeze({__proto__:null,ARTICLE_ENTITY_TYPES_PRIORITIES:ln,extract:function({attributePath:e,entitiesConstraint:t},r){try{const n=document.querySelectorAll('script[type="application/ld+json"]');return n&&e?function(e,t){for(const r of e){const e=cn(r,t);if(e)return e}return null}(function(e,t,r){const n=(e=>Array.from(e).map((e=>{var t;try{const r=e.textContent?((null===(t=e.textContent)||void 0===t?void 0:t.trim())||"").replace(/\n|\t/g,""):"{}";return JSON.parse(`${r}`)}catch(e){return null}})).filter(Boolean).map((e=>e instanceof Array?e:[e])).map((e=>e.map((e=>(e=>{if("@graph"in e){const t=e["@graph"];if(t instanceof Array)return[e,...t];if(t)return[e,t]}return[e]})(e))).flat())).flat())(e);return((e,t,r)=>{const n=e[0]instanceof Array?e:[e];return(void 0===r?n:n.map((e=>{const n=e.filter((e=>"mainEntityOfPage"in e&&!!e.mainEntityOfPage));return n.length?1===n.length?n:n.filter((e=>{const n=e.mainEntityOfPage;if("string"==typeof n)return n===r;if(un(n,r))return!0;if("@id"in n&&"string"==typeof n["@id"]){const e=(i=t,o=n["@id"],i.find((e=>un(e,o))));return!!e&&"url"in e&&e.url===r}var i,o;return!1})):e}))).flat()})(function(e,t,r=!1){const n=e.filter((e=>{const r=cn(e,["@type"]);return!t||!!r&&t.includes(r)})).sort(((e,r)=>t?t.indexOf(cn(e,["@type"]))-t.indexOf(cn(r,["@type"])):0));return r?n.reduce(((e,t)=>{let r=e.at(-1);return r||(r=[],e.push(r)),r.at(-1)&&cn(r.at(-1),["@type"])!==cn(t,["@type"])?e.push([t]):r.push(t),e}),[]):n}(n,t,!0),n,r)}(n,t,r),e):null}catch(e){return null}}});const pn=/^(\d{4})-(\d{2})-(\d{2})T(\d{2}):(\d{2}):(\d{2})(\.\d+)?(Z|[+-]\d{2}:\d{2})$/;function fn(e){let t;return t=pn.test(e)?new Date(e):new Date(e+"Z"),t.getTime()}const hn={jsonLD:dn,querySelector:Object.freeze({__proto__:null,extract:function({queries:e}){if(!e)return null;const t=e.reduce(((e,{query:t,attribute:r})=>(document.querySelectorAll(t).forEach((t=>{r?e.push(t.getAttribute(r)||null):t.textContent&&e.push(t.textContent)})),e)),[]).filter((e=>null!==e));return 1===t.length||t.length>1&&t.every((e=>e===t[0]||fn(e)===fn(t[0])))?t[0]:null}})},mn=(e,t)=>{for(const r of e){const e=hn[r.type].extract(r,t);if(e)return e}return null},vn=[{type:"jsonLD",attributePath:["dateModified"],entitiesConstraint:ln},{type:"querySelector",queries:[{query:'meta[property="article:modified_time"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'meta[itemprop="dateModified"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'time[itemprop="dateModified"]',attribute:"datetime"}]},{type:"querySelector",queries:[{query:'time[itemprop="dateModified"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'[itemprop="dateModified"]'}]}];var gn=Object.freeze({__proto__:null,extract:e=>mn(vn,e)});const yn=[{type:"jsonLD",attributePath:["datePublished"],entitiesConstraint:ln},{type:"querySelector",queries:[{query:'[itemtype="http://schema.org/NewsArticle"] time[itemprop="datePublished"]',attribute:"datetime"}]},{type:"querySelector",queries:[{query:'meta[property="article:published_time"]',attribute:"content"},{query:':not([itemprop="image"]) > meta[itemprop="datePublished"]',attribute:"content"},{query:'time[itemprop="datePublished"]',attribute:"datetime"},{query:'time[itemprop="datePublished"]',attribute:"content"},{query:'meta[name="cXenseParse:recs:publishtime"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'[itemprop="datePublished"]'}]}];var bn=Object.freeze({__proto__:null,extract:e=>mn(yn,e)});const wn=[{type:"jsonLD",attributePath:["offers","lowPrice"],entitiesConstraint:["Product"]},{type:"jsonLD",attributePath:["offers","price"],entitiesConstraint:["Product"]},{type:"querySelector",queries:[{query:'[itemprop="offers"] [itemprop="price"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'meta[property="product:price:amount"]',attribute:"content"}]}];var On=Object.freeze({__proto__:null,extract:e=>mn(wn,e)});const Pn=[{type:"jsonLD",attributePath:["offers","availability"],entitiesConstraint:["Product"]},{type:"querySelector",queries:[{query:'[itemprop="offers"] link[itemprop="availability"]',attribute:"href"},{query:'[itemprop="offers"] [itemprop="availability"]',attribute:"content"}]},{type:"querySelector",queries:[{query:'meta[property="product:availability"]',attribute:"content"}]}],En={updateTime:gn,publishTime:bn,availability:Object.freeze({__proto__:null,extract:e=>mn(Pn,e)}),price:On},kn=(e,t)=>En[e].extract(t),Sn=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];try{if(t){const t=Le(e);return JSON.parse(t)||{}}return(e=>{const t=Ee(e);if(t)try{return JSON.parse(t)}catch(e){}return null})(e)||{}}catch(e){return{}}},jn=function(e,t){let r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];const n=t?Sn("".concat(e,"_").concat(t),r):null;return n&&0!==Object.keys(n).length?n:Sn(e,r)};function Cn(e,t){let r=0;return e.active&&(r=5),Math.min(t-e.time,r)}class Tn{constructor(){this.totalEngagedTime=0,this.prevEvent=void 0}pushEvent(e){this.prevEvent&&this.prevEvent.time{document.addEventListener(e,(()=>this.eventTriggered(!0)))})),In.forEach((e=>{document.addEventListener(e,(()=>this.eventTriggered(!1)))})),N((()=>this.eventTriggered(!1))),L((()=>this.eventTriggered(!0)))}getTimeSinceStart(){const e=Date.now()-this.startTime;return e>0?e:0}eventTriggered(e){e&&this.listeningActive||!e&&this.listeningInactive||(this.listeningActive=e,this.listeningInactive=!e,this.handleEvent(e))}handleEvent(e){const t=Math.floor(this.getTimeSinceStart()/1e3);setTimeout((()=>{this.listeningActive=!1,this.listeningInactive=!1}),1e3),this.acitvityHistory.pushEvent({active:e,time:t})}getTotalEngagedTime(){const e=Math.floor(this.getTimeSinceStart()/1e3);return this.acitvityHistory.getTotalEngagedTime(e)}}function _n(){let e=arguments.length>1?arguments[1]:void 0,t=!1;(arguments.length>0&&void 0!==arguments[0]?arguments[0]:[]).forEach((e=>{let{selector:r,name:n}=e;document.querySelectorAll(r).forEach((e=>{e.getAttribute("data-mrf-conversion")||(t=!0,e.setAttribute("data-mrf-conversion",n))}))})),t&&Xr(e)}function Nn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}const Ln=function(e){const t=e=>e&&"object"==typeof e;for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i(Object.keys(r).forEach((n=>{const i=e[n],o=r[n];Array.isArray(i)&&Array.isArray(o)?e[n]=[...i].concat(...o):t(i)&&t(o)?e[n]=Ln(i,o):e[n]=o})),e)),e)},Rn=e=>[...new Set(e)],xn="".concat("https://experiences.mrf.io","/passexperience/dw-check.html?v=6");let Mn=!1;function Un(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Vn(e){for(var t=1;t{const e=new Date;return e.setMonth(e.getMonth()+6),e.toGMTString()};class Fn{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Ce,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Ie,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:De;var i;this.trackerName=window.__mrfCompass?"__mrfCompass":"__newsroom_js",window[this.trackerName].data=window[this.trackerName].data||[],this.handleImmediateCallsToDataArray(),this.userIdManager=new Vr(this),this.tracker=window[this.trackerName],this.accountId=this.tracker.accountId,this.cookieDomain=this.tracker.cookieDomain||(e=>{const t=e.split(".").filter((e=>"www"!==e));if(t.length<2||G.test(e))return null;if(2===t.length)return t.join(".");const r=t.slice(-2),n=t.length-1;return(e=>{const t=e.length-1;return 2===e[t].length&&!!["avz","co","com","df","gob","gov","org","rt"].includes(e[t-1])})(r)&&r.unshift(t[n-2]),r.join(".")})(window.location.hostname),this.initFlags(),this.adsTracker=new rn,this.adsDelay=200,this.consentManager=t,this.setupConsent(this.tracker),this.synchronizer=r,this.events=n,this.dispatcher=new sn,this.initializeCookies(),this.tracker.lazy||this.initialize(),this.synchronizer.wait("pageInitialized").then((()=>{N((()=>{(e=>{this.synchronizer.resolve("experimentationDisabled",!1)})(),this.setPageVar("lastEvent",!0,!1),this.collectAndTrackPage()})),L((()=>{Rr(),this.trackPage()}))})),i=()=>this.trackNewPage({rs:"back forward cache"}),window.addEventListener("pageshow",(e=>{e.persisted&&i()}),{capture:!0}),function(e,t,r){r?an(e,t):window.customElements.whenDefined("amp-ad").then((()=>an(e,t)))}(this.endpoint,this.getBasicConfig(),this.tracker.isAmpFirst),this.tracker.setFCSource=Nt,this.contextVariables={}}initFlags(){this.tracker.lazy=this.tracker.lazy||!1,this.tracker.isAmpFirst=this.tracker.isAmpFirst||!1,this.tracker.isCookieSandboxed=this.tracker.isCookieSandboxed||[1464,3838].includes(this.accountId),(window.navigator.userAgent.includes("Chrome-Lighthouse")||"Mozilla/5.0 (Linux; Android 11; moto g power (2022)) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Mobile Safari/537.36"===window.navigator.userAgent)&&(this.tracker.keepalive=!1);const e=Vn({lazy:!1,layouts:[],modules:[]},this.tracker.rm||{});this.tracker.rm=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];const r={},n=function(e){for(var t=1;tObject.assign(r,{set:t=>{const r=t instanceof Function?t(n):t;e(Ln(n,r))}}))),r);return t&&o.set({}),o}(e,!e.lazy),this.tracker.usePerformanceEndpoint=this.tracker.usePerformanceEndpoint||!1,this.tracker.adsTrackingFromClient&&(this.nrGoogleTrackingActive=!0)}setInterstitialSlot(e){this.adsTracker.setInterstitialSlot(e)}initializeCookies(){const e=this.consentManager.getConsent("cookies");this.temporalCookie=function(e){const t=_e(e,"currentVisitStarted"),r=new Date;return r.setDate(r.getDate()-1),t&&t0&&void 0!==arguments[0]?arguments[0]:{};this.engagementCalculator=new Dn,this.performanceStartTime=performance.now();const{url:t,rs:r,initialPageVars:n}=((e,t)=>e?"string"==typeof e?{url:e}:e:{})(e),i=t?Q(t):t;Rr(),Hr=[],n&&await Promise.all(Object.entries(n).map((async e=>{let[t,r]=e;return await this.setPageVar(t,r,!1)}))),window.googletag=window.googletag||{},window.googletag.cmd=window.googletag.cmd||[],void 0===this.nrGoogleTrackingActive&&(this.nrGoogleTrackingActive=!0,googletag.cmd.push((()=>{googletag.pubads().addEventListener("slotRenderEnded",(e=>{e.isEmpty||this.trackAdEvent("slotRenderEnded",e.slot)})),googletag.pubads().addEventListener("slotVisibilityChanged",(e=>{this.trackAdEvent("slotVisibilityChanged",e.slot)}))})));const o=!this.tick&&(e=>{var t,r;return"back forward cache"!==e&&"back_forward"===(null===(t=performance)||void 0===t||null===(r=t.getEntriesByType)||void 0===r||null===(r=r.call(t,"navigation"))||void 0===r||null===(r=r[0])||void 0===r?void 0:r.type)})(r)?"back forward":r;this.temporalCookieModified=!1,this.permanentCookieModified=!1,this.adsTracked=!1,this.pageId=null,this.isFirstPage=!0,this.recirculationSource=null,this.updateTime=null,this.publishTime=null,this.newAds=[],this.newAdUnitPaths=[],this.conversion=null,this.tick=0,this.endpoint=this.tracker.endpoint||"https://events.newsroom.bi/ingest.php",this.endpointDomain=(e=>{const t=document.createElement("a");return t.href=e,t.origin})(this.endpoint),this.currentPage=i||B(this.tracker.pageType),this.startPageTime=Ne(),this.pageId=de(),this.url=i||B(this.tracker.pageType),this.canonical=i||pe(this.tracker.pageType),this.setFirstVisit(),this.setPreviousVisit(),this.setCurrentVisitStarted(),this.setTimesVisited(),this.setPagesViewed(),this.setLandingPage(i),this.setRecirculationSource(o),this.saveCookies(),this.webVitals=new Ir,this.updateTime=kn("updateTime",this.canonical),this.publishTime=kn("publishTime",this.canonical),document.prerendering&&(await this.setPageVar("mrfprerendering","prerendered",!1),await this.setPageVar("mrfprerendered_tracked","true",!1),document.addEventListener("prerenderingchange",(()=>{this.setPageVar("mrfprerendering","loaded",!1)})));const a=this.trackPage();return this.setRecirculationTracking(),(e=>{const t=e.trackConversion.bind(e);(e=>{window.addEventListener("blur",(()=>(e=>{Kr&&e(Kr)})(e)))})((e=>{var r;return e&&t(null==e||null===(r=e.dataset)||void 0===r?void 0:r.mrfConversion)})),document.readyState&&"complete"===document.readyState?Qr(t):document.addEventListener("DOMContentLoaded",(()=>{Qr(t)}))})(this),this.dispatcher.dispatch("pageInitialized",{url:this.canonical}),this.synchronizer.resolve("pageInitialized"),a}handleImmediateCallsToDataArray(){window[this.trackerName].data.oldPush=window[this.trackerName].data.push,window[this.trackerName].data.push=e=>{"getRFV"===e[0]?this.getRFV(e[1]):window[this.trackerName].data.oldPush(e)}}setFirstVisit(){let e=_e(this.permanentCookie,"firstVisit");if(!1===e){e=Ne(),this.permanentCookie.firstVisit=e;const t=Le("compass_uid");this.permanentCookie.userId=t?le(t)?t:((e,t)=>{const r=ue(`${e}`,"c0a334de-7622-4bd6-8bff-0b2b750cf2c6");return ue(`${t}`,r)})(this.accountId,t):de(),this.permanentCookie.userVars=[],this.markAsModified("permanent")}else this.permanentCookie.userVars=this.permanentCookie.userVars||[]}setPreviousVisit(){const e=_e(this.temporalCookie,"previousVisit"),t=_e(this.permanentCookie,"futurePreviousVisit");if(!1===e&&!1!==t)this.temporalCookie.previousVisit=t,this.permanentCookie.futurePreviousVisit=Ne(),this.markAsModified("temporal"),this.markAsModified("permanent");else if(!1===e&&!1===t){const e=Ne();this.temporalCookie.previousVisit=e,this.permanentCookie.futurePreviousVisit=e,this.markAsModified("temporal"),this.markAsModified("permanent")}}setCurrentVisitStarted(){let e=_e(this.temporalCookie,"currentVisitStarted");!1===e?(e=Ne(),this.temporalCookie.currentVisitStarted=e,this.markAsModified("temporal"),this.temporalCookie.sessionId=de(),this.temporalCookie.sessionVars=[]):this.isFirstPage=!1}setTimesVisited(){let e=_e(this.permanentCookie,"timesVisited");!1!==_e(this.temporalCookie,"visitedInThisSession")&&!1!==e||(e=!1===e||isNaN(parseInt(e,10))?1:e+1,this.permanentCookie.timesVisited=e,this.temporalCookie.visitedInThisSession=!0,this.markAsModified("permanent"),this.markAsModified("temporal"))}setPagesViewed(){let e=_e(this.temporalCookie,"pagesViewed");e=!1===e||isNaN(parseInt(e,10))?1:e+1,this.temporalCookie.pagesViewed=e,this.markAsModified("temporal")}setLandingPage(e){!1===_e(this.temporalCookie,"landingPage")&&(this.temporalCookie.landingPage=e||B(this.tracker.pageType),this.temporalCookie.referrer=K(this.tracker.pageType),this.markAsModified("temporal"))}getLandingPage(){var e;return null===(e=this.temporalCookie)||void 0===e?void 0:e.landingPage}setRecirculationSource(e){if(e)this.recirculationSource=e;else{const e=(e=>{const t=((e,t)=>W(e).search.substring(1).split("&").map((e=>e.split("="))).filter((e=>{let[t]=e;return"utm_cmp_rs"===t})).map((e=>{let[t,r]=e;return decodeURIComponent(r)})).shift())(e);return t||(e=>{const t=Ye(e),r=nt(),n=pe();return r&&(r[t]||r[n])})(e)})(this.currentPage);e&&(this.recirculationSource=e,(e=>{const t=Ye(e),r=nt();r&&(delete r[t],We("___m_rec",JSON.stringify(r)))})(this.currentPage),(e=>"refresh"===e)(e)&&(this.previousPage=this.canonical))}}saveTemporalCookie(e){const t=this.tracker.isCookieSandboxed?"".concat("___nrbic","_").concat(this.accountId):"___nrbic";e&&Re(t,JSON.stringify(this.temporalCookie),null,"/",this.cookieDomain),ke(t,this.temporalCookie)}savePermanentCookie(e){const t=this.tracker.isCookieSandboxed?"".concat("___nrbi","_").concat(this.accountId):"___nrbi";if(e){const e=qn(),{actualUserId:r}=this.userIdManager.getUserId();Re(t,JSON.stringify(this.permanentCookie),e,"/",this.cookieDomain),this.saveAmpPermanentCookie(r)}ke(t,this.permanentCookie)}saveAmpPermanentCookie(e){e&&Re("compass_uid",e,arguments.length>1&&void 0!==arguments[1]&&!arguments[1]?void 0:qn(),"/",this.cookieDomain)}saveCookies(){let{force:e}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=this.consentManager.getConsent("cookies");this.temporalCookie&&(this.temporalCookieModified||e)&&this.saveTemporalCookie(t),this.permanentCookie&&(this.permanentCookieModified||e)&&this.savePermanentCookie(t)}markAsModified(e){this[e+"CookieModified"]=!0}getReferrer(){return this.previousPage?this.previousPage:K(this.tracker.pageType)}hasTrackedAds(){return!this.nrGoogleTrackingActive||this.adsTracked}getEngagedTime(){var e;const t=Ne()-this.startPageTime;return"fbia"===(null===(e=this.tracker)||void 0===e?void 0:e.pageType)?t:this.engagementCalculator.getTotalEngagedTime()}async track(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new FormData;return new Promise((t=>{const r=0===this.tick,n="1"===e.get("le");x(this.endpoint,function(e){const t=[];return e.forEach(((e,r)=>{t.push(r+"="+encodeURIComponent(e).replace(/[!'\(\)~]|%20|%00/g,(function(e){return fe[e]})))})),t.join("&")}(e),{needsXHR:r,contentType:"application/x-www-form-urlencoded",keepalive:n&&this.tracker.keepalive},(e=>{let r={};try{r=JSON.parse(e)}catch(e){}var n;this.userIdManager.processIngestResponse(r),r.strategy&&(n=r.strategy,Lr=n.reduce(((e,t)=>_r(_r({},e),{},{[t.tick]:t.delay})),{})),r.ads&&(this.adsDelay=r.ads),t()})),r||t()}))}setUserType(e){this.synchronizer.wait("pageInitialized"),this.permanentCookie.userType=e,this.markAsModified("permanent"),this.saveCookies()}getUserId(){return this.userIdManager.getUserId()}getSiteUserId(){return this.permanentCookie.siteUserId}getSessionReferrer(){return this.temporalCookie.referrer}getSessionId(){return this.temporalCookie.sessionId}getPageId(){return this.pageId}getRecirculationSource(){return this.recirculationSource}getFirstVisit(){return this.permanentCookie.firstVisit}getLastVisit(){return this.temporalCookie.previousVisit!==this.permanentCookie.futurePreviousVisit?this.temporalCookie.previousVisit:null}getPageType(){const e=this.tracker.pageType;return e&&Fr(e)?Fr(e):0}getUserType(){return function(e){if("number"==typeof e)return e;let t=parseInt(e||"",10);if(isNaN(t))switch(e){case"anonymous":t=1;break;case"logged":t=2;break;case"paid":t=3;break;default:t=0}return t}(this.permanentCookie.userType)}getTotalPageviews(){return this.temporalCookie.pagesViewed}getSessionDuration(){return Ne()-this.temporalCookie.currentVisitStarted}getEndpointDomain(){return this.endpointDomain}getUserVars(){return this.permanentCookie.userVars}getSessionVars(){return this.temporalCookie.sessionVars}getPageVars(){return Hr}getUrl(){return this.url}getPublishTime(){return this.publishTime}setEcommerceData(e){this.ecommerceData=e}getCanonical(){return this.canonical}setSiteUserId(e){this.permanentCookie.siteUserId=e,this.markAsModified("permanent"),this.saveCookies()}setCookies(e){this.consentManager.setConsent("cookies",e)}getUserConsent(){return arguments.length>0&&void 0!==arguments[0]&&!arguments[0]?this.consentManager.getConsent("cookies"):async function(e,t){return e.isInitiated()?e.getConsent(t):await Promise.race([new Promise((e=>setTimeout((()=>e(!0)),5e3))),new Promise((t=>e.onChange((()=>t(!0))))),new Promise((e=>N((()=>e(!0)))))]).then((async()=>e.getConsent(t)))}(this.consentManager,"cookies")}trackAdEvent(e,t){this.adsTracker.trackAdEvent(e,t)&&-1!==this.adsDelay&&(this.adsTracked=!0,Rr(),xr(this.adsDelay,(()=>this.trackPage())))}trackAdRendered(e,t){this.adsTracker.trackAdEventLegacy("slotRenderEnded",e,t)&&-1!==this.adsDelay&&(this.adsTracked=!0,Rr(),xr(this.adsDelay,(()=>this.trackPage())))}async setUserVar(e,t){await this.synchronizer.wait("pageInitialized"),zr(this.permanentCookie.userVars,e,t),this.markAsModified("permanent"),this.saveCookies()}async setSessionVar(e,t){await this.synchronizer.wait("pageInitialized"),zr(this.temporalCookie.sessionVars,e,t),this.markAsModified("temporal"),this.saveCookies()}async setPageVar(e,t){var r;(!(arguments.length>2&&void 0!==arguments[2])||arguments[2])&&await this.synchronizer.wait("pageInitialized"),Br(e,t),r=t,"closed"===e&&this.setUserVar("lastClosed",r)}async trackConversion(e,t){this.conversion={conv:e,conv_i:t},(async e=>{const t=await(r=en,Promise.resolve(Zr().entries[r]))||{};var r;const n=t[e]||0;t[e]=n+1,await function(e,t){return Zr().entries[e]=t,Promise.resolve(Yr(Zr()))}(en,t)})(e),Rr(),await this.trackPage()}async trackRecirculationEvent(e){var t,r;let n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];const i=await this.getTrackingCommonData(),o={t:e,m:n.map((e=>{var t,r;return Vn(Vn({},e),{},{e:(null===(t=(r=e.e).map)||void 0===t?void 0:t.call(r,$))||e.e})})),ac:i.ac,url:i.url,c:i.c,ut:i.ut,fv:i.fv,lv:i.lv,r:i.r,lp:i.lp,pageType:0,sui:i.sui,u:i.u,uc:i.uc,cc:i.cc,n:Ne()};this.tracker.pageType&&"fbia"===this.tracker.pageType&&(o.pageType=2);const a=Be(this.accountId);if(a){const{rfv:e,v:t,f:r,r:n}=a;o.rfv=e,o.rfv_r=n,o.rfv_f=r,o.rfv_v=t}return x("".concat(this.getEndpointDomain(),"/recirculation.php"),JSON.stringify(o)),null===(t=this.events)||void 0===t||null===(r=t.emitRecirculation)||void 0===r||r.call(t,o),o}getBasicConfig(){const{actualUserId:e}=this.getUserId();return{ac:this.accountId,co:this.cookieDomain,t:this.temporalCookie.currentVisitStarted,r:this.getSessionReferrer(),url:this.url,c:this.canonical,pp:this.getReferrer(),lp:this.getLandingPage(),p:this.pageId,u:e,s:this.getSessionId(),v:.2}}async getTrackingCommonData(){const{userIdPromise:e}=this.getUserId();return Vn(Vn({},this.getBasicConfig()),{},{u:await e,ua:window.navigator.userAgent,rs:this.getRecirculationSource(),sui:this.getSiteUserId()||"",ut:this.getUserType(),fv:this.getFirstVisit(),lv:this.getLastVisit(),uvar:this.getUserVars(),svar:this.getSessionVars(),pvar:this.getPageVars(),uc:await this.getUserConsent(),useg:this.getUserSegments(),cc:Ae(this.consentManager)})}async trackPageInternal(){this.tick>0&&(this.performanceStartTime=performance.now());const e=new FormData,{pageNav:t,jsTime:r}=(e=>{if(void 0!==window.performance&&"function"==typeof window.performance.getEntriesByType){const t=window.performance.getEntriesByType("navigation")[0];return qe=qe||window.performance.now()-e,qe>0?{pageNav:t,jsTime:qe}:{}}return{}})(this.performanceStartTime);null!=r&&(e.append("pt",r),void 0!==t&&void 0!==t.domainLookupEnd&&(e.append("pdns",t.domainLookupEnd-t.domainLookupStart),e.append("pcon",t.connectEnd-t.connectStart),e.append("pfet",t.responseEnd-t.fetchStart),e.append("pnet",t.responseEnd-t.requestStart),e.append("pttf",t.responseStart-t.requestStart),e.append("pint",t.domInteractive),e.append("pdcl",t.domContentLoadedEventEnd),e.append("pdclf",t.duration))),e.append("wv",this.webVitals.hasWebVitals()),e.append("lcp",this.webVitals.lcp),e.append("fid",this.webVitals.fid),e.append("cls",this.webVitals.cls),e.append("fcp",this.webVitals.fcp),e.append("tbt",this.webVitals.tbt),e.append("inp",this.webVitals.inp),this.webVitals.lcpOffender&&e.append("lcp_o",this.webVitals.lcpOffender),this.webVitals.clsOffender&&(e.append("cls_o",this.webVitals.clsOffender),e.append("cls_o_s",this.webVitals.clsOffenderStatus)),this.webVitals.inpOffender&&(e.append("inp_o",this.webVitals.inpOffender),e.append("inp_o_s",this.webVitals.inpOffenderStatus)),Object.entries(this.getBasicConfig()).forEach((t=>{let[r,n]=t;null!=n&&e.append(r,n)}));const n=this.getUserSegments();null!=n&&n.length&&e.append("useg",JSON.stringify(n)),e.append("a",this.tick),e.append("n",Ne());const i=Ne()-this.startPageTime;e.append("et",this.getEngagedTime()),e.append("l",i),e.append("ps",this.startPageTime),e.append("ut",this.getUserType()),e.append("sui",this.getSiteUserId()||""),e.append("sc",be(0===this.tick)),e.append("fv",this.getFirstVisit()),e.append("lv",this.getLastVisit()),e.append("uvar",JSON.stringify(this.getUserVars())),e.append("svar",JSON.stringify(this.getSessionVars())),e.append("pvar",JSON.stringify(this.getPageVars()));let o=!1;try{o=!!JSON.parse(e.get("pvar")).find((e=>"lastEvent"===e[0]&&e[1]))}catch(e){}o&&e.append("le","1"),this.ecommerceData&&e.append("stock",this.ecommerceData.stock),(this.publishTime||this.updateTime)&&(e.append("uti",this.updateTime),e.append("pti",this.publishTime)),e.append("ads",this.adsTracker.getAds());const a=this.adsTracker.getAdUnits();a.length>0&&e.append("aups",a);const{conv:s,conv_i:c}=this.conversion||{};if(s&&(e.append("conv",s),c&&e.append("conv_i",c),this.conversion=null),this.recirculationSource&&e.append("rs",this.getRecirculationSource()),e.append("uc",o?this.getUserConsent(!1):await this.getUserConsent()),e.append("cc",Ae(this.consentManager)),this.consentManager.getConsent("personalization")){const t=Be(this.accountId);if(t){const{rfv:r,v:n,r:i,f:o}=t;e.append("rfv",r),e.append("rfv_v",n),e.append("rfv_r",i),e.append("rfv_f",o)}}return this.tracker.pageType&&e.append("pageType",Fr(this.tracker.pageType)),await this.track(e),this.tick++,e}async collectAndTrackPage(){for(;window[this.trackerName].data.length>0;){const e=window[this.trackerName].data.shift();"userType"===e[0]?this.setUserType(e[1]):"userId"===e[0]?this.setSiteUserId(e[1]):"setCookies"===e[0]?this.setCookies(e[1]):"adRendered"===e[0]?this.adsTracker.trackAdEventLegacy("slotRenderEnded",e[1],e[2]):"userVar"===e[0]?this.setUserVar(e[1],e[2]):"sessionVar"===e[0]?this.setSessionVar(e[1],e[2]):"pageVar"===e[0]?this.setPageVar(e[1],e[2]):"trackConversion"===e[0]?this.trackConversion(e[1],e[2]):"getRFV"===e[0]&&this.getRFV(e[1])}return await this.trackPageInternal()}async trackPage(){(e=>{let t=-1;for(let e=0;e{const r=Object.keys(Lr).map((e=>parseInt(e,10))).sort(((e,t)=>e-t)).reduce(((t,r)=>null===t&&r>e?r:t),null);r&&Nr.callOnTimer(t,Lr[r])})(this.tick,(()=>this.trackPage())),e}getRFV(e){if(!this.consentManager.getConsent("personalization"))return e?e(Fe):Fe;const{userIdPromise:t,actualUserId:r}=this.getUserId();return e?t.then((t=>(async(e,t,r,n)=>{const i=Be(e);return i?(r(i),i):((e,t,r,n)=>new Promise((i=>{const o=He(e,t,n);x("https://compassdata.mrf.io/rfv.php",o,{needsXHR:!0},(t=>{const n=ze(JSON.parse(t),e);r(n),i(n)}))})))(e,t,r,n)})(this.accountId,t,e,this.getSiteUserId()))):(console.error("Deprecated: please pass a callback to the function getRFV"),((e,t,r)=>Be(e)||((e,t,r)=>{const n=new XMLHttpRequest;return n.open("POST","https://compassdata.mrf.io/rfv.php",!1),n.send(He(e,t,r)),ze(JSON.parse(n.responseText),e)})(e,t,r))(this.accountId,r,this.getSiteUserId()))}async trackNewPage(e){return this.tick>0&&(await this.trackPageInternal(),this.previousPage=""+this.canonical),H={},await this.initialize(e)}on(e,t){this.dispatcher.on(e,t)}setupConsent(e){const t=()=>{this.saveAmpPermanentCookie(Le("compass_uid"),this.consentManager.getConsent("cookies"))};this.consentManager.onChange((()=>{this.consentManager.getConsent("cookies")&&this.saveCookies({force:!0}),t()}).bind(this)),t();const r=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const{useCookies:t}=e;if(Te(t))return t;const r=Ee("__nrCookieConsent");return Te(r)?r:null}(e);null!==r&&this.consentManager.setConsent("cookies",r)}async getPaywallScore(){const{actualUserId:e}=this.userIdManager.getUserId();return this.consentManager.getConsent("personalization")?(async e=>{const t="".concat(Me,"?").concat(Ve(e)),r=await window.fetch(t);if(!r.ok)throw new Error(r.status);const{score:n}=await r.json();return n})({accountId:this.accountId,userId:e,siteUserId:this.getSiteUserId()}):xe}async predict(){const{actualUserId:e}=this.userIdManager.getUserId(),t=await(async e=>{const t="".concat(Ue,"?").concat(Ve(e)),r=await fetch(t);if(!r.ok)throw new Error(r.status);return await r.json()})({accountId:this.accountId,userId:e,siteUserId:this.getSiteUserId(),totalPageviews:this.getTotalPageviews(),sessionDuration:this.getSessionDuration()});return t.probability&&Br("predict:probability",t.probability),t}async setRecirculationTracking(){return this.setRecirculationTrackingInternal(!0)}async setRecirculationTrackingInternal(){let e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];const t=Promise.race([this.synchronizer.wait("experimentation").then((e=>e?this.synchronizer.wait("headline"):Promise.resolve())),this.synchronizer.wait("experimentationFailed"),this.synchronizer.wait("experimentationDisabled").then((()=>Promise.resolve())),new Promise((e=>setTimeout(e,3e3)))]),[{layouts:r}]=await Promise.all([this.tracker.rm,t]);await async function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:()=>{};(()=>{if(window.performance){if(window.performance.navigation&&1===window.performance.navigation.type)return!0;if("function"==typeof window.performance.getEntriesByType)return window.performance.getEntriesByType("navigation").map((e=>e.type)).includes("reload")}return!1})()&&it("refresh",e),await _t(),function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:()=>{};const{observeDomChanges:n=!0,layouts:i=[]}=t,o=n?Dt:It;Ze().forEach((t=>t.shadowRoot&&o(e,t.shadowRoot,{parentNode:t,layouts:i},r))),o(e,document.body,{layouts:i},r)}(t,r,n)}(B(this.tracker.pageType),((e,t)=>{(e=>{"hidden"!==document.visibilityState?e():document.addEventListener("visibilitychange",(()=>{"hidden"!==document.visibilityState&&e()}),{once:!0})})((()=>this.trackRecirculationEvent(e,t.map((e=>{let{module:t,links:r,position:n}=e;return{n:t,e:r,p:n}})),"")))}),{observeDomChanges:e,layouts:r},(()=>this.dispatcher.dispatch("recirculationChanged"))),this.synchronizer.resolve("recirculationTracking")}setRecirculationConfig(){let{modules:e=[],layouts:t=[],blacklist:r=[],redirectionLinks:n=[]}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.tracker.rm.set((i=>{let{modules:o=[],layouts:a=[],blacklist:s=[],redirectionLinks:c=[]}=i;const u={blacklist:Rn([...s,...r]),redirectionLinks:Rn([...c,...n]),modules:Rn([...o,...e]),layouts:Rn([...a,...t])};return this.dispatcher.dispatch("recirculationConfigChanged",Vn({},u)),u})),async function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:()=>{};e.modules.length&&(await _t(),Lt(e),z((()=>{Lt(e)&&t()})),t())}({modules:e,blacklist:r,redirectionLinks:n},(()=>{this.setRecirculationTrackingInternal(!1),this.dispatcher.dispatch("recirculationChanged")}))}getRecirculationConfig(){return this.tracker.rm}setRecirculationModules(e){this.setRecirculationConfig({modules:e})}setConversionButtons(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];e&&e.length&&function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;_n(e,t),z((()=>{_n(e,t)}))}(e,this.trackConversion.bind(this))}addUserSegment(e){const t=_e(this.permanentCookie,"userSegments")||[];this.permanentCookie.userSegments=[...t,e],this.markAsModified("permanent"),this.saveCookies()}setUserSegments(e){this.permanentCookie.userSegments="string"==typeof e?e.split(","):e,this.markAsModified("permanent"),this.saveCookies()}removeUserSegment(e){this.permanentCookie.userSegments=this.permanentCookie.userSegments?this.permanentCookie.userSegments.filter((t=>t!==e)):[],this.markAsModified("permanent"),this.saveCookies()}clearUserSegments(){this.permanentCookie.userSegments=[],this.markAsModified("permanent"),this.saveCookies()}getUserSegments(){var e;return(null===(e=this.permanentCookie)||void 0===e?void 0:e.userSegments)||[]}getContext(e){var t;return e?null===(t=this.contextVariables)||void 0===t?void 0:t[e]:this.contextVariables}setContext(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.contextVariables=e}trackPaymentMethod(){(e=>{try{const r=e.getSessionVars();if("hub.marfeel.com"===document.location.host)return;if(window.addEventListener("message",(t=>{if("https://experiences.mrf.io"===t.origin){var r,n,i;if(null!==(r=t.data)&&void 0!==r&&r.activePayment)e.setSessionVar("activePaymentMethod",t.data.activePayment);else if(null!==(n=t.data)&&void 0!==n&&n.retryData&&window.PaymentRequest){var o;const{paymentMethod:r,paymentDetails:n}=null===(o=t.data)||void 0===o?void 0:o.retryData;new PaymentRequest([r],n,{}).canMakePayment().then((t=>{t&&e.setSessionVar("activePaymentMethod","applePay")})).catch((()=>{}))}Mn=!1;const a=null===(i=document.body)||void 0===i?void 0:i.querySelector("iframe#".concat("dw-mrf"));a&&document.body.removeChild(a)}})),!Mn||!r.activePaymentMethod){var t;const e=document.createElement("iframe");e.id="dw-mrf",e.setAttribute("allow","payment"),e.setAttribute("style","display:none;"),e.src=xn,null===(t=document.body)||void 0===t||t.appendChild(e),Mn=!0}}catch(e){}})(this)}}function zn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Hn(e){for(var t=1;t{var t,n;null===(t=window)||void 0===t||null===(n=t.top)||void 0===n||n.marfeel.cmd.push(["compass",function(){var t=r((function*(t){return e(yield t.getTrackingCommonData())}));return function(e){return t.apply(this,arguments)}}()])}))}))()}}function Kn(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Gn(e){for(var t=1;t{ei().push(["consent",n=>{try{if(n.getConsent("cookies"))return window.localStorage.setItem(t,r),e(!0)}catch(e){}return e(!1)}])}));var t,r}function ni(){return ii.apply(this,arguments)}function ii(){return(ii=r((function*(){var e,t,r=yield(e=ti,new Promise((t=>{ei().push(["consent",r=>{try{if(r.getConsent("cookies"))return t(window.localStorage.getItem(e))}catch(e){}return t(null)}])})));return r?JSON.parse(atob(r)):(ri(t={creation:Date.now(),update:Date.now(),entries:{}}),t)}))).apply(this,arguments)}function oi(e){return ai.apply(this,arguments)}function ai(){return(ai=r((function*(e){return(yield ni()).entries[e]}))).apply(this,arguments)}function si(e,t){return ci.apply(this,arguments)}function ci(){return(ci=r((function*(e,t){var r=yield ni();return r.entries[e]=t,ri(r)}))).apply(this,arguments)}var ui=function(e){return e["2G"]="2g",e["3G"]="3g",e["4G"]="4g",e}(ui||{}),li={[ui["2G"]]:70,[ui["3G"]]:750,[ui["4G"]]:Number.MAX_VALUE},di="mrf-connection-speed",pi=[1059,1659,2223,2224,2225,2335,2336,2337,2338,2339,2340],fi=function(){var e=r((function*(e){if(!window.performance||!pi.includes(Number(e.siteId)||0))return"";var t=[...window.performance.getEntriesByType("navigation"),...window.performance.getEntriesByType("resource")].filter((e=>e.transferSize>1e4));if(!t.length){var{connection_kbps:r,connection_type:n}=yield oi(di);return r&&n?"kbps=".concat(r,"&ctyp=").concat(n):""}var i=t.reduce(((e,t)=>t.encodedBodySize>e.encodedBodySize?t:e)),o=i.encodedBodySize/1e3,a=i.responseEnd-i.responseStart,s=Math.round(8*o/(a/1e3)),c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return e"".concat(encodeURIComponent(t),",").concat(e[t])));return"".concat("cnv","=").concat(t.join(","))}));return function(){return e.apply(this,arguments)}}(),mi=function(){var e,t=arguments.length>1?arguments[1]:void 0;return null===(e=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").replace(t,"").replace("true","").split("&").find((e=>e.startsWith("mrfexperiences=")||e.startsWith("mrfexp=")||e.startsWith("mrfdebug="))))||void 0===e?void 0:e.split("=")[1]},vi=e=>{if(e){var t=mi(e.hash,"#")||mi(e.search,"?");if(t)return t}return null},gi=function(){var e=r((function*(e){var t=e.experienceId;return t&&""!==t?"id=".concat(t):""}));return function(t){return e.apply(this,arguments)}}();function yi(e,t){if("provider"!==e)return t}var bi=function(){var e=r((function*(e){var t,r;if(null===(t=e.externalExperiences)||void 0===t||null===(r=t[$n.FLOWCARDS])||void 0===r||!r.length)return"";var n=e.externalExperiences[$n.FLOWCARDS].map((e=>{var t=e;return"object"==typeof e.renderProps&&(t.renderProps=JSON.stringify(e.renderProps)),t})),i=encodeURIComponent(JSON.stringify(n,yi));return"dflwc=".concat(i)}));return function(t){return e.apply(this,arguments)}}(),wi=function(){var e=r((function*(e){return isNaN(e.firstVisit)?"":"fvst=".concat(e.firstVisit)}));return function(t){return e.apply(this,arguments)}}(),Oi="mrfgeo=",Pi=function(){var e=r((function*(e){return"geo=".concat((e=>{if(e){var t=e.search.replace("?","").split("&").find((e=>e.startsWith(Oi)));if(t)return t.replace(Oi,"")}return null})(e.location)||"__INJECT_GEO__")}));return function(t){return e.apply(this,arguments)}}(),Ei=function(){var e=r((function*(e){var t=/hubspotutk=(.+?)(?:;|$)/.exec(e.cookies||"");return t?"hutk=".concat(t[1]):""}));return function(t){return e.apply(this,arguments)}}(),ki=function(){var e=r((function*(e){var t=e.pageTechnology?e.pageTechnology:0;return"ptch=".concat(t)}));return function(t){return e.apply(this,arguments)}}(),Si=function(){var e=r((function*(e){return isNaN(e.totalPageViews)?"":"pgv=".concat(e.totalPageViews)}));return function(t){return e.apply(this,arguments)}}(),ji=function(){var e=r((function*(e){if(!e.referrer)return"";var t=encodeURIComponent(e.referrer);return"ppg=".concat(t)}));return function(t){return e.apply(this,arguments)}}();function Ci(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ti(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1?arguments[1]:void 0;if(void 0===t)return e;var r=[...e.filter((e=>e!==t)),t];return r.length>100?r.slice(1):r};function Di(){return _i.apply(this,arguments)}function _i(){return(_i=r((function*(){return(yield oi(Ai))||{sites:{}}}))).apply(this,arguments)}function Ni(){return(Ni=r((function*(e,t){var r,n=yield Di(),i=Ti(Ti({},n),{},{sites:Ti(Ti({},n.sites),{},{[e]:Ti(Ti({},n.sites[e]),{},{readEditorialIds:Ii(null===(r=n.sites[e])||void 0===r?void 0:r.readEditorialIds,t.editorialId)})})});return si(Ai,i)}))).apply(this,arguments)}var Li=function(){var e=r((function*(e){var{siteId:t,personalizedContent:r}=e;if(void 0!==t&&r){var n,i,o=(e=>e.sort(((e,t)=>e-t)).map(((e,t,r)=>{var n=e;return t>0&&(n-=r[t-1]),n})))(null!==(n=null===(i=(yield Di()).sites[t])||void 0===i?void 0:i.readEditorialIds)&&void 0!==n?n:[]);if(o.length>0)return"red=".concat(o.join(","))}return""}));return function(t){return e.apply(this,arguments)}}(),Ri=function(){var e=r((function*(e){if(!e.recirculationSource)return"";var t=encodeURIComponent(e.recirculationSource);return"rsrc=".concat(t)}));return function(t){return e.apply(this,arguments)}}(),xi=function(){var e=r((function*(e){if(!e.sessionReferrer)return"";var t=new URL(e.sessionReferrer);t.hash="",t.search="";var r=encodeURIComponent(t.toString());return"ref=".concat(r)}));return function(t){return e.apply(this,arguments)}}(),Mi=function(){var e=r((function*(e){return isNaN(e.sessionDuration)?"":"sdu=".concat(e.sessionDuration)}));return function(t){return e.apply(this,arguments)}}(),Ui=function(){var e=r((function*(e){return isNaN(e.siteId)?"":"sid=".concat(e.siteId)}));return function(t){return e.apply(this,arguments)}}(),Vi=function(){var e=r((function*(e){var t,r=Object.assign({},e.targeting,(t=e.compassVars)?[...t.page,...t.user,...t.session].reduce(((e,t)=>{var[r,n]=t;return e[r]=n,e}),{}):{});return 0===Object.keys(r).length?"":Object.keys(r).filter((e=>void 0!==r[e])).map((e=>[e,encodeURIComponent(r[e])].join("="))).join("&")}));return function(t){return e.apply(this,arguments)}}(),qi=0,Fi=1,zi=7,Hi=4,Bi=7,Ki=864e5;function Gi(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate())),r=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate()+Hi-(t.getUTCDay()||Bi))),n=new Date(Date.UTC(r.getFullYear(),qi,Fi));return{week:Math.ceil(((r.getTime()-n.getTime())/Ki+1)/zi),year:r.getUTCFullYear()}}var Wi=function(e){return e.impression="impression",e.close="close",e}({});function Ji(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Xi(e){for(var t=1;t{var r=Xi({total:{impression:0,close:0}},e||{}),n="w".concat(Yi.week);return r[n]=r[n]||{impression:0,close:0},r[n][t]++,r},to=(e,t)=>{var r=Xi({total:{impression:0,close:0}},e||{});return r.total[t]++,r[$i.getMonth()]=((e,t)=>{var r=Xi({total:{impression:0,close:0}},e||{}),n=$i.getDate();return r[n]=r[n]||{impression:0,close:0},r[n][t]++,r.total[t]++,r})(r[$i.getMonth()],t),r};function ro(){return void 0===Qi&&($i=new Date(Date.now()),Yi=Gi($i),Qi=oi(Zi).then((e=>e||{}))),Qi}var no=function(e){return e.lifetime="l",e.month="m",e.week="w",e.day="d",e}(no||{}),io=function(e){return e.last="ls",e}(io||{}),oo=e=>{if(!e)return 0;var t=Date.now()-e;return Math.floor(t/1e3)},ao=(e,t,r,n)=>{var{impression:i,close:o}=n;i>0&&e.has(r)&&t.push(r,String(i)),o>0&&e.has("".concat("c").concat(r))&&t.push("".concat("c").concat(r),String(o))},so=function(){var e=r((function*(e){var t,r=new Map(Object.entries(null!==(t=e.userExperiences)&&void 0!==t?t:{}).map((e=>{var[t,r]=e;return[t,new Set(r)]})));return ro().then((e=>{var t=Object.entries(e).reduce(((e,t)=>{var[n,i]=t,o=[],a=r.get(n);if(!i||0===i.total.impression||!a)return e;!function(e,t,r){ao(e,t,no.lifetime,r.total)}(a,o,i);var s=new Date(Date.now()),c=Gi(s),u=i[s.getFullYear()],l=i[c.year],d=null==u?void 0:u[s.getMonth()],p=null==d?void 0:d[s.getDate()];!function(e,t,r){r&&ao(e,t,no.month,r.total)}(a,o,d),function(e,t,r,n){if(r){var i=r["w".concat(n.week)];i&&ao(e,t,no.week,i)}}(a,o,l,c),function(e,t,r){r&&ao(e,t,no.day,r)}(a,o,p),((e,t,r)=>{r.last&&ao(e,t,io.last,{impression:oo(r.last.impression),close:oo(r.last.close)})})(a,o,i);var f=o.join("|");return f.length>0?e.concat(n,f):e}),[]);return t.length>0?"uexp=".concat(t.join(",")):""}))}));return function(t){return e.apply(this,arguments)}}(),co=function(){var e=r((function*(e){return Array.isArray(e.userSegments)?"useg=".concat(e.userSegments.join(",")):""}));return function(t){return e.apply(this,arguments)}}(),uo=function(){var e=r((function*(e){return isNaN(e.userType)?"":"utyp=".concat(e.userType)}));return function(t){return e.apply(this,arguments)}}(),lo=e=>{try{return decodeURIComponent(e),!0}catch(e){return!1}},po=function(e){return e.USQP="usqp",e.CAMPAIGN="utm_campaign",e.CONTENT="utm_content",e.MEDIUM="utm_medium",e.SOURCE="utm_source",e}(po||{}),fo={[po.CAMPAIGN]:"u_cpg",[po.CONTENT]:"u_cnt",[po.MEDIUM]:"u_mdm",[po.SOURCE]:"u_src"},ho={canonical_url:"url",client_id:"clid",connection_speed:"cspd",conversions:"cnv",dynamic_flowcards:"dflwc",experience_id:"id",first_visit:"fvst",hubspot_utk:"hutk",page_technology:"ptch",pageviews:"pgv",previous_page:"ppg",recirculation_source:"rsrc",referrer:"ref",session_duration:"sdu",site_id:"sid",targeting:"trg",user_experiences:"uexp",user_type:"utyp",visitor_frequency:"vfrq"},mo={url:Yn,clid:Zn,cspd:fi,cnv:hi,debug_experiences:e=>{var t=vi(e.location);return Promise.resolve(t?"debug_experiences=".concat(t):"")},dflwc:bi,fvst:wi,geo:Pi,hutk:Ei,id:gi,ptch:ki,pgv:Si,ppg:ji,pti:e=>{var t=e.publishTime;return Promise.resolve(t?"pti=".concat(t):"")},qpa:e=>{var t=e.location,r=[];if(t)for(var n of Array.from(t.searchParams.keys()).reverse())-1===r.indexOf(n)&&r.push(n);return Promise.resolve(r.length>0?"qpa=".concat(r.reverse().join(",")):"")},rsrc:Ri,red:Li,ref:xi,sdu:Mi,sid:Ui,trg:Vi,uexp:so,useg:co,utyp:uo,utms:function(){var e=r((function*(e){var t=e.location;if(!t)return"";var r=Object.values(po);return Array.from(t.searchParams.entries()).filter((e=>{var[t]=e;return r.includes(t)})).map((e=>{var t,[r,n]=e;return"".concat(null!==(t=fo[r])&&void 0!==t?t:r,"=").concat(n)})).filter(lo).join("&")}));return function(t){return e.apply(this,arguments)}}(),vfrq:function(){var e=r((function*(e){return e.hasConsent?"":"".concat("vfrq","=").concat("6")}));return function(t){return e.apply(this,arguments)}}()},vo=function(){var e=r((function*(e,t,r){var n=yield Promise.all((e=>{var t=Object.entries(mo);if(!e)return t;var r=new Set(Array.from(e.values()).map((e=>{var t;return null!==(t=ho[e])&&void 0!==t?t:e})));return r.add("sid"),r.add("ptch"),t.filter((e=>{var[t]=e;return r.has(t)}))})(r).map((t=>{var[r,n]=t;return n(e)})));return"".concat(t,"?").concat(n.filter((e=>!!e)).join("&"))}));return function(t,r,n){return e.apply(this,arguments)}}();function go(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function yo(e){for(var t=1;te.reduce(((e,t)=>ko(ko({},e),{},{[t.origin]:t.goal})),{}),jo=function(){var e=r((function*(e,t){var r={handlerName:"content",handled:!1};return t.config.accountId&&e.content&&(r.handled=yield function(e,t){return Ni.apply(this,arguments)}(t.config.accountId,e.content)),Promise.resolve(r)}));return function(t,r){return e.apply(this,arguments)}}(),Co="mrfExperiment_";var To=a(539);function Ao(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Io(e){for(var t=1;t{var r;if("object"==typeof e){r=e;for(var n=t.split("."),i=0;i{if(void 0===t)return!0;if(void 0!==e&&"*"===t)return!0;if(e===t)return!0;if(Array.isArray(t)){var r=Array.from(e);if(r.length>=t.length)return t.map(((e,t)=>No(r[t],e))).every(Boolean)}return"object"==typeof e&&"object"==typeof t&&Object.entries(t).map((t=>{var[r,n]=t;return No(e[r],n)})).every(Boolean)},Lo=(e,t)=>{switch(t.type){case"composite":return Array.isArray(t.value)?t.value.map((t=>Lo(e,t))):Object.entries(t.value).reduce(((t,r)=>{var[n,i]=r;return Io(Io({},t),{},{[n]:Lo(e,i)})}),{});case"lookup":return t.value?_o(e,t.value):e;default:return t.value}},Ro=e=>{var t,r,n=e.hasTrackedAds();return e.getEngagedTime()>=5&&(n||null===(t=window.googletag)||void 0===t||null===(r=t.cmd)||void 0===r||r.push((()=>{e.setPageVar("mrf::optimized","true"),window.googletag.pubads().refresh()})),!0)};function xo(){return(xo=r((function*(e){var t=yield vo(e,"https://experiences.mrf.io/recommenderexperience/render.json",new Set(["canonical_url","client_id","experience_id"])),r=yield fetch(t),n=yield r.json();return null==n?void 0:n.recommendation}))).apply(this,arguments)}!function(e){e.AMP_DOCUMENT="AMPDocument",e.WIDGET_PROVIDER="WidgetProvider",e.AD_SERVER_PROVIDER="AdServerProvider",e.TEXT_HTML="TextHTML",e.CONTAINER="Container"}(Do||(Do={}));var Mo=e=>e.type===Do.AMP_DOCUMENT,Uo=e=>e.type===Do.TEXT_HTML;function Vo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function qo(e){for(var t=1;t{if(e.has(Fo)){var r={src:e.get(Fo)};return e.has(zo)&&(r.height=parseInt(e.get(zo),10)),qo(qo({},t),{},{heroElement:r})}return t};function Bo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ko(e){for(var t=1;t{if(e.has(Go)){var r={url:e.get(Go)};return Ko(Ko({},t),{},{canonical:r})}return t},Jo=e=>e.includes("marfeelrecommenderexperienceengine.mrf.io");function Xo(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Qo(e){for(var t=1;tr(t,e)),{})}catch(t){throw new Error("".concat(t,"::").concat(e.url))}}))).apply(this,arguments)}function Yo(e){return Zo.apply(this,arguments)}function Zo(){return Zo=r((function*(e){return Object.entries(e).map(function(){var e=r((function*(e){var t,r,[n,i]=e;return r=i.content,(Mo(r)||Uo(r))&&(t=yield function(e){return $o.apply(this,arguments)}(i.content)),[n,i,t]}));return function(t){return e.apply(this,arguments)}}()).reduce(function(){var e=r((function*(e,t){var r,n=yield e,[i,o,a]=yield t;return a&&(r=function(e,t){return Qo(Qo({},e),{},{features:Qo(Qo({},e.features),t)})}(o,a)),n[i]=r||o,n}));return function(t,r){return e.apply(this,arguments)}}(),Promise.resolve({}))})),Zo.apply(this,arguments)}function ea(e,t){return r=>{var n=r.detail;(null==n?void 0:n.owner)===t&&e({uri:n.uri})}}var ta=()=>window.location.hash.includes("mrfdebug"),ra=function(){var e=r((function*(e,t,r){var n,i,o,a,s,c=ta(),{userIdPromise:u,actualUserId:l}=t.getUserId(),d=c?l:yield u,p=!!c||(yield t.getUserConsent());return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=e.canonical?{headers:{"mrf-lb-hash":e.canonical}}:void 0;return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return vo(e,"https://flowcards.mrf.io/json/experiences",t.length>0?new Set(t):void 0).then((e=>"".concat(e,"&v=2")))}(e,t).then((e=>fetch(e,r))).then((e=>e.json())).then(bo)}({pageTechnology:t.getPageType(),canonical:(null===(n=document.querySelector('link[rel="canonical"]'))||void 0===n?void 0:n.getAttribute("href"))||void 0,location:new URL(window.location.toString()),publishTime:t.getPublishTime(),siteId:e.accountId,externalExperiences:e.experiences,targeting:e.targeting,userId:d,userSegments:t.getUserSegments(),userType:t.getUserType(),userExperiences:null===(i=e.preflight)||void 0===i||null===(o=i.preflight)||void 0===o||null===(a=o.targeting)||void 0===a?void 0:a.frequencyCap,firstVisit:t.getFirstVisit(),recirculationSource:t.getRecirculationSource(),referrer:t.getReferrer(),sessionDuration:t.getSessionDuration(),sessionReferrer:t.getSessionReferrer(),totalPageViews:t.getTotalPageviews(),cookies:document.cookie,compassVars:{user:t.getUserVars(),session:t.getSessionVars(),page:t.getPageVars()},hasConsent:p,personalizedContent:!(null===(s=e.recommenderConfig)||void 0===s||!s.personalizedContent)},r)}));return function(t,r,n){return e.apply(this,arguments)}}();function na(e,t){var r=document.createElement("script");return r.setAttribute("type","application/javascript"),r.setAttribute("src",e),t&&(r.id=t),r}function ia(e){return(t,r)=>{var n=na(t,r);n.setAttribute("type","module"),e.appendChild(n)}}function oa(e){return(t,r)=>{var n=na(t,r);n.noModule=!0,n.async=!0,n.defer=!0,e.appendChild(n)}}function aa(e){return(t,r)=>{var n=na(t,r);e.appendChild(n)}}function sa(e){return"marfeel-".concat(e)}function ca(e){return function(e){return document.querySelector(sa(e))}(e)||function(e){return document.body.appendChild(document.createElement(sa(e)))}(e)}var ua=function(){var e=r((function*(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{onInteraction:r=!0,strategy:n="async"}=t;return(e=>{var t="string"!=typeof e?e.module:e;return!!document.querySelector('script[src="'.concat(t,'"]'))})(e)?Promise.resolve():(r?function(){var e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:2e4,r=["touchstart","click","scroll"];return new Promise((n=>{var i=()=>{r.forEach((e=>((e,t)=>{document.removeEventListener(e,t)})(e,i))),window.clearTimeout(e),n()};r.forEach((e=>((e,t)=>{document.addEventListener(e,t,{passive:!0})})(e,i))),e=window.setTimeout(i,t)}))}():Promise.resolve()).then((()=>{"sync"===n?"string"!=typeof e?(function(){ia(document.head)(...arguments)}(e.module),function(){oa(document.head)(...arguments)}(e.nomodule)):function(){aa(document.head)(...arguments)}(e):"string"!=typeof e?(function(){ia(document.body)(...arguments)}(e.module),function(){oa(document.body)(...arguments)}(e.nomodule)):function(){aa(document.body)(...arguments)}(e)}))}));return function(t){return e.apply(this,arguments)}}(),la=[],da=[];function pa(e,t){var r=e instanceof Array?e:[e],n=function(e){switch(e){case Wi.impression:return la;case Wi.close:return da;default:return[]}}(t);r.forEach((e=>{var r,i;(function(e,t){return t.indexOf(e)>-1})(e,n)||(n.push(e),r=e,i=t,ro().then((e=>{e[r]=function(e,t){var r=Xi({total:{impression:0,close:0},last:{impression:0,close:0}},e||{});return r.total[t]++,r[$i.getFullYear()]=to(r[$i.getFullYear()],t),r[Yi.year]=eo(r[Yi.year],t),r.last[t]=Number(Date.now()),r}(e[r],i),si(Zi,e)})))}))}function fa(e){pa(e,Wi.impression)}function ha(e){pa(e,Wi.close)}var ma=(e,t,n)=>function(){var i=r((function*(r,i,o){var a,s=(null==n?void 0:n(r))||(null===(a=r[e])||void 0===a?void 0:a.actions),c={handlerName:e,handled:!1};if(s){var u=Object.values(s);if(u.length){var l=yield t(u,i,o);c.handled=null==l||l,fa(u.map((e=>{var{id:t}=e;return t})))}}return c}));return function(e,t,r){return i.apply(this,arguments)}}(),va=ma($n.EXPERIMENTATION,function(){var e=r((function*(e){f(d.INIT_HANDLE_EXPERIMENTATION),yield Promise.all(e.map((e=>{var{url:t}=e,r=new URL(t),n=r.searchParams.get("experimentType");if(null!==n&&document.querySelector('[src*="experimentType='.concat(n,'"]')))return Promise.resolve();var i=new URL(t);return r.searchParams.append("version","esnext"),i.searchParams.append("version","legacy"),ua({module:r.toString(),nomodule:i.toString()},{onInteraction:!1,strategy:"sync"})}))),h(d.INIT_HANDLE_EXPERIMENTATION,d.END_HANDLE_EXPERIMENTATION)}));return function(t){return e.apply(this,arguments)}}()),ga="complete",ya="interactive",ba="loading",wa=()=>document.readyState===ga,Oa=()=>document.readyState===ya,Pa=()=>{var e;return document.readyState===ba&&!(null===(e=document.head)||void 0===e||!e.appendChild)},Ea=function(){var e=r((function*(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ga;return new Promise((t=>{var r=(e=>{switch(e){case ba:return[Pa,Oa,wa];case ya:return[Oa,wa];default:return[wa]}})(e),n=()=>r.some((e=>e()));n()?t():document.addEventListener("readystatechange",(()=>{n()&&t()}))}))}));return function(){return e.apply(this,arguments)}}();function ka(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Sa(e){for(var t=1;tPromise.resolve()),enrich:o=!1}=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};f(d.INIT_HANDLE_INLINE_EXPERIENCE);var a=t[e]||{actions:{}},s=a.actions||{},c={handlerName:e,handled:!1};if(Object.keys(s).length>0){yield i();var u=Sa(Sa({},a),{},{actions:o?yield Yo(a.actions):a.actions});yield Ea(n),function(e,t){var r=document.createElement("script");r.setAttribute("type","application/json"),r.innerHTML=JSON.stringify(t);var n=ca(e);n.appendChild(r),n.setAttribute("initialization","inline")}(e,u),yield r(u),c.handled=!0}return h(d.INIT_HANDLE_INLINE_EXPERIENCE,d.END_HANDLE_INLINE_EXPERIENCE,{type:e,jsonResponse:t}),c}));return function(t,r,n){return e.apply(this,arguments)}}();function Ca(e,t){return t.id||e}function Ta(e,t){Object.entries(t.actions).forEach((t=>{var[r,n]=t,i=function(e){var t;return(null===(t=e.features.canonical)||void 0===t?void 0:t.url)||(Mo(e.content)||Uo(e.content)?e.content.url:e.content.type===Do.WIDGET_PROVIDER||(e=>e.type===Do.AD_SERVER_PROVIDER)(e.content)?e.content.name:void 0)}(n);i&&e.trackRecirculationEvent("elegible",[{n:Ca(r,n),e:[i]}],"")}))}var Aa="//flowcards.mrf.io/statics/experience-web",Ia="".concat(Aa,"/index.es2015.standalone.js"),Da="".concat(Aa,"/index.es5.standalone.js"),_a=function(){var e=r((function*(e,t){if(matchMedia("only screen and (min-width:800px)").matches)return{handlerName:$n.FLOWCARDS,handled:!1};var{compassSDK:n}=t;return ja($n.FLOWCARDS,e,function(){var e=r((function*(e){Ta(n,e),yield ua({module:Ia,nomodule:Da}),ca($n.FLOWCARDS).addEventListener("snappointchange",(e=>{var{snapPoint:t,initiator:r,cardId:n}=e.detail;(function(e,t){return"hidden"===e&&"user:button"===t})(t,r)&&ha(n),function(e){return"initial"===e||"active"===e}(t)&&fa(n)}))}));return function(t){return e.apply(this,arguments)}}(),{enrich:!0})}));return function(t,r){return e.apply(this,arguments)}}(),Na=ma($n.GOOGLE_OPTIMIZE,function(){var e=r((function*(e,t){var r=e.map((e=>{var{experiments:t}=e;return t})).reduce(((e,t)=>(t.forEach((t=>e.add(t))),e)),new Set);return new Promise((e=>{!function(){window.dataLayer=window.dataLayer||[],window.dataLayer.push(arguments)}("event","optimize.callback",{callback:(n,i)=>{r.has(i)&&(t.compassSDK.setUserVar("optimize-".concat(i),n),r.delete(i)),0===r.size&&e()}})}))}));return function(t,r){return e.apply(this,arguments)}}()),La="https://experiences.mrf.io/statics/inline-experiences",Ra="".concat(La,"/esnext/standalone.js"),xa="".concat(La,"/legacy/standalone.js"),Ma=function(){var e=r((function*(e){return ja($n.INLINE,e,function(){var e=r((function*(e){var t,{actions:r={}}=e;null===(t=window.mrfInlineExperiences)||void 0===t||t.init(),(e=>{Object.entries(e).forEach((e=>{var[t,r]=e;fa(r.id)})),document.addEventListener("mrfCloseInline",(e=>{var t;ha(null===(t=e.detail)||void 0===t?void 0:t.id)}))})(r)}));return function(t){return e.apply(this,arguments)}}(),{documentState:ya,prepare:(t=r((function*(){yield Ea(ba),yield ua({module:Ra,nomodule:xa},{onInteraction:!1,strategy:"sync"})})),function(){return t.apply(this,arguments)})});var t}));return function(t){return e.apply(this,arguments)}}();function Ua(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Va(e){for(var t=1;t{var{moduleName:t,config:r}=e;window.marfeel.cmd.push(["loader",function(e){e.load(t,r)}])}))}));return function(t){return e.apply(this,arguments)}}(),(e=>{var{loader:t={actions:{}},multimedia:r={actions:{}},ecommerce:n={actions:{}}}=e;return Va(Va(Va({},t.actions),r.actions),n.actions)})),Fa=ma($n.CONTEXT_EXPOSITION,function(){var e=r((function*(e,t){e.forEach((e=>{var{contextVariables:r}=e;try{r&&t.compassSDK.setContext(JSON.parse(r))}catch(e){console.error("not valid JSON for the contextExposition experience")}}))}));return function(t,r){return e.apply(this,arguments)}}()),za="closed",Ha=function(){var e=r((function*(e,t){var r,n,i=yield t.wait("piano-offer");return!("purchase"!==i.offerType||("inline"===i.displayMode?(e.compassSDK.setPageVar(za,"hard-paywall"),0):"modal"!==i.displayMode||!i.activeMeters||"DefaultMeter"!==(r=i.activeMeters,n=JSON.parse(r),Array.isArray(n)?n[0]:n).meterName||(e.compassSDK.setPageVar(za,"dynamic-paywall"),0)))}));return function(t,r){return e.apply(this,arguments)}}(),Ba="piano subscribe",Ka=function(){var e=r((function*(e,t,r){var n,i=yield r.wait("piano-subscription"),o=t.find((e=>e.rid===i.rid));return!!o&&(e.compassSDK.trackConversion(null!==(n=o.conversion)&&void 0!==n?n:Ba),!0)}));return function(t,r,n){return e.apply(this,arguments)}}(),Ga=function(){var e=r((function*(e,t,n){var i,o,a=yield Promise.all(t.map(function(){var t=r((function*(t){if(yield((e,t)=>new Promise((r=>{e.api.callApi("/access/check",{rid:t},(function(e){var t=e.access.granted;return r(t)}))})))(e,t.rid))return t}));return function(e){return t.apply(this,arguments)}}()));n.compassSDK.setUserType(null!==(i=null===(o=a.find(Boolean))||void 0===o?void 0:o.userType)&&void 0!==i?i:"logged")}));return function(t,r,n){return e.apply(this,arguments)}}(),Wa=function(){var e=r((function*(e,t){var r,n,i=null!==(r=null===(n=e.pianoId.getUser())||void 0===n?void 0:n.uid)&&void 0!==r?r:void 0;if(!i)try{var o,a;i=JSON.parse(atob(null===(o=e.pianoId.getToken())||void 0===o||null===(a=o.split("."))||void 0===a?void 0:a[1])).sub}catch(e){}i&&t.compassSDK.setSiteUserId(i)}));return function(t,r){return e.apply(this,arguments)}}(),Ja=function(){var e=r((function*(){if(window.tp&&!Array.isArray(window.tp)||(yield new Promise((e=>{!function(){window.tp=window.tp||[],Array.isArray(window.tp)&&window.tp.push(arguments)}("init",e)}))),window.tp&&!Array.isArray(window.tp))return window.tp}));return function(){return e.apply(this,arguments)}}(),Xa=e=>Array.isArray(e.resources)?e.resources:e.rid.split(";").map((e=>({rid:e,userType:3,conversion:Ba}))),Qa=function(){var e=r((function*(e,t,r,n){return!(!e.pianoId.isUserValid()&&!e.user.isUserValid()||(yield Ga(e,r,n),t&&e.pianoId.isUserValid()&&(yield Wa(e,n)),0))}));return function(t,r,n,i){return e.apply(this,arguments)}}(),$a=ma($n.PIANO,function(){var e=r((function*(e,t,n){var i=e.map(Xa).reduce(((e,t)=>[...e,...t]),[]),o=e.some((e=>null==e?void 0:e.deviceUnification));yield Promise.all([Ha(t,n),Ka(t,i,n),Ja().then(function(){var e=r((function*(e){return new Promise((n=>{if(!e)return n();var a=0,s=setInterval(r((function*(){if((yield Qa(e,o,i,t))||a>=3)return clearInterval(s),n();a+=1})),5e3)}))}));return function(t){return e.apply(this,arguments)}}())])}));return function(t,r,n){return e.apply(this,arguments)}}()),Ya=function(){var e=r((function*(){if(!document.querySelector(".js_smartbanner")){var[e]=yield Promise.all([a.e(512).then(a.bind(a,512)),a.e(376).then(a.bind(a,376))]);(new e.default).publish()}}));return function(){return e.apply(this,arguments)}}(),Za=function(){var e=r((function*(e){[["smartbanner:title",e.title],["smartbanner:author",e.author],["smartbanner:price","GET"],["smartbanner:price-suffix-google"," - In Google Play"],["smartbanner:price-suffix-apple"," - On the App Store"],["smartbanner:icon-google",e.icon],["smartbanner:icon-apple",e.icon],["smartbanner:button-url-google","https://play.google.com/store/apps/details?id=".concat(e.androidId)],["smartbanner:button-url-apple","https://apps.apple.com/app/id".concat(e.iosId)],["smartbanner:enabled-platforms","android,ios"],["smartbanner:button","VIEW"],["smartbanner:custom-design-modifier","marfeel"],["smartbanner:api","true"]].forEach((e=>{var[t,r]=e;return((e,t)=>{var r=document.createElement("meta");r.name=e,r.content=t,document.head.appendChild(r)})(t,r)})),yield Ya()}));return function(t){return e.apply(this,arguments)}}(),es=ma($n.APP_BANNER,function(){var e=r((function*(e){var t=e[0];yield Za(t),window.addEventListener("smartbanner.exit",(()=>{ha(t.id)}))}));return function(t){return e.apply(this,arguments)}}()),ts=ma($n.SOCIAL_ACQUISITION,function(){var e=r((function*(e){e.forEach((e=>{var{pixelId:t}=e;(e=>{var{pixelId:t}=e;!function(e,t,r,n,i,o,a){e.fbq||(i=e.fbq=function(){i.callMethod?i.callMethod.apply(i,arguments):i.queue.push(arguments)},e._fbq||(e._fbq=i),i.push=i,i.loaded=!0,i.version="2.0",i.queue=[],(o=t.createElement(r)).async=!0,o.src="https://connect.facebook.net/en_US/fbevents.js",(a=t.getElementsByTagName(r)[0]).parentNode.insertBefore(o,a))}(window,document,"script"),window.fbq("init",t),window.fbq("track","PageView")})({pixelId:t})}))}));return function(t){return e.apply(this,arguments)}}()),rs=a(595),ns=["www.amazon","/dp/"],is="asc_refurl",os="asc_source",as="asc_campaign";const ss=new class{isAffiliateUrl(e){return ns.every((t=>e.includes(t)))}getModifiedUrl(e,t){var r=new URL(e),n=r.searchParams.get(is),i=r.searchParams.get(as),o=r.searchParams.get(os);return!n&&t.url&&r.searchParams.set(is,t.url),!o&&t.source&&r.searchParams.set(os,t.source),!i&&t.campaign&&r.searchParams.set(as,t.campaign),{isCorrect:!!n&&!!o&&!!i,url:r.toString()}}};var cs=[ss],us=(e,t)=>{[...document.querySelectorAll("a")].filter((e=>!!e.href)).forEach((r=>{try{var n,{url:i,isValid:o,build:a}=((e,t)=>{var r=new URL(e);if(t){var n=r.searchParams.get(t);return{isValid:!!n,build:e=>(r.searchParams.set(t,encodeURIComponent(e)),r.toString()),url:n?decodeURIComponent(decodeURIComponent(n)):""}}return{isValid:!0,build:e=>e,url:r.toString()}})(r.href,t);if(!o)return;var s=null===(n=cs.filter((e=>e.isAffiliateUrl(i))))||void 0===n?void 0:n[0];if(!s)return;var{isCorrect:c,url:u}=s.getModifiedUrl(i,e);c||(r.href=a(u))}catch(e){}}))},ls=ma($n.AFFILIATION_ENHANCER,function(){var e=r((function*(e){e.forEach((e=>{var{context:t,queryParam:r}=e;((e,t)=>{us(e,t),(0,rs.N)((()=>{us(e,t)}))})(JSON.parse(t),r)}))}));return function(t){return e.apply(this,arguments)}}()),ds=[[(e,t)=>{var r,n,i,o={handlerName:"experiments",handled:!1};if(e.experiments){var a=(r=e.experiments,n=t.compassSDK,i=n.getUserVars()||[],r.filter((e=>{var{name:t}=e;return!i.some((e=>{var[r]=e;return r==="".concat(Co).concat(t)}))})));o.handled=function(e,t){return 0!==e.length&&(e.forEach((e=>{var{name:r,group:n,groups:i}=e;t.setUserVar("".concat(Co).concat(r),function(e,t){return t?(Math.floor(Math.random()*t)+1).toString():e.toString()}(n,i))})),!0)}(a,t.compassSDK)}return Promise.resolve(o)}]],ps=[[Ma],[(e,t)=>{var{compass:r={actions:{}},recirculation:n={actions:{}},conversions:i={actions:{}}}=e,o=Object.values(Oo(Oo(Oo({},null==r?void 0:r.actions),null==n?void 0:n.actions),null==i?void 0:i.actions)),a={handlerName:"compass",handled:!1};if(o.length){var s={layouts:[],modules:[],blacklist:[],redirectionLinks:[]};Object.values(o).forEach((e=>{var{recirculationModules:r=[],userType:n,userVars:i={},conversionButtons:o=[],layouts:a=[],blacklist:c=[],redirectionLinks:u=[]}=e;t.compassSDK.setConversionButtons(o),void 0!==n&&t.compassSDK.setUserType(n),Object.entries(i).forEach((e=>{var[r,n]=e;return t.compassSDK.setUserVar(r,n)})),s.modules.push(...r),s.layouts.push(...a),s.blacklist.push(...c),s.redirectionLinks.push(...u)})),t.compassSDK.setRecirculationConfig(s),a.handled=!0}return Promise.resolve(a)}],[e=>{var{adManager:t}=e,r={handlerName:"ad-manager",handled:!1};return null!=t&&t.actions&&(Object.values(t.actions).forEach((e=>{var t,{targeting:r}=e;(t=r)&&(window.googletag=window.googletag||{},window.googletag.cmd=window.googletag.cmd||[],t.forEach((e=>{var{key:t,value:r}=e;window.googletag.cmd.push((()=>{window.googletag.pubads().setTargeting(t,r)}))})))})),r.handled=!0),Promise.resolve(r)},jo,va,_a,Na,$a,ts,(e,t)=>{var{goalTracking:r}=e,n={handlerName:"goalTracking",handled:!1};return null!=r&&r.actions&&(Object.values(r.actions).forEach((e=>{var{goals:r}=e;null==r||r.forEach((e=>t.compassSDK.trackConversion(e)))})),n.handled=!0),Promise.resolve(n)},(e,t)=>{var{genericGoalTracking:r}=e,n={handlerName:"genericGoalTracking",handled:!1},i=!1;if(null!=r&&r.actions){var o,a,s=Object.values(r.actions).reduce(((e,t)=>((e[t.source]=e[t.source]||[]).push(t),e)),{});if((null===(o=s[Po.POST_MESSAGE])||void 0===o?void 0:o.length)>0){var c=So(s[Po.POST_MESSAGE]);window.addEventListener("message",(e=>{if(Object.keys(c).includes(e.origin)){var r,n;try{n=JSON.parse(e.data)}catch(e){return}"complete"!==n.event&&("close"!==n.event&&"purge"!==n.event||null===(r=n.params)||void 0===r||!r.completePayment)||i||(i=!0,t.compassSDK.trackConversion(c[e.origin]))}})),n.handled=!0}if((null===(a=s[Po.HTTP])||void 0===a?void 0:a.length)>0){var u=So(s[Po.HTTP]),l=window.fetch,d=window.XMLHttpRequest.prototype.open;window.fetch=(e,r)=>{var n=l(e,r);return Object.keys(u).includes(e)&&n.then((r=>{r.ok&&t.compassSDK.trackConversion(u[e])})),n},window.XMLHttpRequest.prototype.open=function(){d.apply(this,arguments);try{var e=new URL(arguments[1]);Object.keys(u).includes(e.origin)&&t.compassSDK.setPageVar(u[e.origin],"true")}catch(e){}},n.handled=!0}}return Promise.resolve(n)},qa,(e,t)=>{var{siteContextSynchronizer:r}=e,n={handlerName:"siteContextSynchronizer",handled:!1};return null!=r&&r.actions&&(Object.values(r.actions).forEach((e=>{e.definition.forEach((e=>{return r=e,n=t.compassSDK,i=0,o=(e,t)=>{var r=Lo(e,t.params);switch(function(e){return void 0!==(null==e?void 0:e.name)}(t.action)?t.action.name:t.action){case"userType":"string"!=typeof r&&"number"!=typeof r||n.setUserType(r);break;case"conversion":"string"==typeof r&&n.trackConversion(r);break;case"marfeelCMD":var i=t.action;window.marfeel.cmd.push([i.config.module,e=>{var t;Array.isArray(r)&&(null==e||null===(t=e[i.config.method])||void 0===t||t.call(e,...r))}])}},a=e=>{for(var t of r.effects)if(No(e,t.condition))return void o(e,t)},(s=function e(){var t,n=!(arguments.length>0&&void 0!==arguments[0])||arguments[0],o=r.path.startsWith("window.")?r.path.substring(7):r.path,s=_o(window,o);if(s)if("array"===r.type){if(Array.isArray(s)){for(var c=i;c0&&setTimeout((()=>e()),u)})(),void(0,To.C)((()=>{s(!1)}));var r,n,i,o,a,s}))})),n.handled=!0),Promise.resolve(n)},Fa,es,(e,t)=>{var{marfeelOptimizer:r}=e,n={handlerName:"marfeelOptimizer",handled:!1};return null!=r&&r.actions&&Object.values(r.actions).length>0?new Promise((e=>{var r=Ro(t.compassSDK),n=0;if(r)return e();var i=setInterval((()=>{if(Ro(t.compassSDK)||n>=2)return clearInterval(i),e();n+=1}),5e3)})).then((()=>(n.handled=!0,Promise.resolve(n)))):Promise.resolve(n)},ls]],fs=function(){var e=r((function*(e,t,r,n){var i=[];for(var[o,a]of e.entries()){f(d.INIT_HANDLE_ACTION);var s=yield Promise.all(a.map((e=>e(t,r,n))));h(d.INIT_HANDLE_ACTION,d.END_HANDLE_ACTION,{index:o}),i.push(...s)}return i}));return function(t,r,n,i){return e.apply(this,arguments)}}(),hs=(e,t,r)=>fs(ps,e,t,r);class ms{constructor(){i(this,"promise",void 0),i(this,"promiseResolve",void 0),this.promise=new Promise((e=>{this.promiseResolve=e}))}resolve(){var e;null===(e=this.promiseResolve)||void 0===e||e.call(this)}}var vs=function(e){return e.NOT_EQUALS="NOT_EQUALS",e.EQUALS="EQUALS",e}({}),gs=e=>e.replace(/\/+$/,""),ys=(e,t)=>e.hostname===t.hostname&&gs(e.pathname)===gs(t.pathname),bs=function(){var e=r((function*(e){var t=window.location;switch(e.operator){case vs.NOT_EQUALS:return e.values.every((e=>!ys(t,new URL(e))));case vs.EQUALS:default:return e.values.some((e=>ys(t,new URL(e))))}}));return function(t){return e.apply(this,arguments)}}(),ws=function(){var e=r((function*(e,t){if(ta()||e.operator!==vs.EQUALS)return!0;var n=function(){var e=r((function*(){return new Promise((e=>{if(window.didomiConfig)return window.didomiOnReady=window.didomiOnReady||[],void window.didomiOnReady.push((t=>{e(t.shouldConsentBeCollected())}));t.consentSDK.hasToPromptForConsent(e)}))}));return function(){return e.apply(this,arguments)}}();return!!(yield n())||t.consentSDK.isActive()&&!function(e){var t=new RegExp("(^|;) ?".concat("mrfpass","=([^;]*)(;|$)")).exec(document.cookie);return t?t[2]:null}()&&e.values.some((e=>!t.consentSDK.hasConsentForPurpose(+e)))}));return function(t,r){return e.apply(this,arguments)}}(),Os="pendingConsent",Ps=function(){var e=r((function*(e){var t=window.location.hostname;switch(e.operator){case vs.NOT_EQUALS:return e.values.every((e=>e!==t));case vs.EQUALS:default:return e.values.some((e=>e===t))}}));return function(t){return e.apply(this,arguments)}}(),Es=function(){var e=r((function*(e){var t=document.documentElement.lang||"None";switch(e.operator){case vs.NOT_EQUALS:return e.values.every((e=>e!==t));case vs.EQUALS:default:return e.values.some((e=>e===t))}}));return function(t){return e.apply(this,arguments)}}(),ks=function(){var e=r((function*(e){var[t,r="/"]=window.location.pathname.split("/"),n="/"!==r?"/".concat(r,"/"):r;switch(e.operator){case vs.NOT_EQUALS:return e.values.every((e=>e!==n));case vs.EQUALS:default:return e.values.some((e=>e===n))}}));return function(t){return e.apply(this,arguments)}}(),Ss=function(){var e=r((function*(e){var t,r=(null==(t=window.navigator.language||window.navigator.userLanguage)?void 0:t.split("-")[0].toLowerCase())||"en";switch(e.operator){case vs.NOT_EQUALS:return e.values.every((e=>e!==r));case vs.EQUALS:default:return e.values.some((e=>e===r))}}));return function(t){return e.apply(this,arguments)}}();function js(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Cs(e){for(var t=1;tfunction(){var t=r((function*(t){switch(t.operator){case vs.NOT_EQUALS:return t.values.every((t=>t!==e));case vs.EQUALS:default:return t.values.some((t=>t===e))}}));return function(e){return t.apply(this,arguments)}}();function Is(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ds(e){for(var t=1;t(e.compassSDK.getUserVars()||[]).map((e=>{var[t,r]=e,n=As(r.toString());return Cs({[t]:n,["".concat("userVar::").concat(t)]:n},(e=>e.startsWith(Ts))(t)?{[t.replace(Ts,"")]:n}:{})})).reduce(((e,t)=>Cs(Cs({},e),t)),{})],Rs=function(){var e=r((function*(e,t){return Promise.all(e.map(t)).then((t=>e.filter(((e,r)=>t[r]))))}));return function(t,r){return e.apply(this,arguments)}}(),xs=function(){var e=r((function*(e,t,r){return!Array.isArray(e.filters)||0===e.filters.length||(yield Promise.all(e.filters.map((e=>{var n=r[e.key];return!n||n(e,t)})))).every(Boolean)}));return function(t,r,n){return e.apply(this,arguments)}}(),Ms=function(){var e=r((function*(e,t){if(!e.actions)return e;var r=yield t(e.actions);return 0!==r.length?Ds(Ds({},e),{},{actions:r.reduce(((e,t)=>{var[r,n]=t;return Ds(Ds({},e),{},{[r]:n})}),{})}):void 0}));return function(t,r){return e.apply(this,arguments)}}(),Us=function(){var e=r((function*(e,t){return Object.entries(e).reduce(function(){var e=r((function*(e,r){var[n,i]=r,o=yield((e,t)=>{var r=(e=>{var t=Ls.map((t=>t(e))).reduce(((e,t)=>Ds(Ds({},e),t)),{});return Ds(Ds({},Ns),t)})(t);return Ms(e,(e=>Rs(Object.entries(e),(e=>{var[n,i]=e;return xs(i,t,r)}))))})(i,t);return o?Ds(Ds({},yield e),{},{[n]:o}):e}));return function(t,r){return e.apply(this,arguments)}}(),Promise.resolve({}))}));return function(t,r){return e.apply(this,arguments)}}(),Vs=function(){var e=r((function*(e,t){return Object.entries(e).reduce(function(){var e=r((function*(e,r){var[n,i]=r,o=yield((e,t)=>Ms(e,(e=>Rs(Object.entries(e),(e=>{var[r,n]=e;return((e,t)=>Promise.resolve(t.some((t=>e.id===t))))(n,t)})))))(i,t.split(","));return o?Ds(Ds({},yield e),{},{[n]:o}):e}));return function(t,r){return e.apply(this,arguments)}}(),Promise.resolve({}))}));return function(t,r){return e.apply(this,arguments)}}(),qs=function(){var e=r((function*(e,t){var r,n=(r=vi(new URL(window.location.href)))&&_s.some((e=>r.startsWith(e)))?r:void 0;return n?Vs(e,n):Us(e,t)}));return function(t,r){return e.apply(this,arguments)}}();function Fs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function zs(e){for(var t=1;t(e=>"content"in e)(e)&&Uo(e.content)&&e.content.url.includes("marfeelpassexperience");function Bs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Ks(e){for(var t=1;t1&&void 0!==arguments[1]?arguments[1]:{actions:{}};if(!("actions"in e))return e;var{actions:r}=e,{actions:n={}}=t;if(Object.values(n).some(Hs))return{actions:Object.entries(r).reduce(((e,t)=>{var[r,n]=t;return Hs(n)?zs({},e):zs(zs({},e),{},{[r]:n})}),{})};if(Object.values(r).filter(Hs).length>1){var i=Object.keys(r).filter((e=>Hs(r[e])))[0];return{actions:zs({[i]:r[i]},Object.entries(r).filter((e=>{var[t,r]=e;return!Hs(r)})).reduce(((e,t)=>{var[r,n]=t;return zs(zs({},e),{},{[r]:n})}),{}))}}return e}};function Ws(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Js(e){for(var t=1;t(e=>"content"in e)(e)&&Uo(e.content)&&e.content.url.includes("marfeelpassexperienceengine.mrf.io")?Js(Js({},e),{},{features:Js(Js({},e.features),{},{removable:!1}),filters:[...e.filters||[],{operator:vs.EQUALS,values:["1","2","3","4","5","6","7","8","9","10","11"],key:Os}]}):e];function Qs(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function $s(e){for(var t=1;tXs.reduce(((e,t)=>t(e)),e)},Zs=e=>Object.entries(e).reduce(((e,t)=>{var[r,n]=t,i=Ys[r];return $s($s({},e),{},i&&n&&"actions"in n?{[r]:$s($s({},n),{},{actions:Object.entries(n.actions).reduce(((e,t)=>{var[r,n]=t;return $s($s({},e),{},{[r]:i(n)})}),{})})}:{[r]:n})}),{});function ec(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function tc(e){for(var t=1;t{var t=e(),r=new Promise((e=>{window.setTimeout((()=>{e(void 0)}),3e3)}));return Promise.race([t,r])},nc=e=>!!e,ic=function(){var e=r((function*(e,t,r,n){return yield((e,t,r)=>rc((()=>((e,t,r)=>fs(ds,e,t,r))(e,t,r))))(e,t,r),((e,t)=>Object.entries(e).reduce(((e,r)=>{var[n,i]=r,o=Gs[n];return Ks(Ks({},e),{},o&&i?{[n]:o(i,t[n])}:{[n]:i})}),{}))(yield qs(e,t),n)}));return function(t,r,n,i){return e.apply(this,arguments)}}();class oc{constructor(e,t,r,n){i(this,"config",void 0),i(this,"compassSDK",void 0),i(this,"synchronizer",void 0),i(this,"consentSDK",void 0),i(this,"executionData",void 0),i(this,"deferred",void 0);var o=e.experiences||e.flowcards;this.compassSDK=t,this.synchronizer=r,this.consentSDK=n,this.config={accountId:e.accountId,targeting:{}},o&&Object.assign(this.config,o),this.deferred=new ms,this.executionData=this.loadExperiences()}loadExperiences(){var e=this;return r((function*(){f(d.LOADING_EXPERIENCES);var t,n,i,o,a,s,c,u={},l=[],p={config:e.config,compassSDK:e.compassSDK,consentSDK:e.consentSDK},{active:m,clientParameters:v,preflight:g,recommender:y}=yield(t=e.config,t.preflight?(t.preflight.active=t.preflight.active||!!vi(new URL(window.location.href)),Promise.resolve(t.preflight)):function(e){return(e=>vo(e,"https://flowcards.mrf.io/json/active",new Set(["sid","ptch","debug_experiences"])))(e).then(fetch).then((e=>e.json())).then((e=>e.preflight?yo(yo({},e),{},{preflight:bo(e.preflight)}):e))}({location:new URL(window.location.toString()),siteId:t.accountId,pageTechnology:0})),b=Promise.resolve();if(e.config.recommenderConfig=y,g){var w=yield ic(Zs(g),p,e.synchronizer,u);u=Qn()(u,w),b=((e,t,r)=>rc((()=>hs(e,t,r))))(w,p,e.synchronizer).then((e=>{Array.isArray(e)&&l.push(...e);var[t]=l.filter((e=>"compass"===(null==e?void 0:e.handlerName)));(null==t||!t.handled)&&p.compassSDK.setRecirculationConfig({})}))}if(m){yield(n=e.config,i=e.deferred,null!==(o=n.waitFor)&&void 0!==o&&o.promise?n.waitFor.promise:null!==(a=n.waitFor)&&void 0!==a&&a.timeout?(c=n.waitFor.timeout,new Promise((e=>{setTimeout(e,c)}))):null!==(s=n.waitFor)&&void 0!==s&&s.done?i.promise:Promise.resolve());var O=yield ra(e.config,e.compassSDK,v).then(function(){var t=r((function*(t){var r=yield ic(Zs(t),p,e.synchronizer,u);return u=Qn()(u,r),((e,t,r)=>hs(e,t,r))(r,p,e.synchronizer)}));return function(e){return t.apply(this,arguments)}}());Array.isArray(O)&&l.push(...O)}yield b;var P=l.filter(nc).reduce(((e,t)=>tc(tc({},e),{},{[t.handlerName]:e[t.handlerName]||t.handled})),{});return Object.values($n).forEach((t=>{e.synchronizer.resolve(t,!!P[t])})),h(d.LOADING_EXPERIENCES,d.END_LOADING_EXPERIENCES),{handled:P,experiences:u}}))()}done(){this.deferred.resolve()}addTargeting(e,t){this.config.targeting[e]=t}addExperience(e,t){var r,n,i,o;null!==(n=(r=this.config).experiences)&&void 0!==n||(r.experiences={}),null!==(o=(i=this.config.experiences)[e])&&void 0!==o||(i[e]=[]),this.config.experiences[e].push(t)}addEventListener(e,t,r){var n=function(e,t){return"navigationchange"===e?e=>{t(e)}:"navigationfromcard"===e?ea(t,"host"):"navigationtocard"===e?ea(t,"flowcards"):null}(t,r);n&&ca(e).addEventListener("navigationchange",n)}hasExperiences(e){return this.executionData.then((t=>{var{handled:r}=t;return!!r[e]}))}triggerExperiences(){var e=this;return r((function*(){return e.loadExperiences()}))()}hasExperimentation(e){return this.executionData.then((t=>{var{experiences:r}=t;return((e,t)=>{var r,n=null===(r=e.experimentation)||void 0===r?void 0:r.actions;return!!n&&Object.values(n).some((e=>{var{url:r}=e;return-1!==r.indexOf("experimentType=".concat(t))}))})(r,e)}))}getRecommendations(e){var t=this;return r((function*(){return yield function(e){return xo.apply(this,arguments)}({experienceId:e,canonical:t.compassSDK.getCanonical(),userId:t.compassSDK.getUserId().actualUserId})}))()}}v("experiences",["compass","synchronizer","consent"],(()=>Promise.resolve(oc)));class ac{constructor(e,t){i(this,"croupier",void 0),this.croupier=t}addTargeting(e,t){this.croupier.addTargeting(e,t)}addCard(e){this.croupier.addExperience($n.FLOWCARDS,e)}addEventListener(e,t){this.croupier.addEventListener($n.FLOWCARDS,e,t)}hasCards(){return this.croupier.hasExperiences($n.FLOWCARDS)}}function sc(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function cc(e){for(var t=1;tPromise.resolve(ac))),v("multimedia",["compass","consent","synchronizer"],function(){var e=r((function*(e,t){var r,n,i,[o,s,c]=t;return yield S(cc(cc({},e),{},{blockOnNoConsent:!(null===(r=e.multimedia)||void 0===r||!r.providers)&&-1!==(null===(n=e.multimedia)||void 0===n||null===(i=n.providers)||void 0===i?void 0:i.indexOf("youtube"))||e.blockOnNoConsent}),s,c),e.multimedia?a.e(401).then(a.bind(a,401)).then((e=>e.default)):Promise.reject()}));return function(t,r){return e.apply(this,arguments)}}());class uc{constructor(){i(this,"promises",void 0),this.promises={}}wait(e){var t,r;null!==(r=(t=this.promises)[e])&&void 0!==r||(t[e]={});var n=this.promises[e].promise;return void 0===n?(n=new Promise(((t,r)=>{this.promises[e].resolve=t,this.promises[e].reject=r})),this.promises[e].promise=n,n):n}resolve(e,t){var r,n;null!==(n=(r=this.promises)[e])&&void 0!==n||(r[e]={}),void 0===this.promises[e].resolve?this.promises[e].promise=Promise.resolve(t):(0,this.promises[e].resolve)(t)}reject(e,t){var r,n;null!==(n=(r=this.promises)[e])&&void 0!==n||(r[e]={}),void 0===this.promises[e].reject?this.promises[e].promise=Promise.reject(t):(0,this.promises[e].reject)(t)}}v("synchronizer",[],(()=>Promise.resolve(uc)));let lc=()=>({emit(e,...t){for(let r=0,n=this.events[e]||[],i=n.length;r{this.events[e]=this.events[e]?.filter((e=>t!==e))}}});function dc(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function pc(e){for(var t=1;t{"click"===e.t?null==t||t(e):setTimeout((()=>{null==t||t(e)}),0)}))}emitRecirculation(e){var t=function(e){return{t:fc[e.t],m:e.m}}(e),r=function(e){return e.m.reduce(((t,r)=>{var n=r.n;if(n.startsWith("FC_")||n.startsWith("IL_")){var i,o=n.startsWith("IL_")?"inline":"flowcards";return pc(pc({},t),{},{["recirculation:".concat(o)]:{t:e.t,m:[...(null===(i=t["recirculation:".concat(o)])||void 0===i?void 0:i.m)||[],r]},["recirculation:".concat(n)]:{t:e.t,m:[r]}})}return pc(pc({},t),{},{["recirculation:".concat(n)]:{t:e.t,m:[r]}})}),{})}(t);this.emitter.emit("recirculation",t),Object.keys(r).forEach((e=>{this.emitter.emit(e,r[e])}))}}v("events",[],(()=>Promise.resolve(hc)));var mc=(e,t,r)=>{var n,i;n=((e,t,r)=>{var n=document.createElement("script");return n.src=e,n.id=r,t?n.type="module":(n.setAttribute("nomodule",""),n.setAttribute("defer","")),n})(e,r,t),i=document.head,new Promise(((e,t)=>{n.addEventListener("error",(e=>t(e.error))),i.append(n)}))},vc="https://sdk.mrf.io/statics",gc={ecommerce:{srcModule:"".concat(vc,"/compass-ecommerce-sdk.js"),srcNoModule:"".concat(vc,"/compass-ecommerce-sdk.es5.js"),dependencies:["compass"]},multimedia:{srcModule:"".concat(vc,"/compass-multimedia-sdk.js"),srcNoModule:"".concat(vc,"/compass-multimedia-sdk.es5.js"),dependencies:["compass"]}},yc=e=>"".concat(e,"?version=1940");class bc{load(e,t){var r=gc[e];t&&function(){m.addConfig(...arguments)}(t),mc(yc(r.srcModule),e,!0),mc(yc(r.srcNoModule),e,!1)}}v("loader",[],(()=>Promise.resolve(bc)))})();