ats-wrapper.privacymanager.io
Open in
urlscan Pro
18.245.31.100
Public Scan
URL:
https://ats-wrapper.privacymanager.io/ats-modules/2e06f752-55d7-4caa-a21a-d4b6eb54d92f/ats.js
Submission: On November 14 via api from IT — Scanned from IT
Submission: On November 14 via api from IT — Scanned from IT
Form analysis
0 forms found in the DOMText Content
!function(){var e={781:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppCaliforniaConsent=void 0;var r=n(3230);t.checkGppCaliforniaConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=!(1!==e.SaleOptOutNotice||1!==e.SharingOptOutNotice||0!==e.SensitiveDataLimitUseNotice&&1!==e.SensitiveDataLimitUseNotice||2!==e.SaleOptOut||2!==e.SharingOptOut||"[0,0,0,0,0,0,0,0,0]"!==JSON.stringify(e.SensitiveDataProcessing)||"[0,0]"!==JSON.stringify(e.KnownChildSensitiveDataConsents)||0!==e.PersonalDataConsents&&2!==e.PersonalDataConsents||!1!=!!e.Gpc),t.sectionId=r.GPP_SECTION_IDS.CALIFORNIA),t}},2988:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppColoradoConsent=void 0;var r=n(3230);t.checkGppColoradoConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=1===e.SharingNotice&&1===e.SaleOptOutNotice&&1===e.TargetedAdvertisingOptOutNotice&&2===e.SaleOptOut&&2===e.TargetedAdvertisingOptOut&&"[0,0,0,0,0,0,0]"===JSON.stringify(e.SensitiveDataProcessing)&&0===e.KnownChildSensitiveDataConsents&&!1==!!e.Gpc,t.sectionId=r.GPP_SECTION_IDS.COLORADO),t}},6883:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppConnecticutConsent=void 0;var r=n(3230);t.checkGppConnecticutConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=1===e.SharingNotice&&1===e.SaleOptOutNotice&&1===e.TargetedAdvertisingOptOutNotice&&2===e.SaleOptOut&&2===e.TargetedAdvertisingOptOut&&"[0,0,0,0,0,0,0,0]"===JSON.stringify(e.SensitiveDataProcessing)&&"[0,0,0]"===JSON.stringify(e.KnownChildSensitiveDataConsents)&&!1==!!e.Gpc,t.sectionId=r.GPP_SECTION_IDS.CONNECTICUT),t}},5991:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ConsentCheck=void 0;var r=n(653),o=n(781),i=n(6403),a=n(2988),s=n(2209),c=n(6883),u=n(3442),l=n(3230);t.ConsentCheck=class{constructor(e,t){this.sectionId=t,this.consent=this.handleSectionData(e)}handleSectionData=e=>e&&e.length>0?e.reduce(((e,t)=>Object.assign(e,t))):e.constructor===Object?e:null;checkGppSectionConsent=()=>{let e={sectionId:"",consent:!1};return this.sectionId&&(r.log.debug(`Checking GPP for ${l.GPP_STATE_NAMES[this.sectionId]}: ${JSON.stringify(this.consent)}`),this.sectionId===l.API_PREFIX_STRING.CALIFORNIA?e=(0,o.checkGppCaliforniaConsent)(this.consent):this.sectionId===l.API_PREFIX_STRING.COLORADO?e=(0,a.checkGppColoradoConsent)(this.consent):this.sectionId===l.API_PREFIX_STRING.UTAH?e=(0,s.checkGppUtahConsent)(this.consent):this.sectionId===l.API_PREFIX_STRING.CONNECTICUT?e=(0,c.checkGppConnecticutConsent)(this.consent):this.sectionId===l.API_PREFIX_STRING.VIRGINIA&&(e=(0,i.checkGppVirginiaConsent)(this.consent))),e.consent||e.sectionId||(e=(0,u.checkGppNationalConsent)(this.consent)),e}}},3230:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.US_STATES=t.GPP_STATE_NAMES=t.GPP_SECTION_IDS=t.API_PREFIX_STRING=void 0;t.GPP_SECTION_IDS={US_NATIONAL:"7",CALIFORNIA:"8",VIRGINIA:"9",COLORADO:"10",UTAH:"11",CONNECTICUT:"12"},t.US_STATES={CALIFORNIA:"CA",VIRGINIA:"VA",COLORADO:"CO",UTAH:"UT",CONNECTICUT:"CT"},t.API_PREFIX_STRING={US_NATIONAL:"usnat",CALIFORNIA:"usca",VIRGINIA:"usva",COLORADO:"usco",UTAH:"usut",CONNECTICUT:"usct"},t.GPP_STATE_NAMES={usnat:"US National",usca:"California",usva:"Virginia",usco:"Colorado",usut:"Utah",usct:"Connecticut"}},6717:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"ConsentCheck",{enumerable:!0,get:function(){return r.ConsentCheck}});var r=n(5991)},3442:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppNationalConsent=void 0;var r=n(3230);t.checkGppNationalConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=!(1!==e.SharingNotice||1!==e.SaleOptOutNotice||1!==e.SharingOptOutNotice||1!==e.TargetedAdvertisingOptOutNotice||0!==e.SensitiveDataProcessingOptOutNotice&&1!==e.SensitiveDataProcessingOptOutNotice||0!==e.SensitiveDataLimitUseNotice&&1!==e.SensitiveDataLimitUseNotice||2!==e.SaleOptOut||2!==e.SharingOptOut||2!==e.TargetedAdvertisingOptOut||"[0,0,0,0,0,0,0,0,0,0,0,0]"!==JSON.stringify(e.SensitiveDataProcessing)||"[0,0]"!==JSON.stringify(e.KnownChildSensitiveDataConsents)||0!==e.PersonalDataConsents&&2!==e.PersonalDataConsents||!1!=!!e.Gpc),t.sectionId=r.GPP_SECTION_IDS.US_NATIONAL),t}},2209:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppUtahConsent=void 0;var r=n(3230);t.checkGppUtahConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=1===e.SharingNotice&&1===e.SaleOptOutNotice&&1===e.TargetedAdvertisingOptOutNotice&&(0===e.SensitiveDataProcessingOptOutNotice||1===e.SensitiveDataProcessingOptOutNotice)&&2===e.SaleOptOut&&2===e.TargetedAdvertisingOptOut&&"[0,0,0,0,0,0,0,0]"===JSON.stringify(e.SensitiveDataProcessing)&&0===e.KnownChildSensitiveDataConsents&&!1==!!e.Gpc,t.sectionId=r.GPP_SECTION_IDS.UTAH),t}},6403:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.checkGppVirginiaConsent=void 0;var r=n(3230);t.checkGppVirginiaConsent=e=>{const t={sectionId:"",consent:!1};return e&&(t.consent=1===e.SharingNotice&&1===e.SaleOptOutNotice&&1===e.TargetedAdvertisingOptOutNotice&&2===e.SaleOptOut&&2===e.TargetedAdvertisingOptOut&&"[0,0,0,0,0,0,0,0]"===JSON.stringify(e.SensitiveDataProcessing)&&0===e.KnownChildSensitiveDataConsents&&!1==!!e.Gpc,t.sectionId=r.GPP_SECTION_IDS.VIRGINIA),t}},9782:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getGppConsentObject=void 0;var r=n(5483);t.getGppConsentObject=(e,t)=>{new r.GppVersion(t,e).awaitGppLibrary()}},6984:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GPP_VERSIONS=t.GPP_SECTIONS=t.GPP_APIS_PREFIXES=t.API_VARIATIONS=void 0;t.GPP_VERSIONS={v1_0:"1.0",v1_0_lr:"1.0_lr",v1_1:"1.1"},t.GPP_SECTIONS={CA:"usca",VA:"usva",CO:"usco",UT:"usut",CT:"usct",US_NATIONAL:"usnat"},t.GPP_APIS_PREFIXES=["usnat","usca","usva","usco","usut","usct","7:usnat","8:usca","9:usva","10:usco","11:usut","12:usct"],t.API_VARIATIONS={CA:["usca","8:usca"],VA:["usva","9:usva"],CO:["usco","10:usco"],UT:["usut","11:usut"],CT:["usct","12:usct"],US_NATIONAL:["usnat","7:usnat"]}},5271:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.GppVersion=void 0;var r=n(653),o=n(6717),i=n(6984),a=n(4505);t.GppVersion=class{constructor(e,t=null){this.moduleName=e,this.usStateCode=t,this.flag_gppLibraryFullyLoaded=!1,this.flag_gppEventListenerExists=!1,this.flag_gppEventListenerRegistered=!1}setGppLibraryFullyLoadedFlag(e){this.flag_gppLibraryFullyLoaded=e}setGppEventListenerExists(e){this.flag_gppEventListenerExists=e}setGppEventListenerRegistered(e){this.flag_gppEventListenerRegistered=e}awaitGppLibrary(){const e={cmpType:"gpp",consentString:"",consent:null,sectionId:""};let t=0;const n=setInterval((()=>{++t,window.__gpp||this.flag_gppLibraryFullyLoaded||10!==t||(clearInterval(n),(0,a.dispatchCustomEvent)(`${this.moduleName}CcpaFallbackEvent`,null)),window.__gpp&&!this.flag_gppEventListenerExists&&(clearInterval(n),window.__gpp("addEventListener",(t=>this.gppEventListenerCallback(t,e))),this.setGppEventListenerExists(!0),this.flag_gppEventListenerRegistered||(0,a.dispatchCustomEvent)(`${this.moduleName}RecheckAtsConsentEvent`,e))}),200)}gppEventListenerCallback(e,t){this.setGppEventListenerRegistered(!0);const{eventName:n,pingData:r}=e;if(["cmpStatus","sectionChange","listenerRegistered"].includes(n)&&r&&"loaded"===r.cmpStatus){const{gppVersion:e,supportedAPIs:o}=r;if(this.isApiSupported(o)){const n=this.getSupportedSectionPrefix(this.usStateCode,o),i=this.getVersionData(e,n,r);Object.assign(t,i),i||(0,a.dispatchCustomEvent)(`${this.moduleName}CcpaFallbackEvent`,null),i&&!this.flag_gppLibraryFullyLoaded&&(this.setGppLibraryFullyLoadedFlag(!0),(0,a.dispatchCustomEvent)(`${this.moduleName}RecheckAtsConsentEvent`,t))}else(0,a.dispatchCustomEvent)(`${this.moduleName}CcpaFallbackEvent`,null);"sectionChange"===n&&(Object.assign(t,{...t,isUserInteraction:!0}),(0,a.dispatchCustomEvent)(`${this.moduleName}UserActionCompleteEvent`,t))}}isApiSupported=e=>e.some((e=>i.GPP_APIS_PREFIXES.includes(e)));getSectionPrefix=e=>i.GPP_SECTIONS[e]?i.GPP_SECTIONS[e]:i.GPP_SECTIONS.US_NATIONAL;getSectionPrefixVariations=e=>i.API_VARIATIONS[e]?i.API_VARIATIONS[e]:i.API_VARIATIONS.US_NATIONAL;getSupportedSectionPrefix=(e,t)=>{if(!e)return r.log.debug("Could not get US state."),i.GPP_SECTIONS.US_NATIONAL;r.log.debug(`Checking GPP for ${i.GPP_SECTIONS[e]?i.GPP_SECTIONS[e]:i.GPP_SECTIONS.US_NATIONAL} section(user's location: ${e})`);const n=this.getSectionPrefix(e),o=this.getSectionPrefixVariations(e),a=t.some((e=>o.includes(e)));return a||r.log.debug(`CMP does not support ${i.GPP_SECTIONS[this.usStateCode]?i.GPP_SECTIONS[this.usStateCode]:this.usStateCode} API. Checking GPP for US National.`),a?n:i.GPP_SECTIONS.US_NATIONAL};getVersionData(e,t,n){let a,s="";if(e===i.GPP_VERSIONS.v1_0){r.log.debug("Gpp getGPPData return immediately value implementation");const e=window.__gpp("getGPPData");s=e.gppString;const n=window.__gpp("getSection",null,t);a=[n]}e===i.GPP_VERSIONS.v1_0_lr&&(r.log.debug("Gpp getGPPData callback implementation"),window.__gpp("getGPPData",(e=>{s=e.gppString})),window.__gpp("getSection",(e=>{a=e}),t)),e===i.GPP_VERSIONS.v1_1&&(r.log.debug("Gpp getSection callback implementation"),s=n.gppString,window.__gpp("getSection",(e=>{a=e}),t));let c={consentString:s,consent:null,sectionId:""};if(a){r.log.debug(`[GPP] Event listener invoked with ${JSON.stringify(a)}`);const e=new o.ConsentCheck(a,t),{consent:n,sectionId:i}=e.checkGppSectionConsent();c.consent=n,c.sectionId=i}else c=null,r.log.debug(`[GPP] Section "${t}" is not supported by CMP. Event listener invoked with ${JSON.stringify(a)}`);return c}}},5483:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"GppVersion",{enumerable:!0,get:function(){return r.GppVersion}});var r=n(5271)},7249:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.gppConsentCheck=void 0;var r=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=o(t);if(n&&n.has(e))return n.get(e);var r={__proto__:null},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=i?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(r,a,s):r[a]=e[a]}return r.default=e,n&&n.set(e,r),r}(n(9782));function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(o=function(e){return e?n:t})(e)}t.gppConsentCheck=r},2525:function(e,t,n){"use strict";Object.defineProperty(t,"mF",{enumerable:!0,get:function(){return o.gppConsentCheck}}),Object.defineProperty(t,"ff",{enumerable:!0,get:function(){return r.tcfConsentCheck}});var r=n(3166),o=n(7249)},4351:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getConsent=void 0;var r=n(653),o=n(4738),i=n(4037);t.getConsent=e=>{const t=(e=>{try{return new o.TCString(e).getCoreSegmentData()}catch(e){r.log.error(`Failed to decode consent string. ${e}`)}})(e);return!!t&&((n=t)&&n.vendorsConsent.includes(i.LIVERAMP_VENDOR_ID)&&i.LIVERAMP_PURPOSE_IDS.every((e=>n.purposesConsent.includes(e))));var n}},4037:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.LIVERAMP_VENDOR_ID=t.LIVERAMP_PURPOSE_IDS=t.GDPR_COUNTRIES=void 0;t.LIVERAMP_VENDOR_ID=97,t.LIVERAMP_PURPOSE_IDS=[1,2,3,4,5,6,7,8,9,10],t.GDPR_COUNTRIES=["AT","BE","BG","HR","CY","CZ","DK","EE","FI","FR","DE","GR","HU","IE","IT","LV","LT","LU","MT","NL","PL","PT","RO","SK","SI","ES","SE","GB"]},3166:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.tcfConsentCheck=void 0;var r=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=o(t);if(n&&n.has(e))return n.get(e);var r={__proto__:null},i=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if("default"!==a&&Object.prototype.hasOwnProperty.call(e,a)){var s=i?Object.getOwnPropertyDescriptor(e,a):null;s&&(s.get||s.set)?Object.defineProperty(r,a,s):r[a]=e[a]}return r.default=e,n&&n.set(e,r),r}(n(5544));function o(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(o=function(e){return e?n:t})(e)}t.tcfConsentCheck=r},5544:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.getTcfConsentObject=t.gdprApplies=void 0;var r=n(4351),o=n(4037),i=n(4505);const a=(e,t,n)=>{window.__tcfapi("addEventListener",2,((o,a)=>{if(a&&("tcloaded"===o.eventStatus||"useractioncomplete"===o.eventStatus)){const a=(0,r.getConsent)(o.tcString);if(e.consent=a,e.isUserInteraction="useractioncomplete"===o.eventStatus,e.consentString=o.tcString,e.isUserInteraction&&!t)return void(0,i.dispatchCustomEvent)(`${n}UserActionCompleteEvent`,e);(0,i.dispatchCustomEvent)(`${n}RecheckAtsConsentEvent`,e),t=!1}})),t&&(t=!1,(0,i.dispatchCustomEvent)(`${n}RecheckAtsConsentEvent`,e))};t.getTcfConsentObject=(e,t)=>{let n=0;const r={cmpType:"gdpr",consent:null,isUserInteraction:!1,consentString:null};if(window.__tcfapi)a(r,e,t);else{(0,i.dispatchCustomEvent)(`${t}RecheckAtsConsentEvent`,r);const o=setInterval((()=>{++n,window.__tcfapi?(clearInterval(o),a(r,e,t)):10===n&&(clearInterval(o),(0,i.dispatchCustomEvent)(`${t}RecheckAtsConsentEvent`,r))}),200)}};t.gdprApplies=e=>o.GDPR_COUNTRIES.includes(e)},8036:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.decodeFromBase64=function(e,t){const n=function(e){let t=e;for(;t.length%4!=0;)t+="=";t=t.replace(/-/g,"+").replace(/_/g,"/");const n=o.default.decode(t);let r="";for(let e=0;e<n.length;e+=1){const t=n.charCodeAt(e).toString(2);r+=(0,i.padLeft)(t,8-t.length)}return r}(e),{decodedObject:r}=(0,a.decodeFields)(n,t);return r};var r,o=(r=n(3418))&&r.__esModule?r:{default:r},i=n(5588),a=n(2790)},2790:function(e,t,n){"use strict";function r(e,t,n){if(void 0!==n&&e.length<t+n)throw new Error("Invalid decoding input")}function o(e,t,n){return r(e,t,n),parseInt(e.substr(t,n),2)}function i(e,t,n){return r(e,t,n),new Date(100*o(e,t,n))}function a(e,t){return 1===parseInt(e.substr(t,1),2)}function s(e){const t=o(e);return String.fromCharCode(t+65).toLowerCase()}function c(e,t,n){r(e,t,n);const o=e.substr(t,n);return s(o.slice(0,n/2))+s(o.slice(n/2))}function u(e,t){let n=t;const r=[],i=o(e,n,12);n+=12;let s=0;for(;s<i;){const t=a(e,n);if(n+=1,t){const t=o(e,n,16);n+=16;const i=o(e,n,16);n+=16;for(let e=t;e<=i;e+=1)r.push(e)}else{const t=o(e,n,16);n+=16,r.push(t)}s+=1}return{fieldValue:r,newPosition:n}}function l(e,t,n){r(e,t,n);const o=[],i=e.substr(t,n);for(let e=0;e<i.length;e+=1)"0"!==i[e]&&o.push(e+1);return o}function d(e,t,n){let r=[],i=t;const s=o(e,t,n);i+=n;const c=a(e,i);return i+=1,c?u(e,i):(r=l(e.substr(i,s)),i+=s,{fieldValue:r,newPosition:i})}function f(e,t,n=0){let r=n;t.segmentId&&(r+=3);const s=t.fields.reduce(((t,n)=>{const{name:s,numBits:f}=n,{fieldValue:g,newPosition:b}=function(e,t,n,r){const{type:s,numBits:f}=r,g="function"==typeof f?f(t):f;switch(s){case"int":return{fieldValue:o(e,n,g)};case"bool":return{fieldValue:a(e,n)};case"date":return{fieldValue:i(e,n,g)};case"list":return{fieldValue:l(e,n,g)};case"textcode":return{fieldValue:c(e,n,g)};case"range":return u(e,n);case"minlist":return d(e,n,g);case"array":return p(e,n,g,r);default:throw new Error(`TCString - Unknown field type ${s} for decoding`)}}(e,t,r,n);return void 0!==g&&(t[s]=g),void 0!==b?r=b:"number"==typeof f&&(r+=f),t}),{});return{decodedObject:s,newPosition:r}}function p(e,t,n,r){let i=t;const a=[],s=o(e,i,n);i+=n;for(let t=0;t<s;t+=1){const{decodedObject:t,newPosition:n}=f(e,r,i);i=n,a.push(t)}return{fieldValue:a,newPosition:i}}Object.defineProperty(t,"__esModule",{value:!0}),t.decodeBitsToArray=p,t.decodeBitsToBool=a,t.decodeBitsToDate=i,t.decodeBitsToInt=o,t.decodeBitsToLetter=s,t.decodeBitsToMinList=d,t.decodeBitsToRange=u,t.decodeBitsToTextCode=c,t.decodeFields=f,n(4936)},9618:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;t.default={core:{fields:[{name:"version",type:"int",numBits:6},{name:"created",type:"date",numBits:36},{name:"lastUpdated",type:"date",numBits:36},{name:"cmpId",type:"int",numBits:12},{name:"cmpVersion",type:"int",numBits:12},{name:"consentScreen",type:"int",numBits:6},{name:"consentLanguage",type:"textcode",numBits:12},{name:"vendorListVersion",type:"int",numBits:12},{name:"tcfPolicyVersion",type:"int",numBits:6},{name:"isServiceSpecific",type:"bool",numBits:1},{name:"useNonStandardStacks",type:"bool",numBits:1},{name:"specialFeatureOptIns",type:"list",numBits:12},{name:"purposesConsent",type:"list",numBits:24},{name:"purposeLITransparency",type:"list",numBits:24},{name:"purposeOneTreatment",type:"bool",numBits:1},{name:"publisherCC",type:"textcode",numBits:12},{name:"vendorsConsent",type:"minlist",numBits:16},{name:"vendorsLegitimateInterest",type:"minlist",numBits:16},{name:"publisherRestrictions",type:"array",numBits:12,fields:[{name:"purposeId",type:"int",numBits:6},{name:"restrictionType",type:"int",numBits:2},{name:"restrictedVendors",type:"range"}]}]}}},4738:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"TCString",{enumerable:!0,get:function(){return r.TCString}});var r=n(8138)},8138:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.TCString=void 0;var r,o=n(8036),i=(r=n(9618))&&r.__esModule?r:{default:r};t.TCString=class{constructor(e=null){this.setConsentString(e)}setConsentString(e){if(this.core=null,e){const t=e.split(".");if(t.length>0&&(this.core=this.setCoreSegmentString(t[0])),t.length>2)throw new Error("Unknown segment type in consent string")}}setCoreSegmentString=e=>(0,o.decodeFromBase64)(e,i.default.core);getCoreSegmentData=()=>this.core?{...this.core}:null}},5588:function(e,t){"use strict";function n(e,t="0"){let n="";for(let r=0;r<e;r+=1)n+=t;return n}Object.defineProperty(t,"__esModule",{value:!0}),t.getMaxListElement=function(e){let t=0;return(e||[]).forEach((e=>{e>t&&(t=e)})),t},t.padLeft=function(e,t){return n(Math.max(0,t))+e},t.padRight=function(e,t){return e+n(Math.max(0,t))}},4505:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.dispatchCustomEvent=void 0;t.dispatchCustomEvent=async(e,t)=>{const n=new CustomEvent(e,{detail:t});window.dispatchEvent(n)}},9937:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=n(8309);function o(e,t){const n={...e,...t};return Object.keys(e).forEach((i=>{e[i]&&"object"==typeof e[i]&&((0,r.isObject)(e[i])&&t[i]?n[i]=o(e[i],t[i]):!t[i]||t[i].constructor!==String&&t[i].constructor!==Array?e[i].constructor===String||e[i].constructor===Array?n[i]=e[i]:n[i]={...e[i],...t[i]}:n[i]=t[i])})),n}t.default=new class{constructor(){this.validKeys={}}update=(e,t)=>{if(e&&"object"==typeof e){t&&(this.validKeys=Object.keys(e));const{validUpdates:n}=Object.keys(e).reduce(((t,n)=>(this.validKeys.indexOf(n)>-1&&(t.validUpdates={...t.validUpdates,[n]:e[n]}),t)),{validUpdates:{}}),r=o(this,n);Object.assign(this,r)}}}},1469:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.cmpUtils=t.cmpStorage=void 0,Object.defineProperty(t,"config",{enumerable:!0,get:function(){return o.default}}),t.locationHandler=void 0,Object.defineProperty(t,"log",{enumerable:!0,get:function(){return i.default}}),t.portal=void 0,Object.defineProperty(t,"setLogger",{enumerable:!0,get:function(){return i.setLogger}});var r,o=(r=n(9937))&&r.__esModule?r:{default:r},i=d(n(8237)),a=d(n(5716));t.portal=a;var s=d(n(5269));t.cmpStorage=s;var c=d(n(8309));t.cmpUtils=c;var u=d(n(4447));function l(e){if("function"!=typeof WeakMap)return null;var t=new WeakMap,n=new WeakMap;return(l=function(e){return e?n:t})(e)}function d(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var n=l(t);if(n&&n.has(e))return n.get(e);var r={__proto__:null},o=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var i in e)if("default"!==i&&Object.prototype.hasOwnProperty.call(e,i)){var a=o?Object.getOwnPropertyDescriptor(e,i):null;a&&(a.get||a.set)?Object.defineProperty(r,i,a):r[i]=e[i]}return r.default=e,n&&n.set(e,r),r}t.locationHandler=u},4447:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.updateGeoTargeting=t.isLocationUs=t.isLocationSupported=t.getLocation=void 0;var r=s(n(9937)),o=s(n(8237)),i=n(8309),a=n(5269);function s(e){return e&&e.__esModule?e:{default:e}}t.updateGeoTargeting=e=>{const t=document.getElementById("liveramp-cmp-wrapper");if(t){const{geoTargeting:n}=t.dataset;if(n)try{e.geoTargeting=JSON.parse(n),o.default.debug("Updated geo targeting: ",n)}catch(e){o.default.error("Unable to parse geo targeting: ",e)}}return e};t.getLocation=async()=>{let e=await(0,a.readGeoLocation)();if(e=(e=>{const t=(0,i.getUrlParam)("lrcountry"),n=(0,i.getUrlParam)("lrregion");return e?(t&&(e.country=t),n&&(e.region=n),e):{country:t,region:n}})(e),e&&e.country)return e;try{const e=await fetch(r.default.geoTargetingUrl,{headers:{Accept:"application/json","Content-Type":"application/json"}});if(e){const t=await e.json();if(t&&t.country)return(0,a.writeGeoLocation)(JSON.stringify(t),!0),t}}catch(e){return o.default.warn("Location Data Unavailable. Some features may be limited. Please allow location services for full functionality.",e),null}};const c=e=>"US"===e;t.isLocationUs=c;t.isLocationSupported=(e,t)=>{let n=!1;if(t.allCountries)n=!0;else if(e){const r=t.countries.includes(e.country);if(r&&c(e.country))if(t.allStates)n=!0;else{const r=!!(t.states&&t.states.length>0)&&t.states.includes(e.region);n=t.includeSelection?r:!r}else n=t.includeSelection?r:!r}return n}},8237:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.setLogger=t.default=void 0;var r,o=(r=n(9937))&&r.__esModule?r:{default:r};let i=null,a=null;t.setLogger=(e,t)=>{i=e,a=t};const s=["debug","info","warn","error"];t.default=s.reduce(((e,t,n)=>(e[t]=(...e)=>{const r="debug"===t?"log":t;let{logging:c}=o.default;if(void 0===c&&(c=i),Function.prototype.bind&&window.console&&"object"==typeof console.log&&["log","info","warn","error","assert","dir","clear","profile","profileEnd"].forEach((e=>{console[e]=(void 0).bind(console[e],console)}),Function.prototype.call),c&&console&&"function"==typeof console[r]){const o=s.indexOf(c.toString().toLocaleLowerCase());if(!0===c||o>-1&&n>=o){const[n,...o]=[...e];console[r](`${t.toUpperCase()} - ${a||"(GlobalCmp)"} ${n}`,...o)}}},e)),{})},5716:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.openGlobalPortal=b,t.openSharedPortal=h,t.sendGlobalPortalCommand=function(e,t){const n="vp:"+ ++l;return new Promise(((r,o)=>b(t).then((i=>{v(i,e,t,f,n,r,o)})).catch(o)))},t.sendSharedPortalCommand=function(e,t){const n="vp:"+ ++d;return new Promise(((r,o)=>h(t).then((i=>{v(i,e,t,p,n,r,o)})).catch(o)))};var r,o=(r=n(9937))&&r.__esModule?r:{default:r};const i=5e4,a=5e3,s="lrcmpData";let c,u,l=0,d=0;const f={},p={};function g(e,t,n){return new Promise(((r,o)=>{const a=function(e){const t=document.createElement("iframe");return t.setAttribute("style","display: none;"),t.setAttribute("src",e),t}(e),c=function(e){const t=setInterval((()=>{document.body&&(document.body.appendChild(e),clearInterval(t))}),5);return t}(a);let u=setTimeout((()=>{clearInterval(c),o(new Error(`Communication could not be established with the portal domain within ${i} milliseconds`))}),i);window.addEventListener("message",(e=>{if(e&&e.data){const o=e.data[n||s];if(o)if("isLoaded"===o.command&&u)clearTimeout(u),u=void 0,r(a);else{const e=t[o.callId];if(e){const{timeout:n}=e,r=e.resolve;delete t[o.callId],clearTimeout(n),r(o.result)}}}}))}))}function b(e){return u||(u=g(o.default.globalConsentLocation,f,e)),u}function h(e){return c||(c=g(o.default.sharedConsentLocation,p,e)),c}function v(e,t,n,r,o,i,c){const u=setTimeout((()=>{delete r[o],c(new Error(`${t.command} response not received from portal domain within ${a} milliseconds`))}),a);r[o]={resolve:i,timeout:u};const l={};l[n||s]={callId:o,...t},e.contentWindow.postMessage(l,"*")}},5269:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.MAX_AGE=void 0,t.readCookie=g,t.readData=v,t.readFromLocalStorage=p,t.readFromPortal=m,t.readGeoLocation=function(){if(!i.isSafari&&r.default.thirdPartyCookieSync)return m(a.sendSharedPortalCommand,l,d).then((e=>{o.default.debug("Read geo location from portal: ",e);try{if(e)return O(e),JSON.parse(e)}catch(e){o.default.debug("Error while parsing geoLocation from portal: ",e)}return w()}));return Promise.resolve(w())},t.writeCookie=b,t.writeData=y,t.writeGeoLocation=O,t.writeOnPortal=S,t.writeToLocalStorage=h;var r=s(n(9937)),o=s(n(8237)),i=n(8309),a=n(5716);function s(e){return e&&e.__esModule?e:{default:e}}const c="Thu, 01 Jan 1970 00:00:01 GMT;",u=t.MAX_AGE=33696e3,l="lrcmpData",d="geo-location",f=86400;function p(e,t=!1,n=!1){try{if(localStorage)if(n){const t=localStorage.getItem(e);if(t)return t}else{const n=JSON.parse(localStorage.getItem(e));if(n&&n.data){if(!n.expire||n.expire>+new Date)return n.data;if(!t){const t=g(e,!0);return t||n.data}}}}catch(t){o.default.error(`Unable to parse ${e} from localStorage: `,t)}return t?null:g(e,!0)}function g(e,t=!1){const n=`; ${document.cookie}`.split(`; ${e}=`);return n.length>=2?n.pop().split(";").shift():t?null:p(e,!0)}function b(e,t,n,o="/"){const i=null===n?"":`;max-age=${n}`,a=null===n?"":`;expires=${new Date(1*new Date+1e3*n).toUTCString()}`;o=`;path=${o}`;let s=function(){let e,t;const n="lr_get_top_level_domain=cookie",r=document.location.hostname.split(".");for(e=r.length-1;e>=0;e--)if(t=r.slice(e).join("."),document.cookie=`${n};domain=.${t};SameSite=Lax`,document.cookie.indexOf(n)>-1)return document.cookie=`${n.split("=")[0]}=;domain=.${t};expires==${c}SameSite=Lax`,t;return null}();return s=s?`;domain=.${s}`:"",t?r.default.useSecondLevelDomain?(document.cookie=`${e}=${o};expires=${c}SameSite=Lax`,document.cookie=`${e}=${t}${o}${s}${i}${a};SameSite=Lax`):(document.cookie=`${e}=${s}${o};expires=${c}SameSite=Lax`,document.cookie=`${e}=${t}${o}${i}${a};SameSite=Lax`):(document.cookie=`${e}=${o};expires=${c}SameSite=Lax`,document.cookie=`${e}=${s}${o};expires=${c}SameSite=Lax`),g(e)}function h(e,t,n=u,r=!1){try{if(localStorage){if(t){const r={data:t,expire:+new Date(1*new Date+1e3*n)};localStorage.setItem(e,JSON.stringify(r))}else localStorage.removeItem(e);return t}}catch(t){o.default.error(`Unable to store ${e} to localStorage: `,t)}return r?null:b(e,t,n)}function v(e,t=!1,n=!1){if(r.default.useExternalData){const t=(0,i.getUrlParam)(e);if(t)return o.default.debug(`Skipping cookies and localStorage for ${e}, read from query string: `,t),t}return r.default.useCookies?g(e):p(e,t,n)}function y(e,t,n,o){return r.default.useCookies?b(e,t,n,o):h(e,t,n)}function m(e,t,n){return o.default.debug("Request data from portal"),e({command:"read",name:n,useCookies:r.default.useCookies},t).then((e=>(o.default.debug("Read data from portal: ",e),e))).catch((e=>{o.default.error("Failed reading from portal: ",e)}))}function S(e,t,n,i,a){return o.default.debug("Send data to portal: ",i),e({command:"write",name:n,value:i,maxAgeSeconds:a,useCookies:r.default.useCookies},t).catch((e=>{o.default.error("Failed writing data on portal: ",e)}))}function w(){const e=v(d);if(o.default.debug("Read local geoLocation: ",e),e)try{return JSON.parse(e)}catch(e){o.default.debug("Error while parsing local geoLocation: ",e)}return e}function O(e,t){o.default.debug("Writing geoLocation: ",e),!i.isSafari&&r.default.thirdPartyCookieSync&&t&&S(a.sendSharedPortalCommand,l,d,e,f),y(d,e,f)}},8309:function(e){"use strict";const t=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);function n(){return!!window.navigator.globalPrivacyControl}function r(){const e=window.doNotTrack||window.navigator.doNotTrack||window.navigator.msDoNotTrack;return!!e&&("1"===e.charAt(0)||"yes"===e)}e.exports={isSafari:t,getDecisecond:function(){const e=new Date,t=Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate());return Math.round(t/100)},isDoNotTrackEnabled:r,isBoolean:function(e){return!1===e||!0===e},isObject:function(e){const t=typeof e;return("function"===t||"object"===t&&!!e)&&e.constructor!==Array},isObjectEmpty:function(e){return 0===Object.keys(e).length&&e.constructor===Object},orderObject:function(e){return Object.keys(e).sort().reduce(((t,n)=>(t[n]=e[n],Array.isArray(t[n])&&t[n].sort(),t)),{})},hashCode:function(e){let t=0;const n=e.length;let r=0;if(n>0)for(;r<n;)t=(t<<5)-t+e.charCodeAt(r++)|0;return t.toString()},getUrlParam:function(e){return function(){const e=window.location.href.split("?")[1],t={};if(e){const n=e.split("&");for(const e of n){const[n,r]=e.split("=");t[n]=r}}return t}()[e]},syncEmitter:function(e,t){this.done=()=>{e(t)}},shouldCcpaBeSuppressed:function(e){const t=r()&&e.doNotTrack,o=n()&&e.globalPrivacyControl;return e.enabled&&(t||o)},dispatchCustomEvent:function(e,t){const n=new CustomEvent(e,{detail:t});window.dispatchEvent(n)},isGlobalPrivacyControlEnabled:n}},653:function(e,t,n){e.exports=n(1469)},3418:function(e,t,n){var r;e=n.nmd(e),function(){var o=t,i=(e&&e.exports,"object"==typeof n.g&&n.g);i.global!==i&&i.window;var a=function(e){this.message=e};(a.prototype=new Error).name="InvalidCharacterError";var s=function(e){throw new a(e)},c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",u=/[\t\n\f\r ]/g,l={encode:function(e){e=String(e),/[^\0-\xFF]/.test(e)&&s("The string to be encoded contains characters outside of the Latin1 range.");for(var t,n,r,o,i=e.length%3,a="",u=-1,l=e.length-i;++u<l;)t=e.charCodeAt(u)<<16,n=e.charCodeAt(++u)<<8,r=e.charCodeAt(++u),a+=c.charAt((o=t+n+r)>>18&63)+c.charAt(o>>12&63)+c.charAt(o>>6&63)+c.charAt(63&o);return 2==i?(t=e.charCodeAt(u)<<8,n=e.charCodeAt(++u),a+=c.charAt((o=t+n)>>10)+c.charAt(o>>4&63)+c.charAt(o<<2&63)+"="):1==i&&(o=e.charCodeAt(u),a+=c.charAt(o>>2)+c.charAt(o<<4&63)+"=="),a},decode:function(e){var t=(e=String(e).replace(u,"")).length;t%4==0&&(t=(e=e.replace(/==?$/,"")).length),(t%4==1||/[^+a-zA-Z0-9/]/.test(e))&&s("Invalid character: the string to be decoded is not correctly encoded.");for(var n,r,o=0,i="",a=-1;++a<t;)r=c.indexOf(e.charAt(a)),n=o%4?64*n+r:r,o++%4&&(i+=String.fromCharCode(255&n>>(-2*o&6)));return i},version:"1.0.0"};void 0===(r=function(){return l}.call(t,n,t,e))||(e.exports=r)}()},2471:function(e,t){var n,r;r="undefined"!=typeof self?self:this,n=function(){return function(e){"use strict";if("function"!=typeof Promise)throw"Promise support required";var t=e.crypto||e.msCrypto;if(t){var n=t.subtle||t.webkitSubtle;if(n){var r=e.Crypto||t.constructor||Object,o=e.SubtleCrypto||n.constructor||Object,i=(e.CryptoKey||e.Key,e.navigator.userAgent.indexOf("Edge/")>-1),a=!!e.msCrypto&&!i,s=!t.subtle&&!!t.webkitSubtle;if(a||s){var c={KoZIhvcNAQEB:"1.2.840.113549.1.1.1"},u={"1.2.840.113549.1.1.1":"KoZIhvcNAQEB"};if(["generateKey","importKey","unwrapKey"].forEach((function(e){var r=n[e];n[e]=function(o,i,c){var u,l,d,g,S=[].slice.call(arguments);switch(e){case"generateKey":u=b(o),l=i,d=c;break;case"importKey":u=b(c),l=S[3],d=S[4],"jwk"===o&&((i=v(i)).alg||(i.alg=h(u)),i.key_ops||(i.key_ops="oct"!==i.kty?"d"in i?d.filter(A):d.filter(E):d.slice()),S[1]=y(i));break;case"unwrapKey":u=S[4],l=S[5],d=S[6],S[2]=c._key}if("generateKey"===e&&"HMAC"===u.name&&u.hash)return u.length=u.length||{"SHA-1":512,"SHA-256":512,"SHA-384":1024,"SHA-512":1024}[u.hash.name],n.importKey("raw",t.getRandomValues(new Uint8Array(u.length+7>>3)),u,l,d);if(s&&"generateKey"===e&&"RSASSA-PKCS1-v1_5"===u.name&&(!u.modulusLength||u.modulusLength>=2048))return(o=b(o)).name="RSAES-PKCS1-v1_5",delete o.hash,n.generateKey(o,!0,["encrypt","decrypt"]).then((function(e){return Promise.all([n.exportKey("jwk",e.publicKey),n.exportKey("jwk",e.privateKey)])})).then((function(e){return e[0].alg=e[1].alg=h(u),e[0].key_ops=d.filter(E),e[1].key_ops=d.filter(A),Promise.all([n.importKey("jwk",e[0],u,!0,e[0].key_ops),n.importKey("jwk",e[1],u,l,e[1].key_ops)])})).then((function(e){return{publicKey:e[0],privateKey:e[1]}}));if((s||a&&"SHA-1"===(u.hash||{}).name)&&"importKey"===e&&"jwk"===o&&"HMAC"===u.name&&"oct"===i.kty)return n.importKey("raw",p(f(i.k)),c,S[3],S[4]);if(s&&"importKey"===e&&("spki"===o||"pkcs8"===o))return n.importKey("jwk",m(i),c,S[3],S[4]);if(a&&"unwrapKey"===e)return n.decrypt(S[3],c,i).then((function(e){return n.importKey(o,e,S[4],S[5],S[6])}));try{g=r.apply(n,S)}catch(e){return Promise.reject(e)}return a&&(g=new Promise((function(e,t){g.onabort=g.onerror=function(e){t(e)},g.oncomplete=function(t){e(t.target.result)}}))),g=g.then((function(e){return"HMAC"===u.name&&(u.length||(u.length=8*e.algorithm.length)),0==u.name.search("RSA")&&(u.modulusLength||(u.modulusLength=(e.publicKey||e).algorithm.modulusLength),u.publicExponent||(u.publicExponent=(e.publicKey||e).algorithm.publicExponent)),e=e.publicKey&&e.privateKey?{publicKey:new C(e.publicKey,u,l,d.filter(E)),privateKey:new C(e.privateKey,u,l,d.filter(A))}:new C(e,u,l,d)}))}})),["exportKey","wrapKey"].forEach((function(e){var t=n[e];n[e]=function(r,o,i){var c,u=[].slice.call(arguments);switch(e){case"exportKey":u[1]=o._key;break;case"wrapKey":u[1]=o._key,u[2]=i._key}if((s||a&&"SHA-1"===(o.algorithm.hash||{}).name)&&"exportKey"===e&&"jwk"===r&&"HMAC"===o.algorithm.name&&(u[0]="raw"),!s||"exportKey"!==e||"spki"!==r&&"pkcs8"!==r||(u[0]="jwk"),a&&"wrapKey"===e)return n.exportKey(r,o).then((function(e){return"jwk"===r&&(e=p(unescape(encodeURIComponent(JSON.stringify(v(e)))))),n.encrypt(u[3],i,e)}));try{c=t.apply(n,u)}catch(e){return Promise.reject(e)}return a&&(c=new Promise((function(e,t){c.onabort=c.onerror=function(e){t(e)},c.oncomplete=function(t){e(t.target.result)}}))),"exportKey"===e&&"jwk"===r&&(c=c.then((function(e){return(s||a&&"SHA-1"===(o.algorithm.hash||{}).name)&&"HMAC"===o.algorithm.name?{kty:"oct",alg:h(o.algorithm),key_ops:o.usages.slice(),ext:!0,k:d(g(e))}:((e=v(e)).alg||(e.alg=h(o.algorithm)),e.key_ops||(e.key_ops="public"===o.type?o.usages.filter(E):"private"===o.type?o.usages.filter(A):o.usages.slice()),e)}))),!s||"exportKey"!==e||"spki"!==r&&"pkcs8"!==r||(c=c.then((function(e){return e=S(v(e))}))),c}})),["encrypt","decrypt","sign","verify"].forEach((function(e){var t=n[e];n[e]=function(r,o,i,s){if(a&&(!i.byteLength||s&&!s.byteLength))throw new Error("Empty input is not allowed");var c,u=[].slice.call(arguments),l=b(r);if(!a||"sign"!==e&&"verify"!==e||"RSASSA-PKCS1-v1_5"!==r&&"HMAC"!==r||(u[0]={name:r}),a&&o.algorithm.hash&&(u[0].hash=u[0].hash||o.algorithm.hash),a&&"decrypt"===e&&"AES-GCM"===l.name){var d=r.tagLength>>3;u[2]=(i.buffer||i).slice(0,i.byteLength-d),r.tag=(i.buffer||i).slice(i.byteLength-d)}a&&"AES-GCM"===l.name&&void 0===u[0].tagLength&&(u[0].tagLength=128),u[1]=o._key;try{c=t.apply(n,u)}catch(e){return Promise.reject(e)}return a&&(c=new Promise((function(t,n){c.onabort=c.onerror=function(e){n(e)},c.oncomplete=function(n){if(n=n.target.result,"encrypt"===e&&n instanceof AesGcmEncryptResult){var r=n.ciphertext,o=n.tag;(n=new Uint8Array(r.byteLength+o.byteLength)).set(new Uint8Array(r),0),n.set(new Uint8Array(o),r.byteLength),n=n.buffer}t(n)}}))),c}})),a){var l=n.digest;n.digest=function(e,t){if(!t.byteLength)throw new Error("Empty input is not allowed");var r;try{r=l.call(n,e,t)}catch(e){return Promise.reject(e)}return r=new Promise((function(e,t){r.onabort=r.onerror=function(e){t(e)},r.oncomplete=function(t){e(t.target.result)}}))},e.crypto=Object.create(t,{getRandomValues:{value:function(e){return t.getRandomValues(e)}},subtle:{value:n}}),e.CryptoKey=C}s&&(t.subtle=n,e.Crypto=r,e.SubtleCrypto=o,e.CryptoKey=C)}}}function d(e){return btoa(e).replace(/\=+$/,"").replace(/\+/g,"-").replace(/\//g,"_")}function f(e){return e=(e+="===").slice(0,-e.length%4),atob(e.replace(/-/g,"+").replace(/_/g,"/"))}function p(e){for(var t=new Uint8Array(e.length),n=0;n<e.length;n++)t[n]=e.charCodeAt(n);return t}function g(e){return e instanceof ArrayBuffer&&(e=new Uint8Array(e)),String.fromCharCode.apply(String,e)}function b(e){var t={name:(e.name||e||"").toUpperCase().replace("V","v")};switch(t.name){case"SHA-1":case"SHA-256":case"SHA-384":case"SHA-512":break;case"AES-CBC":case"AES-GCM":case"AES-KW":e.length&&(t.length=e.length);break;case"HMAC":e.hash&&(t.hash=b(e.hash)),e.length&&(t.length=e.length);break;case"RSAES-PKCS1-v1_5":e.publicExponent&&(t.publicExponent=new Uint8Array(e.publicExponent)),e.modulusLength&&(t.modulusLength=e.modulusLength);break;case"RSASSA-PKCS1-v1_5":case"RSA-OAEP":e.hash&&(t.hash=b(e.hash)),e.publicExponent&&(t.publicExponent=new Uint8Array(e.publicExponent)),e.modulusLength&&(t.modulusLength=e.modulusLength);break;default:throw new SyntaxError("Bad algorithm name")}return t}function h(e){return{HMAC:{"SHA-1":"HS1","SHA-256":"HS256","SHA-384":"HS384","SHA-512":"HS512"},"RSASSA-PKCS1-v1_5":{"SHA-1":"RS1","SHA-256":"RS256","SHA-384":"RS384","SHA-512":"RS512"},"RSAES-PKCS1-v1_5":{"":"RSA1_5"},"RSA-OAEP":{"SHA-1":"RSA-OAEP","SHA-256":"RSA-OAEP-256"},"AES-KW":{128:"A128KW",192:"A192KW",256:"A256KW"},"AES-GCM":{128:"A128GCM",192:"A192GCM",256:"A256GCM"},"AES-CBC":{128:"A128CBC",192:"A192CBC",256:"A256CBC"}}[e.name][(e.hash||{}).name||e.length||""]}function v(e){(e instanceof ArrayBuffer||e instanceof Uint8Array)&&(e=JSON.parse(decodeURIComponent(escape(g(e)))));var t={kty:e.kty,alg:e.alg,ext:e.ext||e.extractable};switch(t.kty){case"oct":t.k=e.k;case"RSA":["n","e","d","p","q","dp","dq","qi","oth"].forEach((function(n){n in e&&(t[n]=e[n])}));break;default:throw new TypeError("Unsupported key type")}return t}function y(e){var t=v(e);return a&&(t.extractable=t.ext,delete t.ext),p(unescape(encodeURIComponent(JSON.stringify(t)))).buffer}function m(e){var t=w(e),n=!1;t.length>2&&(n=!0,t.shift());var r={ext:!0};if("1.2.840.113549.1.1.1"!==t[0][0])throw new TypeError("Unsupported key type");var o=["n","e","d","p","q","dp","dq","qi"],i=w(t[1]);n&&i.shift();for(var a=0;a<i.length;a++)i[a][0]||(i[a]=i[a].subarray(1)),r[o[a]]=d(g(i[a]));return r.kty="RSA",r}function S(e){var t,n=[["",null]],r=!1;if("RSA"!==e.kty)throw new TypeError("Unsupported key type");for(var o=["n","e","d","p","q","dp","dq","qi"],i=[],a=0;a<o.length&&o[a]in e;a++){var s=i[a]=p(f(e[o[a]]));128&s[0]&&(i[a]=new Uint8Array(s.length+1),i[a].set(s,1))}return i.length>2&&(r=!0,i.unshift(new Uint8Array([0]))),n[0][0]="1.2.840.113549.1.1.1",t=i,n.push(new Uint8Array(O(t)).buffer),r?n.unshift(new Uint8Array([0])):n[1]={tag:3,value:n[1]},new Uint8Array(O(n)).buffer}function w(e,t){if(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),t||(t={pos:0,end:e.length}),t.end-t.pos<2||t.end>e.length)throw new RangeError("Malformed DER");var n,r=e[t.pos++],o=e[t.pos++];if(o>=128){if(o&=127,t.end-t.pos<o)throw new RangeError("Malformed DER");for(var i=0;o--;)i<<=8,i|=e[t.pos++];o=i}if(t.end-t.pos<o)throw new RangeError("Malformed DER");switch(r){case 2:n=e.subarray(t.pos,t.pos+=o);break;case 3:if(e[t.pos++])throw new Error("Unsupported bit string");o--;case 4:n=new Uint8Array(e.subarray(t.pos,t.pos+=o)).buffer;break;case 5:n=null;break;case 6:var a=btoa(g(e.subarray(t.pos,t.pos+=o)));if(!(a in c))throw new Error("Unsupported OBJECT ID "+a);n=c[a];break;case 48:n=[];for(var s=t.pos+o;t.pos<s;)n.push(w(e,t));break;default:throw new Error("Unsupported DER tag 0x"+r.toString(16))}return n}function O(e,t){t||(t=[]);var n=0,r=0,o=t.length+2;if(t.push(0,0),e instanceof Uint8Array){n=2,r=e.length;for(var i=0;i<r;i++)t.push(e[i])}else if(e instanceof ArrayBuffer)for(n=4,r=e.byteLength,e=new Uint8Array(e),i=0;i<r;i++)t.push(e[i]);else if(null===e)n=5,r=0;else if("string"==typeof e&&e in u){var a=p(atob(u[e]));for(n=6,r=a.length,i=0;i<r;i++)t.push(a[i])}else if(e instanceof Array){for(i=0;i<e.length;i++)O(e[i],t);n=48,r=t.length-o}else{if(!("object"==typeof e&&3===e.tag&&e.value instanceof ArrayBuffer))throw new Error("Unsupported DER value "+e);for(n=3,r=(e=new Uint8Array(e.value)).byteLength,t.push(0),i=0;i<r;i++)t.push(e[i]);r++}if(r>=128){var s=r;for(r=4,t.splice(o,0,s>>24&255,s>>16&255,s>>8&255,255&s);r>1&&!(s>>24);)s<<=8,r--;r<4&&t.splice(o,4-r),r|=128}return t.splice(o-2,2,n,r),t}function C(e,t,n,r){Object.defineProperties(this,{_key:{value:e},type:{value:e.type,enumerable:!0},extractable:{value:void 0===n?e.extractable:n,enumerable:!0},algorithm:{value:void 0===t?e.algorithm:t,enumerable:!0},usages:{value:void 0===r?e.usages:r,enumerable:!0}})}function E(e){return"verify"===e||"encrypt"===e||"wrapKey"===e}function A(e){return"sign"===e||"decrypt"===e||"unwrapKey"===e}}(r)}.apply(t,[]),void 0===n||(e.exports=n)},1052:function(e,t,n){"use strict";var r=n(688),o=n(3397),i=TypeError;e.exports=function(e){if(r(e))return e;throw new i(o(e)+" is not a function")}},9175:function(e,t,n){"use strict";var r=n(5309),o=String,i=TypeError;e.exports=function(e){if(r(e))return e;throw new i(o(e)+" is not an object")}},1138:function(e,t,n){"use strict";var r=n(6854),o=n(7352),i=n(8344),a=function(e){return function(t,n,a){var s=r(t),c=i(s);if(0===c)return!e&&-1;var u,l=o(a,c);if(e&&n!=n){for(;c>l;)if((u=s[l++])!=u)return!0}else for(;c>l;l++)if((e||l in s)&&s[l]===n)return e||l||0;return!e&&-1}};e.exports={includes:a(!0),indexOf:a(!1)}},6207:function(e,t,n){"use strict";var r=n(9924),o=n(256),i=TypeError,a=Object.getOwnPropertyDescriptor,s=r&&!function(){if(void 0!==this)return!0;try{Object.defineProperty([],"length",{writable:!1}).length=1}catch(e){return e instanceof TypeError}}();e.exports=s?function(e,t){if(o(e)&&!a(e,"length").writable)throw new i("Cannot set read only .length");return e.length=t}:function(e,t){return e.length=t}},7686:function(e,t,n){"use strict";var r=n(9668);e.exports=r([].slice)},2177:function(e,t,n){"use strict";var r=n(9668),o=r({}.toString),i=r("".slice);e.exports=function(e){return i(o(e),8,-1)}},3891:function(e,t,n){"use strict";var r=n(4678),o=n(990),i=n(7537),a=n(2131);e.exports=function(e,t,n){for(var s=o(t),c=a.f,u=i.f,l=0;l<s.length;l++){var d=s[l];r(e,d)||n&&r(n,d)||c(e,d,u(t,d))}}},2385:function(e,t,n){"use strict";var r=n(9924),o=n(2131),i=n(7781);e.exports=r?function(e,t,n){return o.f(e,t,i(1,n))}:function(e,t,n){return e[t]=n,e}},7781:function(e){"use strict";e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},9393:function(e,t,n){"use strict";var r=n(1135),o=n(2131);e.exports=function(e,t,n){return n.get&&r(n.get,t,{getter:!0}),n.set&&r(n.set,t,{setter:!0}),o.f(e,t,n)}},2470:function(e,t,n){"use strict";var r=n(688),o=n(2131),i=n(1135),a=n(1604);e.exports=function(e,t,n,s){s||(s={});var c=s.enumerable,u=void 0!==s.name?s.name:t;if(r(n)&&i(n,u,s),s.global)c?e[t]=n:a(t,n);else{try{s.unsafe?e[t]&&(c=!0):delete e[t]}catch(e){}c?e[t]=n:o.f(e,t,{value:n,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return e}},1604:function(e,t,n){"use strict";var r=n(3931),o=Object.defineProperty;e.exports=function(e,t){try{o(r,e,{value:t,configurable:!0,writable:!0})}catch(n){r[e]=t}return t}},9924:function(e,t,n){"use strict";var r=n(4694);e.exports=!r((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))},1442:function(e,t,n){"use strict";var r=n(3931),o=n(5309),i=r.document,a=o(i)&&o(i.createElement);e.exports=function(e){return a?i.createElement(e):{}}},3433:function(e){"use strict";var t=TypeError;e.exports=function(e){if(e>9007199254740991)throw t("Maximum allowed index exceeded");return e}},2367:function(e){"use strict";e.exports=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"]},6540:function(e,t,n){"use strict";var r=n(8655);e.exports=/(?:ipad|iphone|ipod).*applewebkit/i.test(r)},1056:function(e,t,n){"use strict";var r=n(2438);e.exports="NODE"===r},8655:function(e,t,n){"use strict";var r=n(3931).navigator,o=r&&r.userAgent;e.exports=o?String(o):""},2273:function(e,t,n){"use strict";var r,o,i=n(3931),a=n(8655),s=i.process,c=i.Deno,u=s&&s.versions||c&&c.version,l=u&&u.v8;l&&(o=(r=l.split("."))[0]>0&&r[0]<4?1:+(r[0]+r[1])),!o&&a&&(!(r=a.match(/Edge\/(\d+)/))||r[1]>=74)&&(r=a.match(/Chrome\/(\d+)/))&&(o=+r[1]),e.exports=o},2438:function(e,t,n){"use strict";var r=n(3931),o=n(8655),i=n(2177),a=function(e){return o.slice(0,e.length)===e};e.exports=a("Bun/")?"BUN":a("Cloudflare-Workers")?"CLOUDFLARE":a("Deno/")?"DENO":a("Node.js/")?"NODE":r.Bun&&"string"==typeof Bun.version?"BUN":r.Deno&&"object"==typeof Deno.version?"DENO":"process"===i(r.process)?"NODE":r.window&&r.document?"BROWSER":"REST"},5532:function(e,t,n){"use strict";var r=n(3931),o=n(7537).f,i=n(2385),a=n(2470),s=n(1604),c=n(3891),u=n(1633);e.exports=function(e,t){var n,l,d,f,p,g=e.target,b=e.global,h=e.stat;if(n=b?r:h?r[g]||s(g,{}):r[g]&&r[g].prototype)for(l in t){if(f=t[l],d=e.dontCallGetSet?(p=o(n,l))&&p.value:n[l],!u(b?l:g+(h?".":"#")+l,e.forced)&&void 0!==d){if(typeof f==typeof d)continue;c(f,d)}(e.sham||d&&d.sham)&&i(f,"sham",!0),a(n,l,f,e)}}},4694:function(e){"use strict";e.exports=function(e){try{return!!e()}catch(e){return!0}}},9659:function(e,t,n){"use strict";var r=n(6398),o=Function.prototype,i=o.apply,a=o.call;e.exports="object"==typeof Reflect&&Reflect.apply||(r?a.bind(i):function(){return a.apply(i,arguments)})},4162:function(e,t,n){"use strict";var r=n(5033),o=n(1052),i=n(6398),a=r(r.bind);e.exports=function(e,t){return o(e),void 0===t?e:i?a(e,t):function(){return e.apply(t,arguments)}}},6398:function(e,t,n){"use strict";var r=n(4694);e.exports=!r((function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))},8724:function(e,t,n){"use strict";var r=n(6398),o=Function.prototype.call;e.exports=r?o.bind(o):function(){return o.apply(o,arguments)}},453:function(e,t,n){"use strict";var r=n(9924),o=n(4678),i=Function.prototype,a=r&&Object.getOwnPropertyDescriptor,s=o(i,"name"),c=s&&"something"===function(){}.name,u=s&&(!r||r&&a(i,"name").configurable);e.exports={EXISTS:s,PROPER:c,CONFIGURABLE:u}},5033:function(e,t,n){"use strict";var r=n(2177),o=n(9668);e.exports=function(e){if("Function"===r(e))return o(e)}},9668:function(e,t,n){"use strict";var r=n(6398),o=Function.prototype,i=o.call,a=r&&o.bind.bind(i,i);e.exports=r?a:function(e){return function(){return i.apply(e,arguments)}}},2160:function(e,t,n){"use strict";var r=n(3931),o=n(688);e.exports=function(e,t){return arguments.length<2?(n=r[e],o(n)?n:void 0):r[e]&&r[e][t];var n}},5383:function(e,t,n){"use strict";var r=n(1052),o=n(5268);e.exports=function(e,t){var n=e[t];return o(n)?void 0:r(n)}},3931:function(e,t,n){"use strict";var r=function(e){return e&&e.Math===Math&&e};e.exports=r("object"==typeof globalThis&&globalThis)||r("object"==typeof window&&window)||r("object"==typeof self&&self)||r("object"==typeof n.g&&n.g)||r("object"==typeof this&&this)||function(){return this}()||Function("return this")()},4678:function(e,t,n){"use strict";var r=n(9668),o=n(298),i=r({}.hasOwnProperty);e.exports=Object.hasOwn||function(e,t){return i(o(e),t)}},7390:function(e){"use strict";e.exports={}},8651:function(e,t,n){"use strict";var r=n(2160);e.exports=r("document","documentElement")},7913:function(e,t,n){"use strict";var r=n(9924),o=n(4694),i=n(1442);e.exports=!r&&!o((function(){return 7!==Object.defineProperty(i("div"),"a",{get:function(){return 7}}).a}))},4347:function(e,t,n){"use strict";var r=n(9668),o=n(4694),i=n(2177),a=Object,s=r("".split);e.exports=o((function(){return!a("z").propertyIsEnumerable(0)}))?function(e){return"String"===i(e)?s(e,""):a(e)}:a},1881:function(e,t,n){"use strict";var r=n(9668),o=n(688),i=n(6762),a=r(Function.toString);o(i.inspectSource)||(i.inspectSource=function(e){return a(e)}),e.exports=i.inspectSource},7804:function(e,t,n){"use strict";var r,o,i,a=n(4724),s=n(3931),c=n(5309),u=n(2385),l=n(4678),d=n(6762),f=n(1962),p=n(7390),g="Object already initialized",b=s.TypeError,h=s.WeakMap;if(a||d.state){var v=d.state||(d.state=new h);v.get=v.get,v.has=v.has,v.set=v.set,r=function(e,t){if(v.has(e))throw new b(g);return t.facade=e,v.set(e,t),t},o=function(e){return v.get(e)||{}},i=function(e){return v.has(e)}}else{var y=f("state");p[y]=!0,r=function(e,t){if(l(e,y))throw new b(g);return t.facade=e,u(e,y,t),t},o=function(e){return l(e,y)?e[y]:{}},i=function(e){return l(e,y)}}e.exports={set:r,get:o,has:i,enforce:function(e){return i(e)?o(e):r(e,{})},getterFor:function(e){return function(t){var n;if(!c(t)||(n=o(t)).type!==e)throw new b("Incompatible receiver, "+e+" required");return n}}}},256:function(e,t,n){"use strict";var r=n(2177);e.exports=Array.isArray||function(e){return"Array"===r(e)}},688:function(e){"use strict";var t="object"==typeof document&&document.all;e.exports=void 0===t&&void 0!==t?function(e){return"function"==typeof e||e===t}:function(e){return"function"==typeof e}},1633:function(e,t,n){"use strict";var r=n(4694),o=n(688),i=/#|\.prototype\./,a=function(e,t){var n=c[s(e)];return n===l||n!==u&&(o(t)?r(t):!!t)},s=a.normalize=function(e){return String(e).replace(i,".").toLowerCase()},c=a.data={},u=a.NATIVE="N",l=a.POLYFILL="P";e.exports=a},5268:function(e){"use strict";e.exports=function(e){return null==e}},5309:function(e,t,n){"use strict";var r=n(688);e.exports=function(e){return"object"==typeof e?null!==e:r(e)}},6555:function(e){"use strict";e.exports=!1},7935:function(e,t,n){"use strict";var r=n(2160),o=n(688),i=n(6148),a=n(4866),s=Object;e.exports=a?function(e){return"symbol"==typeof e}:function(e){var t=r("Symbol");return o(t)&&i(t.prototype,s(e))}},8344:function(e,t,n){"use strict";var r=n(7331);e.exports=function(e){return r(e.length)}},1135:function(e,t,n){"use strict";var r=n(9668),o=n(4694),i=n(688),a=n(4678),s=n(9924),c=n(453).CONFIGURABLE,u=n(1881),l=n(7804),d=l.enforce,f=l.get,p=String,g=Object.defineProperty,b=r("".slice),h=r("".replace),v=r([].join),y=s&&!o((function(){return 8!==g((function(){}),"length",{value:8}).length})),m=String(String).split("String"),S=e.exports=function(e,t,n){"Symbol("===b(p(t),0,7)&&(t="["+h(p(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(t="get "+t),n&&n.setter&&(t="set "+t),(!a(e,"name")||c&&e.name!==t)&&(s?g(e,"name",{value:t,configurable:!0}):e.name=t),y&&n&&a(n,"arity")&&e.length!==n.arity&&g(e,"length",{value:n.arity});try{n&&a(n,"constructor")&&n.constructor?s&&g(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var r=d(e);return a(r,"source")||(r.source=v(m,"string"==typeof t?t:"")),e};Function.prototype.toString=S((function(){return i(this)&&f(this).source||u(this)}),"toString")},1787:function(e){"use strict";var t=Math.ceil,n=Math.floor;e.exports=Math.trunc||function(e){var r=+e;return(r>0?n:t)(r)}},2131:function(e,t,n){"use strict";var r=n(9924),o=n(7913),i=n(2666),a=n(9175),s=n(2358),c=TypeError,u=Object.defineProperty,l=Object.getOwnPropertyDescriptor,d="enumerable",f="configurable",p="writable";t.f=r?i?function(e,t,n){if(a(e),t=s(t),a(n),"function"==typeof e&&"prototype"===t&&"value"in n&&p in n&&!n[p]){var r=l(e,t);r&&r[p]&&(e[t]=n.value,n={configurable:f in n?n[f]:r[f],enumerable:d in n?n[d]:r[d],writable:!1})}return u(e,t,n)}:u:function(e,t,n){if(a(e),t=s(t),a(n),o)try{return u(e,t,n)}catch(e){}if("get"in n||"set"in n)throw new c("Accessors not supported");return"value"in n&&(e[t]=n.value),e}},7537:function(e,t,n){"use strict";var r=n(9924),o=n(8724),i=n(8208),a=n(7781),s=n(6854),c=n(2358),u=n(4678),l=n(7913),d=Object.getOwnPropertyDescriptor;t.f=r?d:function(e,t){if(e=s(e),t=c(t),l)try{return d(e,t)}catch(e){}if(u(e,t))return a(!o(i.f,e,t),e[t])}},6217:function(e,t,n){"use strict";var r=n(1528),o=n(2367).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return r(e,o)}},5168:function(e,t){"use strict";t.f=Object.getOwnPropertySymbols},6148:function(e,t,n){"use strict";var r=n(9668);e.exports=r({}.isPrototypeOf)},1528:function(e,t,n){"use strict";var r=n(9668),o=n(4678),i=n(6854),a=n(1138).indexOf,s=n(7390),c=r([].push);e.exports=function(e,t){var n,r=i(e),u=0,l=[];for(n in r)!o(s,n)&&o(r,n)&&c(l,n);for(;t.length>u;)o(r,n=t[u++])&&(~a(l,n)||c(l,n));return l}},8208:function(e,t){"use strict";var n={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,o=r&&!n.call({1:2},1);t.f=o?function(e){var t=r(this,e);return!!t&&t.enumerable}:n},110:function(e,t,n){"use strict";var r=n(8724),o=n(688),i=n(5309),a=TypeError;e.exports=function(e,t){var n,s;if("string"===t&&o(n=e.toString)&&!i(s=r(n,e)))return s;if(o(n=e.valueOf)&&!i(s=r(n,e)))return s;if("string"!==t&&o(n=e.toString)&&!i(s=r(n,e)))return s;throw new a("Can't convert object to primitive value")}},990:function(e,t,n){"use strict";var r=n(2160),o=n(9668),i=n(6217),a=n(5168),s=n(9175),c=o([].concat);e.exports=r("Reflect","ownKeys")||function(e){var t=i.f(s(e)),n=a.f;return n?c(t,n(e)):t}},7929:function(e,t,n){"use strict";var r=n(9175);e.exports=function(){var e=r(this),t="";return e.hasIndices&&(t+="d"),e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.dotAll&&(t+="s"),e.unicode&&(t+="u"),e.unicodeSets&&(t+="v"),e.sticky&&(t+="y"),t}},1166:function(e,t,n){"use strict";var r=n(5268),o=TypeError;e.exports=function(e){if(r(e))throw new o("Can't call method on "+e);return e}},7994:function(e,t,n){"use strict";var r,o=n(3931),i=n(9659),a=n(688),s=n(2438),c=n(8655),u=n(7686),l=n(4051),d=o.Function,f=/MSIE .\./.test(c)||"BUN"===s&&((r=o.Bun.version.split(".")).length<3||"0"===r[0]&&(r[1]<3||"3"===r[1]&&"0"===r[2]));e.exports=function(e,t){var n=t?2:1;return f?function(r,o){var s=l(arguments.length,1)>n,c=a(r)?r:d(r),f=s?u(arguments,n):[],p=s?function(){i(c,this,f)}:c;return t?e(p,o):e(p)}:e}},1962:function(e,t,n){"use strict";var r=n(2645),o=n(5736),i=r("keys");e.exports=function(e){return i[e]||(i[e]=o(e))}},6762:function(e,t,n){"use strict";var r=n(6555),o=n(3931),i=n(1604),a="__core-js_shared__",s=e.exports=o[a]||i(a,{});(s.versions||(s.versions=[])).push({version:"3.38.1",mode:r?"pure":"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})},2645:function(e,t,n){"use strict";var r=n(6762);e.exports=function(e,t){return r[e]||(r[e]=t||{})}},4112:function(e,t,n){"use strict";var r=n(2273),o=n(4694),i=n(3931).String;e.exports=!!Object.getOwnPropertySymbols&&!o((function(){var e=Symbol("symbol detection");return!i(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&r&&r<41}))},9891:function(e,t,n){"use strict";var r,o,i,a,s=n(3931),c=n(9659),u=n(4162),l=n(688),d=n(4678),f=n(4694),p=n(8651),g=n(7686),b=n(1442),h=n(4051),v=n(6540),y=n(1056),m=s.setImmediate,S=s.clearImmediate,w=s.process,O=s.Dispatch,C=s.Function,E=s.MessageChannel,A=s.String,P=0,_={},I="onreadystatechange";f((function(){r=s.location}));var T=function(e){if(d(_,e)){var t=_[e];delete _[e],t()}},N=function(e){return function(){T(e)}},x=function(e){T(e.data)},R=function(e){s.postMessage(A(e),r.protocol+"//"+r.host)};m&&S||(m=function(e){h(arguments.length,1);var t=l(e)?e:C(e),n=g(arguments,1);return _[++P]=function(){c(t,void 0,n)},o(P),P},S=function(e){delete _[e]},y?o=function(e){w.nextTick(N(e))}:O&&O.now?o=function(e){O.now(N(e))}:E&&!v?(a=(i=new E).port2,i.port1.onmessage=x,o=u(a.postMessage,a)):s.addEventListener&&l(s.postMessage)&&!s.importScripts&&r&&"file:"!==r.protocol&&!f(R)?(o=R,s.addEventListener("message",x,!1)):o=I in b("script")?function(e){p.appendChild(b("script"))[I]=function(){p.removeChild(this),T(e)}}:function(e){setTimeout(N(e),0)}),e.exports={set:m,clear:S}},7352:function(e,t,n){"use strict";var r=n(1680),o=Math.max,i=Math.min;e.exports=function(e,t){var n=r(e);return n<0?o(n+t,0):i(n,t)}},6854:function(e,t,n){"use strict";var r=n(4347),o=n(1166);e.exports=function(e){return r(o(e))}},1680:function(e,t,n){"use strict";var r=n(1787);e.exports=function(e){var t=+e;return t!=t||0===t?0:r(t)}},7331:function(e,t,n){"use strict";var r=n(1680),o=Math.min;e.exports=function(e){var t=r(e);return t>0?o(t,9007199254740991):0}},298:function(e,t,n){"use strict";var r=n(1166),o=Object;e.exports=function(e){return o(r(e))}},1272:function(e,t,n){"use strict";var r=n(8724),o=n(5309),i=n(7935),a=n(5383),s=n(110),c=n(2032),u=TypeError,l=c("toPrimitive");e.exports=function(e,t){if(!o(e)||i(e))return e;var n,c=a(e,l);if(c){if(void 0===t&&(t="default"),n=r(c,e,t),!o(n)||i(n))return n;throw new u("Can't convert object to primitive value")}return void 0===t&&(t="number"),s(e,t)}},2358:function(e,t,n){"use strict";var r=n(1272),o=n(7935);e.exports=function(e){var t=r(e,"string");return o(t)?t:t+""}},3397:function(e){"use strict";var t=String;e.exports=function(e){try{return t(e)}catch(e){return"Object"}}},5736:function(e,t,n){"use strict";var r=n(9668),o=0,i=Math.random(),a=r(1..toString);e.exports=function(e){return"Symbol("+(void 0===e?"":e)+")_"+a(++o+i,36)}},4866:function(e,t,n){"use strict";var r=n(4112);e.exports=r&&!Symbol.sham&&"symbol"==typeof Symbol.iterator},2666:function(e,t,n){"use strict";var r=n(9924),o=n(4694);e.exports=r&&o((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype}))},4051:function(e){"use strict";var t=TypeError;e.exports=function(e,n){if(e<n)throw new t("Not enough arguments");return e}},4724:function(e,t,n){"use strict";var r=n(3931),o=n(688),i=r.WeakMap;e.exports=o(i)&&/native code/.test(String(i))},2032:function(e,t,n){"use strict";var r=n(3931),o=n(2645),i=n(4678),a=n(5736),s=n(4112),c=n(4866),u=r.Symbol,l=o("wks"),d=c?u.for||u:u&&u.withoutSetter||a;e.exports=function(e){return i(l,e)||(l[e]=s&&i(u,e)?u[e]:d("Symbol."+e)),l[e]}},4936:function(e,t,n){"use strict";var r=n(5532),o=n(298),i=n(8344),a=n(6207),s=n(3433);r({target:"Array",proto:!0,arity:1,forced:n(4694)((function(){return 4294967297!==[].push.call({length:4294967296},1)}))||!function(){try{Object.defineProperty([],"length",{writable:!1}).push()}catch(e){return e instanceof TypeError}}()},{push:function(e){var t=o(this),n=i(t),r=arguments.length;s(n+r);for(var c=0;c<r;c++)t[n]=arguments[c],n++;return a(t,n),n}})},4171:function(e,t,n){"use strict";var r=n(3931),o=n(9924),i=n(9393),a=n(7929),s=n(4694),c=r.RegExp,u=c.prototype;o&&s((function(){var e=!0;try{c(".","d")}catch(t){e=!1}var t={},n="",r=e?"dgimsy":"gimsy",o=function(e,r){Object.defineProperty(t,e,{get:function(){return n+=r,!0}})},i={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};for(var a in e&&(i.hasIndices="d"),i)o(a,i[a]);return Object.getOwnPropertyDescriptor(u,"flags").get.call(t)!==r||n!==r}))&&i(u,"flags",{configurable:!0,get:a})},7356:function(e,t,n){"use strict";var r=n(5532),o=n(3931),i=n(9891).clear;r({global:!0,bind:!0,enumerable:!0,forced:o.clearImmediate!==i},{clearImmediate:i})},6539:function(e,t,n){"use strict";n(7356),n(7052)},7052:function(e,t,n){"use strict";var r=n(5532),o=n(3931),i=n(9891).set,a=n(7994),s=o.setImmediate?a(i,!1):i;r({global:!0,bind:!0,enumerable:!0,forced:o.setImmediate!==s},{setImmediate:s})},4147:function(e){"use strict";e.exports=JSON.parse('{"name":"atsenvelopemodule","version":"1.6.0","description":"ats-envelope-module","main":"src/index.js","scripts":{"test":"jest","clean":"rimraf coverage build","build:dev:only":"webpack --mode=development","build:dev":"run-s clean build:dev:only","build:prod:only":"webpack --mode=production","build:prod":"run-s clean build:prod:only","start":"webpack-dev-server --https","lint":"eslint \\"src/\\" --ext .js -c ../../.eslintrc","lint:fix":"eslint \\"src/\\" --ext .js --fix -c ../../.eslintrc","format":"prettier --write \\"**/*.js\\"","format:staged":"pretty-quick --staged"},"author":"","license":"ISC"}')}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={id:r,loaded:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.loaded=!0,i.exports}n.d=function(e,t){for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=function(e){return e.paths=[],e.children||(e.children=[]),e};var r={};!function(){"use strict";n.r(r),n.d(r,{invalidateEnvelope:function(){return xt},isModuleReady:function(){return Rt},outputCurrentConfiguration:function(){return Nt},retrieveEnvelope:function(){return Tt},setAdditionalData:function(){return It},start:function(){return _t}});n(4171),n(6539);var e="undefined"!=typeof globalThis&&globalThis||"undefined"!=typeof self&&self||void 0!==n.g&&n.g||{},t="URLSearchParams"in e,o="Symbol"in e&&"iterator"in Symbol,i="FileReader"in e&&"Blob"in e&&function(){try{return new Blob,!0}catch(e){return!1}}(),a="FormData"in e,s="ArrayBuffer"in e;if(s)var c=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]"],u=ArrayBuffer.isView||function(e){return e&&c.indexOf(Object.prototype.toString.call(e))>-1};function l(e){if("string"!=typeof e&&(e=String(e)),/[^a-z0-9\-#$%&'*+.^_`|~!]/i.test(e)||""===e)throw new TypeError('Invalid character in header field name: "'+e+'"');return e.toLowerCase()}function d(e){return"string"!=typeof e&&(e=String(e)),e}function f(e){var t={next:function(){var t=e.shift();return{done:void 0===t,value:t}}};return o&&(t[Symbol.iterator]=function(){return t}),t}function p(e){this.map={},e instanceof p?e.forEach((function(e,t){this.append(t,e)}),this):Array.isArray(e)?e.forEach((function(e){if(2!=e.length)throw new TypeError("Headers constructor: expected name/value pair to be length 2, found"+e.length);this.append(e[0],e[1])}),this):e&&Object.getOwnPropertyNames(e).forEach((function(t){this.append(t,e[t])}),this)}function g(e){if(!e._noBody)return e.bodyUsed?Promise.reject(new TypeError("Already read")):void(e.bodyUsed=!0)}function b(e){return new Promise((function(t,n){e.onload=function(){t(e.result)},e.onerror=function(){n(e.error)}}))}function h(e){var t=new FileReader,n=b(t);return t.readAsArrayBuffer(e),n}function v(e){if(e.slice)return e.slice(0);var t=new Uint8Array(e.byteLength);return t.set(new Uint8Array(e)),t.buffer}function y(){return this.bodyUsed=!1,this._initBody=function(e){var n;this.bodyUsed=this.bodyUsed,this._bodyInit=e,e?"string"==typeof e?this._bodyText=e:i&&Blob.prototype.isPrototypeOf(e)?this._bodyBlob=e:a&&FormData.prototype.isPrototypeOf(e)?this._bodyFormData=e:t&&URLSearchParams.prototype.isPrototypeOf(e)?this._bodyText=e.toString():s&&i&&((n=e)&&DataView.prototype.isPrototypeOf(n))?(this._bodyArrayBuffer=v(e.buffer),this._bodyInit=new Blob([this._bodyArrayBuffer])):s&&(ArrayBuffer.prototype.isPrototypeOf(e)||u(e))?this._bodyArrayBuffer=v(e):this._bodyText=e=Object.prototype.toString.call(e):(this._noBody=!0,this._bodyText=""),this.headers.get("content-type")||("string"==typeof e?this.headers.set("content-type","text/plain;charset=UTF-8"):this._bodyBlob&&this._bodyBlob.type?this.headers.set("content-type",this._bodyBlob.type):t&&URLSearchParams.prototype.isPrototypeOf(e)&&this.headers.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"))},i&&(this.blob=function(){var e=g(this);if(e)return e;if(this._bodyBlob)return Promise.resolve(this._bodyBlob);if(this._bodyArrayBuffer)return Promise.resolve(new Blob([this._bodyArrayBuffer]));if(this._bodyFormData)throw new Error("could not read FormData body as blob");return Promise.resolve(new Blob([this._bodyText]))}),this.arrayBuffer=function(){if(this._bodyArrayBuffer){var e=g(this);return e||(ArrayBuffer.isView(this._bodyArrayBuffer)?Promise.resolve(this._bodyArrayBuffer.buffer.slice(this._bodyArrayBuffer.byteOffset,this._bodyArrayBuffer.byteOffset+this._bodyArrayBuffer.byteLength)):Promise.resolve(this._bodyArrayBuffer))}if(i)return this.blob().then(h);throw new Error("could not read as ArrayBuffer")},this.text=function(){var e,t,n,r,o,i=g(this);if(i)return i;if(this._bodyBlob)return e=this._bodyBlob,t=new FileReader,n=b(t),r=/charset=([A-Za-z0-9_-]+)/.exec(e.type),o=r?r[1]:"utf-8",t.readAsText(e,o),n;if(this._bodyArrayBuffer)return Promise.resolve(function(e){for(var t=new Uint8Array(e),n=new Array(t.length),r=0;r<t.length;r++)n[r]=String.fromCharCode(t[r]);return n.join("")}(this._bodyArrayBuffer));if(this._bodyFormData)throw new Error("could not read FormData body as text");return Promise.resolve(this._bodyText)},a&&(this.formData=function(){return this.text().then(w)}),this.json=function(){return this.text().then(JSON.parse)},this}p.prototype.append=function(e,t){e=l(e),t=d(t);var n=this.map[e];this.map[e]=n?n+", "+t:t},p.prototype.delete=function(e){delete this.map[l(e)]},p.prototype.get=function(e){return e=l(e),this.has(e)?this.map[e]:null},p.prototype.has=function(e){return this.map.hasOwnProperty(l(e))},p.prototype.set=function(e,t){this.map[l(e)]=d(t)},p.prototype.forEach=function(e,t){for(var n in this.map)this.map.hasOwnProperty(n)&&e.call(t,this.map[n],n,this)},p.prototype.keys=function(){var e=[];return this.forEach((function(t,n){e.push(n)})),f(e)},p.prototype.values=function(){var e=[];return this.forEach((function(t){e.push(t)})),f(e)},p.prototype.entries=function(){var e=[];return this.forEach((function(t,n){e.push([n,t])})),f(e)},o&&(p.prototype[Symbol.iterator]=p.prototype.entries);var m=["CONNECT","DELETE","GET","HEAD","OPTIONS","PATCH","POST","PUT","TRACE"];function S(t,n){if(!(this instanceof S))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');var r,o,i=(n=n||{}).body;if(t instanceof S){if(t.bodyUsed)throw new TypeError("Already read");this.url=t.url,this.credentials=t.credentials,n.headers||(this.headers=new p(t.headers)),this.method=t.method,this.mode=t.mode,this.signal=t.signal,i||null==t._bodyInit||(i=t._bodyInit,t.bodyUsed=!0)}else this.url=String(t);if(this.credentials=n.credentials||this.credentials||"same-origin",!n.headers&&this.headers||(this.headers=new p(n.headers)),this.method=(r=n.method||this.method||"GET",o=r.toUpperCase(),m.indexOf(o)>-1?o:r),this.mode=n.mode||this.mode||null,this.signal=n.signal||this.signal||function(){if("AbortController"in e)return(new AbortController).signal}(),this.referrer=null,("GET"===this.method||"HEAD"===this.method)&&i)throw new TypeError("Body not allowed for GET or HEAD requests");if(this._initBody(i),!("GET"!==this.method&&"HEAD"!==this.method||"no-store"!==n.cache&&"no-cache"!==n.cache)){var a=/([?&])_=[^&]*/;if(a.test(this.url))this.url=this.url.replace(a,"$1_="+(new Date).getTime());else{this.url+=(/\?/.test(this.url)?"&":"?")+"_="+(new Date).getTime()}}}function w(e){var t=new FormData;return e.trim().split("&").forEach((function(e){if(e){var n=e.split("="),r=n.shift().replace(/\+/g," "),o=n.join("=").replace(/\+/g," ");t.append(decodeURIComponent(r),decodeURIComponent(o))}})),t}function O(e,t){if(!(this instanceof O))throw new TypeError('Please use the "new" operator, this DOM object constructor cannot be called as a function.');if(t||(t={}),this.type="default",this.status=void 0===t.status?200:t.status,this.status<200||this.status>599)throw new RangeError("Failed to construct 'Response': The status provided (0) is outside the range [200, 599].");this.ok=this.status>=200&&this.status<300,this.statusText=void 0===t.statusText?"":""+t.statusText,this.headers=new p(t.headers),this.url=t.url||"",this._initBody(e)}S.prototype.clone=function(){return new S(this,{body:this._bodyInit})},y.call(S.prototype),y.call(O.prototype),O.prototype.clone=function(){return new O(this._bodyInit,{status:this.status,statusText:this.statusText,headers:new p(this.headers),url:this.url})},O.error=function(){var e=new O(null,{status:200,statusText:""});return e.ok=!1,e.status=0,e.type="error",e};var C=[301,302,303,307,308];O.redirect=function(e,t){if(-1===C.indexOf(t))throw new RangeError("Invalid status code");return new O(null,{status:t,headers:{location:e}})};var E=e.DOMException;try{new E}catch(e){(E=function(e,t){this.message=e,this.name=t;var n=Error(e);this.stack=n.stack}).prototype=Object.create(Error.prototype),E.prototype.constructor=E}function A(t,n){return new Promise((function(r,o){var a=new S(t,n);if(a.signal&&a.signal.aborted)return o(new E("Aborted","AbortError"));var c=new XMLHttpRequest;function u(){c.abort()}if(c.onload=function(){var e,t,n={statusText:c.statusText,headers:(e=c.getAllResponseHeaders()||"",t=new p,e.replace(/\r?\n[\t ]+/g," ").split("\r").map((function(e){return 0===e.indexOf("\n")?e.substr(1,e.length):e})).forEach((function(e){var n=e.split(":"),r=n.shift().trim();if(r){var o=n.join(":").trim();try{t.append(r,o)}catch(e){console.warn("Response "+e.message)}}})),t)};0===a.url.indexOf("file://")&&(c.status<200||c.status>599)?n.status=200:n.status=c.status,n.url="responseURL"in c?c.responseURL:n.headers.get("X-Request-URL");var o="response"in c?c.response:c.responseText;setTimeout((function(){r(new O(o,n))}),0)},c.onerror=function(){setTimeout((function(){o(new TypeError("Network request failed"))}),0)},c.ontimeout=function(){setTimeout((function(){o(new TypeError("Network request timed out"))}),0)},c.onabort=function(){setTimeout((function(){o(new E("Aborted","AbortError"))}),0)},c.open(a.method,function(t){try{return""===t&&e.location.href?e.location.href:t}catch(e){return t}}(a.url),!0),"include"===a.credentials?c.withCredentials=!0:"omit"===a.credentials&&(c.withCredentials=!1),"responseType"in c&&(i?c.responseType="blob":s&&(c.responseType="arraybuffer")),n&&"object"==typeof n.headers&&!(n.headers instanceof p||e.Headers&&n.headers instanceof e.Headers)){var f=[];Object.getOwnPropertyNames(n.headers).forEach((function(e){f.push(l(e)),c.setRequestHeader(e,d(n.headers[e]))})),a.headers.forEach((function(e,t){-1===f.indexOf(t)&&c.setRequestHeader(t,e)}))}else a.headers.forEach((function(e,t){c.setRequestHeader(t,e)}));a.signal&&(a.signal.addEventListener("abort",u),c.onreadystatechange=function(){4===c.readyState&&a.signal.removeEventListener("abort",u)}),c.send(void 0===a._bodyInit?null:a._bodyInit)}))}A.polyfill=!0,e.fetch||(e.fetch=A,e.Headers=p,e.Request=S,e.Response=O);n(2471);function P(e){return P="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},P(e)}function _(e){var t=function(e,t){if("object"!=P(e)||!e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!=P(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"==P(t)?t:t+""}var I=n(653);const T={placementID:-1,storageType:"cookie",expirationTime:1296e6,expirationRefreshTime:18e5,logging:void 0,email:void 0,emailHashes:void 0,urlHashType:void 0,phoneNumber:void 0,phoneNumberHashes:void 0,customerID:void 0,accountID:void 0,customerIDRegex:void 0,catchIdentifier:!0,ccpaConsentString:void 0,gdprConsentString:void 0,gppConsentString:void 0,startWithExternalId:!1,rootDomain:void 0,testMode:!1,useESP:!1,usePAIR:!1,useDirect:!1};var N=new class{constructor(){var e,t,n;e=this,n=e=>{if(e){const t=function(e,t){const n={...e};for(const e in t)"placementID"===e?Number.isInteger(+t.placementID)?n.placementID=+t.placementID:I.log.error("placementID is not a number!"):"expirationTime"===e?Number.isInteger(+t.expirationTime)?n.expirationTime=+t.expirationTime:I.log.error("expirationTime is not a number!"):n[e]=t[e];return n}(this,e);Object.assign(this,t)}},(t=_(t="update"))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,this.update(T)}};function x(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:31536e3,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"/",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0,i=new Date;i.setTime(i.getTime()+1e3*n);let a=";expires="+i.toUTCString(),s=";max-age="+n,c=";path="+r,u=o?";domain="+o:"",l=e+"="+encodeURIComponent(t);document.cookie=l+s+a+u+c}function R(e){const t=e+"=",n=document.cookie.split(";");for(let e=0;e<n.length;e++){const r=n[e].trim();if(0===r.indexOf(t))return decodeURIComponent(r.substring(t.length,r.length))}return""}function D(e,t){const n=new Date;n.setTime(n.getTime()-864e5);const r=`expires=${n.toUTCString()}`;document.cookie=t?`${e}=;domain=${t};path=/;${r}`:`${e}=;path=/;${r}`}function L(e){null!==localStorage.getItem(e)&&localStorage.removeItem(e)}const j=Object.freeze({LIVERAMP:"LIVERAMP",FACEBOOK:"FACEBOOK",PAIR_ID:"PAIR_ID",ATS_DIRECT:"ATS_DIRECT",GOOGLE_SSP:"GOOGLE_SSP"}),k=Object.freeze({LIVERAMP:"_lr_env",FACEBOOK:"_lr_fb_env",PAIR_ID:"_lr_pairId",ATS_DIRECT:"_lr_atsDirect",GOOGLE_SSP:"_lr_google_env"}),U=Object.freeze({LIVERAMP:19,FACEBOOK:24,PAIR_ID:25,ATS_DIRECT:26,GOOGLE_SSP:27}),G=Object.freeze({PINTEREST:"_lr_pint_events",FACEBOOK:"_lr_fb_events",SNAPCHAT:"_lr_snap_events",TIKTOK:"_lr_tiktok_events"}),M=(Object.freeze({PINTEREST:"pinterest",SNAPCHAT:"snapchat",TIKTOK:"tikTok"}),Object.freeze({AUTOMATIC:"automatically",API:"api"}),"envelope"),B="conversion",H={method:"GET",mode:"cors"};async function F(e){try{const t=await fetch(e,H);if(t&&200===t.status&&null!==t.body)return t.json()}catch(e){console.error("There has been a problem with your fetch operation: ",e)}}function K(e){for(const t in k)L(k[t]),D(k[t],e);for(const e in G)L(G[e])}function $(e){for(let t in e)if(40===e[t].length)return!0;return!1}let V;function J(e){V=e}let W=!1;function q(e){W=e}let z=!1;const X=()=>{I.log.debug("Consent is given, module will start!")},Z=e=>{e===M?I.log.debug("Consent is rejected. Envelope will be removed and module will shutdown!"):I.log.debug("Consent is rejected. Module will shutdown!")},Y=()=>{I.log.debug("Consent was given. Module is already running!")};function Q(e){return function(e){for(var t,n="0123456789ABCDEF",r="",o=0;o<e.length;o++)t=e.charCodeAt(o),r+=n.charAt(t>>>4&15)+n.charAt(15&t);return r}(function(e){for(var t="",n=0;n<32*e.length;n+=8)t+=String.fromCharCode(e[n>>5]>>>n%32&255);return t}(function(e,t){e[t>>5]|=128<<t%32,e[14+(t+64>>>9<<4)]=t;for(var n=1732584193,r=-271733879,o=-1732584194,i=271733878,a=0;a<e.length;a+=16){const t=n,s=r,c=o,u=i;r=oe(r=oe(r=oe(r=oe(r=re(r=re(r=re(r=re(r=ne(r=ne(r=ne(r=ne(r=te(r=te(r=te(r=te(r,o=te(o,i=te(i,n=te(n,r,o,i,e[a],7,-680876936),r,o,e[a+1],12,-389564586),n,r,e[a+2],17,606105819),i,n,e[a+3],22,-1044525330),o=te(o,i=te(i,n=te(n,r,o,i,e[a+4],7,-176418897),r,o,e[a+5],12,1200080426),n,r,e[a+6],17,-1473231341),i,n,e[a+7],22,-45705983),o=te(o,i=te(i,n=te(n,r,o,i,e[a+8],7,1770035416),r,o,e[a+9],12,-1958414417),n,r,e[a+10],17,-42063),i,n,e[a+11],22,-1990404162),o=te(o,i=te(i,n=te(n,r,o,i,e[a+12],7,1804603682),r,o,e[a+13],12,-40341101),n,r,e[a+14],17,-1502002290),i,n,e[a+15],22,1236535329),o=ne(o,i=ne(i,n=ne(n,r,o,i,e[a+1],5,-165796510),r,o,e[a+6],9,-1069501632),n,r,e[a+11],14,643717713),i,n,e[a],20,-373897302),o=ne(o,i=ne(i,n=ne(n,r,o,i,e[a+5],5,-701558691),r,o,e[a+10],9,38016083),n,r,e[a+15],14,-660478335),i,n,e[a+4],20,-405537848),o=ne(o,i=ne(i,n=ne(n,r,o,i,e[a+9],5,568446438),r,o,e[a+14],9,-1019803690),n,r,e[a+3],14,-187363961),i,n,e[a+8],20,1163531501),o=ne(o,i=ne(i,n=ne(n,r,o,i,e[a+13],5,-1444681467),r,o,e[a+2],9,-51403784),n,r,e[a+7],14,1735328473),i,n,e[a+12],20,-1926607734),o=re(o,i=re(i,n=re(n,r,o,i,e[a+5],4,-378558),r,o,e[a+8],11,-2022574463),n,r,e[a+11],16,1839030562),i,n,e[a+14],23,-35309556),o=re(o,i=re(i,n=re(n,r,o,i,e[a+1],4,-1530992060),r,o,e[a+4],11,1272893353),n,r,e[a+7],16,-155497632),i,n,e[a+10],23,-1094730640),o=re(o,i=re(i,n=re(n,r,o,i,e[a+13],4,681279174),r,o,e[a],11,-358537222),n,r,e[a+3],16,-722521979),i,n,e[a+6],23,76029189),o=re(o,i=re(i,n=re(n,r,o,i,e[a+9],4,-640364487),r,o,e[a+12],11,-421815835),n,r,e[a+15],16,530742520),i,n,e[a+2],23,-995338651),o=oe(o,i=oe(i,n=oe(n,r,o,i,e[a],6,-198630844),r,o,e[a+7],10,1126891415),n,r,e[a+14],15,-1416354905),i,n,e[a+5],21,-57434055),o=oe(o,i=oe(i,n=oe(n,r,o,i,e[a+12],6,1700485571),r,o,e[a+3],10,-1894986606),n,r,e[a+10],15,-1051523),i,n,e[a+1],21,-2054922799),o=oe(o,i=oe(i,n=oe(n,r,o,i,e[a+8],6,1873313359),r,o,e[a+15],10,-30611744),n,r,e[a+6],15,-1560198380),i,n,e[a+13],21,1309151649),o=oe(o,i=oe(i,n=oe(n,r,o,i,e[a+4],6,-145523070),r,o,e[a+11],10,-1120210379),n,r,e[a+2],15,718787259),i,n,e[a+9],21,-343485551),n=ie(n,t),r=ie(r,s),o=ie(o,c),i=ie(i,u)}return Array(n,r,o,i)}(function(e){for(var t=Array(e.length>>2),n=0;n<t.length;n++)t[n]=0;for(n=0;n<8*e.length;n+=8)t[n>>5]|=(255&e.charCodeAt(n/8))<<n%32;return t}(e),8*e.length))).toLowerCase()}function ee(e,t,n,r,o,i){return ie(function(e,t){return e<<t|e>>>32-t}(ie(ie(t,e),ie(r,i)),o),n)}function te(e,t,n,r,o,i,a){return ee(t&n|~t&r,e,t,o,i,a)}function ne(e,t,n,r,o,i,a){return ee(t&r|n&~r,e,t,o,i,a)}function re(e,t,n,r,o,i,a){return ee(t^n^r,e,t,o,i,a)}function oe(e,t,n,r,o,i,a){return ee(n^(t|~r),e,t,o,i,a)}function ie(e,t){const n=(65535&e)+(65535&t);return(e>>16)+(t>>16)+(n>>16)<<16|65535&n}const ae=/((([^<>()\[\].,;:\s@"]+(\.[^<>()\[\].,;:\s@"]+)*)|(".+"))@(([^<>()[\].,;:\s@"]+\.)+[^<>()[\].,;:\s@"]{2,}))/i;function se(e){if(window.TextEncoder)return new TextEncoder("utf-8").encode(e);const t=unescape(encodeURIComponent(e)),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return n}async function ce(e){return Q(e)}async function ue(e){const t=se(e);try{return fe(await crypto.subtle.digest("SHA-256",t))}catch(e){return console.error("SHA-256 encryption failed: "+e),""}}async function le(e){const t=se(e);try{return fe(await crypto.subtle.digest("SHA-1",t))}catch(e){return console.error("SHA-1 encryption failed: "+e),""}}function de(e){return ae.test(e)}function fe(e){const t=[],n=new DataView(e);for(let e=0;e<n.byteLength;e+=4){const r="00000000",o=(r+n.getUint32(e).toString(16)).slice(-r.length);t.push(o)}return t.join("")}const pe=/(^[a-f0-9]{32}$)|(^[a-f0-9]{40}$)|(^[a-f0-9]{64}$)/,ge="sha256Email",be="sha1Email",he="md5Email",ve="phoneNumber",ye=["cfcd208495d565ef66e7dff9f98764da","2f43b42fd833d1e77420a8dae7419000","7215ee9c7d9dc229d2921a40e899ec5f","3d407cbd539c1f1f4b436169c9f5e1a3","07e541ee7ffe448eae004c08a59dd91b","852438d026c018c4307b916406f98c62","4da8b7eb2c3f2007cf8238334401ef51","334c4a4c42fdb79d7ebc3e73b517e6f8","6adf97f83acf6453d4a6a4b1070f3754","bbb93ef26e3c101ff11cdd21cab08a94","37a6259cc0c1dae299a7866489dff0bd","8589033c2cd15744c3ce30d1bddeb087","93942e96f5acd83e2e047ad8fe03114d","55502f40dc8b7c769880b10874abc9d0","1aedb8d9dc4751e229a335e371db8058","8d89c3087cc6cb98793ab7c0f5658c56","97dfebf4098c0f5c16bca61e2b76c373","476869598e748d958e819c180af31982","ef8ca1c0ff7d2e34dc0953d4222655b8","eca74378f20815070e1bec3ee81bfabc","88e478531ab3bc303f1b5da82c2e9bbb","8c3fe1ad25e6d5f47512ea7365419966","9ad574806427070b94735f216e9abdc1","ad16f2226a41423949f2c6d400bbc5d7","3d751a0c27cbe4cd47f1fe09352c24fb","799dd2047247877f2da2158fd61e25b6","348bec5913e8550419c565d84ef92e52","5beba8117bb43bde25beb24b58412183","348bec5913e8550419c565d84ef92e52","5beba8117bb43bde25beb24b58412183","a18bf786efb76a3d56ee69a3b343952a","86b5735c643e34006dfc421030e5d211","5e543256c480ac577d30f76f9120eb74","ec0fc0100c4fc1ce4eea230c3dc10360","b58996c504c5638798eb6b511e6f49af","946003f97ccc52d5d3b54ac0ec31bbfc","b6589fc6ab0dc82cf12099d1c2d40ab994e8410c","6eae3a5b062c6d0d79f070c26e6d62486b40cb46","b858cb282617fb0956d960215c8e84d1ccf909c6","4cefae8c39427da6c5d65b35f34211656e091b97","27386f29c24918f7635a238a804215ae154a9d0b","b5366a2d2ac98dae978423083f8b09e5cddc705d","c916da70cd4a32512ca71d70e5cc765d00357df4","71f8e7976e4cbc4561c9d62fb283e7f788202acb","6eef6648406c333a4035cd5e60d0bf2ecf2606d7","109085beaaa80ac89858b283a64f7c75d7e5bb12","2be88ca4242c76e8253ac62474851065032d6833","7e05143b040cbe5768da6abe82229f08c0f977d5","f7a36129f691baa1201d963b8537eb69caa28863","567159d622ffbb50b11b0efd307be358624a26ee","ea97b75619f5cb2b9df9d184c4541aafe3b87484","22d002c0a1d1f181dcbd75573e18de5af0eab43d","52e17b67fd82b0545bb4fbdc5748ed23104133c7","624ddbfecf6c492001bd3660870958cb84120ff9","4ad6658bbc6700c113fe12acaa77ebf4d00f7cf5","1245282959d9e21d2c2033fff63b765b6805b483","49eb577150e21ee3180224a011edfc310acc3779","ca7fe1db6188a235dabc9c1457d82e636b11a543","b9f87d81ccb9795c4a8b82055610334e3881ca80","dcf608cc7daaf155d54aad5b16f10f102bc2cab7","0a75e7e26ee11630e8090f43a7a36ab283e7bd79","2ebc7ba1d181ae807a36734904d5506dae4599d1","7ee99aec60d570c612b86f417c579ce6c0d28799","849f789f32f74696f4e5a2e3ca999db468d11cc4","79cc65d586f548f71229672ca3455a754c13e44d","e62f22de243201afe4303ebd42984f10f77eb983","d5d4cd07616a542891b7ec2d0257b3a24b69856e","0646f4afd90c8fdb87bbcb57b63ee1911f5a9a46","63a710569261a24b3766275b7000ce8d7b32e2f7","0ed2d7b5cdb77627bc46c6fac5026ec27b694d42","5feceb66ffc86f38d952786c6d696c79c2dbc239dd4e91b46729d73a27fb57e9","ab5df625bc76dbd4e163bed2dd888df828f90159bb93556525c31821b6541d46","36a9e7f1c95b82ffb99743e0c5c4ce95d83c9a430aac59f84ef3cbfab6145068","c6f62b06b3cd95ac3cc5b6aba2b157283273febc7d62fd3785d9f14737128166","e40ff7f3a562b8757869d839b578d56390dd68e1cc28bf9b6d5362bc717e1c90","5da3a4c7f117944275b4c8629c4916403625d5a4a6573a01ecb03f0e9d2edbe6","e118b5c29cb4b975251601a6cc3209a4ea3eb0b429b205b679a8645da47da654","140bedbf9c3f6d56a9846d2ba7088798683f4da0c248231336e6a05679e4fdfe","dc937b59892604f5a86ac96936cd7ff09e25f18ae6b758e8014a24c7fa039e91","fa1d2db62d4d952e2031452e1bc1ddcad0b192c2e29a706f11ce426ae5acddea","74234e98afe7498fb5daf1f36ac2d78acc339464f950703b8c019892f982b90b","f320794388bf29dabc846c54fe7ff28f78fc3bc3c13748783335a9bf33440d55","73062d872926c2a556f17b36f50e328ddf9bff9d403939bd14b6c3b7f5a33fc2","973dfe463ec85785f5f95af5ba3906eedb2d931c24e69824a89ea65dba4e813b","87924606b4131a8aceeeae8868531fbb9712aaa07a5d3a756b26ce0f5d6ca674","f080ca14e0e21e303b60a69e20be89fb3a682f8721b922823fcffcb108bb1363","f0e2a21bcf499cbc713c47d8f034d66e90a99f9ffcfe96466c9971dfdc5c9816","f303cf025f54905caca8788d2c7070d47fb49eb6515b7d886d3305a4f10396f9","1f9e575ad4234c30a81d30c70affd4bba7b0d57d8e8607ad255496863d72c8bb","587d4c12fef06af41f2fdfa19a3e68443bf8a7923b47cb75022481f8d77552ad","e85bbf307aedebc91b078f5bc1ebd50d72e7494ffd85f32184688bfd032c3271","66067ef9e155e39767ab7da916d84ee8ff70efe1459b4c0808fc776d52d85848","944653ca1e1968fc3f9a0137faad3df546ac6065e1bd95e896ad69200dbe449c","fe83e987766f25a7132fb9f45bc9620374568405a6a2b9d275d88f5042a8dc9b","920c46ed756bcc1ea8f70cc90a59584efa6b2b6b5d394ca323dafd5ffce25a4c","65c85ffcc43d86169bc4cc7c49a71fa505ddf863ba4a2af6cfaf1adbc0fd5d47","bb8db4111f03c65c52df77d8d6963b7aee7b28bd8fd4eae61ead6e824770490e","109fe15ff056d9cf6b5f4fa2be71da6db3308190149ae6d5eee2f5905a88fde9","dae9c7c55697ba170d6b494c458649bd469af525520280d0dcfc98d74d13b17e","b1bc5cb7473bd88caf80e991de2067f4b00dd25b0923f6c2eb57d18d79391399","eb045d78d273107348b0300c01d29b7552d622abbc6faf81b3ec55359aa9950c","f02dfb7da82a40b055700e27ce61e0b3ad10985137f721e7a2c62b3dc3fbaf31","b4c9a289323b21a01c3e940f150eb9b8c542587f1abfd8f0e1cc1ffc5e475514","4e523a5ae5b4636c75901b79fafbd3912e41dc7987414e688b09d4b436ff22b3"];function me(e){return pe.test(e)&&-1===ye.indexOf(e)}function Se(e,t){32===t.length?e[he]=t:40===t.length?N.urlHashType===ve?e[ve]=t:e[be]=t:64===t.length&&(e[ge]=t)}async function we(e){const t=new CustomEvent(e);window.dispatchEvent(t)}function Oe(){return N.startWithExternalId&&!N.catchIdentifier}const Ce=/(^((\+1)?)([\s.-]?)?[(]?[2-9][0-9][0-9][)]?[(\s)?.-]?[2-9][0-9][0-9][\s.-]?\d{4}$)/,Ee=/(\+1)|[.]|[(]|[)]|[-]|[ ]/gi;async function Ae(e){if(Array.isArray(e)){if(!$(e))return I.log.debug("Phone number hash is invalid")}else{if("string"!=typeof e&&(e+=""),!function(e){return Ce.test(e.trim(e))}(e))return I.log.debug("Phone number is invalid");I.log.debug("We detected phone number: "+e),e=function(e){return e.replace(Ee,"")}(e),e=await le(e)}if(await qe(!0))return;const t={phoneNumber:Array.isArray(e)?e[0]:e};I.log.debug("New Envelope will be acquired."),je(t,N.placementID)}const Pe=e=>{window.googletag&&window.googletag.cmd&&e?window.googletag.cmd.push((()=>{window.googletag.pubads().setTargeting("atsd",e)})):I.log.warn("Can't set page ad targeting. Missing audienceIds or GPT library.")};let _e=!1;const Ie=async()=>{let e=Ne();return e.country||(e=await xe.getGeoLocation(),e.region&&x("_lr_geo_location_state",e.region,86400),e.country||(e.country="US"),x("_lr_geo_location",e.country,86400)),_e="US"===e.country,e},Te=()=>_e,Ne=()=>({country:""+R("_lr_geo_location"),region:""+R("_lr_geo_location_state")}),xe={getGeoLocation:async()=>{const e=await F("https://geo.privacymanager.io/");if(e)return e;I.log.error("Geo location is undefined or empty")}};const Re="https://api.rlcdn.com/api/identity/v2/envelope";let De=!1,Le=!1;async function je(e,t){const n=N.customerID&&N.accountID?"&it=15&iv="+N.accountID+":"+N.customerID:(e.sha256Email?"&it=4&iv="+e.sha256Email:"")+(e.sha1Email?"&it=4&iv="+e.sha1Email:"")+(e.md5Email?"&it=4&iv="+e.md5Email:"")+(e.phoneNumber?"&it=11&iv="+e.phoneNumber:""),r=Xe();let o=Re+"?pid="+t+n+r;Le||(o+="&src=9"),await ke(o)}async function ke(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(N.testMode){const e="MOCKED_ENVELOPE";I.log.debug("New mocked envelope: ",e);Me(Ge(e,n[j.LIVERAMP]))}else try{const r=await F(e);r&&r.envelopes&&r.envelopes.length>0?r.envelopes.filter((e=>e)).forEach((e=>{if(e.type!==U.LIVERAMP||void 0!==t&&t!==j.LIVERAMP)if(e.type!==U.FACEBOOK||void 0!==t&&t!==j.FACEBOOK)if(e.type!==U.PAIR_ID||void 0!==t&&t!==j.PAIR_ID||!N.usePAIR)if(e.type===U.ATS_DIRECT&&(void 0===t||t===j.ATS_DIRECT&&N.useDirect)){let t=JSON.parse(atob(e.value));Pe(t),Ue(t,j.ATS_DIRECT,n[j.ATS_DIRECT])}else e.type===U.GOOGLE_SSP&&(void 0===t||t===j.GOOGLE_SSP&&N.useESP)&&Te()&&(Ue(e.value,j.GOOGLE_SSP,n[j.GOOGLE_SSP]),We(j.GOOGLE_SSP));else{Ue(JSON.parse(atob(e.value)),j.PAIR_ID,n[j.PAIR_ID])}else e.err?I.log.error("Facebook envelope error: ",e.err):e.value&&""!==e.value?Ue(e.value,j.FACEBOOK,n[j.FACEBOOK]):I.log.error("Envelope retrieved from API is undefined or empty");else e.err?I.log.error("Liveramp envelope error: ",e.err):e.value&&""!==e.value?(Ue(e.value,j.LIVERAMP,n[j.LIVERAMP]),!r.envelopes.find((e=>e.type===U.GOOGLE_SSP))&&N.useESP&&We(j.LIVERAMP)):I.log.error("Envelope retrieved from API is undefined or empty")})):I.log.error("Envelope retrieved from API is undefined or empty")}catch(e){I.log.error("Error from envelope API: ",e)}}function Ue(e,t,n){const r=Ge(e,n);I.log.debug(`Encoded ${t} envelope: `,JSON.stringify(r)),Me(r,t)}function Ge(e,t){const n={timestamp:+new Date,version:"1.6.0",envelope:e,creationTimestamp:t||+new Date};return btoa(JSON.stringify(n))}function Me(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.LIVERAMP;var n,r;"cookie"===N.storageType?De?x(k[t],e,31536e3,"/",N.rootDomain):x(k[t],e):(n=k[t],(r=e)&&localStorage.setItem(n,r)),t===j.LIVERAMP?we("lrEnvelopePresent"):t===j.FACEBOOK?we("fbEnvelopePresent"):t===j.ATS_DIRECT?we("atsDirectEnvelopePresent"):t===j.GOOGLE_SSP?we("googleSspEnvelopePresent"):we("pairIdEnvelopePresent")}async function Be(){let e,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.LIVERAMP;const n=Ke(t);if(void 0===n||""===n)I.log.debug("There is no envelope in storage.");else try{JSON.parse(atob(n)).timestamp+2592e6<+new Date?$e(t):e=atob(n)}catch(e){I.log.error("Envelope is invalid: "+e),$e(t)}return e}async function He(e){let t,n,r;if(e?t=await async function(e){if(de(e=function(e){const t=(e=e.toLowerCase().trim()).split("@");let n=t[0];const r=t[1];let o=n.indexOf("+");return-1===o&&(o=n.indexOf(" ")),-1===o&&(o=n.indexOf("%2b")),-1!==o&&(n=n.slice(0,o)),"gmail.com"===r&&(n=n.replace(/\./g,"")),n+"@"+r}(e))){const t={sha256Email:await ue(e),sha1Email:await le(e),md5Email:await ce(e)};return""===t.sha1Email&&delete t.sha1Email,""===t.sha256Email&&delete t.sha256Email,t}}(e):N.emailHashes&&(n=function(){const e={};if(!N.email&&N.emailHashes)return N.emailHashes[0]&&(me(N.emailHashes[0])?Se(e,N.emailHashes[0]):I.log.debug(N.emailHashes[0]+" is invalid hash")),N.emailHashes[1]&&(me(N.emailHashes[1])?Se(e,N.emailHashes[1]):I.log.debug(N.emailHashes[1]+" is invalid hash")),N.emailHashes[2]&&(me(N.emailHashes[2])?Se(e,N.emailHashes[2]):I.log.debug(N.emailHashes[2]+" is invalid hash")),JSON.stringify(e)!==JSON.stringify({})?(I.log.debug("At least one hash is valid."),e):void I.log.debug("All passed hashes are invalid.")}(),n&&(t=n)),!t&&!N.customerID)return void I.log.debug("Encrypted Emails are missing!");if(-1===N.placementID&&!N.testMode)return void I.log.debug("PlacementID is set to -1, ATS API wont be called!");r=N.customerID?await ue(N.customerID):t.sha256Email;await qe(!0)||je(t,N.placementID)}async function Fe(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.LIVERAMP,t=arguments.length>1?arguments[1]:void 0,n=Ke(e);const r=+new Date;if(Le=!1,void 0===n||""===n)return I.log.debug(e+" envelope not found in storage! New envelope will be acquired."),Le=!0,"new_envelope";try{return n=JSON.parse(atob(n)),N.testMode||"MOCKED_ENVELOPE"!==n.envelope?n.timestamp+N.expirationTime<r||r-n.creationTimestamp>864e5&&t?"new_envelope":n.timestamp+2592e6<r||n.timestamp+N.expirationRefreshTime<r?"expired":"not_expired":(I.log.debug("Deleting mocked envelope"),$e(e),"new_envelope")}catch(t){return I.log.error(e+" envelope is invalid: "+t),$e(e),"new_envelope"}}function Ke(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:j.LIVERAMP;if("cookie"===N.storageType){const t=R(k[e]);return navigator.vendor.includes("Apple")&&(De?x(k[e],t,31536e3,"/",N.rootDomain):x(k[e],t)),t}return function(e){if(null!==localStorage.getItem(e))return localStorage.getItem(e)}(k[e])}async function $e(e){if(e){-1!==Object.keys(k).indexOf(e)&&(e=k[e]),D(e,De?N.rootDomain:void 0),L(e)}else K(De?N.rootDomain:void 0)}async function Ve(){await qe(mt);if(!mt&&Oe())return I.log.debug("Envelope module is in direct mode. Stoping the flow until identifier is passed."),void Ze();var e;N.customerID&&N.accountID?(I.log.debug("Customer id: ",N.customerID),I.log.debug("Account id: ",N.accountID),e=N.customerID,N.customerIDRegex&&new RegExp(N.customerIDRegex).test(e)?He():I.log.error("CustomerID is not valid!")):N.email?(I.log.debug("Config email: ",N.email),de(N.email)?He(N.email):I.log.error("Config email is not valid!")):N.phoneNumber?(I.log.debug("Config phone number: ",N.phoneNumber),Ae(N.phoneNumber)):N.phoneNumberHashes?(I.log.debug("Config phone number hashes: "+N.phoneNumberHashes),Ae(N.phoneNumberHashes)):N.emailHashes?(I.log.debug("Config email hashes: "+N.emailHashes),He()):N.catchIdentifier&&(I.log.info("Catching identifier configured."),window.addEventListener("detected-identifier",Je,!1)),Ze()}function Je(e){if(!1!==V)if(I.log.debug("Identifier caught from detection: - ",e.detail.identifier),"email"===e.detail.type)He(e.detail.identifier);else if("phoneNumber"===e.detail.type)Ae(e.detail.identifier);else if("customerID"===e.detail.type)N.accountID=e.detail.identifier.accountId,N.customerID=e.detail.identifier.customerId,He();else if("envelope"===e.detail.type){let t;try{t=JSON.parse(e.detail.identifier).envelope}catch(n){t=e.detail.identifier}Me(Ge(t))}else"SHA256Hash"!==e.detail.type&&"SHA1Hash"!==e.detail.type&&"MD5Hash"!==e.detail.type||(N.emailHashes=[e.detail.identifier],He());else I.log.debug("No consent has been given, library will shutdown!")}async function We(e){let t;e?t=await Be(e):(t=await Be(j.GOOGLE_SSP),t||(t=await Be(j.LIVERAMP))),t&&(t=JSON.parse(t),t.envelope&&(I.log.debug("Inserting secure signal provides script."),window.googletag=window.googletag||{cmd:[]},window.googletag.secureSignalProviders=window.googletag.secureSignalProviders||[],window.googletag.secureSignalProviders.push({id:"liveramp.com",collectorFunction:()=>Promise.resolve(t.envelope)})))}async function qe(e){const t=[Fe(j.LIVERAMP,e),window.fbcapimodule?Fe(j.FACEBOOK,e):null],n=await Promise.all(t);let r=!1;if(!n.includes("new_envelope")){r=!0;let e="";const t={};if(n[0]&&"expired"===n[0]){I.log.debug("LR envelope has expired!"),[e,t[j.LIVERAMP]]=ze(e,j.LIVERAMP);const n=Ke(j.PAIR_ID);if(n&&""!==n){const e=JSON.parse(atob(n))?.creationTimestamp;t[j.PAIR_ID]=e}const r=Ke(j.ATS_DIRECT);if(r&&""!==r){const e=JSON.parse(atob(r))?.creationTimestamp;t[j.ATS_DIRECT]=e}if(Te()){const e=Ke(j.GOOGLE_SSP);if(e){const n=JSON.parse(atob(e))?.creationTimestamp;t[j.GOOGLE_SSP]=n}}}if(n[0]&&"not_expired"===n[0]){I.log.debug("LR envelope did not expire!"),we("lrEnvelopePresent");const e=Ke(j.PAIR_ID);if(e&&""!==e){const t=JSON.parse(atob(e)).envelope;t&&t.length>0&&we("pairIdEnvelopePresent")}const t=Ke(j.ATS_DIRECT);if(t&&""!==t){const e=JSON.parse(atob(t)).envelope;e&&e.length>0&&(Pe(e),we("atsDirectEnvelopePresent"))}if(Te()){const e=Ke(j.GOOGLE_SSP);if(e){const t=JSON.parse(atob(e)).envelope;t&&t.length>0&&we("googleSspEnvelopePresent")}}}n[1]&&"expired"===n[1]&&(I.log.debug("FB envelope has expired!"),t[j.FACEBOOK]=null,[e,t[j.FACEBOOK]]=ze(e,j.FACEBOOK)),n[1]&&"not_expired"===n[1]&&(I.log.debug("FB envelope did not expire!"),we("fbEnvelopePresent")),e&&(e+=Xe(),await ke(e,void 0,t))}return r}function ze(e,t){let n=Ke(t);return n=JSON.parse(atob(n)),0===e.length?e=Re+"/refresh?pid="+N.placementID+"&it="+U[t]+"&iv="+n.envelope:e+="&it="+U[t]+"&iv="+n.envelope,[e,n.creationTimestamp]}function Xe(){return(N.ccpaConsentString?"&ct=3&cv="+encodeURIComponent(N.ccpaConsentString):"")+(N.gdprConsentString?"&ct=4&cv="+N.gdprConsentString:"")+(N.gppConsentString?"&gpp="+N.gppConsentString+"&gpp_sid="+N.gppSectionId:"")}function Ze(){let e=0;if(!wt&&(wt=!0,I.log.info("Envelope-module is configured."),we("envelopeModuleReady"),window.envelopeModuleReady=!0,N.startWithExternalId&&N.catchIdentifier||Oe())){const t=setInterval((()=>{++e,mt||3===e?clearInterval(t):(we("envelopeModuleReady"),I.log.info("We have dispatched envelopeModuleReady event again!"),I.log.info("How many times we have dispatched event envelopeModuleReady: ",e+1))}),1e3)}}var Ye=n(2525);let Qe=!1;const et=(e,t)=>{Qe=!0,I.log.debug("GPP fully loaded"),nt(e,t)},tt=e=>{I.log.debug("GPP library didn't load in time."),window.__uspapi?e.ccpaFallbackHandler():(I.log.debug("Library __uspapi is not present."),J(!0),e.onConsentAccepted())},nt=(e,t)=>{t.onLoadHandler&&t.onLoadHandler(),rt(t),"boolean"==typeof e.consent&&(e.consent?(J(!0),X(),t.onConsentAccepted(e.consentString,e.cmpType,e.sectionId)):(Z(t.moduleName),t.onConsentRejected&&t.onConsentRejected()))},rt=e=>{W||(q(!0),window.addEventListener(`${e.moduleName}UserActionCompleteEvent`,(t=>{ot(t.detail,e)})))},ot=(e,t)=>{I.log.debug(`[GPP] event listener responded with ${JSON.stringify(e)}`);const{gppString:n,consent:r,sectionId:o,cmpType:i}=e;r?V?Y():(X(),J(!0),t.onUserInteractionAccept(n,i,o)):(Z(t.moduleName),J(!1),t.onUserInteractionReject&&t.onUserInteractionReject(i))},it={consent:!1,consentString:"",cmpType:"",sectionId:""};const at=(e,t,n)=>{it.consent?st(it,e,t,n):(z||(z=!0,window.addEventListener(`${n}LaunchpadCommunicationEvent`,(r=>{Object.assign(it,r.detail),J(r.detail.consent),st(r.detail,e,t,n)}))),I.cmpUtils.dispatchCustomEvent("atsConsentGatheringStartedEvent",n))},st=(e,t,n,r)=>{e.consent?(X(),t(e.consentString,e.cmpType,e.sectionId)):(n&&n(e.cmpType),Z(r))};let ct=!1;const ut=e=>{if(I.log.info("Location of the user is in country that has GDPR regulation!"),!0===ct)return I.log.debug("TCF library is loaded."),void(!0===V&&(X(),e.triggerModuleHandler()));W||e.moduleName===B||(window.addEventListener(`${e.moduleName}UserActionCompleteEvent`,(t=>{lt.triggerModuleBasedOnTcfConsent(t.detail,e)})),q(!0)),lt.handleConsent(e)},lt={handleConsent:e=>{ct||(ct=!0,e.moduleName!==B&&window.addEventListener(`${e.moduleName}RecheckAtsConsentEvent`,(t=>{"boolean"==typeof t.detail.consent&<.triggerModuleBasedOnTcfConsent(t.detail,e)})),Ye.ff.getTcfConsentObject(!0,e.moduleName))},triggerModuleBasedOnTcfConsent:(e,t)=>{e.consent?V?Y():(X(),J(!0),e.isUserInteraction?t.onUserInteractionAccept(e.consentString,e.cmpType):t.onConsentAccepted(e.consentString,e.cmpType)):(Z(t.moduleName),t.onUserInteractionReject&&t.onUserInteractionReject(e.cmpType),J(!1))}};function dt(){I.log.debug("CCPA library is present"),__uspapi("getUSPData",1,((e,t)=>{if(null===e.uspString)return I.log.debug("User did not interact with consent manager."),Ve();t?!function(e,t,n,r){if(4!==e.length)return r("CCPA consent string is not 4 characters long!"),!1;const o=e.split("")[2];return"Y"===o?(n("User didn't give consent. Library will shut down."),t.ccpaConsentString=void 0,!1):("N"===o?(n("User gave consent"),t.ccpaConsentString=e):"-"===o&&(n("CCPA doesnt apply to this user"),t.ccpaConsentString=void 0),!0)}(e.uspString,N,I.log.debug,I.log.error)?(I.log.debug("No consent has been given, envelope will be removed and library will shutdown!"),K(De?N.rootDomain:void 0)):Ve():(I.log.debug("No consent has been given, envelope will be removed and library will shutdown!"),K(De?N.rootDomain:void 0))}))}const ft=(e,t)=>{N.expirationTime=2592e6,"US"===e&&"CA"===t&&(N.expirationTime=1296e6)};function pt(){N.ccpaConsentString=void 0,N.gdprConsentString=void 0,N.gppConsentString=void 0}const gt=()=>K(De?N.rootDomain:void 0),bt=(e,t,n)=>{"gdpr"===t?N.gdprConsentString=e:"gpp"===t?(N.gppSectionId=+n,N.gppConsentString=e):"ccpa"===t?N.ccpaConsentString="-"===e.split("")[2]?void 0:e:pt(),Ve()},ht=e=>{"gdpr"===e?N.gdprConsentString=void 0:"gpp"===e?(N.gppSectionId=void 0,N.gppConsentString=void 0):"ccpa"===e&&(N.ccpaConsentString=void 0),gt()},vt={triggerModuleHandler:()=>Ve(),moduleName:M,onLoadHandler:null,onConsentAccepted:bt,onConsentRejected:gt,onUserInteractionAccept:bt,onUserInteractionReject:ht,ccpaFallbackHandler:dt},yt={checkCCPAConsent:dt,gatherUSConsent:async function(e){I.log.debug("User is in the US"),window.__gpp?((e,t)=>{I.log.debug("Check if GPP library is loaded?"),Qe?V&&(I.log.debug("GPP library is loaded."),X(),e.triggerModuleHandler()):(window.addEventListener(`${e.moduleName}CcpaFallbackEvent`,(()=>{tt(e)})),window.addEventListener(`${e.moduleName}RecheckAtsConsentEvent`,(t=>{et(t.detail,e)})),Ye.mF.getGppConsentObject(t,e.moduleName))})(vt,e):window.__uspapi?yt.checkCCPAConsent():Ve()},onUserInteractionAccept:bt,onUserInteractionReject:ht};let mt=!1;function St(e){mt=e}let wt=!1;async function Ot(e){N.update(e),N.gdprConsentString=void 0,N.ccpaConsentString=void 0,N.gppConsentString=void 0,function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"(ATS)";e.testMode||e.testEventCode?(e.logging="debug",(0,I.setLogger)(e.logging,t),I.log.debug("Test mode enabled.")):(0,I.setLogger)(e.logging,t);try{const n=new URL(window.location.href).searchParams.get("ats_debug");"true"===n?(e.logging="debug",(0,I.setLogger)(e.logging,t),I.log.debug("Debug mode enabled.")):"false"===n&&(I.log.debug("Debug mode disabled."),e.logging=void 0,(0,I.setLogger)(e.logging,t))}catch(e){I.log.debug("Creating URL object failed: "+e)}}(N,"(ATS-ENVELOPE-MODULE)"),window.addEventListener("message",Et,!1),window.addEventListener("message",At,!1),I.log.debug("ats-set-additional-data event set up."),N.useESP&&We(),Ct()}async function Ct(){if(window.navigator.globalPrivacyControl)return I.log.debug("GPC is enabled. Envelope will be deleted and envelope module will shutdown."),void K(De?N.rootDomain:void 0);if(function(){const e=window.doNotTrack||window.navigator.doNotTrack||window.navigator.msDoNotTrack;return!!e&&("1"===e.charAt(0)||"yes"===e)}())return I.log.debug("Do Not Track is enabled. Envelope will be deleted and envelope module will shutdown."),void K(De?N.rootDomain:void 0);N.rootDomain&&function(e,t){let n=e.split("."),r=t.split(".");for(let e=n.length-1,t=r.length-1;e>-1;e--,t--)if(n[e]!==r[t])return void I.log.error("Passed root domain is invalid!");De=!0}(N.rootDomain,window.location.hostname);const e=await Ie();N.countryCode=e.country,function(e){ft(e.country,e.region),window.__launchpad?at(vt.onUserInteractionAccept,vt.onUserInteractionReject,vt.moduleName):"US"===e.country?(N.gdprConsentString=void 0,yt.gatherUSConsent(e.region)):Ye.ff.gdprApplies(e.country)?(N.ccpaConsentString=void 0,N.gppConsentString=void 0,ut(vt)):(I.log.info("Location of the user is NOT in country that has GDPR or CCPA regulation!"),pt(),Ve())}(e)}async function Et(e){if(e&&e.source&&e.data&&"ats-modules-liveramp-envelope-request"===e.data){let t=await Be();t?(e.source.postMessage({message:"ats-modules-liveramp-envelope-result",result:t},"*"),I.log.debug("ats-modules-liveramp-envelope-result postMessage dispatched!")):(e.source.postMessage({message:"ats-modules-liveramp-envelope-result",result:void 0},"*"),I.log.debug("There is no envelope!"))}}async function At(e){e&&e.type&&"message"===e.type&&e.data&&e.data["ats-set-additional-data"]&&e.data["ats-set-additional-data"].detail&&"set-additional-data"===e.data["ats-set-additional-data"].detail.eventName&&e.data["ats-set-additional-data"].detail.identifier&&(I.log.debug("setAdditionalDataEvent received data."),N.email=e.data["ats-set-additional-data"].detail.identifier,St(!0),Ct())}const Pt=n(4147);function _t(e){Ot(e)}function It(e){!async function(e){if(I.log.info("START setAdditionalData FUNCTION!"),e&&e.id&&e.type)if(!1!==V){if(e.type&&e.id){if(!N.startWithExternalId)return void I.log.error("The startWithExternalId flag is set to false");switch(e.type){case"email":N.email=e.id;break;case"phoneNumber":N.phoneNumber=e.id;break;case"emailHashes":N.emailHashes=e.id;break;case"phoneNumberHashes":if(!$(e.id))return void I.log.error(`The "${e.type}" value is not hashed correctly.`);N.phoneNumberHashes=e.id;break;case"customerID":N.customerID=e.id;break;default:return void I.log.error(`The "${e.type}" value of type parameter is not in right format. Has to be one of: email, phoneNumber, emailHashes, phoneNumberHashes or customerID`)}}St(!0),Ct()}else I.log.debug("Consent was not given. Passing identifier will not be allowed.");else I.log.error("Data object is empty")}(e)}async function Tt(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:j.LIVERAMP,n=Object.values(k).indexOf(t);-1!==n&&(t=Object.keys(j)[n]);const r=await Be(t);return e?e(r):r}function Nt(e){const t={ENVELOPE_MODULE_VERSION:Pt.version,ENVELOPE_MODULE_CONFIG:JSON.parse(JSON.stringify(N))};if(!e)return t;e(t)}function xt(e){$e(e)}function Rt(){return wt}}(),window.atsenvelopemodule=r}();window.atsenvelopemodule.start({"placementID":"14044","storageType":"cookie","logging":"errors","accountID":"-1","catchIdentifier":false,"startWithExternalId":true,"testMode":false,"useESP":true,"usePAIR":true,"useDirect":false,"configId":"2e06f752-55d7-4caa-a21a-d4b6eb54d92f"});window.ats={},window.ats.LIB_GENERATED_TIMESTAMP=+new Date,window.ats.setAdditionalData=function(n){window.atsdropmatchpixelmodule&&window.atsdropmatchpixelmodule.setAdditionalData(n),window.atsenvelopemodule&&window.atsenvelopemodule.setAdditionalData(n)},window.ats.retrieveEnvelope=function(n,o="_lr_env"){if(window.atsenvelopemodule)return window.atsenvelopemodule.retrieveEnvelope(n,o)},window.ats.outputCurrentConfiguration=function(n){var o={};return window.atsdropmatchpixelmodule&&(o.DROP_MATCH_PIXEL_MODULE_INFO=window.atsdropmatchpixelmodule.outputCurrentConfiguration()),window.atsenvelopemodule&&(o.ENVELOPE_MODULE_INFO=window.atsenvelopemodule.outputCurrentConfiguration()),window.atsdetectionmodule&&(o.DETECTION_MODULE_INFO=window.atsdetectionmodule.outputCurrentConfiguration()),window.fbcapimodule&&(o.FBCAPI_MODULE_INFO=window.fbcapimodule.outputCurrentConfiguration()),window.atsconversionsmodule&&(o.CONVERSION_MODULE_INFO=window.atsconversionsmodule.outputCurrentConfiguration()),o.LIB_GENERATED_TIMESTAMP=window.ats.LIB_GENERATED_TIMESTAMP,n?n(o):o},window.ats.triggerDetection=function(){window.atsdetectionmodule&&window.atsdetectionmodule.triggerDetection()},window.ats.detectDataLayerEvents=function(n){window.fbcapimodule&&window.fbcapimodule.detectDataLayerEvents(n),window.atsconversionsmodule&&window.atsconversionsmodule.detectDataLayerEvents(n)},window.ats.invalidateEnvelope=function(n){window.atsenvelopemodule&&window.atsenvelopemodule.invalidateEnvelope(n)},window.ats.sendFbEvents=function(n){window.fbcapimodule&&window.fbcapimodule.sendFbEvents(n)},window.ats.sendPinterestEvents=function(n){window.atsconversionsmodule&&window.atsconversionsmodule.sendPinterestEvents(n)},window.ats.sendSnapchatEvents=function(n){window.atsconversionsmodule&&window.atsconversionsmodule.sendSnapchatEvents(n)},window.ats.sendTikTokEvents=function(n){window.atsconversionsmodule&&window.atsconversionsmodule.sendTikTokEvents(n)},window.ats.sendConversionEvents=function(){window.atsconversionsmodule&&window.atsconversionsmodule.sendConversionEvents()};