"use strict";(function(T,te){typeof exports=="object"&&typeof module0&&a[a.length-1])&&(u[0]===6||u[0]===2)){t=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]=r.length&&(r=void 0),{value:r&&r[i++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function W(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var i=t.call(r),n,a=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(s){o={error:s}}finally{try{n&&!n.done&&(t=i.return)&&t.call(i)}finally{if(o)throw o.error}}return a}function Ae(r,e,t){if(t||arguments.length===2)for(var i=0,n=e.length,a;i0&&a[a.length-1])&&(u[0]===6||u[0]===2)){t=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]=r.length&&(r=void 0),{value:r&&r[i++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function xe(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var i=t.call(r),n,a=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(s){o={error:s}}finally{try{n&&!n.done&&(t=i.return)&&t.call(i)}finally{if(o)throw o.error}}return a}function Te(r,e,t){if(t||arguments.length===2)for(var i=0,n=e.length,a;i>6|192,e[t++]=n&63|128):(n&64512)==55296&&i+1>18|240,e[t++]=n>>12&63|128,e[t++]=n>>6&63|128,e[t++]=n&63|128):(e[t++]=n>>12|224,e[t++]=n>>6&63|128,e[t++]=n&63|128)}return Uint8Array.from(e)},ue=-862048943,le=461845907,ce=15,zt=13,Qt=5,Wt=-430675100,Kt=function(r,e){e===void 0&&(e=0);for(var t=Gt(r),i=t.length,n=i>>2,a=e,o=0;o>>0},Jt=function(r,e){var t=r,i=e;return t=Math.imul(t,ue),t=re(t,ce),t=Math.imul(t,le),i^=t,i=re(i,zt),i=Math.imul(i,Qt),i+Wt|0},Xt=function(r){var e=r;return e^=e>>>16,e=Math.imul(e,-2048144789),e^=e>>>13,e=Math.imul(e,-1028477387),e^=e>>>16,e},re=function(r,e,t){t===void 0&&(t=32),e>t&&(e=e%t);var i=4294967295>>0,n=(r&i)>>>0>>>t-e>>>0;return(r>>0},Yt=function(r,e){e===void 0&&(e=0);var t=r[e]>>24|(r&16711680)>>>8|(r&65280)e.major?1:this.majore.minor?1:this.minore.patch?1:this.patche.preRelease?1:this.preRelease=v&&f

=b&&yi;case g.GREATER_THAN_EQUALS:case g.VERSION_GREATER_THAN_EQUALS:return e>=i;default:return!1}},r.prototype.versionComparator=function(e,t,i){var n=e.compareTo(i);switch(t){case g.LESS_THAN:case g.VERSION_LESS_THAN:return n0;case g.GREATER_THAN_EQUALS:case g.VERSION_GREATER_THAN_EQUALS:return n>=0;default:return!1}},r.prototype.matchesRegex=function(e,t){return t.some(function(i){return!!new RegExp(i).exec(e)})},r.prototype.containsNone=function(e){return e.some(function(t){return t==="(none)"})},r.prototype.containsBooleans=function(e){return e.some(function(t){switch(t.toLowerCase()){case"true":case"false":return!0;default:return!1}})},r.prototype.parseNumber=function(e){var t;return(t=Number(e))!==null&&t!==void 0?t:void 0},r.prototype.coerceString=function(e){if(e!=null)return typeof e=="object"?JSON.stringify(e):String(e)},r.prototype.coerceStringArray=function(e){var t=this;if(Array.isArray(e)){var i=e;return i.map(function(s){return t.coerceString(s)}).filter(Boolean)}var n=String(e);try{var a=JSON.parse(n);if(Array.isArray(a)){var i=e;return i.map(function(l){return t.coerceString(l)}).filter(Boolean)}else{var o=this.coerceString(n);return o?[o]:void 0}}catch{var o=this.coerceString(n);return o?[o]:void 0}},r.prototype.isSetOperator=function(e){switch(e){case g.SET_IS:case g.SET_IS_NOT:case g.SET_CONTAINS:case g.SET_DOES_NOT_CONTAIN:case g.SET_CONTAINS_ANY:case g.SET_DOES_NOT_CONTAIN_ANY:return!0;default:return!1}},r.prototype.setEquals=function(e,t){var i=new Set(e),n=new Set(t);return i.size===n.size&&Te([],xe(n),!1).every(function(a){return i.has(a)})},r.prototype.matchesSetContainsAll=function(e,t){var i,n;if(e.length{let e={};return r.forEach((t,i)=>e[t]=i),e})(ie),sr=/^(?:[A-Za-z\d+\/]{4})*?(?:[A-Za-z\d+\/]{2}(?:==)?|[A-Za-z\d+\/]{3}=?)?$/,U=String.fromCharCode.bind(String),Ze=typeof Uint8Array.from=="function"?Uint8Array.from.bind(Uint8Array):r=>new Uint8Array(Array.prototype.slice.call(r,0)),$e=r=>r.replace(/=/g,"").replace(/[+\/]/g,e=>e=="+"?"-":"_"),et=r=>r.replace(/[^A-Za-z0-9\+\/]/g,""),tt=r=>{let e,t,i,n,a="";const o=r.length%3;for(let s=0;s255||(i=r.charCodeAt(s++))>255||(n=r.charCodeAt(s++))>255)throw new TypeError("invalid character found");e=t>18&63]+ie[e>>12&63]+ie[e>>6&63]+ie[e&63]}return o?a.slice(0,o-3)+"===".substring(o):a},ke=typeof btoa=="function"?r=>btoa(r):X?r=>Buffer.from(r,"binary").toString("base64"):tt,Ie=X?r=>Buffer.from(r).toString("base64"):r=>{let t=[];for(let i=0,n=r.length;ie?$e(Ie(r)):Ie(r),ur=r=>{if(r.length>>6)+U(128|e&63):U(224|e>>>12&15)+U(128|e>>>6&63)+U(128|e&63)}else{var e=65536+(r.charCodeAt(0)-55296)*1024+(r.charCodeAt(1)-56320);return U(240|e>>>18&7)+U(128|e>>>12&63)+U(128|e>>>6&63)+U(128|e&63)}},lr=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,rt=r=>r.replace(lr,ur),it=X?r=>Buffer.from(r,"utf8").toString("base64"):Ye?r=>Ie(Ye.encode(r)):r=>ke(rt(r)),Y=(r,e=!1)=>e?$e(it(r)):it(r),nt=r=>Y(r,!0),cr=/[\xC0-\xDF][\x80-\xBF]|[\xE0-\xEF][\x80-\xBF]{2}|[\xF0-\xF7][\x80-\xBF]{3}/g,fr=r=>{switch(r.length){case 4:var e=(7&r.charCodeAt(0))>>10)+55296)+U((t&1023)+56320);case 3:return U((15&r.charCodeAt(0))r.replace(cr,fr),ot=r=>{if(r=r.replace(/\s+/g,""),!sr.test(r))throw new TypeError("malformed base64.");r+="==".slice(2-(r.length&3));let e,t="",i,n;for(let a=0;a>16&255):n===64?U(e>>16&255,e>>8&255):U(e>>16&255,e>>8&255,e&255);return t},Ne=typeof atob=="function"?r=>atob(et(r)):X?r=>Buffer.from(r,"base64").toString("binary"):ot,st=X?r=>Ze(Buffer.from(r,"base64")):r=>Ze(Ne(r).split("").map(e=>e.charCodeAt(0))),ut=r=>st(lt(r)),dr=X?r=>Buffer.from(r,"base64").toString("utf8"):Xe?r=>Xe.decode(st(r)):r=>at(Ne(r)),lt=r=>et(r.replace(/[-_]/g,e=>e=="-"?"+":"/")),Oe=r=>dr(lt(r)),vr=r=>{if(typeof r!="string")return!1;const e=r.replace(/\s+/g,"").replace(/={0,2}$/,"");return!/[^\s0-9a-zA-Z\+/]/.test(e)||!/[^\s0-9a-zA-Z\-_]/.test(e)},ct=r=>({value:r,enumerable:!1,writable:!0,configurable:!0}),ft=function(){const r=(e,t)=>Object.defineProperty(String.prototype,e,ct(t));r("fromBase64",function(){return Oe(this)}),r("toBase64",function(e){return Y(this,e)}),r("toBase64URI",function(){return Y(this,!0)}),r("toBase64URL",function(){return Y(this,!0)}),r("toUint8Array",function(){return ut(this)})},dt=function(){const r=(e,t)=>Object.defineProperty(Uint8Array.prototype,e,ct(t));r("toBase64",function(e){return de(this,e)}),r("toBase64URI",function(){return de(this,!0)}),r("toBase64URL",function(){return de(this,!0)})},Ce={version:Je,VERSION:or,atob:Ne,atobPolyfill:ot,btoa:ke,btoaPolyfill:tt,fromBase64:Oe,toBase64:Y,encode:Y,encodeURI:nt,encodeURL:nt,utob:rt,btou:at,decode:Oe,isValid:vr,fromUint8Array:de,toUint8Array:ut,extendString:ft,extendUint8Array:dt,extendBuiltins:()=>{ft(),dt()}};var vt=(function(r){Ge(e,r);function e(t,i){var n=r.call(this,i)||this;return n.statusCode=t,Object.setPrototypeOf(n,e.prototype),n}return e})(Error),Pe=(function(r){Ge(e,r);function e(t){var i=r.call(this,t)||this;return Object.setPrototypeOf(i,e.prototype),i}return e})(Error),hr=(function(){function r(e,t,i){this.deploymentKey=e,this.serverUrl=t,this.httpClient=i}return r.prototype.getVariants=function(e,t){return ze(this,void 0,void 0,function(){var i,n,a,o;return Qe(this,function(s){switch(s.label){case 0:return i=Ce.encodeURL(JSON.stringify(e)),n={Authorization:"Api-Key ".concat(this.deploymentKey),"X-Amp-Exp-User":i},t?.flagKeys&&(n["X-Amp-Exp-Flag-Keys"]=Ce.encodeURL(JSON.stringify(t.flagKeys))),t?.trackingOption&&(n["X-Amp-Exp-Track"]=t.trackingOption),a=new URL("".concat(this.serverUrl,"/sdk/v2/vardata?v=0")),t?.evaluationMode&&a.searchParams.append("eval_mode",t?.evaluationMode),t?.deliveryMethod&&a.searchParams.append("delivery_method",t?.deliveryMethod),[4,this.httpClient.request({requestUrl:a.toString(),method:"GET",headers:n,timeoutMillis:t?.timeoutMillis})];case 1:if(o=s.sent(),o.status!=200)throw new vt(o.status,"Fetch error response: status=".concat(o.status));return[2,JSON.parse(o.body)]}})})},r})(),pr=(function(){function r(e,t,i){this.deploymentKey=e,this.serverUrl=t,this.httpClient=i}return r.prototype.getFlags=function(e){return ze(this,void 0,void 0,function(){var t,i,n;return Qe(this,function(a){switch(a.label){case 0:return t={Authorization:"Api-Key ".concat(this.deploymentKey)},e?.libraryName&&e?.libraryVersion&&(t["X-Amp-Exp-Library"]="".concat(e.libraryName,"/").concat(e.libraryVersion)),e?.user&&(t["X-Amp-Exp-User"]=Ce.encodeURL(JSON.stringify(e.user))),[4,this.httpClient.request({requestUrl:"".concat(this.serverUrl,"/sdk/v2/flags")+(e?.deliveryMethod?"?delivery_method=".concat(e.deliveryMethod):""),method:"GET",headers:t,timeoutMillis:e?.timeoutMillis})];case 1:if(i=a.sent(),i.status!=200)throw Error("Flags error response: status=".concat(i.status));return n=JSON.parse(i.body),[2,n.reduce(function(o,s){return o[s.key]=s,o},{})]}})})},r})(),P=typeof globalThis=2&&d[1]&&(v=atob(d[1])),{deviceId:d[0],userId:v}}catch{return}},mr=function(r){var e=Re(r,!0);try{var t=P.localStorage.getItem(e);if(!t)return;var i=JSON.parse(t);return typeof i!="object"?void 0:i}catch{return}},br=function(r){var e=Re(r,!0);try{var t=P.sessionStorage.getItem(e);if(!t)return;var i=JSON.parse(t);return typeof i!="object"?void 0:i}catch{return}},Re=function(r,e){if(e)return r?.length0&&(this.queue.forEach(function(t){e(t)}),this.queue=[])},r})(),z=function(){return z=Object.assign||function(e){for(var t,i=1,n=arguments.length;i=r.length&&(r=void 0),{value:r&&r[i++],done:!r}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function yt(r,e){var t=typeof Symbol=="function"&&r[Symbol.iterator];if(!t)return r;var i=t.call(r),n,a=[],o;try{for(;(e===void 0||e-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(s){o={error:s}}finally{try{n&&!n.done&&(t=i.return)&&t.call(i)}finally{if(o)throw o.error}}return a}typeof SuppressedError=="function"&&SuppressedError;var he=function(r,e){var t,i,n=["string","number","boolean","undefined"],a=typeof r,o=typeof e;if(a!==o)return!1;try{for(var s=ve(n),l=s.next();!l.done;l=s.next()){var u=l.value;if(u===a)return r===e}}catch(p){t={error:p}}finally{try{l&&!l.done&&(i=s.return)&&i.call(s)}finally{if(t)throw t.error}}if(r==null&&e==null)return!0;if(r==null||e==null||r.length!==e.length)return!1;var f=Array.isArray(r),y=Array.isArray(e);if(f!==y)return!1;if(f&&y){for(var c=0;cthis.maxQueueSize&&(this.inMemoryQueue=this.inMemoryQueue.slice(this.inMemoryQueue.length-this.maxQueueSize)),P.localStorage.setItem(this.storageKey,JSON.stringify(this.inMemoryQueue)))},r.prototype.loadFlushStore=function(){this.loadQueue(),this.flush(),this.storeQueue()},r})(),Dr=function(){var r=K();if(r)try{var e="EXP_test";return r.sessionStorage.setItem(e,e),r.sessionStorage.removeItem(e),!0}catch{return!1}return!1},Ue=(function(){function r(){this.globalScope=K()}return r.prototype.get=function(e){var t;return(t=this.globalScope)===null||t===void 0?void 0:t.localStorage.getItem(e)},r.prototype.put=function(e,t){var i;(i=this.globalScope)===null||i===void 0||i.localStorage.setItem(e,t)},r.prototype.delete=function(e){var t;(t=this.globalScope)===null||t===void 0||t.localStorage.removeItem(e)},r})(),Fr=function(r,e,t){var i=r.substring(r.length-6),n="amp-exp-".concat(e,"-").concat(i);return new wt(n,t,St)},Br=function(r,e,t){t===void 0&&(t=new Ue);var i=r.substring(r.length-6),n="amp-exp-".concat(e,"-").concat(i,"-flags");return new wt(n,t)},wt=(function(){function r(e,t,i){this.cache={},this.namespace=e,this.storage=t,this.transformer=i}return r.prototype.get=function(e){return this.cache[e]},r.prototype.getAll=function(){return A({},this.cache)},r.prototype.put=function(e,t){this.cache[e]=t},r.prototype.putAll=function(e){var t,i;try{for(var n=q(Object.keys(e)),a=n.next();!a.done;a=n.next()){var o=a.value;this.cache[o]=e[o]}}catch(s){t={error:s}}finally{try{a&&!a.done&&(i=n.return)&&i.call(n)}finally{if(t)throw t.error}}},r.prototype.remove=function(e){delete this.cache[e]},r.prototype.clear=function(){this.cache={}},r.prototype.load=function(){var e,t,i=this.storage.get(this.namespace),n;try{n=JSON.parse(i)||{}}catch{return}var a={};try{for(var o=q(Object.keys(n)),s=o.next();!s.done;s=o.next()){var l=s.value;try{var u=void 0;this.transformer?u=this.transformer(n[l]):u=n[l],u&&(a[l]=u)}catch{}}}catch(f){e={error:f}}finally{try{s&&!s.done&&(t=o.return)&&t.call(o)}finally{if(e)throw e.error}}this.clear(),this.putAll(a)},r.prototype.store=function(e){e===void 0&&(e=this.cache),this.storage.put(this.namespace,JSON.stringify(e))},r})(),St=function(r){if(typeof r=="string")return{key:r,value:r};if(typeof r=="object"){var e=r.key,t=r.value,i=r.payload,n=r.metadata,a=r.expKey;n&&n.experimentKey?a=n.experimentKey:a&&(n=n||{},n.experimentKey=a);var o={};return e?o.key=e:t&&(o.key=t),t&&(o.value=t),n&&(o.metadata=n),i&&(o.payload=i),a&&(o.expKey=a),o}},Et=(function(){function r(){this.globalScope=K()}return r.prototype.get=function(e){var t;return(t=this.globalScope)===null||t===void 0?void 0:t.sessionStorage.getItem(e)},r.prototype.put=function(e,t){var i;(i=this.globalScope)===null||i===void 0||i.sessionStorage.setItem(e,t)},r.prototype.delete=function(e){var t;(t=this.globalScope)===null||t===void 0||t.sessionStorage.removeItem(e)},r})(),Hr=function(r,e,t,i){var n,a="[Experiment] Exposure",o=t?.value,s="[Experiment] ".concat(e);return{name:a,user:r,key:e,variant:t,userProperty:s,properties:{key:e,variant:o,source:i},userProperties:(n={},n[s]=o,n)}},B=function(r){return r==null},Le=function(r){return B(r)?!0:r&&Object.keys(r).length===0},jr=function(r){var e,t;if(!r||typeof r!="object")return{};var i={};try{for(var n=q(Object.entries(r)),a=n.next();!a.done;a=n.next()){var o=W(a.value,2),s=o[0],l=o[1];B(l)||(i[s]=l)}}catch(u){e={error:u}}finally{try{a&&!a.done&&(t=n.return)&&t.call(n)}finally{if(e)throw e.error}}return i},At=function(r){var e;return((e=r?.metadata)===null||e===void 0?void 0:e.evaluationMode)==="local"},qr=(function(){function r(e,t,i,n){this.started=!1,this.done=!1,this.attempts=e,this.min=t,this.max=i,this.scalar=n}return r.prototype.start=function(e){return O(this,void 0,void 0,function(){return C(this,function(t){switch(t.label){case 0:if(!this.started)this.started=!0;else throw Error("Backoff already started");return[4,this.backoff(e,0,this.min)];case 1:return t.sent(),[2]}})})},r.prototype.cancel=function(){this.done=!0,clearTimeout(this.timeoutHandle)},r.prototype.backoff=function(e,t,i){return O(this,void 0,void 0,function(){var n=this;return C(this,function(a){return this.done?[2]:(this.timeoutHandle=P.setTimeout(function(){return O(n,void 0,void 0,function(){var o,s;return C(this,function(l){switch(l.label){case 0:return l.trys.push([0,2,,3]),[4,e()];case 1:return l.sent(),[3,3];case 2:return l.sent(),o=t+1,o0&&y[0]){var c=y[0],h={group_name:c},d=(n=(i=r.group_properties)===null||i===void 0?void 0:i[f])===null||n===void 0?void 0:n[c];d&&Object.keys(d).length>0&&(h.group_properties=d),s[f]=h}}}catch(v){e={error:v}}finally{try{u&&!u.done&&(t=l.return)&&t.call(l)}finally{if(e)throw e.error}}return Object.keys(s).length>0&&(a.groups=s),delete a.user.groups,delete a.user.group_properties,a},M=function(r){return r==null?{}:typeof r=="string"?{key:r,value:r}:r},_t=function(r){if(!r)return{};var e=void 0;r.metadata&&(e=r.metadata.experimentKey);var t={};return r.key&&(t.key=r.key),r.value&&(t.value=r.value),r.payload&&(t.payload=r.payload),e&&(t.expKey=e),r.metadata&&(t.metadata=r.metadata),t},Gr=(function(){function r(e){this.setProperties={},this.unsetProperties={},this.analyticsProvider=e}return r.prototype.track=function(e){this.setProperties[e.key]!=e.variant.value&&(this.setProperties[e.key]=e.variant.value,delete this.unsetProperties[e.key],this.analyticsProvider.track(e))},r.prototype.setUserProperty=function(e){this.setProperties[e.key]!=e.variant.value&&this.analyticsProvider.setUserProperty(e)},r.prototype.unsetUserProperty=function(e){this.unsetProperties[e.key]||(this.unsetProperties[e.key]="unset",delete this.setProperties[e.key],this.analyticsProvider.unsetUserProperty(e))},r})(),zr=(function(){function r(e){this.tracked={},this.exposureTrackingProvider=e}return r.prototype.track=function(e){var t=this.tracked[e.flag_key];t&&t.variant===e.variant||(this.tracked[e.flag_key]=e,this.exposureTrackingProvider.track(e))},r})(),Qr=1e4,Wr=8,Kr=500,Jr=1e4,Xr=1.5,xt=6e4,Yr="https://api.lab.eu.amplitude.com",Zr="https://flag.lab.eu.amplitude.com",Tt=(function(){function r(e,t){var i=this,n,a,o,s;this.engine=new nr,this.isRunning=!1,this.apiKey=e,t=jr(t),this.config=A(A(A({},J),t),{serverUrl:t?.serverUrl||(((n=t?.serverZone)===null||n===void 0?void 0:n.toLowerCase())==="eu"?Yr:J.serverUrl),flagsServerUrl:t?.flagsServerUrl||(((a=t?.serverZone)===null||a===void 0?void 0:a.toLowerCase())==="eu"?Zr:J.flagsServerUrl),flagConfigPollingIntervalMillis:t.flagConfigPollingIntervalMillis=500||e.statusCode===429:!0},r.prototype.addPlugin=function(e){e.type==="integration"&&this.integrationManager.setIntegration(e)},r})(),$r=typeof globalThis0?x.length===2?typeof x[1]==s?this[x[0]]=x[1].call(this,j):this[x[0]]=x[1]:x.length===3?typeof x[1]===s&&!(x[1].exec&&x[1].test)?this[x[0]]=j?x[1].call(this,j,x[2]):i:this[x[0]]=j?j.replace(x[1],x[2]):i:x.length===4&&(this[x[0]]=j?x[3].call(this,j.replace(x[1],x[2])):i):this[x]=j||i;S+=2}},Ve=function(w,_){for(var S in _)if(typeof _[S]===u&&_[S].length>0){for(var I=0;I<_ s="==o?i:S}else" if w mini desktop gecko secure focus touch coc coast safari qtcarbrowser . headless wv webview version vr rv: reality browser ppc mac nexus bui build lte bui. oppo tv c tablet b phone note duo noble b. one xbox netcast. applew mobile ce edge nt os like opera x rv:. linux gnu enterprise instanceof h new t this.getbrowser="function(){var" e="{};return">V?qe(E,V):E,this},this.setUA(S),this};H.VERSION=n,H.BROWSER=we([h,p,y]),H.CPU=we([k]),H.DEVICE=we([c,v,d,R,m,L,b,D,Q]),H.ENGINE=H.OS=we([h,p]),r.exports&&(e=r.exports=H),e.UAParser=H;var ee=typeof t!==l&&(t.jQuery||t.Zepto);if(ee&&!ee.ua){var Se=new H;ee.ua=Se.getResult(),ee.ua.get=function(){return Se.getUA()},ee.ua.set=function(w){Se.setUA(w);var _=Se.getResult();for(var S in _)ee.ua[S]=_[S]}}})(typeof window=="object"?window:$r)}),ii=(function(){function r(e,t){var i,n,a;this.globalScope=K(),this.userAgent=typeof((i=this.globalScope)===null||i===void 0?void 0:i.navigator)